1. Packages
  2. Ibm Provider
  3. API Docs
  4. BillingReportSnapshot
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

ibm.BillingReportSnapshot

Explore with Pulumi AI

ibm logo
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

    Create, update, and delete billing_report_snapshots with this resource.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const billingReportSnapshotInstance = new ibm.BillingReportSnapshot("billingReportSnapshotInstance", {
        cosBucket: "bucket_name",
        cosLocation: "us-south",
        cosReportsFolder: "IBMCloud-Billing-Reports",
        interval: "daily",
        versioning: "new",
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    billing_report_snapshot_instance = ibm.BillingReportSnapshot("billingReportSnapshotInstance",
        cos_bucket="bucket_name",
        cos_location="us-south",
        cos_reports_folder="IBMCloud-Billing-Reports",
        interval="daily",
        versioning="new")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ibm.NewBillingReportSnapshot(ctx, "billingReportSnapshotInstance", &ibm.BillingReportSnapshotArgs{
    			CosBucket:        pulumi.String("bucket_name"),
    			CosLocation:      pulumi.String("us-south"),
    			CosReportsFolder: pulumi.String("IBMCloud-Billing-Reports"),
    			Interval:         pulumi.String("daily"),
    			Versioning:       pulumi.String("new"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ibm = Pulumi.Ibm;
    
    return await Deployment.RunAsync(() => 
    {
        var billingReportSnapshotInstance = new Ibm.BillingReportSnapshot("billingReportSnapshotInstance", new()
        {
            CosBucket = "bucket_name",
            CosLocation = "us-south",
            CosReportsFolder = "IBMCloud-Billing-Reports",
            Interval = "daily",
            Versioning = "new",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ibm.BillingReportSnapshot;
    import com.pulumi.ibm.BillingReportSnapshotArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var billingReportSnapshotInstance = new BillingReportSnapshot("billingReportSnapshotInstance", BillingReportSnapshotArgs.builder()
                .cosBucket("bucket_name")
                .cosLocation("us-south")
                .cosReportsFolder("IBMCloud-Billing-Reports")
                .interval("daily")
                .versioning("new")
                .build());
    
        }
    }
    
    resources:
      billingReportSnapshotInstance:
        type: ibm:BillingReportSnapshot
        properties:
          cosBucket: bucket_name
          cosLocation: us-south
          cosReportsFolder: IBMCloud-Billing-Reports
          interval: daily
          versioning: new
    

    With Service-To-Service Authorization

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const policy = new ibm.IamAuthorizationPolicy("policy", {
        sourceServiceName: "billing",
        targetServiceName: "cloud-object-storage",
        targetResourceInstanceId: "cos_instance_id",
        roles: [
            "Object Writer",
            "Content Reader",
        ],
    });
    const billingReportSnapshotInstance = new ibm.BillingReportSnapshot("billingReportSnapshotInstance", {
        cosBucket: "bucket_name",
        cosLocation: "us-south",
        cosReportsFolder: "IBMCloud-Billing-Reports",
        interval: "daily",
        versioning: "new",
        reportTypes: [
            "account_summary",
            "account_resource_instance_usage",
        ],
    }, {
        dependsOn: [policy],
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    policy = ibm.IamAuthorizationPolicy("policy",
        source_service_name="billing",
        target_service_name="cloud-object-storage",
        target_resource_instance_id="cos_instance_id",
        roles=[
            "Object Writer",
            "Content Reader",
        ])
    billing_report_snapshot_instance = ibm.BillingReportSnapshot("billingReportSnapshotInstance",
        cos_bucket="bucket_name",
        cos_location="us-south",
        cos_reports_folder="IBMCloud-Billing-Reports",
        interval="daily",
        versioning="new",
        report_types=[
            "account_summary",
            "account_resource_instance_usage",
        ],
        opts = pulumi.ResourceOptions(depends_on=[policy]))
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		policy, err := ibm.NewIamAuthorizationPolicy(ctx, "policy", &ibm.IamAuthorizationPolicyArgs{
    			SourceServiceName:        pulumi.String("billing"),
    			TargetServiceName:        pulumi.String("cloud-object-storage"),
    			TargetResourceInstanceId: pulumi.String("cos_instance_id"),
    			Roles: pulumi.StringArray{
    				pulumi.String("Object Writer"),
    				pulumi.String("Content Reader"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = ibm.NewBillingReportSnapshot(ctx, "billingReportSnapshotInstance", &ibm.BillingReportSnapshotArgs{
    			CosBucket:        pulumi.String("bucket_name"),
    			CosLocation:      pulumi.String("us-south"),
    			CosReportsFolder: pulumi.String("IBMCloud-Billing-Reports"),
    			Interval:         pulumi.String("daily"),
    			Versioning:       pulumi.String("new"),
    			ReportTypes: pulumi.StringArray{
    				pulumi.String("account_summary"),
    				pulumi.String("account_resource_instance_usage"),
    			},
    		}, pulumi.DependsOn([]pulumi.Resource{
    			policy,
    		}))
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ibm = Pulumi.Ibm;
    
    return await Deployment.RunAsync(() => 
    {
        var policy = new Ibm.IamAuthorizationPolicy("policy", new()
        {
            SourceServiceName = "billing",
            TargetServiceName = "cloud-object-storage",
            TargetResourceInstanceId = "cos_instance_id",
            Roles = new[]
            {
                "Object Writer",
                "Content Reader",
            },
        });
    
        var billingReportSnapshotInstance = new Ibm.BillingReportSnapshot("billingReportSnapshotInstance", new()
        {
            CosBucket = "bucket_name",
            CosLocation = "us-south",
            CosReportsFolder = "IBMCloud-Billing-Reports",
            Interval = "daily",
            Versioning = "new",
            ReportTypes = new[]
            {
                "account_summary",
                "account_resource_instance_usage",
            },
        }, new CustomResourceOptions
        {
            DependsOn =
            {
                policy,
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ibm.IamAuthorizationPolicy;
    import com.pulumi.ibm.IamAuthorizationPolicyArgs;
    import com.pulumi.ibm.BillingReportSnapshot;
    import com.pulumi.ibm.BillingReportSnapshotArgs;
    import com.pulumi.resources.CustomResourceOptions;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var policy = new IamAuthorizationPolicy("policy", IamAuthorizationPolicyArgs.builder()
                .sourceServiceName("billing")
                .targetServiceName("cloud-object-storage")
                .targetResourceInstanceId("cos_instance_id")
                .roles(            
                    "Object Writer",
                    "Content Reader")
                .build());
    
            var billingReportSnapshotInstance = new BillingReportSnapshot("billingReportSnapshotInstance", BillingReportSnapshotArgs.builder()
                .cosBucket("bucket_name")
                .cosLocation("us-south")
                .cosReportsFolder("IBMCloud-Billing-Reports")
                .interval("daily")
                .versioning("new")
                .reportTypes(            
                    "account_summary",
                    "account_resource_instance_usage")
                .build(), CustomResourceOptions.builder()
                    .dependsOn(policy)
                    .build());
    
        }
    }
    
    resources:
      policy:
        type: ibm:IamAuthorizationPolicy
        properties:
          sourceServiceName: billing
          targetServiceName: cloud-object-storage
          targetResourceInstanceId: cos_instance_id
          roles:
            - Object Writer
            - Content Reader
      billingReportSnapshotInstance:
        type: ibm:BillingReportSnapshot
        properties:
          cosBucket: bucket_name
          cosLocation: us-south
          cosReportsFolder: IBMCloud-Billing-Reports
          interval: daily
          versioning: new
          reportTypes:
            - account_summary
            - account_resource_instance_usage
        options:
          dependsOn:
            - ${policy}
    

    If service-to-service authorization already exists in the specific COS bucket, the resource policy can be omitted and the depends_on flag can also be removed from resource billing_report_snapshot_instance. For more information, about IAM service authorizations, see using authorizations to grant access between services.

    Create BillingReportSnapshot Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new BillingReportSnapshot(name: string, args: BillingReportSnapshotArgs, opts?: CustomResourceOptions);
    @overload
    def BillingReportSnapshot(resource_name: str,
                              args: BillingReportSnapshotArgs,
                              opts: Optional[ResourceOptions] = None)
    
    @overload
    def BillingReportSnapshot(resource_name: str,
                              opts: Optional[ResourceOptions] = None,
                              cos_bucket: Optional[str] = None,
                              cos_location: Optional[str] = None,
                              interval: Optional[str] = None,
                              billing_report_snapshot_id: Optional[str] = None,
                              cos_reports_folder: Optional[str] = None,
                              report_types: Optional[Sequence[str]] = None,
                              versioning: Optional[str] = None)
    func NewBillingReportSnapshot(ctx *Context, name string, args BillingReportSnapshotArgs, opts ...ResourceOption) (*BillingReportSnapshot, error)
    public BillingReportSnapshot(string name, BillingReportSnapshotArgs args, CustomResourceOptions? opts = null)
    public BillingReportSnapshot(String name, BillingReportSnapshotArgs args)
    public BillingReportSnapshot(String name, BillingReportSnapshotArgs args, CustomResourceOptions options)
    
    type: ibm:BillingReportSnapshot
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args BillingReportSnapshotArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args BillingReportSnapshotArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args BillingReportSnapshotArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args BillingReportSnapshotArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args BillingReportSnapshotArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var billingReportSnapshotResource = new Ibm.BillingReportSnapshot("billingReportSnapshotResource", new()
    {
        CosBucket = "string",
        CosLocation = "string",
        Interval = "string",
        BillingReportSnapshotId = "string",
        CosReportsFolder = "string",
        ReportTypes = new[]
        {
            "string",
        },
        Versioning = "string",
    });
    
    example, err := ibm.NewBillingReportSnapshot(ctx, "billingReportSnapshotResource", &ibm.BillingReportSnapshotArgs{
    	CosBucket:               pulumi.String("string"),
    	CosLocation:             pulumi.String("string"),
    	Interval:                pulumi.String("string"),
    	BillingReportSnapshotId: pulumi.String("string"),
    	CosReportsFolder:        pulumi.String("string"),
    	ReportTypes: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	Versioning: pulumi.String("string"),
    })
    
    var billingReportSnapshotResource = new BillingReportSnapshot("billingReportSnapshotResource", BillingReportSnapshotArgs.builder()
        .cosBucket("string")
        .cosLocation("string")
        .interval("string")
        .billingReportSnapshotId("string")
        .cosReportsFolder("string")
        .reportTypes("string")
        .versioning("string")
        .build());
    
    billing_report_snapshot_resource = ibm.BillingReportSnapshot("billingReportSnapshotResource",
        cos_bucket="string",
        cos_location="string",
        interval="string",
        billing_report_snapshot_id="string",
        cos_reports_folder="string",
        report_types=["string"],
        versioning="string")
    
    const billingReportSnapshotResource = new ibm.BillingReportSnapshot("billingReportSnapshotResource", {
        cosBucket: "string",
        cosLocation: "string",
        interval: "string",
        billingReportSnapshotId: "string",
        cosReportsFolder: "string",
        reportTypes: ["string"],
        versioning: "string",
    });
    
    type: ibm:BillingReportSnapshot
    properties:
        billingReportSnapshotId: string
        cosBucket: string
        cosLocation: string
        cosReportsFolder: string
        interval: string
        reportTypes:
            - string
        versioning: string
    

    BillingReportSnapshot Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The BillingReportSnapshot resource accepts the following input properties:

    CosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    CosLocation string
    Region of the COS instance.
    Interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    BillingReportSnapshotId string
    The unique identifier of the billing_report_snapshot.
    CosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    ReportTypes List<string>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    Versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    CosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    CosLocation string
    Region of the COS instance.
    Interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    BillingReportSnapshotId string
    The unique identifier of the billing_report_snapshot.
    CosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    ReportTypes []string
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    Versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    cosBucket String
    The name of the COS bucket to store the snapshot of the billing reports.
    cosLocation String
    Region of the COS instance.
    interval String
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    billingReportSnapshotId String
    The unique identifier of the billing_report_snapshot.
    cosReportsFolder String
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    reportTypes List<String>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    versioning String
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    cosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    cosLocation string
    Region of the COS instance.
    interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    billingReportSnapshotId string
    The unique identifier of the billing_report_snapshot.
    cosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    reportTypes string[]
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    cos_bucket str
    The name of the COS bucket to store the snapshot of the billing reports.
    cos_location str
    Region of the COS instance.
    interval str
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    billing_report_snapshot_id str
    The unique identifier of the billing_report_snapshot.
    cos_reports_folder str
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    report_types Sequence[str]
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    versioning str
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    cosBucket String
    The name of the COS bucket to store the snapshot of the billing reports.
    cosLocation String
    Region of the COS instance.
    interval String
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    billingReportSnapshotId String
    The unique identifier of the billing_report_snapshot.
    cosReportsFolder String
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    reportTypes List<String>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    versioning String
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the BillingReportSnapshot resource produces the following output properties:

    AccountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    Compression string
    (String) Compression format of the snapshot report.
    ContentType string
    (String) Type of content stored in snapshot report.
    CosEndpoint string
    (String) The endpoint of the COS instance.
    CreatedAt double
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    Histories List<BillingReportSnapshotHistory>
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUpdatedAt double
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    State string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    AccountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    Compression string
    (String) Compression format of the snapshot report.
    ContentType string
    (String) Type of content stored in snapshot report.
    CosEndpoint string
    (String) The endpoint of the COS instance.
    CreatedAt float64
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    Histories []BillingReportSnapshotHistory
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUpdatedAt float64
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    State string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    accountType String
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    compression String
    (String) Compression format of the snapshot report.
    contentType String
    (String) Type of content stored in snapshot report.
    cosEndpoint String
    (String) The endpoint of the COS instance.
    createdAt Double
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    histories List<BillingReportSnapshotHistory>
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    id String
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt Double
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    state String
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    accountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    compression string
    (String) Compression format of the snapshot report.
    contentType string
    (String) Type of content stored in snapshot report.
    cosEndpoint string
    (String) The endpoint of the COS instance.
    createdAt number
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    histories BillingReportSnapshotHistory[]
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    id string
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt number
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    state string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    account_type str
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    compression str
    (String) Compression format of the snapshot report.
    content_type str
    (String) Type of content stored in snapshot report.
    cos_endpoint str
    (String) The endpoint of the COS instance.
    created_at float
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    histories Sequence[BillingReportSnapshotHistory]
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    id str
    The provider-assigned unique ID for this managed resource.
    last_updated_at float
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    state str
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    accountType String
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    compression String
    (String) Compression format of the snapshot report.
    contentType String
    (String) Type of content stored in snapshot report.
    cosEndpoint String
    (String) The endpoint of the COS instance.
    createdAt Number
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    histories List<Property Map>
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    id String
    The provider-assigned unique ID for this managed resource.
    lastUpdatedAt Number
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    state String
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.

    Look up Existing BillingReportSnapshot Resource

    Get an existing BillingReportSnapshot resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: BillingReportSnapshotState, opts?: CustomResourceOptions): BillingReportSnapshot
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            account_type: Optional[str] = None,
            billing_report_snapshot_id: Optional[str] = None,
            compression: Optional[str] = None,
            content_type: Optional[str] = None,
            cos_bucket: Optional[str] = None,
            cos_endpoint: Optional[str] = None,
            cos_location: Optional[str] = None,
            cos_reports_folder: Optional[str] = None,
            created_at: Optional[float] = None,
            histories: Optional[Sequence[BillingReportSnapshotHistoryArgs]] = None,
            interval: Optional[str] = None,
            last_updated_at: Optional[float] = None,
            report_types: Optional[Sequence[str]] = None,
            state: Optional[str] = None,
            versioning: Optional[str] = None) -> BillingReportSnapshot
    func GetBillingReportSnapshot(ctx *Context, name string, id IDInput, state *BillingReportSnapshotState, opts ...ResourceOption) (*BillingReportSnapshot, error)
    public static BillingReportSnapshot Get(string name, Input<string> id, BillingReportSnapshotState? state, CustomResourceOptions? opts = null)
    public static BillingReportSnapshot get(String name, Output<String> id, BillingReportSnapshotState state, CustomResourceOptions options)
    resources:  _:    type: ibm:BillingReportSnapshot    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AccountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    BillingReportSnapshotId string
    The unique identifier of the billing_report_snapshot.
    Compression string
    (String) Compression format of the snapshot report.
    ContentType string
    (String) Type of content stored in snapshot report.
    CosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    CosEndpoint string
    (String) The endpoint of the COS instance.
    CosLocation string
    Region of the COS instance.
    CosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    CreatedAt double
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    Histories List<BillingReportSnapshotHistory>
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    Interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    LastUpdatedAt double
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    ReportTypes List<string>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    State string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    Versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    AccountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    BillingReportSnapshotId string
    The unique identifier of the billing_report_snapshot.
    Compression string
    (String) Compression format of the snapshot report.
    ContentType string
    (String) Type of content stored in snapshot report.
    CosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    CosEndpoint string
    (String) The endpoint of the COS instance.
    CosLocation string
    Region of the COS instance.
    CosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    CreatedAt float64
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    Histories []BillingReportSnapshotHistoryArgs
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    Interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    LastUpdatedAt float64
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    ReportTypes []string
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    State string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    Versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    accountType String
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    billingReportSnapshotId String
    The unique identifier of the billing_report_snapshot.
    compression String
    (String) Compression format of the snapshot report.
    contentType String
    (String) Type of content stored in snapshot report.
    cosBucket String
    The name of the COS bucket to store the snapshot of the billing reports.
    cosEndpoint String
    (String) The endpoint of the COS instance.
    cosLocation String
    Region of the COS instance.
    cosReportsFolder String
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    createdAt Double
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    histories List<BillingReportSnapshotHistory>
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    interval String
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    lastUpdatedAt Double
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    reportTypes List<String>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    state String
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    versioning String
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    accountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    billingReportSnapshotId string
    The unique identifier of the billing_report_snapshot.
    compression string
    (String) Compression format of the snapshot report.
    contentType string
    (String) Type of content stored in snapshot report.
    cosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    cosEndpoint string
    (String) The endpoint of the COS instance.
    cosLocation string
    Region of the COS instance.
    cosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    createdAt number
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    histories BillingReportSnapshotHistory[]
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    lastUpdatedAt number
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    reportTypes string[]
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    state string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    account_type str
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    billing_report_snapshot_id str
    The unique identifier of the billing_report_snapshot.
    compression str
    (String) Compression format of the snapshot report.
    content_type str
    (String) Type of content stored in snapshot report.
    cos_bucket str
    The name of the COS bucket to store the snapshot of the billing reports.
    cos_endpoint str
    (String) The endpoint of the COS instance.
    cos_location str
    Region of the COS instance.
    cos_reports_folder str
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    created_at float
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    histories Sequence[BillingReportSnapshotHistoryArgs]
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    interval str
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    last_updated_at float
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    report_types Sequence[str]
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    state str
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    versioning str
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    accountType String
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    billingReportSnapshotId String
    The unique identifier of the billing_report_snapshot.
    compression String
    (String) Compression format of the snapshot report.
    contentType String
    (String) Type of content stored in snapshot report.
    cosBucket String
    The name of the COS bucket to store the snapshot of the billing reports.
    cosEndpoint String
    (String) The endpoint of the COS instance.
    cosLocation String
    Region of the COS instance.
    cosReportsFolder String
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    createdAt Number
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    histories List<Property Map>
    (List) List of previous versions of the snapshot configurations. Nested schema for history:
    interval String
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    lastUpdatedAt Number
    (Integer) Timestamp in milliseconds when the snapshot configuration was last updated.
    reportTypes List<String>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    state String
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    versioning String
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.

    Supporting Types

    BillingReportSnapshotHistory, BillingReportSnapshotHistoryArgs

    AccountId string
    (String) Account ID for which billing report snapshot is configured.
    AccountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    Compression string
    (String) Compression format of the snapshot report.
    ContentType string
    (String) Type of content stored in snapshot report.
    CosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    CosEndpoint string
    (String) The endpoint of the COS instance.
    CosLocation string
    Region of the COS instance.
    CosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    EndTime double
    (Integer) Timestamp in milliseconds when the snapshot configuration ends.
    Interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    ReportTypes List<string>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    StartTime double
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    State string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    UpdatedBy string
    (String) Account that updated the billing snapshot configuration.
    Versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    AccountId string
    (String) Account ID for which billing report snapshot is configured.
    AccountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    Compression string
    (String) Compression format of the snapshot report.
    ContentType string
    (String) Type of content stored in snapshot report.
    CosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    CosEndpoint string
    (String) The endpoint of the COS instance.
    CosLocation string
    Region of the COS instance.
    CosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    EndTime float64
    (Integer) Timestamp in milliseconds when the snapshot configuration ends.
    Interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    ReportTypes []string
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    StartTime float64
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    State string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    UpdatedBy string
    (String) Account that updated the billing snapshot configuration.
    Versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    accountId String
    (String) Account ID for which billing report snapshot is configured.
    accountType String
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    compression String
    (String) Compression format of the snapshot report.
    contentType String
    (String) Type of content stored in snapshot report.
    cosBucket String
    The name of the COS bucket to store the snapshot of the billing reports.
    cosEndpoint String
    (String) The endpoint of the COS instance.
    cosLocation String
    Region of the COS instance.
    cosReportsFolder String
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    endTime Double
    (Integer) Timestamp in milliseconds when the snapshot configuration ends.
    interval String
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    reportTypes List<String>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    startTime Double
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    state String
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    updatedBy String
    (String) Account that updated the billing snapshot configuration.
    versioning String
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    accountId string
    (String) Account ID for which billing report snapshot is configured.
    accountType string
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    compression string
    (String) Compression format of the snapshot report.
    contentType string
    (String) Type of content stored in snapshot report.
    cosBucket string
    The name of the COS bucket to store the snapshot of the billing reports.
    cosEndpoint string
    (String) The endpoint of the COS instance.
    cosLocation string
    Region of the COS instance.
    cosReportsFolder string
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    endTime number
    (Integer) Timestamp in milliseconds when the snapshot configuration ends.
    interval string
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    reportTypes string[]
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    startTime number
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    state string
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    updatedBy string
    (String) Account that updated the billing snapshot configuration.
    versioning string
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    account_id str
    (String) Account ID for which billing report snapshot is configured.
    account_type str
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    compression str
    (String) Compression format of the snapshot report.
    content_type str
    (String) Type of content stored in snapshot report.
    cos_bucket str
    The name of the COS bucket to store the snapshot of the billing reports.
    cos_endpoint str
    (String) The endpoint of the COS instance.
    cos_location str
    Region of the COS instance.
    cos_reports_folder str
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    end_time float
    (Integer) Timestamp in milliseconds when the snapshot configuration ends.
    interval str
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    report_types Sequence[str]
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    start_time float
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    state str
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    updated_by str
    (String) Account that updated the billing snapshot configuration.
    versioning str
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.
    accountId String
    (String) Account ID for which billing report snapshot is configured.
    accountType String
    (String) Type of account. Possible values [enterprise, account].

    • Constraints: Allowable values are: account, enterprise.
    compression String
    (String) Compression format of the snapshot report.
    contentType String
    (String) Type of content stored in snapshot report.
    cosBucket String
    The name of the COS bucket to store the snapshot of the billing reports.
    cosEndpoint String
    (String) The endpoint of the COS instance.
    cosLocation String
    Region of the COS instance.
    cosReportsFolder String
    The billing reports root folder to store the billing reports snapshots. Defaults to "IBMCloud-Billing-Reports".

    • Constraints: The default value is IBMCloud-Billing-Reports.
    endTime Number
    (Integer) Timestamp in milliseconds when the snapshot configuration ends.
    interval String
    Frequency of taking the snapshot of the billing reports.

    • Constraints: Allowable values are: daily.
    reportTypes List<String>
    The type of billing reports to take snapshot of. Possible values are [account_summary, enterprise_summary, account_resource_instance_usage].

    • Constraints: Allowable list items are: account_summary, enterprise_summary, account_resource_instance_usage.
    startTime Number
    (Integer) Timestamp in milliseconds when the snapshot configuration was created.
    state String
    (String) Status of the billing snapshot configuration. Possible values are [enabled, disabled].

    • Constraints: Allowable values are: enabled, disabled.
    updatedBy String
    (String) Account that updated the billing snapshot configuration.
    versioning String
    A new version of report is created or the existing report version is overwritten with every update.

    • Constraints: The default value is new. Allowable values are: new, overwrite.

    Import

    You can import the ibm_billing_report_snapshot resource by using account_id. Account ID for which billing report snapshot is configured.

    Syntax

    
    ```sh
    $ pulumi import ibm:index/billingReportSnapshot:BillingReportSnapshot billing_report_snapshot <account_id>
    ```
    
    

    Example

    $ pulumi import ibm:index/billingReportSnapshot:BillingReportSnapshot billing_report_snapshot abc
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    ibm logo
    ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud