terraform-state-manager

terraform-state-manager is a skill for Claude Code from armanzeroeight/fastagent-plugins. It costs 59 tokens per session (1,304 once invoked), scanned A, original, MIT.

A guide for managing Terraform state, the record Terraform uses to track deployed infrastructure. It covers importing existing resources, changing resource addresses, removing resources from state without deleting them, and moving state between backends.

In plain words
What is it for?
Use it to bring existing infrastructure under Terraform, rename or reorganize resources, migrate state storage, split or merge state files, and troubleshoot state conflicts or corruption.
Why use it?
It helps handle state changes and recovery tasks carefully, where an incorrect operation could make Terraform plan unwanted infrastructure changes.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the terraform-toolkit plugin — 5 skills shipped together

Good fit Use it to bring existing infrastructure under Terraform, rename or reorganize resources, migrate state storage, split or merge state files, and troubleshoot state conflicts or corruption.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/armanzeroeight/fastagent-plugins/terraform-state-manager
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add armanzeroeight/fastagent-plugins --skill terraform-state-manager
Clone the repo
git clone --depth 1 https://github.com/armanzeroeight/fastagent-plugins

Made for: Claude Code.

Or install terraform-toolkit, the plugin that ships this one along with the rest of its 5 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for terraform-state-manager

README.md
[![agentmods](https://agentmods.dev/badge/skills/armanzeroeight/fastagent-plugins/terraform-state-manager/github.svg)](https://agentmods.dev/skills/armanzeroeight/fastagent-plugins/terraform-state-manager)
Your own site
<a href="https://agentmods.dev/skills/armanzeroeight/fastagent-plugins/terraform-state-manager"><img src="https://agentmods.dev/badge/skills/armanzeroeight/fastagent-plugins/terraform-state-manager/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for terraform-state-manager

Your own site · 80×15
<a href="https://agentmods.dev/skills/armanzeroeight/fastagent-plugins/terraform-state-manager"><img src="https://agentmods.dev/badge/skills/armanzeroeight/fastagent-plugins/terraform-state-manager.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 59 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,304 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00059 $0.01304
Opus 5 $0.00030 $0.00652
Sonnet 5 $0.00012 $0.00261
Haiku 4.5 $0.00006 $0.00130

Measured 6d ago against content hash 1d28c7bfa05a, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

terraform-state-manager scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/terraform-toolkit/skills/terraform-state-manager/SKILL.md · 230 lines

How it starts

The opening of the file, as written. The whole thing — 230 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Terraform State Manager

This skill provides safe workflows for Terraform state operations and troubleshooting.

When to Use

Use this skill when:

  • Importing existing infrastructure into Terraform
  • Moving resources to different addresses (renaming)
  • Removing resources from state without destroying them
  • Migrating state between backends (local to S3, etc.)
  • Recovering from state corruption or conflicts
  • Splitting or merging state files

Critical Safety Rules

ALWAYS follow these rules when working with state:

  1. Backup first: Create state backup before any operation
  2. Plan after: Run terraform plan after state changes to verify
  3. One at a time: Make incremental changes, not bulk operations
  4. Test in non-prod: Practice state operations in dev/test first
  5. Version control: Commit code changes with state operations

Common Operations

1. Import Existing Resources

Workflow:

# Step 1: Write the resource configuration in .tf file
# Step 2: Import the resource
terraform import <resource_address> <resource_id>

# Step 3: Verify with plan (should show no changes)
terraform plan

Example - Import AWS S3 Bucket:

# 1. Add to main.tf
resource "aws_s3_bucket" "existing" {
  bucket = "my-existing-bucket"
}

# 2. Import
terraform import aws_s3_bucket.existing my-existing-bucket

# 3. Verify
terraform plan  # Should show: No changes

Tips:

  • Find resource ID format in provider docs
  • Import one resource at a time
  • Some resources require multiple imports (bucket + versioning + encryption)
  • Use terraform show to see imported attributes

2. Move Resources (Rename/Refactor)

Workflow:

# Move resource to new address
terraform state mv <source> <destination>

# Verify
terraform plan  # Should show: No changes

Example - Rename Resource:

# Before: aws_s3_bucket.bucket
# After:  aws_s3_bucket.main

terraform state mv aws_s3_bucket.bucket aws_s3_bucket.main

Example - Move to Module:

Read the full file on GitHub · 230 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 230 lines · 59 tokens per session scan A 1d28c7bfa05a

Subscribe to this mod's changes

terraform-state-manager is a skill published in the GitHub repository armanzeroeight/fastagent-plugins (29 stars, last pushed 1mo ago), licensed MIT. It adds 59 tokens to every session and 1,304 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

develop-web-game

Use when Codex is building or iterating on a web game (HTML/JS) and needs a reliable development + testing loop: implement small changes, run a Playwright-based test script with short input bursts and intentional pauses, inspect screenshots/text, and review console errors with rendergametotext.

netease-youdao/LobsterAI · 64 tokens

content-planner

WeChat Official Account topic planning and content calendar management. Based on WeChat article search and trending analysis, generates differentiated topic recommendations and outputs structured content calendars. Activated when users mention "topic", "planning", "content calendar", "trending", or "what to write next…

netease-youdao/LobsterAI · 63 tokens

music-search

Search cloud drives for downloadable music resources (songs, albums, lossless audio). Use this skill when the user wants to download a specific song or album. Do NOT use for general music information, lyrics, or recommendations.

netease-youdao/LobsterAI · 47 tokens

skill-vetter

Security-first skill vetting for AI agents. Use before installing any skill from ClawdHub, GitHub, or other sources. Checks for red flags, permission scope, and suspicious patterns.

netease-youdao/LobsterAI · 42 tokens

stock-analyzer

A comprehensive stock deep analysis tool that combines real-time quotes, fundamental metrics, technical indicators, and growth analysis into a single professional report. Supports A-share, US stocks, HK stocks. Generates detailed investment recommendations with risk assessment and actionable trading strategies.

netease-youdao/LobsterAI · 53 tokens

stock-explorer

A Yahoo Finance (yfinance) powered financial analysis tool. Get real-time quotes, generate technical indicator reports (RSI/MACD/Bollinger/VWAP/ATR), summarize fundamentals, and run a one-shot report that outputs a text summary.

netease-youdao/LobsterAI · 55 tokens