Skip to main content
Glama

tf_list_providers

Read-onlyIdempotent

List providers and pinned versions locked in a Terraform root module's .terraform.lock.hcl so code targets the versions actually in use, defaulting to the current directory.

Instructions

List providers and their PINNED versions for a Terraform root module (default: cwd). Call this first so code targets the versions actually locked in .terraform.lock.hcl, not the latest release. Lists only the providers locked in THIS directory; it does not search the registry. For registry search, provider docs or the latest version, use the official terraform MCP server (search_provider_docs / get_latest_provider_version).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dirNoTerraform root module directory (must already be initialized). Default: TERRAFORM_CWD_MCP_DIR, else the server's working directory.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint/idempotentHint/destructiveHint=false, so safety is covered. The description adds genuine behavioral context beyond that: the data source is .terraform.lock.hcl and it lists only providers locked in THIS directory, which is real scope information. It stops short of describing return format or handling of uninitialized directories.

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?

Three sentences, all front-loaded and purposeful: what it returns, when to call it, what it does not cover, and where to go instead. No filler or redundancy.

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

Completeness5/5

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

For a single-parameter, read-only listing tool with no output schema, the description covers the return subject (providers and pinned versions), the scope limitation, and the routing to alternatives. Nothing needed to call it correctly is missing.

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?

Schema coverage is 100%; the single dir parameter already documents its default precedence (TERRAFORM_CWD_MCP_DIR, else server working directory). The description's '(default: cwd)' restates this without adding syntax or edge-case detail, so the baseline 3 applies.

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

Purpose5/5

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

States a specific verb (List) plus resource (providers and their PINNED versions) and scopes it to a Terraform root module defaulting to cwd. It also distinguishes itself from registry search, so an agent can separate it from tf_get_schema or a registry lookup without opening the schema.

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

Usage Guidelines5/5

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

Explicitly says 'Call this first' and gives the reason (code should target versions locked in .terraform.lock.hcl, not the latest release). It also states when NOT to use it ('does not search the registry') and names the alternative server and tools (search_provider_docs / get_latest_provider_version).

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