Elastix · Schema

CreateChatCompletionRequest

Company

Properties

Name Type Description
model string ID of the model to use. See the `/models` endpoint.
messages array The conversation so far, in order.
stream boolean If true, stream the response as server-sent events.
max_tokens integernull Maximum number of tokens to generate in the completion.
temperature number Sampling temperature. Higher is more random.
top_p number Nucleus sampling probability mass.
stop object Sequences where generation stops. String or array of strings.
n integer How many chat completion choices to generate for each input.
seed integernull If set, sampling is made best-effort deterministic so repeated requests with the same seed and parameters return similar results.
reasoning_effort string How hard a reasoning model should think before answering. Only the GPT OSS models support this field; other models ignore it if provided.
frequency_penalty number Penalize new tokens by their existing frequency in the text so far, decreasing verbatim repetition.
presence_penalty number Penalize new tokens that already appear in the text so far, encouraging the model to talk about new topics.
logit_bias objectnull Map of token id to bias value added to the logits before sampling.
response_format objectnull Controls the format of the model's output.
logprobs boolean Whether to return log probabilities of the output tokens.
top_logprobs integernull Number of most likely tokens to return at each position, each with its log probability. Requires `logprobs` to be true.
stream_options objectnull Options for streaming responses. Only used when `stream` is true.
tools array A list of functions the model may call. The model returns the calls it wants to make in the response; your application executes them and sends the results back as `"tool"` messages.
tool_choice object Controls whether and which tool the model calls. `"none"` disables tools, `"auto"` (the default when `tools` are present) lets the model decide, `"required"` forces at least one call, and an object fo
parallel_tool_calls boolean Whether the model may request multiple tool calls in a single turn. Set to false to allow at most one.
metadata objectnull Arbitrary key/value metadata attached to the request. Currently used for session stickiness via `session_id` (experimental).
View JSON Schema on GitHub

JSON Schema

