TronBid

TronBid Quick Rent API

B2B REST API for automated TRON Energy rental. Buy energy for USDT TRC-20 transfers programmatically β€” on-chain or from your TronBid balance.

On this page

Overview: what it is and who it's for

The Quick Rent API is a way to rent TRON Energy automatically, with no manual work. Energy makes USDT (TRC-20) transfers and other smart-contract calls cheaper than burning TRX.

In plain words: your program (a site, bot, or service) buys energy itself, exactly when it's needed β€” for example, before each USDT transfer your customer makes.

Think of a vending machine: you check the price, insert money, get your item. The API is the same set of buttons β€” only your program presses them.

  1. 1
    Ask for a price

    Your program asks the API how much the needed energy package costs right now.

  2. 2
    Create an order and pay

    Your program creates an order and pays it β€” by sending TRX to the given address or by charging your TronBid balance.

  3. 3
    Get the energy

    Within a few seconds energy appears on the target wallet, and USDT can be sent cheaper.

Important: the API is a tool for a developer. To use it, someone has to write code that sends the requests.

If there's no one to write code β€” use the ready-made energy purchase on the site (Quick Rent) or the Telegram bot @tronbid. Same result, just done manually.

Glossary

Short explanations of the words used in this documentation.

Energy
The "fuel" of the TRON network for smart-contract operations. If there isn't enough, the network burns TRX instead β€” which is more expensive. Renting energy saves money.
TRX
The native coin of the TRON network. It pays for energy rental and network fees.
USDT TRC-20
A stablecoin (dollar) on TRON. Sending it is a smart-contract call that needs energy.
API key
Your secret password for API access. Sent with every request. Keep it on the server only.
Endpoint
A specific address-"button" of the API where your program sends a request (e.g. /quote β€” get a price).
GET / POST
Request types. GET means "just ask / read data"; POST means "do an action" (create an order, calculate a price).
Bearer token
How you pass the API key: the header reads Authorization: Bearer YOUR_KEY.
On-chain payment
Paying an order with a plain TRX transfer to the given address β€” works right away, nothing to enable.
Balance payment
Paying by charging your TronBid account balance. Faster, but must be enabled for your key first.
Delegation
Temporarily handing the rented energy to the target wallet for the rental period (e.g. 15 or 60 minutes).
Polling
Re-asking the order status periodically (every couple of seconds) until it becomes delegated or ends with an error.
idempotency_key
Your unique order id. If a request is sent twice, the API returns the same order instead of creating a new one β€” protection against double payment.

Before you start

What to prepare before making your first request.

  1. 1
    Get an API key

    Message @tronbid on Telegram β€” you'll get a key bound to your TronBid account. Requests won't pass without it.

  2. 2
    Have a target TRON wallet

    Decide the address (target_address) that needs energy. Usually it's the wallet your customers send USDT from.

  3. 3
    Pick a package from the catalog

    Energy is sold in packages (usually 65000 or 131000 energy for 15 or 60 minutes). Get the live list from the catalog endpoint, no auth needed.

  4. 4
    Prepare payment

    For on-chain β€” a wallet with TRX to pay. For balance payment β€” a funded TronBid account and the balance mode enabled.

Introduction

The Quick Rent API lets your service rent TRON Energy automatically, so USDT TRC-20 transfers and other smart-contract calls cost less than burning TRX.

All endpoints share one base URL.

Base URL (production)
http
https://tronbid.com/api/v2/quick-rent

Authorization

Every request must include your API key as a Bearer token in the Authorization header.

Keep the key server-side only (backend, CI secrets). Never ship it in frontend code or public repositories. The key is bound to a single TronBid account (the wallet set when access was granted); balance payments can only draw from that account.

If you exceed the rate limit, the API responds with HTTP 429.

http
Authorization: Bearer <API_KEY>

Payment Modes

There are two ways to pay for an order. On-chain is the default and needs no setup. Balance payment is optional and must be enabled for your key.

Without activation, a request with payment_mode: balance returns 403 BALANCE_PAYMENT_NOT_ENABLED. To enable it, contact TronBid support.

ModeHow to enablePayment
on-chainDefault β€” omit payment_mode (or "onchain")Send TRX to pay_address from payer_address
balancepayment_mode: balance + enabled for your keyDebited from your TronBid TRX balance

Package Catalog

energy_amount and duration_minutes must match an active Quick Rent package β€” usually 65000 or 131000 energy and 15 or 60 minutes.

Fetch the current catalog any time (no auth required):

Get the active catalog (no auth)
bash
curl -sS https://tronbid.com/api/public/quick-rent/skus

Quickstart: from zero to energy

