Treat every integration as a trust boundary
CRM, payment, identity, analytics and trading systems often have different data permissions and uptime characteristics. Use explicit scopes, authenticated service identities, TLS, secret rotation and network restrictions appropriate to each connection.
Design for duplicate and delayed messages
Retries are essential but can create duplicate work when the original request succeeded and the response was lost. Use idempotency keys where supported, validate state transitions, and make reconciliation possible without exposing client secrets.
- Separate development and production credentials
- Store secrets outside source-controlled files
- Validate payloads and allow-list accepted fields
- Apply least privilege and rotate keys
- Log event IDs without leaking sensitive payloads
- Set timeouts, bounded retries and clear failure states
Keep a recoverable audit trail
Record who initiated consequential actions, which service acted, the target record, the outcome and a correlation ID. Logs should be access-controlled and retained according to the organization’s policies.
Good integration security is not one extra layer. It is a consistent way to limit trust, detect failures and recover without guessing.




