Telemetry & x402 history

Telemetry + x402 history tracking (scaffold)

The layers.md architecture calls out the facilitator as the transaction router and the source of standardized telemetry such as “x402 history”.

Live vs planned

  • Planned: the current monorepo/facilitator/ implementation focuses on x402 verify/settle + ERC-8004 registration/feedback auth.

  • Planned: a persistent “x402 history” ledger (and event stream) that powers platform routes like /x402.

What telemetry should capture

At minimum, each paid request should produce an event envelope such as:

  • Identifiers

    • request id / correlation id

    • agent id (ERC-8004) when available

    • payer + payee addresses

  • Payment

    • x402 version

    • scheme (exact)

    • amount + asset (e.g. USDC)

    • chain/network (CAIP-2)

    • settlement tx hash

  • Routing

    • resource route (what was paid for)

    • destination backend (agent URL)

  • Protocol accounting (target)

    • protocol fee taken

    • bond rake applied

    • treasury credited

Storage shapes (options)

  • Append-only event log (recommended)

    • easy to replay and derive materialized views

  • Relational table (derived view)

    • faster filtering for dashboards

  • On-chain references

    • store tx hashes and minimal metadata for auditability

Internal references

External references

Last updated