domain_names
Creates, updates, deletes, gets or lists a domain_names resource.
Overview
| Name | domain_names |
| Type | Resource |
| Id | aws.apigatewayv2.domain_names |
Fields
The following fields are returned by SELECT queries:
- get_domain_name
- get_domain_names
| Name | Datatype | Description |
|---|---|---|
api_mapping_selection_expression | string | An expression used to extract information at runtime. See Selection Expressions for more information. |
domain_name | string | A string with a length between [1-512]. |
domain_name_arn | string | Represents an Amazon Resource Name (ARN). |
domain_name_configurations | array | The domain name configurations. |
mutual_tls_authentication | object | The mutual TLS authentication configuration for a custom domain name. |
routing_mode | string | The routing mode. (API_MAPPING_ONLY, ROUTING_RULE_ONLY, ROUTING_RULE_THEN_API_MAPPING) |
tags | object | The collection of tags associated with a domain name. |
| Name | Datatype | Description |
|---|---|---|
api_mapping_selection_expression | string | An expression used to extract information at runtime. See Selection Expressions for more information. |
domain_name | string | A string with a length between [1-512]. |
domain_name_arn | string | Represents an Amazon Resource Name (ARN). |
domain_name_configurations | array | The domain name configurations. |
mutual_tls_authentication | object | The mutual TLS authentication configuration for a custom domain name. |
routing_mode | string | The routing mode. (API_MAPPING_ONLY, ROUTING_RULE_ONLY, ROUTING_RULE_THEN_API_MAPPING) |
tags | object | The collection of tags associated with a domain name. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_domain_name | select | domain_name, region | Gets a domain name. | |
get_domain_names | select | region | maxResults, nextToken | Gets the domain names for an AWS account. |
create_domain_name | insert | region, DomainName | Creates a domain name. | |
update_domain_name | update | domain_name, region | Updates a domain name. | |
delete_domain_name | delete | domain_name, region | Deletes a domain name. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
domain_name | string | The domain name. |
region | string | AWS region (default: us-east-1) |
maxResults | string | The maximum number of elements to be returned for this resource. |
nextToken | string | The next page of elements from this collection. Not valid for the last element of the collection. |
SELECT examples
- get_domain_name
- get_domain_names
Gets a domain name.
SELECT
api_mapping_selection_expression,
domain_name,
domain_name_arn,
domain_name_configurations,
mutual_tls_authentication,
routing_mode,
tags
FROM aws.apigatewayv2.domain_names
WHERE domain_name = '{{ domain_name }}' -- required
AND region = '{{ region }}' -- required
;
Gets the domain names for an AWS account.
SELECT
api_mapping_selection_expression,
domain_name,
domain_name_arn,
domain_name_configurations,
mutual_tls_authentication,
routing_mode,
tags
FROM aws.apigatewayv2.domain_names
WHERE region = '{{ region }}' -- required
AND maxResults = '{{ maxResults }}'
AND nextToken = '{{ nextToken }}'
;
INSERT examples
- create_domain_name
- Manifest
Creates a domain name.
INSERT INTO aws.apigatewayv2.domain_names (
DomainName,
DomainNameConfigurations,
MutualTlsAuthentication,
RoutingMode,
Tags,
region
)
SELECT
'{{ DomainName }}' /* required */,
'{{ DomainNameConfigurations }}',
'{{ MutualTlsAuthentication }}',
'{{ RoutingMode }}',
'{{ Tags }}',
'{{ region }}'
RETURNING
api_mapping_selection_expression,
domain_name,
domain_name_arn,
domain_name_configurations,
mutual_tls_authentication,
routing_mode,
tags
;
# Description fields are for documentation purposes
- name: domain_names
props:
- name: region
value: "{{ region }}"
description: Required parameter for the domain_names resource.
- name: DomainName
value: "{{ DomainName }}"
description: |
A string with a length between [1-512].
- name: DomainNameConfigurations
description: |
The domain name configurations.
value:
- ApiGatewayDomainName: "{{ ApiGatewayDomainName }}"
CertificateArn: "{{ CertificateArn }}"
CertificateName: "{{ CertificateName }}"
CertificateUploadDate: "{{ CertificateUploadDate }}"
DomainNameStatus: "{{ DomainNameStatus }}"
DomainNameStatusMessage: "{{ DomainNameStatusMessage }}"
EndpointType: "{{ EndpointType }}"
HostedZoneId: "{{ HostedZoneId }}"
IpAddressType: "{{ IpAddressType }}"
SecurityPolicy: "{{ SecurityPolicy }}"
OwnershipVerificationCertificateArn: "{{ OwnershipVerificationCertificateArn }}"
- name: MutualTlsAuthentication
value:
TruststoreUri: "{{ TruststoreUri }}"
TruststoreVersion: "{{ TruststoreVersion }}"
- name: RoutingMode
value: "{{ RoutingMode }}"
valid_values: ['API_MAPPING_ONLY', 'ROUTING_RULE_ONLY', 'ROUTING_RULE_THEN_API_MAPPING']
- name: Tags
value: "{{ Tags }}"
description: |
Represents a collection of tags associated with the resource.
UPDATE examples
- update_domain_name
Updates a domain name.
UPDATE aws.apigatewayv2.domain_names
SET
DomainNameConfigurations = '{{ DomainNameConfigurations }}',
MutualTlsAuthentication = '{{ MutualTlsAuthentication }}',
RoutingMode = '{{ RoutingMode }}'
WHERE
domain_name = '{{ domain_name }}' --required
AND region = '{{ region }}' --required
RETURNING
api_mapping_selection_expression,
domain_name,
domain_name_arn,
domain_name_configurations,
mutual_tls_authentication,
routing_mode,
tags;
DELETE examples
- delete_domain_name
Deletes a domain name.
DELETE FROM aws.apigatewayv2.domain_names
WHERE domain_name = '{{ domain_name }}' --required
AND region = '{{ region }}' --required
;