teamcity
v2.16.1MCP server exposing JetBrains TeamCity CI/CD workflows to AI coding assistants
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
ping
Test MCP server connectivity. Returns a confirmation echo and optional message.
| Parameter | Type | Description |
|---|---|---|
message | string | Optional message to echo back |
get_mcp_mode
Get the current MCP mode. Dev mode is read-only; full mode enables all operations.
set_mcp_mode
Switch MCP mode at runtime. Returns previous and current modes with the updated tool count; idempotent and notifies clients of the list change.
| Parameter | Type | Description |
|---|---|---|
mode * | string | Target mode: dev (read-only) or full (all operations) |
list_projects
List TeamCity projects. Supports pagination and locator filtering.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
fields | string | Optional fields selector for server-side projection |
locator | string | Optional locator to filter projects |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
parentProjectId | string | Filter by parent project ID |
get_project
Get details of a specific project.
| Parameter | Type | Description |
|---|---|---|
projectId * | string | Project ID |
list_builds
List TeamCity builds. Supports pagination and locator filtering.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
branch | string | Filter by branch (logical or VCS name) |
buildTypeId | string | Filter by build type ID |
count | number | Deprecated: use pageSize |
fields | string | Optional fields selector for server-side projection |
locator | string | Optional build locator to filter builds |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
projectId | string | Filter by project ID |
status | string | Filter by status |
get_build
Get details of a specific build. Works for queued, running, and finished builds.
| Parameter | Type | Description |
|---|---|---|
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
trigger_build
Trigger a new build; runs asynchronously, use `wait_for_build` to monitor. Returns the queued build id; returns 404 if buildTypeId is unknown.
| Parameter | Type | Description |
|---|---|---|
buildTypeId * | string | Build type ID to trigger |
agentId | integer | Run the build on the agent with this id (optional, excludes agentName) |
agentName | string | Run the build on the agent with this name, e.g. "ciagent-h08" (optional) |
branchName | string | Branch to build (optional) |
comment | string | Build comment (optional) |
moveToTop | boolean | Put the build at the top of the queue instead of the end (optional, defaults to false) |
properties | object | Optional build parameters to set when triggering the build |
cancel_queued_build
Cancel a queued (not-yet-running) build. Idempotent; returns 404 if the build already started or was cancelled.
| Parameter | Type | Description |
|---|---|---|
buildId * | string | Queued build ID |
cancel_build
Cancel or stop a running or queued build, with optional comment and requeue flag. Returns the cancelled build; returns 404 if the build is unknown.
| Parameter | Type | Description |
|---|---|---|
buildId * | string | Build ID |
comment | string | Optional cancellation comment |
readdIntoQueue | boolean | If true, a new identical build will be queued after cancel (running builds only). Defaults to false. |
get_build_pin
Get the pin status of a build, including comment, user and time. Finds build numbers on any branch; returns an error if a number matches several builds.
| Parameter | Type | Description |
|---|---|---|
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
set_build_pin
Set the pin status of a build; the TeamCity cleanup keeps a pinned build and its artifacts. Idempotent; pinning again replaces the comment. Returns the buildId and the new pin status; returns 404 if the build is unknown.
| Parameter | Type | Description |
|---|---|---|
pinned * | boolean | true to pin, false to unpin |
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
comment | string | Pin comment (only used when pinning) |
list_pinned_builds
List pinned builds with pin comment, user and time on all branches, including canceled and personal builds. Filter by build configuration or project; supports pagination.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
buildTypeId | string | Only builds of this build configuration |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
projectId | string | Only builds of this project and its subprojects |
get_build_status
Get build status. Optionally includes test and problem summaries plus queue context.
| Parameter | Type | Description |
|---|---|---|
buildId | string | Build ID |
buildNumber | string | Human build number (requires buildTypeId when provided) |
buildTypeId | string | Build configuration identifier (required when using buildNumber) |
includeProblems | boolean | Include build problems |
includeQueueReason | boolean | Include waitReason for the queued item (extra API call when queued) |
includeQueueTotals | boolean | Include total queued count (extra API call when queued) |
includeTests | boolean | Include test summary |
wait_for_build
Wait for a build to reach a terminal state (finished, canceled, failed). Long-running; polls until completion or timeout.
| Parameter | Type | Description |
|---|---|---|
buildId | string | Build ID to wait for |
buildNumber | string | Human build number (requires buildTypeId) |
buildTypeId | string | Build configuration ID (required with buildNumber) |
includeProblems | boolean | Include build problems in result |
includeTests | boolean | Include test summary in result |
pollInterval | number | Seconds between polls (default 15, min 5) |
timeout | number | Max seconds to wait (default 600, max 3600) |
fetch_build_log
Fetch a build log. Supports line-based pagination and streaming output.
| Parameter | Type | Description |
|---|---|---|
buildId | string | Build ID (TeamCity internal id) |
buildNumber | string | Human build number (e.g., 54). If provided, optionally include buildTypeId to disambiguate. |
buildTypeId | string | Optional build type ID to disambiguate buildNumber |
encoding | string | Response encoding: 'text' (default) or 'stream'. 'stream' writes the whole log, or the requested line range, to outputPath; logs can be several GB |
lineCount | number | Max lines to return (overrides pageSize) |
minFreeDiskMb | number | Streaming only: disk space in MiB that must stay free on the target disk, otherwise the download aborts (default 1024, 0 disables the reserve) |
outputPath | string | Optional absolute path to write streamed logs; defaults to a temp file when streaming |
page | number | 1-based page number |
pageSize | number | Lines per page (default 500) |
startLine | number | 0-based start line (overrides page) |
tail | boolean | Tail mode: return last N lines |
list_build_configs
List build configurations. Supports pagination and locator filtering.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
fields | string | Optional fields selector for server-side projection |
locator | string | Optional build type locator to filter |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
projectId | string | Filter by project ID |
get_build_config
Get details of a build configuration.
| Parameter | Type | Description |
|---|---|---|
buildTypeId * | string | Build type ID |
list_test_failures
List test failures for a build. Supports pagination.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
fields | string | Optional fields selector for server-side projection |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
list_queued_builds
List queued builds. Supports TeamCity queue locator filtering and pagination.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
fields | string | Optional fields selector for server-side projection |
locator | string | Queue locator filter (e.g., project:(id:MyProj)) |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
get_server_info
Get TeamCity server info including version, build number, and state.
get_build_results
Get detailed results of a build. Optionally includes tests, artifacts, changes, statistics, and dependencies.
| Parameter | Type | Description |
|---|---|---|
artifactEncoding | string | Encoding mode for artifacts when includeArtifacts is true |
artifactFilter | string | Filter artifacts by name/path pattern |
buildId | string | Build ID |
buildNumber | Build number when buildId is not available | |
buildTypeId | string | Build configuration ID when resolving by number |
includeArtifacts | boolean | Include artifacts listing and metadata |
includeChanges | boolean | Include VCS changes |
includeDependencies | boolean | Include dependency builds |
includeStatistics | boolean | Include build statistics |
maxArtifactSize | number | Max artifact content size (bytes) when inlining |
list_build_artifacts
List artifact files and directories for a build, optionally browsing into subdirectories. Returns an array of artifact entries with name, path, size, and isDirectory flag.
| Parameter | Type | Description |
|---|---|---|
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
extension | string | Filter by file extension (e.g. "yaml", ".yaml") |
includeNested | boolean | Recursively include all files within subdirectories (default: false) |
nameFilter | string | Glob pattern to filter artifacts by name (e.g. "*.yaml") |
path | string | Sub-path to list (e.g. "okd" or "okd/subdir"). Omit to list top-level artifacts. |
pathFilter | string | Glob pattern to filter artifacts by full path |
download_build_artifact
Download a single build artifact, with base64, text, or streaming output. Returns the artifact bytes or stream metadata; returns 404 if the build or path is unknown.
| Parameter | Type | Description |
|---|---|---|
artifactPath * | string | Artifact path or name |
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
encoding | string | Response encoding: 'base64' (default), 'text', or 'stream' |
maxSize | number | Maximum artifact size (bytes) allowed before aborting |
outputPath | string | Optional absolute path to write streamed content; defaults to a temp file when streaming |
download_build_artifacts
Download multiple build artifacts, with base64, text, or streaming output. Returns per-artifact payloads or stream metadata; returns 404 if the build or any path is unknown.
| Parameter | Type | Description |
|---|---|---|
artifactPaths * | array | Artifact paths or names to download |
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
encoding | string | Response encoding: 'base64' (default), 'text', or 'stream' |
maxSize | number | Maximum artifact size (bytes) allowed before aborting |
outputDir | string | Optional absolute directory to write streamed artifacts; defaults to temp files when streaming |
get_test_details
Get detailed information about test failures.
| Parameter | Type | Description |
|---|---|---|
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
testNameId | string | Test name ID (optional) |
analyze_build_problems
Analyze and report build problems and failures.
| Parameter | Type | Description |
|---|---|---|
buildId | string | Build ID (internal TeamCity ID) |
buildNumber | Human-readable build number (requires buildTypeId) | |
buildTypeId | string | Build configuration ID (required when using buildNumber) |
list_changes
List VCS changes. Supports pagination.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
buildId | string | Filter by build ID via locator helper |
fields | string | Optional fields selector for server-side projection |
locator | string | Optional change locator to filter results |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
projectId | string | Filter by project ID via locator helper |
list_problems
List build problems. Supports pagination.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
buildId | string | Filter by build ID via locator helper |
fields | string | Optional fields selector for server-side projection |
locator | string | Optional problem locator to filter results |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
projectId | string | Filter by project ID via locator helper |
list_problem_occurrences
List build problem occurrences. Supports pagination.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
buildId | string | Filter by build ID via locator helper |
fields | string | Optional fields selector for server-side projection |
locator | string | Optional problem occurrence locator to filter results |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
problemId | string | Filter by problem ID via locator helper |
list_investigations
List open investigations. Supports pagination.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
assigneeUsername | string | Filter by responsible user username via locator helper |
buildTypeId | string | Filter by build configuration ID via locator helper |
fields | string | Optional fields selector for server-side projection |
locator | string | Optional investigation locator to filter results |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
projectId | string | Filter by project ID via locator helper |
list_muted_tests
List muted tests. Supports pagination.
| Parameter | Type | Description |
|---|---|---|
all | boolean | Fetch all pages up to maxPages |
buildTypeId | string | Filter by build configuration ID via locator helper |
fields | string | Optional fields selector for server-side projection |
locator | string | Optional mute locator to filter results |
maxPages | number | Max pages to fetch (when all=true) |
pageSize | number | Items per page (default 100) |
projectId | string | Filter by project ID via locator helper |
testNameId | string | Filter by test name ID via locator helper |
list_branches
List branches for a project or build configuration.
| Parameter | Type | Description |
|---|---|---|
buildTypeId | string | Build type ID |
projectId | string | Project ID |
list_parameters
List parameters for a build configuration.
| Parameter | Type | Description |
|---|---|---|
buildTypeId * | string | Build type ID |
list_project_hierarchy
List project hierarchy showing parent-child relationships.
| Parameter | Type | Description |
|---|---|---|
rootProjectId | string | Root project ID (defaults to _Root) |