# Cyber Chain API
> Live on-chain data for Cyber mainnet (an Ethereum L2 by CyberConnect, native ETH) via Blockscout — no key. Read network stats (block height, total transactions, gas), a gas oracle in gwei, the most recent blocks and full block detail by height or hash, any address balance and contract info, full transaction detail, ERC-20 token detail by contract, and a universal search across addresses, tokens, blocks and transactions. Real Layer-2 chain data with the rotating proxy as automatic fallback — 9 endpoints. Ideal for wallets, explorers, portfolio trackers, analytics dashboards and on-chain monitoring on Cyber.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/cyber-api/..."
```

## Pricing
- **Free** (Free) — 4,800 calls/Mo, 2 req/s
- **Basic** ($8/Mo) — 108,000 calls/Mo, 8 req/s
- **Pro** ($26/Mo) — 600,000 calls/Mo, 20 req/s
- **Mega** ($71/Mo) — 3,000,000 calls/Mo, 50 req/s

## Endpoints

### Network

#### `GET /v1/gas` — Gas oracle (gwei)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/gas"
```

**Response:**
```json
{
    "data": {
        "fast": 0.01,
        "slow": 0.01,
        "unit": "gwei",
        "average": 0.01,
        "gas_used_today": "2142421892"
    },
    "meta": {
        "timestamp": "2026-06-08T18:26:21.357Z",
        "request_id": "92aca3cf-7127-4eda-abe3-ca292b1702cf"
    },
    "status": "ok",
    "message": "Gas retrieved successfully",
    "success": true
}
```

#### `GET /v1/stats` — Network stats

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/stats"
```

**Response:**
```json
{
    "data": {
        "tvl_usd": null,
        "gas_prices": {
            "fast": 0.01,
            "slow": 0.01,
            "average": 0.01
        },
        "total_blocks": 33757127,
        "coin_price_usd": null,
        "gas_used_today": "2142421892",
        "market_cap_usd": 0,
        "total_addresses": "1982855",
        "total_transactions": "66154365",
        "transactions_today": "46280",
        "network_utilization_percent": 0.16668613333333332
    },
    "meta": {
        "timestamp": "2026-06-08T18:26:21.637Z",
        "request_id": "118b54d9-528d-4aff-84f6-b882319369fb"
    },
    "status": "ok",
    "message": "Stats retrieved successfully",
    "success": true
}
```

### Blocks

#### `GET /v1/block` — Block detail by height or hash

**Parameters:**
- `height` (query, optional, string) — Block height Example: `33744000`
- `hash` (query, optional, string) — Block hash (0x + 64 hex)

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/block?height=33744000"
```

**Response:**
```json
{
    "data": {
        "block": {
            "hash": "0x1277a56018627463230526c5b6b1d0b5fce277c17279a66bec254380471a2662",
            "size": 849,
            "miner": "0x4200000000000000000000000000000000000011",
            "height": 33744000,
            "gas_used": 43827,
            "tx_count": 1,
            "gas_limit": 30000000,
            "timestamp": "2026-06-08T11:02:47.000000Z",
            "burnt_fees": "11044404",
            "difficulty": "0",
            "base_fee_per_gas": "252"
        }
    },
    "meta": {
        "timestamp": "2026-06-08T18:26:21.904Z",
        "request_id": "0e990634-3838-407c-a54b-e5414ecd6106"
    },
    "status": "ok",
    "message": "Block retrieved successfully",
    "success": true
}
```

