Get simple price for a given input mint, output mint and amount

Retrieve simple price for any token pair

🚧

Price API v1 Deprecation Notice

Price API v1 will be deprecated on November 30, 2024.

Please migrate to Price V2 to ensure uninterrupted service.

  • More Info on Price V2: here
  • Get unit buy price for the token specified with the ids parameter.
  • The price is based on the best pricing data available across all DEXes queried.
  • vsToken is defaulted to USDC when left emptied.

Parameters:

  • ids (required, string): Supports symbol or address of a token. You can also pass in an array of ids with , as separator.
    • Address are case-sensitive
      • mSoLzYCxHdYgdzU16g5QSh3i5K3z3KZK7ytfqcJm7So
      • mSoLzYCxHdYgdzU16g5QSh3i5K3z3KZK7ytfqcJm7So,So11111111111111111111111111111111111111112
  • vsToken (string): Support symbol or address of a token.
    • Defaults to USDC
    • Symbol are case-sensitive
      • SOL, BTC, mSOL
    • Address is case-sensitive
      • EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v

Typings of response data

Field AttributeTypeDescription
idstringAddress of the token
mintSymbolstringSymbol of the token
vsTokenstringAddress of the VS token
vsTokenSymbolstringSymbol of the VS token
pricenumberDefault to 1 unit of the token worth in USDC if vsToken is not specified
timeTakennumberAPI internal compute response time

Example Response

# Unit price of 1 SOL based on the buy amount of USDC
https://api.jup.ag/price/v1?ids=SOL

{
  "data": {
    "SOL": {
      "id": "So11111111111111111111111111111111111111112",
      "mintSymbol": "SOL",
      "vsToken": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
      "vsTokenSymbol": "USDC",
      "price": 30.389174403
    }
  },
  "timeTaken": 0.0003002400007972028
}

Rate Limits: This endpoint is rate limited to 600 requests/min.

HTTP Status Code

CodeError Message
400
  • Amount lesser or equals to 0
  • No routed found for trading pairs
404Symbol or address not found for either input or vsToken
409Duplicate symbol found for input or vsToken.

The server will respond an error structure which contains the conflict addresses. User will have to use address mode instead.

{ "error": "Duplicated symbol found for PERP, use one of the address instead", "addresses" ["D68NB5JkzvyNCZAvi6EGtEcGvSoRNPanU9heYTAUFFRa", "9BsnSWDPfbusseZfnXyZ3un14CyPMZYvsKjWY3Y8Gbqn", "EBQ6gWBQNxA2zB4twR5GWP6CkeAhqZZZeDgeP7BTtdM3"]}
Language
Click Try It! to start a request and see the response here!