aws.costoptimizationhub.EnrollmentStatus
Explore with Pulumi AI
Resource for managing AWS Cost Optimization Hub Enrollment Status.
TIP: The Cost Optimization Hub only has a
us-east-1
endpoint. However, you can access the service globally with the AWS Provider from other regions. Other tools, such as the AWS CLI, may require you to specify theus-east-1
region when using the service.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.costoptimizationhub.EnrollmentStatus("example", {});
import pulumi
import pulumi_aws as aws
example = aws.costoptimizationhub.EnrollmentStatus("example")
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/costoptimizationhub"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := costoptimizationhub.NewEnrollmentStatus(ctx, "example", nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.CostOptimizationHub.EnrollmentStatus("example");
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.costoptimizationhub.EnrollmentStatus;
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 EnrollmentStatus("example");
}
}
resources:
example:
type: aws:costoptimizationhub:EnrollmentStatus
Usage with all the arguments
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const example = new aws.costoptimizationhub.EnrollmentStatus("example", {includeMemberAccounts: true});
import pulumi
import pulumi_aws as aws
example = aws.costoptimizationhub.EnrollmentStatus("example", include_member_accounts=True)
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/costoptimizationhub"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := costoptimizationhub.NewEnrollmentStatus(ctx, "example", &costoptimizationhub.EnrollmentStatusArgs{
IncludeMemberAccounts: pulumi.Bool(true),
})
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var example = new Aws.CostOptimizationHub.EnrollmentStatus("example", new()
{
IncludeMemberAccounts = true,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.costoptimizationhub.EnrollmentStatus;
import com.pulumi.aws.costoptimizationhub.EnrollmentStatusArgs;
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 EnrollmentStatus("example", EnrollmentStatusArgs.builder()
.includeMemberAccounts(true)
.build());
}
}
resources:
example:
type: aws:costoptimizationhub:EnrollmentStatus
properties:
includeMemberAccounts: true
Create EnrollmentStatus Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new EnrollmentStatus(name: string, args?: EnrollmentStatusArgs, opts?: CustomResourceOptions);
@overload
def EnrollmentStatus(resource_name: str,
args: Optional[EnrollmentStatusArgs] = None,
opts: Optional[ResourceOptions] = None)
@overload
def EnrollmentStatus(resource_name: str,
opts: Optional[ResourceOptions] = None,
include_member_accounts: Optional[bool] = None)
func NewEnrollmentStatus(ctx *Context, name string, args *EnrollmentStatusArgs, opts ...ResourceOption) (*EnrollmentStatus, error)
public EnrollmentStatus(string name, EnrollmentStatusArgs? args = null, CustomResourceOptions? opts = null)
public EnrollmentStatus(String name, EnrollmentStatusArgs args)
public EnrollmentStatus(String name, EnrollmentStatusArgs args, CustomResourceOptions options)
type: aws:costoptimizationhub:EnrollmentStatus
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 EnrollmentStatusArgs
- 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 EnrollmentStatusArgs
- 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 EnrollmentStatusArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args EnrollmentStatusArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args EnrollmentStatusArgs
- 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 awsEnrollmentStatusResource = new Aws.CostOptimizationHub.EnrollmentStatus("awsEnrollmentStatusResource", new()
{
IncludeMemberAccounts = false,
});
example, err := costoptimizationhub.NewEnrollmentStatus(ctx, "awsEnrollmentStatusResource", &costoptimizationhub.EnrollmentStatusArgs{
IncludeMemberAccounts: pulumi.Bool(false),
})
var awsEnrollmentStatusResource = new EnrollmentStatus("awsEnrollmentStatusResource", EnrollmentStatusArgs.builder()
.includeMemberAccounts(false)
.build());
aws_enrollment_status_resource = aws.costoptimizationhub.EnrollmentStatus("awsEnrollmentStatusResource", include_member_accounts=False)
const awsEnrollmentStatusResource = new aws.costoptimizationhub.EnrollmentStatus("awsEnrollmentStatusResource", {includeMemberAccounts: false});
type: aws:costoptimizationhub:EnrollmentStatus
properties:
includeMemberAccounts: false
EnrollmentStatus 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 EnrollmentStatus resource accepts the following input properties:
- Include
Member boolAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
.
- Include
Member boolAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
.
- include
Member BooleanAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
.
- include
Member booleanAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
.
- include_
member_ boolaccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
.
- include
Member BooleanAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
.
Outputs
All input properties are implicitly available as output properties. Additionally, the EnrollmentStatus resource produces the following output properties:
Look up Existing EnrollmentStatus Resource
Get an existing EnrollmentStatus 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?: EnrollmentStatusState, opts?: CustomResourceOptions): EnrollmentStatus
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
include_member_accounts: Optional[bool] = None,
status: Optional[str] = None) -> EnrollmentStatus
func GetEnrollmentStatus(ctx *Context, name string, id IDInput, state *EnrollmentStatusState, opts ...ResourceOption) (*EnrollmentStatus, error)
public static EnrollmentStatus Get(string name, Input<string> id, EnrollmentStatusState? state, CustomResourceOptions? opts = null)
public static EnrollmentStatus get(String name, Output<String> id, EnrollmentStatusState 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.
- Include
Member boolAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
. - Status string
- Include
Member boolAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
. - Status string
- include
Member BooleanAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
. - status String
- include
Member booleanAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
. - status string
- include_
member_ boolaccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
. - status str
- include
Member BooleanAccounts - Flag to enroll member accounts of the organization if the account is the management account. No drift detection is currently supported for this argument. Default value is
false
. - status String
Import
Using pulumi import
, import Cost Optimization Hub Enrollment Status using your AWS account ID. For example:
$ pulumi import aws:costoptimizationhub/enrollmentStatus:EnrollmentStatus example 111222333444
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.