{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "https://www.thecdsgroups.com/ai-index.schema.json",
  "title": "CDS Group AI Agent Content Index",
  "description": "Structured index of https://www.thecdsgroups.com for AI agent ingestion. Exposes pages, services, case studies, clients, leadership, and tech stack as typed JSON.",
  "type": "object",
  "required": ["site", "generated", "format", "version", "identity", "summary", "sections", "services", "selectedClients", "industriesServed", "globalPresence", "leadership", "caseStudies", "techStack"],
  "properties": {
    "$schema": {
      "type": "string",
      "format": "uri",
      "description": "URI of this JSON Schema for validation."
    },
    "site": {
      "type": "string",
      "format": "uri",
      "description": "Canonical origin of the website. Prepend to relative paths to form full URLs."
    },
    "generated": {
      "type": "string",
      "format": "date-time",
      "description": "ISO 8601 timestamp when this file was last regenerated."
    },
    "format": {
      "type": "string",
      "const": "ai-index",
      "description": "Document format identifier. Always 'ai-index'."
    },
    "version": {
      "type": "string",
      "pattern": "^\\d+\\.\\d+\\.\\d+$",
      "description": "Semantic version of this schema / index format."
    },
    "readme": {
      "type": "object",
      "description": "Agent-facing instructions for interpreting this file.",
      "properties": {
        "purpose": { "type": "string" },
        "howToUse": {
          "type": "array",
          "items": { "type": "string" }
        },
        "fieldTypes": {
          "type": "object",
          "additionalProperties": { "type": "string" }
        },
        "deepLinkRule": { "type": "string" },
        "freshness": { "type": "string" }
      }
    },
    "companion": {
      "type": "object",
      "description": "URLs to related machine-readable files.",
      "properties": {
        "txt": { "type": "string", "format": "uri" },
        "json": { "type": "string", "format": "uri", "description": "Structured JSON companion." },
        "schema": { "type": "string", "format": "uri", "description": "JSON Schema for validation." },
        "llms": { "type": "string", "format": "uri" },
        "llmsFull": { "type": "string", "format": "uri" },
        "sitemap": { "type": "string", "format": "uri" },
        "robots": { "type": "string", "format": "uri" }
      }
    },
    "identity": {
      "type": "object",
      "required": ["name", "url"],
      "properties": {
        "name": { "type": "string", "description": "Brand name." },
        "legalName": { "type": "string", "description": "Registered legal name." },
        "alternateNames": {
          "type": "array",
          "items": { "type": "string" },
          "description": "Other names the company is known by."
        },
        "url": { "type": "string", "format": "uri" },
        "email": { "type": "string", "format": "email" },
        "phone": { "type": "string" },
        "headquarters": { "type": "string" },
        "logo": { "type": "string", "format": "uri" },
        "socialCard": { "type": "string", "format": "uri", "description": "Open Graph / social share image URL." }
      }
    },
    "summary": {
      "type": "string",
      "description": "Citation-ready single-paragraph company description."
    },
    "sections": {
      "type": "array",
      "description": "Top-level public routes of the site.",
      "items": {
        "type": "object",
        "required": ["path", "title", "description"],
        "properties": {
          "path": { "type": "string", "description": "Origin-root-relative path (e.g. '/about')." },
          "title": { "type": "string" },
          "description": { "type": "string" }
        }
      }
    },
    "services": {
      "type": "array",
      "description": "Practice areas / service lines offered.",
      "items": {
        "type": "object",
        "required": ["slug", "title", "description", "url"],
        "properties": {
          "slug": { "type": "string", "description": "URL-safe identifier." },
          "title": { "type": "string" },
          "eyebrow": { "type": "string", "description": "Short tagline or category label." },
          "description": { "type": "string" },
          "url": { "type": "string", "format": "uri" }
        }
      }
    },
    "selectedClients": {
      "type": "array",
      "description": "Enterprise brands CDS has partnered with.",
      "items": {
        "type": "object",
        "required": ["name", "industry", "url"],
        "properties": {
          "name": { "type": "string" },
          "industry": { "type": "string" },
          "url": { "type": "string", "format": "uri", "description": "Canonical homepage of the client brand." }
        }
      }
    },
    "industriesServed": {
      "type": "array",
      "description": "Verticals / industries served.",
      "items": { "type": "string" }
    },
    "globalPresence": {
      "type": "array",
      "description": "Delivery studio / office locations.",
      "items": {
        "type": "object",
        "required": ["country", "region"],
        "properties": {
          "country": { "type": "string" },
          "region": { "type": "string" }
        }
      }
    },
    "leadership": {
      "type": "array",
      "description": "Named leadership team members.",
      "items": {
        "type": "object",
        "required": ["name", "title", "focus"],
        "properties": {
          "name": { "type": "string" },
          "title": { "type": "string" },
          "focus": {
            "type": "array",
            "items": { "type": "string" },
            "description": "Focus areas or specialisations."
          }
        }
      }
    },
    "caseStudies": {
      "type": "array",
      "description": "Published engagement outcomes.",
      "items": {
        "type": "object",
        "required": ["slug", "title", "industry", "service", "summary", "url"],
        "properties": {
          "slug": { "type": "string" },
          "title": { "type": "string" },
          "industry": { "type": "string" },
          "service": { "type": "string", "description": "Primary service line (e.g. 'Product Engineering')." },
          "summary": { "type": "string", "description": "One-paragraph outcome summary." },
          "url": { "type": "string", "format": "uri" },
          "featured": { "type": "boolean", "description": "Whether this case is highlighted on the homepage." }
        }
      }
    },
    "techStack": {
      "type": "array",
      "description": "Core technologies used across engagements.",
      "items": { "type": "string" }
    }
  }
}
