aspect mcp runs a Model Context Protocol (MCP) server that gives an AI agent read-only access to your build and test results: builds, their logs, the targets they built and tested, and statistics across builds. An agent can then work out why a build failed, find when a test started flaking or compare two runs by calling tools, without anyone pasting logs into the chat.
The data comes from the build results REST API, on Aspect Cloud or on an Aspect Enterprise deployment running Aspect Workflows 6.0.30 or later with the API enabled.
aspect mcp and speaks MCP on its stdin and stdout; Connect an AI assistant to build results has the setup for Claude Code, Claude Desktop, Codex, Cursor and VS Code.
Flags
How it behaves
- Stdout carries the protocol. The server writes its banner and every diagnostic to stderr, so run in a terminal it prints a banner and waits for a client. Your AI tool’s MCP server log shows those diagnostics.
- It uses your stored login. Each tool call authenticates with the credential
aspect auth loginstored for the deployment and refreshes it as needed, so a long agent session keeps working. There’s no URL or token in the server’s configuration. - It answers with the fix. When you aren’t logged in, or the deployment doesn’t serve the API, the tool call returns an error naming the command to run or the requirement to meet. The server checks again on the next call, so tools start working once the API is enabled, without restarting the client.
- It only reads. No tool starts, cancels or changes a build.
Tools
Builds are addressed by the
id these tools return, not by the invocation ID Bazel printed. The server tells the agent to resolve one to the other with list_invocations, so you can hand it a UUID from a CI log directly. Addressing a build explains why the two differ.
