import * as core from "@terrascript/core"; export interface DefaultRouteSettingsArgs extends core.SchemaArgs { dataTraceEnabled?: boolean | core.BooleanOut; detailedMetricsEnabled?: boolean | core.BooleanOut; loggingLevel?: string | core.StringOut; throttlingBurstLimit?: number | core.NumberOut; throttlingRateLimit?: number | core.NumberOut; } export class DefaultRouteSettings extends core.Schema { @core.attr(Boolean) public dataTraceEnabled?: boolean | core.BooleanOut; @core.attr(Boolean) public detailedMetricsEnabled?: boolean | core.BooleanOut; @core.attr(String, { computed: true }) public loggingLevel?: string | core.StringOut; @core.attr(Number) public throttlingBurstLimit?: number | core.NumberOut; @core.attr(Number) public throttlingRateLimit?: number | core.NumberOut; } export interface AccessLogSettingsArgs extends core.SchemaArgs { destinationArn: string | core.StringOut; format: string | core.StringOut; } export class AccessLogSettings extends core.Schema { @core.attr(String) public destinationArn!: string | core.StringOut; @core.attr(String) public format!: string | core.StringOut; } export interface RouteSettingsArgs extends core.SchemaArgs { dataTraceEnabled?: boolean | core.BooleanOut; detailedMetricsEnabled?: boolean | core.BooleanOut; loggingLevel?: string | core.StringOut; routeKey: string | core.StringOut; throttlingBurstLimit?: number | core.NumberOut; throttlingRateLimit?: number | core.NumberOut; } export class RouteSettings extends core.Schema { @core.attr(Boolean) public dataTraceEnabled?: boolean | core.BooleanOut; @core.attr(Boolean) public detailedMetricsEnabled?: boolean | core.BooleanOut; @core.attr(String, { computed: true }) public loggingLevel?: string | core.StringOut; @core.attr(String) public routeKey!: string | core.StringOut; @core.attr(Number) public throttlingBurstLimit?: number | core.NumberOut; @core.attr(Number) public throttlingRateLimit?: number | core.NumberOut; } export interface StageArgs extends core.ResourceArgs { /** * (Optional) Settings for logging access in this stage. */ accessLogSettings?: AccessLogSettings; /** * (Required) The API identifier. */ apiId: string | core.StringOut; /** * (Optional) Whether updates to an API automatically trigger a new deployment. Defaults to `false`. Ap * plicable for HTTP APIs. */ autoDeploy?: boolean | core.BooleanOut; /** * (Optional) The identifier of a client certificate for the stage. Use the [`aws_api_gateway_client_ce * rtificate`](/docs/providers/aws/r/api_gateway_client_certificate.html) resource to configure a clien * t certificate. */ clientCertificateId?: string | core.StringOut; /** * (Optional) The default route settings for the stage. */ defaultRouteSettings?: DefaultRouteSettings; /** * (Optional) The deployment identifier of the stage. Use the [`aws_apigatewayv2_deployment`](/docs/pro * viders/aws/r/apigatewayv2_deployment.html) resource to configure a deployment. */ deploymentId?: string | core.StringOut; /** * (Optional) The description for the stage. Must be less than or equal to 1024 characters in length. */ description?: string | core.StringOut; /** * (Required) The name of the stage. Must be between 1 and 128 characters in length. */ name: string | core.StringOut; /** * (Optional) Route settings for the stage. */ routeSettings?: core.Array | core.ArrayOut; /** * (Optional) A map that defines the stage variables for the stage. */ stageVariables?: core.Map | core.MapOut; /** * (Optional) A map of tags to assign to the stage. If configured with a provider [`default_tags` confi * guration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-confi * guration-block) present, tags with matching keys will overwrite those defined at the provider-level. */ tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ tagsAll?: core.Map | core.MapOut; } export class Stage extends core.Resource { /** * (Optional) Settings for logging access in this stage. */ @core.attr(AccessLogSettings) public accessLogSettings?: AccessLogSettings; /** * (Required) The API identifier. */ @core.attr(String) public apiId!: string | core.StringOut; /** * The ARN of the stage. */ @core.attr(String, { computed: true }) public arn!: string | core.StringOut; /** * (Optional) Whether updates to an API automatically trigger a new deployment. Defaults to `false`. Ap * plicable for HTTP APIs. */ @core.attr(Boolean) public autoDeploy?: boolean | core.BooleanOut; /** * (Optional) The identifier of a client certificate for the stage. Use the [`aws_api_gateway_client_ce * rtificate`](/docs/providers/aws/r/api_gateway_client_certificate.html) resource to configure a clien * t certificate. */ @core.attr(String) public clientCertificateId?: string | core.StringOut; /** * (Optional) The default route settings for the stage. */ @core.attr(DefaultRouteSettings) public defaultRouteSettings?: DefaultRouteSettings; /** * (Optional) The deployment identifier of the stage. Use the [`aws_apigatewayv2_deployment`](/docs/pro * viders/aws/r/apigatewayv2_deployment.html) resource to configure a deployment. */ @core.attr(String, { computed: true }) public deploymentId?: string | core.StringOut; /** * (Optional) The description for the stage. Must be less than or equal to 1024 characters in length. */ @core.attr(String) public description?: string | core.StringOut; /** * The ARN prefix to be used in an [`aws_lambda_permission`](/docs/providers/aws/r/lambda_permission.ht * ml)'s `source_arn` attribute. */ @core.attr(String, { computed: true }) public executionArn!: string | core.StringOut; /** * The stage identifier. */ @core.attr(String, { computed: true }) public id!: string | core.StringOut; /** * The URL to invoke the API pointing to the stage, */ @core.attr(String, { computed: true }) public invokeUrl!: string | core.StringOut; /** * (Required) The name of the stage. Must be between 1 and 128 characters in length. */ @core.attr(String) public name!: string | core.StringOut; /** * (Optional) Route settings for the stage. */ @core.attr(RouteSettings, { kind: "array" }) public routeSettings?: | core.Array | core.ArrayOut; /** * (Optional) A map that defines the stage variables for the stage. */ @core.attr(String, { kind: "map" }) public stageVariables?: | core.Map | core.MapOut; /** * (Optional) A map of tags to assign to the stage. If configured with a provider [`default_tags` confi * guration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-confi * guration-block) present, tags with matching keys will overwrite those defined at the provider-level. */ @core.attr(String, { kind: "map" }) public tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ @core.attr(String, { computed: true, kind: "map" }) public tagsAll?: core.Map | core.MapOut; constructor(name: string, args?: StageArgs) { super(name, "aws_apigatewayv2_stage", args); } public override getNamespace(): string { return "aws_apigatewayv2"; } }