A full end-to-end example on the simplest scenario (on-chain). Four steps and energy is on the wallet.

Below is what happens at each step and what the API returns. Plug in your API key, addresses and order id.

  1. 1
    Step 1. Get a price β€” POST /quote

    Send the energy amount and duration. You get price_trx back and how many seconds it's locked for.

  2. 2
    Step 2. Create an order β€” POST /orders

    Send the package, your idempotency_key and payer_address. You get pay_address (where to pay), amount_trx (how much) and expires_at (until when).

  3. 3
    Step 3. Pay

    Send exactly amount_trx TRX to pay_address from your payer_address. It's a plain TRON transfer.

  4. 4
    Step 4. Wait for energy β€” GET /orders/:id

    Poll the status every couple of seconds until it becomes delegated. That means energy is delegated to the wallet β€” done.

Response
json
{
  "price_trx": "3.200000",
  "available": true,
  "save_percent": 62,
  "expires_in_sec": 30
}
Response (on-chain)
json
{
  "id": "uuid",
  "status": "pending_payment",
  "payment_mode": "onchain",
  "pay_address": "TDeposit...",
  "amount_trx": "3.200000",
  "energy_amount": 131000,
  "duration_minutes": 15,
  "expires_at": "2026-04-29T13:15:00.000Z",
  "qr_payload": "tron:TDeposit...?amount=3.200000",
  "duplicate": false,
  "target_address": "TTarget..."
}
cURL
bash
# poll every 3s until the order is done
while true; do
  STATUS=$(curl -sS "$BASE_URL/api/v2/quick-rent/orders/$ORDER_ID" \
    -H "Authorization: Bearer $API_KEY" | jq -r .status)
  echo "status: $STATUS"
  case "$STATUS" in
    delegated|failed|expired|cancelled) break ;;
  esac
  sleep 3
done
Response
json
{
  "id": "uuid",
  "status": "delegated",
  "payment_mode": "onchain",
  "amount_trx": "3.200000",
  "energy_amount": 131000,
  "effective_energy_amount": 131000,
  "duration_minutes": 15,
  "pay_address": "TDeposit...",
  "payer_address": "TPayer...",
  "target_address": "TTarget...",
  "error_code": null,
  "error_message": null
}

On-chain Flow

Step 1 β€” POST /quote to learn the price. Step 2 β€” POST /orders to create the order and receive pay_address, amount_trx and expires_at. Step 3 β€” send exactly amount_trx TRX to pay_address from your payer_address. Step 4 β€” poll GET /orders/:id until the status is delegated (or failed / expired / cancelled).

target_address is optional β€” if omitted, energy is delegated to payer_address.

Only one open on-chain order (pending_payment) is allowed per payer_address at a time; otherwise you get 409 PENDING_PAYMENT_INTENT_EXISTS. On under/overpayment the final energy may differ β€” check effective_energy_amount in GET /orders/:id.

Request body
json
{
  "energy_amount": 131000,
  "duration_minutes": 15,
  "idempotency_key": "your-unique-key-001",
  "payer_address": "TPayerWalletXXXXXXXXXXXXXXXXXXXXXX",
  "target_address": "TTargetWalletXXXXXXXXXXXXXXXXXXXXX"
}
Response
json
{
  "id": "uuid",
  "status": "pending_payment",
  "payment_mode": "onchain",
  "pay_address": "TDeposit...",
  "amount_trx": "3.200000",
  "energy_amount": 131000,
  "duration_minutes": 15,
  "expires_at": "2026-04-29T13:15:00.000Z",
  "qr_payload": "tron:TDeposit...?amount=3.200000",
  "duplicate": false,
  "target_address": "TTarget..."
}

Balance Flow

Step 1 β€” GET /balance to check your TRX. Step 2 β€” POST /quote for the price. Step 3 β€” POST /orders with payment_mode: balance to debit and start delegation. Step 4 β€” poll GET /orders/:id until delegated (on a delegation error it becomes failed and TRX is refunded to your balance).

payer_address is not needed β€” the account linked to your API key pays. The energy_amount in the response can be higher than the ordered SKU (price-matrix bonus).

Request body
json
{
  "energy_amount": 131000,
  "duration_minutes": 15,
  "idempotency_key": "your-unique-key-balance-001",
  "payment_mode": "balance",
  "target_address": "TTargetWalletXXXXXXXXXXXXXXXXXXXXX"
}
Response
json
{
  "id": "uuid",
  "status": "delegating",
  "payment_mode": "balance",
  "pay_address": null,
  "amount_trx": "3.200000",
  "energy_amount": 132310,
  "duration_minutes": 15,
  "expires_at": null,
  "qr_payload": null,
  "duplicate": false,
  "target_address": "TTarget..."
}

