Skip to main content
Glama
AdsPower

AdsPower LocalAPI MCP Server

Official

select-option

Select specific dropdown options in browser automation by providing CSS selectors and values to interact with web page elements programmatically.

Instructions

Select the option

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
selectorYesThe selector of the option to select, find from the page source code
valueYesThe value of the option to select

Implementation Reference

  • The handler function that executes the logic for the 'select-option' tool: waits for the selector, selects the option by value using Puppeteer page.selectOption, and returns a success message.
    async selectOption({ selector, value }: SelectOptionParams) {
        browser.checkConnected();
        await browser.pageInstance!.waitForSelector(selector);
        await browser.pageInstance!.selectOption(selector, value);
        return `Selected option with selector: ${selector} with value: ${value} successfully`;
  • Zod schema defining the input parameters (selector and value) for the 'select-option' tool.
    selectOptionSchema: z.object({
        selector: z.string().describe('The selector of the option to select, find from the page source code'),
        value: z.string().describe('The value of the option to select')
    }).strict(),
  • Registration of the 'select-option' tool on the MCP server, linking the schema and wrapped handler.
    server.tool('select-option', 'Select the option', schemas.selectOptionSchema.shape,
        wrapHandler(automationHandlers.selectOption));
Behavior1/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Select the option' vaguely implies a UI interaction but doesn't specify whether this is a read-only or mutating operation, what happens after selection (e.g., form submission, page change), error conditions, or performance characteristics. This is inadequate for a tool that likely modifies UI state.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

While technically concise with only three words, the description is under-specified rather than efficiently informative. It fails to front-load critical information about the tool's purpose and context, wasting its minimal content on a tautological restatement of the name rather than earning its place with useful details.

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

Completeness1/5

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

Given the lack of annotations and output schema, plus the presence of many sibling UI interaction tools, this description is severely incomplete. It doesn't explain what 'selecting an option' entails behaviorally, what the tool returns, how it differs from similar tools, or what context it operates in (browser automation based on sibling tools). This leaves too many gaps for effective agent use.

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?

The input schema has 100% description coverage, with clear documentation for both 'selector' and 'value' parameters. The description adds no additional semantic context beyond what's in the schema (e.g., examples of selectors, format of values, or how they interact). This meets the baseline expectation when schema coverage is complete.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose2/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Select the option' is a tautology that merely restates the tool name 'select-option' without adding meaningful context. It doesn't specify what type of option (e.g., dropdown, radio button, checkbox) or in what context (e.g., web page, application UI), nor does it distinguish this tool from sibling tools like 'click-element' or 'fill-input' that might perform similar UI interactions.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines1/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing an open browser), context (e.g., interacting with form elements), or exclusions (e.g., not for clicking buttons). With sibling tools like 'click-element' and 'fill-input' available, this lack of differentiation leaves the agent guessing about appropriate use cases.

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/AdsPower/local-api-mcp-typescript'

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