Skip to content

confirmed flag gates payment, but the receipt still isn't independently checkable after the fact #3

Description

@giskard09

The confirmed parameter on x402_get_and_pay (when REQUIRE_CONFIRM=true) is a real, useful pre-execution gate — the tool returns a payment preview and won't sign until called again with confirmed: true. That's a genuinely stronger story than most agent-payment tools have.

What's still open: once the payment happens, the only record of what was requested, confirmed, and paid is the MCP response and whatever the host app's own logs retain — the receipt parsed from the v2 PAYMENT-RESPONSE header (success, transaction, network, payer) isn't independently checkable by a third party (an auditor, a counterparty, a user whose vault moved funds) without trusting that log. And since REQUIRE_CONFIRM defaults to false, the confirmation step itself is opt-in — whether it exists for a given call depends on deployment config, which makes a post-execution record more useful, not less.

Worked example, applying a public spec (no changes asked of this repo): https://github.com/giskard09/fireblocks-action-ref-anchor

It derives action_ref — a content-addressed id from {agent_id, action_type, scope, timestamp} (JCS RFC 8785 + SHA-256, argentum-core/action-ref-v1) — for a synthetic x402_get_and_pay call shaped exactly per this repo's own inputSchema (url, confirmed, ...) and the receipt shape this repo's own code parses (src/HttpX402Service.ts), then anchors it permissionlessly on Base mainnet (tx in the repo, independently verifiable, no owner/roles on the registry). The envelope anchors params + confirmed-flag + receipt as three separately recomputable digests, so the confirmation step itself (when configured on) is part of what's checkable, not just the payment.

To be explicit about what this is: a worked example against your public source, not a claim that x402-agent does or should implement this, and not an ask for any change here.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions