Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.codex.io/llms.txt

Use this file to discover all available pages before exploring further.

onFilterTokensUpdated is the live counterpart to filterTokens. It accepts the same filter and ranking inputs, sends the current matching set on the first message, then re-evaluates every 30 seconds and pushes updates as the matching set changes. Use it anywhere you would otherwise re-run filterTokens on a timer.
Boolean filtering: The filters input supports an optional boolFilter field that accepts and, or, and not operators (nestable up to 4 levels). Use it when you need different filter conditions for a subsets of tokens, such as per-network thresholds, or across different fields. For example, you might want different filter conditions depending on whether tokens are on Solana or Base. See Advanced Filtering for details.
This endpoint requires a Growth or Enterprise plan. Learn more.

Returns

Arguments

The first message delivers all tokens matching your filters. Subsequent messages only include tokens with updated data, returned at the interval you set via updatePeriod. Every 30 seconds, the filter itself re-evaluates: if tokens start or stop meeting your filters, the result set updates automatically.
subscription {
  onFilterTokensUpdated(
    limit: 25
    filters: {buyVolume1: {gt: 10000}, top10HoldersPercent: {lt: 80}, marketCap: {gt: 100000, lt: 20000000}}
    useAggregatedStats: true
    rankings: {attribute: trendingScore24, direction: DESC}
    updatePeriod: 500
  ) {
    updates {
      token {
        info {
          name
          symbol
          networkId
        }
      }
      marketCap
      priceUSD
      change1
      volume1
      top10HoldersPercent
      liquidity
    }
  }
}
Example Response
{
  "data": {
    "onFilterTokensUpdated": {
      "updates": [
        {
          "token": {
            "info": {
              "name": "Flat Eric",
              "symbol": "ooo",
              "networkId": 1399811149
            }
          },
          "marketCap": "1829189",
          "priceUSD": "0.00195113499065",
          "change1": "0.21374966245293178",
          "volume1": "126901",
          "top10HoldersPercent": 31.38365436675934,
          "liquidity": "79447"
        },
        {
          "token": {
            "info": {
              "name": "Peace Frog",
              "symbol": "PEACE",
              "networkId": 1399811149
            }
          },
          "marketCap": "7095047",
          "priceUSD": "0.00709505107906",
          "change1": "-0.0418823989642306",
          "volume1": "98114",
          "top10HoldersPercent": 12.362009437839479,
          "liquidity": "137270"
        },
        {
          "token": {
            "info": {
              "name": "SPIKE",
              "symbol": "SPIKE",
              "networkId": 1399811149
            }
          },
          "marketCap": "10145817",
          "priceUSD": "0.0101458368323",
          "change1": "-0.029693786111620973",
          "volume1": "87815",
          "top10HoldersPercent": 8.754611894819124,
          "liquidity": "227631"
        },
        {
          "token": {
            "info": {
              "name": "Larpcoin",
              "symbol": "LARP",
              "networkId": 1399811149
            }
          },
          "marketCap": "904235",
          "priceUSD": "0.00090423514265",
          "change1": "0.16557388134971962",
          "volume1": "181774",
          "top10HoldersPercent": 20.51292553319232,
          "liquidity": "40300"
        },
        {
          "token": {
            "info": {
              "name": "哈基米",
              "symbol": "哈基米",
              "networkId": 56
            }
          },
          "marketCap": "18268865",
          "priceUSD": "0.0182688647732",
          "change1": "-0.15041202192869108",
          "volume1": "184963",
          "top10HoldersPercent": 59.72826922461662,
          "liquidity": "737724"
        },
        {
          "token": {
            "info": {
              "name": "Tung Tung Tung Sahur",
              "symbol": "TripleT",
              "networkId": 1399811149
            }
          },
          "marketCap": "3812896",
          "priceUSD": "0.00381311474198",
          "change1": "0.03728259993298412",
          "volume1": "65648",
          "top10HoldersPercent": 18.637573181722505,
          "liquidity": "156325"
        },
        {
          "token": {
            "info": {
              "name": "afk",
              "symbol": "afk",
              "networkId": 1399811149
            }
          },
          "marketCap": "4248821",
          "priceUSD": "0.00448164388206",
          "change1": "0.023518386389426892",
          "volume1": "11243",
          "top10HoldersPercent": 15.219805376721089,
          "liquidity": "151350"
        },
        {
          "token": {
            "info": {
              "name": "Block Street",
              "symbol": "BSB",
              "networkId": 56
            }
          },
          "marketCap": "14792062",
          "priceUSD": "0.360374979334",
          "change1": "-0.011605132198808736",
          "volume1": "333721",
          "top10HoldersPercent": 64.47136246550876,
          "liquidity": "200176"
        },
        {
          "token": {
            "info": {
              "name": "assface",
              "symbol": "assface",
              "networkId": 1399811149
            }
          },
          "marketCap": "429130",
          "priceUSD": "0.000429168549105",
          "change1": "0.0039139458187899615",
          "volume1": "106149",
          "top10HoldersPercent": 23.25621437058673,
          "liquidity": "38003"
        },
        {
          "token": {
            "info": {
              "name": "uncraft",
              "symbol": "uncraft",
              "networkId": 1399811149
            }
          },
          "marketCap": "4860071",
          "priceUSD": "0.00486010293642",
          "change1": "0.47386803384848103",
          "volume1": "2141376",
          "top10HoldersPercent": 15.659377708792855,
          "liquidity": "111152"
        },
        {
          "token": {
            "info": {
              "name": "fat choi",
              "symbol": "发财",
              "networkId": 1399811149
            }
          },
          "marketCap": "2837240",
          "priceUSD": "0.00296621392708",
          "change1": "0.0034901703058449816",
          "volume1": "80584",
          "top10HoldersPercent": 38.76097132829333,
          "liquidity": "97172"
        },
        {
          "token": {
            "info": {
              "name": "unc",
              "symbol": "unc",
              "networkId": 1399811149
            }
          },
          "marketCap": "7071256",
          "priceUSD": "0.00707206012359",
          "change1": "-0.064170587795235",
          "volume1": "190729",
          "top10HoldersPercent": 10.192638745751273,
          "liquidity": "363956"
        },
        {
          "token": {
            "info": {
              "name": "Wrapped MON",
              "symbol": "WMON",
              "networkId": 143
            }
          },
          "marketCap": "11864092",
          "priceUSD": "0.0339234271493",
          "change1": "-0.003037937307371629",
          "volume1": "806817",
          "top10HoldersPercent": 59.53991890235804,
          "liquidity": "9667761"
        },
        {
          "token": {
            "info": {
              "name": "BELIEF",
              "symbol": "BELIEF",
              "networkId": 1399811149
            }
          },
          "marketCap": "16080541",
          "priceUSD": "0.0171526449453",
          "change1": "-0.017646300856981517",
          "volume1": "110988",
          "top10HoldersPercent": 58.706574401235365,
          "liquidity": "275007"
        },
        {
          "token": {
            "info": {
              "name": "Dumb Money",
              "symbol": "DUMBMONEY",
              "networkId": 1399811149
            }
          },
          "marketCap": "1108146",
          "priceUSD": "0.00111617990749",
          "change1": "-0.057635940913987604",
          "volume1": "148757",
          "top10HoldersPercent": 10.00502812835363,
          "liquidity": "84105"
        },
        {
          "token": {
            "info": {
              "name": "Huma Finance",
              "symbol": "HUMA",
              "networkId": 56
            }
          },
          "marketCap": "11259237",
          "priceUSD": "0.0246464157567",
          "change1": "0.014621906976420972",
          "volume1": "205621",
          "top10HoldersPercent": 36.668810577350726,
          "liquidity": "2832638"
        },
        {
          "token": {
            "info": {
              "name": "Believe",
              "symbol": "BELIEVE",
              "networkId": 1399811149
            }
          },
          "marketCap": "974088",
          "priceUSD": "0.000761009418281",
          "change1": "-0.12116746795530602",
          "volume1": "131748",
          "top10HoldersPercent": 48.243932294422876,
          "liquidity": "43303"
        },
        {
          "token": {
            "info": {
              "name": "Wrapped Sonic",
              "symbol": "wS",
              "networkId": 146
            }
          },
          "marketCap": "10656021",
          "priceUSD": "0.0438266970262",
          "change1": "-0.007544105952512887",
          "volume1": "29643",
          "top10HoldersPercent": 72.3758553402159,
          "liquidity": "1546888"
        },
        {
          "token": {
            "info": {
              "name": "Wrapped ETH",
              "symbol": "WETH",
              "networkId": 2741
            }
          },
          "marketCap": "7792414",
          "priceUSD": "2400.40214443",
          "change1": "-0.0014648585627610304",
          "volume1": "18579",
          "top10HoldersPercent": 24.376711845331464,
          "liquidity": "6362821"
        },
        {
          "token": {
            "info": {
              "name": "Wojak",
              "symbol": "WOJAK",
              "networkId": 1399811149
            }
          },
          "marketCap": "3952627",
          "priceUSD": "0.00395305266273",
          "change1": "-0.07301419052147469",
          "volume1": "65462",
          "top10HoldersPercent": 20.747708963574766,
          "liquidity": "285363"
        },
        {
          "token": {
            "info": {
              "name": "Deployr",
              "symbol": "Deployr",
              "networkId": 1399811149
            }
          },
          "marketCap": "748438",
          "priceUSD": "0.00765675034212",
          "change1": "-0.04677212604804801",
          "volume1": "22672",
          "top10HoldersPercent": 46.25422412860161,
          "liquidity": "47431"
        },
        {
          "token": {
            "info": {
              "name": "Dumb Money",
              "symbol": "DUMBMONEY",
              "networkId": 1399811149
            }
          },
          "marketCap": "2839373",
          "priceUSD": "0.00283937331254",
          "change1": "53.170773887827416",
          "volume1": "148762",
          "top10HoldersPercent": 6.7282942456018,
          "liquidity": "7106"
        },
        {
          "token": {
            "info": {
              "name": "Justice for Evelyn",
              "symbol": "EVELYN",
              "networkId": 1399811149
            }
          },
          "marketCap": "331370",
          "priceUSD": "0.000331369977886",
          "change1": "111.38237343868775",
          "volume1": "482230",
          "top10HoldersPercent": 4.6684968243218,
          "liquidity": "23633"
        },
        {
          "token": {
            "info": {
              "name": "Wrapped Polygon Ecosystem Token",
              "symbol": "WPOL",
              "networkId": 137
            }
          },
          "marketCap": "19630736",
          "priceUSD": "0.0935282748972",
          "change1": "-0.0013144673725107396",
          "volume1": "52459",
          "top10HoldersPercent": 70.87448266847595,
          "liquidity": "6339439"
        },
        {
          "token": {
            "info": {
              "name": "Humanity",
              "symbol": "H",
              "networkId": 56
            }
          },
          "marketCap": "16197678",
          "priceUSD": "0.129283372611",
          "change1": "-0.006961189205480443",
          "volume1": "171817",
          "top10HoldersPercent": 79.73114731398417,
          "liquidity": "1151147"
        }
      ]
    }
  }
}

