Skip to main content
Glama

Create Browser Session

session_create

Create isolated browser sessions with distinct cookies and storage to prevent data leakage between parallel automation tasks. Configure custom proxies, viewports, and authentication profiles per session.

Instructions

Create a new isolated browser session with its own cookies and state. Returns a short session ID (e.g. s_k3m7x1) to pass to all other tools. Each session is a separate BrowserContext — no cookie leakage between sessions. Pool limit: 15 concurrent sessions. Sessions auto-expire after 30 minutes of inactivity. Use keep-alive pattern (periodic navigate or snapshot) for long-running sessions.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
profilePathNoPath to a Playwright storageState JSON file for pre-authenticated sessions.
viewportNoCustom viewport. Default: 1280x720.
userAgentNoCustom user agent string.
localeNoBrowser locale (e.g. 'en-US', 'fr-FR').
timezoneIdNoTimezone ID (e.g. 'America/New_York', 'Europe/London').
geolocationNoGeolocation to emulate.
permissionsNoPermissions to grant (e.g. ['geolocation', 'notifications']).
colorSchemeNoPreferred color scheme.
acceptDownloadsNoWhether to accept downloads. Default: true.
stealthNoEnable/disable stealth mode for this session. Default: true (uses global setting).
proxyNoPer-session proxy configuration. Each session can use a different proxy.
profileNoProfile shorthand name (e.g. 'github', 'gmail'). Uses persistent Chrome profile at ~/.leapfrog/chrome-profiles/{name}/.
headedNoRun browser with visible UI for this session. Overrides LEAP_HEADED env var.
extensionsNoPaths to unpacked Chrome extensions to load.
cdpNoCDP endpoint URL to connect to a running Chrome instance (e.g. 'http://localhost:9222').
clientIdNoClient identifier for per-client pool partitioning. Used with LEAP_MAX_SESSIONS_PER_CLIENT.
pinnedNoPin this session to prevent idle timeout cleanup.
Behavior5/5

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

No annotations exist, so description carries full burden. Discloses critical runtime behaviors: BrowserContext isolation model ('no cookie leakage'), concrete pool limit (15), auto-expiry (30 min), return value format (s_k3m7x1), and resource management requirements.

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?

Six sentences, zero waste. Structure front-loads the action, followed by return value, isolation guarantee, resource limits, expiry policy, and operational pattern. Each sentence delivers distinct, essential information for a stateful resource constructor.

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?

Comprehensive for a complex 17-parameter initialization tool with no output schema. Covers creation contract, return format, isolation semantics, resource constraints, and maintenance patterns—sufficient for correct agent operation without external documentation.

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 has 100% description coverage, establishing baseline 3. Description adds conceptual framing ('isolated browser session with its own cookies and state') that contextualizes the 17 configuration parameters but does not elaborate on individual parameter semantics beyond the schema.

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?

Description opens with specific verb+resource ('Create a new isolated browser session') and distinguishes from siblings by explaining it returns a session ID 'to pass to all other tools', establishing it as the prerequisite entry point for the browser tool suite.

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?

Provides operational guidance on keep-alive patterns ('periodic navigate or snapshot') and lifecycle constraints (pool limit, expiry). Lacks explicit comparison to sibling session_* tools (e.g., session_health), but clearly signals it must be called first via the session ID reference.

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/anthonybono21-cloud/leapfrog'

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