APIs & Integrations

badru
Member

syncing eCommerce data into HubSpot My eCommerce Website is custom made

so i need to send order data from my website to hubspot when successfull place order.

 

so how can i start with.

0 Upvotes
1 Reply 1
jackcoldrick
HubSpot Employee
HubSpot Employee

syncing eCommerce data into HubSpot My eCommerce Website is custom made

Hi @badru,

 

I'd recommend leveraging the eCommerce Bridge API. This API is a collection of endpoints that facilitate the connection of multiple eCommerce stores to HubSpot. Once connected it allows for a unidirectional flow of data from the source store to the HubSpot portal. In addition to this it enables some eCommerce functionality in the portal. Specifically: 

 

  • eCommerce Pipeline - All orders synced from your system will reside here as deals.
  • eCommerce Reports - Some out of the box reports you can use on dashboards.
  • eCommerce Workflows - Ability to automate processes for cart abandonment, re-engagement and welcome emails.
  • eCommerce Templates - A collection of email templates to use in the above workflows. These can be customized.

in terms of technical setup, documentation can be found here. I've also recorded a 45 minute long instructional video as to how this API works and how it can be used to sync data into a HubSpot Portal: https://share.vidyard.com/watch/ioASdnjaCi4iUGF869kRER?

 

It's important to note that the bridge is focused on 4 core objects they are as follows:

 

  • Contacts - These represent your customers
  • Deals - These represent your orders
  • Products - These represent your product library/inventory
  • Line Items - These represent a single line on a transaction record. They can be thought of as an instace of a Product that a customer has begun or completed purchasing. They are associated with both Deals and Products.

The relationship between those objects looks like this:

 

Screen Shot 2020-08-02 at 2.35.43 PM.png

 

The general approach (outlined in the video) when it comes to setting up an integration of this nature is as follows: 

 

  • CHOOSE AUTHENTICATION: Decide on method of authentication, whether you want to use an API key or oAuth2.0. More information on authentication can be found here. Generally speaking if the application is being designed for a single portal I'd recommend using the API key. If you intend to use it across multiple different portals I'd recommend the oAuth2.0 authentication method.
  • DEFINE SETTINGS: Using this endpoint define your eCommerce sync settings. During this process you are mapping object properties in your system to object properties in HubSpot. This is a very important phase and one I often recommend you plan on paper first. Think about what information you have in your ecommerce system and decide what properties you will store it against in HubSpot. 
  • CREATE STORES: Using this endpoint create your stores. All data synced to HubSpot will have a source store property allowing for easy filtering/segmentation and reporting. 
  • SYNC DATA: Once you've defined your settings and created your stores you are ready to start syncing data to HubSpot via this endpoint. Please keep in mind that the eCommerce Bridge is an asynchronous API so you will always receive a 204 response code (more on error handling down below). HubSpot will then take your sync message, query your settings defined and update the appropriate Objects and properties within the Hubspot system.

As mentioned it's an asynchronous API. Therefore erros are not surfaced straight away. With that said there are endpoints that can help here:

 

If you've gone down the route of using an API key for a single portal install then the following endpoints can assist with error checking:

 

  • Check Sync Status for specific Object: This will allow you to see if any errors have occurred when syncing a specific object (Contact, Deal, Product or Line Item).
  • Get all sync errors for a portal:  This endpoint will allow you to see all errors for the entire portal across all objects (Contact, Deal, Product or Line Item). You can also filter by open and resolved issues.

Alternatively If you're using oAuth and/or have your app installed across multiple portals the following endpoints will help from an error checking standpoint:

 

I hope this helps.

Jack

Jack Coldrick
Solutions Engineer @ HubSpot
Add me on LinkedIn
0 Upvotes