#### `GET /v1/blocks` — Most recent blocks

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/blocks"
```

**Response:**
```json
{
    "data": {
        "count": 50,
        "blocks": [
            {
                "hash": "0x667e271f8f50e20066cac0bb2590b7c25e66d37b2cf1ef3acf02e22b200fecec",
                "size": 849,
                "miner": "0x4200000000000000000000000000000000000011",
                "height": 33757306,
                "gas_used": 43827,
                "tx_count": 1,
                "gas_limit": 30000000,
                "timestamp": "2026-06-08T18:26:19.000000Z",
                "burnt_fees": "11044404",
                "difficulty": "0",
                "base_fee_per_gas": "252"
            },
            {
                "hash": "0xa80990dd414dd4aa02e6d2a46bffe2b000abf485a71ab79bddf25d43a2bcd613",
                "size": 849,
                "miner": "0x4200000000000000000000000000000000000011",
                "height": 33757305,
                "gas_used": 43827,
                "tx_count": 1,
                "gas_limit": 30000000,
                "timestamp": "2026-06-08T18:26:17.000000Z",
                "burnt_fees": "11044404",
                "difficulty": "0",
                "base_fee_per_gas": "252"
            },
            {
                "hash": "0xf7ccc0aa104c2ce36b4a4ebef8e6438d2aca3c3668667ed0911c1861f8c3575a",
                "size": 849,
                "miner": "0x4200000000000000000000000000000000000011",
                "height": 33757304,
                "gas_used": 43827,
                "tx_count": 1,
                "gas_limit": 30000000,
        
…(truncated, see openapi.json for full schema)
```

### Accounts

#### `GET /v1/address` — Address balance & contract info

**Parameters:**
- `address` (query, required, string) — Address (0x + 40 hex) Example: `0x9B6cB5ee13014110211304De0C5CEE1D9410a67f`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/address?address=0x9B6cB5ee13014110211304De0C5CEE1D9410a67f"
```

**Response:**
```json
{
    "data": {
        "address": {
            "ens": null,
            "hash": "0x9B6cB5ee13014110211304De0C5CEE1D9410a67f",
            "name": null,
            "token": null,
            "creator": null,
            "balance_eth": 6.23025985e-10,
            "balance_wei": "623025985",
            "is_contract": false,
            "is_verified": false
        }
    },
    "meta": {
        "timestamp": "2026-06-08T18:26:22.967Z",
        "request_id": "e01931eb-69ff-43ad-aa08-e2f7f3cfef7b"
    },
    "status": "ok",
    "message": "Address retrieved successfully",
    "success": true
}
```

#### `GET /v1/transaction` — Transaction detail

**Parameters:**
- `hash` (query, required, string) — Transaction hash (0x + 64 hex) Example: `0x6db1be00de1341301a79ebbe330bd147a15335f32300e9ee6a6333dce2ac18a1`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/transaction?hash=0x6db1be00de1341301a79ebbe330bd147a15335f32300e9ee6a6333dce2ac18a1"
```

**Response:**
```json
{
    "data": {
        "transaction": {
            "to": "0x4cD00E387622C35bDDB9b4c962C136462338BC31",
            "from": "0x9B6cB5ee13014110211304De0C5CEE1D9410a67f",
            "hash": "0x6db1be00de1341301a79ebbe330bd147a15335f32300e9ee6a6333dce2ac18a1",
            "type": 0,
            "block": 33744388,
            "nonce": 111,
            "method": "0x49290c1c",
            "status": "ok",
            "fee_eth": 9.077618e-12,
            "fee_wei": "9077618",
            "gas_used": 24812,
            "gas_price": "352",
            "timestamp": "2026-06-08T11:15:43.000000Z",
            "value_eth": 0.000191253576779778,
            "value_wei": "191253576779778",
            "confirmations": 12919
        }
    },
    "meta": {
        "timestamp": "2026-06-08T18:26:23.328Z",
        "request_id": "27b8d9ca-6871-419a-8b13-085bab4156bf"
    },
    "status": "ok",
    "message": "Transaction retrieved successfully",
    "success": true
}
```

### Tokens

#### `GET /v1/token` — ERC-20 token detail

**Parameters:**
- `address` (query, required, string) — Token contract (0x + 40 hex) Example: `0x14778860E937f509e651192a90589dE711Fb88a9`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/token?address=0x14778860E937f509e651192a90589dE711Fb88a9"
```

**Response:**
```json
{
    "data": {
        "token": {
            "icon": null,
            "name": "CyberConnect",
            "type": "ERC-20",
            "symbol": "CYBER",
            "address": "0x14778860E937f509e651192a90589dE711Fb88a9",
            "holders": 92844,
            "decimals": 18,
            "total_supply": "7382792573788317536879913",
            "exchange_rate_usd": null,
            "circulating_market_cap": null
        }
    },
    "meta": {
        "timestamp": "2026-06-08T18:26:23.622Z",
        "request_id": "2ea0ab9c-38a6-45d6-b565-fe799698acc9"
    },
    "status": "ok",
    "message": "Token retrieved successfully",
    "success": true
}
```

### Search

#### `GET /v1/search` — Universal search

**Parameters:**
- `q` (query, required, string) — Address, token, block or tx Example: `cyber`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/search?q=cyber"
```

**Response:**
```json
{
    "data": {
        "count": 50,
        "query": "cyber",
        "results": [
            {
                "name": "CyberArticle",
                "type": "token",
                "symbol": "CyberArticle-NFT",
                "address": "0x601B0206c70182bFC31306cB3D487433a2A67007"
            },
            {
                "name": "Cybersapien",
                "type": "token",
                "symbol": "CS",
                "address": "0x88B9f0Ce8336A04aBe581918AB38532f8c3cfc2e"
            },
            {
                "name": "CyberID",
                "type": "token",
                "symbol": "CYBERID",
                "address": "0xC137Be6B59E824672aaDa673e55Cf4D150669af8"
            },
            {
                "name": "CyberProject",
                "type": "token",
                "symbol": "CyberProject-NFT",
                "address": "0x2d9181b954736971bb74043d4782dFe93b55a9af"
            },
            {
                "name": "CyberProject",
                "type": "token",
                "symbol": "CyberProject-NFT",
                "address": "0x5239edBdAFEdDD6A6659E74A99Bf99eD32717184"
            },
            {
                "name": "CyberConnect",
                "type": "token",
                "symbol": "CYBER",
                "address": "0x14778860E937f509e651192a90589dE711Fb88a9"
            },
            {
                "name": "Cyber: The New Era",
                "type": "token",
                "symbol": "CYBERNEWERA",
  
…(truncated, see openapi.json for full schema)
```

### Meta

#### `GET /v1/meta` — Spec

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/cyber-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "service": "cyber-api",
        "endpoints": {
            "GET /v1/gas": "Gas oracle (slow/average/fast in gwei).",
            "GET /v1/meta": "This document.",
            "GET /v1/block": "Block detail by height= or hash=.",
            "GET /v1/stats": "Network stats (blocks, txns, coin price, market cap, gas).",
            "GET /v1/token": "ERC-20 token detail by contract (address=).",
            "GET /v1/blocks": "The most recent blocks.",
            "GET /v1/search": "Search addresses, tokens, blocks & txns (q=).",
            "GET /v1/address": "Address balance & contract info (address=).",
            "GET /v1/transaction": "Transaction detail (hash=)."
        },
        "description": "Live Cyber (ETH) L2 on-chain data via Blockscout: network stats, a gas oracle (gwei), recent blocks and block detail, address balances, transaction detail, ERC-20 token detail and a universal search across addresses, tokens, blocks and transactions. Real on-chain data, no key."
    },
    "meta": {
        "timestamp": "2026-06-08T18:26:23.971Z",
        "request_id": "0241d2b1-d903-4d20-aedf-bb0ae8f226b2"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/cyber-api
OpenAPI spec: https://www.oanor.com/api/cyber-api/openapi.json
