navex
A 4 MB HTTP scenario runner with an embedded JS engine. Scrape with CSS selectors, probe a site's forms with validated selectors, replay flows offline, and classify challenge gates instead of guessing.
Documentation
navex

Ultra-light HTTP scenario runner — 5.1 MB binary, ~7 MB RAM, no browser.
Français · Deutsch · Español · Italiano · Português · Nederlands · Polski · Русский · Türkçe · العربية · 中文 · 日本語 · 한국어 · हिन्दी · Indonesia
navex replays declarative HTTP scenarios and produces a machine-readable report.
It is built for CI, QA and behaviour measurement: verify that a service answers,
that a protected page redirects, or that an edge/CDN classifies a client the way
you expect.
Why it exists
Running a full browser to send three HTTP requests is wasteful. navex keeps the useful parts — TLS behaviour, headers, cookies, redirects, an embedded JS engine — and drops the rendering stack.
Features
- Declarative TOML scenarios: steps, regex captures, verdict rules
- Two backends:
builtin(ureq + rustls) andcurl_cffi(browser TLS fingerprint) - Embedded QuickJS engine with a restricted simulated DOM (navigator, screen, canvas, cookies, crypto). Memory and time are bounded; no host object is exposed
- Human input simulation: Bézier mouse paths following Fitts's law, keystroke dwell/flight timings, cursor position preserved across steps
- Configurable session rotation (per run count, on verdict, or after N minutes)
- Optional ad/tracker blocklist to keep the simulated DOM stable
- Resumable JSONL report, plus a local debug UI (
--ui)
Documentation
Full documentation lives in wiki/:
| Page | Content |
|---|---|
| Getting started | install, first run, first scenario |
| CLI reference | every command and flag |
| Scenarios | the TOML format step by step |
| Engines | builtin vs curl_cffi, TLS fingerprints |
| JS engine | QuickJS, simulated DOM, limits |
| Profiles | device coherence, 2^64 configurations |
| Proxies | rotation, verification, exit-IP detection |
| Challenges | 13 types, sitekey extraction, solver config |
| Verdicts | what each outcome means |
| Debug UI | --ui, /state, /metrics |
| Architecture | modules, data flow, isolation |
| Troubleshooting | the errors you will actually hit |
For AI agents
One command to load the operator guide:
curl -s https://raw.githubusercontent.com/pecorio-dev/navex/master/PROMPT.md
MCP server, installed from PyPI:
pip install navex-mcp # 7.5 KB, no required dependency
pip install navex-mcp[fetch] # adds curl_cffi for navex_fetch / navex_google
MCP (stdio) exposes the runner to any agent:
{
"mcpServers": {
"navex": { "command": "python3", "args": ["/path/to/navex/mcp/server.py"] }
}
}
Tools: navex_run (scenario → report), navex_fetch (single request + gate
detection), navex_google (search with gate detection).
Install
cargo build --release
./target/release/navex --help
Quick start
navex run --site scenarios/app.toml
navex run --site scenarios/app.toml --proxies egress.txt --workers 8 --out report.jsonl
navex run --site scenarios/app.toml --var token=abc --cookie-jar session.json
navex run --site scenarios/app.toml --ui 7899
navex extract --url https://example.com --select 'a@href' --all
navex import session.har --out scenarios/site.toml
navex diff before.jsonl after.jsonl
Verdicts
OK, REFUSED, CHALLENGE, AUTH_REQUIRED, RATE_LIMITED, NOT_FOUND,
TIMEOUT, ERREUR.
A detected challenge is never reported as a credential failure: AUTH_REQUIRED
means the site answered and wants a session; CHALLENGE means a bot-defence
layer answered instead of the site.
What it costs
Measured with /usr/bin/time -f %M (peak RSS of the process).
| Use case | RSS | Note |
|---|---|---|
--help | 4.8 MB | bare binary |
| one simple scenario | 7.4 MB | the usual case |
| 4 workers | 7.9 MB | threads are cheap |
dom / page (real DOM) | 13-15 MB | linkedom tree |
[engine] webgl = true | 75 MB | Mesa + driver, opt-in only |
WebGL is off by default for this reason: it costs ten times the rest. A 256 MB VPS will feel it.
Measured
| Metric | Value |
|---|---|
| Release binary | 5 128 064 bytes |
| RSS, 4 workers | 6 908 KB |
| Tests | 61 (58 unit + 1 integration) |
| Live HTTP request | 200, 49 ms |
Responsibility
This is a testing and measurement tool. It ships with no accounts, no credentials and no targets.
The author is not responsible for how it is used. You alone are responsible for complying with the terms of service of the services you query, with applicable law, and with the data you process. Use it only on systems you are authorised to test.
Licence
MIT