Order Statuses

Every order moves through these statuses. Poll GET /orders/:id to follow it.

StatusMeaning
pending_paymentWaiting for on-chain payment
delegatingPayment received or balance charged; delegation in progress
delegatedEnergy delegated
cancelledCancelled before payment (on-chain)
expiredOn-chain payment window elapsed
failedError (for balance, TRX is refunded)

Idempotency

idempotency_key (8–128 chars) is a unique order id on your side. Repeating POST /orders with the same key (for the same API client) returns the same order with "duplicate": true.

Do not reuse one idempotency_key across different payment modes (onchain vs balance) β€” that returns 409 IDEMPOTENCY_PAYMENT_MODE_MISMATCH.

Calculator

Estimate how much energy an address needs for a transfer. Pass the recipient wallet and whether it already holds USDT.

POST/api/v2/quick-rent/calculator

Parameters

ParameterTypeDescriptionExample
wallet_addressstringTRON address to analyzeTXXXXXXXX...XXXX
has_usdtboolean | nullWhether the recipient already holds USDT (affects energy). true, false, or omit.true
Request body
json
{
  "wallet_address": "TXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
  "has_usdt": true
}
cURL
bash
curl -sS -X POST "$BASE_URL/api/v2/quick-rent/calculator" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"wallet_address":"TXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX","has_usdt":true}'

Get Quote

Returns the current price for a package: price_trx, availability, save_percent and how long the quote is valid (expires_in_sec).

POST/api/v2/quick-rent/quote

Parameters

ParameterTypeDescriptionExample
energy_amountintEnergy amount from the active catalog131000
duration_minutesintRental duration from the catalog15
Response
json
{
  "price_trx": "3.200000",
  "available": true,
  "save_percent": 62,
  "expires_in_sec": 30
}
cURL
bash
export BASE_URL="https://tronbid.com"
export API_KEY="your_api_key"

curl -sS -X POST "$BASE_URL/api/v2/quick-rent/quote" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"energy_amount":131000,"duration_minutes":15}'

Create Order

Creates a rental order. For on-chain, pass payer_address and pay the returned amount_trx to pay_address. For balance, add payment_mode: balance and the linked account is charged immediately.

target_address is optional (defaults to payer_address). Mind the 409 rules: one open on-chain order per payer, and no active Quick Rent delegation already on the target (ACTIVE_DELEGATION_EXISTS).

POST/api/v2/quick-rent/orders

Parameters

ParameterTypeDescriptionExample
energy_amountintEnergy amount from the catalog131000
duration_minutesintRental duration from the catalog15
idempotency_keystringYour unique order id (8–128 chars)partner-onchain-001
payment_modestringOptional. "onchain" (default) or "balance".balance
payer_addressstringOn-chain: wallet that sends TRX. Not needed for balance.TPayer...
target_addressstringOptional. Wallet that receives energy (defaults to payer_address).TTarget...
Response (on-chain)
json
{
  "id": "uuid",
  "status": "pending_payment",
  "payment_mode": "onchain",
  "pay_address": "TDeposit...",
  "amount_trx": "3.200000",
  "energy_amount": 131000,
  "duration_minutes": 15,
  "expires_at": "2026-04-29T13:15:00.000Z",
  "qr_payload": "tron:TDeposit...?amount=3.200000",
  "duplicate": false,
  "target_address": "TTarget..."
}
Response (balance)
json
{
  "id": "uuid",
  "status": "delegating",
  "payment_mode": "balance",
  "pay_address": null,
  "amount_trx": "3.200000",
  "energy_amount": 132310,
  "duration_minutes": 15,
  "expires_at": null,
  "qr_payload": null,
  "duplicate": false,
  "target_address": "TTarget..."
}
cURL (on-chain)
bash
curl -sS -X POST "$BASE_URL/api/v2/quick-rent/orders" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "energy_amount": 131000,
    "duration_minutes": 15,
    "idempotency_key": "partner-onchain-001",
    "payer_address": "TPayer...",
    "target_address": "TTarget..."
  }'
cURL (balance)
bash
curl -sS -X POST "$BASE_URL/api/v2/quick-rent/orders" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "energy_amount": 131000,
    "duration_minutes": 15,
    "idempotency_key": "partner-balance-001",
    "payment_mode": "balance",
    "target_address": "TTarget..."
  }'

Get Order Status

Returns the current status, payment_mode, amounts, addresses, and error_code / error_message if something failed. effective_energy_amount reflects the actual delegated energy after under/overpayment.

GET/api/v2/quick-rent/orders/:id

