KosmoKrator

productivity

Terraform Cloud MCP, CLI, and Lua Integration for AI Agents

Terraform Cloud integration docs for AI agents: MCP gateway setup, Terraform Cloud CLI commands, Lua API reference, credentials, and function schemas.

7 functions 7 read 0 write API token auth

Terraform Cloud for agents

Credentials can be configured manually in web or CLI hosts.

Use this integration from Lua code mode, the headless integrations CLI, or the KosmoKrator MCP gateway. The same package metadata powers all three surfaces.

Machine-Readable Metadata
integration_slug
terraform
route_slug
terraform
package
terraform
auth_strategy
api_token API token
cli_setup_supported
true
cli_runtime_supported
true
mcp_gateway_supported
true
lua_supported
true
supports_multi_account
true

Quick Links

Terraform Cloud MCP Client Matrix

Use these pages when a specific agent client or framework needs copy-pasteable MCP setup for Terraform Cloud.

Terraform Cloud CLI Matrix

Use these pages for direct Terraform Cloud CLI workflows in scripts, CI, cron, and agent wrappers.

Function Catalog

FunctionTypeParametersDescription
terraform.terraform_list_workspaces Read read 3 List workspaces in a Terraform Cloud organization. Returns workspace IDs, names, Terraform versions, and locked status.
terraform.terraform_get_workspace Read read 1 Get details of a specific Terraform Cloud workspace by its ID. Returns workspace configuration, status, and VCS settings.
terraform.terraform_list_runs Read read 3 List runs for a Terraform Cloud workspace. Returns run IDs, statuses, trigger reasons, and timestamps.
terraform.terraform_get_run Read read 1 Get details of a specific Terraform Cloud run by its ID. Returns run status, plan/apply results, and configuration version info.
terraform.terraform_list_variables Read read 1 List variables for a Terraform Cloud workspace. Returns variable names, types (Terraform or environment), and sensitivity flags.
terraform.terraform_list_organizations Read read 2 List Terraform Cloud organizations the authenticated user has access to. Returns organization names and IDs.
terraform.terraform_get_current_user Read read 0 Get the currently authenticated Terraform Cloud user. Useful for verifying authentication and retrieving user details.