# CoinGecko Pro On-Chain WETH Price (Ethereum)

> CoinGecko Pro On-Chain WETH Price (Ethereum) is a paid API for AI agents from pro-api.coingecko.com, paid per call via x402, $0.010000/call, status unknown (last checked 2026-10-11).

Fetches the real-time on-chain price for WETH (Wrapped Ether) on Ethereum mainnet by contract address via CoinGecko Pro.

## Facts

- Endpoint: GET https://pro-api.coingecko.com/api/v3/x402/onchain/simple/networks/eth/token_price/0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2?utm_source=zero.xyz
- Price: $0.010000/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-11
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/pro-api-coingecko-com-2e506987
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Mr4F_HU8QzkIa9aKAoVs5

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-2e506987
```

Example prompt: What's the current on-chain price of WETH on Ethereum right now, and can you also include its 24-hour price change and trading volume?

## When to prefer this

Use this endpoint when you specifically need the real-time on-chain DEX price of WETH on Ethereum mainnet from CoinGecko's Pro API, especially when you need DEX-sourced pricing (not centralized exchange pricing) with optional market data like 24hr volume or market cap. Prefer this over generic coin price endpoints when you need on-chain data tied to a specific contract address rather than a coin ID.

## Known failure modes

- Payment not received or x402 payment protocol failure — endpoint returns 402 Payment Required
- Invalid or unsupported contract address — returns 404 or empty result
- Network not supported — returns error if network identifier is incorrect
- Rate limit exceeded — returns 429 Too Many Requests
- Stale or missing on-chain liquidity data — price may be unavailable for illiquid tokens

## How this service works

Fetches the real-time on-chain price for WETH (0xC02aaa39b223fe8d0a0e5c4f27ead9083c756cc2) on Ethereum via CoinGecko Pro x402.

## Output

Returns the real-time on-chain price of WETH (0xC02aaa39b223fe8d0a0e5c4f27ead9083c756cc2) on Ethereum, along with optional fields such as 24hr trading volume, market cap, 24hr price change percentage, and total reserve in USD — sourced from CoinGecko's on-chain DEX data.

## Example request

```json
{
 "input": {
  "type": "http",
  "method": "GET",
  "queryParams": {
   "include_24hr_vol": true,
   "mcap_fdv_fallback": false,
   "include_market_cap": false,
   "include_inactive_source": false,
   "include_24hr_price_change": true,
   "include_total_reserve_in_usd": false
  }
 },
 "output": {
  "type": "object",
  "example": {
   "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2": {
    "eth": {
     "price": 2500.5,
     "24h_vol": 1500000000,
     "24h_price_change_percentage": 2.35
    }
   }
  }
 }
}
```

## 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"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "data"
 ],
 "properties": {
  "data": {
   "type": "object",
   "required": [
    "id",
    "type",
    "attributes"
   ],
   "properties": {
    "id": {
     "type": "string"
    },
    "type": {
     "type": "string"
    },
    "attributes": {
     "type": "object",
     "required": [
      "token_prices",
      "h24_volume_usd",
      "h24_price_change_percentage"
     ],
     "properties": {
      "token_prices": {
       "type": "object",
       "required": [
        "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2"
       ],
       "properties": {
        "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2": {
         "type": "string"
        }
       }
      },
      "h24_volume_usd": {
       "type": "object",
       "required": [
        "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2"
       ],
       "properties": {
        "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2": {
         "type": "string"
        }
       }
      },
      "h24_price_change_percentage": {
       "type": "object",
       "required": [
        "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2"
       ],
       "properties": {
        "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2": {
         "type": "string"
        }
       }
      }
     }
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/pro-api-coingecko-com-2e506987/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)
