Skip to main content
TRON API method that retrieves the current market price for a specific TRC10↔TRC10 trading pair on the TRON DEX.
Get you own node endpoint todayStart for free and get your app to production levels immediately. No credit card required.You can sign up with your GitHub, X, Google, or Microsoft account.

Parameters

  • sell_token_id — TRC10 token ID being sold, as a numeric string (for example, “1000006”).
  • buy_token_id — TRC10 token ID being purchased, as a numeric string.
  • visible — optional boolean. Some node builds require visible: true.

Response

  • sell_token_id — token ID being sold
  • buy_token_id — token ID being purchased
  • prices — array of recent price points containing:
    • sell_token_quantity — quantity of sell token
    • buy_token_quantity — quantity of buy token
    • timestamp — when this price point was recorded

Use case

The wallet/getmarketpricebypair method is used for:
  • Getting current market rates for trading pair price calculations.
  • Building price tracking and charting applications for TRON DEX.
  • Implementing automated trading strategies based on market prices.
  • Displaying real-time pricing information in trading interfaces.
  • Analyzing price trends and market volatility for specific token pairs.

curl example

Shell
curl --request POST \
  --url 'https://tron-mainnet.core.chainstack.com/95e61622bf6a8af293978377718e3b77/wallet/getmarketpricebypair' \
  --header 'Content-Type: application/json' \
  --data '{
    "sell_token_id": "1000006",
    "buy_token_id": "1000001",
    "visible": true
  }'