Which provider actually delivered this

Every send writes a row naming the provider that carried it, its provider message id, the outcome, and the billable units.

What it is

A fire-and-forget send_log write records channel, org, recipient, subject, status (sent/failed/skipped), provider key, provider id and error. Billing quantity is recorded as SMS segments rather than message count. The provider id is the join key that later delivery events (Mailgun opens, clicks, bounces) attach to.

Also called: send log · delivery attribution · who sent it · message audit

See it
Which provider actually delivered this
Area
Integrations
Group
Provider architecture
System
Provider Independence
Solves
2 named problems
01The port facade calls logSend after the chain resolves.
02The row carries provider and provider_id so an event webhook can find the tenant that owns the message.
03units is the billable quantity — SMS segments, from lib/smsSegments.
A send_log table view with a Provider column showing mixed twilio/ghl rows for the same account, and a provider id column. Sample data — no customer information appears here.
How it works
  1. 1The port facade calls logSend after the chain resolves.
  2. 2The row carries provider and provider_id so an event webhook can find the tenant that owns the message.
  3. 3units is the billable quantity — SMS segments, from lib/smsSegments.
  4. 4Logging never blocks or fails a send.
Why we built it

The comment on the billing field states the specific loss: 'units is the billable quantity — SMS segments, not messages. Counting rows under-bills every text over 160 characters (or 70, if it contains a single emoji), and the platform silently absorbs the difference.' The attribution half exists because with a fallback chain, 'which provider sent it' stops being knowable from configuration alone.

The problem
  • With fallbacks in play, configuration no longer tells you who delivered a message.
  • Counting messages instead of segments under-billed every long text.
Sound familiar?
What you get
Every send is traceable to a provider and a provider-side id.
Delivery events can be joined back to the right tenant.
Usage billing prices the real carrier unit.

See it on your own jobs

Twenty minutes, your numbers, no slide deck. We’ll build one of your real buildings in front of you and send you the estimate link at the end — yours to keep either way.

or keep browsing features →