Skip to main content
Glama
surpasses
by surpasses

resize_viewport

Set a browser tab's viewport dimensions in CSS pixels, such as 390x844 for phone testing, to verify responsive layouts.

Instructions

Set the tab's viewport size in CSS pixels (e.g. 390x844 for phone).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tabIdYesTab id from tabs_context
widthYes
heightYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior3/5

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

No annotations are present, so the description carries the behavioral burden. It clearly states the effect and uses a precise verb, but does not mention side effects like re-layout, page reload, persistence, or required tab state. Adequate for a simple setter but not rich.

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?

One front-loaded sentence states the action, object, unit, and a useful example with no filler.

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 three-required-param primitive tool with no output schema, the essential call facts are present: what to set, the units, and a realistic value pair. Missing 'when' guidance is minor for this level of 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?

Schema describes only tabId; width and height are bare integers. The description compensates partially by giving units ('CSS pixels') and a concrete example ('390x844'), but it does not document ranges, constraints, or the relationship between width and height.

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 a precise action ('Set'), the resource ('the tab's viewport size'), and the unit ('CSS pixels'), with a concrete phone-size example. This clearly distinguishes it from all listed siblings such as navigate, screenshot, or tabs_activate.

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?

The '390x844 for phone' example implies mobile/responsive viewport testing, but there is no explicit statement of when to call this tool rather than alternatives or whether it should precede screenshots. No sibling provides the same function, so routing is less critical.

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