{
  "openapi": "3.1.0",
  "info": {
    "title": "Meridian Observatory API",
    "version": "1.4.2",
    "summary": "Public read-only access to atmospheric time-series and station metadata.",
    "description": "Environmental monitoring data collected by the Meridian station network. All endpoints are unauthenticated and GET-only.",
    "contact": { "name": "Meridian Data", "url": "https://alreadyowned.top" },
    "license": { "name": "CC-BY-4.0", "url": "https://creativecommons.org/licenses/by/4.0/" }
  },
  "servers": [{ "url": "https://api.alreadyowned.top", "description": "Production" }],
  "paths": {
    "/v1": {
      "get": {
        "operationId": "getRoot",
        "summary": "API root with resource links",
        "responses": { "200": { "description": "Root document", "content": { "application/json": {} } } }
      }
    },
    "/v1/health": {
      "get": { "operationId": "getHealth", "summary": "Service health probe",
        "responses": { "200": { "description": "Health status", "content": { "application/json": {} } } } }
    },
    "/v1/status": {
      "get": { "operationId": "getStatus", "summary": "Operational status and ingest lag",
        "responses": { "200": { "description": "Status", "content": { "application/json": {} } } } }
    },
    "/v1/stations": {
      "get": { "operationId": "listStations", "summary": "List monitoring stations",
        "responses": { "200": { "description": "Station collection", "content": { "application/json": {} } } } }
    },
    "/v1/stations/{id}": {
      "get": { "operationId": "getStation", "summary": "Station detail",
        "parameters": [{ "name": "id", "in": "path", "required": true, "schema": { "type": "string" } }],
        "responses": { "200": { "description": "Station", "content": { "application/json": {} } },
                       "404": { "description": "Unknown station" } } }
    },
    "/v1/series": {
      "get": { "operationId": "listSeries", "summary": "Dataset catalog",
        "responses": { "200": { "description": "Series index", "content": { "application/json": {} } } } }
    },
    "/v1/series/{id}": {
      "get": { "operationId": "getSeries", "summary": "Time-series values",
        "parameters": [
          { "name": "id", "in": "path", "required": true, "schema": { "type": "string" } },
          { "name": "start", "in": "query", "required": false, "schema": { "type": "string", "format": "date-time" } },
          { "name": "interval", "in": "query", "required": false, "schema": { "type": "string", "enum": ["1h", "1d"] } }
        ],
        "responses": { "200": { "description": "Series", "content": { "application/json": {} } },
                       "404": { "description": "Unknown series" } } }
    }
  }
}
