Skip to main content
Glama
andresolbach

nodriver-mcp-server

Load session

load_session

Restore cookies and localStorage from a saved session file to start a run already logged in. Navigates to the saved origin, reloads the page, and skips invalid cookies.

Instructions

Restore cookies and localStorage from a saved session file.

Use it at the start of a run to arrive already logged in. The page is first navigated to the saved origin so localStorage lands where it belongs, then reloaded so the restored cookies take effect.

Cookies that no longer apply are skipped rather than failing the whole restore, and the response reports how many were actually restored. Expired tokens still leave you logged out, so check the page afterwards.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
filenameYesSession filename as shown by list_sessions, or an absolute path to a session JSON file.
restore_pagesNoAlso re-open the tabs that were open when the session was saved. Default false, which restores only cookies and localStorage.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

Describes non-obvious behaviors: navigation to the saved origin before restoring localStorage, reloading to apply cookies, skipping invalid cookies rather than failing, reporting restore count, and warning that expired tokens may leave the user logged out. This goes well beyond the annotations, which only state flags (readOnly=false, etc.). No contradiction.

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?

Every sentence is informative and earns its place. It opens with the core purpose, then explains the internal procedure, edge-case handling, and a necessary caveat. No fluff or repetition.

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

Completeness5/5

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

Covers what it does, when to use it, side effects (navigation/reload), failure handling, and what the response reports. With an output schema available, this description is complete for the tool's complexity.

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?

Input schema covers 100% of parameters with detailed descriptions (filename and restore_pages). The description adds no additional parameter-specific meaning beyond the schema, so baseline 3 is appropriate.

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 the exact action: 'Restore cookies and localStorage from a saved session file.' It clearly differentiates from sibling tools like set_cookie and save_session by focusing on restoring a previously saved session, and adds the use-case 'at the start of a run to arrive already logged in.'

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?

Explicitly says when to use ('Use it at the start of a run to arrive already logged in'), and implies a difference from per-cookie/per-localStorage tools. However, it does not explicitly name alternatives or state when not to use it, so it falls short of a 5.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/andresolbach/nodriver-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server