Publisher Bot
The publisher bot updates on a cycle to
- Every minute, pull data from all providers. This requires an API key per provider, and must respect each provider's rate limits. A minimum provider threshold is required to reach “quorum” for a price update.
- Match and normalize tokens across providers. The first run takes a couple seconds on minimal hardware; after the first run we cache the cross token matches for performance.
- Tokens often have slightly different identifiers across platforms, e.g.
eth
andethereum
. - Most of the time, a token has the same symbol across all providers.
- If the symbol doesn't match, we look for a matching circulating supply.
- Tokens often have slightly different identifiers across platforms, e.g.
- For each provider,
- Filter out
- Tokens that do not appear in the entire quorum set of providers
- Tokens with <$1000 volume in the last 24 hours
- Wrapped or staked tokens
- Select the top 200 tokens by market cap
- Compute for BTCDOM, ETHDOM, and USDTDOM
- Filter out
- Take the mean of the computed dominance values across providers.
- Publish BTCDOM, ETHDOM, and USDTDOM prices in a single transaction to the on-chain oracle contract
- This emits a
PriceUpdate
event, used by the Chart API to notify live chart subscriptions.
- This emits a
Note that CoinGecko is currently our only provider.