import * as core from "@terrascript/core"; 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 CanarySettingsArgs extends core.SchemaArgs { percentTraffic?: number | core.NumberOut; stageVariableOverrides?: | core.Map | core.MapOut; useStageCache?: boolean | core.BooleanOut; } export class CanarySettings extends core.Schema { @core.attr(Number) public percentTraffic?: number | core.NumberOut; @core.attr(String, { kind: "map" }) public stageVariableOverrides?: | core.Map | core.MapOut; @core.attr(Boolean) public useStageCache?: boolean | core.BooleanOut; } export interface StageArgs extends core.ResourceArgs { /** * (Optional) Enables access logs for the API stage. See [Access Log Settings](#access-log-settings) be * low. */ accessLogSettings?: AccessLogSettings; /** * (Optional) Specifies whether a cache cluster is enabled for the stage */ cacheClusterEnabled?: boolean | core.BooleanOut; /** * (Optional) The size of the cache cluster for the stage, if enabled. Allowed values include `0.5`, `1 * .6`, `6.1`, `13.5`, `28.4`, `58.2`, `118` and `237`. */ cacheClusterSize?: string | core.StringOut; /** * (Optional) Configuration settings of a canary deployment. See [Canary Settings](#canary-settings) be * low. */ canarySettings?: CanarySettings; /** * (Optional) The identifier of a client certificate for the stage. */ clientCertificateId?: string | core.StringOut; /** * (Required) The ID of the deployment that the stage points to */ deploymentId: string | core.StringOut; /** * (Optional) The description of the stage. */ description?: string | core.StringOut; /** * (Optional) The version of the associated API documentation */ documentationVersion?: string | core.StringOut; /** * (Required) The ID of the associated REST API */ restApiId: string | core.StringOut; /** * (Required) The name of the stage */ stageName: string | core.StringOut; /** * (Optional) A map of tags to assign to the resource. If configured with a provider [`default_tags` co * nfiguration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-co * nfiguration-block) present, tags with matching keys will overwrite those defined at the provider-lev * el. */ 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; /** * (Optional) A map that defines the stage variables */ variables?: core.Map | core.MapOut; /** * (Optional) Whether active tracing with X-ray is enabled. Defaults to `false`. */ xrayTracingEnabled?: boolean | core.BooleanOut; } export class Stage extends core.Resource { /** * (Optional) Enables access logs for the API stage. See [Access Log Settings](#access-log-settings) be * low. */ @core.attr(AccessLogSettings) public accessLogSettings?: AccessLogSettings; /** * Amazon Resource Name (ARN) */ @core.attr(String, { computed: true }) public arn!: string | core.StringOut; /** * (Optional) Specifies whether a cache cluster is enabled for the stage */ @core.attr(Boolean) public cacheClusterEnabled?: boolean | core.BooleanOut; /** * (Optional) The size of the cache cluster for the stage, if enabled. Allowed values include `0.5`, `1 * .6`, `6.1`, `13.5`, `28.4`, `58.2`, `118` and `237`. */ @core.attr(String) public cacheClusterSize?: string | core.StringOut; /** * (Optional) Configuration settings of a canary deployment. See [Canary Settings](#canary-settings) be * low. */ @core.attr(CanarySettings) public canarySettings?: CanarySettings; /** * (Optional) The identifier of a client certificate for the stage. */ @core.attr(String) public clientCertificateId?: string | core.StringOut; /** * (Required) The ID of the deployment that the stage points to */ @core.attr(String) public deploymentId!: string | core.StringOut; /** * (Optional) The description of the stage. */ @core.attr(String) public description?: string | core.StringOut; /** * (Optional) The version of the associated API documentation */ @core.attr(String) public documentationVersion?: string | core.StringOut; /** * The execution ARN to be used in [`lambda_permission`](/docs/providers/aws/r/lambda_permission.html)' * s `source_arn` */ @core.attr(String, { computed: true }) public executionArn!: string | core.StringOut; /** * The ID of the stage */ @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 ID of the associated REST API */ @core.attr(String) public restApiId!: string | core.StringOut; /** * (Required) The name of the stage */ @core.attr(String) public stageName!: string | core.StringOut; /** * (Optional) A map of tags to assign to the resource. If configured with a provider [`default_tags` co * nfiguration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-co * nfiguration-block) present, tags with matching keys will overwrite those defined at the provider-lev * el. */ @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; /** * (Optional) A map that defines the stage variables */ @core.attr(String, { kind: "map" }) public variables?: core.Map | core.MapOut; /** * The ARN of the WebAcl associated with the Stage. */ @core.attr(String, { computed: true }) public webAclArn!: string | core.StringOut; /** * (Optional) Whether active tracing with X-ray is enabled. Defaults to `false`. */ @core.attr(Boolean) public xrayTracingEnabled?: boolean | core.BooleanOut; constructor(name: string, args?: StageArgs) { super(name, "aws_api_gateway_stage", args); } public override getNamespace(): string { return "aws_api_gateway"; } }