Subscriptions use
wss://graphql.mobula.io/graphql with the graphql-transport-ws protocol. wss://graphql.mobula.io/graphql/subscriptions is also supported for backwards compatibility.Overview
Stream the current page of a filterTokens query in real time. The same filters, rankings, and pagination arguments accepted byfilterTokens are accepted here — the server re-evaluates them on every tick and pushes the full current page.
- First message is the full filtered set for the supplied arguments.
- Subsequent messages re-run the filter every
updatePeriodms and yield the full current set (not a delta). updatePerioddefaults to 500 ms and is capped at 60000 ms.
Returns
FilterTokenUpdates!
Current page of matching tokens for the supplied filters. See FilterTokenUpdates.
Arguments
TokenFilters
Filter conditions. See TokenFilters.
[TokenRanking]
Sorting criteria. See TokenRanking and TokenRankingAttribute.
TokenPairStatisticsType
FILTERED or UNFILTERED. See TokenPairStatisticsType.String
Search phrase to match against token name or symbol.
[String]
Array of specific token selectors in
"address:networkId" format.[String]
Array of token addresses to exclude from results.
Int
Maximum number of results to return (default: 25, max: 200).
Int
Pagination offset (default: 0).
Int
Update interval in milliseconds (default:
500, max: 60000).Example
Subscribe example
Open agraphql-transport-ws WebSocket to wss://api.mobula.io/graphql/subscriptions, complete the connection_init handshake, then send a subscribe message: