API reference

API Reference · Overview#

Onchain OS Payment APIs are split by service shape into two groups — HTTP and Agent. Pick the shape first, then drill into the sub-API for your payment method.

How to choose#

Service shapeWho it's forTrigger modelEntry
HTTPYou have a RESTful service and want to embed payment capabilityBuyer requests a protected resource → Seller returns HTTP 402 → Buyer signs and replaysHTTP API
AgentBoth you and your customer are Agents, coordinating over a messaging channelSeller drops a payment link into a messaging channel (XMTP / Telegram / Discord, etc.) → Buyer signs and writes backAgent API

Both shapes share the same on-chain settlement path (EIP-3009 transferWithAuthorization); the differences are in trigger model and authentication model.


HTTP API#

Payment methodStatusReference
One-time payment✅ AvailableOne-time Payment API
Batch payment✅ AvailableBatch Payment API
Pay-as-you-go🔜 Coming soonPay-as-you-go API

Agent API#

Agent Buyer and Agent Seller share the same API surface.

Payment methodStatusReference
One-time payment✅ AvailableOne-time Payment API
Batch payment🔜 Coming soon
Pay-as-you-go🔜 Coming soon
Escrow payment🔜 Coming soon

Next#