1 | import { Resource } from '@aws-cdk/core';
|
2 | import { Construct } from 'constructs';
|
3 | import { IDomainName } from './domain-name';
|
4 | import { IRestApi } from './restapi';
|
5 | import { Stage } from './stage';
|
6 | export interface BasePathMappingOptions {
|
7 | /**
|
8 | * The base path name that callers of the API must provide in the URL after
|
9 | * the domain name (e.g. `example.com/base-path`). If you specify this
|
10 | * property, it can't be an empty string.
|
11 | *
|
12 | * @default - map requests from the domain root (e.g. `example.com`). If this
|
13 | * is undefined, no additional mappings will be allowed on this domain name.
|
14 | */
|
15 | readonly basePath?: string;
|
16 | /**
|
17 | * The Deployment stage of API
|
18 | * [disable-awslint:ref-via-interface]
|
19 | * @default - map to deploymentStage of restApi otherwise stage needs to pass in URL
|
20 | */
|
21 | readonly stage?: Stage;
|
22 | }
|
23 | export interface BasePathMappingProps extends BasePathMappingOptions {
|
24 | /**
|
25 | * The DomainName to associate with this base path mapping.
|
26 | */
|
27 | readonly domainName: IDomainName;
|
28 | /**
|
29 | * The RestApi resource to target.
|
30 | */
|
31 | readonly restApi: IRestApi;
|
32 | }
|
33 | /**
|
34 | * This resource creates a base path that clients who call your API must use in
|
35 | * the invocation URL.
|
36 | *
|
37 | * Unless you're importing a domain with `DomainName.fromDomainNameAttributes()`,
|
38 | * you can use `DomainName.addBasePathMapping()` to define mappings.
|
39 | */
|
40 | export declare class BasePathMapping extends Resource {
|
41 | constructor(scope: Construct, id: string, props: BasePathMappingProps);
|
42 | }
|