🚀 CRM ↔ ERP Real-Time Integration Framework

 

🚀 CRM ↔ ERP Real-Time Integration Framework


Sharing a simple and reliable pattern to implement bi-directional synchronization between Microsoft Dynamics CRM and an ERP system using Azure Service Bus.




CRM ↔ ERP architecture diagram



Note: This approach is majorly for integrating dynamics CRM with non-Microsoft ERP system as we have OOB dual write approach to integrate with Microsoft ERP system.


CRM → ERP

  • Whenever a real CRM user updates an Account or Contact, a plugin sends the change as a JSON payload to Azure Service Bus.
  • A corresponding Integration Log entry is also created in CRM, capturing the status, source, and payload.
  • The ERP system reads the message, updates its records, and then calls Dynamics via API to mark the Integration Log entry as Success.


✅ ERP → CRM

  • Any time the ERP updates an Account or Contact, it pushes a JSON payload to the ERP-CRM queue.
  • Dynamics picks up the message, creates Integration Log record with a Pending status, updates the CRM record, and then marks the Integration Log as Success.


Preventing Infinite Loops


To avoid circular updates, both systems check who made the change.

If the update originates from the integration user, the system does not send the message to the queue ensuring a clean, loop-free sync. this is because, integration user will be the user used in azure functions to update CRM-ERP bidirectional updates



Comments

Popular posts from this blog

Accessing Fields on QuickView Form through javaScript

Custom Subgrid Using HTML Web resource

Check Dirty Fields or Forms in Dynamics 365