Sync with Waxpeer session to auto-fill API key

Rent Tron energy for an address

POST/v1/payment/tron-energy/rent

Rents Tron energy for the specified address, deducting the cost from the user's balance. The cost is determined by the current TRX price and the amount of energy required (5 TRX for 65000 energy or 10 TRX for 131000 energy).

Parameters

NameLocationTypeDescription
api
required
querystring

Request body

NameLocationTypeDescription
address
required
bodystring

Tron wallet address

Example
{
  "address": "TJnmJPpsbmfaLPmkxWz5EXKxUCtzdGSvcT"
}

Responses

200 Successful operation

NameTypeDescription
success
optional
boolean

Whether the operation succeeded

address
optional
string

Tron wallet address

total_cost
optional
number

Total cost debited in integer cents

msg
optional
string

Reason message when success is false

Response
{
  "success": true,
  "address": "TJnmJPpsbmfaLPmkxWz5EXKxUCtzdGSvcT",
  "total_cost": 1170,
  "msg": "Successfully rented Tron energy for 1.17 USD (5 TRX)"
}