Skip to main content
Glama

Set context

set_context
Idempotent

Set the active brand and/or event so subsequent tools don't need IDs passed every call. Pass brandName / eventName for friendlier display in summaries.

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": "set_context"
  }
}

Input Schema

NameRequiredDescriptionDefault
brandIdNoBrand ID to set as active.
eventIdNoEvent ID to set as active.
brandNameNoBrand name (for display in context summaries).
eventNameNoEvent name (for display in context summaries).

Output Schema

NameRequiredDescriptionDefault
contextYesThe selected brand and event, when set.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "context": {
      +      "description": "The selected brand and event, when set.",
      +      "properties": {
      +        "brandId": {
      +          "description": "Selected brand identifier.",
      +          "type": "string"
      +        },
      +        "brandName": {
      +          "description": "Selected brand name.",
      +          "type": "string"
      +        },
      +        "eventId": {
      +          "description": "Selected event identifier.",
      +          "type": "string"
      +        },
      +        "eventName": {
      +          "description": "Selected event name.",
      +          "type": "string"
      +        }
      +      },
      +      "type": "object"
      +    }
      +  },
      +  "required": [
      +    "context"
      +  ],
      +  "type": "object"
      +}
  2. Added

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, idempotentHint=true, and destructiveHint=false. The description adds genuinely useful context: the effect is on session context rather than stored data, and it makes later calls simpler. It says nothing about validation failures (nonexistent IDs), scope of persistence, or interaction with clear_context.

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 sentences, no waste, with the effect on subsequent calls front-loaded. It could state the optionality of all parameters more explicitly, but nothing is redundant.

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?

An output schema exists, so return values need not be explained. However, for a state-setting tool, the definition omits how the context is cleared, whether it persists across sessions, and how it differs from the sibling select_brand/select_event tools.

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 100%, so all four parameters are documented, establishing a baseline of 3. The description clarifies that brandName/eventName are optional display-only companions to the ID parameters, but that largely repeats the schema's own wording.

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 ("Set the active brand and/or event") plus the payoff ("subsequent tools don't need IDs passed every call"), which is enough for an agent to recognize the tool. It does not distinguish itself from the sibling tools select_brand and select_event, which appear to overlap, so it falls 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?

The description implies when to use it by naming the benefit (avoiding repeated ID arguments), which is a real usage cue. But it offers no exclusions and never mentions the obviously related siblings clear_context, get_context, select_brand, or select_event, leaving the agent to guess which one to pick.

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