Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
OPENROUTER_API_KEYYesYour model API key (for example an OpenRouter key) used by the MCP server for authoring. Prefer inheriting it from the environment or prompting for it rather than writing it into a JSON file.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

sitelooper authors browser tests with an agent and compiles them to plain Playwright. Authoring: open (learn=true) → set_var → one do or assert per verifiable outcome → save_flow → build_start, then poll job_status. build_start, check (ready), repair_propose and rerecord are background jobs polled with job_status. Credentials only as {{env:NAME}} / {{totp:NAME}} markers; never ask for a secret value.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
openA

Navigate a browser session to a URL (no model involved); starts the session if it is not running. learn and headed apply only when this call starts the session: learn=true records every later do/assert as a reusable flow step (needed before save_flow). Typical authoring: open (learn) → set_var → do/assert per outcome → save_flow → build_start.

doA

Have the agent perform ONE verifiable outcome in the session's browser and verify it, e.g. "create a customer named {{runid}} and confirm it appears in the list". One verifiable outcome per do: split multi-part tasks into several calls. State expected values in the sentence. Credentials: write each secret as one {{env:NAME}} marker ({{totp:NAME}} for a one-time code), exactly as written: the marker alone, never the value and never $NAME. NAME must be set in the environment the MCP server was started with. Never ask the user for a secret value. Needs a model API key in the server environment. Returns the report (status, summary, evidence values). Exit 1 = the agent could not complete it.

assertA

Check a condition on the current page now; never acts. State the expected text in the sentence, e.g. "the order list shows a row with total 42.00". In a learn session a passing assert becomes a flow step that fails the run when it does not hold. Credentials: write each secret as one {{env:NAME}} marker ({{totp:NAME}} for a one-time code), exactly as written: the marker alone, never the value and never $NAME. NAME must be set in the environment the MCP server was started with. Never ask the user for a secret value. isError with exit 1 = the condition did not hold; exit 2 = could not be checked.

set_varA

Set a session variable that later instructions reference as {{name}}; in a learn session it becomes a flow variable that build/check bind with vars. Not for secrets (use {{env:NAME}} markers).

peekA

Return the session page's URL, title and an accessibility snapshot (no model, no actions).

screenshotA

Capture the session page as a PNG; returns the image and the file path it was saved to.

save_flowA

Stop a learn session, save what it recorded as a named flow, then export the flow with its pinned procedures to a bundle file (default .sitelooper/procedures.json in cwd). Closes the session's browser. Then call build_start with the flow name.

list_flowsB

List saved flows with their step counts, variables and origin.

build_startA

Start a background job that compiles a saved flow (or bundle) into a Playwright .flow.ts/.spec.ts and verifies it (readiness: clean runs). With a reset command (sitelooper.config.json resetCommand) it first converges, re-recording failing steps with the model. Readiness needs a reset command or fixture_isolation. Returns a job_id at once: poll job_status until done/failed (minutes).

checkA

Run a compiled .flow.ts once under plain Playwright (no model) and report pass/fail (exit 4 = failed, 2 = could not run). With ready=true it runs the readiness gate (several clean runs) as a background job: the call returns a job_id; poll job_status.

repair_proposeA

Start a background job that replays a compiled .flow.ts against the app, repairs drifted steps and stages a checked candidate as a proposal file for review (repair --propose); never rewrites the spec. Returns a job_id: poll job_status. Apply a good proposal with repair_apply.

repair_applyA

Apply a proposal staged by repair_propose to its flow file exactly as checked (no browser run).

rerecordA

Start a background job that re-records one step of a flow with the agent (optionally with a new instruction), then verifies it over several runs and re-pins it. Needs a model API key. Credentials: write each secret as one {{env:NAME}} marker ({{totp:NAME}} for a one-time code), exactly as written: the marker alone, never the value and never $NAME. NAME must be set in the environment the MCP server was started with. Never ask the user for a secret value. Returns a job_id: poll job_status.

job_statusA

Report a background job started by build_start, check (ready), repair_propose or rerecord: status running|done|failed, the last progress lines, and the final JSON result and exit code when finished. Waits up to wait_s seconds for the job to finish before answering.

sessionsB

List browser sessions and whether each is running.

stopA

Stop a browser session (closes its browser and daemon) without saving a flow. Use save_flow instead to keep a learn session's recording.

doctorA

Inspect the setup: browser, Node, and which model provider/API key is in use and why (never shows the key).

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A3.7/5.0

Scored across 17 tools

Disambiguation4/5

Most tools map to distinct lifecycle stages, but check vs build_start (both verify flows) and repair_propose vs rerecord (both repair/re-record steps) require reading descriptions to choose correctly. do vs assert are close but described distinctly enough.

Naming Consistency3/5

All names are lowercase snake_case, but the grammatical pattern is mixed: single verbs (open, do, assert, check, stop), noun-like names (sessions, screenshot, doctor), and compound verb_noun names (save_flow, build_start, repair_propose). Readable, but not one predictable convention.

Tool Count4/5

17 tools is on the high side, but it is justified by a multi-stage workflow: session authoring, flow saving, building, checking, repairing, rerecording, and setup. Each tool occupies a distinct stage, though a few could potentially be consolidated.

Completeness4/5

The set covers session lifecycle, authoring, flow persistence, build/check/repair, job polling, and environment diagnosis. Minor gaps remain: no get/delete/rename flow operation or job cancellation, and list_flows is shallow, but core workflows are covered.

Maintenance

ActivityActive
ResponsivenessNo recent community issues