FrameParse
v0.2.04-layer webpage frames + MCP observe/act for agents.
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
frame_open
Parse a webpage (URL, raw HTML, live browser DOM snapshot from frameparse://browser-extractor.js, or built-in fixture) deterministically with zero AI, cache it in a session, and return ONLY Frame 1 (Structure: every s# landmark listed) + token compression telemetry. Always call this first; use frame_read layers 2–4 with regions[] to scope text/controls/actions.
| Parameter | Type | Description |
|---|---|---|
fixture | string | Optional built-in sample webpage fixture for testing. |
html | string | Raw HTML string to parse directly. |
includeHidden | boolean | Include hidden/aria-hidden elements (default: false). |
sessionId | string | Optional custom session ID to reuse or overwrite. |
snapshot | object | Live post-hydration browser DOM snapshot captured via frameparse://browser-extractor.js (supports SPAs, auth sessions, Shadow DOM, iframes, real CSS visibility, and JS/cursor:pointer clickables). |
url | string | Live webpage URL (http/https) to fetch and parse. |
frame_read
Progressively read a single frame layer (1=Structure, 2=Text, 3=Interactables, 4=Actions) from a cached session. Layer 1 always returns the full landmark tree (paginate with offset/maxTokens). Layers 2–4 accept optional regions[] (Frame 1 IDs e.g. ['s4']) to scope content, plus maxTokens pagination.
| Parameter | Type | Description |
|---|---|---|
layer * | integer | 1=Structure, 2=Text, 3=Interactables, 4=Actions. |
sessionId * | string | Session ID returned by frame_open. |
effects | array | Optional filter for Frame 4 action side-effect tiers. |
kinds | array | Optional filter for Frame 2 block kinds or Frame 3 interactable kinds. |
maxTokens | integer | Hard token budget for this response (default: 900). Use offset to paginate if truncated. |
offset | integer | Line offset for pagination (default: 0). |
regions | array | Optional Frame 1 landmark IDs (e.g. ['s4']) — applies to layers 2–4 only; layer 1 ignores regions and always lists all landmarks. |
frame_query
High-density zero-AI search across Frames 1-4 inside a cached page session. Returns only the matching text blocks, controls, and actions (~80-180 tokens) so the agent finds prices, labels, or buttons without reading the whole page.
| Parameter | Type | Description |
|---|---|---|
query * | string | Keywords or phrase to locate (e.g. 'price', 'battery', 'warranty', 'login'). |
sessionId * | string | Session ID returned by frame_open. |
layers | array | Which layers to search (default: [2, 3, 4]). |
limit | integer | Maximum ranked matches to return (default: 8). |
frame_plan
Zero-AI deterministic action planner on Frame 4. Given a natural-language goal (e.g. 'search for laptops', 'add to cart', 'sign in'), returns ranked composite workflows & atomic actions with safety effect tiers, preconditions, parameters, and executable browser steps.
| Parameter | Type | Description |
|---|---|---|
goal * | string | What the agent wants to accomplish on the page. |
sessionId * | string | Session ID returned by frame_open. |
allowDestructive | boolean | Whether to include destructive actions like delete/revoke (default: true; always confirm destructive actions with the user). |
limit | integer | Max ranked action plans to return (default: 5). |
regions | array | Optional Frame 1 landmark IDs to restrict candidate actions. |
frame_inspect
Inspect the complete vertical cross-layer lineage (Frame 1 Structure <-> Frame 2 Text <-> Frame 3 Interactables <-> Frame 4 Actions) for any single ref ID (s#, t#, i#, w#, or a#).
| Parameter | Type | Description |
|---|---|---|
ref * | string | Any frame reference ID such as s4, t2, i11, w1, or a3. |
sessionId * | string | Session ID returned by frame_open. |
frame_diff
Compute a compact delta between the cached page session and a new page state (URL, HTML, or live browser DOM snapshot after clicking/submitting). Pass executedActionId (e.g. 'a5' or 'w1') to automatically learn and cache that control's real-world outcome on this origin for future Frame 4 parses.
| Parameter | Type | Description |
|---|---|---|
sessionId * | string | Existing session ID to diff against. |
executedActionId | string | Optional Frame 4 action/workflow ID (e.g. 'a5', 'w1') that caused this transition; records its observed effect into the site-level ActionEffectCache. |
fixture | string | Optional built-in fixture for after-state testing. |
html | string | New raw HTML after the action. |
snapshot | object | New live browser DOM snapshot after the action. |
updateSession | boolean | Update the cached session to the new state (default: true). |
url | string | New URL to fetch after the action. |
frame_sessions
List active cached webpage sessions with cumulative token savings telemetry (raw HTML tokens avoided vs compact frame tokens emitted), or close a session.
| Parameter | Type | Description |
|---|---|---|
action | string | Default: list. |
sessionId | string | Required when action is 'close'. |
frame_browser
Connect FrameParse's built-in CDP actuator to Chrome (no DevTools uid required). Actions: status | connect | launch | disconnect | navigate. Prefer connect to an existing debugging port (http://127.0.0.1:9222).
| Parameter | Type | Description |
|---|---|---|
action | string | Default: status. action=open navigates (optional url), extracts live DOM snapshot, and frame_open's it into a session. |
browserURL | string | Chrome remote debugging HTTP endpoint, e.g. http://127.0.0.1:9222 |
executablePath | string | Chrome binary for action=launch. |
headless | boolean | For action=launch (default true). |
profileDirectory | string | Chrome profile folder name (default: Default when useDefaultProfile is true). |
sessionId | string | Optional session id for action=open. |
url | string | URL for action=navigate or action=open. |
useDefaultProfile | boolean | For action=launch: omit --user-data-dir so Chrome uses the OS default profile. Close all other Chrome windows first; CDP may be blocked on some Chrome builds. |
usePersistentProfile | boolean | For action=launch (recommended): use %LOCALAPPDATA%/FrameParse/ChromeProfile — CDP works reliably and logins persist for marketing submissions. |
userDataDir | string | Override Chrome --user-data-dir for launch. |
wsEndpoint | string | Direct CDP WebSocket endpoint. |
frame_act
Execute interaction(s) from FrameParse frames via CDP — click/fill/select/toggle/submit/navigate/hover/focus/type/press — using i# / a# / w# refs or a goal. Does NOT use DevTools a11y uids. Auto scroll-into-view before target ops. Re-extracts snapshot + returns frame_diff by default.
| Parameter | Type | Description |
|---|---|---|
sessionId * | string | |
confirmDestructive | boolean | Required true to execute destructive Frame 4 actions. |
goal | string | If ref omitted, run the top Frame 4 plan for this goal. |
params | object | Values for fill/select/toggle/press (e.g. { q: "laptops", value: "...", key: "Enter" }). |
ref | string | Frame ref to act on: i12 (interactable), a3/w1 (Frame 4 action/workflow), or s4 (scroll region). |
reobserve | boolean | Re-extract live DOM and return frame_diff (default true). |
frame_chain
Direct multi-step tool call chain in ONE invocation. Presets: orient_and_plan, query_then_inspect, plan_and_inspect, action_and_observe. Variables: $sessionId, $prev.ref, $steps.<alias>.*.
| Parameter | Type | Description |
|---|---|---|
compact | boolean | |
json | boolean | |
preset | string | |
presetArgs | object | |
steps | array |
frame_scroll
Scroll using FrameParse refs: into_view(ref), by(dx,dy), or to(top|bottom|x,y). Uses CDP actuator; reobserves by default.
| Parameter | Type | Description |
|---|---|---|
op * | string | |
sessionId * | string | |
dx | number | |
dy | number | |
ref | string | i# / a# / s# for into_view or element scroll container. |
reobserve | boolean | Default true. |
target | string | For op=to without x/y. |
x | number | |
y | number |