The 101pay API is a JSON REST API. All requests and responses use application/json. Base URL:
https://api-production-4983.up.railway.app
The API accepts three credential types depending on the endpoint:
A public key (pk_test_…) and a private key (sk_test_…), generated in Key management. A transaction only settles when the two keys form a matched pair. The pair is passed in the request body.
Obtain a token from POST /v1/auth/login and send it as Authorization: Bearer <token>. Used for checkout-session creation, key management, the transaction statement, KYC and payment methods.
Shown once at signup (ap_test_…). Sent as Authorization: Bearer <apiKey> for GET /v1/payments.
POST /v1/auth/register).Settle a transaction with a key pair. No header auth — the pair travels in the body.
/v1/transactions/chargepublicKey — string, requiredprivateKey — string, requiredamount — decimal string, required (e.g. "9.99")currency — USDC · USDT · JPY · USD (default USDC)description — string, optionalcurl -X POST https://api-production-4983.up.railway.app/v1/transactions/charge \
-H "content-type: application/json" \
-d '{
"publicKey": "pk_test_…",
"privateKey": "sk_test_…",
"amount": "9.99",
"currency": "USD",
"description":"order #1024"
}'{
"orderNo": "20260517000000042",
"transaction": "0x…",
"amount": "999",
"currency": "USD",
"status": "settled"
}A mismatched pair returns 401 key_pair_invalid. amount is echoed back in minor units (see Reference).
Create a checkout session, then send the customer to the hosted url. The customer picks a crypto method (USDC, BTC, ETH, …) and pays via a requires_action → confirm flow on the hosted page.
/v1/checkout/sessions · Bearer JWTcurl -X POST https://api-production-4983.up.railway.app/v1/checkout/sessions \
-H "authorization: Bearer <JWT>" \
-H "content-type: application/json" \
-d '{ "amount":"1500", "currency":"JPY", "description":"Pro plan" }'
# → { "session": { "id": "…", "status": "open", … }, "url": "https://…/checkout/<id>" }/v1/checkout/sessions/:id · public — poll the session status/v1/checkout/sessions/:id/pay/intent · public — body { method } → payment instructions/v1/checkout/sessions/:id/pay/confirm · public — body { paymentId } → settlementIn production the confirm step is driven by the payment provider's webhook; the hosted page handles this for you.
Accept USDT on the TRON network (TRC20). The platform is non-custodial — funds settle straight into your own receiving address.
In the dashboard, open Receiving accounts and add your USDT-TRC20 address. Every USDT payment for your account settles there.
Your server calls the endpoint below with your Client ID and a secret key — one of the private keys from the Keys page. A mismatch returns 401.
/v1/paymentsclientId your 15-digit Client IDsecret a key-pair private key (sk_test_…)amount decimal string, e.g. "1.00"currency invoice currency — USDC · USDTmethod payment rail — usdtcurl -X POST https://api-production-4983.up.railway.app/v1/payments \
-H "content-type: application/json" \
-d '{
"clientId": "101000000000000",
"secret": "sk_test_…",
"amount": "1.00",
"currency": "USDT",
"method": "usdt"
}'The response returns cryptoPayLink — the hosted-checkout URL you send your customer to.
{
"success": true,
"payment": { "id": "…", "status": "open", "amount": "1.00", "currency": "USDT", "method": "usdt" },
"cryptoPayLink": "https://…/en/checkout/<id>"
}The customer opens cryptoPayLink, chooses USDT, and is shown your receiving address and the exact amount. The order is marked paid once the on-chain transfer is confirmed via TronGrid.
The amount carries a unique sub-cent suffix so each payment can be matched on-chain. The customer must transfer exactly that amount and keep the checkout page open until it confirms.
Price any resource with the x402 protocol so AI agents can pay per request.
/v1/resource/:sku?merchant=<merchantId>Without an X-PAYMENT header the endpoint answers 402 with PaymentRequirements. The agent signs an EIP-3009 authorization and retries with the X-PAYMENT header; the facilitator verifies and settles, and the resource is returned. Payment history: GET /v1/payments (merchant API key).
USDC — 6 decimals · USD — 2 decimals · JPY — 0 decimalsusdc · btc · eth · usdt · bnb · sol · ada · xrp · doge · dotEvery transaction gets a unique 17-digit order number: 8 digits of the transaction date (YYYYMMDD) + a 9-digit sequence — e.g. 20260517000000042.
Errors return a JSON body and a matching HTTP status:
{ "error": "key_pair_invalid", "message": "the public key and private key do not form a valid pair" }400 invalid_request · 401 unauthorized · 402 payment_rejected404 not_found · 409 conflict · 500 internal_errorThese docs are visible to signed-in merchants only.