ml-connector
Microsoft Dynamics 365 Business CentralMarketo

Microsoft Dynamics 365 Business Central and Marketo integration

Microsoft Dynamics 365 Business Central runs finance, sales, and the customer master. Marketo runs B2B marketing automation across leads, companies, and campaigns. Connecting the two means the customers and contacts kept in the ERP show up in Marketo as Leads and Companies, carrying the account and revenue attributes marketers segment on, and new leads created in marketing flow back into Business Central as customers. ml-connector handles the very different APIs on each side and moves the records on a schedule you control. Because Marketo holds no AP invoices or general ledger, finance data stays in Business Central and only people and account records cross over.

How Microsoft Dynamics 365 Business Central works

Microsoft Dynamics 365 Business Central exposes customers, contacts, vendors, items, sales documents, and GL data through Business Central API v2.0, a REST API built on OData v4, with JSON payloads and all resources nested under a company in a named tenant environment. It authenticates with Microsoft Entra ID OAuth 2.0 client credentials, using a registered app client ID, client secret, and tenant ID against the businesscentral.dynamics.com scope. It supports push notifications through a subscription API, but those notifications carry only a change signal, so the connector must fetch the changed record afterward, and subscriptions expire every three days and must be renewed. Customers and most masters are read and written, and incremental reads use an OData filter on lastModifiedDateTime.

How Marketo works

Marketo exposes Leads, Companies, Opportunities, Sales Persons, and read-only Activities through the Marketo REST API v1, with JSON bodies on a per-instance subdomain derived from the Munchkin Account ID. It authenticates with OAuth 2.0 client credentials generated from a Custom Service, returning a Bearer token that lasts at most one hour and must be renewed before it expires. Leads upsert on email and Companies upsert on externalCompanyId. Marketo has no inbound webhook or change-event subscription, so a connector pulling data out must poll the REST API or the Bulk Extract API. Most API errors return HTTP 200 with a success flag set to false and an errors array, so the body must be parsed rather than the status code.

What moves between them

The main flow runs from Microsoft Dynamics 365 Business Central into Marketo. ml-connector reads customers and their contact records and upserts them into Marketo as Companies and Leads, carrying account attributes such as company name, currency, balance, and total sales so marketing can segment on real ERP data. Customer contacts map to Marketo Leads keyed on email, and the parent customer maps to a Marketo Company keyed on externalCompanyId. A reverse flow reads new and changed Marketo Leads on a schedule and creates or updates matching customers and contacts in Business Central. Finance documents such as AP bills and the general ledger have no equivalent in Marketo, so they stay in Business Central and never cross over.

How ml-connector handles it

ml-connector stores both credential sets encrypted. On the Business Central side it requests an Entra ID client-credentials token for the businesscentral.dynamics.com scope and builds the base URL from the stored environment name and company ID. On the Marketo side it exchanges the Custom Service client ID and secret for a Bearer token and renews it before the one-hour expiry. Business Central change subscriptions deliver only a signal, so on each notification the connector fetches the customer or contact by ID and then upserts it into Marketo, while a scheduled poll using an OData lastModifiedDateTime filter backfills anything a notification missed. Because Marketo has no inbound webhooks, the reverse direction is always a poll, reading changed Leads with an updatedAt filter and a paging token. Leads dedupe on email and Companies on externalCompanyId, so re-reading a record updates rather than duplicates it, and a BullMQ jobId keyed on the Business Central number prevents double enqueues. A real edge case: if a native Dynamics CRM sync is already enabled inside Marketo, Companies and Opportunities become read-only through the API, so the connector writes Leads only in that configuration and surfaces the company writes as skipped. Marketo returns most errors as HTTP 200 with success false, so the connector inspects the errors array, backs off on rate-limit codes 606 and 615, and replays any record whose downstream write fails.

A real-world example

A mid-sized industrial equipment maker with roughly 250 employees runs Microsoft Dynamics 365 Business Central for finance, sales orders, and the customer master, and runs Marketo for demand generation and nurture campaigns. Before the integration, a marketing operations person exported customer lists from the ERP to a spreadsheet every few weeks and imported them into Marketo by hand, so segments were stale, account revenue was missing, and new inbound leads sat in Marketo with no matching customer in finance. With Business Central and Marketo connected, each customer and contact flows into Marketo as a Company and Lead within the sync window, carrying balance and total-sales figures for segmentation, and new marketing leads land back in Business Central as customers. The manual export step is gone and the two systems agree on who the accounts and contacts are.

What you can do

  • Upsert Microsoft Dynamics 365 Business Central customers into Marketo as Companies keyed on externalCompanyId.
  • Sync Business Central customer contacts into Marketo as Leads deduplicated on email.
  • Carry account attributes such as currency, balance, and total sales so marketing can segment on real ERP data.
  • Read new and changed Marketo Leads back into Business Central as customers and contacts on a schedule.
  • Bridge Entra ID client credentials and Marketo OAuth tokens, with rate-limit backoff and a full audit trail on every record.

Questions

Which direction does data move between Microsoft Dynamics 365 Business Central and Marketo?
The main flow is Business Central into Marketo. Customers and their contacts move out of the ERP and upsert into Marketo as Companies and Leads, carrying account and revenue attributes for segmentation. A reverse flow reads new and changed Marketo Leads back into Business Central as customers and contacts, while finance data such as AP bills and the general ledger stays in Business Central because Marketo has no equivalent.
Does Marketo push changes, or does ml-connector poll for them?
Marketo has no inbound webhook or change-event subscription, so ml-connector polls the Marketo REST API on a schedule, reading changed Leads with an updatedAt filter and a paging token. Business Central does support subscription notifications, but they carry only a change signal, so the connector fetches the changed record afterward and renews each subscription before its three-day expiry. A scheduled poll on lastModifiedDateTime backs up the notifications.
What happens if a native Dynamics sync is already turned on inside Marketo?
Marketo makes Companies, Opportunities, and Sales Persons read-only through its API whenever a native SFDC or Dynamics CRM sync is enabled. In that configuration ml-connector writes Leads only, since Leads remain writable, and reports the company writes as skipped rather than failing them. Marketo returns these and most other conditions as HTTP 200 with a success flag of false, so the connector parses the response body instead of trusting the status code.

Related integrations

Connect Microsoft Dynamics 365 Business Central and Marketo

Free to use. Add your credentials, ping your real systems, and see if we fit.

Get started