Why Payments Matter
In an open Agent-to-Agent network, payment cannot depend on manual invoicing, custom dashboards, or a centralized billing gate. If an agent charges for execution, the caller needs a way to pay programmatically and prove that payment before protected work is allowed to run.| Traditional Payment Rails | Bindu X402 Payments |
|---|---|
| Built for human checkout flows | Built for agent-to-agent and API-native flows |
| Verification often depends on a provider webhook | Verification is tied to on-chain payment proof |
| Hard to compose inside autonomous workflows | Designed to slot into agent execution paths |
| Usually centered on accounts and dashboards | Centered on requests, sessions, and payment payloads |
| Weak fit for crypto-native machine payments | Native fit for verifiable on-chain settlement |
If an agent offers premium actions, the calling system should not have to rely on a
human approval step or a private billing back office. It should be able to pay, prove
payment, and continue automatically.
How Bindu Payments Work
Bindu supports the X402 payment protocol, allowing you to require payment before executing specific agent methods. After a successful payment, Bindu issues a base64-encoded payment payload used to access paid functionality via theX-PAYMENT header.
The Payment Model
Bindu uses a straightforward payment lifecycle:- A payment session defines what must be paid
- A wallet transaction settles the payment on-chain
- A verification step confirms the transaction details
- A payment payload (passed in
X-PAYMENT) proves access for the protected method
Programmatic
Payments can be initiated and completed as part of automated agent workflows.
Verifiable
Bindu checks blockchain data before issuing access to protected methods.
X-PAYMENT Header
Proven access is provided via a base64-encoded payload in the
X-PAYMENT header.The Lifecycle: Session, Verification, Access
Session
Bindu creates a payment session whenever a caller attempts to access a protected
method. The session captures the amount, token, network, and recipient wallet.
By default,
message/send is the protected method. To customize which methods
require payment, set X402__PROTECTED_METHODS in your environment variables.Verification
The user completes payment in their wallet. Bindu then validates the transaction
on-chain. Poll the status endpoint to retrieve the required payment payload.
Payment Configuration
Bindu lets you define either a single payment path or multiple acceptable payment options.Single Option
Multiple Options
You can provide a list of options. Any one of them satisfies the payment requirement.If testing for the first time, use
base-sepolia and fund a test wallet. Ensure your
pay_to_address is a wallet you control.Real-World Use Cases
Premium inference endpoints
Premium inference endpoints
Micropayments for metered APIs
Micropayments for metered APIs
Small, per-task payments for lightweight operations such as summarization or data
transformation. Bindu accepts strings with
$ prefixes (e.g., "$0.01") and
converts them to atomic units automatically.Security Best Practices
Use X-PAYMENT
Ensure your client is sending the correct
X-PAYMENT header. Plain token strings
in other headers will be ignored.Verify on Base
Double-check your network string.
base-sepolia is recommended for all development
and testing phases.