import * as core from "@terrascript/core"; export interface ConditionArgs extends core.SchemaArgs { key: string | core.StringOut; type: string | core.StringOut; value: string | core.StringOut; } export class Condition extends core.Schema { @core.attr(String) public key!: string | core.StringOut; @core.attr(String) public type!: string | core.StringOut; @core.attr(String) public value!: string | core.StringOut; } export interface CloudwatchEventPermissionArgs extends core.ResourceArgs { /** * (Optional) The action that you are enabling the other account to perform. Defaults to `events:PutEve * nts`. */ action?: string | core.StringOut; /** * (Optional) Configuration block to limit the event bus permissions you are granting to only accounts * that fulfill the condition. Specified below. */ condition?: Condition; /** * (Optional) The event bus to set the permissions on. If you omit this, the permissions are set on the * default` event bus. */ eventBusName?: string | core.StringOut; /** * (Required) The 12-digit AWS account ID that you are permitting to put events to your default event b * us. Specify `*` to permit any account to put events to your default event bus, optionally limited by * condition`. */ principal: string | core.StringOut; /** * (Required) An identifier string for the external account that you are granting permissions to. */ statementId: string | core.StringOut; } export class CloudwatchEventPermission extends core.Resource { /** * (Optional) The action that you are enabling the other account to perform. Defaults to `events:PutEve * nts`. */ @core.attr(String) public action?: string | core.StringOut; /** * (Optional) Configuration block to limit the event bus permissions you are granting to only accounts * that fulfill the condition. Specified below. */ @core.attr(Condition) public condition?: Condition; /** * (Optional) The event bus to set the permissions on. If you omit this, the permissions are set on the * default` event bus. */ @core.attr(String) public eventBusName?: string | core.StringOut; /** * The statement ID of the EventBridge permission. */ @core.attr(String, { computed: true }) public id!: string | core.StringOut; /** * (Required) The 12-digit AWS account ID that you are permitting to put events to your default event b * us. Specify `*` to permit any account to put events to your default event bus, optionally limited by * condition`. */ @core.attr(String) public principal!: string | core.StringOut; /** * (Required) An identifier string for the external account that you are granting permissions to. */ @core.attr(String) public statementId!: string | core.StringOut; constructor(name: string, args?: CloudwatchEventPermissionArgs) { super(name, "aws_cloudwatch_event_permission", args); } public override getNamespace(): string { return "aws_eventbridge"; } }