import * as cdk from "aws-cdk-lib"; import * as apigw from "aws-cdk-lib/aws-apigatewayv2"; import * as route53 from "aws-cdk-lib/aws-route53"; import * as constructs from "constructs"; export type ApiGatewayDnsProps = { /** * Only the subdomain prefix, which should be the name of the service. * Example: Subdomain `product` would give the end result of an API-GW with * `product.platform.example.no`. */ subdomain: string; /** * Hosted Zone for the external facing domain. * This is where routes will be created, to redirect consumers to the API-GW. * For example a HZ for `platform.example.no`. */ hostedZone: route53.IHostedZone; /** * The Time To Live (TTL) for the public DNS A record that will expose the API-GW. * This is how long DNS servers will cache the record. * * A long TTL (hours) is beneficial to DNS servers, but makes developers (you) wait longer when * doing changes. * * @default 5 minutes */ ttl?: cdk.Duration; }; /** * Creates a custom domain for the API-Gateway, a Route53 record and an HTTPS cert. * * @author Kristian Rekstad */ export declare class ApiGatewayDomain extends constructs.Construct { /** The Fully Qualified Domain Name (FQDN) like `product.platform.example.no`. */ readonly fullDomainName: string; readonly apiGwDomainName: apigw.DomainName; constructor(scope: constructs.Construct, id: string, props: ApiGatewayDnsProps); }