CostAllocationTag

Provides a CE Cost Allocation Tag.

Example Usage

using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() => 
{
    var example = new Aws.CostExplorer.CostAllocationTag("example", new()
    {
        Status = "Active",
        TagKey = "example",
    });

});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v5/go/aws/costexplorer"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := costexplorer.NewCostAllocationTag(ctx, "example", &costexplorer.CostAllocationTagArgs{
			Status: pulumi.String("Active"),
			TagKey: pulumi.String("example"),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.costexplorer.CostAllocationTag;
import com.pulumi.aws.costexplorer.CostAllocationTagArgs;
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 example = new CostAllocationTag("example", CostAllocationTagArgs.builder()        
            .status("Active")
            .tagKey("example")
            .build());

    }
}
import pulumi
import pulumi_aws as aws

example = aws.costexplorer.CostAllocationTag("example",
    status="Active",
    tag_key="example")
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const example = new aws.costexplorer.CostAllocationTag("example", {
    status: "Active",
    tagKey: "example",
});
resources:
  example:
    type: aws:costexplorer:CostAllocationTag
    properties:
      status: Active
      tagKey: example

Create CostAllocationTag Resource

new CostAllocationTag(name: string, args: CostAllocationTagArgs, opts?: CustomResourceOptions);
@overload
def CostAllocationTag(resource_name: str,
                      opts: Optional[ResourceOptions] = None,
                      status: Optional[str] = None,
                      tag_key: Optional[str] = None)
@overload
def CostAllocationTag(resource_name: str,
                      args: CostAllocationTagArgs,
                      opts: Optional[ResourceOptions] = None)
func NewCostAllocationTag(ctx *Context, name string, args CostAllocationTagArgs, opts ...ResourceOption) (*CostAllocationTag, error)
public CostAllocationTag(string name, CostAllocationTagArgs args, CustomResourceOptions? opts = null)
public CostAllocationTag(String name, CostAllocationTagArgs args)
public CostAllocationTag(String name, CostAllocationTagArgs args, CustomResourceOptions options)
type: aws:costexplorer:CostAllocationTag
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

name string
The unique name of the resource.
args CostAllocationTagArgs
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 CostAllocationTagArgs
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 CostAllocationTagArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args CostAllocationTagArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name String
The unique name of the resource.
args CostAllocationTagArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

CostAllocationTag Resource Properties

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

Inputs

The CostAllocationTag resource accepts the following input properties:

Status string

The status of a cost allocation tag. Valid values are Active and Inactive.

TagKey string

The key for the cost allocation tag.

Status string

The status of a cost allocation tag. Valid values are Active and Inactive.

TagKey string

The key for the cost allocation tag.

status String

The status of a cost allocation tag. Valid values are Active and Inactive.

tagKey String

The key for the cost allocation tag.

status string

The status of a cost allocation tag. Valid values are Active and Inactive.

tagKey string

The key for the cost allocation tag.

status str

The status of a cost allocation tag. Valid values are Active and Inactive.

tag_key str

The key for the cost allocation tag.

status String

The status of a cost allocation tag. Valid values are Active and Inactive.

tagKey String

The key for the cost allocation tag.

Outputs

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

Id string

The provider-assigned unique ID for this managed resource.

Type string

The type of cost allocation tag.

Id string

The provider-assigned unique ID for this managed resource.

Type string

The type of cost allocation tag.

id String

The provider-assigned unique ID for this managed resource.

type String

The type of cost allocation tag.

id string

The provider-assigned unique ID for this managed resource.

type string

The type of cost allocation tag.

id str

The provider-assigned unique ID for this managed resource.

type str

The type of cost allocation tag.

id String

The provider-assigned unique ID for this managed resource.

type String

The type of cost allocation tag.

Look up Existing CostAllocationTag Resource

Get an existing CostAllocationTag 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?: CostAllocationTagState, opts?: CustomResourceOptions): CostAllocationTag
@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        status: Optional[str] = None,
        tag_key: Optional[str] = None,
        type: Optional[str] = None) -> CostAllocationTag
func GetCostAllocationTag(ctx *Context, name string, id IDInput, state *CostAllocationTagState, opts ...ResourceOption) (*CostAllocationTag, error)
public static CostAllocationTag Get(string name, Input<string> id, CostAllocationTagState? state, CustomResourceOptions? opts = null)
public static CostAllocationTag get(String name, Output<String> id, CostAllocationTagState state, CustomResourceOptions options)
Resource lookup is not supported in YAML
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:
Status string

The status of a cost allocation tag. Valid values are Active and Inactive.

TagKey string

The key for the cost allocation tag.

Type string

The type of cost allocation tag.

Status string

The status of a cost allocation tag. Valid values are Active and Inactive.

TagKey string

The key for the cost allocation tag.

Type string

The type of cost allocation tag.

status String

The status of a cost allocation tag. Valid values are Active and Inactive.

tagKey String

The key for the cost allocation tag.

type String

The type of cost allocation tag.

status string

The status of a cost allocation tag. Valid values are Active and Inactive.

tagKey string

The key for the cost allocation tag.

type string

The type of cost allocation tag.

status str

The status of a cost allocation tag. Valid values are Active and Inactive.

tag_key str

The key for the cost allocation tag.

type str

The type of cost allocation tag.

status String

The status of a cost allocation tag. Valid values are Active and Inactive.

tagKey String

The key for the cost allocation tag.

type String

The type of cost allocation tag.

Import

aws_ce_cost_allocation_tag can be imported using the id, e.g.

 $ pulumi import aws:costexplorer/costAllocationTag:CostAllocationTag example key

Package Details

Repository
https://github.com/pulumi/pulumi-aws
License
Apache-2.0
Notes

This Pulumi package is based on the aws Terraform Provider.