Skip to content

Merchant API — Overview ​

The Merchant API lets your backend server interact with DPT programmatically using an API key instead of a user session. Use it to accept payments, manage withdrawals, issue cards, and build reseller platforms.

Base URLs ​

EnvironmentBase URL
Productionhttps://api.dpt.xyz
Testhttps://api-test.dpt.xyz

Use the test environment for development and integration testing — it runs against a sandbox with no real funds. Switch to production when you're ready to go live.

Authentication ​

Every request must include your API key in the Authorization header:

http
Authorization: Bearer dptb_your_api_key_here

API keys are scoped to a single business. You do not need to pass a business ID in the URL — it is derived from the key itself.

Getting an API Key ​

  1. Go to Dashboard → API Keys
  2. Click New Key, give it a name
  3. Copy the key from the confirmation banner, or click View on any key to retrieve it later

Keys are prefixed with dptb_. Store them securely (environment variables, secret managers). Never commit keys to source control.

Revoking a Key ​

From the dashboard, navigate to API Keys and click the revoke button next to any key. Revocation takes effect immediately.

Request Format ​

  • All request bodies must be JSON
  • Set Content-Type: application/json on requests with a body
http
POST /v1/checkouts HTTP/1.1
Authorization: Bearer dptb_...
Content-Type: application/json

{ "title": "Order #1234", "amount": 10000, "currency": "USDC" }

Response Format ​

All responses are JSON. Successful responses return the created or fetched resource directly. Errors return:

json
{
  "error": "Human-readable error message"
}

HTTP Status Codes ​

CodeMeaning
200Success with body
204Success, no body (DELETE, some POST)
400Bad request — check your parameters
401Missing or invalid API key
403API key does not have access to the resource
404Resource not found
422Validation error
500Server error

Amounts and Currencies ​

All monetary amounts are in the smallest unit of the currency:

  • USDC / USDT: amounts are in micro-units (1 USDC = 1,000,000)
  • USD (fiat): amounts are in cents (1 USD = 100)

Currency codes follow ISO 4217 for fiat and ticker symbols for crypto (e.g. USDC, USDT, ETH).

Rate Limits ​

  • 1000 requests per minute per API key
  • 10 concurrent requests per API key

Exceeding limits returns 429 Too Many Requests.

Available Resource Groups ​

DocResources
CheckoutsPayment links, refunds
Static AddressesPermanent deposit addresses for any-amount crypto receive
WithdrawalsSend funds to an on-chain address
ResellerCreate payments on behalf of other merchants, commission splits
WebhooksEvent delivery and security
API KeysKey management

DPT Merchant API