get_cumulative_prices
Last updated
Last updated
This on-chain view returns cumulative prices and last timestamp of its calculation for a liquidity pool (pair). Also can return a list of cumulative prices for a list of liquidity pools.
Field | Type | Description |
---|---|---|
108
- pair (pool) with the specified token_id
not listed.
Field | Type | Description |
---|---|---|
Field | Type | Description |
---|---|---|
cum_prices_req_t
token_id_t (nat)
Pair ID for which you need to get cumulative prices
last_block_timestamp
timestamp
Last timestamp of cumulative prices calculation
token_a_price_cml
nat
Cumulative price of token A
token_b_price_cml
nat
Cumulative price of token B
request
cum_prices_req_t (nat)
Cumulative prices request
cumulative_prices
Cumulative prices response