Skip to main content
Glama

router_chat_completions

Sends OpenAI-compatible chat completion requests to a specified model using message JSON and optional tools, returning model responses for agent or chatbot workflows.

Instructions

OpenAI-compatible chat completions

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "model": "<model>",
      "messages_json": "<messages_json>"
    },
    "name": "router_chat_completions"
  }
}

Input Schema

NameRequiredDescriptionDefault
modelYesModel ID
max_tokensNoMax tokens
tools_jsonNoJSON array of tools
temperatureNoTemperature
messages_jsonYesJSON array of messages

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.0.0

TDQS

C2.3/5.0
Behavior1/5

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

No annotations are supplied, so the description carries the full burden of behavioral disclosure and provides essentially none. It says nothing about cost, latency, streaming behavior, whether the call is billed or rate-limited, model routing semantics, or what errors look like for an inference tool. 'OpenAI-compatible' hints at payload conventions but discloses no operational traits.

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

Conciseness3/5

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

At five words the description contains no waste, but it is under-specified rather than concise, so it does not earn the top of the scale. There is no structure because there is effectively one phrase.

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

Completeness2/5

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

This is a complex inference tool with five parameters, no annotations, and no output schema, so the description should explain at minimum the return shape and the JSON-string payload conventions. 'OpenAI-compatible' gestures at the contract but leaves an agent guessing about response format and limits. It is far from sufficient given the tool's complexity.

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%, so each of the five parameters already has a documented meaning in the schema. The description adds no additional semantics such as the expected JSON shape of messages_json or tools_json, or how model interacts with routing. Baseline 3 applies when the schema does the work.

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

Purpose3/5

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

The description adds 'OpenAI-compatible' to the name, which tells an agent the request/response shape mirrors the OpenAI chat completions API. However, it never states in plain terms that the tool sends a message list to a model and returns a completion, and it does not distinguish itself from siblings like router_completions or router_embeddings. Purpose is only implied by the name.

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

Usage Guidelines2/5

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

There is no when-to-use guidance and no mention of alternatives such as router_completions for legacy prompt-style calls or router_embeddings for vectorization. An agent must infer that this is the conversational/multi-message path purely from the word 'chat' in the name, which the description itself does not reinforce.

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

Deploy Server

Other Tools