Skip to main content
Glama

Write to the workspace data store

set_workspace_data

Creates or replaces a workspace-scoped key-value entry storing any JSON value, with optional TTL expiry for live runtime data.

Instructions

Creates or replaces one entry in the per-workspace key-value store. value is any JSON. Optional ttlSeconds expires it. This is live runtime data — NOT versioned with the workspace's grid commits.

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": {
      "workspaceId": "<workspaceId>",
      "key": "<key>",
      "value": "<value>"
    },
    "name": "set_workspace_data"
  }
}

Input Schema

NameRequiredDescriptionDefault
keyYes
valueYesAny JSON value (object, array, string, number, boolean or null).
ttlSecondsNoSeconds until the entry expires.
workspaceIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.53.0

TDQS

B3.4/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden and does meaningful work: it discloses upsert semantics ('creates or replaces', implying existing values are overwritten), TTL-based expiry, and the critical fact that this data is live runtime state not tied to grid commits. It omits permissions/auth requirements, size limits, and consequences of overwrite, so it is strong but not exhaustive.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Four short sentences, each front-loaded with the most decision-relevant fact: operation type first, value shape second, expiry third, and the non-versioned distinction last as the differentiator. No filler or redundancy.

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

Completeness2/5

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

For an unannotated 4-parameter mutation tool with no output schema and 50% schema coverage, the description leaves significant gaps: nothing about what the call returns, whether overwriting is destructive to consumers, auth requirements, or the semantics of the undocumented workspaceId and key parameters.

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

Parameters2/5

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

Schema coverage is 50% and the description adds little beyond it: 'value is any JSON' restates the schema description, and 'Optional ttlSeconds expires it' only marginally extends 'Seconds until the entry expires.' The undocumented workspaceId and key parameters receive no explanation of scoping or key-naming constraints.

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 specific verb pair plus resource: 'Creates or replaces one entry in the per-workspace key-value store,' which is concrete enough for an agent to know exactly what state change occurs. It stops short of naming a sibling (e.g. set_workspace_content or write_file) to disambiguate against the other write tools in the catalog, so it is clear but not sibling-differentiated.

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 only implied: 'This is live runtime data — NOT versioned with the workspace's grid commits' tells the agent this is for ephemeral scratch state rather than committed content, which is a real selection signal. However, no alternative tool is named and there is no explicit when-not-to-use guidance, leaving the agent to infer the boundary with set_workspace_content or add_to_workspace.

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