Skip to main content
Glama

AI gateway keys

ai.keys
Read-onlyIdempotent

The AI gateway for this branch: its keys' daily and monthly caps and usage, and which providers are connected. Never returns a key. Scope: keys:read.

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": "ai.keys"
  }
}

Input Schema

NameRequiredDescriptionDefault
branchNoBranch (environment) id. Optional: defaults to `production`.
project_idNoProject id. Optional: defaults to the project used last in this session, or the only one.
organization_idNoOrganization id. Optional: defaults to the token's organization, or the only one you belong to.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already establish this as a read-only, idempotent, closed-world operation, so the bar is lower. The description still adds real value by promising 'Never returns a key' (a security-relevant guarantee about the response) and stating the branch scoping and required 'keys:read' scope.

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 short sentences with zero filler, and the substance (caps, usage, providers) is front-loaded before the negative guarantee. The colon-chained phrasing is slightly dense but nothing is wasted.

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

Completeness4/5

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

With no output schema, the description carries the burden of describing return content, and it does so concretely (caps, usage, provider connectivity) while flagging that key material is excluded. Combined with fully documented optional parameters and safe read annotations, an agent has enough to call it correctly.

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?

All three parameters have full schema descriptions including defaulting rules (production, last-used project, token organization), so the schema does the heavy lifting. The description adds only the notion that results are branch-scoped and contributes no syntax or semantics beyond that, making the baseline 3 appropriate.

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 names a specific resource (AI gateway keys for a branch) and enumerates what the response contains: daily/monthly caps, usage, and connected providers. It is clearly distinct from generic siblings such as keys.get and apikey.list, though it never names those alternatives explicitly.

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 implied rather than stated: an agent can infer this is the tool for inspecting gateway key limits/usage, and the 'keys:read' scope signals the permission needed. There is no explicit when-to-use/when-not-to-use guidance or routing to keys.get or apikey.list for other key questions.

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