# CoinGecko On-Chain SOL Token Price (Solana)

> CoinGecko On-Chain SOL Token Price (Solana) is a paid API for AI agents from pro-api.coingecko.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-13).

Fetches the current on-chain USD price and market data for the native Solana (SOL) token (mint So11111111111111111111111111111111111111112) from CoinGecko's Pro API.

## Facts

- Endpoint: GET https://pro-api.coingecko.com/api/v3/x402/onchain/simple/networks/solana/token_price/So11111111111111111111111111111111111111112
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/pro-api-coingecko-com-963930ee
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_RkYFRkI3m3A-3SQaIBEDH

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 pro-api-coingecko-com-963930ee
```

Example prompt: What's the current on-chain price of SOL in USD right now, including its 24-hour volume, market cap, and price change percentage?

## When to prefer this

Use this endpoint when you specifically need the on-chain USD price of the native Solana (SOL) token with optional market data (volume, market cap, 24h change) from CoinGecko's Pro API. Prefer this over general CoinGecko coin price endpoints when you want on-chain DEX-sourced data for SOL rather than aggregated CEX pricing. Ideal for DeFi agents needing real-time SOL valuation.

## Known failure modes

- Payment required (402): x402 micropayment of $0.01 USDC not provided or failed
- Invalid token address: returns 404 or empty result
- Network unavailable or CoinGecko Pro API outage: 503 or timeout
- Rate limit exceeded: 429 Too Many Requests
- Malformed query parameters: 400 Bad Request

## How this service works

Fetches the on-chain USD price for the Solana token mint So11111111111111111111111111111111111111112 via x402 v2.

## Output

Returns a JSON object keyed by the SOL mint address containing the current USD token price, and optionally 24-hour trading volume in USD, market cap in USD, and 24-hour price change percentage. Example: {"So11111111111111111111111111111111111111112": {"usd": 150.25, "usd_24h_vol": 3096660945.57, "usd_market_cap": 1084494857.78, "usd_24h_change": -0.47}}

## Example request

```json
{
 "input": {
  "type": "http",
  "method": "GET",
  "queryParams": {
   "include_24hr_vol": true,
   "include_market_cap": true,
   "include_24hr_price_change": true
  }
 },
 "output": {
  "type": "object",
  "example": {
   "So11111111111111111111111111111111111111112": {
    "usd": 150.25,
    "usd_24h_vol": 5000000000,
    "usd_24h_change": 2.5,
    "usd_market_cap": 50000000000
   }
  }
 }
}
```

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input",
  "output"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "include_24hr_vol": {
       "type": "boolean"
      },
      "mcap_fdv_fallback": {
       "type": "boolean"
      },
      "include_market_cap": {
       "type": "boolean"
      },
      "include_inactive_source": {
       "type": "boolean"
      },
      "include_24hr_price_change": {
       "type": "boolean"
      },
      "include_total_reserve_in_usd": {
       "type": "boolean"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type",
    "example"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/pro-api-coingecko-com-963930ee/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from pro-api.coingecko.com](https://www.zero.xyz/host/pro-api.coingecko.com/llms.txt)
