Allure TestOps MCP Server

Allure TestOps MCP Server

Enables natural language interaction with Allure TestOps API for managing test cases, launches, and test plans with full CRUD support and 56+ controller endpoints.

Category
访问服务器

README

Allure TestOps MCP Server (Python)

Model Context Protocol server for Allure TestOps API, written in Python.

Overview

This MCP server provides a Python implementation for interacting with Allure TestOps API through the Model Context Protocol. It supports full CRUD operations for test cases, launches, and test plans, along with 56+ controller endpoints for comprehensive Allure TestOps integration.

Installation

Prerequisites

  • Python 3.10 or higher
  • Poetry package manager

Setup

  1. Clone the repository:
git clone <repository-url>
cd allure_testops/mcp/python
  1. Install dependencies:
poetry install
  1. Set up environment variables (see Configuration section below)

Configuration

Set the following environment variables:

  • ALLURE_TESTOPS_URL: Base URL of your Allure TestOps instance (e.g., https://your-allure-instance.com)
  • ALLURE_TOKEN: API token for authentication (generate in Allure TestOps user settings)
  • PROJECT_ID: Default project ID (numeric string, e.g., "1")

Using Environment Variables

export ALLURE_TESTOPS_URL='https://your-allure-instance.com'
export ALLURE_TOKEN='your-api-token'
export PROJECT_ID='1'

Using .env File (Recommended)

Create a .env file in the project root:

ALLURE_TESTOPS_URL=https://your-allure-instance.com
ALLURE_TOKEN=your-api-token
PROJECT_ID=1

Note: Never commit .env files to version control. Use .env.example as a template.

Usage

Running the MCP Server

Run the server directly:

poetry run python index.py

The server will run on stdio and communicate via the Model Context Protocol.

Standalone Scripts

The repository includes utility scripts:

  • get_open_launches.py - Fetch all open launches from Allure TestOps
poetry run python get_open_launches.py

MCP Configuration

Add to your mcp.json (typically located in ~/.cursor/mcp.json or similar):

{
  "mcpServers": {
    "allure-testops-python": {
      "command": "python3",
      "args": [
        "/absolute/path/to/index.py"
      ],
      "env": {
        "ALLURE_TESTOPS_URL": "https://your-allure-instance.com",
        "ALLURE_TOKEN": "your-api-token",
        "PROJECT_ID": "1"
      }
    }
  }
}

Available Tools

Test Cases

  • list_test_cases - List all test cases in the project
  • get_test_case - Get a specific test case by ID
  • create_test_case - Create a new test case
  • update_test_case - Update an existing test case
  • delete_test_case - Delete a test case
  • bulk_create_test_cases_from_csv - Bulk create test cases from CSV

Launches

  • list_launches - List all launches in the project
  • get_launch - Get a specific launch by ID
  • create_launch - Create a new launch
  • update_launch - Update an existing launch
  • delete_launch - Delete a launch
  • close_launch - Close a launch

Test Plans

  • list_test_plans - List all test plans in the project
  • get_test_plan - Get a specific test plan by ID
  • create_test_plan - Create a new test plan
  • update_test_plan - Update an existing test plan
  • delete_test_plan - Delete a test plan

Features

  • ✅ Full Allure TestOps API integration
  • ✅ 56+ controller endpoints
  • ✅ Async/await support for high performance
  • ✅ Type-safe tool definitions
  • ✅ Comprehensive error handling
  • ✅ CSV import support for bulk operations

Project Structure

.
├── index.py                 # Main MCP server entry point
├── allure_client.py         # HTTP client for Allure TestOps API
├── csv_parser.py           # CSV parsing utilities
├── controllers/            # API controller modules
├── get_open_launches.py   # Utility script for fetching open launches
├── pyproject.toml         # Poetry configuration
├── poetry.lock          # Lock file for dependencies
└── README.md              # This file

Development

Testing

Run the test scripts:

poetry run python test_simple.py
poetry run python test_mcp.py

See TESTING.md and QUICK_TEST.md for more details.

Security Notes

  • Never commit API tokens or credentials to version control
  • Use environment variables or secure secret management
  • The .gitignore file excludes sensitive files by default
  • Rotate API tokens regularly

Contributing

Contributions are welcome! Please ensure:

  1. Code follows Python best practices
  2. All tests pass
  3. No sensitive data is included in commits
  4. README is updated for new features

License

See LICENSE file for details.

Support

For issues and questions:

  • Check the documentation in TESTING.md and QUICK_TEST.md
  • Review Allure TestOps API documentation
  • Open an issue in the repository

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选