{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/axonflow/json-schema/axonflow-chat-completion-request-schema.json",
  "title": "ChatCompletionRequest",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/axonflow-openai-compatible-api-openapi.yml#/components/schemas/ChatCompletionRequest",
  "type": "object",
  "required": [
    "model",
    "messages"
  ],
  "properties": {
    "model": {
      "type": "string",
      "description": "ID of the model to use (e.g. gpt-4o, gpt-4o-mini)."
    },
    "messages": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "role",
          "content"
        ],
        "properties": {
          "role": {
            "type": "string",
            "enum": [
              "system",
              "user",
              "assistant",
              "tool"
            ]
          },
          "content": {
            "description": "Message content (string or array for multimodal)."
          },
          "name": {
            "type": "string"
          },
          "tool_calls": {
            "type": "array",
            "items": {
              "type": "object"
            }
          },
          "tool_call_id": {
            "type": "string"
          }
        }
      },
      "minItems": 1
    },
    "temperature": {
      "type": "number",
      "minimum": 0,
      "maximum": 2
    },
    "top_p": {
      "type": "number"
    },
    "max_tokens": {
      "type": "integer"
    },
    "max_completion_tokens": {
      "type": "integer"
    },
    "stream": {
      "type": "boolean",
      "description": "Must be false or omitted. Streaming is not supported in this\nrelease; setting stream=true returns HTTP 400.\n"
    },
    "stop": {
      "description": "Up to 4 stop sequences."
    },
    "presence_penalty": {
      "type": "number"
    },
    "frequency_penalty": {
      "type": "number"
    },
    "user": {
      "type": "string"
    },
    "response_format": {
      "type": "object"
    },
    "seed": {
      "type": "integer"
    },
    "tools": {
      "type": "array",
      "items": {
        "type": "object"
      }
    },
    "tool_choice": {
      "description": "Tool choice configuration."
    }
  }
}