Skip to content

x402 Micropayments (furlpay x402) ​

Autonomous machine-to-machine micropayments over the HTTP 402 Payment Required protocol, with EIP-712 cryptographic authorization and a TigerBeetle-style double-entry netting model.

Honesty label

There is no live TigerBeetle connection in this build — settlement runs as a clearly-labeled local simulation. Every response says SIMULATED / LOCAL_SIMULATION, and simulated tx ids carry the furlpay_simnet_ prefix. The MCP tool furlpay_settle_invoice is labeled identically.

Settle a challenge ​

bash
furlpay x402 pay \
  --challenge-header 'WWW-Authenticate: x402 recipient="GBLX99API", amount="0.0005", token="USDC"' \
  --max-cost 0.005

Replay protection ​

Consumed payment nonces are tracked in a file-locked atomic ledger under ~/.furlpay/ — not an in-memory Set. A signed EIP-712 payment authorization replayed in a later CLI invocation is rejected: nonce state survives process restarts.

Agent gatekeeping ​

When an MCP agent settles a challenge, the agent policy gate fires before settlement: read-validate-record under the policy lock, so concurrent tool calls cannot both pass against a stale spend snapshot. With no policy on disk the settlement stays in simulation mode — it never moves value. Note the MCP default: furlpay_settle_invoice is a value-moving tool, so it is structurally absent from tools/list until --enable-execution + a configured policy, and even then it runs through the two-phase preview→confirm protocol (readiness P7).

The netting model ​

The engine models debits, credits and pending transfers with deterministic, microsecond-order semantics — the same double-entry discipline the facilitator would enforce against a live TigerBeetle cluster. What is simulated here is the ledger transport, not the accounting: netting arithmetic is real integer math.

Live enablement path ​

Wiring a live facilitator means replacing the simulated settlement sink with an authenticated facilitator endpoint; the challenge parser, nonce ledger and netting math stay as-is. Until then, every response is labeled simulated — the CLI never prints a settlement it did not perform.

FurlPay CLI is non-custodial software. Every execution surface is labeled live or simulated at runtime.