Works with the AI Agents you already use
Terraform Variables and Outputs Review
by Saizul Amin
This skill gives your agent a proven procedure plus scripts that check the facts, so you get the same correct answer every time, with exact fixes instead of vague advice.
$4
Terraform Variables and Outputs Review
Example session with this skill installed
Run the Terraform Variables and Outputs Review skill on my project and give me a prioritised list of what to fix, with exact changes.
- Read your context and instructions
- Compiled the terraform variables
Here is what the Terraform Variables and Outputs Review skill produced.
Demo: real, unedited output of the skill's bundled script on a sample input from its test suite.
Output
HIGH -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad:0 var.ami_id: referenced but not declared [variable.undeclared]
HIGH -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/outputs.tf:1 output.db_password: exposes a secret-looking value without sensitive = true [output.not_sensitive]
HIGH -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/outputs.tf:5 output.generated_password: exposes a secret-looking value without sensitive = true [output.not_sensitive]
HIGH -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/terraform.tfvars:4 api_token: literal secret in a tfvars file (value hidden): use TF_VAR_ env vars or a secret store; keep the file out of git [tfvars.secret]
HIGH -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/variables.tf:5 var.db_password: looks like a secret but is not marked sensitive = true [variable.not_sensitive]
HIGH -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/variables.tf:5 var.db_password: secret has a literal default (value hidden): remove it and pass the value at runtime [variable.secret_default]
MEDIUM -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/terraform.tfvars:4 api_token: set in tfvars but no variable declares it (typo or removed variable) [tfvars.undeclared]
MEDIUM -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/variables.tf:16 var.unused_flag: declared but never referenced [variable.unused]
MEDIUM -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/variables.tf:27 var.instance_count: no type constraint [variable.type]
LOW -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/main.tf:3 local.leftover: defined but never referenced [local.unused]
LOW -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/outputs.tf:1 output.db_password: no description [output.description]
LOW -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/outputs.tf:10 output.web: returns the whole object aws_instance.web: output the attributes callers need [output.whole_object]
LOW -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/outputs.tf:15 output.WebIP: use snake_case names [output.naming]
LOW -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/variables.tf:1 var.region: no description [variable.description]
LOW -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/variables.tf:22 var.Settings: use snake_case names [variable.naming]
LOW -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/variables.tf:22 var.Settings: type = any: use a precise type [variable.type_any]
INFO -Users-SaizulAmin-Saizul-Old-PC-Saizul-com/bc16f08c-2133-4c9b-92e4-fd071b48ec64/scratchpad/src/terraform-iac-skills/tests/fixtures/tf/vars-bad/variables.tf:11 var.environment: enum-like variable without a validation block (e.g. contains([...], var.x)) [variable.validation]
17 finding(s)
What you do next
- Fix the highest-severity items first.
- Ask your agent to apply the fixes it suggests, then run the skill again to confirm.
- Keep the skill installed and re-run it whenever the project changes.
Connects securely to your tools. The creator never sees your data.
About this skill
Lint and improve Terraform/OpenTofu input variables, outputs, locals and tfvars files with a deterministic script - missing descriptions and types, type = any, secret-looking variables not marked sensitive or with literal defaults, unused and undeclared variables, unused locals, non-snake_case names, enum-like variables without validation blocks, outputs without descriptions, outputs exposing passwords/keys/tokens without sensitive = true, outputs returning whole resource objects, tfvars keys no variable declares and literal secrets in committed tfvars (values never printed). Also covers writing good variable types (object with optional()), validation rules, nullable, sensitive and ephemeral values.
Who it's for
Use when the user asks to clean up variables.tf or outputs.tf, review a module's interface, "terraform validate warns about undeclared variable", wants validation blocks, or asks how to handle secrets in variables and tfvars.
What's inside
- Tested, offline Python script(s): vars_outputs_lint.py (deterministic results, standard library only unless noted)
- Reference guides: patterns.md
- Step-by-step agent instructions in SKILL.md covering: When to use; When not to use; Workflow
Why it's worth it
Generic prompts guess. This skill gives your agent a proven procedure plus scripts that check the facts, so you get the same correct answer every time, with exact fixes instead of vague advice. See the real demo below.
Works with every major AI agent
Built on the open SKILL.md standard: Claude Code, Codex CLI, Cursor, VS Code Copilot, Gemini CLI, Windsurf and 20+ other agents.
Requirements
- Python 3.8+ for the bundled scripts
- No API keys, no account, runs locally
Open source: saizul/terraform-iac-skills on GitHub (MIT licence, by Saizul Amin).
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse All Claude Skills.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 1 day ago
- Software
Python 3.8+