To bug bash your app with Mo instead, see Run Mo from a coding agent or
CI.
Create repository tests
For web tests, paste this prompt into your coding agent. It checks your existing setup, installs missing tools, writes one test against your app, and runs it. You provide the first user flow, your app’s URL, and an API key if it finds no key or CLI sign-in.Setup prompt
Review the first test
Review the generated YAML diff and confirm the assertions match the behavior you asked for. Open the run URL the agent returns, check that the run passed, and inspect the screenshot at the assertion step. Resolve a failed or blocked run and rerun the test before adding it to CI.Install the tools yourself
Use these commands to configure an existing project manually. The setup prompt above checks for these tools and installs them when needed.1
Sign in and add MCP
The MCP server gives the agent a live browser or device and tools to browse,
edit, run, and triage tests. Pass
install-mcp detects the coding agents on your
machine and writes the config for each one.--client to pick agents and --scope user to write your user config
instead of the project config. See the MCP page
for manual setup per client.The local momentic and momentic-mobile servers need MOMENTIC_API_KEY
or the saved sign-in from qa login. In Claude Code, select the Momentic
plugin on the Installed tab in /plugin and choose Configure to set the
API key. Tests need a reachable app: a local dev server, a preview deploy,
or staging.2
Install the skills
Skills are markdown instructions that tell the agent how to use the MCP
tools and the Momentic test format. Both CLIs ship the same
See Coding agent skills for install directories,
targets, and update behavior.
momentic-test, momentic-maintain, and momentic-spec skills with web
and mobile references. Replace claude-code with your agent’s target.Write tests from a diff or a user story
Themomentic-spec skill maps
a change to the user journeys it touches. From a pull request diff:
/momentic-spec cover the checkout changes in src/payments/.
From a user story, paste the acceptance criteria after the skill name:
- Writes the test and prepares the accounts, data, and services it needs. If setup is blocked, it reports that instead.
- Runs it once to confirm the expected failure.
- Once the feature works, enables the test and runs the smallest affected set.
Write a mobile test
-
Upload an iOS simulator build or
Android APK to the channel and tag the test
uses:
- Install the tools with the Mobile tabs above.
-
Run
npx momentic-mobile loginso the MCP server can read the saved key. Editors usually don’t inherit your shell environment.
platform: ios and your app’s bundle identifier in openApp:
tests/checkout.test.yaml
--session-idle-timeout-minutes to momentic-mobile mcp to change it.
Gate the pull request on the build it uploads
Gate the pull request on the build it uploads
Upload the branch’s build with a unique tag, then run the tests against that
tag, so the test and the app come from the same commit. For iOS, replace the
APK path below with the path to your simulator The unique tag avoids immutable-tag collisions on reruns. Without
.app directory and use
platform: ios in the test:--channel
and --tag, the run falls back to defaultChannel and defaultTag and can
test a stale build. See
momentic-mobile run.Edit the generated test
Review the YAML in the same pull request as the feature:- Rename the
idto something your team recognizes, then keep it stable. See File format. - Replace a natural-language step with a preset step when the action is exact.
click: Applyperforms one action, where “click the apply button” leaves the path to an AI action. See Steps. - Match each check to the contract. If the story fixes an exact total, verify it with an element-content or JavaScript check, not an AI assertion.
- Move shared setup such as log-in into a module.
- Keep a test that would have caught the change’s bug. Drop one that only re-asserts unchanged behavior.
Skills and the MCP server
The skills explain the test format and authoring workflow. The local MCP server lets the agent inspect your app and try steps while it writes a test. If MCP is unavailable, the setup prompt uses the CLI to validate and run YAML files.qa skills installs the CLI-only mo-qa; its Mo flows use qa login and do
not need MCP. The currently published full Momentic marketplace plugin still
uses a separate MCP-only mo-qa, even in Claude Code or Codex, and bundles
repository-authoring skills and local servers. See the
skills guide for current and pending distribution
status. Hosted-only Claude and OpenAI packages remain MCP-only. The ChatGPT
plugin and Claude.ai connector use hosted MCP with OAuth. For local MCP-only
operations, the optional qa mcp bridge reuses a valid saved CLI login. See
MCP setup.
Invoke a skill by name in your prompt, for example
/momentic-test write a test for checkout. See
Use the skills for the skill list and
more examples.
Use repository instructions
If you use an agent without the skills or MCP server, add these instructions toAGENTS.md, CLAUDE.md, or .cursor/rules. You still need the Momentic CLI to
validate and run the tests: