{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://api-evangelist.github.io/sap-api-management/json-schema/api-proxy.json",
  "title": "SAP API Management API Proxy",
  "description": "Schema for an SAP API Management API Proxy, which fronts a backend service and applies policies for security, transformation, and throttling.",
  "type": "object",
  "required": ["name", "basepath"],
  "properties": {
    "name": {
      "type": "string",
      "description": "Unique identifier for the API proxy",
      "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$",
      "examples": ["OrderManagement", "customer-api-v2"]
    },
    "title": {
      "type": "string",
      "description": "Human-readable display title shown in the developer portal"
    },
    "description": {
      "type": "string",
      "description": "Detailed description of the API proxy's purpose and usage"
    },
    "version": {
      "type": "string",
      "description": "API version string",
      "examples": ["v1", "v2", "1.0"]
    },
    "basepath": {
      "type": "string",
      "description": "Base path for routing incoming requests to this proxy",
      "examples": ["/orders", "/customers/v2"]
    },
    "status": {
      "type": "string",
      "enum": ["Active", "Inactive", "Draft"],
      "description": "Deployment status of the API proxy"
    },
    "apiProviderId": {
      "type": "string",
      "description": "Reference to the API provider (backend system) this proxy fronts"
    },
    "createdAt": {
      "type": "string",
      "format": "date-time",
      "description": "Creation timestamp"
    },
    "modifiedAt": {
      "type": "string",
      "format": "date-time",
      "description": "Last modification timestamp"
    }
  }
}
