API surface. Invoices (read, pay, dispute, export), payment methods, payments, balances and usage reporting are REST. Invoice authoring and import, reconciliation, meters, price plans, billing profiles, refunds and payouts are GraphQL Interface.Money moves in three directions in logistics, and most systems tangle them together:
All three end in the same place: an invoice that is paid through a payment provider. The spec defines invoices, usage and reconciliation as its own objects, and reaches Stripe, Adyen, PayPal, card networks (through acquirers) and bank rails (ACH, SEPA, Faster Payments) through a
payments interface (chapter 26). Swapping providers changes a connection, not a data model.
1. Invoice
One object for every invoice, whichever direction it flows.
Endpoints:
Import and export formats
Injection billing. A receiving network (3PL, carrier, network) bills each injecting partner (chapter 18 §6) with a
transport invoice whose lines reference the injected shipments by injection.upstream_reference. It exports in ubl or json. The partner imports it, and lines are matched to its own shipments by upstream reference, so both sides reconcile the same identifiers.
2. Reconciliation
Carrier invoices rarely match what was quoted. Reconciliation matches every line against the platform’s own records and classifies the differences.- Rules (
reconciliation_rule_set,rset_) set tolerances ({ absolute: 50, percent: 0.02 }), per-cause actions, and rebill policy (rebill_to: "merchant", withmarkuporat_cost). rebillappends aChargewithkind: "adjustment"to the shipment’spurchase.charges(shipment.charges_adjustedfires), and adds a usage or adjustment line to the merchant’s next invoice. This is how platforms pass carrier reweighs through without spreadsheets.disputefiles the dispute through the carrier connection when the integration supportslsp.billing_disputes, and otherwise records it for manual filing. Evidence can cite data network records: dimension scans from devices, the void confirmation, delivery attestations.type: "usage_vs_invoice"reconciles a platform’s usage (§4) against an LSP’s invoice. Labels the platform purchased for an account are matched against what the carrier billed that account, so both sides agree on volume.
3. Billing profiles
billingProfile (GraphQL Interface query) and updateBillingProfile (GraphQL Interface mutation) act on the current account. Platforms manage children’s profiles with Shipping-Account.
collectionischarge_automatically(charge the default payment method when the invoice finalizes) orsend_invoice(the account pays bydue_on).payments_connectionchooses which payments provider collects for this account (§6).
4. Usage metering and price plans
Meters
sourceis{ event }(an event type, chapter 08 §2) or{ reported: true }(usage reported through the API).aggregationiscount,sum(ofvalue_path, e.g.purchase.amount.amountfor value-based fees, orquantity),max(peak storage), orunique(distinctvalue_pathvalues, such as active trackers).- Built-in meters:
storage.pallet_days,fulfillment.picksand the other inventory meters (chapter 29 §7),labels.purchased,labels.voided,rates.requested,trackers.active,address_validations.completed,documents.generated,device_events.ingested,records.stored,coverages.premium. Platforms add their own.
Usage records
labels.voided can be a negative-priced meter).
Price plans
model is per_unit, graduated (each tier priced separately), volume (the reached tier prices every unit), package ({ size, amount }), or percentage (of a summed money meter). Unit amounts are in the currency’s minor units and may be fractional (0.5 cents per tracker) for high-volume meters, rounded at invoice time.
At the end of each billing_profile.cycle, the implementer runs a billing.cycle job (chapter 27) that aggregates usage, applies plans, and finalizes a usage invoice per account. Platforms preview the upcoming invoice with GET /v1/invoices/upcoming.
5. Prepaid balances
Many carriers and platforms run on prepaid postage: labels are debited from a balance that is topped up by card or bank transfer.balance_transaction (btx_) types are top_up, label_charge, label_refund (on a successful void), adjustment (rebilled reweighs), coverage_premium, fee, and payout. A purchase that would take the available balance below zero fails with 402 billing_error / insufficient_balance, unless auto_top_up succeeds first.
6. Payments interface
payments is an integration interface (chapter 26). Providers include Stripe, Adyen, PayPal, Checkout.com, and bank rails. Card networks such as Visa and Mastercard are reached through an acquirer or processor, never directly.
- Card and bank details are collected only in the provider’s own hosted fields or pages (Stripe Elements, Adyen Drop-in, and similar), using the
setupresponse. Spec implementers MUST NOT receive, store or transmit primary account numbers. This keeps implementers outside PCI DSS cardholder-data scope. - Domain objects (
invoice,usage_record,balance,settlement) never reference provider objects directly. Onlypayment,payment_method,refundandpayoutcarry provider references, incarrier_metadata(the namespace for any external provider’s data). - Provider webhooks enter through the inbound receiver of the payments connection (
POST /v1/inbound/{connection_id}, chapter 08 §6), and updatepaymentstatus. Domain events (invoice.paid) follow from that. - Bank statement reconciliation accepts ISO 20022
camt.053statements (POST /v1/payments/reconcile_statement { file }), matching remittances to invoices forsend_invoicecollection. - Switching provider means adding a connection and re-collecting payment methods through the new provider’s setup. Invoices, usage, balances and history are unchanged.
7. Events
invoice.created, invoice.finalized, invoice.sent, invoice.paid, invoice.partially_paid, invoice.overdue, invoice.disputed, invoice.voided, invoice.imported, reconciliation.completed, reconciliation.line_resolved, usage_record.created, billing.cycle_completed, balance.low, balance.topped_up, payment_method.attached, payment.succeeded, payment.failed, payment.requires_action, refund.created, payout.paid, payout.failed.