> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dexploit.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Filter tokens (Phase-7 V2 screener)

> Server-side filtered + sorted token search. Filters combine as AND. Volume/change windows default to `1h`.

The NL-style query bar and chip bar on the Dexploit terminal screener serialize into this same JSON body. The flat `GET /search` alias maps query-string params onto the same filters.

Response is **top-level** — `{ results, total_matches, limit, offset, warnings }` with **no** `{success, data, error}` wrapper. (Errors are still enveloped — see below.)

Response headers: `x-cache` (`HIT`|`MISS`) and `x-total-matches-exact` (`true`|`false` — when `false`, `total_matches` is a lower bound). `warnings` carries deferred-filter and cold-cache notes (e.g. `sectors_filter_skipped_cold_cache`, `total_matches_is_lower_bound`, and risk_score being deferred).

**Two failure modes:**
- **Malformed address filter** (`mint`, `mints[]`, or `creator` not valid base58) → **HTTP 400** with the enveloped body `{"success":false,"data":null,"error":"invalid parameter: invalid_filter:mint|creator|mints"}`.
- **Unsupported filter** (e.g. `risk_score`) → stays **HTTP 200**; the filter is ignored and a note is appended to the `warnings[]` array rather than failing the request.

The `GET /search` alias inherits both behaviors.



## OpenAPI

````yaml /api-reference/openapi.json post /screener
openapi: 3.1.0
info:
  title: Dexploit API
  version: 1.0.0
  description: Real-time and historical Solana DEX swap and OHLCV data.
servers:
  - url: https://api.dexploit.dev
    description: Production
security:
  - ApiKeyHeader: []
  - BearerAuth: []
  - ApiKeyQuery: []
paths:
  /screener:
    post:
      tags:
        - Screener
      summary: Filter tokens (Phase-7 V2 screener)
      description: >-
        Server-side filtered + sorted token search. Filters combine as AND.
        Volume/change windows default to `1h`.


        The NL-style query bar and chip bar on the Dexploit terminal screener
        serialize into this same JSON body. The flat `GET /search` alias maps
        query-string params onto the same filters.


        Response is **top-level** — `{ results, total_matches, limit, offset,
        warnings }` with **no** `{success, data, error}` wrapper. (Errors are
        still enveloped — see below.)


        Response headers: `x-cache` (`HIT`|`MISS`) and `x-total-matches-exact`
        (`true`|`false` — when `false`, `total_matches` is a lower bound).
        `warnings` carries deferred-filter and cold-cache notes (e.g.
        `sectors_filter_skipped_cold_cache`, `total_matches_is_lower_bound`, and
        risk_score being deferred).


        **Two failure modes:**

        - **Malformed address filter** (`mint`, `mints[]`, or `creator` not
        valid base58) → **HTTP 400** with the enveloped body
        `{"success":false,"data":null,"error":"invalid parameter:
        invalid_filter:mint|creator|mints"}`.

        - **Unsupported filter** (e.g. `risk_score`) → stays **HTTP 200**; the
        filter is ignored and a note is appended to the `warnings[]` array
        rather than failing the request.


        The `GET /search` alias inherits both behaviors.
      operationId: runScreener
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                filters:
                  $ref: '#/components/schemas/ScreenerFiltersV2'
                sort:
                  $ref: '#/components/schemas/ScreenerSortV2'
                limit:
                  type: integer
                  default: 200
                  minimum: 1
                  maximum: 500
                offset:
                  type: integer
                  default: 0
                  minimum: 0
                compact:
                  type: boolean
                  default: false
                  description: When `true`, rows use the compact variant.
            example:
              limit: 25
              filters:
                volume_sol:
                  window: 1h
                  min: 500
                holders:
                  min: 100
                audit:
                  lp_burnt: true
                  mint_revoked: true
                status: graduated
              sort:
                by: trending_score
                order: desc
      responses:
        '200':
          description: Filtered results. Full rows unless `compact=true`.
          headers:
            x-cache:
              schema:
                type: string
                enum:
                  - HIT
                  - MISS
              description: Cache hit/miss.
            x-total-matches-exact:
              schema:
                type: string
                enum:
                  - 'true'
                  - 'false'
              description: When `false`, `total_matches` is a lower bound.
          content:
            application/json:
              schema:
                type: object
                properties:
                  results:
                    type: array
                    items:
                      oneOf:
                        - $ref: '#/components/schemas/ScreenerResultV2'
                        - $ref: '#/components/schemas/ScreenerResultV2Compact'
                  total_matches:
                    type: integer
                    description: >-
                      Total matching tokens before paging. See
                      `x-total-matches-exact`.
                  limit:
                    type: integer
                  offset:
                    type: integer
                  warnings:
                    type: array
                    items:
                      type: string
        '400':
          description: >-
            Malformed address filter (`mint`, `mints[]`, or `creator` not valid
            base58). Unsupported filters like `risk_score` do **not** 400 — they
            stay 200 with a `warnings[]` note.
          content:
            application/json:
              schema:
                type: object
                required:
                  - success
                  - data
                  - error
                properties:
                  success:
                    type: boolean
                    enum:
                      - false
                  data:
                    type: 'null'
                  error:
                    type: string
                    description: >-
                      Always of the form `invalid parameter:
                      invalid_filter:<field>` where `<field>` is `mint`,
                      `creator`, or `mints`.
                    example: 'invalid parameter: invalid_filter:mint'
              example:
                success: false
                data: null
                error: 'invalid parameter: invalid_filter:mint'
