{
  "openapi": "3.1.0",
  "info": {
    "title": "AETV Media Corp Inquiry API",
    "version": "1.0.0",
    "description": "Public API for submitting a project inquiry to AETV Media Corp. Use the HTML contact form at /contact or POST application/x-www-form-urlencoded fields to /send.php.",
    "contact": {
      "name": "AETV Media Corp",
      "email": "hello@aetvmedia.com",
      "url": "https://aetvmedia.com/contact"
    }
  },
  "servers": [
    {
      "url": "https://aetvmedia.com",
      "description": "Production"
    }
  ],
  "paths": {
    "/send.php": {
      "post": {
        "operationId": "submitInquiry",
        "summary": "Submit a project inquiry",
        "description": "Accepts a project inquiry from the website contact form. Required fields are name, email and message.",
        "requestBody": {
          "required": true,
          "content": {
            "application/x-www-form-urlencoded": {
              "schema": {
                "$ref": "#/components/schemas/Inquiry"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Inquiry accepted and emailed to the studio.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/InquiryResult"
                }
              }
            }
          },
          "405": {
            "description": "Method not allowed. Use POST."
          },
          "422": {
            "description": "Missing name, valid email, or project description."
          },
          "500": {
            "description": "The server could not send the message."
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Inquiry": {
        "type": "object",
        "required": ["name", "email", "message"],
        "properties": {
          "name": { "type": "string" },
          "company": { "type": "string" },
          "email": { "type": "string", "format": "email" },
          "phone": { "type": "string" },
          "website": { "type": "string" },
          "location": { "type": "string" },
          "industry": { "type": "string" },
          "budget": { "type": "string" },
          "services": { "type": "string" },
          "launch": { "type": "string" },
          "style": { "type": "string" },
          "message": { "type": "string" },
          "source": { "type": "string" }
        }
      },
      "InquiryResult": {
        "type": "object",
        "required": ["message"],
        "properties": {
          "message": { "type": "string" }
        }
      }
    }
  }
}
