Modules
Elixir implementation of the Machine Payments Protocol (MPP).
Parse, format, and rank the Accept-Payment client-preference header.
Amount and decimal helpers for converting human-readable amounts to base units.
SHA-256 body digest computation and verification.
Payment challenge — the 402 response that tells a client what to pay.
Gates Accept-Payment header injection on outgoing HTTP requests.
Wraps multiple payment providers and dispatches to the first match.
Behaviour for client-side payment providers.
Behaviour for client-side transports that bridge a protocol response/request pair and the MPP payment flow.
HTTP implementation of MPP.Client.Transport over Req.
Shared base64url→JSON token decoding for the wire-format modules
(MPP.Credential, MPP.Receipt, MPP.Methods.Tempo.SessionReceipt).
Payment credential — the client's response to a 402 challenge.
Decentralized identifier (DID) helpers for MPP credential sources.
Demo payment method — accepts a magic token for local testing.
Demo router for mix mpp.demo — serves a protected endpoint behind MPP.
RFC 9457 Problem Details for MPP payment errors.
Expiration timestamp helpers for MPP challenges.
Parse and format the three MPP protocol wire-format headers.
Small internal hex-string helpers shared across the payment-method and wire-format modules.
Charge intent request schema — the "Intent = Schema" half of MPP.
RFC 8785 JSON Canonicalization Scheme (JCS) — MPP subset.
MCP (Model Context Protocol) payment transport helpers.
Behaviour for pluggable payment method verification.
Generic EVM payment method — verifies on-chain ERC-20 or native ETH transfers.
Verification helpers shared by the payment-method modules
(MPP.Methods.EVM, MPP.Methods.Tempo, MPP.Methods.Stripe).
Stripe payment method — verifies payment via Stripe PaymentIntent with SPT.
Tempo payment method — verifies payment via on-chain TIP-20 token transfer.
Sponsor (fee-payer) gas-economics policy for Tempo transactions.
Hosted Tempo fee-payer JSON-RPC fill support.
EIP-712 proof credentials for zero-amount Tempo charge flows.
Session-intent receipt for Tempo — returned in the Payment-Receipt header
for session/pay-as-you-go payments.
Plug middleware implementing the MPP 402 payment handshake.
Validated configuration for MPP.Plug.
Per-method configuration within a multi-method endpoint.
Payment receipt — proof-of-payment returned in the Payment-Receipt header.
Server-side payment observability via standard :telemetry events.
Built-in ETS-based dedup store using ConCache (TTL-enabled ETS wrapper by Saša Jurić).
Behaviour for transaction dedup stores used by MPP.Methods.Tempo.
Transport-neutral payment credential verification.
Mix Tasks
Starts a local HTTP server demonstrating the full MPP 402 payment flow.
Generates a static api_manifest.json from the library's descripex annotations.