Skip to main content
Glama

rex_api_call

Call any Rex API method with policy enforcement; write operations require an owned or allowlisted session supplied via session or args.session_id.

Instructions

Call any API method (rex api call). Policy class comes from the method table; writes need an owned or allowlisted session via session or args.session_id.

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": {
      "method": "<method>"
    },
    "name": "rex_api_call"
  }
}

Input Schema

NameRequiredDescriptionDefault
argsNo
methodYes
sessionNoSession label or ID

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full disclosure burden. It does useful work by explaining that the policy class is derived from the method table and that write methods are gated on an owned/allowlisted session. It does not describe what a call returns, how errors surface, or whether reads have any restrictions.

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?

Two tight sentences with the gating rule front-loaded. The only waste is the '(rex api call)' parenthetical, which restates the tool name without adding information.

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?

For a generic escape-hatch caller with a free-form nested `args` object and no output schema, an agent still lacks the method-signature mapping and return/error semantics. The policy and session gating are covered, but the core 'what can I put in args' question is left to inference.

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 coverage is only 33% (`session` has a description; `method` and `args` do not). The description partially compensates by revealing that the session ID may be supplied inside args.session_id, a fact absent from the schema. But it says nothing about the shape `method` expects or how `args` maps to the target method's signature, leaving the nested object undocumented.

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?

The description gives a concrete verb+resource: 'Call any API method'. The parenthetical '(rex api call)' merely echoes the tool name. Because no sibling tool is named, an agent cannot tell from the text alone when to use this generic caller instead of rex_action_do or when to first call rex_api_describe.

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?

One real usage rule is given: writes need an owned or allowlisted session, passed via `session` or args.session_id. Missing is discovery guidance (how to find valid method names, e.g., via rex_api_list/rex_api_describe) and any statement about which cases this tool should be preferred over the higher-level rex_action_do.

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