components:
  schemas:
    ScreenerFiltersV2:
      type: object
      description: >-
        Phase-7 V2 screener filters (~40 fields, all optional, combined as AND).
        Replaces the legacy 6-field `ScreenerFilters`. Range filters take `{min,
        max}`. Volume/change windows default to `1h`.
      properties:
        liquidity_sol:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        volume_sol:
          type: object
          properties:
            window:
              type: string
              enum:
                - 5m
                - 15m
                - 1h
                - 6h
                - 24h
              default: 1h
            min:
              type: number
            max:
              type: number
        age_hours:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        change_pct:
          type: object
          properties:
            window:
              type: string
              enum:
                - 5m
                - 15m
                - 1h
                - 6h
                - 24h
              default: 1h
            min:
              type: number
            max:
              type: number
        audit:
          type: object
          properties:
            mint_revoked:
              type: boolean
            freeze_revoked:
              type: boolean
            lp_burnt:
              type: boolean
        trending_score:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        sectors:
          type: array
          items:
            type: string
        dexes:
          type: array
          items:
            type: string
        query:
          type: string
        symbol:
          type: string
        mint:
          type: string
          description: >-
            Single mint address. Must be a valid base58 mint; a malformed value
            returns `400 invalid parameter: invalid_filter:mint` (see endpoint
            responses).
        mints:
          type: array
          items:
            type: string
          maxItems: 200
          description: >-
            Batch filter — restrict results to this set of mints (cap 200). Use
            this to fetch screener rows for a known list of tokens in one call.
            Any malformed entry returns `400 invalid parameter:
            invalid_filter:mints`.
        creator:
          type: string
          description: >-
            Creator/deployer wallet. A malformed (non-base58) value returns `400
            invalid parameter: invalid_filter:creator`.
        has_image:
          type: boolean
        has_socials:
          type: boolean
        has_twitter:
          type: boolean
        has_telegram:
          type: boolean
        has_website:
          type: boolean
        launchpad:
          type: string
        market:
          type: string
        created_at:
          type: object
          properties:
            min:
              type: integer
            max:
              type: integer
          description: Epoch (uint) range.
        market_cap:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        status:
          type: string
        holders:
          type: object
          properties:
            min:
              type: integer
            max:
              type: integer
        top10:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        dev:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        insiders:
          type: object
          properties:
            min:
              type: integer
            max:
              type: integer
        insiders_pct:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        snipers:
          type: object
          properties:
            min:
              type: integer
            max:
              type: integer
        snipers_pct:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        bundlers:
          type: object
          properties:
            min:
              type: integer
            max:
              type: integer
        bundlers_pct:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        graduated_at:
          type: object
          properties:
            min:
              type: integer
            max:
              type: integer
        curve_pct:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        price:
          type: object
          properties:
            min:
              type: number
            max:
              type: number
        buys:
          type: object
          properties:
            min:
              type: integer
            max:
              type: integer
        sells:
          type: object
          properties:
            min:
              type: integer
            max:
              type: integer
        rugged:
          type: boolean
        risk_score:
          type: object
          properties:
            min:
              type: null
            max:
              type: null
          description: Deferred — currently produces a warning rather than filtering.
    ScreenerSortV2:
      type: object
      properties:
        by:
          type: string
          description: >-
            Sort key (e.g. `volume_sol`, `market_cap`, `holders`, `change_pct`,
            `trending_score`, `age_hours`).
        order:
          type: string
          enum:
            - asc
            - desc
          default: desc
    ScreenerResultV2:
      type: object
      description: Full Phase-7 V2 screener result row (`compact=false`).
      properties:
        mint:
          type: string
        volume_sol:
          type: number
        price_per_token:
          type: number
          description: Price in **lamports per atomic token unit** (1 SOL = 1e9 lamports).
        last_ts:
          type: integer
          description: Epoch ms of most recent swap considered.
        first_ts:
          type: integer
          description: Epoch ms of first swap in the window.
        age_hours:
          type: number
        change_pct:
          type: number
        buys:
          type: integer
          description: uint64.
        sells:
          type: integer
          description: uint64.
        curve_pct:
          type: number
          description: Bonding-curve progress = real_sol_reserves / 85e9 * 100.
        liquidity_sol:
          type:
            - number
            - 'null'
          description: >-
            Pool/curve liquidity in SOL. A **number** when `liquidity_status` is
            `IN_CURVE`; **0** when `DRAINED` (curve reserves collapsed —
            LP-drain/rug); **null** for `POOL_DEPTH` (graduated/AMM pools, where
            curve liquidity is not the relevant measure).
        liquidity_status:
          type: string
          enum:
            - IN_CURVE
            - POOL_DEPTH
            - DRAINED
          description: >-
            Source/meaning of `liquidity_sol`. `IN_CURVE` = pre-graduation
            bonding-curve liquidity (numeric `liquidity_sol`); `POOL_DEPTH` =
            post-graduation AMM pool depth (`liquidity_sol` is null); `DRAINED`
            = curve reserves collapsed / rugged (`liquidity_sol` is `0`).
        market_cap:
          type:
            - number
            - 'null'
          description: Market cap in SOL. **null** (not 0) when not yet computable.
        holder_count:
          type:
            - integer
            - 'null'
          description: >-
            uint64. **null** (not 0) when holder data has not been computed for
            this mint yet.
        top10_pct:
          type:
            - number
            - 'null'
          description: >-
            Top-10 (pool-excluded) share of supply. **null** (not 0) when holder
            data is unavailable.
        dev_held_pct:
          type: number
        insider_count:
          type: integer
          description: uint32.
        insider_pct:
          type: number
        sniper_count:
          type: integer
          description: uint32.
        sniper_pct:
          type: number
        bundler_count:
          type: integer
          description: uint32.
        bundler_pct:
          type: number
        graduated_ts:
          type: integer
          description: Epoch ms (int64).
        status:
          type: string
          enum:
            - active
            - graduating
            - graduated
            - rugged
        trending_score:
          type: number
    ScreenerResultV2Compact:
      type: object
      description: Compact Phase-7 V2 screener result row (`compact=true`).
      properties:
        mint:
          type: string
        volume_sol:
          type: number
        price_per_token:
          type: number
          description: Price in lamports per atomic token unit (1 SOL = 1e9 lamports).
        change_pct:
          type: number
        market_cap:
          type:
            - number
            - 'null'
          description: '**null** (not 0) when not yet computable.'
        holder_count:
          type:
            - integer
            - 'null'
          description: '**null** (not 0) when holder data is unavailable.'
        status:
          type: string
  securitySchemes:
    ApiKeyHeader:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Preferred for swaps-api endpoints (`/swaps/*`, `/stats/*`, `/trending`,
        `/pool-events`).
    BearerAuth:
      type: http
      scheme: bearer
      description: >-
        Required by the OHLCV endpoints (`/api/v1/*`) and accepted by every
        other endpoint. Send `Authorization: Bearer ohlcv_live_sk_<your_key>`.
    ApiKeyQuery:
      type: apiKey
      in: query
      name: api_key
      description: >-
        Browser-friendly alternative to the Bearer header — accepted by every
        endpoint and required for WebSocket from the browser.

````