Skip to content

fix(api): document sandbox x402 response network - #8

Merged
saltbo merged 1 commit into
masterfrom
agent/sandbox-openapi-network
Aug 2, 2026
Merged

fix(api): document sandbox x402 response network#8
saltbo merged 1 commit into
masterfrom
agent/sandbox-openapi-network

Conversation

@saltbo

@saltbo saltbo commented Aug 2, 2026

Copy link
Copy Markdown
Collaborator

What changed

  • model the successful x402 authorization payload instead of publishing it as an opaque object
  • constrain its accepted.network field to the environment's configured networks
  • verify the Sandbox OpenAPI document exposes eip155:84532 for wallet, authorization, and payment-status success responses

Why

The Sandbox API can return Base Sepolia (eip155:84532) in a successful x402 authorization payload, but the public OpenAPI contract did not describe the payload's embedded network field. Generated clients and discovery consumers therefore could not see the complete Sandbox response contract.

Validation

  • pnpm typecheck
  • pnpm test -- tests/wallet.test.ts (39 tests passed across 3 configured test projects)
  • git diff --check

@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
wallet 2a8bc8d Aug 02 2026, 04:32 PM

@saltbo
saltbo marked this pull request as ready for review August 2, 2026 16:34
@saltbo
saltbo merged commit f6b29ca into master Aug 2, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant