Skip to main content
By the end of this guide, transfers out of your Tron wallets can be sponsored: a wallet that holds only USDT can send it, and the TRX for the fee comes from a gas station that keeps itself funded.

Before you start

  • A sandbox API key exported as PLATFORM_API_KEY.
  • A treasury wallet on Tron with some test TRX, to fund the gas station. Save its ID as TREASURY_WALLET_ID.
  • A sending wallet on Tron with test USDT and no TRX. Save its ID as WALLET_ID.
Create wallet and the quickstart cover creating wallets. A sandbox key works on Tron’s Nile testnet.
1

Create the gas station

Create gas station needs a name, a chain, and a threshold. Turn on auto-refill at the same time, so the station tops itself up from the treasury wallet.
Save the id as GAS_STATION_ID. The balance is zero, so health_status starts as low. threshold and refill_amount are in TRX. Don’t send network: it follows your API key.
2

Fund it

Refill it once by hand with Refill gas station, from the treasury wallet.
The response is the funding transaction. Once it completes, Get gas station shows health_status as healthy.
3

Estimate a sponsored transfer

Estimate transaction fee with sponsor: true shows what the gas station will pay.
4

Send it

Send the same body to Create transaction, with an Idempotency-Key.
The transaction passes through awaiting_sponsorship before broadcasting. When it completes, it has "sponsored": true and the gas_station_id that paid. The sending wallet’s TRX balance is still zero.If one of your policies holds the transaction, you get 202 instead. See Handle held and rejected transactions.
5

Alert before it runs dry

Subscribe to the gas station events with Create webhook:
  • gas_station.low_balance and gas_station.critical_balance: page whoever funds the treasury wallet.
  • gas_station.auto_refilled: log it, and watch how often it fires.
Auto-refill keeps the station topped up only while the treasury wallet has TRX. Alert on the treasury wallet’s balance too.

Sizing the threshold and refill

Size both from your volume, not from a guess:
  • threshold: enough for the transfers you send in the time it takes a refill to confirm, plus a margin. On a busy chain, a few hours of fees.
  • refill_amount: enough for about a day of fees. Too small and you refill constantly, paying a fee each time. Too large and you hold idle native balance in a hot account.
Review both after the first week, using the fees on your sponsored transactions and the number of auto_refilled events.

Change the configuration

Update gas station changes name, threshold, refill_amount, and auto_refill_enabled. Fields you leave out stay unchanged.

One per chain

Create a gas station for each chain you send sponsored transfers on. List gas stations with chain=tron shows the stations you have on a chain. The exchange integration guide shows a multi-chain setup.