For AI agents: the index of this site is https://dejo.run/llms.txt, and every page is also served as markdown (add .md to its address, or send Accept: text/markdown).

dejo

Tools

The Dejo MCP server gives your agent 5 tools. You don't call them yourself: you ask in plain words, and every reply tells your agent what to do next. This page is for when you want to know what is going on.

Replies are plain text, written for your agent to read. Every reply that is not finished ends with a next: line.

toolwhat it does
dejo_runEvery website task. A known task replays in one call. A new one shows the page, and your agent sends the steps in its next call.
dejo_loginOpens a real browser window so you sign in, however the site asks.
dejo_profileSwitches to another signed-in identity, such as vendor or admin, or lists them.
dejo_memoryReads what Dejo remembers: sites, one task's steps, the site map, shared tasks.
dejo_manageChanges it: forget, add a note, share a task, borrow one.

dejo_run

dejo_run(site, task, url?, steps?, done?, profile?)

  • site: the website, as a domain or a full URL.
  • task: the job in plain words, like "download this month's invoice". It is the task's name. Close wording finds the same task.
  • url: where to start.
  • steps: step lines, one per line (below).
  • done: true saves a task that reads nothing, like "sign in".
  • profile: which signed-in identity to use.

What happens

  1. Dejo knows the task. It replays it and answers in this one call: done: ... 4 steps replayed in 980 ms, no page reading, then the answers. No model calls, no page reading.
  2. The task is new. Dejo opens the page and shows it, one line per control, each with a ref like e12. Your agent sends the steps in its next call. When a step reads the answer, the task is saved by itself.
  3. The site changed. Dejo stops at the one step that broke and shows the page there. Your agent sends one line for that step. Only that step is updated, the old ways to find it stay as backups, and the rest of the task runs in the same call.

Dejo also stops, and says why, when the site wants a sign-in (see Signing in), when a captcha or a "verify you are human" page is in the way, when the site answers with an error page or refuses the browser, or when the browser is not on the page the task starts from. None of these marks the task broken.

Steps

go https://billing.acme.com/invoices
click link "September 2026"
fill label "Search" "acme"
read css ".total" as total

Steps run in order. Dejo stops at the first one that fails, keeps the ones that passed, and shows the page there, so the next call sends only the rest.

