{
  "openapi": "3.1.0",
  "info": {
    "title": "Rewa Division Cricket Association (RDCA) Archive API",
    "version": "1.0.0",
    "description": "Public RESTful archive endpoints, Markdown content negotiation, and metadata specifications for the official Rewa Cricket Division database.",
    "contact": {
      "name": "Rewa Division Cricket Association Secretariat",
      "email": "dsywsportsmp@gmail.com",
      "url": "https://rewa-cricket-division.vercel.app"
    },
    "license": {
      "name": "Open Historical Sports Data",
      "url": "https://rewa-cricket-division.vercel.app/about/"
    }
  },
  "servers": [
    {
      "url": "https://rewa-cricket-division.vercel.app",
      "description": "Production edge CDN (Vercel)"
    }
  ],
  "paths": {
    "/": {
      "get": {
        "summary": "Homepage & Latest Highlights",
        "description": "Returns the RDCA homepage. Send Accept: text/markdown for clean LLM-friendly markdown.",
        "responses": {
          "200": {
            "description": "Successful response",
            "headers": {
              "Vary": {
                "schema": {
                  "type": "string",
                  "example": "Accept, Accept-Encoding"
                }
              }
            },
            "content": {
              "text/html": {
                "schema": {
                  "type": "string"
                }
              },
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/matches/": {
      "get": {
        "summary": "Match Directory",
        "description": "List of all recorded cricket matches with filters and scorecard links.",
        "responses": {
          "200": {
            "description": "List of matches",
            "content": {
              "text/html": {
                "schema": {
                  "type": "string"
                }
              },
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/players/": {
      "get": {
        "summary": "Player Registry",
        "description": "Alphabetical directory of all 1,300+ registered Rewa division cricketers.",
        "responses": {
          "200": {
            "description": "Player list",
            "content": {
              "text/html": {
                "schema": {
                  "type": "string"
                }
              },
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/teams/": {
      "get": {
        "summary": "Teams Directory",
        "description": "All 178 teams and franchise squads in Rewa cricket history.",
        "responses": {
          "200": {
            "description": "Team list",
            "content": {
              "text/html": {
                "schema": {
                  "type": "string"
                }
              },
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/tournaments/": {
      "get": {
        "summary": "Tournament Directory",
        "description": "Official tournaments, local cups, and seasonal competitions.",
        "responses": {
          "200": {
            "description": "Tournament list",
            "content": {
              "text/html": {
                "schema": {
                  "type": "string"
                }
              },
              "text/markdown": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/search-index.json": {
      "get": {
        "summary": "Offline Full-Text Search Index",
        "description": "Complete JSON array of all 1,942 pages with titles, paths, and descriptions.",
        "responses": {
          "200": {
            "description": "JSON search catalog",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "path": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "category": {
                        "type": "string"
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/.well-known/mcp": {
      "get": {
        "summary": "Model Context Protocol (MCP) Live Handshake",
        "description": "Handshake endpoint for LLM agents (Claude, ChatGPT) connecting to the RDCA MCP server.",
        "responses": {
          "200": {
            "description": "MCP Server capabilities and tools definition",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/llms.txt": {
      "get": {
        "summary": "LLM Agent Machine Guide",
        "description": "Standard /llms.txt guidance document describing when and how to query the archive.",
        "responses": {
          "200": {
            "description": "Plaintext LLM guide",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    }
  }
}