{
 "openapi": "3.1.0",
 "info": {
  "title": "base-risk-feed",
  "version": "1.1.0",
  "description": "Free feed of newly created Base token pools, each with a short automated risk verdict (score 0-100, higher = riskier). Full report $0.01 per token via x402. Not investment advice. Fresh data (no 30-minute delay) with the full risk report per token: GET https://base-risk-feed.restockalarm.workers.dev/v1/feed-pro ($0.01 per call via x402, up to 50 tokens, poll with ?since=<next_cursor>) or a credit pack https://base-risk-feed.restockalarm.workers.dev/v1/feed-pro-pack ($0.02 = 20 calls, X-API-Key, valid 7 days).",
  "contact": {
   "name": "Space Command Kits",
   "email": "spacecommand+circle@mail.grokbot.com",
   "url": "https://base-risk-feed.restockalarm.workers.dev/"
  }
 },
 "servers": [
  {
   "url": "https://base-risk-feed.restockalarm.workers.dev"
  }
 ],
 "paths": {
  "/v1/feed-pro": {
   "get": {
    "operationId": "base-token-risk-feed",
    "summary": "Newest Base tokens risk feed",
    "description": "Fresh new Base tokens with the FULL risk report (score breakdown, top holders incl. lockers/vaults, liquidity across all pools, contract flags), no 30-minute delay. Poll cheaply with ?since=<next_cursor>. $0.01 USDC per call via x402 (Base or Polygon), or 2 credits per call with header X-API-Key (credit pack https://base-risk-feed.restockalarm.workers.dev/v1/feed-pro-pack). No charge for failed calls (settled only after a <400 response).",
    "tags": [
     "base-risk-feed"
    ],
    "parameters": [
     {
      "name": "since",
      "in": "query",
      "required": false,
      "description": "Only items checked after this point: ISO 8601 timestamp, unix seconds/ms, or the next_cursor from the previous response. Omit for the latest items.",
      "schema": {
       "type": "string"
      }
     },
     {
      "name": "limit",
      "in": "query",
      "required": false,
      "description": "Max items (default 20, max 50)",
      "schema": {
       "type": "integer",
       "minimum": 1,
       "maximum": 50
      }
     }
    ],
    "x-payment-info": {
     "price": {
      "mode": "fixed",
      "currency": "USDC",
      "amount": "0.010000"
     },
     "protocols": [
      {
       "x402": {}
      }
     ],
     "networks": [
      "eip155:8453",
      "eip155:137"
     ],
     "payTo": "0x7B97303d62517eA9E26D1E1b199Eac42a487F430"
    },
    "x-api-key-credits": 2,
    "responses": {
     "200": {
      "description": "Items (newest first without since; oldest first after since) + next_cursor",
      "content": {
       "application/json": {
        "example": {
         "chain": "base",
         "count": 1,
         "limit": 20,
         "since": "2026-10-28T15:00:00.000Z",
         "next_cursor": "2026-10-28T15:40:48.218Z",
         "has_more": false,
         "delay_minutes": 0,
         "items": [
          {
           "address": "0xdb4274e52bdd18e492035696388c2c1af3a2b68b",
           "symbol": "EXAMPLE",
           "dex": "Uniswap V3",
           "pool_created_at": "2026-10-28T15:21:00.000Z",
           "liquidity_band": "$1k-$10k",
           "checked_at": "2026-10-28T15:40:48.218Z",
           "score": 62,
           "verdict": "caution",
           "report": {
            "score": 62,
            "score_breakdown": {
             "liquidity": 25,
             "holder_concentration": 22,
             "contract_trading": 10,
             "pool_age": 5,
             "news_sentiment": 0
            },
            "liquidity": {
             "level": "thin",
             "band": "$1k-$10k",
             "pools_counted": 1,
             "top_pool": {
              "address": "0x…",
              "share_pct": 100
             },
             "derived_from": "geckoterminal"
            },
            "liquidity_risk": {
             "level": "high",
             "band": "$1k-$10k",
             "pools": 1
            },
            "holder_concentration": {
             "level": "high",
             "top5": [
              {
               "address": "0x…",
               "pct": 41.2,
               "type": "wallet"
              },
              {
               "address": "0x…",
               "pct": 12,
               "type": "locker",
               "label": "UNCX"
              }
             ]
            },
            "contract_flags": {
             "sell_blocked": false,
             "buy_tax_pct": 0,
             "sell_tax_pct": 0,
             "mintable": true,
             "blacklist": false,
             "flags": [
              "mintable"
             ]
            }
           }
          }
         ]
        }
       }
      }
     },
     "400": {
      "description": "Invalid since"
     },
     "402": {
      "description": "Payment Required (x402 v2 header + v1 body)"
     },
     "503": {
      "description": "Store unavailable (not charged)"
     }
    }
   }
  },
  "/v1/feed-pro-pack": {
   "get": {
    "operationId": "getFeedProPack",
    "summary": "Credit pack: X-API-Key with 20 feed-pro calls",
    "description": "Credit pack: one $0.02 x402 payment returns an X-API-Key with 40 credits = 20 feed-pro calls (2 credits per call), valid 7 days. $0.02 USDC via x402. Key shown once.",
    "tags": [
     "base-risk-feed"
    ],
    "x-payment-info": {
     "price": {
      "mode": "fixed",
      "currency": "USDC",
      "amount": "0.020000"
     },
     "protocols": [
      {
       "x402": {}
      }
     ],
     "networks": [
      "eip155:8453",
      "eip155:137"
     ],
     "payTo": "0x7B97303d62517eA9E26D1E1b199Eac42a487F430"
    },
    "responses": {
     "200": {
      "description": "New API key"
     },
     "402": {
      "description": "Payment Required (x402)"
     }
    }
   }
  },
  "/feed.json": {
   "get": {
    "operationId": "getFeedJson",
    "summary": "Free JSON Feed (30-minute delay, 3 calls/day per IP)",
    "description": "Free. Lite verdict only, items at least 30 minutes old. After 3 calls/day per IP: HTTP 402 with the feed-pro offer (no x402 requirements). Header X-Free-Calls-Left.",
    "tags": [
     "base-risk-feed"
    ],
    "responses": {
     "200": {
      "description": "JSON Feed 1.1"
     },
     "402": {
      "description": "Free limit reached: offer"
     }
    }
   }
  },
  "/rss.xml": {
   "get": {
    "operationId": "getRss",
    "summary": "Free RSS 2.0 (30-minute delay)",
    "tags": [
     "base-risk-feed"
    ],
    "responses": {
     "200": {
      "description": "RSS"
     }
    }
   }
  }
 }
}