HUB
Sign inSign up
mcp-server logo

reportportal/mcp-server

By reportportal

•Updated 16 days ago

The ReportPortal MCP Server is a bridge between your ReportPortal instance and AI chat assistants

Image
0

10K+

reportportal/mcp-server repository overview

Docker Pulls License Build Status

⁠ReportPortal MCP Server

Official Docker image of the ReportPortal MCP Server⁠ — a Model Context Protocol⁠ server that connects your ReportPortal instance to AI assistants such as Cursor, GitHub Copilot (VS Code, JetBrains), Claude Desktop, and Claude Code.

Ask questions in plain English — "What tests failed in the latest run?", "Run quality gate on launch 12345", "Create a test plan for the current sprint milestone" — and the assistant gets the answers from ReportPortal for you.

⁠Compatibility

MCP serverReportPortal
2.x26.1+ (required for Test Case Management tools)
1.x25.1 and older (service-api 5.x)

⁠Quick start

⁠Local mode (stdio) - single machine usage

Add the server to your AI tool's MCP configuration (mcp.json in Cursor / VS Code, claude_desktop_config.json in Claude Desktop, etc.):

{
  "mcpServers": {
    "reportportal": {
      "command": "docker",
      "args": [
        "run", "-i", "--rm",
        "-e", "RP_API_TOKEN",
        "-e", "RP_HOST",
        "-e", "RP_PROJECT",
        "reportportal/mcp-server"
      ],
      "env": {
        "RP_API_TOKEN": "your-api-token",
        "RP_HOST": "https://your-reportportal-instance.com",
        "RP_PROJECT": "your_project_key"
      }
    }
  }
}

VS Code / JetBrains Copilot use the top-level key servers instead of mcpServers.

Claude Code CLI:

claude mcp add-json reportportal '{"command":"docker","args":["run","-i","--rm","-e","RP_API_TOKEN","-e","RP_HOST","-e","RP_PROJECT","reportportal/mcp-server"],"env":{"RP_API_TOKEN":"your-api-token","RP_HOST":"https://your-reportportal-instance.com","RP_PROJECT":"your_project_key"}}'
⁠Server mode (HTTP) — shared deployment for many users
docker run -d --name reportportal-mcp \
  -p 8080:8080 \
  -e MCP_MODE=http \
  -e RP_HOST=https://your-reportportal-instance.com \
  reportportal/mcp-server

In HTTP mode the server holds no credentials: each client passes its own token and project in request headers.

{
  "mcpServers": {
    "reportportal": {
      "url": "http://your-mcp-server-host:8080/mcp",
      "headers": {
        "Authorization": "Bearer your-api-token",
        "X-Project": "your_project_key"
      }
    }
  }
}

Check that it is up: curl http://localhost:8080/health.

⁠Configuration

⁠Where to get the values
  • RP_HOST — URL of your ReportPortal, including the protocol (e.g. https://reportportal.example.com).
  • RP_API_TOKEN — generate it in ReportPortal: Profile → API Keys. Never commit tokens to version control.
  • RP_PROJECT — the project key (unique identifier), not the display name. You can find it on the project's Settings → General page.
⁠Environment variables

stdio mode (default)

VariableRequiredDescription
RP_HOSTYesReportPortal URL
RP_API_TOKENYesReportPortal API token
RP_PROJECTNoDefault project key. Tools can override it with the projectKey argument

HTTP mode (MCP_MODE=http)

VariableRequiredDescription
MCP_MODEYesstdio (default) or http
RP_HOSTYesReportPortal URL
MCP_SERVER_PORTNoHTTP port (default 8080)
MCP_AUDIT_LOGNotrue/false — JSON audit events to stdout. On by default when OAuth is enabled
RP_MAX_WORKERSNoMax worker goroutines (0 = auto, CPU × 2)
RP_CONNECTION_TIMEOUTNoOutbound connection timeout in seconds (default 30)

RP_API_TOKEN and RP_PROJECT are ignored in HTTP mode — use the Authorization: Bearer <token> and X-Project: <projectKey> request headers instead on MCP client side.

Common (both modes)

VariableRequiredDescription
LOG_LEVELNodebug, info (default), warn, error
RP_INSECURE_TLSNotrue to skip TLS verification for ReportPortal (self-signed certificates). Mutually exclusive with RP_TLS_CA_CERT
RP_TLS_CA_CERTNoPath inside the container to a PEM file with extra trusted CA certificates. Mount it with -v
RP_MCP_ANALYTICS_OFFNotrue to disable usage analytics

OAuth (HTTP mode, optional) — authenticate MCP clients through your corporate IdP (e.g. Microsoft Entra ID) instead of static API keys.

VariableDescription
MCP_OAUTH_ENABLEDtrue to enable OAuth
MCP_PUBLIC_URLPublic URL of the MCP endpoint, e.g. https://mcp.example.com/mcp. Clients must use exactly this URL
MCP_OAUTH_ISSUERhttps://login.microsoftonline.com/{tenant-id}/v2.0
MCP_OAUTH_JWKS_URLhttps://login.microsoftonline.com/{tenant-id}/discovery/v2.0/keys
MCP_OAUTH_AUDIENCEApplication (client) ID of the MCP app registration
MCP_OAUTH_SCOPEScope clients must request, e.g. api://<app-id>/access_as_user

ReportPortal service-api must be configured for the same IdP. See the OAuth section⁠ of the main README for details.

⁠Custom CA certificate example
docker run -i --rm \
  -v /path/to/corp-ca.pem:/certs/ca.pem:ro \
  -e RP_TLS_CA_CERT=/certs/ca.pem \
  -e RP_HOST -e RP_API_TOKEN -e RP_PROJECT \
  reportportal/mcp-server

⁠HTTP endpoints

EndpointPurpose
POST/GET /mcp (alias /api/mcp)MCP protocol (JSON-RPC + SSE stream)
GET /healthHealth check — use it for liveness and readiness probes
GET /info (alias /api/status)Server version and configuration
GET /Server information and available endpoints

⁠Features

  • Launches — list and filter launches, get them by ID or name, update, force-finish, delete, and import from files (JUnit XML, Allure ZIP, etc. through RP import plugins).
  • Analysis — run Auto Analysis, Unique Error Analysis, and Quality Gate on a launch.
  • Test items — browse suites and test items, read logs and attachments (images are returned as images), view execution history, and update defect types in bulk.
  • Test Case Management (2.x, RP 26.1+) — test cases (text or steps scenarios, with attachments), folders, milestones, test plans, manual launches, and execution status updates.

The full list of tools and their parameters is in the README on GitHub⁠.

TMS write tools (create_*, update_*, delete_*, etc.) change data in ReportPortal. Use them with care on important data.

⁠Troubleshooting

SymptomWhat to check
AI tool shows no ReportPortal toolsJSON syntax of the MCP config; restart the AI tool
401 UnauthorizedToken is wrong or expired — generate a new one
403 ForbiddenRP_PROJECT / X-Project must be the project key, and the user must have access to the project
404 in HTTP modeSend requests to /mcp, not to /
Cannot reach a local ReportPortalInside the container localhost is the container itself — use http://host.docker.internal:8080 (Docker Desktop) or --network host (Linux)

⁠License

Apache 2.0⁠

Tag summary
Recent tags
Content type
Image
Digest
sha256:ead2e0047…
Size
14.7 MB
Last updated
16 days ago
docker pull reportportal/mcp-server:latest