Show / Hide Table of Contents

Class ApiMappingOptions

Options for creating an api mapping.

Inheritance
object
ApiMappingOptions
Implements
IApiMappingOptions
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.APIGateway
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class ApiMappingOptions : IApiMappingOptions
Syntax (vb)
Public Class ApiMappingOptions Implements IApiMappingOptions
Remarks

ExampleMetadata: infused

Examples
var acmCertificateForExampleCom;
            RestApi restApi;
            RestApi secondRestApi;


            var domain = new DomainName(this, "custom-domain", new DomainNameProps {
                DomainName = "example.com",
                Certificate = acmCertificateForExampleCom,
                Mapping = restApi
            });

            domain.AddApiMapping(secondRestApi.DeploymentStage, new ApiMappingOptions {
                BasePath = "orders/v2/api"
            });

Synopsis

Constructors

ApiMappingOptions()

Options for creating an api mapping.

Properties

BasePath

The api path name that callers of the API must provide in the URL after the domain name (e.g. example.com/base-path). If you specify this property, it can't be an empty string.

Constructors

ApiMappingOptions()

Options for creating an api mapping.

public ApiMappingOptions()
Remarks

ExampleMetadata: infused

Examples
var acmCertificateForExampleCom;
            RestApi restApi;
            RestApi secondRestApi;


            var domain = new DomainName(this, "custom-domain", new DomainNameProps {
                DomainName = "example.com",
                Certificate = acmCertificateForExampleCom,
                Mapping = restApi
            });

            domain.AddApiMapping(secondRestApi.DeploymentStage, new ApiMappingOptions {
                BasePath = "orders/v2/api"
            });

Properties

BasePath

The api path name that callers of the API must provide in the URL after the domain name (e.g. example.com/base-path). If you specify this property, it can't be an empty string.

public string? BasePath { get; set; }
Property Value

string

Remarks

If this is undefined, a mapping will be added for the empty path. Any request that does not match a mapping will get sent to the API that has been mapped to the empty path.

Default: - map requests from the domain root (e.g. example.com).

Implements

IApiMappingOptions
Back to top Generated by DocFX