elastix-create-chat-completion-request-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/elastix/json-schema/elastix-create-chat-completion-request-schema.json",
  "title": "CreateChatCompletionRequest",
  "x-generated": "2026-11-29",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/elastix-openapi.json#/components/schemas/CreateChatCompletionRequest",
  "type": "object",
  "required": [
    "model",
    "messages"
  ],
  "properties": {
    "model": {
      "type": "string",
      "description": "ID of the model to use. See the `/models` endpoint."
    },
    "messages": {
      "type": "array",
      "minItems": 1,
      "items": {
        "$ref": "#/$defs/ChatMessage"
      },
      "description": "The conversation so far, in order."
    },
    "stream": {
      "type": "boolean",
      "default": false,
      "description": "If true, stream the response as server-sent events."
    },
    "max_tokens": {
      "type": [
        "integer",
        "null"
      ],
      "minimum": 1,
      "description": "Maximum number of tokens to generate in the completion."
    },
    "temperature": {
      "type": "number",
      "minimum": 0,
      "default": 1,
      "description": "Sampling temperature. Higher is more random."
    },
    "top_p": {
      "type": "number",
      "exclusiveMinimum": 0,
      "maximum": 1,
      "default": 1,
      "description": "Nucleus sampling probability mass."
    },
    "stop": {
      "description": "Sequences where generation stops. String or array of strings.",
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        {
          "type": "null"
        }
      ]
    },
    "n": {
      "type": "integer",
      "minimum": 1,
      "default": 1,
      "description": "How many chat completion choices to generate for each input."
    },
    "seed": {
      "type": [
        "integer",
        "null"
      ],
      "description": "If set, sampling is made best-effort deterministic so repeated requests with the same seed and parameters return similar results."
    },
    "reasoning_effort": {
      "type": "string",
      "enum": [
        "low",
        "medium",
        "high"
      ],
      "default": "medium",
      "description": "How hard a reasoning model should think before answering. Only the GPT OSS models support this field; other models ignore it if provided."
    },
    "frequency_penalty": {
      "type": "number",
      "minimum": -2,
      "maximum": 2,
      "default": 0,
      "description": "Penalize new tokens by their existing frequency in the text so far, decreasing verbatim repetition."
    },
    "presence_penalty": {
      "type": "number",
      "minimum": -2,
      "maximum": 2,
      "default": 0,
      "description": "Penalize new tokens that already appear in the text so far, encouraging the model to talk about new topics."
    },
    "logit_bias": {
      "type": [
        "object",
        "null"
      ],
      "additionalProperties": {
        "type": "number"
      },
      "description": "Map of token id to bias value added to the logits before sampling."
    },
    "response_format": {
      "type": [
        "object",
        "null"
      ],
      "properties": {
        "type": {
          "type": "string",
          "enum": [
            "text",
            "json_object"
          ],
          "default": "text",
          "description": "`json_object` constrains the model to emit valid JSON."
        }
      },
      "description": "Controls the format of the model's output."
    },
    "logprobs": {
      "type": "boolean",
      "default": false,
      "description": "Whether to return log probabilities of the output tokens."
    },
    "top_logprobs": {
      "type": [
        "integer",
        "null"
      ],
      "minimum": 0,
      "maximum": 20,
      "description": "Number of most likely tokens to return at each position, each with its log probability. Requires `logprobs` to be true."
    },
    "stream_options": {
      "type": [
        "object",
        "null"
      ],
      "properties": {
        "include_usage": {
          "type": "boolean",
          "description": "If true, a final SSE chunk before `[DONE]` carries token usage."
        }
      },
      "description": "Options for streaming responses. Only used when `stream` is true."
    },
    "tools": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Tool"
      },
      "description": "A list of functions the model may call. The model returns the calls it wants to make in the response; your application executes them and sends the results back as `\"tool\"` messages."
    },
    "tool_choice": {
      "description": "Controls whether and which tool the model calls. `\"none\"` disables tools, `\"auto\"` (the default when `tools` are present) lets the model decide, `\"required\"` forces at least one call, and an object forces a specific function.",
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "none",
            "auto",
            "required"
          ]
        },
        {
          "$ref": "#/$defs/ToolChoiceFunction"
        }
      ]
    },
    "parallel_tool_calls": {
      "type": "boolean",
      "default": true,
      "description": "Whether the model may request multiple tool calls in a single turn. Set to false to allow at most one."
    },
    "metadata": {
      "type": [
        "object",
        "null"
      ],
      "properties": {
        "session_id": {
          "type": "string",
          "description": "**Experimental — subject to change.** Stable conversation id used to optimize multi-turn routing: requests that share a session_id are routed on a best-effort basis to the server that served the previous turn to optimize prompt caching. This is used as an additional signal to content based routing."
        }
      },
      "description": "Arbitrary key/value metadata attached to the request. Currently used for session stickiness via `session_id` (experimental)."
    }
  },
  "$defs": {
    "ChatMessage": {
      "type": "object",
      "required": [
        "role",
        "content"
      ],
      "properties": {
        "role": {
          "type": "string",
          "enum": [
            "system",
            "developer",
            "user",
            "assistant",
            "tool"
          ],
          "description": "The author of the message. `\"developer\"` is an alias for `\"system\"` and is treated identically. A system/developer message is optional, but if present it must be the first message in the array. Use `\"tool\"` to return the result of a tool call back to the model."
        },
        "content": {
          "type": [
            "string",
            "null"
          ],
          "description": "The message text. Text only — image (vision) and audio content are not supported yet (both planned). May be `null` on an assistant message that only requests tool calls (see `tool_calls`)."
        },
        "tool_calls": {
          "type": "array",
          "description": "Tool calls the model wants to make. Present only on an assistant message; when set, `content` is typically `null`.",
          "items": {
            "$ref": "#/$defs/ToolCall"
          }
        },
        "tool_call_id": {
          "type": "string",
          "description": "Required on a `\"tool\"` message: the `id` of the tool call this message provides the result for."
        }
      }
    },
    "Tool": {
      "type": "object",
      "required": [
        "type",
        "function"
      ],
      "description": "A function the model may call.",
      "properties": {
        "type": {
          "type": "string",
          "const": "function",
          "description": "The tool type. Only `function` is supported."
        },
        "function": {
          "type": "object",
          "required": [
            "name",
            "description"
          ],
          "properties": {
            "name": {
              "type": "string",
              "description": "The function name. Must match `^[a-zA-Z0-9_-]+$`; this is the name the model returns when it calls the tool."
            },
            "description": {
              "type": "string",
              "description": "What the function does. The model uses this to decide when and how to call it, so make it descriptive. **Required** — unlike the OpenAI spec, our backend rejects a tool with no description."
            },
            "parameters": {
              "type": "object",
              "description": "The function's parameters as a JSON Schema object — see [OpenAI's function calling guide](https://developers.openai.com/api/docs/guides/function-calling). Optional: for a function that takes no arguments, omit it or pass an empty schema `{ \"type\": \"object\", \"properties\": {} }`."
            }
          }
        }
      }
    },
    "ToolCall": {
      "type": "object",
      "required": [
        "id",
        "type",
        "function"
      ],
      "description": "A tool call requested by the model.",
      "properties": {
        "id": {
          "type": "string",
          "description": "Identifier for this call. Echo it back as `tool_call_id` on the `\"tool\"` message that carries the result."
        },
        "type": {
          "type": "string",
          "const": "function"
        },
        "function": {
          "type": "object",
          "required": [
            "name",
            "arguments"
          ],
          "properties": {
            "name": {
              "type": "string"
            },
            "arguments": {
              "type": "string",
              "description": "The call arguments as a JSON-encoded string (not a JSON object). Parse it before use; the model may occasionally emit invalid JSON."
            }
          }
        }
      }
    },
    "ToolChoiceFunction": {
      "type": "object",
      "required": [
        "type",
        "function"
      ],
      "description": "Forces the model to call a specific function.",
      "properties": {
        "type": {
          "type": "string",
          "const": "function"
        },
        "function": {
          "type": "object",
          "required": [
            "name"
          ],
          "properties": {
            "name": {
              "type": "string"
            }
          }
        }
      }
    }
  }
}

Work with this as data

Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for schemas

4 MCP tools reach this
  • find_json_schemasBrowse and filter every JSON Schema in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/elastix-create-chat-completion-request"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.