---
title: "AI Integration Quick Start"
language: "en"
url: "https://docs.testany.io/en/docs/ai-integration-quick-start/"
markdown_url: "https://docs.testany.io/en/docs/ai-integration-quick-start.md"
translation: "https://docs.testany.io/zh/docs/ai-integration-quick-start.md"
last_updated: "2026-02-07T18:19:37+08:00"
---

# AI Integration Quick Start

## Quick Start

Get Testany AI integration working in 5 minutes.

### Prerequisites

- An AI assistant (Claude Code, GitHub Copilot, VS Code Copilot, etc.)
- A Testany account with API access

---

### Step 1: Get Your API Token

1. Log in to Testany Platform
2. Click your avatar in the top right corner
3. Select **Settings**
4. Find the **Developer Settings** section
5. Click **Create Token** to generate a new token
6. Copy the token (format: `ta_live_xxxxxxxxxxxx`)


> **Warning**
>
> Keep your API token secure. Never commit it to version control or share it publicly.


---

### Step 2: Install Testany MCP


> **Tip**
>
> The Testany MCP toolset consumes approximately 6000 tokens of context. Recommendations:
> - **Project-level installation (Recommended)**: Only enable in projects that need it to avoid wasting tokens in unrelated projects
> - **User-level installation**: Choose global installation if you need Testany across multiple projects


Choose your AI assistant below and follow the platform-specific instructions.

**Testany MCP Endpoints:**
| Environment | URL |
|-------------|-----|
| China | `https://<tenant_name>.testany.com.cn/mcp` |
| International | Coming soon |

Replace `<tenant_name>` with your organization's tenant name.

---

#### Claude Code

Project-level installation (run in project directory):

```bash
claude mcp add --transport http testany https://<tenant_name>.testany.com.cn/mcp \
  --header "Authorization: Bearer ta_live_YOUR_TOKEN"
```

> User-level installation: Add `--scope user` to enable globally.

Verify installation:

```bash
claude mcp list
```

---

#### Claude Desktop

**Method A: Using Settings > Connectors (Recommended)**

1. Open Claude Desktop
2. Go to **Settings** → **Connectors**
3. Add a new connector with your Testany MCP URL and credentials

**Method B: Using mcp-remote bridge (Legacy)**

Edit `~/Library/Application Support/Claude/claude_desktop_config.json` (macOS):

```json
{
  "mcpServers": {
    "testany": {
      "command": "npx",
      "args": [
        "mcp-remote",
        "https://<tenant_name>.testany.com.cn/mcp",
        "--header",
        "Authorization: Bearer ta_live_YOUR_TOKEN"
      ]
    }
  }
}
```

---

#### OpenAI Codex

Create `.codex/config.toml` in your project directory:

```toml
[mcp_servers.testany]
url = "https://<tenant_name>.testany.com.cn/mcp"

[mcp_servers.testany.http_headers]
Authorization = "Bearer ta_live_YOUR_TOKEN"
```

> User-level installation: Place the config file at `~/.codex/config.toml`.
>
> You can also use environment variables: Replace the `http_headers` section with `bearer_token_env_var = "TESTANY_API_KEY"`, then set `export TESTANY_API_KEY="ta_live_YOUR_TOKEN"`.

---

#### Google Gemini CLI

Edit `~/.gemini/settings.json` (Gemini CLI only supports user-level configuration):

```json
{
  "mcpServers": {
    "testany": {
      "url": "https://<tenant_name>.testany.com.cn/mcp",
      "headers": {
        "Authorization": "Bearer ta_live_YOUR_TOKEN"
      }
    }
  }
}
```

---

#### VS Code (GitHub Copilot)

Create `.vscode/mcp.json` in your project directory:

```json
{
  "servers": {
    "testany": {
      "type": "http",
      "url": "https://<tenant_name>.testany.com.cn/mcp",
      "headers": {
        "Authorization": "Bearer ${input:testany-token}"
      }
    }
  },
  "inputs": [
    {
      "id": "testany-token",
      "type": "promptString",
      "description": "Testany API Token",
      "password": true
    }
  ]
}
```


> **Note**
>
> **Token Input Mechanism**: The `${input:testany-token}` in the configuration is a VS Code secure input variable. When you first use the MCP server, VS Code will prompt you to enter the token. Once entered, it's securely stored in VS Code and you won't need to enter it again.


> **User-level installation**: Open user-level config via Command Palette `Cmd+Shift+P` → Search "MCP: Open User Configuration".

---

#### Cursor

Create `.cursor/mcp.json` in your project directory:

```json
{
  "mcpServers": {
    "testany": {
      "url": "https://<tenant_name>.testany.com.cn/mcp",
      "headers": {
        "Authorization": "Bearer ta_live_YOUR_TOKEN"
      }
    }
  }
}
```

> User-level installation: Place the config file at `~/.cursor/mcp.json`.

---

#### TRAE

Create `.trae/mcp.json` in your project directory:

```json
{
  "mcpServers": {
    "testany": {
      "url": "https://<tenant_name>.testany.com.cn/mcp",
      "headers": {
        "Authorization": "Bearer ta_live_YOUR_TOKEN"
      }
    }
  }
}
```

> User-level installation: Add via TRAE's "Add MCP Servers" UI, or place the config in the global configuration file.

---

