Saltar al contenido principal
POST
/
api
/
v1
/
energy
/
buy
Comprar energia
curl --request POST \
  --url https://api.example.com/api/v1/energy/buy \
  --header 'Content-Type: application/json' \
  --data '
{
  "target_address": "<string>",
  "volume": 123,
  "duration": "<string>"
}
'
{
  "id": 123,
  "status": "<string>",
  "txid": {},
  "price_trx": "<string>",
  "reclaim_at": {},
  "activation_cost_trx": "<string>"
}

Comprar energia

Delega energia a la direccion TRON especificada. El costo se deduce del saldo de tu cuenta.

Cuerpo de la solicitud

target_address
string
requerido
Direccion TRON de destino (formato T…, 34 caracteres)
volume
number
requerido
Cantidad de energia a delegar (min 32,000, max 5,000,000)
duration
string
requerido
Duración del alquiler: "1h" (1 hora) o "1d" (1 día, solo bandwidth)

Respuesta

id
number
Unique order identifier
status
string
Order status: pending, filled, failed
txid
string | null
On-chain transaction id once the delegation is broadcast (null while pending)
price_trx
string
Total cost charged from your balance, in TRX
reclaim_at
string | null
ISO 8601 timestamp when the bandwidth rental is reclaimed (energy is reclaimed automatically by the provider)
activation_cost_trx
string
Address activation cost in TRX ("0" if the recipient is already activated)

Ejemplo

curl -X POST https://api.tronrental.com/v1/energy/buy \
  -H "X-API-Key: your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "target_address": "TYourRecipientAddress1234567890abc",
    "volume": 65000,
    "duration": "1h"
  }'
Response
{
  "id": 12345,
  "price_trx": "2.75",
  "status": "pending"
}
65,000 de energia cubre una transferencia USDT a una direccion que ya posee USDT. Usa 131,000 para destinatarios que reciben USDT por primera vez (creacion de nuevo slot de almacenamiento).