Parameters

ParameterTypeDescriptionExample
idstringOrder id (path parameter)uuid
Response
json
{
  "id": "uuid",
  "status": "delegated",
  "payment_mode": "onchain",
  "amount_trx": "3.200000",
  "energy_amount": 131000,
  "effective_energy_amount": 131000,
  "duration_minutes": 15,
  "pay_address": "TDeposit...",
  "payer_address": "TPayer...",
  "target_address": "TTarget...",
  "error_code": null,
  "error_message": null
}
cURL
bash
curl -sS "$BASE_URL/api/v2/quick-rent/orders/$ORDER_ID" \
  -H "Authorization: Bearer $API_KEY"

Cancel Order

Cancels an order that is still pending_payment (on-chain only). Once energy has been delegated, the order can no longer be cancelled.

POST/api/v2/quick-rent/orders/:id/cancel

Parameters

ParameterTypeDescriptionExample
idstringOrder id (path parameter)uuid
cURL
bash
curl -sS -X POST "$BASE_URL/api/v2/quick-rent/orders/$ORDER_ID/cancel" \
  -H "Authorization: Bearer $API_KEY"

Change Payer

Changes the paying wallet for a pending_payment on-chain order β€” useful if the customer decides to pay from a different wallet before sending TRX.

POST/api/v2/quick-rent/orders/:id/set-payer

Parameters

ParameterTypeDescriptionExample
idstringOrder id (path parameter)uuid
payer_addressstringNew paying walletTNewPayer...
cURL
bash
curl -sS -X POST "$BASE_URL/api/v2/quick-rent/orders/$ORDER_ID/set-payer" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"payer_address":"TNewPayer..."}'

Get Balance

Returns the TRX balance of the TronBid account linked to your API key (your in-app balance, not an on-chain wallet). Requires the Authorization header.

GET/api/v2/quick-rent/balance
Response
json
{ "balance_trx": "150.500000" }
cURL
bash
curl -sS "$BASE_URL/api/v2/quick-rent/balance" \
  -H "Authorization: Bearer $API_KEY"

Error Codes

Errors return an HTTP status and an error field. Here are the ones you may encounter.

HTTPerrorWhen
400Invalid bodyInvalid JSON or fields
400INVALID_SKU / SKU_INACTIVEPackage unavailable
400INVALID_PAYER_ADDRESS / INVALID_TARGET_ADDRESSMalformed TRON address
400TARGET_ACCOUNT_NOT_ACTIVATEDEnergy recipient wallet is not activated on TRON (no TRX received yet)
503TRON_ACCOUNT_CHECK_FAILEDCould not verify account status on TRON β€” try again later
400INSUFFICIENT_BALANCENot enough TRX on balance (balance mode)
401UnauthorizedMissing or invalid API key
403BALANCE_PAYMENT_NOT_ENABLEDBalance payment not enabled for your key
409PENDING_PAYMENT_INTENT_EXISTSAn open on-chain order already exists for this payer
409ACTIVE_DELEGATION_EXISTSTarget already has an active Quick Rent delegation
409POOL_ENERGY_INSUFFICIENTNo free pool energy right now
409IDEMPOTENCY_PAYMENT_MODE_MISMATCHSame idempotency_key with a different payment_mode
429Too Many RequestsRate limit
503β€”Service temporarily unavailable, retry later

If something goes wrong

Common situations and what to do, in plain words.

I paid but the order is stuck in pending_payment

Make sure the transferred amount exactly equals amount_trx and the funds went to pay_address from the exact payer_address. The transfer must arrive before expires_at. The status usually updates within a minute after network confirmation β€” keep polling GET /orders/:id.

The status became failed β€” what is it?

Delegation didn't succeed. For balance payments the TRX is automatically returned to your balance. The reason is in error_code and error_message of GET /orders/:id. You can create a new order.

Error 409 PENDING_PAYMENT_INTENT_EXISTS

This payer_address already has an unpaid on-chain order. Pay it, wait for it to expire (expires_at), or cancel it via /orders/:id/cancel, then create a new one.

Error 403 BALANCE_PAYMENT_NOT_ENABLED

Balance payment isn't enabled for your key. Contact TronBid support to activate it, or use on-chain (the default).

Error 429 Too Many Requests

Too many requests in a short time. Lower the polling frequency (e.g. once every 3 seconds) and retry later.

I got less energy than I ordered

With underpayment/overpayment on-chain the final amount changes. Check effective_energy_amount in GET /orders/:id β€” that's the energy actually delegated.

Support

Need API access, higher limits, or balance payment enabled? Reach out and we'll help.

API access & balance paymentTelegram @tronbid