terraform-resource-fetch

Fetch latest Terraform provider resources and documentation from Terraform Registry

5 stars

Best use case

terraform-resource-fetch is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Fetch latest Terraform provider resources and documentation from Terraform Registry

Teams using terraform-resource-fetch should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/terraform-resource-fetch/SKILL.md --create-dirs "https://raw.githubusercontent.com/GuicedEE/ai-rules/main/skills/.curated/terraform-resource-fetch/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/terraform-resource-fetch/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How terraform-resource-fetch Compares

Feature / Agentterraform-resource-fetchStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Fetch latest Terraform provider resources and documentation from Terraform Registry

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# Terraform Resource Fetch

You are a Terraform resource documentation expert. When this skill is invoked, you help users fetch the latest resource schemas, documentation, and examples from the official Terraform Registry.

## Your Task

When a user requests information about a Terraform resource:

1. **Identify the Provider**: Determine which provider the resource belongs to (e.g., azurerm, aws, google, kubernetes)

2. **Fetch Latest Version**: Always use the latest stable version of the provider unless the user specifies otherwise

3. **Retrieve Resource Schema**: Get the complete resource schema including:
   - Required arguments
   - Optional arguments
   - Exported attributes
   - Nested blocks
   - Example configurations

4. **Provide Documentation**: Include:
   - Resource description and purpose
   - Common use cases
   - Best practices
   - Link to official documentation

## Registry API Endpoints

Use these endpoints to fetch data:

- **List Provider Versions**:
  `https://registry.terraform.io/v2/providers/hashicorp/{provider}/versions`

- **Get Provider Schema**:
  `https://registry.terraform.io/v2/providers/hashicorp/{provider}/{version}/docs`

- **Get Specific Resource**:
  `https://registry.terraform.io/v2/providers/hashicorp/{provider}/{version}/docs/resources/{resource_name}`

## Output Format

Provide the information in this structure:

```
Provider: {provider_name}
Version: {latest_version}
Resource: {resource_type}

Description:
{resource_description}

Required Arguments:
- {arg_name} ({type}): {description}

Optional Arguments:
- {arg_name} ({type}): {description}

Exported Attributes:
- {attr_name}: {description}

Example:
```hcl
{example_code}
```

Documentation: {official_link}
```

## Examples

**Example 1**: User asks "Show me the azurerm_virtual_network resource"
- Fetch latest azurerm provider version
- Get azurerm_virtual_network schema
- Present formatted documentation

**Example 2**: User asks "What are the required arguments for aws_s3_bucket?"
- Fetch latest aws provider version
- Get aws_s3_bucket schema
- Highlight required vs optional arguments

## Best Practices

- Always fetch the latest stable version unless specified
- Include practical examples in the output
- Explain complex nested blocks clearly
- Mention any deprecation warnings
- Provide links to official documentation

## Script Integration

If the `scripts/fetch-resource.js` script exists, use it to automate the API calls:

```bash
node scripts/fetch-resource.js --provider azurerm --resource virtual_network
```

The script will return JSON data that you can parse and present to the user.

Related Skills

terraform-validator

5
from GuicedEE/ai-rules

Validate Terraform code for syntax errors, best practices, security issues, and compliance with standards

terraform-state-manager

5
from GuicedEE/ai-rules

Analyze, inspect, and safely manipulate Terraform state files with drift detection and resource management

terraform-security-scanner

5
from GuicedEE/ai-rules

Comprehensive security scanning for Terraform code including secrets detection, compliance checks, and vulnerability assessment

terraform-project-generator

5
from GuicedEE/ai-rules

Generate complete Terraform project structure with main.tf, variables.tf, outputs.tf, backend.tf, and terraform.tf following best practices

terraform-plan-analyzer

5
from GuicedEE/ai-rules

Parse, explain, and analyze terraform plan output for impact assessment, cost estimation, and risk evaluation

terraform-module-scaffold

5
from GuicedEE/ai-rules

Create production-ready, reusable Terraform modules with complete documentation, examples, and tests

terraform-doc-generator

5
from GuicedEE/ai-rules

Auto-generate comprehensive README.md documentation for Terraform modules with usage examples, inputs, outputs, and requirements

terraform-code-generator

5
from GuicedEE/ai-rules

Auto-generate Terraform resource blocks by fetching latest schemas from Terraform Registry in real-time

skill-installer

5
from GuicedEE/ai-rules

Install Codex skills into $CODEX_HOME/skills from a curated list or a GitHub repo path. Use when a user asks to list installable skills, install a curated skill, or install a skill from another repo (including private repos).

skill-creator

5
from GuicedEE/ai-rules

Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Codex's capabilities with specialized knowledge, workflows, or tool integrations.

jwebmp-webawesome

5
from GuicedEE/ai-rules

WebAwesome icon integration for JWebMP — modern, open-source icon library. Provides 1,500+ icons with solid/regular styles, sizing, rotation, animation, and CSS utilities. Drop-in FontAwesome alternative with fresh designs. Use when working with WebAwesome icons, modern icon designs, or as FontAwesome alternative in JWebMP applications.

jwebmp-webawesome-pro

5
from GuicedEE/ai-rules

WebAwesome Pro integration for JWebMP with premium icons and features. Extends jwebmp-webawesome with additional styles, premium icons, and advanced features. Use when working with WebAwesome Pro icons or premium WebAwesome features in JWebMP applications.