{
  "openapi": "3.1.0",
  "info": {
    "title": "Forgiving Golf public API",
    "version": "1.0.0",
    "summary": "Which golf clubs forgive a miss: irons, drivers, hybrids, woods, putters and complete sets compared on the numbers the makers publish, sorted by price.",
    "termsOfService": "https://forgiving.golf/data",
    "contact": {
      "name": "Forgiving Golf",
      "email": "hello@forgiving.golf"
    }
  },
  "servers": [
    {
      "url": "https://forgiving.golf/"
    }
  ],
  "paths": {
    "/api/v1/latest.json": {
      "get": {
        "summary": "Every club record with its forgiveness cues, shafts, lofts, prices, read dates and source URLs.",
        "parameters": [
          {
            "name": "client",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Optional polite client identifier. Static hosting may record it in edge access logs."
          }
        ],
        "responses": {
          "200": {
            "description": "Every club record with its forgiveness cues, shafts, lofts, prices, read dates and source URLs.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true
                }
              }
            }
          }
        }
      }
    },
    "/api/latest.json": {
      "get": {
        "summary": "Every club record with its forgiveness cues, shafts, lofts, prices, read dates and source URLs.",
        "parameters": [
          {
            "name": "client",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Optional polite client identifier. Static hosting may record it in edge access logs."
          }
        ],
        "responses": {
          "200": {
            "description": "Every club record with its forgiveness cues, shafts, lofts, prices, read dates and source URLs.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "additionalProperties": true
                }
              }
            }
          }
        }
      },
      "x-permanent-alias-for": "/api/v1/latest.json"
    },
    "/api/v1/health.json": {
      "get": {
        "summary": "Dataset freshness and availability",
        "parameters": [
          {
            "name": "client",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Optional polite client identifier. Static hosting may record it in edge access logs."
          }
        ],
        "responses": {
          "200": {
            "description": "Dataset freshness and availability",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "status",
                    "generated_at",
                    "datasets"
                  ],
                  "properties": {
                    "status": {
                      "type": "string",
                      "enum": [
                        "ok",
                        "stale",
                        "unavailable"
                      ]
                    },
                    "generated_at": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "datasets": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "additionalProperties": true
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/health.json": {
      "get": {
        "summary": "Dataset freshness and availability",
        "parameters": [
          {
            "name": "client",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Optional polite client identifier. Static hosting may record it in edge access logs."
          }
        ],
        "responses": {
          "200": {
            "description": "Dataset freshness and availability",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "required": [
                    "status",
                    "generated_at",
                    "datasets"
                  ],
                  "properties": {
                    "status": {
                      "type": "string",
                      "enum": [
                        "ok",
                        "stale",
                        "unavailable"
                      ]
                    },
                    "generated_at": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "datasets": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "additionalProperties": true
                      }
                    }
                  }
                }
              }
            }
          }
        }
      },
      "x-permanent-alias-for": "/api/v1/health.json"
    },
    "/forgiving-golf-clubs.csv": {
      "get": {
        "summary": "One row per club: brand, model, type, category, forgiveness cues, flexes, 7-iron loft, prices, read date and source URL.",
        "parameters": [
          {
            "name": "client",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "description": "Optional polite client identifier. Static hosting may record it in edge access logs."
          }
        ],
        "responses": {
          "200": {
            "description": "One row per club: brand, model, type, category, forgiveness cues, flexes, 7-iron loft, prices, read date and source URL.",
            "content": {
              "text/csv": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    }
  }
}