Skip to main content
Glama

Create Chat Completion

post_chat_completions

Creates a model response for the given chat conversation. Group: OpenAI Endpoints. Billing per call: Credits: metered (~927.1 avg).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "post_chat_completions"
  }
}

Input Schema

NameRequiredDescriptionDefault
bodyNoJSON request body. Example: {"model":"gpt-6.1-sol","stream":false,"messages":[{"role":"user","content":"There are ten birds in a tree. A hunter shoots one. How many are left in the tree?"}]}

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / body / description
      Previous value: -"JSON request body. Example: {\"model\":\"gpt-5.6-terra\",\"stream\":false,\"messages\":[{\"role\":\"user\",\"content\":\"How many days in 3 weeks.\"}]}"New value: +"JSON request body. Example: {\"model\":\"gpt-6.1-sol\",\"stream\":false,\"messages\":[{\"role\":\"user\",\"content\":\"There are ten birds in a tree. A hunter shoots one. How many are left in the tree?\"}]}"
  2. Changed1 schema field changed
    • changedInput schema / properties / body / description
      Previous value: -"JSON request body. Example: {\"model\":\"gpt-5-mini\",\"stream\":false,\"messages\":[{\"role\":\"user\",\"content\":\"How many days in 3 weeks.\"}]}"New value: +"JSON request body. Example: {\"model\":\"gpt-5.6-terra\",\"stream\":false,\"messages\":[{\"role\":\"user\",\"content\":\"How many days in 3 weeks.\"}]}"
  3. First observed

TDQS

B3.4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are supplied, so the description carries the full behavioral burden. It does add genuine value by disclosing the cost model ('Billing per call: Credits: metered (~927.1 avg)'), which is a real behavioral trait an agent can use for budget reasoning. However, it omits critical behavior for this endpoint: that it is stateless (no server-side memory), how 'stream' changes the response, and any rate-limit or failure semantics.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

One tight sentence plus two short metadata fragments, front-loaded with the core purpose; nothing is padded. The 'Group: OpenAI Endpoints' tag is boilerplate but cheap, and the billing line earns its place by carrying cost signal.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no annotations, no output schema, and a single nested body parameter, the description is minimal but the schema example patches the most likely misuse. It leaves the agent guessing about the return shape and streaming behavior, which matters for a generation endpoint with no output schema to fall back on.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% and the single 'body' parameter already carries a concrete request example, so the baseline is 3. The description adds nothing about the body beyond what the schema shows — no mention of the model field, message roles, or the stream flag that appears in the example.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: 'Creates a model response for the given chat conversation' — an agent can identify this as the chat-completions endpoint and distinguish it from sibling categories like audio, embeddings, and moderations. It does not explicitly contrast with the closer siblings (post_responses, post_messages), so it stops short of a 5.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied by the phrase 'chat conversation' — there is no explicit when-to-use versus post_responses/post_messages, no note that this is a stateless single-turn request (conversation history must be resent), and no exclusions. An agent must infer the selection criteria from sibling names alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources