Skip to main content
Glama
matchs

Terraform Cloud MCP Server

by matchs

Terraform Cloud MCP Server

Model Context Protocol server providing Terraform Cloud API integration as tools for AI assistants.

Features

This MCP server exposes four main tools for interacting with Terraform Cloud:

  • get_run_status: Get current run status and recent runs for a workspace

  • list_workspaces: List all workspaces in an organization

  • get_workspace_details: Get detailed information about a specific workspace

  • get_run_details: Get detailed information about a specific run by its ID

Related MCP server: Terraform MCP Server

Installation

npm install
npm run build

Configuration

The server reads your Terraform Cloud token from ~/.terraform.d/credentials.tfrc.json. Make sure this file exists with the following format:

{
  "credentials": {
    "app.terraform.io": {
      "token": "your-terraform-cloud-token"
    }
  }
}

Usage

With Claude Desktop

Add to your Claude Desktop configuration (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):

{
  "mcpServers": {
    "terraform-cloud": {
      "command": "node",
      "args": ["/absolute/path/to/tf-cloud-mcp-server/build/index.js"]
    }
  }
}

With MCP Inspector

Test your server with the MCP Inspector:

npx @modelcontextprotocol/inspector node build/index.js

With VS Code

Create a .vscode/mcp.json file in your project:

{
  "servers": {
    "terraform-cloud": {
      "type": "stdio",
      "command": "node",
      "args": ["/absolute/path/to/tf-cloud-mcp-server/build/index.js"]
    }
  }
}

Available Tools

get_run_status

Get the current run status for a Terraform Cloud workspace.

Parameters:

  • workspaceName (string, required): Name of the workspace

  • organization (string, optional): Organization name (default: "urbanmedia")

Example:

Get the run status for workspace "capivara-dpa-importer"

list_workspaces

List all workspaces in a Terraform Cloud organization.

Parameters:

  • organization (string, optional): Organization name (default: "urbanmedia")

Example:

List all workspaces in urbanmedia organization

get_workspace_details

Get detailed information about a specific workspace.

Parameters:

  • workspaceName (string, required): Name of the workspace

  • organization (string, optional): Organization name (default: "urbanmedia")

Example:

Get details for workspace "capivara-dpa-importer"

get_run_details

Get detailed information about a specific Terraform Cloud run by its ID.

Parameters:

  • runId (string, required): Run ID (e.g., "run-abc123")

Example:

Get details for run "run-abc123"

Development

Project Structure

tf-cloud-mcp-server/
├── src/
│   └── index.ts          # Main server implementation
├── build/                 # Compiled JavaScript (generated)
├── package.json
├── tsconfig.json
└── README.md

Running in Development

npm run dev  # Watch mode for TypeScript compilation

Building

npm run build

License

MIT

Available Tools

4 tools
get_run_detailsGet Run DetailsB

Get detailed information about a specific Terraform Cloud run by its ID

ParametersJSON Schema
NameRequiredDescriptionDefault
runIdYesRun ID (e.g., run-abc123)

Output Schema

ParametersJSON Schema
NameRequiredDescription
idYes
sourceYes
statusYes
messageYes
createdAtYes
workspaceYes
hasChangesYes
planStatusNo
applyStatusNo
isConfirmableYes
configurationVersionNo

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states this is a read operation ('Get'), implying it's likely safe and non-destructive, but doesn't specify authentication requirements, rate limits, error conditions, or what 'detailed information' entails (e.g., includes logs, configuration, or status). For a tool with zero annotation coverage, this leaves significant gaps in understanding its behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that directly states the tool's purpose without unnecessary words. It's front-loaded with the core action and resource, making it easy to parse quickly, and every part of the sentence contributes essential information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's low complexity (1 parameter, no nested objects) and the presence of an output schema (which handles return values), the description is reasonably complete for its purpose. However, it lacks context on behavioral aspects like authentication or error handling, which are important for a tool interacting with a cloud service like Terraform Cloud, slightly reducing completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema description coverage is 100%, with the single parameter 'runId' fully documented in the schema as 'Run ID (e.g., run-abc123)'. The description adds no additional parameter details beyond what the schema provides, such as format constraints or examples, so it meets the baseline score of 3 for high schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Get detailed information') and resource ('about a specific Terraform Cloud run by its ID'), making the purpose unambiguous. However, it doesn't explicitly differentiate from sibling tools like 'get_run_status' or 'get_workspace_details', which might offer overlapping or related information about runs or workspaces.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'get_run_status' (which might provide less detailed status info) or 'get_workspace_details' (which might include run info as part of workspace data), leaving the agent to infer usage context based on tool names alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_run_statusGet Run StatusB

Get the current run status for a Terraform Cloud workspace

ParametersJSON Schema
NameRequiredDescriptionDefault
workspaceNameYesWorkspace name
organizationNoOrganization nameurbanmedia

Output Schema

ParametersJSON Schema
NameRequiredDescription
recentRunsYes
workspaceIdYes
currentRunIdNo
workspaceNameYes
currentRunStatusNo

TDQS

B3.1/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It states it's a read operation ('Get'), implying it's non-destructive, but doesn't mention any behavioral traits like authentication requirements, rate limits, error handling, or what 'status' entails (e.g., pending, running, failed). This leaves significant gaps for an agent to understand how to interact with it effectively.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that directly states the tool's purpose without any wasted words. It's appropriately sized and front-loaded, making it easy to parse quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (a read operation with 2 parameters) and the presence of an output schema (which handles return values), the description is minimally adequate. However, it lacks context about behavioral aspects and usage guidelines, which are important for an agent to operate correctly, especially with sibling tools available.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, clearly documenting both parameters ('workspaceName' and 'organization' with a default). The description adds no additional meaning beyond this, such as explaining parameter relationships or usage context. This meets the baseline of 3 since the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('Get') and resource ('current run status for a Terraform Cloud workspace'), making the purpose immediately understandable. However, it doesn't explicitly differentiate from sibling tools like 'get_run_details' or 'get_workspace_details', which likely provide related but different information.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like 'get_run_details' or 'get_workspace_details'. It lacks context about prerequisites, such as needing an existing run or workspace, or any exclusions for when not to use it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

get_workspace_detailsGet Workspace DetailsB

Get detailed information about a Terraform Cloud workspace

ParametersJSON Schema
NameRequiredDescriptionDefault
workspaceNameYesWorkspace name
organizationNoOrganization nameurbanmedia

Output Schema

ParametersJSON Schema
NameRequiredDescription
idYes
nameYes
lockedYes
vcsRepoNo
autoApplyYes
executionModeYes
terraformVersionYes
workingDirectoryNo

TDQS

B3.1/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It states this is a read operation ('Get'), implying it's non-destructive, but doesn't mention any behavioral traits like authentication needs, rate limits, error handling, or what 'detailed information' entails beyond the output schema.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that directly states the tool's purpose without unnecessary words. It's appropriately sized and front-loaded, with no wasted content.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's low complexity, 100% schema coverage, and presence of an output schema, the description is minimally adequate. However, it lacks context about when to use it versus siblings and behavioral details, which are gaps despite the structured data support.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema description coverage is 100%, so the schema already documents both parameters ('workspaceName' and 'organization') adequately. The description adds no additional meaning beyond what the schema provides, such as explaining parameter interactions or constraints, meeting the baseline for high schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Get' and resource 'detailed information about a Terraform Cloud workspace', making the purpose evident. However, it doesn't explicitly differentiate from sibling tools like 'list_workspaces' or 'get_run_details', which prevents a perfect score.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives such as 'list_workspaces' for a broader overview or 'get_run_details' for run-specific information. The description lacks any context about prerequisites or exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

list_workspacesList WorkspacesB

List all workspaces in a Terraform Cloud organization

ParametersJSON Schema
NameRequiredDescriptionDefault
organizationNoOrganization nameurbanmedia

Output Schema

ParametersJSON Schema
NameRequiredDescription
workspacesYes

TDQS

B3.1/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It states it's a listing operation but doesn't mention whether it's paginated, what permissions are required, rate limits, or what the output format looks like. For a read operation with zero annotation coverage, this leaves significant behavioral gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that directly states the tool's purpose without any wasted words. It's appropriately sized and front-loaded with the core functionality.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool has an output schema (which handles return values) and 100% schema coverage for its single parameter, the description is minimally adequate. However, as a read operation with no annotations, it should ideally provide more behavioral context about permissions, pagination, or limitations to be fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema description coverage is 100%, so the schema already documents the single parameter 'organization' with its type, default value, and description. The tool description doesn't add any additional meaning or context about this parameter beyond what's in the schema, meeting the baseline for high schema coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the action ('List all workspaces') and resource ('in a Terraform Cloud organization'), providing a specific verb+resource combination. However, it doesn't differentiate from sibling tools like 'get_workspace_details' which suggests this is a listing operation versus a detailed retrieval, but this distinction isn't explicitly stated in the description itself.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives like 'get_workspace_details' or other sibling tools. It lacks context about use cases, prerequisites, or exclusions, leaving the agent to infer usage from the tool name and description alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 4 tool updatesv1.0.0
    • First observedget_run_details
    • First observedget_run_status
    • First observedget_workspace_details
    • First observedlist_workspaces

TDQS

B3.2/5.0
Disambiguation4/5

The tools are mostly distinct, with clear separation between workspace operations (list_workspaces, get_workspace_details) and run operations (get_run_details, get_run_status). However, get_run_details and get_run_status could potentially be confused since both relate to run information, though their descriptions differentiate them as 'detailed information' versus 'current status'.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern with snake_case (e.g., get_run_details, list_workspaces). The verbs 'get' and 'list' are used appropriately and predictably throughout the set.

Tool Count3/5

With only 4 tools, the server feels thin for managing Terraform Cloud resources. While it covers basic read operations, the scope suggests more comprehensive management (e.g., create/update/delete operations) would be expected, making the count borderline for the domain.

Completeness2/5

The toolset is severely incomplete for Terraform Cloud management. It only provides read operations (get and list) with no ability to create, update, or delete workspaces, runs, or other resources. This will cause significant agent failures when attempting full lifecycle management.

Maintenance

ActivityInactive
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/matchs/tf-cloud-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server