**Replace** `ta_live_YOUR_TOKEN` with your actual API token from Step 1

---

### Step 3: Install Testany Skills (Optional)


> **Info**
>
> Skills are specialized instruction sets that help AI assistants better understand and execute Testany-related tasks. After installation, you can use shortcut commands like `/case`, `/pipeline`, `/tests`.
>
> This step is optional. Even without Skills, you can still use Testany MCP tools via natural language.


#### Choose Your Plugin

The [testany-agent-skills](https://github.com/TestAny-io/testany-agent-skills) repository contains the **testany-bot** plugin for test platform integration:

| Plugin | Architecture | Supported Platforms |
|--------|--------------|---------------------|
| **testany-bot** | Self-contained Skills | All platforms (Claude Code, Codex, Gemini CLI, VS Code Copilot, Cursor, TRAE) |

---

#### Claude Code

**Method A: Install from Marketplace (Recommended)**

```bash
# 1. Add Marketplace
/plugin marketplace add TestAny-io/testany-agent-skills

# 2. Open plugin manager and select testany-bot to install
/plugin
```

In the plugin manager, select `testany-bot`, then choose the installation scope (project or user level).

**Method B: Manual Configuration**

```bash
git clone https://github.com/TestAny-io/testany-agent-skills.git
```

Edit `.claude/settings.json` (project-level):

```json
{
  "plugins": ["./testany-agent-skills/plugins/testany-bot"]
}
```

> User-level installation: Edit `~/.claude/settings.json` with an absolute path.

---

#### OpenAI Codex

```bash
git clone https://github.com/TestAny-io/testany-agent-skills.git
mkdir -p .codex/skills
cp -r testany-agent-skills/plugins/testany-bot/skills/* .codex/skills/
```

> User-level installation: Copy to `~/.codex/skills/`.

---

#### Google Gemini CLI


> **Note**
>
> Agent Skills is an experimental feature (v0.23.0+). Enable `experimental.skills` in `/settings`.


```bash
git clone https://github.com/TestAny-io/testany-agent-skills.git
mkdir -p .gemini/skills
cp -r testany-agent-skills/plugins/testany-bot/skills/* .gemini/skills/
```

> User-level installation: Copy to `~/.gemini/skills/`.

---

#### VS Code (GitHub Copilot)


> **Note**
>
> Agent Skills is an experimental feature. Enable `chat.useAgentSkills` in VS Code settings.


```bash
git clone https://github.com/TestAny-io/testany-agent-skills.git
mkdir -p .github/skills
cp -r testany-agent-skills/plugins/testany-bot/skills/* .github/skills/
```

---

#### Cursor

```bash
git clone https://github.com/TestAny-io/testany-agent-skills.git
mkdir -p .cursor/rules
cp -r testany-agent-skills/plugins/testany-bot/skills/* .cursor/rules/
```

> User-level installation: Copy to `~/.cursor/rules/`.

---

#### TRAE

```bash
git clone https://github.com/TestAny-io/testany-agent-skills.git
mkdir -p .trae/skills
cp -r testany-agent-skills/plugins/testany-bot/skills/* .trae/skills/
```

---

#### Claude Desktop

Claude Desktop supports Skills, but requires uploading a .zip file via the UI:

1. Package `testany-agent-skills/plugins/testany-bot/skills` directory as a .zip file
2. In Claude Desktop, go to **Settings** → **Skills**
3. Click **Upload** to upload the .zip file

---

### Step 4: Verify Installation

#### Claude Code

```bash
# Check MCP tools (should show 59 testany_* tools)
/mcp

# Check Skills (should show /case, /pipeline, /tests, etc.)
/skills
```

#### Other Platforms

Check your platform's MCP and skills status according to its documentation.

---

### Step 5: Try Your First Command

```
/case create an API test for health check
```

Or use natural language:

```
Show me my test pipelines
```

---

## Quick Reference

### Available Skills

| Skill | Description | Example |
|-------|-------------|---------|
| `/case` | Manage test cases | `/case create an API test` |
| `/pipeline` | Manage pipelines | `/pipeline create regression suite` |
| `/tests` | Execute and monitor | `/tests Y2K-0001A` |
| `/debug` | Analyze failures | `/debug Y2K-0001A-0000B` |
| `/orchestrator` | Test orchestration | `/orchestrator create quality gate` |
| `/workspace` | Workspace management | `/workspace add member` |

---

## Troubleshooting

| Issue | Solution |
|-------|----------|
| "Connection failed" | Check your API token and domain URL |
| MCP tools not showing | Restart your AI assistant after configuration |
| Skills not available | Verify the plugin path in your configuration |
| "Unauthorized" error | Regenerate your API token |

---

## Next Steps

- Explore the [Resources](https://docs.testany.io/en/docs/ai-integration-resources.md) page for detailed documentation
- Check the GitHub repos for the latest updates

## Glossary terms on this page

- [User](https://docs.testany.io/en/docs/glossary.md#user)
- [Environment](https://docs.testany.io/en/docs/glossary.md#environment)
- [Command](https://docs.testany.io/en/docs/glossary.md#command)
- [Path](https://docs.testany.io/en/docs/glossary.md#path)
- [Test Case](https://docs.testany.io/en/docs/glossary.md#test-case)
- [Workspace](https://docs.testany.io/en/docs/glossary.md#workspace)
