{"openapi":"3.1.0","info":{"title":"Impulse API"},"servers":[{"url":"https://starknet.impulse.avnu.fi"},{"url":"https://sepolia.impulse.avnu.fi"}],"paths":{"/v3/tokens/prices":{"post":{"tags":["Tokens"],"operationId":"getTokenPrices","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GetTokenPricesRequest"}}},"required":true},"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TokenPriceV3Dto"}}}}}}}},"/v3/tokens":{"get":{"tags":["Tokens"],"summary":"Get the information of the tokens with the largest TVL on Starknet","description":"This endpoint will return various information for the tokens with the largest TVL on Starknet, such as the name, symbol, address, market information, and the USD price feed for the last 7 days.You can view all the data here: https://app.avnu.fi/en/market","operationId":"getTokens","responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TokenV3Dto"}}}}}}}},"/v3/tokens/{tokenAddress}":{"get":{"tags":["Tokens"],"summary":"Get detailed information of a token","operationId":"getTokenInfo","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"withPriceFeed","in":"query","required":false,"schema":{"type":"boolean"}}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"$ref":"#/components/schemas/TokenV3Dto"}}}}}}},"/v3/tokens/{tokenAddress}/volumes/line":{"get":{"tags":["Tokens"],"summary":"Get history of the token's volume","operationId":"getVolumeHistory","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T15:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/LineDatasetItemV3Dto"}}}}}}}},"/v3/tokens/{tokenAddress}/prices/line":{"get":{"tags":["Tokens"],"summary":"Get token's price feed","operationId":"getPriceFeedLine","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"in","in":"query","required":false,"schema":{"type":"string"},"example":"usd"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-05T14:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/LineDatasetItemDto"}}}}}}}},"/v3/tokens/{tokenAddress}/prices/candle":{"get":{"tags":["Tokens"],"summary":"Get token's candle price feed","operationId":"getPriceFeedCandle","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"in","in":"query","required":false,"schema":{"type":"string"},"example":"usd"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-05T14:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CandleDatasetItemDto"}}}}}}}},"/v3/tokens/{tokenAddress}/exchange-volumes":{"get":{"tags":["Tokens"],"summary":"Get the token's exchange volume","operationId":"getExchangeVolumes","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date"},"example":"2024-02-04"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date"},"example":"2024-02-05"}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeVolumeV3Dto"}}}}}}}},"/v3/tokens/{tokenAddress}/exchange-volumes/line":{"get":{"tags":["Tokens"],"summary":"Get history of the token's exchange volume","operationId":"getExchangeVolumesHistory","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T15:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeLineDatasetItemV3Dto"}}}}}}}},"/v3/tokens/{tokenAddress}/exchange-tvl":{"get":{"tags":["Tokens"],"summary":"Get token's tvl on exchanges","operationId":"getExchangeTvl","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"date","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeTvlDto"}}}}}}}},"/v3/tokens/{tokenAddress}/exchange-tvl/line":{"get":{"tags":["Tokens"],"summary":"Get history of token's tvl on exchanges","operationId":"getExchangeTvlHistory","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T15:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeTvlDto"}}}}}}}},"/v1/tokens/{tokenAddress}":{"get":{"tags":["Tokens"],"summary":"Get detailed information of a token","operationId":"getInfo","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"$ref":"#/components/schemas/TokenDto"}}}}}}},"/v1/tokens/{tokenAddress}/volumes/line":{"get":{"tags":["Tokens"],"summary":"Get history of the token's volume","operationId":"getVolumeHistory_1","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T15:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/LineDatasetItemDto"}}}}}}}},"/v1/tokens/{tokenAddress}/prices/line":{"get":{"tags":["Tokens"],"summary":"Get token's price feed","operationId":"getPriceFeedLine_1","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"in","in":"query","required":false,"schema":{"type":"string"},"example":"usd"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-05T14:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/LineDatasetItemDto"}}}}}}}},"/v1/tokens/{tokenAddress}/prices/candle":{"get":{"tags":["Tokens"],"summary":"Get token's candle price feed","operationId":"getPriceFeedCandle_1","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"in","in":"query","required":false,"schema":{"type":"string"},"example":"usd"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-05T14:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CandleDatasetItemDto"}}}}}}}},"/v1/tokens/{tokenAddress}/exchange-volumes":{"get":{"tags":["Tokens"],"summary":"Get the token's exchange volume","operationId":"getExchangeVolumes_1","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date"},"example":"2024-02-04"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date"},"example":"2024-02-05"}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeVolumeDto"}}}}}}}},"/v1/tokens/{tokenAddress}/exchange-volumes/line":{"get":{"tags":["Tokens"],"summary":"Get history of the token's exchange volume","operationId":"getExchangeVolumesHistory_1","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T15:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeLineDatasetItemDto"}}}}}}}},"/v1/tokens/{tokenAddress}/exchange-tvl":{"get":{"tags":["Tokens"],"summary":"Get token's tvl on exchanges","operationId":"getExchangeTvl_1","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"date","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeTvlDto"}}}}}}}},"/v1/tokens/{tokenAddress}/exchange-tvl/line":{"get":{"tags":["Tokens"],"summary":"Get history of token's tvl on exchanges","operationId":"getExchangeTvlHistory_1","parameters":[{"name":"tokenAddress","in":"path","required":true,"schema":{"type":"string"},"example":"0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7"},{"name":"startDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T14:08:38.511Z"},{"name":"endDate","in":"query","required":false,"schema":{"type":"string","format":"date-time"},"example":"2024-02-04T15:08:38.511Z"},{"name":"resolution","in":"query","description":"Accepted values: 1,5,15,1H,4H,1D,1W","required":false,"schema":{"type":"string"},"example":5}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ExchangeTvlDto"}}}}}}}},"/v1/tokens/prices":{"get":{"tags":["Tokens"],"summary":"Get current price of all given tokens","description":"This endpoint will return the price in usd and ETH for the given tokens on starknet. The data are updated every minutes.","operationId":"getTokenPrices_1","parameters":[{"name":"token","in":"query","description":"List of token addresses (hex format)","required":true,"schema":{"type":"array","items":{"type":"string"},"maxItems":10,"minItems":1}}],"responses":{"400":{"description":"Bad Request","content":{"*/*":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"200":{"description":"OK","content":{"*/*":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TokenPriceDto"}}}}}}}}},"components":{"schemas":{"ErrorResponse":{"type":"object","properties":{"messages":{"type":"array","items":{"type":"string"}},"revertError":{"type":"string"}},"required":["messages"]},"GetTokenPricesRequest":{"type":"object","properties":{"tokens":{"type":"array","items":{"type":"string"},"maxItems":50,"minItems":1}},"required":["tokens"]},"Market":{"type":"object","properties":{"usd":{"type":"number","format":"double"}},"required":["usd"]},"TokenPriceV3Dto":{"type":"object","properties":{"address":{"type":"string"},"decimals":{"type":"integer","format":"int32"},"globalMarket":{"$ref":"#/components/schemas/Market"},"starknetMarket":{"$ref":"#/components/schemas/Market"}},"required":["address","decimals","starknetMarket"]},"GlobalMarket":{"type":"object","properties":{"usd":{"type":"number","format":"double"},"usdMarketCap":{"type":"number","format":"double"},"usdFdv":{"type":"number","format":"double"},"usdMarketCapChange24h":{"type":"number","format":"double"},"usdMarketCapChangePercentage24h":{"type":"number","format":"double"}},"required":["usd","usdFdv","usdMarketCap","usdMarketCapChange24h","usdMarketCapChangePercentage24h"]},"LineDatasetItemDto":{"type":"object","properties":{"date":{"type":"string","format":"date-time"},"value":{"type":"number","format":"double"}},"required":["date","value"]},"StarknetMarket":{"type":"object","properties":{"usd":{"type":"number","format":"double"},"usdTvl":{"type":"number","format":"double"},"usdPriceChange1h":{"type":"number","format":"double"},"usdPriceChangePercentage1h":{"type":"number","format":"double"},"usdPriceChange24h":{"type":"number","format":"double"},"usdPriceChangePercentage24h":{"type":"number","format":"double"},"usdPriceChange7d":{"type":"number","format":"double"},"usdPriceChangePercentage7d":{"type":"number","format":"double"},"usdVolume24h":{"type":"number","format":"double"},"usdTradingVolume24h":{"type":"number","format":"double"}},"required":["usd","usdPriceChange1h","usdPriceChange24h","usdPriceChange7d","usdTradingVolume24h","usdTvl","usdVolume24h"]},"TokenV3Dto":{"type":"object","properties":{"name":{"type":"string"},"symbol":{"type":"string"},"address":{"type":"string"},"decimals":{"type":"integer","format":"int32"},"logoUri":{"type":"string"},"coingeckoId":{"type":"string"},"verified":{"type":"boolean"},"starknet":{"$ref":"#/components/schemas/StarknetMarket"},"global":{"$ref":"#/components/schemas/GlobalMarket"},"tags":{"type":"array","items":{"type":"string","enum":["Unknown","Verified","Community","Unruggable","AVNU"]}},"linePriceFeedInUsd":{"type":"array","items":{"$ref":"#/components/schemas/LineDatasetItemDto"}}},"required":["address","decimals","linePriceFeedInUsd","name","starknet","symbol","tags","verified"]},"LineDatasetItemV3Dto":{"type":"object","properties":{"date":{"type":"string","format":"date-time"},"value":{"type":"number","format":"double"},"valueUsd":{"type":"number","format":"double"}},"required":["date","value","valueUsd"]},"CandleDatasetItemDto":{"type":"object","properties":{"date":{"type":"string","format":"date-time"},"open":{"type":"number","format":"double"},"high":{"type":"number","format":"double"},"low":{"type":"number","format":"double"},"close":{"type":"number","format":"double"},"volume":{"type":"number","format":"double"}},"required":["close","date","high","low","open","volume"]},"ExchangeVolumeV3Dto":{"type":"object","properties":{"value":{"type":"number","format":"double"},"valueUsd":{"type":"number","format":"double"},"exchange":{"type":"string"},"startDate":{"type":"string","format":"date"},"endDate":{"type":"string","format":"date"}},"required":["endDate","exchange","startDate","value","valueUsd"]},"ExchangeLineDatasetItemV3Dto":{"type":"object","properties":{"date":{"type":"string","format":"date-time"},"value":{"type":"number","format":"double"},"valueUsd":{"type":"number","format":"double"},"exchange":{"type":"string"}},"required":["date","exchange","value","valueUsd"]},"ExchangeTvlDto":{"type":"object","properties":{"exchange":{"type":"string"},"value":{"type":"number","format":"double"},"valueUsd":{"type":"number","format":"double"},"date":{"type":"string","format":"date-time"}},"required":["date","exchange","value","valueUsd"]},"TokenDto":{"type":"object","properties":{"name":{"type":"string"},"symbol":{"type":"string"},"address":{"type":"string"},"decimals":{"type":"integer","format":"int32"},"logoUri":{"type":"string"},"coingeckoId":{"type":"string"},"verified":{"type":"boolean"},"market":{"$ref":"#/components/schemas/Market"},"tags":{"type":"array","items":{"type":"string","enum":["Unknown","Verified","Community","Unruggable","AVNU"]}}},"required":["address","decimals","market","name","symbol","tags","verified"]},"ExchangeVolumeDto":{"type":"object","properties":{"value":{"type":"number","format":"double"},"exchange":{"type":"string"}},"required":["exchange","value"]},"ExchangeLineDatasetItemDto":{"type":"object","properties":{"date":{"type":"string","format":"date-time"},"value":{"type":"number","format":"double"},"exchange":{"type":"string"}},"required":["date","exchange","value"]},"TokenPriceDto":{"type":"object","properties":{"address":{"type":"string"},"priceInUSD":{"type":"number","format":"double"},"priceInETH":{"type":"number","format":"double"},"decimals":{"type":"integer","format":"int32"}},"required":["address","decimals","priceInETH","priceInUSD"]}}}}