The Tron Payment Gateway API allows you to accept cryptocurrency payments (TRX and USDT TRC-20) through a simple RESTful interface. This documentation covers all available endpoints, authentication, request/response formats, and error handling.
All API requests must include your API key for authentication. You can provide it in two ways:
All API responses follow a consistent JSON format:
Code | HTTP Status | Description |
---|---|---|
VALIDATION_ERROR | 422 | Invalid input data |
PAYMENT_NOT_FOUND | 404 | Payment not found |
PARTNER_ERROR | 400 | Partner-related error |
WALLET_ERROR | 400 | Wallet-related error |
API_LIMIT_EXCEEDED | 503 | API rate limit exceeded |
INSUFFICIENT_WALLETS | 400 | No available wallets |
PAYMENT_NOT_COMPLETED | 400 | Payment not in completed status |
Parameter | Type | Required | Description |
---|---|---|---|
transaction_id | string | Yes | Unique identifier for this payment (max 255 chars) |
asset | string | Yes | Cryptocurrency type: TRX or USDT |
amount_usd | decimal | Yes | Amount in USD (0.01 - 999999.99) |
postback_url | string | No | URL for payment notifications (max 500 chars) |
Parameter | Type | Description |
---|---|---|
page | integer | Page number (default: 1) |
limit | integer | Items per page (1-100, default: 50) |
status | string | pending, completed, expired, failed |
asset | string | TRX or USDT |
Parameter | Type | Required | Description |
---|---|---|---|
address | string | Yes | TRON wallet address (34 characters, starts with T) |
Parameter | Type | Required | Description |
---|---|---|---|
is_active | boolean | Yes | Wallet active status |
Status | Description |
---|---|
pending | Waiting for payment |
completed | Payment received and confirmed |
expired | Payment expired (30 minutes timeout) |
failed | Payment failed |
When a payment is completed, the system will send a POST request to your postback URL: