pulumi-migrate-from-discovered-stack

pulumi-migrate-from-discovered-stack is a skill for Claude Code, Codex from pulumi/agent-skills. It costs 115 tokens per session (5,517 once invoked), scanned A, original, Apache-2.0.

A guide for bringing a cloud stack into Pulumi after Pulumi Cloud's Discovery feature has already scanned it and listed its resources. Pulumi is a tool for managing cloud infrastructure with code.

In plain words
What is it for?
Use it to read discovered CloudFormation or ARM resources, import them into a Pulumi stack, and optionally refactor the resulting infrastructure code.
Why use it?
It provides a workflow based on the resources that actually exist in the discovered stack, avoiding the wrong process for an arbitrary template or an undiscovered account.

Skill for Claude CodeCodex

Written for Claude Code and Codex: shipped in a Claude Code plugin, but also agents/openai.yaml present.

Part of the pulumi-migration plugin — 5 skills shipped together

Good fit Use it to read discovered CloudFormation or ARM resources, import them into a Pulumi stack, and optionally refactor the resulting infrastructure code.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/pulumi/agent-skills/pulumi-migrate-from-discovered-stack
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 pulumi/agent-skills --skill pulumi-migrate-from-discovered-stack
Clone the repo
git clone --depth 1 https://github.com/pulumi/agent-skills

Made for: Claude Code, Codex.

Or install pulumi-migration, 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 pulumi-migrate-from-discovered-stack

README.md
[![agentmods](https://agentmods.dev/badge/skills/pulumi/agent-skills/pulumi-migrate-from-discovered-stack/github.svg)](https://agentmods.dev/skills/pulumi/agent-skills/pulumi-migrate-from-discovered-stack)
Your own site
<a href="https://agentmods.dev/skills/pulumi/agent-skills/pulumi-migrate-from-discovered-stack"><img src="https://agentmods.dev/badge/skills/pulumi/agent-skills/pulumi-migrate-from-discovered-stack/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 pulumi-migrate-from-discovered-stack

Your own site · 80×15
<a href="https://agentmods.dev/skills/pulumi/agent-skills/pulumi-migrate-from-discovered-stack"><img src="https://agentmods.dev/badge/skills/pulumi/agent-skills/pulumi-migrate-from-discovered-stack.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 115 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 5,517 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. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 1 finding, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Tool Misuse · line 96
    Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
    Fix: Validate all tool parameters against an allowlist. Reject dangerous parameter values (shell=True, --force, -rf /) and use safe defaults.
How audits are shown
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.00115 $0.05517
Opus 5 $0.00057 $0.02759
Sonnet 5 $0.00023 $0.01103
Haiku 4.5 $0.00012 $0.00552

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

Security

Grade A, and why

pulumi-migrate-from-discovered-stack 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 11d ago.

The scan reads SKILL.md. This mod also ships 2 executable files (scripts/build_import.py, scripts/triage.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

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.

migration/skills/pulumi-migrate-from-discovered-stack/SKILL.md · 325 lines

How it starts

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

Scope: this skill only applies to stacks Pulumi Cloud's Discovery feature has already scanned and exposed through the discovered-stacks API (GET .../discovered-stacks/{projectName}/{stackName}/resources, see below). It is not for migrating an arbitrary CloudFormation/ARM template or account that Discovery hasn't scanned yet — if no discovered stack exists for the source, this skill has nothing to read and does not apply.

Do not load cloudformation-to-pulumi or pulumi-arm-to-pulumi alongside this skill. Those two skills prescribe a template-first workflow (mechanical translation → import) and mandate aws-native for AWS. This skill is cloud-state-first (import from discovered state → optional refactor against the template later) and defaults to aws classic / azure-native. The useful reference material from those two skills has been curated into cloudformation.md and arm.md in this folder.


Plan adjustment

If you already generated a migration plan before loading this skill, review it against the workflow below and update it — the phases here supersede any earlier plan. Communicate the adjusted plan to the user before proceeding.

Success criteria

A migration is complete when:

  1. Complete resource coverage — every discovered resource is imported OR has an annotation explaining why not.
  2. Zero-diffpulumi preview shows no changes. This proves the code matches the cloud state exactly.
  3. Progress tracked via the API — use compareTo and migration annotations so progress is visible in Pulumi Cloud, not just in agent memory.
  4. PR as the output — a pull request with the migrated code and a migration report.

THE DISCOVERED-STACKS API

Fetching resources

GET /api/preview/insights/{orgName}/discovered-stacks/{projectName}/{stackName}/resources?compareTo={targetProject}/{targetStack}

Always include compareTo if the target Pulumi stack exists (it may already have state from a previous migration attempt). Returns a list of DiscoveredResourceInfo objects. The JSON paths below are exact — verify before consuming:

Read the full file on GitHub · 325 lines

Files

What ships with it

7 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 11d ago First seen · 325 lines · 115 tokens per session scan A b2178a963701

Subscribe to this mod's changes

pulumi-migrate-from-discovered-stack is a skill published in the GitHub repository pulumi/agent-skills (68 stars, last pushed today), licensed Apache-2.0. It adds 115 tokens to every session and 5,517 once invoked, about $0.0006 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-08-30.

Related

Other skills, from other repositories

infrastructure-as-code-guardian

Universal Infrastructure as Code (IaC) agent skill for authoring, securing, and managing cloud infrastructure across Terraform, Pulumi, CloudFormation, Ansible, and Bicep. Provides cross-tool security hardening, state management best practices, cost optimization, drift detection, and CI/CD integration. Covers AWS…

JPeetz/agent-skills · 254 tokens

terraform-expert

Expert-level Terraform infrastructure as code, modules, state management, and production best practices. Use when the user mentions infrastructure as code, devops, or automation, or when the task involves Terraform Basics, Resource Management, Modules, or State Management.

personamanagmentlayer/pcl · 53 tokens

terraform-docs

Terraform 1.15.x — configuration language, resources, variables, modules, state, backends, providers, functions.

pledgeandgrow/pledge-skills · 29 tokens

Terraform Infrastructure as Code

Production-grade Terraform development with HCL best practices, module design, state management, multi-cloud patterns, and AI-enhanced infrastructure as code for scalable cloud deployments.

bobmatnyc/mcp-skillset · 36 tokens

activate-site

Activates and provisions a Power Pages website in a Power Platform environment via the Power Platform REST API. Use when the user wants to activate, provision, turn on, or enable a Power Pages website or portal.

microsoft/power-platform-skills · 45 tokens

deploy

Builds and deploys a Power Apps code app to Power Platform. Use when deploying changes, redeploying an existing app, or pushing updates.

microsoft/power-platform-skills · 32 tokens