Overview
When working with the Novig API, it’s important to understand how outcomes are organized. The order of outcomes in an array does not determine their meaning—theindex field does.
The Index Field
Each outcome object contains anindex field that identifies which side of the market it represents:
Example
Consider this response from the API:- The first item in the
outcomesarray (14e8323b-...) hasindex: 1, making it the Away/No side - The second item in the
outcomesarray (c84fa737-...) hasindex: 0, making it the Home/Yes side
Market Type Mapping
The meaning ofindex: 0 depends on the market type:
For game-level markets (MONEY, SPREAD), index 0 always corresponds to the home team. For totals and player props, index 0 corresponds to the Over or Yes side.
Three-Way Moneylines
Some competitions that can end in a draw (e.g. soccer / the FIFA World Cup) useMONEYLINE_3_WAY_WIN markets. Unlike a standard two-sided moneyline, a three-way moneyline is not a single Home/Away market. Instead, each possible result is its own independent Yes / No market:
Within each of these markets the index follows the Yes/No convention:
In some responses the outcome
type field for these markets may surface as Over / Under rather than Yes / No. This is the same Yes/No semantics described above — index: 0 is always the Yes side. Rely on index, not on type, to determine the side.