{
  "openapi": "3.1.0",
  "info": {
    "title": "Este Training Academy Public Data API",
    "version": "1.0.0",
    "summary": "Read-only JSON feeds describing Este Training Academy and its course catalogue.",
    "description": "A public, unauthenticated, read-only API for AI agents and integrators. It exposes the organisation profile, the course catalogue and the course categories as static JSON over HTTPS. Course fees are not published: they vary by qualification and are confirmed on enquiry via the contact page or +44 121 468 6435. There are no write endpoints and no online checkout.",
    "contact": {
      "name": "Este Training Academy admissions",
      "url": "https://www.estetrainingacademy.com/contact"
    },
    "license": { "name": "Content \u00a9 Este Training Academy \u2014 cite with attribution" }
  },
  "servers": [{ "url": "https://www.estetrainingacademy.com", "description": "Production" }],
  "tags": [
    { "name": "organization", "description": "Who we are and how to reach us" },
    { "name": "courses", "description": "Course catalogue" }
  ],
  "paths": {
    "/api/organization.json": {
      "get": {
        "operationId": "getOrganization",
        "tags": ["organization"],
        "summary": "Get the organisation profile",
        "description": "Returns name, description, address, phone number, accreditations, pricing model and links to every machine-readable interface.",
        "responses": {
          "200": {
            "description": "Organisation profile",
            "content": {
              "application/json": { "schema": { "$ref": "#/components/schemas/Organization" } }
            }
          }
        }
      }
    },
    "/api/courses.json": {
      "get": {
        "operationId": "listCourses",
        "tags": ["courses"],
        "summary": "List all courses",
        "description": "Returns every course with its slug, title, level, duration, categories, locations, summary and page URL.",
        "responses": {
          "200": {
            "description": "Course catalogue",
            "content": {
              "application/json": { "schema": { "$ref": "#/components/schemas/CourseList" } }
            }
          }
        }
      }
    },
    "/api/categories.json": {
      "get": {
        "operationId": "listCategories",
        "tags": ["courses"],
        "summary": "List all course categories",
        "responses": {
          "200": {
            "description": "Category list",
            "content": {
              "application/json": { "schema": { "$ref": "#/components/schemas/CategoryList" } }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Organization": {
        "type": "object",
        "required": ["name", "url", "telephone"],
        "properties": {
          "name": { "type": "string" },
          "url": { "type": "string", "format": "uri" },
          "description": { "type": "string" },
          "telephone": { "type": "string" },
          "address": {
            "type": "object",
            "properties": {
              "streetAddress": { "type": "string" },
              "addressLocality": { "type": "string" },
              "addressRegion": { "type": "string" },
              "postalCode": { "type": "string" },
              "addressCountry": { "type": "string" }
            }
          },
          "accreditations": { "type": "array", "items": { "type": "string" } },
          "pricing": {
            "type": "object",
            "properties": {
              "model": { "type": "string", "enum": ["quote"] },
              "currency": { "type": "string" },
              "description": { "type": "string" },
              "enquiryUrl": { "type": "string", "format": "uri" }
            }
          }
        }
      },
      "Course": {
        "type": "object",
        "required": ["slug", "title", "level", "url"],
        "properties": {
          "slug": { "type": "string", "examples": ["pdo-thread-course"] },
          "title": { "type": "string" },
          "level": { "type": "string", "enum": ["Introduction", "Intermediate", "Advanced"] },
          "duration": { "type": ["string", "null"] },
          "categories": { "type": "array", "items": { "type": "string" } },
          "locations": { "type": "array", "items": { "type": "string" } },
          "summary": { "type": "string" },
          "url": { "type": "string", "format": "uri" }
        }
      },
      "CourseList": {
        "type": "object",
        "properties": {
          "version": { "type": "string" },
          "updated": { "type": "string", "format": "date" },
          "count": { "type": "integer" },
          "pricing": { "type": "string" },
          "courses": { "type": "array", "items": { "$ref": "#/components/schemas/Course" } }
        }
      },
      "Category": {
        "type": "object",
        "required": ["slug", "name", "url"],
        "properties": {
          "slug": { "type": "string" },
          "name": { "type": "string" },
          "url": { "type": "string", "format": "uri" }
        }
      },
      "CategoryList": {
        "type": "object",
        "properties": {
          "version": { "type": "string" },
          "updated": { "type": "string", "format": "date" },
          "count": { "type": "integer" },
          "categories": { "type": "array", "items": { "$ref": "#/components/schemas/Category" } }
        }
      }
    }
  }
}
