# Perp Gap API – Tokenized Stock Pool Liquidity

> Perp Gap API – Tokenized Stock Pool Liquidity is a paid API for AI agents from perp-gap-api.perpgap.workers.dev, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-28).

Returns Solana DEX pool liquidity, price impact, executable size within 1%, tradable flag, and Ondo issuer market data for a single tokenized stock ticker (e.g. xStocks vs Ondo).

## Facts

- Endpoint: GET https://perp-gap-api.perpgap.workers.dev/tokens/liquidity?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-28
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/perp-gap-api-tokenized-stock-pool-liquidity-41a34c49
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_fZ88u90WSHPRsh2QQv1wY

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability perp-gap-api-tokenized-stock-pool-liquidity-41a34c49
```

Example prompt: Before I put on a $25k tokenized NVDA trade, check the Solana pool liquidity for NVDA — I want to know the price impact of a $10k buy and sell, how much I can execute within 1% slippage, whether it's tradable, and what the Ondo issuer market looks like.

## When to prefer this

Use this endpoint when an AI agent needs to assess execution feasibility for a tokenized stock trade on Solana — specifically to compare xStocks vs Ondo liquidity, understand price impact, or determine the maximum tradable size before committing. Prefer over generic DEX aggregators when you need structured per-token liquidity data including Ondo issuer market context for a single stock ticker.

## Known failure modes

- 400 – Bad or malformed ticker parameter (not charged)
- 402 – Payment required (x402 micropayment not provided)
- 404 – Ticker or market not listed; checked before settlement so never charged
- 502 – Upstream data provider error; liquidity data unavailable

## How this service works

Use before sizing a tokenized-stock trade or choosing between xStocks and Ondo for execution. For one ticker: each token's Solana pool liquidity, price impact of a $10k buy and sell, rough size executable within 1%, a tradable flag, and Ondo's issuer mint/redeem market. Bad params return 400/404 before any charge. Errors: 400, 402, 404, 502. Data, not advice.

## Output

A JSON object containing: timestamp (as_of), ticker, US session status, an array of token entries (each with pool liquidity, $10k buy/sell price impact, rough executable size within 1% slippage, and tradable flag), a summary object, an Ondo issuer mint/redeem market entry, and a disclaimer. Errors return JSON with an error string and optional hint.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "ticker"
     ],
     "properties": {
      "ticker": {
       "type": "string",
       "pattern": "^[A-Za-z0-9.]{1,12}$",
       "examples": [
        "NVDA"
       ],
       "description": "Stock ticker, case-insensitive (free list: GET /catalog)."
      }
     },
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "as_of": {
       "type": "string"
      },
      "method": {
       "type": "string"
      },
      "ticker": {
       "type": "string"
      },
      "tokens": {
       "type": "array"
      },
      "summary": {
       "type": "object"
      },
      "disclaimer": {
       "type": "string"
      },
      "us_session": {
       "type": "string"
      }
     },
     "description": "Error responses are JSON {error: string, hint?: string}. 400 bad params (never charged); 402 payment required; 404 ticker/market not listed (checked before settlement, never charged); 502 upstream error. Full field docs: /openapi.json."
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/perp-gap-api-tokenized-stock-pool-liquidity-41a34c49/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from perp-gap-api.perpgap.workers.dev](https://www.zero.xyz/host/perp-gap-api.perpgap.workers.dev/llms.txt)
