Documentation ¶
Index ¶
- func CfnBudget_CFN_RESOURCE_TYPE_NAME() *string
- func CfnBudget_IsCfnElement(x interface{}) *bool
- func CfnBudget_IsCfnResource(construct constructs.IConstruct) *bool
- func CfnBudget_IsConstruct(x interface{}) *bool
- func CfnBudgetsAction_CFN_RESOURCE_TYPE_NAME() *string
- func CfnBudgetsAction_IsCfnElement(x interface{}) *bool
- func CfnBudgetsAction_IsCfnResource(construct constructs.IConstruct) *bool
- func CfnBudgetsAction_IsConstruct(x interface{}) *bool
- func NewCfnBudget_Override(c CfnBudget, scope constructs.Construct, id *string, props *CfnBudgetProps)
- func NewCfnBudgetsAction_Override(c CfnBudgetsAction, scope constructs.Construct, id *string, ...)
- type CfnBudget
- type CfnBudgetProps
- type CfnBudget_AutoAdjustDataProperty
- type CfnBudget_BudgetDataProperty
- type CfnBudget_CostTypesProperty
- type CfnBudget_HistoricalOptionsProperty
- type CfnBudget_NotificationProperty
- type CfnBudget_NotificationWithSubscribersProperty
- type CfnBudget_SpendProperty
- type CfnBudget_SubscriberProperty
- type CfnBudget_TimePeriodProperty
- type CfnBudgetsAction
- type CfnBudgetsActionProps
- type CfnBudgetsAction_ActionThresholdProperty
- type CfnBudgetsAction_DefinitionProperty
- type CfnBudgetsAction_IamActionDefinitionProperty
- type CfnBudgetsAction_ScpActionDefinitionProperty
- type CfnBudgetsAction_SsmActionDefinitionProperty
- type CfnBudgetsAction_SubscriberProperty
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CfnBudget_CFN_RESOURCE_TYPE_NAME ¶
func CfnBudget_CFN_RESOURCE_TYPE_NAME() *string
func CfnBudget_IsCfnElement ¶
func CfnBudget_IsCfnElement(x interface{}) *bool
Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).
Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.
Returns: The construct as a stack element or undefined if it is not a stack element.
func CfnBudget_IsCfnResource ¶
func CfnBudget_IsCfnResource(construct constructs.IConstruct) *bool
Check whether the given construct is a CfnResource.
func CfnBudget_IsConstruct ¶
func CfnBudget_IsConstruct(x interface{}) *bool
Checks if `x` is a construct.
Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.
Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.
Returns: true if `x` is an object created from a class which extends `Construct`.
func CfnBudgetsAction_CFN_RESOURCE_TYPE_NAME ¶
func CfnBudgetsAction_CFN_RESOURCE_TYPE_NAME() *string
func CfnBudgetsAction_IsCfnElement ¶
func CfnBudgetsAction_IsCfnElement(x interface{}) *bool
Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).
Uses duck-typing instead of `instanceof` to allow stack elements from different versions of this library to be included in the same stack.
Returns: The construct as a stack element or undefined if it is not a stack element.
func CfnBudgetsAction_IsCfnResource ¶
func CfnBudgetsAction_IsCfnResource(construct constructs.IConstruct) *bool
Check whether the given construct is a CfnResource.
func CfnBudgetsAction_IsConstruct ¶
func CfnBudgetsAction_IsConstruct(x interface{}) *bool
Checks if `x` is a construct.
Use this method instead of `instanceof` to properly detect `Construct` instances, even when the construct library is symlinked.
Explanation: in JavaScript, multiple copies of the `constructs` library on disk are seen as independent, completely different libraries. As a consequence, the class `Construct` in each copy of the `constructs` library is seen as a different class, and an instance of one class will not test as `instanceof` the other class. `npm install` will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the `constructs` library can be accidentally installed, and `instanceof` will behave unpredictably. It is safest to avoid using `instanceof`, and using this type-testing method instead.
Returns: true if `x` is an object created from a class which extends `Construct`.
func NewCfnBudget_Override ¶
func NewCfnBudget_Override(c CfnBudget, scope constructs.Construct, id *string, props *CfnBudgetProps)
func NewCfnBudgetsAction_Override ¶
func NewCfnBudgetsAction_Override(c CfnBudgetsAction, scope constructs.Construct, id *string, props *CfnBudgetsActionProps)
Types ¶
type CfnBudget ¶
type CfnBudget interface { awscdk.CfnResource awscdk.IInspectable AttrId() *string // The budget object that you want to create. Budget() interface{} SetBudget(val interface{}) // Options for this resource, such as condition, update policy etc. CfnOptions() awscdk.ICfnResourceOptions CfnProperties() *map[string]interface{} // AWS resource type. CfnResourceType() *string // Returns: the stack trace of the point where this Resource was created from, sourced // from the +metadata+ entry typed +aws:cdk:logicalId+, and with the bottom-most // node +internal+ entries filtered. CreationStack() *[]*string // The logical ID for this CloudFormation stack element. // // The logical ID of the element // is calculated from the path of the resource node in the construct tree. // // To override this value, use `overrideLogicalId(newLogicalId)`. // // Returns: the logical ID as a stringified token. This value will only get // resolved during synthesis. LogicalId() *string // The tree node. Node() constructs.Node // A notification that you want to associate with a budget. NotificationsWithSubscribers() interface{} SetNotificationsWithSubscribers(val interface{}) // Return a string that will be resolved to a CloudFormation `{ Ref }` for this element. // // If, by any chance, the intrinsic reference of a resource is not a string, you could // coerce it to an IResolvable through `Lazy.any({ produce: resource.ref })`. Ref() *string // The stack in which this element is defined. // // CfnElements must be defined within a stack scope (directly or indirectly). Stack() awscdk.Stack // Deprecated. // Deprecated: use `updatedProperties` // // Return properties modified after initiation // // Resources that expose mutable properties should override this function to // collect and return the properties object for this resource. UpdatedProperites() *map[string]interface{} // Return properties modified after initiation. // // Resources that expose mutable properties should override this function to // collect and return the properties object for this resource. UpdatedProperties() *map[string]interface{} // Syntactic sugar for `addOverride(path, undefined)`. AddDeletionOverride(path *string) // Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned. // // This can be used for resources across stacks (or nested stack) boundaries // and the dependency will automatically be transferred to the relevant scope. AddDependency(target awscdk.CfnResource) // Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned. // Deprecated: use addDependency. AddDependsOn(target awscdk.CfnResource) // Add a value to the CloudFormation Resource Metadata. // See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html // // Note that this is a different set of metadata from CDK node metadata; this // metadata ends up in the stack template under the resource, whereas CDK // node metadata ends up in the Cloud Assembly. // AddMetadata(key *string, value interface{}) // Adds an override to the synthesized CloudFormation resource. // // To add a // property override, either use `addPropertyOverride` or prefix `path` with // "Properties." (i.e. `Properties.TopicName`). // // If the override is nested, separate each nested level using a dot (.) in the path parameter. // If there is an array as part of the nesting, specify the index in the path. // // To include a literal `.` in the property name, prefix with a `\`. In most // programming languages you will need to write this as `"\\."` because the // `\` itself will need to be escaped. // // For example, // “`typescript // cfnResource.addOverride('Properties.GlobalSecondaryIndexes.0.Projection.NonKeyAttributes', ['myattribute']); // cfnResource.addOverride('Properties.GlobalSecondaryIndexes.1.ProjectionType', 'INCLUDE'); // “` // would add the overrides // “`json // "Properties": { // "GlobalSecondaryIndexes": [ // { // "Projection": { // "NonKeyAttributes": [ "myattribute" ] // ... // } // ... // }, // { // "ProjectionType": "INCLUDE" // ... // }, // ] // ... // } // “` // // The `value` argument to `addOverride` will not be processed or translated // in any way. Pass raw JSON values in here with the correct capitalization // for CloudFormation. If you pass CDK classes or structs, they will be // rendered with lowercased key names, and CloudFormation will reject the // template. AddOverride(path *string, value interface{}) // Adds an override that deletes the value of a property from the resource definition. AddPropertyDeletionOverride(propertyPath *string) // Adds an override to a resource property. // // Syntactic sugar for `addOverride("Properties.<...>", value)`. AddPropertyOverride(propertyPath *string, value interface{}) // Sets the deletion policy of the resource based on the removal policy specified. // // The Removal Policy controls what happens to this resource when it stops // being managed by CloudFormation, either because you've removed it from the // CDK application or because you've made a change that requires the resource // to be replaced. // // The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS // account for data recovery and cleanup later (`RemovalPolicy.RETAIN`). In some // cases, a snapshot can be taken of the resource prior to deletion // (`RemovalPolicy.SNAPSHOT`). A list of resources that support this policy // can be found in the following link:. // See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-deletionpolicy.html#aws-attribute-deletionpolicy-options // ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions) // Returns a token for an runtime attribute of this resource. // // Ideally, use generated attribute accessors (e.g. `resource.arn`), but this can be used for future compatibility // in case there is no generated attribute. GetAtt(attributeName *string, typeHint awscdk.ResolutionTypeHint) awscdk.Reference // Retrieve a value value from the CloudFormation Resource Metadata. // See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html // // Note that this is a different set of metadata from CDK node metadata; this // metadata ends up in the stack template under the resource, whereas CDK // node metadata ends up in the Cloud Assembly. // GetMetadata(key *string) interface{} // Examines the CloudFormation resource and discloses attributes. Inspect(inspector awscdk.TreeInspector) // Retrieves an array of resources this resource depends on. // // This assembles dependencies on resources across stacks (including nested stacks) // automatically. ObtainDependencies() *[]interface{} // Get a shallow copy of dependencies between this resource and other resources in the same stack. ObtainResourceDependencies() *[]awscdk.CfnResource // Overrides the auto-generated logical ID with a specific ID. OverrideLogicalId(newLogicalId *string) // Indicates that this resource no longer depends on another resource. // // This can be used for resources across stacks (including nested stacks) // and the dependency will automatically be removed from the relevant scope. RemoveDependency(target awscdk.CfnResource) RenderProperties(props *map[string]interface{}) *map[string]interface{} // Replaces one dependency with another. ReplaceDependency(target awscdk.CfnResource, newTarget awscdk.CfnResource) // Can be overridden by subclasses to determine if this resource will be rendered into the cloudformation template. // // Returns: `true` if the resource should be included or `false` is the resource // should be omitted. ShouldSynthesize() *bool // Returns a string representation of this construct. // // Returns: a string representation of this resource. ToString() *string ValidateProperties(_properties interface{}) }
The `AWS::Budgets::Budget` resource allows customers to take pre-defined actions that will trigger once a budget threshold has been exceeded.
creates, replaces, or deletes budgets for Billing and Cost Management. For more information, see [Managing Your Costs with Budgets](https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/budgets-managing-costs.html) in the *AWS Billing and Cost Management User Guide* .
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" var costFilters interface{} var plannedBudgetLimits interface{} cfnBudget := awscdk.Aws_budgets.NewCfnBudget(this, jsii.String("MyCfnBudget"), &CfnBudgetProps{ Budget: &BudgetDataProperty{ BudgetType: jsii.String("budgetType"), TimeUnit: jsii.String("timeUnit"), // the properties below are optional AutoAdjustData: &AutoAdjustDataProperty{ AutoAdjustType: jsii.String("autoAdjustType"), // the properties below are optional HistoricalOptions: &HistoricalOptionsProperty{ BudgetAdjustmentPeriod: jsii.Number(123), }, }, BudgetLimit: &SpendProperty{ Amount: jsii.Number(123), Unit: jsii.String("unit"), }, BudgetName: jsii.String("budgetName"), CostFilters: costFilters, CostTypes: &CostTypesProperty{ IncludeCredit: jsii.Boolean(false), IncludeDiscount: jsii.Boolean(false), IncludeOtherSubscription: jsii.Boolean(false), IncludeRecurring: jsii.Boolean(false), IncludeRefund: jsii.Boolean(false), IncludeSubscription: jsii.Boolean(false), IncludeSupport: jsii.Boolean(false), IncludeTax: jsii.Boolean(false), IncludeUpfront: jsii.Boolean(false), UseAmortized: jsii.Boolean(false), UseBlended: jsii.Boolean(false), }, PlannedBudgetLimits: plannedBudgetLimits, TimePeriod: &TimePeriodProperty{ End: jsii.String("end"), Start: jsii.String("start"), }, }, // the properties below are optional NotificationsWithSubscribers: []interface{}{ &NotificationWithSubscribersProperty{ Notification: &NotificationProperty{ ComparisonOperator: jsii.String("comparisonOperator"), NotificationType: jsii.String("notificationType"), Threshold: jsii.Number(123), // the properties below are optional ThresholdType: jsii.String("thresholdType"), }, Subscribers: []interface{}{ &SubscriberProperty{ Address: jsii.String("address"), SubscriptionType: jsii.String("subscriptionType"), }, }, }, }, })
See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budget.html
func NewCfnBudget ¶
func NewCfnBudget(scope constructs.Construct, id *string, props *CfnBudgetProps) CfnBudget
type CfnBudgetProps ¶
type CfnBudgetProps struct { // The budget object that you want to create. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budget.html#cfn-budgets-budget-budget // Budget interface{} `field:"required" json:"budget" yaml:"budget"` // A notification that you want to associate with a budget. // // A budget can have up to five notifications, and each notification can have one SNS subscriber and up to 10 email subscribers. If you include notifications and subscribers in your `CreateBudget` call, AWS creates the notifications and subscribers for you. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budget.html#cfn-budgets-budget-notificationswithsubscribers // NotificationsWithSubscribers interface{} `field:"optional" json:"notificationsWithSubscribers" yaml:"notificationsWithSubscribers"` }
Properties for defining a `CfnBudget`.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" var costFilters interface{} var plannedBudgetLimits interface{} cfnBudgetProps := &CfnBudgetProps{ Budget: &BudgetDataProperty{ BudgetType: jsii.String("budgetType"), TimeUnit: jsii.String("timeUnit"), // the properties below are optional AutoAdjustData: &AutoAdjustDataProperty{ AutoAdjustType: jsii.String("autoAdjustType"), // the properties below are optional HistoricalOptions: &HistoricalOptionsProperty{ BudgetAdjustmentPeriod: jsii.Number(123), }, }, BudgetLimit: &SpendProperty{ Amount: jsii.Number(123), Unit: jsii.String("unit"), }, BudgetName: jsii.String("budgetName"), CostFilters: costFilters, CostTypes: &CostTypesProperty{ IncludeCredit: jsii.Boolean(false), IncludeDiscount: jsii.Boolean(false), IncludeOtherSubscription: jsii.Boolean(false), IncludeRecurring: jsii.Boolean(false), IncludeRefund: jsii.Boolean(false), IncludeSubscription: jsii.Boolean(false), IncludeSupport: jsii.Boolean(false), IncludeTax: jsii.Boolean(false), IncludeUpfront: jsii.Boolean(false), UseAmortized: jsii.Boolean(false), UseBlended: jsii.Boolean(false), }, PlannedBudgetLimits: plannedBudgetLimits, TimePeriod: &TimePeriodProperty{ End: jsii.String("end"), Start: jsii.String("start"), }, }, // the properties below are optional NotificationsWithSubscribers: []interface{}{ &NotificationWithSubscribersProperty{ Notification: &NotificationProperty{ ComparisonOperator: jsii.String("comparisonOperator"), NotificationType: jsii.String("notificationType"), Threshold: jsii.Number(123), // the properties below are optional ThresholdType: jsii.String("thresholdType"), }, Subscribers: []interface{}{ &SubscriberProperty{ Address: jsii.String("address"), SubscriptionType: jsii.String("subscriptionType"), }, }, }, }, }
See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budget.html
type CfnBudget_AutoAdjustDataProperty ¶ added in v2.48.0
type CfnBudget_AutoAdjustDataProperty struct { // The string that defines whether your budget auto-adjusts based on historical or forecasted data. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-autoadjustdata.html#cfn-budgets-budget-autoadjustdata-autoadjusttype // AutoAdjustType *string `field:"required" json:"autoAdjustType" yaml:"autoAdjustType"` // The parameters that define or describe the historical data that your auto-adjusting budget is based on. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-autoadjustdata.html#cfn-budgets-budget-autoadjustdata-historicaloptions // HistoricalOptions interface{} `field:"optional" json:"historicalOptions" yaml:"historicalOptions"` }
Determine the budget amount for an auto-adjusting budget.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" autoAdjustDataProperty := &AutoAdjustDataProperty{ AutoAdjustType: jsii.String("autoAdjustType"), // the properties below are optional HistoricalOptions: &HistoricalOptionsProperty{ BudgetAdjustmentPeriod: jsii.Number(123), }, }
type CfnBudget_BudgetDataProperty ¶
type CfnBudget_BudgetDataProperty struct { // Specifies whether this budget tracks costs, usage, RI utilization, RI coverage, Savings Plans utilization, or Savings Plans coverage. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-budgettype // BudgetType *string `field:"required" json:"budgetType" yaml:"budgetType"` // The length of time until a budget resets the actual and forecasted spend. // // `DAILY` is available only for `RI_UTILIZATION` and `RI_COVERAGE` budgets. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-timeunit // TimeUnit *string `field:"required" json:"timeUnit" yaml:"timeUnit"` // Determine the budget amount for an auto-adjusting budget. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-autoadjustdata // AutoAdjustData interface{} `field:"optional" json:"autoAdjustData" yaml:"autoAdjustData"` // The total amount of cost, usage, RI utilization, RI coverage, Savings Plans utilization, or Savings Plans coverage that you want to track with your budget. // // `BudgetLimit` is required for cost or usage budgets, but optional for RI or Savings Plans utilization or coverage budgets. RI and Savings Plans utilization or coverage budgets default to `100` . This is the only valid value for RI or Savings Plans utilization or coverage budgets. You can't use `BudgetLimit` with `PlannedBudgetLimits` for `CreateBudget` and `UpdateBudget` actions. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-budgetlimit // BudgetLimit interface{} `field:"optional" json:"budgetLimit" yaml:"budgetLimit"` // The name of a budget. // // The value must be unique within an account. `BudgetName` can't include `:` and `\` characters. If you don't include value for `BudgetName` in the template, Billing and Cost Management assigns your budget a randomly generated name. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-budgetname // BudgetName *string `field:"optional" json:"budgetName" yaml:"budgetName"` // The cost filters, such as `Region` , `Service` , `LinkedAccount` , `Tag` , or `CostCategory` , that are applied to a budget. // // AWS Budgets supports the following services as a `Service` filter for RI budgets: // // - Amazon EC2 // - Amazon Redshift // - Amazon Relational Database Service // - Amazon ElastiCache // - Amazon OpenSearch Service. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-costfilters // CostFilters interface{} `field:"optional" json:"costFilters" yaml:"costFilters"` // The types of costs that are included in this `COST` budget. // // `USAGE` , `RI_UTILIZATION` , `RI_COVERAGE` , `SAVINGS_PLANS_UTILIZATION` , and `SAVINGS_PLANS_COVERAGE` budgets do not have `CostTypes` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-costtypes // CostTypes interface{} `field:"optional" json:"costTypes" yaml:"costTypes"` // A map containing multiple `BudgetLimit` , including current or future limits. // // `PlannedBudgetLimits` is available for cost or usage budget and supports both monthly and quarterly `TimeUnit` . // // For monthly budgets, provide 12 months of `PlannedBudgetLimits` values. This must start from the current month and include the next 11 months. The `key` is the start of the month, `UTC` in epoch seconds. // // For quarterly budgets, provide four quarters of `PlannedBudgetLimits` value entries in standard calendar quarter increments. This must start from the current quarter and include the next three quarters. The `key` is the start of the quarter, `UTC` in epoch seconds. // // If the planned budget expires before 12 months for monthly or four quarters for quarterly, provide the `PlannedBudgetLimits` values only for the remaining periods. // // If the budget begins at a date in the future, provide `PlannedBudgetLimits` values from the start date of the budget. // // After all of the `BudgetLimit` values in `PlannedBudgetLimits` are used, the budget continues to use the last limit as the `BudgetLimit` . At that point, the planned budget provides the same experience as a fixed budget. // // `DescribeBudget` and `DescribeBudgets` response along with `PlannedBudgetLimits` also contain `BudgetLimit` representing the current month or quarter limit present in `PlannedBudgetLimits` . This only applies to budgets that are created with `PlannedBudgetLimits` . Budgets that are created without `PlannedBudgetLimits` only contain `BudgetLimit` . They don't contain `PlannedBudgetLimits` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-plannedbudgetlimits // PlannedBudgetLimits interface{} `field:"optional" json:"plannedBudgetLimits" yaml:"plannedBudgetLimits"` // The period of time that is covered by a budget. // // The period has a start date and an end date. The start date must come before the end date. There are no restrictions on the end date. // // The start date for a budget. If you created your budget and didn't specify a start date, the start date defaults to the start of the chosen time period (MONTHLY, QUARTERLY, or ANNUALLY). For example, if you create your budget on January 24, 2019, choose `MONTHLY` , and don't set a start date, the start date defaults to `01/01/19 00:00 UTC` . The defaults are the same for the AWS Billing and Cost Management console and the API. // // You can change your start date with the `UpdateBudget` operation. // // After the end date, AWS deletes the budget and all associated notifications and subscribers. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-budgetdata.html#cfn-budgets-budget-budgetdata-timeperiod // TimePeriod interface{} `field:"optional" json:"timePeriod" yaml:"timePeriod"` }
Represents the output of the `CreateBudget` operation.
The content consists of the detailed metadata and data file information, and the current status of the `budget` object.
This is the Amazon Resource Name (ARN) pattern for a budget:
`arn:aws:budgets::AccountId:budget/budgetName`.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" var costFilters interface{} var plannedBudgetLimits interface{} budgetDataProperty := &BudgetDataProperty{ BudgetType: jsii.String("budgetType"), TimeUnit: jsii.String("timeUnit"), // the properties below are optional AutoAdjustData: &AutoAdjustDataProperty{ AutoAdjustType: jsii.String("autoAdjustType"), // the properties below are optional HistoricalOptions: &HistoricalOptionsProperty{ BudgetAdjustmentPeriod: jsii.Number(123), }, }, BudgetLimit: &SpendProperty{ Amount: jsii.Number(123), Unit: jsii.String("unit"), }, BudgetName: jsii.String("budgetName"), CostFilters: costFilters, CostTypes: &CostTypesProperty{ IncludeCredit: jsii.Boolean(false), IncludeDiscount: jsii.Boolean(false), IncludeOtherSubscription: jsii.Boolean(false), IncludeRecurring: jsii.Boolean(false), IncludeRefund: jsii.Boolean(false), IncludeSubscription: jsii.Boolean(false), IncludeSupport: jsii.Boolean(false), IncludeTax: jsii.Boolean(false), IncludeUpfront: jsii.Boolean(false), UseAmortized: jsii.Boolean(false), UseBlended: jsii.Boolean(false), }, PlannedBudgetLimits: plannedBudgetLimits, TimePeriod: &TimePeriodProperty{ End: jsii.String("end"), Start: jsii.String("start"), }, }
type CfnBudget_CostTypesProperty ¶
type CfnBudget_CostTypesProperty struct { // Specifies whether a budget includes credits. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includecredit // IncludeCredit interface{} `field:"optional" json:"includeCredit" yaml:"includeCredit"` // Specifies whether a budget includes discounts. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includediscount // IncludeDiscount interface{} `field:"optional" json:"includeDiscount" yaml:"includeDiscount"` // Specifies whether a budget includes non-RI subscription costs. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includeothersubscription // IncludeOtherSubscription interface{} `field:"optional" json:"includeOtherSubscription" yaml:"includeOtherSubscription"` // Specifies whether a budget includes recurring fees such as monthly RI fees. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includerecurring // IncludeRecurring interface{} `field:"optional" json:"includeRecurring" yaml:"includeRecurring"` // Specifies whether a budget includes refunds. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includerefund // IncludeRefund interface{} `field:"optional" json:"includeRefund" yaml:"includeRefund"` // Specifies whether a budget includes subscriptions. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includesubscription // IncludeSubscription interface{} `field:"optional" json:"includeSubscription" yaml:"includeSubscription"` // Specifies whether a budget includes support subscription fees. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includesupport // IncludeSupport interface{} `field:"optional" json:"includeSupport" yaml:"includeSupport"` // Specifies whether a budget includes taxes. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includetax // IncludeTax interface{} `field:"optional" json:"includeTax" yaml:"includeTax"` // Specifies whether a budget includes upfront RI costs. // // The default value is `true` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-includeupfront // IncludeUpfront interface{} `field:"optional" json:"includeUpfront" yaml:"includeUpfront"` // Specifies whether a budget uses the amortized rate. // // The default value is `false` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-useamortized // UseAmortized interface{} `field:"optional" json:"useAmortized" yaml:"useAmortized"` // Specifies whether a budget uses a blended rate. // // The default value is `false` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-costtypes.html#cfn-budgets-budget-costtypes-useblended // UseBlended interface{} `field:"optional" json:"useBlended" yaml:"useBlended"` }
The types of cost that are included in a `COST` budget, such as tax and subscriptions.
`USAGE` , `RI_UTILIZATION` , `RI_COVERAGE` , `SAVINGS_PLANS_UTILIZATION` , and `SAVINGS_PLANS_COVERAGE` budgets don't have `CostTypes` .
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" costTypesProperty := &CostTypesProperty{ IncludeCredit: jsii.Boolean(false), IncludeDiscount: jsii.Boolean(false), IncludeOtherSubscription: jsii.Boolean(false), IncludeRecurring: jsii.Boolean(false), IncludeRefund: jsii.Boolean(false), IncludeSubscription: jsii.Boolean(false), IncludeSupport: jsii.Boolean(false), IncludeTax: jsii.Boolean(false), IncludeUpfront: jsii.Boolean(false), UseAmortized: jsii.Boolean(false), UseBlended: jsii.Boolean(false), }
type CfnBudget_HistoricalOptionsProperty ¶ added in v2.48.0
type CfnBudget_HistoricalOptionsProperty struct { // The number of budget periods included in the moving-average calculation that determines your auto-adjusted budget amount. // // The maximum value depends on the `TimeUnit` granularity of the budget: // // - For the `DAILY` granularity, the maximum value is `60` . // - For the `MONTHLY` granularity, the maximum value is `12` . // - For the `QUARTERLY` granularity, the maximum value is `4` . // - For the `ANNUALLY` granularity, the maximum value is `1` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-historicaloptions.html#cfn-budgets-budget-historicaloptions-budgetadjustmentperiod // BudgetAdjustmentPeriod *float64 `field:"required" json:"budgetAdjustmentPeriod" yaml:"budgetAdjustmentPeriod"` }
The parameters that define or describe the historical data that your auto-adjusting budget is based on.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" historicalOptionsProperty := &HistoricalOptionsProperty{ BudgetAdjustmentPeriod: jsii.Number(123), }
type CfnBudget_NotificationProperty ¶
type CfnBudget_NotificationProperty struct { // The comparison that's used for this notification. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-notification.html#cfn-budgets-budget-notification-comparisonoperator // ComparisonOperator *string `field:"required" json:"comparisonOperator" yaml:"comparisonOperator"` // Specifies whether the notification is for how much you have spent ( `ACTUAL` ) or for how much that you're forecasted to spend ( `FORECASTED` ). // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-notification.html#cfn-budgets-budget-notification-notificationtype // NotificationType *string `field:"required" json:"notificationType" yaml:"notificationType"` // The threshold that's associated with a notification. // // Thresholds are always a percentage, and many customers find value being alerted between 50% - 200% of the budgeted amount. The maximum limit for your threshold is 1,000,000% above the budgeted amount. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-notification.html#cfn-budgets-budget-notification-threshold // Threshold *float64 `field:"required" json:"threshold" yaml:"threshold"` // The type of threshold for a notification. // // For `ABSOLUTE_VALUE` thresholds, AWS notifies you when you go over or are forecasted to go over your total cost threshold. For `PERCENTAGE` thresholds, AWS notifies you when you go over or are forecasted to go over a certain percentage of your forecasted spend. For example, if you have a budget for 200 dollars and you have a `PERCENTAGE` threshold of 80%, AWS notifies you when you go over 160 dollars. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-notification.html#cfn-budgets-budget-notification-thresholdtype // ThresholdType *string `field:"optional" json:"thresholdType" yaml:"thresholdType"` }
A notification that's associated with a budget. A budget can have up to ten notifications.
Each notification must have at least one subscriber. A notification can have one SNS subscriber and up to 10 email subscribers, for a total of 11 subscribers.
For example, if you have a budget for 200 dollars and you want to be notified when you go over 160 dollars, create a notification with the following parameters:
- A notificationType of `ACTUAL` - A `thresholdType` of `PERCENTAGE` - A `comparisonOperator` of `GREATER_THAN` - A notification `threshold` of `80`.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" notificationProperty := &NotificationProperty{ ComparisonOperator: jsii.String("comparisonOperator"), NotificationType: jsii.String("notificationType"), Threshold: jsii.Number(123), // the properties below are optional ThresholdType: jsii.String("thresholdType"), }
type CfnBudget_NotificationWithSubscribersProperty ¶
type CfnBudget_NotificationWithSubscribersProperty struct { // The notification that's associated with a budget. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-notificationwithsubscribers.html#cfn-budgets-budget-notificationwithsubscribers-notification // Notification interface{} `field:"required" json:"notification" yaml:"notification"` // A list of subscribers who are subscribed to this notification. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-notificationwithsubscribers.html#cfn-budgets-budget-notificationwithsubscribers-subscribers // Subscribers interface{} `field:"required" json:"subscribers" yaml:"subscribers"` }
A notification with subscribers.
A notification can have one SNS subscriber and up to 10 email subscribers, for a total of 11 subscribers.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" notificationWithSubscribersProperty := &NotificationWithSubscribersProperty{ Notification: &NotificationProperty{ ComparisonOperator: jsii.String("comparisonOperator"), NotificationType: jsii.String("notificationType"), Threshold: jsii.Number(123), // the properties below are optional ThresholdType: jsii.String("thresholdType"), }, Subscribers: []interface{}{ &SubscriberProperty{ Address: jsii.String("address"), SubscriptionType: jsii.String("subscriptionType"), }, }, }
type CfnBudget_SpendProperty ¶
type CfnBudget_SpendProperty struct { // The cost or usage amount that's associated with a budget forecast, actual spend, or budget threshold. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-spend.html#cfn-budgets-budget-spend-amount // Amount *float64 `field:"required" json:"amount" yaml:"amount"` // The unit of measurement that's used for the budget forecast, actual spend, or budget threshold. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-spend.html#cfn-budgets-budget-spend-unit // Unit *string `field:"required" json:"unit" yaml:"unit"` }
The amount of cost or usage that's measured for a budget.
*Cost example:* A `Spend` for `3 USD` of costs has the following parameters:
- An `Amount` of `3` - A `Unit` of `USD`
*Usage example:* A `Spend` for `3 GB` of S3 usage has the following parameters:
- An `Amount` of `3` - A `Unit` of `GB`.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" spendProperty := &SpendProperty{ Amount: jsii.Number(123), Unit: jsii.String("unit"), }
type CfnBudget_SubscriberProperty ¶
type CfnBudget_SubscriberProperty struct { // The address that AWS sends budget notifications to, either an SNS topic or an email. // // When you create a subscriber, the value of `Address` can't contain line breaks. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-subscriber.html#cfn-budgets-budget-subscriber-address // Address *string `field:"required" json:"address" yaml:"address"` // The type of notification that AWS sends to a subscriber. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-subscriber.html#cfn-budgets-budget-subscriber-subscriptiontype // SubscriptionType *string `field:"required" json:"subscriptionType" yaml:"subscriptionType"` }
The `Subscriber` property type specifies who to notify for a Billing and Cost Management budget notification.
The subscriber consists of a subscription type, and either an Amazon SNS topic or an email address.
For example, an email subscriber would have the following parameters:
- A `subscriptionType` of `EMAIL` - An `address` of `example@example.com`
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" subscriberProperty := &SubscriberProperty{ Address: jsii.String("address"), SubscriptionType: jsii.String("subscriptionType"), }
type CfnBudget_TimePeriodProperty ¶
type CfnBudget_TimePeriodProperty struct { // The end date for a budget. // // If you didn't specify an end date, AWS set your end date to `06/15/87 00:00 UTC` . The defaults are the same for the AWS Billing and Cost Management console and the API. // // After the end date, AWS deletes the budget and all the associated notifications and subscribers. You can change your end date with the `UpdateBudget` operation. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-timeperiod.html#cfn-budgets-budget-timeperiod-end // End *string `field:"optional" json:"end" yaml:"end"` // The start date for a budget. // // If you created your budget and didn't specify a start date, the start date defaults to the start of the chosen time period (MONTHLY, QUARTERLY, or ANNUALLY). For example, if you create your budget on January 24, 2019, choose `MONTHLY` , and don't set a start date, the start date defaults to `01/01/19 00:00 UTC` . The defaults are the same for the AWS Billing and Cost Management console and the API. // // You can change your start date with the `UpdateBudget` operation. // // Valid values depend on the value of `BudgetType` : // // - If `BudgetType` is `COST` or `USAGE` : Valid values are `MONTHLY` , `QUARTERLY` , and `ANNUALLY` . // - If `BudgetType` is `RI_UTILIZATION` or `RI_COVERAGE` : Valid values are `DAILY` , `MONTHLY` , `QUARTERLY` , and `ANNUALLY` . // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budget-timeperiod.html#cfn-budgets-budget-timeperiod-start // Start *string `field:"optional" json:"start" yaml:"start"` }
The period of time that is covered by a budget.
The period has a start date and an end date. The start date must come before the end date. There are no restrictions on the end date.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" timePeriodProperty := &TimePeriodProperty{ End: jsii.String("end"), Start: jsii.String("start"), }
type CfnBudgetsAction ¶
type CfnBudgetsAction interface { awscdk.CfnResource awscdk.IInspectable // The trigger threshold of the action. ActionThreshold() interface{} SetActionThreshold(val interface{}) // The type of action. ActionType() *string SetActionType(val *string) // This specifies if the action needs manual or automatic approval. ApprovalModel() *string SetApprovalModel(val *string) // A system-generated universally unique identifier (UUID) for the action. AttrActionId() *string // A string that represents the budget name. BudgetName() *string SetBudgetName(val *string) // Options for this resource, such as condition, update policy etc. CfnOptions() awscdk.ICfnResourceOptions CfnProperties() *map[string]interface{} // AWS resource type. CfnResourceType() *string // Returns: the stack trace of the point where this Resource was created from, sourced // from the +metadata+ entry typed +aws:cdk:logicalId+, and with the bottom-most // node +internal+ entries filtered. CreationStack() *[]*string // Specifies all of the type-specific parameters. Definition() interface{} SetDefinition(val interface{}) // The role passed for action execution and reversion. ExecutionRoleArn() *string SetExecutionRoleArn(val *string) // The logical ID for this CloudFormation stack element. // // The logical ID of the element // is calculated from the path of the resource node in the construct tree. // // To override this value, use `overrideLogicalId(newLogicalId)`. // // Returns: the logical ID as a stringified token. This value will only get // resolved during synthesis. LogicalId() *string // The tree node. Node() constructs.Node // The type of a notification. NotificationType() *string SetNotificationType(val *string) // Return a string that will be resolved to a CloudFormation `{ Ref }` for this element. // // If, by any chance, the intrinsic reference of a resource is not a string, you could // coerce it to an IResolvable through `Lazy.any({ produce: resource.ref })`. Ref() *string // The stack in which this element is defined. // // CfnElements must be defined within a stack scope (directly or indirectly). Stack() awscdk.Stack // A list of subscribers. Subscribers() interface{} SetSubscribers(val interface{}) // Deprecated. // Deprecated: use `updatedProperties` // // Return properties modified after initiation // // Resources that expose mutable properties should override this function to // collect and return the properties object for this resource. UpdatedProperites() *map[string]interface{} // Return properties modified after initiation. // // Resources that expose mutable properties should override this function to // collect and return the properties object for this resource. UpdatedProperties() *map[string]interface{} // Syntactic sugar for `addOverride(path, undefined)`. AddDeletionOverride(path *string) // Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned. // // This can be used for resources across stacks (or nested stack) boundaries // and the dependency will automatically be transferred to the relevant scope. AddDependency(target awscdk.CfnResource) // Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned. // Deprecated: use addDependency. AddDependsOn(target awscdk.CfnResource) // Add a value to the CloudFormation Resource Metadata. // See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html // // Note that this is a different set of metadata from CDK node metadata; this // metadata ends up in the stack template under the resource, whereas CDK // node metadata ends up in the Cloud Assembly. // AddMetadata(key *string, value interface{}) // Adds an override to the synthesized CloudFormation resource. // // To add a // property override, either use `addPropertyOverride` or prefix `path` with // "Properties." (i.e. `Properties.TopicName`). // // If the override is nested, separate each nested level using a dot (.) in the path parameter. // If there is an array as part of the nesting, specify the index in the path. // // To include a literal `.` in the property name, prefix with a `\`. In most // programming languages you will need to write this as `"\\."` because the // `\` itself will need to be escaped. // // For example, // “`typescript // cfnResource.addOverride('Properties.GlobalSecondaryIndexes.0.Projection.NonKeyAttributes', ['myattribute']); // cfnResource.addOverride('Properties.GlobalSecondaryIndexes.1.ProjectionType', 'INCLUDE'); // “` // would add the overrides // “`json // "Properties": { // "GlobalSecondaryIndexes": [ // { // "Projection": { // "NonKeyAttributes": [ "myattribute" ] // ... // } // ... // }, // { // "ProjectionType": "INCLUDE" // ... // }, // ] // ... // } // “` // // The `value` argument to `addOverride` will not be processed or translated // in any way. Pass raw JSON values in here with the correct capitalization // for CloudFormation. If you pass CDK classes or structs, they will be // rendered with lowercased key names, and CloudFormation will reject the // template. AddOverride(path *string, value interface{}) // Adds an override that deletes the value of a property from the resource definition. AddPropertyDeletionOverride(propertyPath *string) // Adds an override to a resource property. // // Syntactic sugar for `addOverride("Properties.<...>", value)`. AddPropertyOverride(propertyPath *string, value interface{}) // Sets the deletion policy of the resource based on the removal policy specified. // // The Removal Policy controls what happens to this resource when it stops // being managed by CloudFormation, either because you've removed it from the // CDK application or because you've made a change that requires the resource // to be replaced. // // The resource can be deleted (`RemovalPolicy.DESTROY`), or left in your AWS // account for data recovery and cleanup later (`RemovalPolicy.RETAIN`). In some // cases, a snapshot can be taken of the resource prior to deletion // (`RemovalPolicy.SNAPSHOT`). A list of resources that support this policy // can be found in the following link:. // See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-attribute-deletionpolicy.html#aws-attribute-deletionpolicy-options // ApplyRemovalPolicy(policy awscdk.RemovalPolicy, options *awscdk.RemovalPolicyOptions) // Returns a token for an runtime attribute of this resource. // // Ideally, use generated attribute accessors (e.g. `resource.arn`), but this can be used for future compatibility // in case there is no generated attribute. GetAtt(attributeName *string, typeHint awscdk.ResolutionTypeHint) awscdk.Reference // Retrieve a value value from the CloudFormation Resource Metadata. // See: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/metadata-section-structure.html // // Note that this is a different set of metadata from CDK node metadata; this // metadata ends up in the stack template under the resource, whereas CDK // node metadata ends up in the Cloud Assembly. // GetMetadata(key *string) interface{} // Examines the CloudFormation resource and discloses attributes. Inspect(inspector awscdk.TreeInspector) // Retrieves an array of resources this resource depends on. // // This assembles dependencies on resources across stacks (including nested stacks) // automatically. ObtainDependencies() *[]interface{} // Get a shallow copy of dependencies between this resource and other resources in the same stack. ObtainResourceDependencies() *[]awscdk.CfnResource // Overrides the auto-generated logical ID with a specific ID. OverrideLogicalId(newLogicalId *string) // Indicates that this resource no longer depends on another resource. // // This can be used for resources across stacks (including nested stacks) // and the dependency will automatically be removed from the relevant scope. RemoveDependency(target awscdk.CfnResource) RenderProperties(props *map[string]interface{}) *map[string]interface{} // Replaces one dependency with another. ReplaceDependency(target awscdk.CfnResource, newTarget awscdk.CfnResource) // Can be overridden by subclasses to determine if this resource will be rendered into the cloudformation template. // // Returns: `true` if the resource should be included or `false` is the resource // should be omitted. ShouldSynthesize() *bool // Returns a string representation of this construct. // // Returns: a string representation of this resource. ToString() *string ValidateProperties(_properties interface{}) }
The `AWS::Budgets::BudgetsAction` resource enables you to take predefined actions that are initiated when a budget threshold has been exceeded.
For more information, see [Managing Your Costs with Budgets](https://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/budgets-managing-costs.html) in the *AWS Billing and Cost Management User Guide* .
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" cfnBudgetsAction := awscdk.Aws_budgets.NewCfnBudgetsAction(this, jsii.String("MyCfnBudgetsAction"), &CfnBudgetsActionProps{ ActionThreshold: &ActionThresholdProperty{ Type: jsii.String("type"), Value: jsii.Number(123), }, ActionType: jsii.String("actionType"), BudgetName: jsii.String("budgetName"), Definition: &DefinitionProperty{ IamActionDefinition: &IamActionDefinitionProperty{ PolicyArn: jsii.String("policyArn"), // the properties below are optional Groups: []*string{ jsii.String("groups"), }, Roles: []*string{ jsii.String("roles"), }, Users: []*string{ jsii.String("users"), }, }, ScpActionDefinition: &ScpActionDefinitionProperty{ PolicyId: jsii.String("policyId"), TargetIds: []*string{ jsii.String("targetIds"), }, }, SsmActionDefinition: &SsmActionDefinitionProperty{ InstanceIds: []*string{ jsii.String("instanceIds"), }, Region: jsii.String("region"), Subtype: jsii.String("subtype"), }, }, ExecutionRoleArn: jsii.String("executionRoleArn"), NotificationType: jsii.String("notificationType"), Subscribers: []interface{}{ &SubscriberProperty{ Address: jsii.String("address"), Type: jsii.String("type"), }, }, // the properties below are optional ApprovalModel: jsii.String("approvalModel"), })
func NewCfnBudgetsAction ¶
func NewCfnBudgetsAction(scope constructs.Construct, id *string, props *CfnBudgetsActionProps) CfnBudgetsAction
type CfnBudgetsActionProps ¶
type CfnBudgetsActionProps struct { // The trigger threshold of the action. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budgetsaction.html#cfn-budgets-budgetsaction-actionthreshold // ActionThreshold interface{} `field:"required" json:"actionThreshold" yaml:"actionThreshold"` // The type of action. // // This defines the type of tasks that can be carried out by this action. This field also determines the format for definition. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budgetsaction.html#cfn-budgets-budgetsaction-actiontype // ActionType *string `field:"required" json:"actionType" yaml:"actionType"` // A string that represents the budget name. // // ":" and "\" characters aren't allowed. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budgetsaction.html#cfn-budgets-budgetsaction-budgetname // BudgetName *string `field:"required" json:"budgetName" yaml:"budgetName"` // Specifies all of the type-specific parameters. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budgetsaction.html#cfn-budgets-budgetsaction-definition // Definition interface{} `field:"required" json:"definition" yaml:"definition"` // The role passed for action execution and reversion. // // Roles and actions must be in the same account. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budgetsaction.html#cfn-budgets-budgetsaction-executionrolearn // ExecutionRoleArn *string `field:"required" json:"executionRoleArn" yaml:"executionRoleArn"` // The type of a notification. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budgetsaction.html#cfn-budgets-budgetsaction-notificationtype // NotificationType *string `field:"required" json:"notificationType" yaml:"notificationType"` // A list of subscribers. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budgetsaction.html#cfn-budgets-budgetsaction-subscribers // Subscribers interface{} `field:"required" json:"subscribers" yaml:"subscribers"` // This specifies if the action needs manual or automatic approval. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-budgets-budgetsaction.html#cfn-budgets-budgetsaction-approvalmodel // ApprovalModel *string `field:"optional" json:"approvalModel" yaml:"approvalModel"` }
Properties for defining a `CfnBudgetsAction`.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" cfnBudgetsActionProps := &CfnBudgetsActionProps{ ActionThreshold: &ActionThresholdProperty{ Type: jsii.String("type"), Value: jsii.Number(123), }, ActionType: jsii.String("actionType"), BudgetName: jsii.String("budgetName"), Definition: &DefinitionProperty{ IamActionDefinition: &IamActionDefinitionProperty{ PolicyArn: jsii.String("policyArn"), // the properties below are optional Groups: []*string{ jsii.String("groups"), }, Roles: []*string{ jsii.String("roles"), }, Users: []*string{ jsii.String("users"), }, }, ScpActionDefinition: &ScpActionDefinitionProperty{ PolicyId: jsii.String("policyId"), TargetIds: []*string{ jsii.String("targetIds"), }, }, SsmActionDefinition: &SsmActionDefinitionProperty{ InstanceIds: []*string{ jsii.String("instanceIds"), }, Region: jsii.String("region"), Subtype: jsii.String("subtype"), }, }, ExecutionRoleArn: jsii.String("executionRoleArn"), NotificationType: jsii.String("notificationType"), Subscribers: []interface{}{ &SubscriberProperty{ Address: jsii.String("address"), Type: jsii.String("type"), }, }, // the properties below are optional ApprovalModel: jsii.String("approvalModel"), }
type CfnBudgetsAction_ActionThresholdProperty ¶
type CfnBudgetsAction_ActionThresholdProperty struct { // The type of threshold for a notification. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-actionthreshold.html#cfn-budgets-budgetsaction-actionthreshold-type // Type *string `field:"required" json:"type" yaml:"type"` // The threshold of a notification. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-actionthreshold.html#cfn-budgets-budgetsaction-actionthreshold-value // Value *float64 `field:"required" json:"value" yaml:"value"` }
The trigger threshold of the action.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" actionThresholdProperty := &ActionThresholdProperty{ Type: jsii.String("type"), Value: jsii.Number(123), }
type CfnBudgetsAction_DefinitionProperty ¶
type CfnBudgetsAction_DefinitionProperty struct { // The AWS Identity and Access Management ( IAM ) action definition details. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-definition.html#cfn-budgets-budgetsaction-definition-iamactiondefinition // IamActionDefinition interface{} `field:"optional" json:"iamActionDefinition" yaml:"iamActionDefinition"` // The service control policies (SCP) action definition details. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-definition.html#cfn-budgets-budgetsaction-definition-scpactiondefinition // ScpActionDefinition interface{} `field:"optional" json:"scpActionDefinition" yaml:"scpActionDefinition"` // The Amazon EC2 Systems Manager ( SSM ) action definition details. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-definition.html#cfn-budgets-budgetsaction-definition-ssmactiondefinition // SsmActionDefinition interface{} `field:"optional" json:"ssmActionDefinition" yaml:"ssmActionDefinition"` }
The definition is where you specify all of the type-specific parameters.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" definitionProperty := &DefinitionProperty{ IamActionDefinition: &IamActionDefinitionProperty{ PolicyArn: jsii.String("policyArn"), // the properties below are optional Groups: []*string{ jsii.String("groups"), }, Roles: []*string{ jsii.String("roles"), }, Users: []*string{ jsii.String("users"), }, }, ScpActionDefinition: &ScpActionDefinitionProperty{ PolicyId: jsii.String("policyId"), TargetIds: []*string{ jsii.String("targetIds"), }, }, SsmActionDefinition: &SsmActionDefinitionProperty{ InstanceIds: []*string{ jsii.String("instanceIds"), }, Region: jsii.String("region"), Subtype: jsii.String("subtype"), }, }
type CfnBudgetsAction_IamActionDefinitionProperty ¶
type CfnBudgetsAction_IamActionDefinitionProperty struct { // The Amazon Resource Name (ARN) of the policy to be attached. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-iamactiondefinition.html#cfn-budgets-budgetsaction-iamactiondefinition-policyarn // PolicyArn *string `field:"required" json:"policyArn" yaml:"policyArn"` // A list of groups to be attached. // // There must be at least one group. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-iamactiondefinition.html#cfn-budgets-budgetsaction-iamactiondefinition-groups // Groups *[]*string `field:"optional" json:"groups" yaml:"groups"` // A list of roles to be attached. // // There must be at least one role. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-iamactiondefinition.html#cfn-budgets-budgetsaction-iamactiondefinition-roles // Roles *[]*string `field:"optional" json:"roles" yaml:"roles"` // A list of users to be attached. // // There must be at least one user. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-iamactiondefinition.html#cfn-budgets-budgetsaction-iamactiondefinition-users // Users *[]*string `field:"optional" json:"users" yaml:"users"` }
The AWS Identity and Access Management ( IAM ) action definition details.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" iamActionDefinitionProperty := &IamActionDefinitionProperty{ PolicyArn: jsii.String("policyArn"), // the properties below are optional Groups: []*string{ jsii.String("groups"), }, Roles: []*string{ jsii.String("roles"), }, Users: []*string{ jsii.String("users"), }, }
type CfnBudgetsAction_ScpActionDefinitionProperty ¶
type CfnBudgetsAction_ScpActionDefinitionProperty struct { // The policy ID attached. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-scpactiondefinition.html#cfn-budgets-budgetsaction-scpactiondefinition-policyid // PolicyId *string `field:"required" json:"policyId" yaml:"policyId"` // A list of target IDs. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-scpactiondefinition.html#cfn-budgets-budgetsaction-scpactiondefinition-targetids // TargetIds *[]*string `field:"required" json:"targetIds" yaml:"targetIds"` }
The service control policies (SCP) action definition details.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" scpActionDefinitionProperty := &ScpActionDefinitionProperty{ PolicyId: jsii.String("policyId"), TargetIds: []*string{ jsii.String("targetIds"), }, }
type CfnBudgetsAction_SsmActionDefinitionProperty ¶
type CfnBudgetsAction_SsmActionDefinitionProperty struct { // The EC2 and RDS instance IDs. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-ssmactiondefinition.html#cfn-budgets-budgetsaction-ssmactiondefinition-instanceids // InstanceIds *[]*string `field:"required" json:"instanceIds" yaml:"instanceIds"` // The Region to run the ( SSM ) document. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-ssmactiondefinition.html#cfn-budgets-budgetsaction-ssmactiondefinition-region // Region *string `field:"required" json:"region" yaml:"region"` // The action subType. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-ssmactiondefinition.html#cfn-budgets-budgetsaction-ssmactiondefinition-subtype // Subtype *string `field:"required" json:"subtype" yaml:"subtype"` }
The Amazon EC2 Systems Manager ( SSM ) action definition details.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" ssmActionDefinitionProperty := &SsmActionDefinitionProperty{ InstanceIds: []*string{ jsii.String("instanceIds"), }, Region: jsii.String("region"), Subtype: jsii.String("subtype"), }
type CfnBudgetsAction_SubscriberProperty ¶
type CfnBudgetsAction_SubscriberProperty struct { // The address that AWS sends budget notifications to, either an SNS topic or an email. // // When you create a subscriber, the value of `Address` can't contain line breaks. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-subscriber.html#cfn-budgets-budgetsaction-subscriber-address // Address *string `field:"required" json:"address" yaml:"address"` // The type of notification that AWS sends to a subscriber. // See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-budgets-budgetsaction-subscriber.html#cfn-budgets-budgetsaction-subscriber-type // Type *string `field:"required" json:"type" yaml:"type"` }
The subscriber to a budget notification.
The subscriber consists of a subscription type and either an Amazon SNS topic or an email address.
For example, an email subscriber has the following parameters:
- A `subscriptionType` of `EMAIL` - An `address` of `example@example.com`
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import "github.com/aws/aws-cdk-go/awscdk" subscriberProperty := &SubscriberProperty{ Address: jsii.String("address"), Type: jsii.String("type"), }
Source Files ¶
- CfnBudget.go
- CfnBudgetProps.go
- CfnBudget_AutoAdjustDataProperty.go
- CfnBudget_BudgetDataProperty.go
- CfnBudget_CostTypesProperty.go
- CfnBudget_HistoricalOptionsProperty.go
- CfnBudget_NotificationProperty.go
- CfnBudget_NotificationWithSubscribersProperty.go
- CfnBudget_SpendProperty.go
- CfnBudget_SubscriberProperty.go
- CfnBudget_TimePeriodProperty.go
- CfnBudget__checks.go
- CfnBudgetsAction.go
- CfnBudgetsActionProps.go
- CfnBudgetsAction_ActionThresholdProperty.go
- CfnBudgetsAction_DefinitionProperty.go
- CfnBudgetsAction_IamActionDefinitionProperty.go
- CfnBudgetsAction_ScpActionDefinitionProperty.go
- CfnBudgetsAction_SsmActionDefinitionProperty.go
- CfnBudgetsAction_SubscriberProperty.go
- CfnBudgetsAction__checks.go
- main.go