stepwhat it does
go URLopens an address
click T, fill T "text", select T "option", check T, press Enterthe usual actions. In a multi-line box, `
` in the text starts a new line
read T as namereads the value your agent will report. This is what Dejo saves.
read count T as name, read all T as namehow many match, or the words of every match
read passage "words" T as namethe section or paragraph inside one long text that says those words
expect url "part", expect text "words", expect see Ta check of your own for the step before it
expect signed in as "you@example.com"the page must show this account; every replay checks it and stops before step 1 if someone else is signed in. See when the site changes
look wordsshows the page, the elements with these words first
back, hover T, wait T, upload T "file", tab Nthe rest. wait T waits for T to appear
js "..."your own JavaScript, alone in its call, never saved into a task
screenshot [T|full], pdfa picture of the screen, one element or the whole page, or the page as a PDF, saved under ~/.dejo/captures. Kept, so every replay saves a new one
look imageputs a picture of the screen in the reply, for a chart, map or canvas
mouse click X Y, mouse drag X Y to X2 Y2, keydown KEY, keyup KEYexact mouse and keys. Options on a click: at=X,Y, keys=Shift, button=right, delay=MS for typing speed
scroll T down 300scroll inside one element, like a chat or a long table
dialog dismiss, dialog accept "answer"how to answer the next alert, confirm or prompt
tab new [URL], tab close [N]open or close a tab (read tabs lists them)
emulate device "iPhone 13", emulate viewport 390x844, emulate locale de-DE, emulate timezone Asia/Tokyo, emulate color dark, emulate offline on, emulate network slow3g, emulate geolocation 18.52,73.85look like another browser or a phone. Kept, so a task learned on a phone replays on a phone. emulate KIND off undoes one
block "**/*.png", header set NAME "VALUE", mock "**/api/user" 200 '{...}'stop the page loading something, send a header, or answer a request with a made-up response for a test
wait request:WORDS, wait response:WORDS, wait "text:Saved|Error"wait for the page's network, or for whichever words come first
cookie set NAME "VALUE", storage set KEY "VALUE", state save NAME, state load NAMEchange cookies or local storage, or save and load a whole sign-in (Playwright's storage-state file). Not kept in a task
record video, record trace, record stoprecord what happens next. The trace opens with npx playwright show-trace FILE
read fields '{"name": "h3", "price": ".price"}' css "article" as items, read table T as rowsmany fields at once, or a whole table, as JSON. No model involved, and it replays
read requests, read console, read cookies, read metrics, read box T, read html Tthe page's network, console, this site's cookies (sign-in cookies stay hidden), load speed, where an element is, its HTML
helplists every step

T is a ref from the page (e12), or role "name" (link "Travel", button "Sign in"), text "...", label "..." or css "...". Add first, last or nth 3 to mean a place in a list rather than one item, so a list in a new order still opens its first item. A name is matched whole first; when nothing has that exact name, Dejo takes the one element whose name contains the words, the way Playwright does, and never guesses between two. Targets also look inside iframes.

Every other tool's features, row by row, and where Dejo has each one: docs/CAPABILITIES.md.

Risky steps

A step that buys, pays, sends, deletes or submits must be marked with !, like click! button "Pay now". Unmarked, Dejo does not do it and says why. Marked, it runs, and it never runs twice on its own, even when a later step fails. After a marked step, Dejo waits for the page to answer and puts what it said in the reply: its message, any request that failed, or that nothing appeared.

A link, a tab or an option only changes what the page shows, so it never needs !, whatever its words say.

Settings

Set these in the env of the Dejo server in your agent's MCP config. All are optional.

settingwhat it does
DEJO_HEADED=1show the browser window, to watch every run live
DEJO_RECORD=video,tracerecord every replay, under ~/.dejo/recordings
DEJO_CDP_URL=http://127.0.0.1:9222drive a browser that is already running: a cloud browser, or your own Chrome started with --remote-debugging-port=9222. Dejo works in a tab of its own and leaves the browser running
DEJO_PROXY=http://proxy.corp:8080send every request through your company's proxy
DEJO_IGNORE_HTTPS_ERRORS=1accept an intranet's own certificate
DEJO_LOCALE=en-INthe language and region the browser tells sites
DEJO_LOG=offstop the step log in ~/.dejo/logs

dejo_login

dejo_login(site, done?, confirmed?)

Opens a real browser window on the site so you sign in there. When you say you are done, your agent calls it again with done: true, Dejo checks the window, and closes it. Details: Signing in.

dejo_profile

dejo_profile(name?)

A profile is a whole signed-in browser. With a name, switches to it (and makes it on first use). Without one, lists them. Each profile keeps its own saved tasks and also reads the default profile's; what Dejo knows about the site (its map and facts) is shared.

dejo_memory

dejo_memory(what, site?, task?, path?)

whatgives back
sitesevery site and task Dejo remembers, and how well each is holding up
showone task, step by step
mapthe pages Dejo has seen on a site; with path, the controls on one of them, ready to use as step targets
commonstasks other agents shared

dejo_manage

dejo_manage(do, site, task?, text?)

dowhat it does
forgetforgets a site, or one task, for good. The next run has nothing to follow and says so.
notekeeps a fact that is not a step, like "needs a code from your phone"
shareleaves a task where other agents can find it. Anything typed into a field, and which account was used, never travel.
borrowcopies a shared task into this agent's memory

The same things from a terminal

The dejo command does most of this without an agent:

dejo run "count open issues" --site github.com
dejo sites
dejo show github.com
dejo map github.com
dejo login --site github.com
dejo forget --site github.com
dejo doctor

dejo --help lists every command.

FAQ

Why does Dejo have only one tool for browsing?

Every action and every read is a step line inside dejo_run. Your agent reads every tool name on every turn, and picking the right tool is the most fragile part of its day, so fewer names means fewer wrong turns.

Does my agent have to call these tools by name?

No. Ask in your own words. The Dejo server tells your agent to call dejo_run for any website task, and every reply ends with a next line that says what to send.

Make your agent remember.

Free and open source. Install it once, and every site your agent learns stays learned.

Get started