
团队 MCP 服务器
概览
一个全面的"模型背景协议"(MCP)服务器,将JetBrains TeamCity暴露为LLM代理和IDE插件的结构化的AI-准备资源和工具. TeamCity MCP服务器被设计为与Cursor等AI动力IDE无缝工作. 这是如何配置它: :健康端点应返回{"状态":"ok"} MCP端点应返回初始化响应. - :完整 JSON-RPC 2. 0 超过 HTTP/WebSocket 支持 - : 完成 REST API 集成 认证 - : 项目,构建类型,构建,代理,以及文物 - :触发,取消,针构建,设置标记,下载文物,搜索 - : 全面构建搜索,包含多个过滤器(状态,分支,用户,日期,标记) - :多克,库伯内特斯,监控,缓存,以及综合记录 - : 不需要配置文件, 所有通过环境变量 – : 提供真实的当前日期/时间来阻止AI模型使用培训数据日期 。 使用包含的校验脚本测试全部...
概述(AI 翻译)
一个全面的"模型背景协议"(MCP)服务器,将JetBrains TeamCity暴露为LLM代理和IDE插件的结构化的AI-准备资源和工具.
□ 快开始
QQ IDE 集成( 课程)
TeamCity MCP服务器被设计为与Cursor等AI动力IDE无缝工作. 这是如何配置它:
QQ 光标配置
将此添加到您的光标 MCP 设置 :
□ 地方发展
- 构建服务器
2. 设置环境变量
QQ 3. 运行服务器
QQ 4. 测试服务器
** 预期成果**: 健康端点应当返回[T0],MCP端点应当返回初始化反应.
□ 特性
- ** MCP协议遵守情况**:HTTP/WebSocket支持的JSON-RPC 2.0完整
- ** TeamCity 集成**: 完成REST API集成认证
- ** 资源存取**:项目、建筑类型、建筑、代理和文物
- ** 建设业务**: 触发、取消、建立针头、设置标签、下载文物、建立搜索
- ** 高级搜索**:使用多个过滤器(状态、分支、用户、日期、标记)的综合构建搜索
- ** 生产准备**:多克克、库伯内特、监测、缓存和全面伐木
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
TeamCity MCP Server
A comprehensive Model Context Protocol (MCP) server that exposes JetBrains TeamCity as structured AI-ready resources and tools for LLM agents and IDE plugins.
Quick Start
IDE Integration (Cursor)
The TeamCity MCP server is designed to work seamlessly with AI-powered IDEs like Cursor. Here’s how to configure it:
Cursor Configuration
Add this to your Cursor MCP settings:
{
"mcpServers": {
"teamcity": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"-e",
"TC_URL",
"-e",
"TC_TOKEN",
"itcaat/teamcity-mcp:latest",
"--transport",
"stdio"
],
"env": {
"TC_URL": "https://your-teamcity-server.com",
"TC_TOKEN": "your-teamcity-api-token"
}
}
}
}
Local Development
1. Build the Server
make build
# This creates ./bin/teamcity-mcp and a symlink ./server
2. Set Environment Variables
# Required
export TC_URL="https://your-teamcity-server.com"
# Optional (enables HMAC authentication)
export SERVER_SECRET="your-hmac-secret-key"
# Authentication
export TC_TOKEN="your-teamcity-api-token"
3. Run the Server
./server
# Server starts on :8123 by default
4. Test the Server
# Health check
curl http://localhost:8123/healthz
# MCP protocol test
curl -X POST http://localhost:8123/mcp \
-H "Content-Type: application/json" \
-H "Authorization: Bearer your-hmac-secret-key" \
-d '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-03-26","capabilities":{}}}'
Expected result: Health endpoint should return {"status":"ok"} and MCP endpoint should return initialization response.
Features
- MCP Protocol Compliance: Full JSON-RPC 2.0 over HTTP/WebSocket support
- TeamCity Integration: Complete REST API integration with authentication
- Resource Access: Projects, build types, builds, agents, and artifacts
- Build Operations: Trigger, cancel, pin builds, set tags, download artifacts, search builds
- Advanced Search: Comprehensive build search with multiple filters (status, branch, user, dates, tags)
- Production Ready: Docker, Kubernetes, monitoring, caching, and comprehensive logging
- Environment-Based Configuration: No config files needed, everything via environment variables
- AI Time Awareness: Provides real current date/time to prevent AI models from using training data dates
Environment Variables Reference
Required Variables
| Variable | Description | Example |
|---|---|---|
TC_URL |
TeamCity server URL | https://teamcity.company.com |
SERVER_SECRET |
HMAC secret for client authentication (optional) | my-secure-secret-123 |
Authentication Variables
| Variable | Description | Example |
|---|
安装
docker run --rm -i -e TC_URL -e TC_TOKEN itcaat/teamcity-mcp:latest --transport stdio配置
{
"mcpServers": {
"teamcity": {
"command": "docker",
"args": [
"run",
"--rm",
"-i",
"-e",
"TC_URL",
"-e",
"TC_TOKEN",
"itcaat/teamcity-mcp:latest",
"--transport",
"stdio"
],
"env": {
"TC_URL": "https://your-teamcity-server.com",
"TC_TOKEN": "your-teamcity-api-token"
}
}
}
}