OLTestStack
Provides persistence for browser recordings and test reports in a PostgreSQL database.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@OLTestStackopen example.com and take a screenshot"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
OLTestStack — AI Browser Testing Framework
MCP server that exposes high-level browser automation tools for AI agents. Internally drives Chromium via Puppeteer/CDP; externally presents flat, stateless MCP command payloads.
git clone https://github.com/openlearnia/OLTestStack.git
cd OLTestStackRequirements
Bun 1.0+ (or Node.js 20+)
Chromium (bundled with Puppeteer, or set
CHROMIUM_EXECUTABLE_PATH)Docker (optional, for PostgreSQL persistence)
Related MCP server: BrowserGenie MCP Server
Ports
Service | Host port | Container port | Notes |
PostgreSQL | 5433 | 5432 | Non-default; avoids local Postgres conflicts |
App health HTTP (Docker) | 8091 | 8081 |
|
MCP HTTP (Docker) | 8092 | 8082 |
|
Local MCP uses stdio by default (no TCP port). bun run dev:http listens on 8081 / 8082 on the host (dashboard at http://localhost:8081/dashboard).
Quick start (local MCP)
bun install
bun run typecheck
bun run devDocker + PostgreSQL quickstart
Persistence is optional. Active browser/page sessions stay in-memory for speed; recordings and test reports flush to Postgres on browser close when enabled.
# 1. Start Postgres (host port 5433)
cp .env.example .env
bun run docker:up
# 2. Apply migrations
bun run db:migrate
# 3. Enable persistence and start MCP server
export DATABASE_URL=postgresql://oltest:oltest@localhost:5433/olteststack
bun run devSessions persist automatically when DATABASE_URL is set. Unsaved sessions expire after SESSION_TTL_HOURS (default 24h); call save_session or use the dashboard to keep them.
Stop infrastructure:
bun run docker:downOptional: run the app container (health on host 8091, MCP on 8092). Run migrations first, then start the full stack:
docker compose run --rm migrate
bun run docker:app
curl http://localhost:8091/health
open http://localhost:8091/dashboardIf the app container restarts in a loop with column "saved" does not exist, apply pending migrations to the existing Postgres volume:
docker compose run --rm migrate
docker compose up -d --buildOverride host ports in .env via APP_HOST_PORT and MCP_HOST_PORT if 8091/8092 are taken.
Run migrations inside Docker:
docker compose run --rm migrateProduction warning: Default credentials in
.env.example(oltest/oltest) are for local development only. ChangePOSTGRES_USER,POSTGRES_PASSWORD, andDATABASE_URLbefore deploying.
Run the MCP server
bun run devOr after building:
bun run build
bun run startThe server communicates over stdio — do not pipe logs to stdout (stderr only for diagnostics).
When DATABASE_URL is set, the server validates the connection at startup and writes reports/events to PostgreSQL on browser_close unless PERSIST_RECORDING=false. Ephemeral sessions auto-delete after SESSION_TTL_HOURS unless promoted via save_session.
Cursor MCP configuration
Add to your Cursor MCP settings (.cursor/mcp.json or Cursor Settings → MCP):
{
"mcpServers": {
"olteststack": {
"command": "bun",
"args": ["run", "dev"],
"cwd": "/Users/kartikbazzad/OLTestStack",
"env": {
"PERSIST_RECORDING": "false"
}
}
}
}Replace cwd with the absolute path to this project on your machine. Set DATABASE_URL for Postgres persistence (default on when set). Use PERSIST_RECORDING=false to disable writes.
Available tools (V1.3 — 35)
Category | Tools |
Browser |
|
Page |
|
Elements |
|
Actions |
|
Inspection |
|
Monitoring |
|
Waiting |
|
Assertions |
|
Session |
|
Debug |
|
Example flow
browser_launch → page_create → page_navigate → page_find → page_type → page_click → page_wait → page_screenshot → browser_closeEnvironment variables
Variable | Default | Description |
|
| Default headless mode |
| auto | Custom Chromium binary |
|
| General operation timeout |
|
| Navigation/reload timeout |
|
| Screenshot output directory |
|
| Allowed server-local paths for |
| — | PostgreSQL connection string ( |
|
| Set |
|
| Hours until unsaved sessions are auto-deleted |
|
| Documented default host port for local Docker Postgres |
| — | App listen port for health + dashboard (8081; container side in Docker) |
|
| Session dashboard at |
|
| Docker host port mapped to |
|
| App listen port for MCP HTTP |
|
| Docker host port mapped to |
|
| Docker Compose Postgres credentials |
Project structure
src/
├── core/ # Types, errors, registry, config, recording
├── cdp/ # Puppeteer CDP adapter
├── db/ # Drizzle schema, migrations runner, persistence
├── dashboard/ # Session dashboard UI + REST API
├── domain/ # Business logic (browser, page, elements)
├── health/ # Optional HTTP health endpoint
└── mcp/ # MCP server, tool registrationScripts
Script | Description |
| Start MCP server (HTTP) + dashboard on 8081 |
| Dashboard + health only (no MCP) on 8081 |
| Start MCP server (stdio) |
| Compile TypeScript to |
| Type-check without emit |
| Run tests |
| End-to-end MCP smoke test (HTTP transport) |
| Full MCP tool-flow test via SDK client (no curl) |
| Same as |
| Start Postgres via Docker Compose |
| Build and start MCP app container (HTTP on host 8091/8092) |
| Stop Docker Compose services |
| Apply Drizzle SQL migrations |
| Generate migrations from schema |
| Open Drizzle Studio (DB GUI) |
Documentation
Agent-focused guides for MCP setup, tool reference, workflows, and Cursor skills:
Session Dashboard — browse persisted test reports and timelines
MCP Server Setup — install, configure Cursor/Claude, troubleshoot
MCP Tools Reference — schemas, examples, error codes
Agent Workflows — recommended patterns for AI agents
Skills — Cursor Agent Skills for browser testing
Cursor setup: project skills (.cursor/skills/) and subagents (.cursor/agents/) ship with the repo; OLTestStack rules live at user level (~/.cursor/rules/olteststack-mcp-usage.mdc, olteststack-typescript.mdc) — see Guides index.
Smoke test
Verify MCP connectivity and core browser flow:
bun run smoke # quick: launch → navigate → elements → close
bun run test:mcp # full tool flow via MCP SDK (no curl)Uses HTTP transport (spawns a local server if none is running). Set CHROMIUM_EXECUTABLE_PATH if Puppeteer's bundled Chromium is unavailable.
What's next
V1 is feature-complete (26 MCP tools, dashboard, session TTL, script export/playback). CI runs on push/PR via .github/workflows/ci.yml. Remaining: push uncommitted work to GitHub, Docker image publish, and V1.2 enhancements (query capture at record time, variable substitution). See docs/plans/v1-implementation-plan.md and docs/plans/session-script-playback.md.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/openlearnia/OLTestStack'
If you have feedback or need assistance with the MCP directory API, please join our Discord server