Who can spend
Bind the mandate to one approved agent public key. Owner updates, pauses, and revocation remain wallet-signed actions.
create_mandate →One MCP endpoint for policy enforcement, wallet authorization, routing, stablecoin settlement, and receipts. Solana is the first settlement layer; connectors keep the agent interface consistent.
/mcpPoint any MCP-compatible agent at the hosted endpoint. Tool discovery is automatic, and the HTTP transport never receives a seed phrase or private key.
{
"mcpServers": {
"chainpay": {
"url": "https://chainpay-mcp.onrender.com/mcp"
}
}
}
Use ChainPay to inspect the protocol config, then quote a payment for this demo invoice without executing it.Keep payment decisions inspectable. Preflight first, sign only in the wallet boundary, then submit and observe the receipt.
Read the mandate, protocol config, and asset registry.
Ask for a policy result without signing or submitting.
Build a mandate-checked transaction plan.
Relay a wallet-signed transaction through the backend.
Wait for status and fetch the durable receipt.
{
"mandate": "MANDATE_PDA",
"agent": "AGENT_PUBLIC_KEY",
"invoiceHash": "32_BYTE_HEX_HASH",
"paymentId": "32_BYTE_HEX_PAYMENT_ID",
"signatureReference": "32_BYTE_HEX_REFERENCE",
"mint": "TOKEN_MINT",
"recipient": "RECIPIENT_TOKEN_ACCOUNT",
"amount": "1000000",
"tokenProgram": "spl-token"
}quote_payment while the agent is deciding. It returns the policy preflight result but does not sign, submit, or move funds.ChainPay exposes one connector boundary for agents. x402 is connected to the same payment interface, so a paid API challenge becomes a mandate-checked Solana transaction without a second agent integration.
A paid resource returns an x402 exact challenge with asset, recipient, amount, nonce, resource, and optional expiry.
prepare_x402_payment accepts Solana Devnet and the exact scheme, then derives deterministic payment references.
ChainPay checks the mandate, mint, token program, supplied recipient, limits, expiry, and available policy authority.
An external wallet or signer reviews the prepared transaction. MCP never receives a seed phrase or private key.
Pass the wallet-signed transaction back to the connector for idempotent Rust backend relay and receipt tracking.
Call execute_x402_payment with the resource, mandate PDA, and approved-agent public key. The first call fetches and validates the live 402 challenge and returns an unsigned transaction. After an external signer approves it, call execute_x402_payment again with signedTransaction; ChainPay verifies finality and the receipt before retrying the resource.
/v1/paymentsIt is not a key custodian or hosted facilitator.Stablecoin payments use the same mandate and receipt model whether the asset is classic SPL Token or Token-2022. A mandate limits the agent, mint, amount, and time; each payment supplies one recipient and settles only to that destination.
Set the stablecoin mint and choose spl-token or token-2022.
Bind the source account, approved agent, per-payment and total limits. The recipient is supplied with each payment request.
Use quote_payment or prepare_payment before any signature is requested.
The program enforces the mandate and transfers through the selected token program. The SDK capability scan admits only extension combinations supported by the current transparent transfer path.
Read the receipt PDA and backend status to give the agent and merchant durable proof.
For standard SPL stablecoins and tokens. Every mint and token account must belong to the classic Token program.
spl-tokenFor enabled registry mints whose live mint, source, and recipient capability scan is compatible. Active hooks, non-zero fees, confidential-only transfers, and unknown transfer-affecting extensions fail closed.
token-2022Select a scenario to open its complete flow. Each sequence keeps the agent, ChainPay MCP, connector, wallet, Solana settlement, and receipt boundary visible.
The assistant retrieves the invoice, asks ChainPay for a policy quote, requests wallet approval, settles the approved amount, and returns a receipt.
The payroll agent creates the payment batch, while ChainPay enforces the payroll wallet, supplied destinations, batch limits, and required approval workflow.
The machine does not implement wallet, token-account, or settlement logic. Its application calls the same ChainPay MCP interface used by every other agent.
The support agent routes the refund through ChainPay instead of integrating directly with Stripe or custom blockchain code, keeping the refund inside an approved policy.
Treasury rules decide which wallets can move funds, how much can move per day, which approvals are required, and whether the request is inside business hours.
The shopping agent retrieves the invoice and calls ChainPay. The connector resolves the merchant payment path while ChainPay handles policy, approval, settlement, and proof.
The manager finds invoices and presents only renewals covered by the approved policy. Cancellation is a separate merchant action; ChainPay executes only the payments that pass policy.
Checkout calls ChainPay MCP instead of embedding custom Solana payment logic. The merchant receives a consistent request, settlement, and receipt path.
The platform’s agent prepares payouts worldwide through ChainPay, keeping limits, supplied destinations, token choice, and receipts consistent across the platform.
The DAO agent checks governance state first. ChainPay settles only when the proposal condition, contributor list, treasury mandate, and spending policy are satisfied.
ChainPay turns an owner-approved mandate into a narrow spending boundary enforced by the on-chain program.
Bind the mandate to one approved agent public key. Owner updates, pauses, and revocation remain wallet-signed actions.
create_mandate →Lock the allowed mint and require every payment request to provide one destination. The transfer settles only to the supplied recipient.
prepare_payment →Set per-payment and total limits, expiry, payment count, and cooldown slots to make agent spending predictable.
update_mandate →ChainPay supports classic SPL Token and Token-2022 settlement, with explicit program selection so an agent cannot accidentally mix account types.
Set tokenProgram to spl-token. The mint, source account, and destination account must belong to the classic Token program.
Register a Token-2022 mint, then ChainPay verifies its program identity and scans the live mint and token-account extensions before every prepared payment. Unsupported transfer behavior is rejected until a tested adapter exists.
Read protocol config →The catalog below is generated from the same definitions returned by MCP tools/list. Required fields are shown to make orchestration easier.
list_mandates
MCP tool
Discover all ChainPay mandates owned by a wallet and report their live status, limits, and token-account delegation.
ownerfind_compatible_mandate
MCP tool
Find an active mandate compatible with an invoice mint, amount, token program, and optional approved agent.
ownermintamountget_mandate
MCP tool
Read an on-chain ChainPay payment mandate and its current status.
addressget_protocol_config
MCP tool
Read the ChainPay protocol configuration and bootstrap asset list.
noneget_asset
MCP tool
Read whether a mint is enabled in the ChainPay asset registry.
mintget_supported_assets
MCP tool
List every mint in the scalable on-chain SupportedAsset registry, including enabled state and exact token program.
nonequote_payment_request
MCP tool
Verify a merchant-signed request, derive deterministic payment references, and quote it against a mandate without signing or submitting.
requestmandateagentcreate_demo_payment_request
MCP tool
Create a valid, merchant-signed Devnet demo payment request using a real token account.
nonecreate_mandate
MCP tool
Prepare a wallet-signed spending mandate. Each payment supplies its own recipient.
ownerapprovedAgentsourceTokenAccountallowedMintmaxPerPaymenttotalLimitexpiresAtSlottokenProgramupdate_mandate
MCP tool
Prepare an owner-signed update to a mandate's agent, limits, expiry, and cooldown policy.
ownerapprovedAgentmaxPerPaymenttotalLimitexpiresAtSlotmaxPaymentCountcooldownSlotscheck_payment_requirements
MCP tool
Check whether a payment has the token, recipient, amount, expiry, mandate limits, and policy details needed to proceed. Ask the user for missing details before quoting or settling.
noneprepare_payment
MCP tool
Validate a payment request against the on-chain mandate and prepare a transaction for the approved agent signer.
mandateagentinvoiceHashpaymentIdsignatureReferencemintrecipientamountexecute_payment
MCP tool
Settle through an explicitly selected human or delegated signing path. Delegated mode uses the mandate-bound provider signer through Axum.
mandateagentinvoiceHashpaymentIdsignatureReferencemintrecipientamountsigningModequote_payment
MCP tool
Return a policy quote and preflight result without signing or submitting a transaction.
mandateagentinvoiceHashpaymentIdsignatureReferencemintrecipientamountverify_payment_request
MCP tool
Verify a merchant-signed payment request before ChainPay settlement.
requestprepare_x402_payment
MCP tool
Normalize a Solana x402 challenge and prepare a mandate-checked payment transaction.
challengemandateagentexecute_x402_payment
MCP tool
Run the live x402 GET/402 flow, prepare an externally signed ChainPay settlement, verify its receipt, and retry the resource with proof.
resourcemandateagentsigningModeget_payment
MCP tool
Fetch a ChainPay receipt PDA and join it with Axum's persisted transaction signature.
nonewait_for_payment
MCP tool
Poll the Rust backend until a relayed payment is confirmed or failed.
paymentIdpause_mandate
MCP tool
Prepare an owner-signed transaction that pauses a ChainPay mandate.
ownerrevoke_mandate
MCP tool
Prepare an owner-signed transaction that permanently revokes a ChainPay mandate.
ownerUse the MCP transport for agents and the read-only routes for humans, health checks, and integration discovery.
/Developer documentation preview
POST/mcpStreamable HTTP JSON-RPC MCP transport
GET/toolsRead-only tool definitions and input schemas
GET/healthzRender health check and service status
GET/logo.svgChainPay brand mark used by this documentation
GET/og-image.pngRaster social preview image for link unfurlers