Skip to content
| Marketplace
Sign in
Visual Studio Code>Snippets>AWS IAM Service Principal SnippetsNew to Visual Studio Code? Get it now.
AWS IAM Service Principal Snippets

AWS IAM Service Principal Snippets

Danny Steenman

towardsthecloud.com
|
5,359 installs
| (1) | Free
This VS Code extension provides autocompletion of all AWS services that can be used as Service Principals in your IAM policies.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

AWS IAM Service Principal Snippets for VS Code

Installs Rating

This VS Code extension provides autocompletion of all AWS services that can be used as Service Principals in your IAM policies.

[!TIP] Stop AWS bill surprises from happening.

Most infrastructure changes look harmless until you see next month's AWS bill. CloudBurn prevents this by analyzing the cost impact of your AWS CDK changes directly in GitHub pull requests, catching expensive mistakes during code review when fixes are quick, not weeks later when they're costly and risky.

Install CloudBurn from GitHub Marketplace

💰 Set it up once, then never be surprised by AWS costs again
  1. First install the free CDK Diff PR Commenter GitHub Action in your repository where you build your AWS CDK infrastructure
  2. Then install the CloudBurn GitHub App on the same repository

What happens now:

Whenever you open a PR with infrastructure changes, the GitHub Action comments with your CDK diff analysis. CloudBurn reads that diff and automatically adds a separate comment with a detailed cost report showing:

  • Monthly cost impact – Will this change increase or decrease your AWS bill? By how much?
  • Per-resource breakdown – See exactly which resources are driving costs (old vs. new monthly costs)
  • Region-aware pricing – We pick the right AWS pricing based on the region where your infrastructure is deployed

Your team can now validate cost impact alongside infrastructure changes during code review. Essentially, this shifts FinOps left where you optimize costs as you code, not weeks later when context is lost and production adjustments require more time and carry added risk.

CloudBurn will be free during beta. After launch, a free Community plan (1 repository with unlimited users) will always be available.


Features

  1. Auto-completion for AWS Service Principals: Provides intelligent auto-completion suggestions for AWS Service Principals when defining IAM policies or roles.
  2. Context-aware Suggestions: The extension intelligently detects when you're working with IAM policies or roles and only suggests Service Principal completions in relevant contexts.
  3. Supports Multiple Languages: Supports auto-completion for Service Principals in JSON, YAML, Terraform, and AWS CDK (TypeScript, and Python).

Usage

  1. Install the "AWS IAM Service Principal Snippets" extension in VS Code.
  2. Open or create a new file (.json, .yml, .tf, .ts, or .py) where you're defining IAM policies or roles.
  3. When you reach a point where you need to specify a Service Principal (e.g., Principal key in JSON/YAML policies, assumed_by parameter in Python roles, etc.), start typing the name of the AWS service.
  4. The extension will provide auto-completion suggestions for matching AWS Service Principals.
  5. Select the desired Service Principal to insert it into your code.

Example of auto-completion in action:

IAM Service Principal Snippets Autocomplete Example

Note: If auto-completion doesn't trigger automatically, press Ctrl+Space (or Cmd+Space on macOS) to manually invoke IntelliSense.


Support

If you have a feature request or an issue, please let me know on Github

Author

Danny Steenman

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft