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

# MCP Server

> Connect AI assistants to Autosana for docs and test management

Connect your AI coding assistant to Autosana for seamless documentation access and test flow management directly from your IDE.

## Configuration

Connect Autosana with your existing account using browser sign-in. Grok Bot and Devin currently use the API-key setup described below.

<Tabs>
  <Tab title="Claude Code">
    Run in your project directory:

    ```bash theme={null}
    claude mcp add --transport http autosana https://mcp.autosana.ai/mcp
    ```

    Open Claude Code, run `/mcp`, select Autosana, and follow the browser sign-in prompt.
  </Tab>

  <Tab title="Claude Desktop">
    In Claude, open **Customize → Connectors → Add custom connector**. Enter **Autosana** as the name and this server URL:

    ```text theme={null}
    https://mcp.autosana.ai/mcp
    ```

    Choose **Connect** and sign in through your browser. Your Claude account must support custom connectors; if the option is disabled, ask your workspace administrator or use another supported client.
  </Tab>

  <Tab title="Cursor">
    Add Autosana to `~/.cursor/mcp.json`, preserving any existing servers:

    ```json theme={null}
    {
      "mcpServers": {
        "autosana": {
          "url": "https://mcp.autosana.ai/mcp"
        }
      }
    }
    ```

    Open Cursor's MCP settings and click **Authenticate** beside Autosana.
  </Tab>

  <Tab title="Gemini CLI">
    Run:

    ```bash theme={null}
    gemini mcp add --transport http autosana https://mcp.autosana.ai/mcp
    ```

    In Gemini CLI, run `/mcp auth autosana` and follow the browser sign-in prompt.
  </Tab>

  <Tab title="Codex">
    Run:

    ```bash theme={null}
    codex mcp add autosana --url https://mcp.autosana.ai/mcp
    codex mcp login autosana
    ```

    If you configure Codex manually, add the following to `~/.codex/config.toml`, then run `codex mcp login autosana`:

    ```toml theme={null}
    [mcp_servers.autosana]
    url = "https://mcp.autosana.ai/mcp"
    ```
  </Tab>

  <Tab title="Dots">
    A dot uses plugins installed in ChatGPT. In ChatGPT on the web, open **Settings → Security and login** and turn on **Developer mode** (Plus, Pro, Business, Enterprise, or Edu). Then open **ChatGPT Plugins**, select **+**, and create an app named **Autosana** with this server URL:

    ```text theme={null}
    https://mcp.autosana.ai/mcp
    ```

    Choose **OAuth** and approve access in your browser. Do not use an API key. In a chat, open **+**, choose **Developer mode**, and select **Autosana**. This connects the app in ChatGPT. It does not add a separate control inside the dot.

    Full walkthrough: [Dots](/dots).
  </Tab>

  <Tab title="Grok Bot">
    Grok Bot has no Settings form for a custom MCP URL, and Autosana is not in the marketplace. Open **[Settings → Integrations → Grok Bot](https://autosana.ai/settings?tab=integrations\&integration=grok-bot)** to create a key, then send this in a Grok Bot chat:

    ```
    Add a custom MCP called Autosana at https://mcp.autosana.ai/mcp with header x-api-key: <YOUR_API_KEY>
    ```

    Approve the confirm card. Next message: `@` Autosana and ask it to list or run a flow. Adding MCP in Cursor does not set up Grok Bot.

    Full walkthrough: [Grok Bot](/grok-bot).
  </Tab>

  <Tab title="Devin">
    In Devin, open **Customize → MCPs → Add a custom MCP**. Choose **HTTP**, not STDIO. Open **[Settings → Integrations → Devin](https://autosana.ai/settings?tab=integrations\&integration=devin)** to create a key, then fill in:

    ```
    Server name: Autosana
    Transport: HTTP
    Server URL: https://mcp.autosana.ai/mcp
    Authentication: Auth Header
    Header key: x-api-key
    Header value: <YOUR_API_KEY>
    ```

    Save, then use **Test listing tools**. Adding MCP in Cursor does not set up Devin.

    Full walkthrough: [Devin](/devin).
  </Tab>

  <Tab title="Hermes Agent">
    Add this under `mcp_servers` in `~/.hermes/config.yaml` (keep any other servers). Hermes opens a browser the first time it connects:

    ```yaml theme={null}
    mcp_servers:
      autosana:
        url: "https://mcp.autosana.ai/mcp"
        auth: oauth
    ```

    Or run `hermes mcp add --url https://mcp.autosana.ai/mcp --auth oauth autosana`. Do not use `--auth header` — that writes `Authorization: Bearer`. Adding MCP in Cursor does not set up Hermes Agent.

    Full walkthrough: [Hermes Agent](/hermes-agent).
  </Tab>

  <Tab title="OpenClaw">
    Run:

    ```bash theme={null}
    openclaw mcp set autosana '{"url":"https://mcp.autosana.ai/mcp","transport":"streamable-http","auth":"oauth"}'
    openclaw mcp login autosana
    ```

    Follow the browser sign-in prompt.
  </Tab>
</Tabs>

In the browser, sign in to Autosana, check the agent name and company, and click **Connect**. The agent can work in any workspace you can access in that company. Return to your agent and ask it to list your Autosana flows.

If the authorization session ends before you approve, start a fresh connection from your agent. Do not reuse the old browser tab.

Existing API-key connections continue to work. To switch one to browser sign-in, remove its `x-api-key` header and reconnect. Keep the key until the new connection works; revoke it only if no other integrations use it.

You may need to restart your agent for the changes to take effect.

***

## Verify the Connection

Once configured, test the server:

```
List all my Autosana flows
```

```
How do suites work in Autosana?
```

If the connection is successful, you'll receive responses from both questions.

***

## Available Tools

The Autosana MCP server provides comprehensive test management, debugging, and documentation access.

### Flow Management

| Tool | Description |
| - | - |
| `flows_list` | List all flows in your organization, optionally filtered by suite |
| `flows_read` | Get details of a specific flow by ID |
| `flows_create` | Create a new test flow with name, instructions, and optional suite |
| `flows_update` | Update an existing flow's name or instructions |
| `flows_delete` | Delete one or more flows (supports batch deletion) |
| `flows_run` | Execute flows, with optional browser and extension loadout overrides |
| `add_hook_to_flow` | Add a setup or teardown hook to a flow |

### Suite Management

| Tool | Description |
| - | - |
| `suites_list` | List all test suites in your organization |
| `suites_read` | Get details of a specific suite by ID |
| `suites_create` | Create a new suite with flows and optional authentication |
| `suites_update` | Update a suite's name, description, or authentication setup |
| `suites_delete` | Delete one or more suites (supports batch deletion) |
| `suites_run` | Execute a suite with optional browser and extension loadout overrides |

### Hook Management

| Tool | Description |
| - | - |
| `hooks_list` | List all hooks in your organization, optionally filtered by flow |
| `hooks_read` | Get details of a specific hook by ID |
| `hooks_create` | Create a new hook with a script (cURL, Python, JS, Shell) |
| `hooks_update` | Update an existing hook's name, script, type, or description |
| `hooks_delete` | Delete one or more hooks (supports batch deletion) |
| `hooks_run` | Execute a hook and wait for results |

To attach a [built-in hook](/guides-otp-testing) such as **Lease email address**, pass `{"type": "builtin", "builtin_key": "lease_email_inbox", "hook_type": "setup"}` in the `hooks` list of `flows_create`, `flows_update`, `suites_create`, or `suites_update`. It's added to your organization automatically if it isn't there yet.

### Apps & Environments

| Tool | Description |
| - | - |
| `apps_list` | List active apps, optionally filtered by platform |
| `apps_read` | Get app details, recent builds, and attached dependencies |
| `apps_register` | Register an iOS, Android, web, or Chrome extension app |
| `builds_upload` | Upload a build from your computer ([details](/upload-build)) |
| `devices_list` | List supported cloud device and OS permutations |
| `environments_list` | List all environments for your organization |

Filter `apps_list` with `platform: "chrome-extension"` to discover extension
apps and their UUIDs.

Use `devices_list` to choose a model and OS. Set `model` or `os_version` to
`"latest"` for explicit rolling resolution, or omit `device` to use the newest
supported default for both.

Both `flows_run` and `suites_run` accept `dependencies` as a JSON array string
for web runs:

```json theme={null}
["extension-app-uuid", {
  "app_id": "another-extension-app-uuid",
  "app_build_id": "exact-extension-build-uuid"
}]
```

Omit `dependencies` to use the web app's attached defaults. Pass `"[]"` to
explicitly run without extensions. An app UUID uses that extension's active
build; an object with `app_build_id` pins the exact build. Extension-enabled
runs use Chromium, and one suite run uses the same extension loadout for every
flow in its shared browser session.

Run responses from `flows_run`, `suites_run`, and `labels_run` include a **Batch** link for viewing or sharing all runs launched together.

To run [code-managed tests](/code-managed-flows) as they are on a branch, pass `repo_full_name` and `branch_name` to `labels_run` or `suites_run`. The run uses that branch's `.autosana/` files, including tests that exist only on the branch, and the newest build uploaded for the branch. A suite that exists only on the branch has no ID yet, so pass `suite_key` (its folder path under `.autosana/`) to `suites_run` instead of `suite_id`. Without a branch, runs use the default branch's tests.

### Workspaces

| Tool | Description |
| - | - |
| `workspaces_list` | List the workspaces in your company and show which one is active |
| `workspaces_switch` | Switch the active workspace to another one in your company |

Every other tool acts in your active workspace. These two tools need a browser sign-in connection. An API key always acts in the workspace it was created in.

Switching applies to your whole Autosana login, not just one agent. The dashboard and any other agent signed in as you switch too.

### Results & Debugging

| Tool | Description |
| - | - |
| `list_suite_runs` | List recent suite run results with optional date filters |
| `list_flow_runs` | List recent flow run results with optional date filters |
| `list_hook_runs` | List recent hook run results with optional date filters |
| `read_suite_run` | Read detailed suite run info showing which flows passed/failed |
| `read_flow_run` | Read run details, actions, review, hooks, and extension build provenance |
| `read_hook_run` | Read detailed hook run info including status and output |

`read_flow_run` reports the exact dependency build IDs and available extension
metadata such as app/build IDs, app name, platform, source, branch, commit, and
upload time.

### Documentation

| Tool | Description |
| - | - |
| `search_autosana_docs` | Search Autosana documentation for information |

***

## Example Usage

#### Generate E2E tests from your codebase

```
Crawl my repo, come up with an E2E testing strategy, and create flows in Autosana
```

#### Increase test coverage from a PR

```
Look at this PR and get us to 80% E2E coverage by writing flows in Autosana
```

#### Debug failing tests

```
My login suite is failing. Help me figure out what's wrong and fix it.
```

#### Create hooks for backend setup

```
Create a setup hook that resets the test database before each flow runs
```

#### Check test run history

```
Show me the last 10 runs of my checkout flow and their success rates
```

#### Identify coverage gaps

```
Look at my Autosana coverage and see where we are missing tests
```

***

## Resources

* [MCP Protocol Specification](https://modelcontextprotocol.io)
* [Claude Code](https://docs.anthropic.com/en/docs/claude-code/mcp)
* [Claude Desktop](https://modelcontextprotocol.io/quickstart/user)
* [Cursor](https://docs.cursor.com/context/model-context-protocol)
* [Gemini CLI](https://google-gemini.github.io/gemini-cli/docs/tools/mcp-server.html)
* [Codex](https://developers.openai.com/codex/mcp/)
* [Dots](/dots)
* [Grok Bot](/grok-bot)
* [Devin](/devin)
* [Hermes Agent](/hermes-agent)
* [OpenClaw](https://docs.openclaw.ai/gateway/configuration)
* [Report an Issue](https://github.com/autosana/autosana/issues)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.