Skip to main content
Glama

Push working context

push_context
Idempotent

Store a key/value entry in a session's working memory (short-lived scratch space). Pushing the same (session_id, key) again replaces the previous value. Read it back with get_context, or with retrieve_memories by passing session_id.

Args:
    session_id: Session identifier.
    key: Entry key.
    value: Value to store; a string is stored as {"data": value}.
    ttl_seconds: Seconds until the entry expires. 0 (default) = never.

Input Schema

NameRequiredDescriptionDefault
keyYes
valueYes
session_idYes
ttl_secondsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior4/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 non-structured behavior: replacement-on-duplicate-key, TTL expiration semantics (0 = never), and the value coercion to {"data": value}. These go beyond the annotation set and give the agent confidence about mutate/replace semantics.

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?

Front-loads purpose and read-back routing before the Args block, with no filler. The Args list is efficient, though the two trivial labels (session_id, key) are slightly redundant with obvious naming.

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?

For a 4-param write tool with no output schema, the description covers purpose, replacement behavior, TTL, value shape, and read-back alternatives. It omits any mention of auth/permissions or return behavior, but those are minor given the annotation coverage of the safety profile.

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 description coverage is 0%, so the description must carry the load, and it does document all four parameters. It adds real meaning for value (stored as {"data": value}) and ttl_seconds (0 default = never expires); session_id and key are only lightly glossed ('Session identifier'/'Entry key'), which is why this is not a 5.

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?

States a specific verb and resource ('Store a key/value entry in a session's working memory') and qualifies the scope as short-lived scratch space, which cleanly separates it from persistent-memory siblings like store_fact or store_procedure. It also names the read-back counterparts (get_context, retrieve_memories), so an agent can route without opening a schema.

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?

Explains the use case (ephemeral scratch space), the write semantics (re-pushing the same session_id+key replaces the value), and points to explicit alternatives for reading back. It stops short of spelling out when to prefer this over other writers (store_fact, store_episode), so it is clear context without full exclusion guidance.

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