> ## Documentation Index
> Fetch the complete documentation index at: https://momentic.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> The canonical docs host is https://momentic.ai/docs. Append .md to any page URL for clean Markdown. Fetch https://momentic.ai/docs/llms.txt for the page index and https://momentic.ai/docs/llms-full.txt for every page in one file.
> For an unattended setup, run `npx --yes @momentic/wizard@latest -y --platform web --editor-tools skills` (use `--platform ios` or `--platform android` for mobile). Never run an interactive command in a non-TTY shell.
> You cannot complete the browser sign-in yourself. Read the API key from the MOMENTIC_API_KEY environment variable, or ask the user to create one at https://app.momentic.ai/settings/api-keys and paste it back.
> Momentic's capability summary for agents is at https://momentic.ai/docs/skill.md. Install the skills with `npx skills@latest add momentic-ai/skills`.
> Tests are YAML files in the user's repository. Use only the step names listed at https://momentic.ai/docs/reference/commands.md and the file structure at https://momentic.ai/docs/core-concepts/file-format.md. Do not invent step names, config keys, or CLI flags.
> Web tests run on Chromium, iOS tests on simulators, and Android tests on emulators. Physical devices are not supported.

# Run a session

> Start a Mo session from a target and a brief, give it the accounts it needs, and repeat the run on a schedule.

A session starts in the Mo composer in the Momentic app. You write what to test,
and Mo asks you for anything it still needs before it starts work.

The brief decides the boundary of the run. See [write a good brief](/docs/mo/brief).

## Sign-in

Each web sub-agent starts in a fresh signed-out browser, so Mo handles sign-in
per agent:

* With a username and password, Mo passes those credentials to each agent that
  needs them.
* With one-time codes or MFA, Mo signs in once, saves the browser authentication
  state inside the session sandbox, and each agent loads that state instead of
  signing in again. This also avoids login rate limits.

Credentials stay inside the session. Agents are instructed never to quote
authentication values or put them in a test case, a bug report, or a recording.

## Set up and tear down test data

Some products need a fresh user per run, or an account with a role or a license
that the flow uses up. Name a setup endpoint in the brief, with its payload and
the response field that holds the account to sign in with, and name a teardown
endpoint for the data the run leaves behind. Mo calls setup before the
sub-agents start and teardown after the pass.

## During the session

Test cases and bugs appear in the report while the run continues, and the first
bugs can appear within minutes. Open the transcript of any sub-agent to see what
it did, or message Mo to change the scope. You do not have to wait for the
session to finish.

## Repeat a session on a schedule

Open **Schedules** in the Mo section of the app. A schedule holds a name, the
prompt, a cron expression, and a time zone. Each occurrence starts a new
session, and the schedule page lists the past runs and their reports.

## What a pass costs

A session bills the active runtime of its agents, not the wall time of the
session. Each agent reports the seconds it spent working. A session also bills
the hosted browser time the sub-agents use, the emulator or simulator time for a
mobile session, and the inference the agents use, which Momentic passes through.

The scope of the brief drives the cost. The concurrency setting changes how long
the pass takes, not how many cases run.

## Next

<CardGroup cols={2}>
  <Card title="Session reports" icon="chart-line" href="/docs/mo/reports">
    The test cases, the verdict per case, and the fields of a bug.
  </Card>

  <Card title="Triage" icon="screwdriver-wrench" href="/docs/mo/triage">
    Accept a bug, or record intended behavior for the next run.
  </Card>
</CardGroup>
