{
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "title": "FetchIndex vendors.json",
 "type": "object",
 "required": [
  "meta",
  "use_cases",
  "categories",
  "vendors"
 ],
 "properties": {
  "meta": {
   "type": "object"
  },
  "use_cases": {
   "type": "object"
  },
  "categories": {
   "type": "array"
  },
  "vendors": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "id",
     "name",
     "category",
     "official_url",
     "pricing_url",
     "plans",
     "normalized",
     "mcp",
     "fetched_at"
    ],
    "properties": {
     "id": {
      "type": "string"
     },
     "name": {
      "type": "string"
     },
     "category": {
      "type": "string"
     },
     "official_url": {
      "type": "string",
      "format": "uri"
     },
     "pricing_url": {
      "type": "string",
      "format": "uri"
     },
     "plans": {
      "type": "array",
      "items": {
       "type": "object",
       "required": [
        "name",
        "price_usd_month"
       ],
       "properties": {
        "name": {
         "type": "string"
        },
        "price_usd_month": {
         "type": [
          "number",
          "null"
         ]
        },
        "price_usd_month_annual_billing": {
         "type": [
          "number",
          "null"
         ]
        },
        "included": {
         "type": [
          "string",
          "null"
         ]
        },
        "overage": {
         "type": [
          "string",
          "null"
         ]
        }
       }
      }
     },
     "normalized": {
      "type": "array",
      "items": {
       "type": "object",
       "required": [
        "use_case",
        "plan",
        "billing",
        "unit",
        "usd",
        "confidence",
        "calc",
        "formula"
       ],
       "properties": {
        "use_case": {
         "enum": [
          "page_basic",
          "page_js",
          "page_protected",
          "serp",
          "search_ai",
          "content_extract",
          "browser_hour",
          "residential_gb"
         ]
        },
        "billing": {
         "enum": [
          "monthly",
          "annual",
          "payg",
          "prepaid"
         ]
        },
        "unit": {
         "enum": [
          "per_1k_requests",
          "per_hour",
          "per_gb"
         ]
        },
        "usd": {
         "type": "number"
        },
        "monthly_usd": {
         "type": [
          "number",
          "null"
         ]
        },
        "confidence": {
         "enum": [
          "published",
          "component",
          "assumption"
         ]
        },
        "calc": {
         "type": "object",
         "properties": {
          "price_usd": {
           "type": "number"
          },
          "quantity": {
           "type": "number"
          },
          "per_request": {
           "type": "number"
          }
         }
        },
        "formula": {
         "type": "string"
        },
        "assumptions": {
         "type": "array",
         "items": {
          "type": "string"
         }
        }
       }
      }
     },
     "mcp": {
      "type": "object",
      "properties": {
       "supported": {
        "type": [
         "boolean",
         "null"
        ]
       },
       "evidence_url": {
        "type": [
         "string",
         "null"
        ]
       }
      }
     },
     "nulls": {
      "type": "array",
      "items": {
       "type": "object",
       "properties": {
        "field": {
         "type": "string"
        },
        "note": {
         "type": "string"
        }
       }
      }
     },
     "affiliate_relationship": {
      "type": "boolean",
      "description": "True if FetchIndex has an affiliate relationship with this vendor (see /disclosure/). Informational only; never affects prices, rankings or caveats. Absent means false."
     },
     "fetched_at": {
      "type": "string",
      "format": "date"
     }
    }
   }
  }
 }
}