Usage Guidelines

  • Accepts the same filters, rankings, and limit arguments as the filterTokens query. If you’ve already built a filterTokens request, you can reuse it here as a subscription.
  • The first message delivered contains the current state of the filtered set, so there’s no need to run a one-off filterTokens query first.
  • Matched tokens push data updates on a configurable interval via updatePeriod (defaults to 500ms if not specified, accepts any value in ms from 0ms to 60s).
  • The filter itself re-evaluates the token list every 30 seconds. If the set of matching tokens changes (a token starts meeting the filters, or stops meeting them), you’ll automatically receive updates reflecting the new set. This re-evaluation interval is not currently configurable.
  • Ideal for keeping trending lists, leaderboards, or filtered dashboards live without manual polling.
  • For ultra-low-latency token discovery (e.g. memescope-style interfaces) our Launchpad subscriptions may be a better fit for that use case.
  • Apply the same quality filters (trendingScore, minimum volume, mcap range, liquidity, holders, etc.) you would on filterTokens to avoid low-quality tokens in the stream.
  • Response limit remains 200 tokens per subscription.

Troubleshooting Tips

No. The first message delivered after subscribing contains the current filtered result set. You can treat the subscription as a full replacement for polling filterTokens for most use cases.
Tokens that match your filters will push data updates on a set updatePeriod (default 500ms). If that period is set high (e.g. 60000 for 60s), pushes will be less frequent. The filter itself also re-evaluates every 30 seconds, so if the set of matching tokens hasn’t changed and no tokens in the set have new data in your updatePeriod window, you may see quiet stretches. Broadening your filters or lowering updatePeriod will confirm the stream is live.
Yes. Set updatePeriod to any value between 0ms and 60s. Note that 0ms means “as fast as events arrive,” which can mean high message volume on busy filter sets.
Not currently. The 30-second filter re-evaluation is fixed. For very low-latency token discovery (e.g. memescope-style UIs), our launchpad subscriptions offer lower-latency streams for newly launched tokens.
It depends on your use case for filterTokens, but in most instances, yes. This subscription is the intended replacement for poll-based refresh patterns on filterTokens.
No. To change filters or rankings, close the current subscription and open a new one with the updated arguments.
  • Discover Tokens: Build token discovery pages with trending data, filters, and search
  • Launchpads: Build a launchpad discovery view with real-time token lifecycle updates