← All resources

How to design CRM, ERP and API integrations that stay reliable

A practical guide to integration projects: data ownership, contracts, states, retries, failure handling, security and launch order.

An integration moves data between owners

Decide who owns each object before choosing the transport.

01SourceCreates and owns the current state
02ContractFields, identifiers and change rules
03ExchangeAPI, event, schedule or queue
04ControlRetries, reconciliation, logs and alerts

Complexity is not the number of URLs

One endpoint can be more critical than ten simple calls when money or orders depend on it.

01DataDifferent dictionaries, formats and owners
02ReliabilityDelay, retries, downtime and event order
03OwnershipWho fixes drift and sees the incident

Start with data ownership

Assign a source of truth for each object: customer, contract, order, inventory, payment or document. Two owners for one field will eventually produce conflicting states.

Draw objects and transitions, not only a list of integrations. This map is useful to business, analysts and engineers.

A data contract matters more than an endpoint name

Define fields, formats, identifiers, statuses, deletion and missing values. Ask what happens when a record arrives twice or a provider adds a field.

Provider documentation rarely covers every business limitation. Request sandbox access, real examples and an owner on the other side.

Design failure before the happy path

An external service can time out, return incomplete data or deliver events out of order. Use timeouts, bounded retries, logs and a visible “needs review” state.

Payments and orders need idempotency. A repeated notification must not create a second charge or order.

Avoid a chain of direct calls

A synchronous request that calls CRM, warehouse, payment and delivery can make every delay visible to the user. Separate critical actions from secondary updates and model intermediate states.

This does not mean every project needs a complex message bus. Choose API, events or queues from actual requirements for order, speed and recovery.

Security belongs in the contract

Document personal data, credentials, access revocation and audit requirements. Never put secrets or sensitive payloads into application logs.

Agree on API versions and backward compatibility so a provider update cannot silently break a purchase or document flow.

Launch the critical path first

Close one journey end to end: request to CRM, or order to payment and inventory reservation. Add secondary exchanges after that path is observable.

Acceptance tests should include downtime, duplicates, delays and manual recovery, not only successful responses.

A contract describes more than a successful JSON sample

Define object ownership, state transitions, identifiers and event order before integration. Document required fields, time zones, money precision, encoding, limits and schema versions. This is cheaper than explaining a data mismatch after launch.

Add timeout, partial-response, retry and incompatible-change examples for every endpoint. The contract should be testable and useful to the operator handling an incident.

Synchronization needs an operation log

Long exchanges should not be one blocking HTTP request. Use a queue, operation status, correlation ID and safe retries. An idempotency key prevents duplicates when a provider accepted a write but the response was lost.

Store attempt results and failure reasons separately from the business object. This allows one failed step to be retried without creating a second order, payment or document.

Observability is part of integration design

Metrics should answer business questions: how many operations are stuck, how long sync takes and which objects need manual correction. Logs without an operation ID cannot connect requests across services.

Before launch, test rate limits, unavailable endpoints and schema changes. The result should include a recovery plan, not only a green integration test.

The contract must describe errors

A successful response is only half of an integration. Record error codes, field requirements, idempotency, limits and retry rules. Client and server must agree whether a request is safe to repeat.

Assign an owner to every provider contract and a way to detect changes. Versioning and sandbox environments cost less than emergency recovery after an incompatible API update.

Synchronization needs an explicit state model

Integrations are often asynchronous: a request is created locally, processed by a partner and confirmed later. Store external IDs, current status, last attempt and failure reason so the chain can be recovered without searching through messages.

Define the source of truth and reconciliation rules before systems diverge. Last-write-wins is unsafe for money, inventory or permissions.

Limit the change surface first

Do not connect every provider capability. Select operations required by the core journey and test them with real-shaped data, timeouts and retries. Add other methods only after their value is confirmed.

Acceptance must include observability: correlation IDs, latency metrics, redacted error logs and a manual recovery path. The integration then becomes a product capability instead of a fragile script.

Treat the API contract as a product interface

Define required fields, states, error codes, idempotency and acceptable latency for every method. A client needs to know whether a request can be retried safely; support needs an operation identifier.

Version contracts predictably. Compatibility windows cost less than coordinating urgent changes across several systems on release day.

An integration is ready after failure testing

Test timeouts, retries, partial success and recovery when a partner is unavailable. A queue without deduplication can create duplicate orders; endless retries turn a temporary issue into permanent load.

Assign an owner and a manual recovery path for exceptions. Operators should see it in their workspace, not only in developer logs.