Skip to main content
Glama

Gateway: Guard mode

gateway_set_guard

Turn Privi Guard on for every tool result that passes through your gateway: tag adds the verdict and a receipt id in result._meta['privi/guard']; block also replaces injected results with an error before your agents see them. Each result is one Guard check (free allowance, then credits). Requires the organization API key.

Input Schema

NameRequiredDescriptionDefault
modeYesoff | tag | block
gw_idYesgw_... ID

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

With none of the annotations declaring what is actually mutated, the description carries that burden well: it specifies the exact write location (result._meta['privi/guard']), the semantic difference of block (injected results are replaced with an error before agents see them), the billing model (one Guard check per result, free allowance then credits), and the auth requirement. That is materially more than readOnlyHint=false / destructiveHint=false convey.

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?

Three compact sentences, front-loaded with the core action, then modes, then cost and auth. The middle clause packs both mode behaviors into one long sentence, which slightly hurts scannability, but there is no filler.

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?

No output schema exists, and the description compensates by naming the result._meta key and the error-substitution behavior of block mode. It leaves 'off' mode and any gateway existence/permission prerequisites unstated, so it is strong but not fully closed.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3, but the description goes further by defining the observable behavior of each mode value rather than restating the enum 'off | tag | block'. It adds nothing for gw_id beyond the schema's 'gw_... ID', and notably omits any explanation of 'off'.

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

Purpose5/5

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

The description gives a specific verb and resource ('Turn Privi Guard on for every tool result that passes through your gateway') and immediately differentiates the two operating modes. It is clearly distinct from sibling gateway_* tools such as gateway_create, gateway_info, or gateway_stats, which deal with gateway lifecycle and metrics rather than guard configuration.

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

Usage Guidelines4/5

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

It explains the selection criteria between the tag and block modes and states a hard prerequisite ('Requires the organization API key'), which is real usage context. It does not address the third schema mode value ('off'), nor when you would prefer Guard over other result-inspection tools like guard_check or scan_*, so there is no explicit alternative routing.

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