TokenPay DevelopersMerchant Dashboard

Quickstart

Create your first TokenPay payment in under five minutes. All you need is a test API key and curl.

1. Get a test API key

Sign in to the Merchant Dashboard and open Settings → API Keys. Create a key with the test scope. Test keys are prefixed tp_test_.

2. Create a payment

Post to /v1/payments with an order ID, amount, and currency. The response includes a hosted checkout_url you can redirect the customer to.

curl https://api.tokenpayment.io/v1/payments \
  -H "Authorization: Bearer tp_test_..." \
  -H "Content-Type: application/json" \
  -d '{
    "amount": "10.00",
    "currency": "AUD",
    "order_id": "order_001",
    "return_url": "https://example.com/thanks"
  }'

3. Redirect to checkout

Redirect the customer's browser to the checkout_url returned in the response. When they complete payment, TokenPay redirects them back to your return_url.

4. Receive a webhook

TokenPay posts a signed payment.completed event to your configured webhook URL once funds settle. See Webhooks for signature verification and the full event catalog.

5. Verify in the dashboard

The payment appears instantly in the Merchant Dashboard under Payments. Drill in to see trade legs, escrow state, and settlement history.

Next steps