CloudBurn Logo
CloudBurnHome
  • Cost estimation

    • AWS Simple Pricing CalculatorEstimate your AWS stack
    • IaC Cost EstimatorReview costs before merge

    Cost analysis

    • AWS Cost TreeSee where your spend went

    Cost Optimization

    • Unused resourcesFind resources to remove
    • Resource efficiencyImprove what you keep
    • Commitment savingsReview plans and reservations
    • Cost GovernanceBudgets, alerts, and tags

    Product

    • RoadmapWhat's coming next
    • ChangelogProduct updates
    • DocsGuides and reference
    • AboutWhy CloudBurn exists
  • Pricing
  • Blog
  • Tools
Join the CloudBurn Discord community
Join the waitlistWaitlist
Join the CloudBurn Discord community1.8k
Navigation
    • Overview
    • Installation
    • Configuration
    • GitHub Action
    • MCP Plugin
    • VS Code Extension
      • Scan IaC Files
      • Discover AWS
      • scan
      • discover
      • config
      • rules list
      • completion
      • estimate
      • Exit Codes
      • Output Formats
      • CI/CD Integration
      • Resource Explorer Setup
    • Overview
    • Connect an AWS Account
    • Set Up PR Cost Estimation
    • Plans and Billing
    • Workspaces and Members
    • AWS Cost Tree
      • Usage Assumptions
      • Examples
      • Unused Resources
      • Resource Efficiency
      • Commitment Savings
      • Cost Governance
    • Overview
    • Understanding Rules
      • CloudFront
      • CloudTrail
      • CloudWatch
      • AWS Config
      • Cost Explorer
      • Cost Guardrails
      • Cost Optimization Hub
      • DynamoDB
      • EBS
      • EC2
      • ECR
      • ECS
      • EKS
      • ElastiCache
      • ELB
      • EMR
      • KMS
      • Lambda
      • RDS
      • Redshift
      • Route 53
      • S3
      • SageMaker
      • Secrets Manager
      • Tagging
    • Overview
    • Installation
      • Static IaC Scan
      • Discovery Scan
      • CloudBurnClient
      • Types
      • Package Exports
      • Custom Config
      • AWS Credentials
    • Overview
    • Installation
    • Configuration
    • GitHub Action
    • MCP Plugin
    • VS Code Extension
      • Scan IaC Files
      • Discover AWS
      • scan
      • discover
      • config
      • rules list
      • completion
      • estimate
      • Exit Codes
      • Output Formats
      • CI/CD Integration
      • Resource Explorer Setup
    • Overview
    • Connect an AWS Account
    • Set Up PR Cost Estimation
    • Plans and Billing
    • Workspaces and Members
    • AWS Cost Tree
      • Usage Assumptions
      • Examples
      • Unused Resources
      • Resource Efficiency
      • Commitment Savings
      • Cost Governance
    • Overview
    • Understanding Rules
      • CloudFront
      • CloudTrail
      • CloudWatch
      • AWS Config
      • Cost Explorer
      • Cost Guardrails
      • Cost Optimization Hub
      • DynamoDB
      • EBS
      • EC2
      • ECR
      • ECS
      • EKS
      • ElastiCache
      • ELB
      • EMR
      • KMS
      • Lambda
      • RDS
      • Redshift
      • Route 53
      • S3
      • SageMaker
      • Secrets Manager
      • Tagging
    • Overview
    • Installation
      • Static IaC Scan
      • Discovery Scan
      • CloudBurnClient
      • Types
      • Package Exports
      • Custom Config
      • AWS Credentials
Loading documentation page
CloudBurn Logo
CloudBurn

Open-source AWS cost checks and an upcoming platform for cost estimation, optimization, and governance.

1.8k

Product

  • Pricing
  • Roadmap
  • Changelog
  • About
  • Blog
  • Waitlist
  • Docs
  • Contact

Free Tools

  • EC2 Pricing Calculator
  • S3 Pricing Calculator
  • Bedrock Pricing Calculator
  • Fargate Pricing Calculator
  • RDS Pricing Calculator
  • ECS Pricing Calculator
  • Aurora Pricing Calculator
  • All AWS pricing calculators →

