Skip to main content

domain_names

Creates, updates, deletes or gets a domain_name resource or lists domain_names in a region

Overview

Namedomain_names
TypeResource
DescriptionThe AWS::ApiGatewayV2::DomainName resource specifies a custom domain name for your API in Amazon API Gateway (API Gateway).
You can use a custom domain name to provide a URL that's more intuitive and easier to recall. For more information about using custom domain names, see [Set up Custom Domain Name for an API in API Gateway](https://docs.aws.amazon.com/apigateway/latest/developerguide/how-to-custom-domains.html) in the *API Gateway Developer Guide*.
Idaws.apigatewayv2.domain_names

Fields

NameDatatypeDescription
mutual_tls_authenticationobjectThe mutual TLS authentication configuration for a custom domain name.
regional_hosted_zone_idstring
regional_domain_namestring
domain_namestringThe custom domain name for your API in Amazon API Gateway. Uppercase letters are not supported.
domain_name_configurationsarrayThe domain name configurations.
tagsobjectThe collection of tags associated with a domain name.
regionstringAWS region.

Methods

NameAccessible byRequired Params
create_resourceINSERTDomainName, region
delete_resourceDELETEdata__Identifier, region
update_resourceUPDATEdata__Identifier, data__PatchDocument, region
list_resourcesSELECTregion
get_resourceSELECTdata__Identifier, region

SELECT examples

Gets all domain_names in a region.

SELECT
region,
mutual_tls_authentication,
regional_hosted_zone_id,
regional_domain_name,
domain_name,
domain_name_configurations,
tags
FROM aws.apigatewayv2.domain_names
WHERE region = 'us-east-1';

Gets all properties from an individual domain_name.

SELECT
region,
mutual_tls_authentication,
regional_hosted_zone_id,
regional_domain_name,
domain_name,
domain_name_configurations,
tags
FROM aws.apigatewayv2.domain_names
WHERE region = 'us-east-1' AND data__Identifier = '<DomainName>';

INSERT example

Use the following StackQL query and manifest file to create a new domain_name resource, using stack-deploy.

/*+ create */
INSERT INTO aws.apigatewayv2.domain_names (
DomainName,
region
)
SELECT
'{{ DomainName }}',
'{{ region }}';

DELETE example

/*+ delete */
DELETE FROM aws.apigatewayv2.domain_names
WHERE data__Identifier = '<DomainName>'
AND region = 'us-east-1';

Permissions

To operate on the domain_names resource, the following permissions are required:

Create

apigateway:POST,
apigateway:GET,
apigateway:PUT

Update

apigateway:PATCH,
apigateway:GET,
apigateway:PUT

Read

apigateway:GET

Delete

apigateway:GET,
apigateway:DELETE

List

apigateway:GET