curl --request POST \
--url https://tron-mainnet.core.chainstack.com/95e61622bf6a8af293978377718e3b77/wallet/exchangecreate \
--header 'Content-Type: application/json' \
--data '
{
"owner_address": "<string>",
"first_token_id": "<string>",
"first_token_balance": 123,
"second_token_id": "<string>",
"second_token_balance": 123,
"permission_id": 123,
"visible": false
}
'{
"txID": "<string>",
"raw_data": {
"contract": [
{
"parameter": {
"value": {
"owner_address": "<string>",
"first_token_id": "<string>",
"first_token_balance": "<string>",
"second_token_id": "<string>",
"second_token_balance": "<string>"
},
"type_url": "<string>"
},
"type": "<string>"
}
],
"ref_block_bytes": "<string>",
"ref_block_hash": "<string>",
"expiration": 123,
"timestamp": 123
},
"raw_data_hex": "<string>"
}Creates a new trading pair on the TRON decentralized exchange with initial liquidity provision
curl --request POST \
--url https://tron-mainnet.core.chainstack.com/95e61622bf6a8af293978377718e3b77/wallet/exchangecreate \
--header 'Content-Type: application/json' \
--data '
{
"owner_address": "<string>",
"first_token_id": "<string>",
"first_token_balance": 123,
"second_token_id": "<string>",
"second_token_balance": 123,
"permission_id": 123,
"visible": false
}
'{
"txID": "<string>",
"raw_data": {
"contract": [
{
"parameter": {
"value": {
"owner_address": "<string>",
"first_token_id": "<string>",
"first_token_balance": "<string>",
"second_token_id": "<string>",
"second_token_balance": "<string>"
},
"type_url": "<string>"
},
"type": "<string>"
}
],
"ref_block_bytes": "<string>",
"ref_block_hash": "<string>",
"expiration": 123,
"timestamp": 123
},
"raw_data_hex": "<string>"
}owner_address — the address that will own and control the exchange pair (base58 with visible: true, or hex with visible: false).first_token_id — TRC10 token ID of the first token in the trading pair.first_token_balance — initial amount for the first token as an integer (token base units).second_token_id — TRC10 token ID of the second token; use _ to denote TRX.second_token_balance — initial amount for the second token as an integer (if TRX, specify in sun).permission_id — optional permission ID for multi‑signature accounts.txID — unique transaction identifierraw_data — raw transaction data including contract detailsraw_data_hex — hexadecimal representation of raw transaction datawallet/exchangecreate method is used for:
curl --request POST \
--url 'https://tron-mainnet.core.chainstack.com/95e61622bf6a8af293978377718e3b77/wallet/exchangecreate' \
--header 'Content-Type: application/json' \
--data '{
"owner_address": "TLyqzVGLV1srkB7dToTAEqgDSfPtXRJZYH",
"first_token_id": "1000001",
"first_token_balance": 1000000000000,
"second_token_id": "_",
"second_token_balance": 5000000000,
"visible": true
}'
_), provide second_token_balance in sun (1 TRX = 1,000,000 sun)._ for TRX or a TRC10 token ID string for both sides to create TRC10–TRC10 pairs.The address that will own and control the exchange pair
Token ID of the first token in the trading pair
Initial balance to provide for the first token (integer amount in the token's base units)
Token ID of the second token in the trading pair. Use '_' to denote TRX.
Initial balance to provide for the second token (integer amount; if TRX, specify in sun)
Optional permission ID for multi-signature accounts
Whether to return human-readable addresses
Successful response with transaction details
Unique transaction identifier
Raw transaction data including contract details
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Hexadecimal representation of raw transaction data
Was this page helpful?