Skip to main content
Glama

browser_set_cookies

Destructive

Set one or more cookies in the browser session. A cookie with the same name, domain and path replaces the existing one.

Input Schema

NameRequiredDescriptionDefault
cookiesYesArray of cookie objects to set
session_idYesSession ID returned by browser_navigate

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.6/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true and readOnlyHint=false, so the agent knows this mutates state. The description adds a genuinely useful behavioral detail beyond that: the name/domain/path key determines replacement of an existing cookie, telling the agent what gets overwritten. It stops short of covering effects on subsequent requests or session persistence.

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?

Two short sentences, zero padding, with the core action stated first and the overwrite rule as a supporting detail. Nothing is redundant with the schema or annotations.

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 2-parameter mutation tool with full schema coverage, rich annotations, and no output schema, the description covers the essential behavior including overwrite semantics. Only minor gaps remain (session prerequisites, effect on in-flight navigation), which are not critical for correct invocation.

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 description coverage is 100% for both parameters, and the nested cookie object fields (expires, secure, http_only, etc.) are fully typed in the schema. The description adds no parameter-level detail beyond what the schema already provides, so the baseline 3 applies.

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 ("Set") and resource ("cookies") scoped to "the browser session," so the operation is unambiguous. It does not explicitly name or contrast with siblings like browser_get_cookies or browser_clear_cookies, but the overwrite clause implicitly separates it from those read/clear operations.

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 reach for this tool versus alternatives, nor any stated prerequisites (e.g., that a session_id from browser_navigate must exist first). Usage is only inferable from the tool name and the session mention.

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.