GI Supply linked OroCommerce and HubSpot with a two-way sync of contacts and orders

By Lynton
GI Supply linked OroCommerce and HubSpot with a two-way sync of contacts and orders

The Customer

GI Supply distributes gastroenterology supplies and devices to hospitals and the clinicians who work in them. Their customer, account and order records lived in OroCommerce, the B2B commerce and CRM platform behind their online shop. Their marketing ran in HubSpot. The two systems had no connection, and Lynton, then a HubSpot partner, was brought in to build one.

The Challenge

The sales side of the business worked in Oro. That is where accounts were owned, where orders were placed and where line items lived. Marketing worked in the other system, where contacts were owned and emails were sent. Anyone who needed the whole picture had to look in both places, and a change made in one system stayed there.

The shape of GI Supply’s customer base made this harder. Parent accounts have many child customers underneath them, around 415 parents in all. Marketing wanted to email everyone under a given parent, which means each contact’s parent membership has to be known on the marketing side. At the time, the platform allowed a contact only one company association, while a contact in Oro could belong to several accounts.

Ownership had its own rules. Who owns a customer is decided in Oro. Who owns a contact is decided in HubSpot. A sync that ignored that split would overwrite the wrong system.

The Solution

We built a two-way integration between OroCommerce and HubSpot in two phases, described in seven field maps.

Phase one covered people and companies. Maps 1 to 3 sync Oro contacts and accounts with the CRM’s contacts and companies. The account owner in Oro sets the company owner in the CRM, and the contact owner in the CRM sets the contact owner in Oro, so each system stays the record of truth for the thing it decides. At GI Supply’s request we also built a workflow that gives a company owner ownership of every contact associated with that company. Calendar events and emails logged in Oro sync across as engagements, which needed GI Supply’s Oro vendor to expose those endpoints in production.

Phase two covered money. Maps 4 and 5 sync CRM deals with Oro opportunities, with ownership flowing both ways and the CRM holding the final say on deal owner. Map 6 brings Oro orders into the CRM as deals, and Map 7 brings their line items, so sales and marketing can see what each customer bought.

For the parent accounts, we used a Primary Account checkbox in Oro. Each contact is assigned one primary account, and that is the company it is associated with in the CRM. The integration then creates a dynamic list for each of the parent accounts and adds every contact under that parent to its list. Lists are keyed on the Oro ID rather than the name, so when a parent is renamed its list follows. Marketing can email by parent account from the lists they already use.

The details got the same attention as the maps. We reconciled the job title picklist between the two systems, including merging property values, audited the internal values of every picklist across every object, mapped Close Reason, removed the Goods Type mapping, and added a custom Oro deal name property in the CRM that syncs to the opportunity name in Oro.

Testing ran until the client signed off. We tested internally first, then ran two rounds of user acceptance testing with GI Supply working from a test-scenario spreadsheet and a feedback form, with test records flagged so only those moved. Change requests from the first round were built and retested in the second. We then tested against sandbox and production Oro deployments before scheduling the historical sync. That sync carried every record created since January 1, 2014, and we monitored it for errors through to completion.

We also set a rule for daily use. When a record is edited in one system, leave its twin alone until the change has synced. Two-way syncs need that discipline.

What They Got

Sales and marketing now work from the same facts. A contact or account created in Oro appears in the CRM, and a contact owner set in the CRM appears in Oro. Orders placed in the shop show up as deals with line items, so marketing can see what a customer bought before writing to them. Every parent account has a ready-made list that keeps itself current.

Owners are set once, in the system that decides them, and the other system follows. This engagement included no measurement of email or sales results after launch, so we make no claims about them.

Wrapping Up

On every integration we write the ownership rules down before we write code, and we test with the client until they sign off in their production system. Lynton now builds AI-native websites on open infrastructure; see our current work at /case-studies.