Skip to main content
Glama

storage.set

Writes a localStorage or sessionStorage key-value pair in a browser page, letting agents persist or update client-side web state for a target or active page.

Instructions

Write a localStorage or sessionStorage value.

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": {
      "key": "<key>",
      "value": "<value>"
    },
    "name": "storage.set"
  }
}

Input Schema

NameRequiredDescriptionDefault
keyYes
kindNo
valueYes
target_idNoTarget handle (tgt_*). Omit for the active page.
browser_idNoBrowser handle (br_*). Omit to use the only running browser, or auto-launch one.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.7/5.0
Behavior2/5

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

Annotations already declare readOnlyHint=false and openWorldHint=true, so the mutation and open-world nature is covered structurally. The description adds nothing further: it does not say whether an existing key is overwritten, whether values are stringified, how origin/page scoping affects which store is written, or what happens if no browser is running.

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?

A single short sentence with no filler, and the operative verb and resource are front-loaded. Its brevity is efficient, though it borders on under-specification rather than genuine conciseness.

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 a five-parameter mutation tool with no output schema and sparse annotation coverage, the definition leaves too much unstated: overwrite semantics, value encoding, page/browser targeting behavior, and interaction with the other storage siblings. An agent could call it, but only by leaning entirely on the schema.

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 only 40%, with target_id and browser_id the only documented parameters; key, value, and kind have no schema descriptions. The phrase 'localStorage or sessionStorage' hints at the kind enum values, but nothing explains key format, value encoding, or the distinction between the two storage kinds, so the description does not compensate for the coverage gap.

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 states a specific verb plus resource: write a localStorage or sessionStorage value. The word 'write' and the storage-type scoping distinguish it from web-storage reads and from cookie/IndexedDB siblings, 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 Guidelines2/5

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

There is no guidance on when to use this tool rather than storage.get, storage.remove, storage.set_cookie, or storage.indexeddb.put, and no mention of prerequisites such as needing the target page loaded. The agent must infer all routing from the tool name and sibling list.

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

Deploy Server

Other Tools