select_frame
Lists frames and iframes in the current page. Pass a frame index to switch the shared context for later click and script actions; omit to list only.
Instructions
Lists or selects frames, including iframes, within the current page. Use it when the target element, page-defined global, script, or execution context may live in an iframe: first list frames, then pass frameIdx before click_element or evaluate_script. Omitting frameIdx lists 20 frames per page without changing context; passing frameIdx changes the shared frame target, with 0 restoring the main frame. It does not switch browser tabs or navigate—use select_page or navigate_page for those actions—and listPageIdx only paginates this listing.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| frameIdx | No | Frame index from the latest frame listing. Pass it to target later frame-aware tools; 0 restores the main frame. Omit it to list frames without changing context, and re-list after navigation or frame attachment/detachment because indices can shift. | |
| pageSize | No | Maximum frames to list per response. Defaults to 20. | |
| listPageIdx | No | Zero-based pagination index for the frame listing only. This is not the frameIdx used to select a frame. Defaults to 0. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | Whether the tool completed successfully. | |
| data | No | ||
| tool | Yes | Stable MCP tool name. | |
| error | No | ||
| summary | Yes | Concise human-readable outcome. |