onyx_verify_explain
Diagnose a failing x402 v2 /verify. Decodes a captured X-PAYMENT header, runs 10 rules (decode, schema, network/asset/payTo match, value sufficiency, EIP-3009 timing, signature shape, scheme) against expected paymentRequirements, and returns the FIRST failing rule with a plain-English fix. Catches the common case where the facilitator returns bare HTTP 402 (no body) because of JWT or schema fail upstream of the verifier. Stdlib-only, no install, no network. (price: $0 USDC, tier: free)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| now_unix | No | Override current unix time for replay/CI use. Defaults to now. | |
| x_payment_b64 | No | Base64-encoded X-PAYMENT (v2 PAYMENT-SIGNATURE) header value. Optional if payment_payload provided. | |
| payment_payload | No | Decoded payment payload dict. Use this OR x_payment_b64. | |
| payment_requirements | Yes | Expected paymentRequirements from the 402 challenge ({scheme, network, payTo, asset, maxAmountRequired, maxTimeoutSeconds, ...}). |