The master skill in PlanetScale's official pack: runs a full read-only best-practices assessment of a database or org, then produces one evidence-backed report.
Terraform Style GuideSkill
Summary
HashiCorp's official skill for writing Terraform that matches the published style guide — file layout, naming, variable validation and secure-by-default resources.
Features
- Canonical file layout across terraform.tf, providers.tf, main.tf, variables.tf, outputs.tf and locals.tf
- Generates in dependency order: providers, data sources, resources, outputs
- Two-space indentation and aligned assignments matching terraform fmt
- Variables with types, descriptions and validation blocks
- Secure-by-default resource configuration
- Refactors count-based resources to for_each
Install This Skill
Add this skill to your favorite AI agent in a few steps.
Skill Content
Example Usage
Audit this module against the HashiCorp Terraform style guide and fix what it flags.
Description
HashiCorp publishes a Terraform Style Guide, and this skill is the machine-readable version of it: an agent loaded with this skill writes HCL that already conforms, instead of producing something plausible that a reviewer then has to correct line by line.
What it enforces
File organisation — the canonical split across terraform.tf (version constraints), providers.tf, main.tf, variables.tf, outputs.tf and locals.tf, with variables and outputs kept in alphabetical order.
Generation order — provider configuration and version constraints first, then data sources, then resources in dependency order, then outputs for the attributes anything downstream will need. Configurable values become variables rather than literals.
Formatting — two-space indentation, aligned equals signs within a block, and the conventions terraform fmt would apply anyway, produced correctly the first time.
Variable declarations — a type, a description and, where the value is constrained, a validation block with a usable error message rather than a failure five minutes into an apply.
Secure defaults — resources generated with encryption and access restrictions on by default, which is the difference between an S3 bucket that passes review and one that does not.
Where you would use it
Scaffolding a new module, auditing an inherited configuration for naming and structure violations, or refactoring count-based resources into for_each — the change that stops a removal in the middle of a list from re-creating everything after it.
Context
The skill lives in hashicorp/agent-skills under plugins/terraform/skills/, one of a set that also covers provider scaffolding, provider resources and actions, acceptance-test patterns, module refactoring, Terraform Stacks, and bulk-importing existing cloud resources into state. Licensed under MPL-2.0.
Related Skills
Build crash-safe AI agents on AgentKit and step.ai — durable tool calls, human-in-the-loop approval, realtime progress, and when not to reach for an agent loop at all.
Inngest's durable-execution playbook as an agent skill — steps and memoisation, event and cron triggers, idempotency, cancellation, retries and non-retriable errors.
Temporal's official skill for building durable workflows — SDK patterns across seven languages, plus the determinism rules that decide whether a workflow survives a replay.