Tron API En
Chinese API
  • Basic information
  • Tron API
    • Get related configuration
    • Pre-order
    • create trx engerg order
    • create usdt engerg order
    • create bandwidth order
    • upload purchase order hash
    • create a sell order
    • Earn energy by stake
    • recovered energy
    • cancel order
    • query purchase order
    • query recent finished order
    • query purchase order records by user address
    • query sell order records by user address
  • Seller Tron API
    • Get seller configuration
    • Seller authorization
    • Update seller configuration
    • Get seller panel
  • Buyer Tron API
    • Get buyer configuration
    • Buyer charge
    • Buyer withdraw
    • Buyer leas energy
    • Buyer leas energy records
    • Buyer asset records
  • FAQ
    • Error Code
Powered by GitBook
On this page
  • Endpoint usage
  • code example
  • Postman example
  1. Buyer Tron API

Buyer leas energy records

Endpoint usage

POST https://open.tronify.io/api/tronRent/user/userAssetRecord

The fields with * are required, and the fields without * are optional

Headers

Name
Type
Description

api-key*

String

Access the buyer management platform of tronify.io to obtain it.

Request Body

Name
Type
Description

address*

String

User address (Wallet address)

sourceFlag*

String

Source channel (Both sides need to agree on a name to represent the channel of the third parties)

pledgeAddress

String

Search by pledgeAddress

orderId

String

Search by orderId

orderType*

String

0: Completed. 1: In progress. Other values: All

type*

String

Fixed value: user

pageSize*

String

page size

page*

String

page num

endTime

String

Search by endTime (YYYY-MM-DD HH:mm:ss)

startTime

String

Search by startTime (YYYY-MM-DD HH:mm:ss)

{
    "resCode": 100,
    "resMsg": "Success",
    "data": {
        "data": [
            {
                "orderId": "kuawcag6_hg5w_jsbe_tg1w_bcrzjl42glb1",
                "fromAddress": "TW7XuicuiQSHCcodUkyjMfdWxnWsbZmiSS",
                "pledgeAddress": "TBuPND7n66qNf3AbYNJA458duuV3ZyWtUk",
                "platformAddress": "",
                "pledgeNum": 32000,
                "trxNum": "3.68",
                "orderPrice": "115",
                "freeAmt": null,
                "orderType": "ENERGY",
                "pledgeDay": "0",
                "pledgeHour": "1",
                "orderStatus": "complete",
                "createTime": "2023-06-20 15:02:49",
                "pledgeTime": "2023-06-20 15:04:01",
                "finishTime": "2023-06-20 16:04:01"
            }
        ],
        "pagination": {
            "page": 1,
            "pageSize": 10,
            "total": 4
        }
    }
}

code example

// example
const params = {
    address: "TW7XuicuiQSHCcodUkyjMfdWxnWsbZmiSS",
    page: 1,
    pageSize: 10,
    code: "g7WNPfO1156",
    type: "user",
    orderType: "2",
    orderId: "",
    pledgeAddress: "",
    startTime: "2023-06-21",
    endTime: "2023-06-22",
    sourceFlag: "path"
}
const headers = {
  'api-key': 'your-api-key'
};
 const res = await axios.post('https://open.tronify.io/api/tronRent/user/userAssetRecord',params, { headers })
 console.log(res)
 if(res.resCode === '100'){
   //...  
 }

Postman example

PreviousBuyer leas energyNextBuyer asset records

Last updated 1 year ago