Skip to main content
Glama

Select option

browser_select_option

Select one or more options by label or value in native select elements and ARIA comboboxes, including Angular Material mat-select and PrimeNG p-select/autocomplete.

Instructions

Select option(s) by label or value in a or ARIA combobox (Angular Material mat-select, PrimeNG p-select/autocomplete).

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": {
      "values": "<values>"
    },
    "name": "browser_select_option"
  }
}

Input Schema

NameRequiredDescriptionDefault
nthNo
refNoElement ref from snapshot (preferred)
nameNo
roleNo
textNo
exactNo
labelNo
expectNoExpectSpec postconditions
pageIdNo
testIdNo
valuesYes
withinNoScope to a unique container (ref, role+name, label, testId or CSS selector)
sessionNo
selectorNoCSS (last resort)
snapshotNoPage state returned after the action: diff (default), full, none
placeholderNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

B3.1/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false and openWorldHint=true, so the mutation and environment profile is covered. The description adds genuine context by disclosing that it works on ARIA comboboxes and specific component libraries, which explains non-native behavior. It does not say whether selection fires change events, how multi-value selection is handled, or what happens if a value matches nothing.

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 front-loaded sentence with no padding; the parenthetical library list is the one thing that earns its words by flagging framework-specific comboboxes. Compact and easy to parse, though it spends its budget on element taxonomy rather than on the 15 undocumented parameters.

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 16-parameter UI-mutation tool with no output schema and low schema coverage, the description is far too thin. It says nothing about multi-select semantics, failure modes when a label/value is not found, or how the action interacts with the snapshot/expect postcondition machinery, leaving the agent to guess on most of the surface.

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?

With 16 parameters and only 31% schema description coverage, the description carries a heavy burden and mostly fails it. 'By label or value' hints at the label/name/text locators and the values array, but nothing explains that values is a required multi-item array (multi-select), nor meaning for exact, nth, within, expect, placeholder, session or pageId — all undocumented in both places.

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 pairs the specific verb 'Select' with a precise resource ('option(s)') and names the target element classes (<select>, ARIA combobox including mat-select and p-select/autocomplete). That is enough to distinguish it from browser_click or browser_fill by the element being acted on, though it never names those siblings explicitly.

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?

Usage is implied by the element taxonomy: an agent can infer this is the tool for select/combobox controls rather than generic clicks. However there is no explicit statement of when to prefer this over browser_click or browser_fill, and no mention of prerequisites such as the element needing an open dropdown or a snapshot ref.

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