Pool/Symbol ID entity
From the history and stream use cases you can see that the ID from “ticker” list is treated as a unique identifier for a particular trading pool.
This value is then used throughout API endpoints as pool ID aka symbol ID, for example in /history
endpoint - ?symbol
query, and in /tokens/stream
endpoint - json pool ID list.
You can also get Pool/Symbol ID list for a trade pair if you only know it’s human readable descriptor. E.g. for ADA-SNEK you can use the following code.
TRADE_PAIR = "ADA.SNEK"
pairs = requests.get(
"https://api.charli3.io/api/v1/symbol_info",
params={"group": group}
).json()
DESCRIPTOR_PAIRS = {}
for symbol, ticker in zip(pairs["symbol"], pairs["ticker"]):
if symbol.startswith(f"{TRADE_PAIR}_"):
DESCRIPTOR_PAIRS[symbol] = ticker
print(DESCRIPTOR_PAIRS)