Quickstart
1. Get credentials
After your merchant account is opened, the platform provides:
| Credential | Purpose |
|---|---|
| API key + API secret | Sign API requests. The secret is shown only once — store it safely. Create keys per scope (read / deposit / withdraw) and bind an IP allowlist |
| Webhook URL + webhook secret | We sign every event we push to your URL with the webhook secret; verify it on your side |
Base URL: https://api.dtpg.net
2. Your first request
List supported chains. Every request carries 4 signature headers — see Authentication; ready-made code is in Code examples.
bash
# 1. Your credentials
API_KEY="your-api-key"
API_SECRET="your-api-secret"
# 2. This request
METHOD="GET"
URI_PATH="/v1/chains"
QUERY="" # canonical query string; empty if none
BODY="" # request body; empty for GET
TIMESTAMP=$(( $(date +%s) * 1000 )) # now, Unix milliseconds
NONCE=$(openssl rand -hex 16) # 32-char random string
# 3. String to sign: 6 parts joined by newlines
BODY_HASH=$(printf '%s' "$BODY" | openssl dgst -sha256 | awk '{print $NF}')
STRING_TO_SIGN=$(printf '%s\n%s\n%s\n%s\n%s\n%s' \
"$METHOD" "$URI_PATH" "$QUERY" "$TIMESTAMP" "$NONCE" "$BODY_HASH")
# 4. Signature = hex(HMAC-SHA256(API secret, string to sign))
SIGNATURE=$(printf '%s' "$STRING_TO_SIGN" | openssl dgst -sha256 -hmac "$API_SECRET" | awk '{print $NF}')
# 5. Send it
curl "https://api.dtpg.net${URI_PATH}" \
-H "X-Api-Key: $API_KEY" \
-H "X-Timestamp: $TIMESTAMP" \
-H "X-Nonce: $NONCE" \
-H "X-Signature: $SIGNATURE"json
{ "chains": [{ "code": "TRON", "name": "TRON" }] }3. Typical integration
- Assign a deposit address:
POST /v1/wallets/{user_id}/addresses(idempotent — safe to call before every display). - Wait for the
deposit.confirmedwebhook: dedupe byevent_id, then credit the user. Missed one? Backfill withGET /v1/events. - Create a withdrawal:
POST /v1/withdrawswith your own order number asbiz_id(idempotency key). - Track it: webhooks
withdraw.broadcasted→withdraw.confirmed(orwithdraw.failed/withdraw.rejected), or pollGET /v1/withdraws/{withdraw_id}.
For AI / coding assistants
Give /llms-full.txt or /openapi.yaml to your AI assistant and it can write the integration for you. Every page also has a "Copy as Markdown" button under its title.