Create invoice
create_invoiceCreate a payment request and get a hosted payment page URL to send to customers; set a USD price or fixed TRX/USDT amount with idempotent order IDs.
Instructions
Create a payment request and get a hosted payment page (payment_url) to send to the customer. Either price_usd (customer picks TRX or USDT, rate locked) or token + amount (fixed coin amount). Minimum 10 USD. Use order_id to make it idempotent and to find it later.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| token | No | Fixed coin, used with amount. | |
| amount | No | Amount in the fixed coin, e.g. "100". | |
| tokens | No | Coins the customer may pick for a USD invoice (default: all). | |
| metadata | No | Free-form data returned in webhooks (max 4 KB). | |
| order_id | No | Your order reference; the same order_id returns the existing invoice. | |
| price_usd | No | Price in US dollars, e.g. "49.90". The customer chooses the coin. | |
| description | No | Shown to the customer on the payment page. | |
| success_url | No | Where the customer goes after paying. | |
| expires_in_minutes | No | How long the invoice stays open (default set by the account, max 24 h). |