Wired Pipeline

case study 02 · CRM integration

Every phone call logged into two CRMs, in under a second

Asterisk PBXSuiteCRM 7Odoo 17PythonREST + OAuth2XML-RPC

The problem

A sales team ran two systems that never talked. The phone system knew every call. The CRM knew every customer. Reps retyped call notes from memory at the end of the day, or didn't, and pipeline reports quietly became fiction. This version was harder: two different CRMs had to stay in sync from one phone system, with different APIs, different logins and different phone number formats.

What we did

  • Built a service that listens to the PBX call records over a read-only account, so it can see calls but never place them
  • Wrote to each CRM through its own API, never its database, so workflows, hooks and audit trails still fire
  • Matched numbers across formats: (813) 555-0142, 813.555.0142 and 18135550142 all find the same customer
  • Made it safe under failure: a call is claimed before any CRM is touched, so restarts never file it twice, and failed writes retry instead of vanishing
Architecture: Asterisk to bridge to SuiteCRM and Odoo
One phone system, two CRMs, no manual entry. Five steps between a hangup and a logged activity.
Live service log showing one call written to both CRMs
The live run. A real call, written to both CRMs, and the duplicate record for the same call skipped. Numbers and names are blurred.
SuiteCRM Calls list with activities created by the bridge
SuiteCRM's Calls list. Every row here was created by the bridge, attached to the right contact, lead or account.
Phone number normalization code
Three formats collapse into one match key. This is the part most integrations get wrong.
Ledger showing calls processed and zero errors
The ledger that keeps it honest: every call claimed once, every write counted.
✓ call in both CRMs 0.5 seconds after hangup (measured from the service log)
✓ verification run: 6 calls, 6 CRM activities, 0 duplicates, 0 errors
✓ inbound, outbound, answered, missed and voicemail all classified correctly
✓ 24 unit tests, named after the bugs they pin
# customer records in the demo are fictional (555-01xx range) and blurred anyway.

Two systems that should agree, but don't?

Phones, CRM, email, forms, invoicing. The pieces here are the same pieces behind any serious integration.