Definition

What is token_id?

A token_id identifies one specific outcome token within a market — the UP side or the DOWN side, for example. Orders are placed against a token_id, not against the market as a whole, so getting the mapping from outcome to token backwards places a trade on the opposite side.

Also called: token id · asset id

Why it matters

Token IDs, like condition IDs, change every cycle on recurring markets. Fetch both together and validate that the outcome label attached to a token is the one you expect before sending an order.

The common mistake

Mapping outcomes to tokens by array position rather than by the outcome label. Position is not guaranteed to be stable, and getting it backwards places the trade on the opposite side of the market.

Related terms

More

Browse the full glossary (32 terms), the strategy database, or the build guides.

Join Discord