CloudBurn Platform · early 2027

Price changes before you deploy. Fix the waste after.

Join now for 30% off, for as long as you keep your plan.

Join the waitlist

Two emails a month at most. Unsubscribe anytime. By signing up you agree to the privacy policy.

CloudBurn © 2026 | Terms & Privacy

Built with ❤️ by Towards the Cloud

  • Pricing
  • Blog
  • Tools
      • Overview
      • Installation
        • Static IaC Scan
        • Discovery Scan
      • Overview
      • Installation
        • Static IaC Scan
        • Discovery Scan
    CloudBurn SDK

    Quickstart: Static IaC Scan

    Scan Terraform and CloudFormation files with the CloudBurn SDK scanStatic() method. Review TypeScript examples and process AWS cost findings before deployment.

    scanStatic() analyzes your infrastructure-as-code files locally — no AWS credentials required. It parses Terraform and CloudFormation files and applies CloudBurn's cost optimization rules. For AWS CDK, synthesize your app and scan the generated CloudFormation templates in cdk.out/.

    Full example

    import { CloudBurnClient } from '@cloudburn/sdk';
    
    const client = new CloudBurnClient();
    const result = await client.scanStatic('./infrastructure');
    
    for (const provider of result.providers) {
      for (const finding of provider.rules) {
        console.log(`[${finding.ruleId}] ${finding.message}`);
        for (const match of finding.findings) {
          console.log(`  ${match.resourceId} at ${match.location?.path}:${match.location?.line}`);
        }
      }
    }
    

    ScanResult shape

    scanStatic() returns a Promise<ScanResult>:

    type ScanResult = {
      diagnostics?: ScanDiagnostic[];   // skipped files and other non-fatal problems
      policy?: ScanPolicyResult;        // present when iac.failOn is configured
      providers: ProviderFindingGroup[];
      suppressed?: SuppressedFinding[]; // findings withheld by cloudburn-ignore comments
    };
    
    type ProviderFindingGroup = {
      provider: CloudProvider;   // 'aws' | 'azure' | 'gcp'
      rules: Finding[];
    };
    
    type Finding = {
      ruleId: string;
      service: string;
      source: Source;            // 'iac' for static scans
      severity: Severity;        // 'high' | 'medium' | 'low'
      message: string;
      findings: FindingMatch[];
    };
    
    type FindingMatch = {
      resourceId: string;
      resourceType?: string;     // provider namespace, when needed to disambiguate
      actionType?: string;       // recommended operation, when one resource has several
      accountId?: string;
      region?: string;
      recommendation?: FindingRecommendation;
      impact?: FindingImpact;
      location?: SourceLocation; // file path + line/column
    };
    

    result.providers is an array grouped by cloud provider. Each Finding represents one rule that matched, and findings lists every individual resource that triggered it. See Types Reference for the full shape of ScanPolicyResult and SuppressedFinding.

    Static scans never populate evidence or evaluations. Those fields only appear on discovery results.

    Filtering with config

    Pass an inline config to scope the scan to specific services or rules:

    const result = await client.scanStatic('./iac', {
      iac: {
        services: ['ec2', 'ebs'],
      },
    });
    

    Enable or disable specific rules:

    const result = await client.scanStatic('./iac', {
      iac: {
        enabledRules: ['CLDBRN-AWS-EBS-1', 'CLDBRN-AWS-EC2-1'],
      },
    });
    

    You can also load config from a file and merge overrides:

    const config = await client.loadConfig();
    const result = await client.scanStatic('./iac', {
      ...config,
      iac: { ...config.iac, services: ['ec2'] },
    });
    

    What's next

    Quickstart: Discovery ScanScan live AWS resources
    Custom ConfigurationLoad and override config programmatically
    RulesBrowse available rules and rule IDs
    ← PreviousInstallationNext →Discovery Scan

    CloudBurn Platform · early 2027

    Price changes before you deploy. Fix the waste after.

    Join now for 30% off, for as long as you keep your plan.

    Join the waitlist

    Two emails a month at most. Unsubscribe anytime. By signing up you agree to the privacy policy.