Docs › Automation
Running tests from Claude
Connect Claude, or another assistant that takes an MCP server, and ask it to build a test for your site and run it on any environment. It plays the testers on AnyVisitor's browsers for a tenth of the credits.
How it works
You set up sites and tests in the app, or build them with your assistant (below). Your assistant then runs them when you ask: it plays each tester, one screen at a time, in AnyVisitor's browsers, and writes the report. AnyVisitor opens the browser on your environment, times every step as a person would take it, catches slips and misclicks, keeps Done when hidden from the tester until they stop, and scores the run. The report lands under Runs like any other.
No AnyVisitor model runs, so each tester try costs 1 credit instead of 10. Three people on one mission use 3 credits. AI agents count the same: the assistant plays them too, each one seeing only what its kind of agent sees (a screenshot, the page structure, or the page text and links), and AnyVisitor still holds it to its authority, budget and step limit.
1. Save the tests
- Set the test up on Set up: the site, its missions and its testers. Add the environments your assistant should test, such as Staging, with their test details and logins (see Sites and environments).
- Press Save tests in the bar at the bottom. Set up then says Runs on MCP, with how many missions and when they were saved.
A site keeps one saved test, run on whichever environment you name. Saving again replaces it, and keeps missions you switched off switched off. On the site's page, under Saved test, switch each mission between On: runs on MCP and Off: not run on MCP, open it in Set up with Edit the test (or a mission's name, to open it at that mission), or Remove it. Save tests in Set up brings you back to the site's page.
Or build the test with your assistant
Once your assistant is connected (step 2), it can set a site up with you instead of Set up. Ask it to design a test for the site. AnyVisitor opens the site once in its browser, as Set it up for me does, and the assistant comes back with:
- The site: what it is and who comes to it, with the first screen as a picture.
- Missions: the closest template, and two to four missions in the visitors' own words, each with what counts as done, the path you would expect and why it matters.
- Who tests: the census audiences that match, and the device.
- In the way: a sign-in wall, a bot check.
Designing is free: 20 times a day per team, shared with Set it up for me. Then say what you want verified. The assistant suggests from what the site is for, and you decide. For example:
- “Design a test for shop.com and tell me what you would check.”
- “Save that with Dale, Mia and the parents audience, and show it to me first.”
- “Run it on Staging.”
The test is built from the same parts as in Set up: a template's missions, tuned or written from scratch, people, census audiences, AI agents and the settings (tries, the time limit, depth, signed in as, conditions). People you describe who aren't in your Library yet are saved there as personas, for you or for your team, once you've seen the profile; the assistant says which details it made up. Leave the testers out and the template's usual testers run it. Before it saves anything, the assistant shows you the plan in plain words, each mission's task and what counts as done, and who tests. It saves only when you agree. Missions follow the same rules as in the app: the goal in the visitor's own words, never the interface; a Done when you can see on screen; never an irreversible step as the goal. See Writing missions.
Saving merges by mission name: the missions the assistant sends replace the saved tests of the same name, people and agents together, and the rest keep their missions and switches. A saved test has one set of testers, as in Set up: the testers the assistant sends test every mission, the ones it did not send too. People switched off in Set up stay switched off with the test, unless the assistant sends them, which switches them back on. Ask it to replace everything and the saved tests become exactly these. A new address becomes a new site with Production only; environments, logins and test details still come from the site's page under Sites. What the assistant saved shows there under Saved test like any other, and Edit the test opens it in the app.
2. Connect your assistant, once
- In your assistant's settings, choose add a custom connector.
- Paste this address:
https://app.anyvisitor.com/mcp - Approve the sign-in it asks for, with the same emailed code you use in the app.
| Assistant | Where the setting lives |
|---|---|
| Claude (claude.ai and the desktop app) | Settings → Connectors → Add custom connector |
| Claude Code | claude mcp add --transport http anyvisitor https://app.anyvisitor.com/mcp, then /mcp to sign in |
| ChatGPT | Plugins → Add → Create MCP App, with this address (Plus and up) |
Settings › Claude and assistants in the app shows the address with a Copy button, and every assistant connected as you, with Disconnect.
3. Ask
- “Which sites and environments do I have?”
- “Which tests are saved for shop.com, and which are switched off?”
- “Run my tests on shop.com Staging.”
- “Run just the returns test on Staging.”
- “Give me the reports from the last Staging run.”
- “Show me the runs on shop.com.”
- “Run my tests on Staging, then fix what they found in this repo.”
The assistant uses twelve tools: show_runs for a site's run history, get_library, design_test, save_persona and save_test to build a test, and list_sites, start_tests, act (a person), act_agent (an AI agent), judge, finish_run and get_reports to run one. When you name tests, only those run, even ones switched off on the site's page; a mission's name brings its AI-agent test along. It brings up credits only when you ask, and then gives the price from the assistant, not the app's.
What you see in the chat
In Claude and other assistants that draw pages, the answers come with the same cards the app shows: the site's saved tests with their on/off switch, the plan before you save it, your library's personas, and each run. While a run is going, its page follows every tester live, with their newest screenshot and what they are saying, and turns into the report when the run ends. Ask “Show me the runs on shop.com” for the site's run history; click a run to open its report. Claude Code and assistants without pages get the same answers as text.
Independent testers
Each tester gets a fresh sub-agent of its own, with a model to match how hard that person thinks, so no tester knows what another learned. Where an assistant cannot start sub-agents, it plays them one after another in one chat, and the report notes that the testers were not independent.
Who may run tests from an assistant
On the People page, owners choose where each member may start tests: Run from an assistant (MCP), Run here and from CI, or both. Someone who may not run over MCP can still connect an assistant to list sites and read reports. Saving tests from an assistant needs Add and change sites, as Save tests in the app does, and a new site needs Test any site. Saving a persona for the whole team needs Share to the team library, as in the app; anyone can save one for themselves. A site another company shares with you keeps its tests with its owner: you can run them, not change them. See Teams, owners and members.
If something goes wrong
- Signed in with the wrong email: disconnect in Settings › Claude and assistants, then connect again.
- “No tests are saved”: open the site in Set up and press Save tests, or ask your assistant to save some.
- “No template called …”, or a tester it does not know: the assistant guessed a name. Ask it to read your library (
get_library) and try again. - A run needs someone to sign in: open the report link and press Open browser.
- A browser closed during a long pause: that tester starts again from the beginning.
More on the Bring your own AI page.
What's next
- CI and the API: checks that run with nobody watching.