Table of Contents
Route53.
Client
¶A low-level client representing Amazon Route 53:
import boto3
client = boto3.client('route53')
These are the available methods:
associate_vpc_with_hosted_zone()
can_paginate()
change_resource_record_sets()
change_tags_for_resource()
create_health_check()
create_hosted_zone()
create_reusable_delegation_set()
delete_health_check()
delete_hosted_zone()
delete_reusable_delegation_set()
disassociate_vpc_from_hosted_zone()
generate_presigned_url()
get_change()
get_checker_ip_ranges()
get_geo_location()
get_health_check()
get_health_check_count()
get_health_check_last_failure_reason()
get_health_check_status()
get_hosted_zone()
get_hosted_zone_count()
get_paginator()
get_reusable_delegation_set()
get_waiter()
list_geo_locations()
list_health_checks()
list_hosted_zones()
list_hosted_zones_by_name()
list_resource_record_sets()
list_reusable_delegation_sets()
list_tags_for_resource()
list_tags_for_resources()
update_health_check()
update_hosted_zone_comment()
associate_vpc_with_hosted_zone
(**kwargs)¶This action associates a VPC with an hosted zone.
To associate a VPC with an hosted zone, send a POST
request to the 2013-04-01/hostedzone/*hosted zone ID* /associatevpc
resource. The request body must include an XML document with a AssociateVPCWithHostedZoneRequest
element. The response returns the AssociateVPCWithHostedZoneResponse
element that contains ChangeInfo
for you to track the progress of the AssociateVPCWithHostedZoneRequest
you made. See GetChange
operation for how to track the progress of your change.
Request Syntax
response = client.associate_vpc_with_hosted_zone(
HostedZoneId='string',
VPC={
'VPCRegion': 'us-east-1'|'us-west-1'|'us-west-2'|'eu-west-1'|'eu-central-1'|'ap-southeast-1'|'ap-southeast-2'|'ap-northeast-1'|'sa-east-1'|'cn-north-1',
'VPCId': 'string'
},
Comment='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'ChangeInfo': {
'Id': 'string',
'Status': 'PENDING'|'INSYNC',
'SubmittedAt': datetime(2015, 1, 1),
'Comment': 'string'
}
}
Response Structure
|
can_paginate
(operation_name)¶Check if an operation can be paginated.
Parameters: | operation_name (string) -- The operation name. This is the same name
as the method name on the client. For example, if the
method name is create_foo , and you'd normally invoke the
operation as client.create_foo(**kwargs) , if the
create_foo operation can be paginated, you can use the
call client.get_paginator("create_foo") . |
---|---|
Returns: | True if the operation can be paginated,
False otherwise. |
change_resource_record_sets
(**kwargs)¶Use this action to create or change your authoritative DNS information. To use this action, send a POST
request to the 2013-04-01/hostedzone/*hosted Zone ID* /rrset
resource. The request body must include an XML document with a ChangeResourceRecordSetsRequest
element.
Changes are a list of change items and are considered transactional. For more information on transactional changes, also known as change batches, see Creating, Changing, and Deleting Resource Record Sets Using the Route 53 API in the Amazon Route 53 Developer Guide .
Warning
Due to the nature of transactional changes, you cannot delete the same resource record set more than once in a single change batch. If you attempt to delete the same change batch more than once, Route 53 returns an InvalidChangeBatch
error.
In response to a ChangeResourceRecordSets
request, your DNS data is changed on all Route 53 DNS servers. Initially, the status of a change is PENDING
. This means the change has not yet propagated to all the authoritative Route 53 DNS servers. When the change is propagated to all hosts, the change returns a status of INSYNC
.
Note the following limitations on a ChangeResourceRecordSets
request:
The sum of the number of characters (including spaces) in all Value
elements in a request cannot exceed 32,000 characters.
Request Syntax
response = client.change_resource_record_sets(
HostedZoneId='string',
ChangeBatch={
'Comment': 'string',
'Changes': [
{
'Action': 'CREATE'|'DELETE'|'UPSERT',
'ResourceRecordSet': {
'Name': 'string',
'Type': 'SOA'|'A'|'TXT'|'NS'|'CNAME'|'MX'|'PTR'|'SRV'|'SPF'|'AAAA',
'SetIdentifier': 'string',
'Weight': 123,
'Region': 'us-east-1'|'us-west-1'|'us-west-2'|'eu-west-1'|'eu-central-1'|'ap-southeast-1'|'ap-southeast-2'|'ap-northeast-1'|'sa-east-1'|'cn-north-1',
'GeoLocation': {
'ContinentCode': 'string',
'CountryCode': 'string',
'SubdivisionCode': 'string'
},
'Failover': 'PRIMARY'|'SECONDARY',
'TTL': 123,
'ResourceRecords': [
{
'Value': 'string'
},
],
'AliasTarget': {
'HostedZoneId': 'string',
'DNSName': 'string',
'EvaluateTargetHealth': True|False
},
'HealthCheckId': 'string'
}
},
]
}
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'ChangeInfo': {
'Id': 'string',
'Status': 'PENDING'|'INSYNC',
'SubmittedAt': datetime(2015, 1, 1),
'Comment': 'string'
}
}
Response Structure
|
Request Syntax
response = client.change_tags_for_resource(
ResourceType='healthcheck'|'hostedzone',
ResourceId='string',
AddTags=[
{
'Key': 'string',
'Value': 'string'
},
],
RemoveTagKeys=[
'string',
]
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {}
Response Structure
|
create_health_check
(**kwargs)¶This action creates a new health check.
To create a new health check, send a POST
request to the 2013-04-01/healthcheck
resource. The request body must include an XML document with a CreateHealthCheckRequest
element. The response returns the CreateHealthCheckResponse
element that contains metadata about the health check.
Request Syntax
response = client.create_health_check(
CallerReference='string',
HealthCheckConfig={
'IPAddress': 'string',
'Port': 123,
'Type': 'HTTP'|'HTTPS'|'HTTP_STR_MATCH'|'HTTPS_STR_MATCH'|'TCP',
'ResourcePath': 'string',
'FullyQualifiedDomainName': 'string',
'SearchString': 'string',
'RequestInterval': 123,
'FailureThreshold': 123
}
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'HealthCheck': {
'Id': 'string',
'CallerReference': 'string',
'HealthCheckConfig': {
'IPAddress': 'string',
'Port': 123,
'Type': 'HTTP'|'HTTPS'|'HTTP_STR_MATCH'|'HTTPS_STR_MATCH'|'TCP',
'ResourcePath': 'string',
'FullyQualifiedDomainName': 'string',
'SearchString': 'string',
'RequestInterval': 123,
'FailureThreshold': 123
},
'HealthCheckVersion': 123
},
'Location': 'string'
}
Response Structure
|
create_hosted_zone
(**kwargs)¶This action creates a new hosted zone.
To create a new hosted zone, send a POST
request to the 2013-04-01/hostedzone
resource. The request body must include an XML document with a CreateHostedZoneRequest
element. The response returns the CreateHostedZoneResponse
element that contains metadata about the hosted zone.
Route 53 automatically creates a default SOA record and four NS records for the zone. The NS records in the hosted zone are the name servers you give your registrar to delegate your domain to. For more information about SOA and NS records, see NS and SOA Records that Route 53 Creates for a Hosted Zone in the Amazon Route 53 Developer Guide .
When you create a zone, its initial status is PENDING
. This means that it is not yet available on all DNS servers. The status of the zone changes to INSYNC
when the NS and SOA records are available on all Route 53 DNS servers.
When trying to create a hosted zone using a reusable delegation set, you could specify an optional DelegationSetId, and Route53 would assign those 4 NS records for the zone, instead of alloting a new one.
Request Syntax
response = client.create_hosted_zone(
Name='string',
VPC={
'VPCRegion': 'us-east-1'|'us-west-1'|'us-west-2'|'eu-west-1'|'eu-central-1'|'ap-southeast-1'|'ap-southeast-2'|'ap-northeast-1'|'sa-east-1'|'cn-north-1',
'VPCId': 'string'
},
CallerReference='string',
HostedZoneConfig={
'Comment': 'string',
'PrivateZone': True|False
},
DelegationSetId='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'HostedZone': {
'Id': 'string',
'Name': 'string',
'CallerReference': 'string',
'Config': {
'Comment': 'string',
'PrivateZone': True|False
},
'ResourceRecordSetCount': 123
},
'ChangeInfo': {
'Id': 'string',
'Status': 'PENDING'|'INSYNC',
'SubmittedAt': datetime(2015, 1, 1),
'Comment': 'string'
},
'DelegationSet': {
'Id': 'string',
'CallerReference': 'string',
'NameServers': [
'string',
]
},
'VPC': {
'VPCRegion': 'us-east-1'|'us-west-1'|'us-west-2'|'eu-west-1'|'eu-central-1'|'ap-southeast-1'|'ap-southeast-2'|'ap-northeast-1'|'sa-east-1'|'cn-north-1',
'VPCId': 'string'
},
'Location': 'string'
}
Response Structure
|
create_reusable_delegation_set
(**kwargs)¶This action creates a reusable delegationSet.
To create a new reusable delegationSet, send a POST
request to the 2013-04-01/delegationset
resource. The request body must include an XML document with a CreateReusableDelegationSetRequest
element. The response returns the CreateReusableDelegationSetResponse
element that contains metadata about the delegationSet.
If the optional parameter HostedZoneId is specified, it marks the delegationSet associated with that particular hosted zone as reusable.
Request Syntax
response = client.create_reusable_delegation_set(
CallerReference='string',
HostedZoneId='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'DelegationSet': {
'Id': 'string',
'CallerReference': 'string',
'NameServers': [
'string',
]
},
'Location': 'string'
}
Response Structure
|
delete_health_check
(**kwargs)¶This action deletes a health check. To delete a health check, send a DELETE
request to the 2013-04-01/healthcheck/*health check ID*
resource.
Warning
You can delete a health check only if there are no resource record sets associated with this health check. If resource record sets are associated with this health check, you must disassociate them before you can delete your health check. If you try to delete a health check that is associated with resource record sets, Route 53 will deny your request with a HealthCheckInUse
error. For information about disassociating the records from your health check, see ChangeResourceRecordSets .
Request Syntax
response = client.delete_health_check(
HealthCheckId='string'
)
Parameters: | HealthCheckId (string) -- [REQUIRED] The ID of the health check to delete. |
---|---|
Return type: | dict |
Returns: | Response Syntax{}
Response Structure
|
delete_hosted_zone
(**kwargs)¶This action deletes a hosted zone. To delete a hosted zone, send a DELETE
request to the 2013-04-01/hostedzone/*hosted zone ID*
resource.
For more information about deleting a hosted zone, see Deleting a Hosted Zone in the Amazon Route 53 Developer Guide .
Warning
You can delete a hosted zone only if there are no resource record sets other than the default SOA record and NS resource record sets. If your hosted zone contains other resource record sets, you must delete them before you can delete your hosted zone. If you try to delete a hosted zone that contains other resource record sets, Route 53 will deny your request with a HostedZoneNotEmpty
error. For information about deleting records from your hosted zone, see ChangeResourceRecordSets .
Request Syntax
response = client.delete_hosted_zone(
Id='string'
)
Parameters: | Id (string) -- [REQUIRED] The ID of the hosted zone you want to delete. |
---|---|
Return type: | dict |
Returns: | Response Syntax{
'ChangeInfo': {
'Id': 'string',
'Status': 'PENDING'|'INSYNC',
'SubmittedAt': datetime(2015, 1, 1),
'Comment': 'string'
}
}
Response Structure
|
delete_reusable_delegation_set
(**kwargs)¶This action deletes a reusable delegation set. To delete a reusable delegation set, send a DELETE
request to the 2013-04-01/delegationset/*delegation set ID*
resource.
Warning
You can delete a reusable delegation set only if there are no associated hosted zones. If your reusable delegation set contains associated hosted zones, you must delete them before you can delete your reusable delegation set. If you try to delete a reusable delegation set that contains associated hosted zones, Route 53 will deny your request with a DelegationSetInUse
error.
Request Syntax
response = client.delete_reusable_delegation_set(
Id='string'
)
Parameters: | Id (string) -- [REQUIRED] The ID of the reusable delegation set you want to delete. |
---|---|
Return type: | dict |
Returns: | Response Syntax{}
Response Structure
|
disassociate_vpc_from_hosted_zone
(**kwargs)¶This action disassociates a VPC from an hosted zone.
To disassociate a VPC to a hosted zone, send a POST
request to the 2013-04-01/hostedzone/*hosted zone ID* /disassociatevpc
resource. The request body must include an XML document with a DisassociateVPCFromHostedZoneRequest
element. The response returns the DisassociateVPCFromHostedZoneResponse
element that contains ChangeInfo
for you to track the progress of the DisassociateVPCFromHostedZoneRequest
you made. See GetChange
operation for how to track the progress of your change.
Request Syntax
response = client.disassociate_vpc_from_hosted_zone(
HostedZoneId='string',
VPC={
'VPCRegion': 'us-east-1'|'us-west-1'|'us-west-2'|'eu-west-1'|'eu-central-1'|'ap-southeast-1'|'ap-southeast-2'|'ap-northeast-1'|'sa-east-1'|'cn-north-1',
'VPCId': 'string'
},
Comment='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'ChangeInfo': {
'Id': 'string',
'Status': 'PENDING'|'INSYNC',
'SubmittedAt': datetime(2015, 1, 1),
'Comment': 'string'
}
}
Response Structure
|
generate_presigned_url
(ClientMethod, Params=None, ExpiresIn=3600, HttpMethod=None)¶Generate a presigned url given a client, its method, and arguments
Parameters: |
|
---|---|
Returns: | The presigned url |
get_change
(**kwargs)¶This action returns the current status of a change batch request. The status is one of the following values:
PENDING
indicates that the changes in this request have not replicated to all Route 53 DNS servers. This is the initial status of all change batch requests.INSYNC
indicates that the changes have replicated to all Amazon Route 53 DNS servers.Request Syntax
response = client.get_change(
Id='string'
)
Parameters: | Id (string) -- [REQUIRED] The ID of the change batch request. The value that you specify here is the value that |
---|---|
Return type: | dict |
Returns: | Response Syntax{
'ChangeInfo': {
'Id': 'string',
'Status': 'PENDING'|'INSYNC',
'SubmittedAt': datetime(2015, 1, 1),
'Comment': 'string'
}
}
Response Structure
|
get_checker_ip_ranges
()¶To retrieve a list of the IP ranges used by Amazon Route 53 health checkers to check the health of your resources, send a GET
request to the 2013-04-01/checkeripranges
resource. You can use these IP addresses to configure router and firewall rules to allow health checkers to check the health of your resources.
Request Syntax
response = client.get_checker_ip_ranges()
Return type: | dict |
---|---|
Returns: | Response Syntax{
'CheckerIpRanges': [
'string',
]
}
Response Structure
|
get_geo_location
(**kwargs)¶To retrieve a single geo location, send a GET
request to the 2013-04-01/geolocation
resource with one of these options: continentcode | countrycode | countrycode and subdivisioncode.
Request Syntax
response = client.get_geo_location(
ContinentCode='string',
CountryCode='string',
SubdivisionCode='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'GeoLocationDetails': {
'ContinentCode': 'string',
'ContinentName': 'string',
'CountryCode': 'string',
'CountryName': 'string',
'SubdivisionCode': 'string',
'SubdivisionName': 'string'
}
}
Response Structure
|
get_health_check
(**kwargs)¶To retrieve the health check, send a GET
request to the 2013-04-01/healthcheck/*health check ID*
resource.
Request Syntax
response = client.get_health_check(
HealthCheckId='string'
)
Parameters: | HealthCheckId (string) -- [REQUIRED] The ID of the health check to retrieve. |
---|---|
Return type: | dict |
Returns: | Response Syntax{
'HealthCheck': {
'Id': 'string',
'CallerReference': 'string',
'HealthCheckConfig': {
'IPAddress': 'string',
'Port': 123,
'Type': 'HTTP'|'HTTPS'|'HTTP_STR_MATCH'|'HTTPS_STR_MATCH'|'TCP',
'ResourcePath': 'string',
'FullyQualifiedDomainName': 'string',
'SearchString': 'string',
'RequestInterval': 123,
'FailureThreshold': 123
},
'HealthCheckVersion': 123
}
}
Response Structure
|
get_health_check_count
()¶To retrieve a count of all your health checks, send a GET
request to the 2013-04-01/healthcheckcount
resource.
Request Syntax
response = client.get_health_check_count()
Return type: | dict |
---|---|
Returns: | Response Syntax{
'HealthCheckCount': 123
}
Response Structure
|
get_health_check_last_failure_reason
(**kwargs)¶If you want to learn why a health check is currently failing or why it failed most recently (if at all), you can get the failure reason for the most recent failure. Send a GET
request to the 2013-04-01/healthcheck/*health check ID* /lastfailurereason
resource.
Request Syntax
response = client.get_health_check_last_failure_reason(
HealthCheckId='string'
)
Parameters: | HealthCheckId (string) -- [REQUIRED] The ID of the health check for which you want to retrieve the reason for the most recent failure. |
---|---|
Return type: | dict |
Returns: | Response Syntax{
'HealthCheckObservations': [
{
'IPAddress': 'string',
'StatusReport': {
'Status': 'string',
'CheckedTime': datetime(2015, 1, 1)
}
},
]
}
Response Structure
|
get_health_check_status
(**kwargs)¶To retrieve the health check status, send a GET
request to the 2013-04-01/healthcheck/*health check ID* /status
resource. You can use this call to get a health check's current status.
Request Syntax
response = client.get_health_check_status(
HealthCheckId='string'
)
Parameters: | HealthCheckId (string) -- [REQUIRED] The ID of the health check for which you want to retrieve the most recent status. |
---|---|
Return type: | dict |
Returns: | Response Syntax{
'HealthCheckObservations': [
{
'IPAddress': 'string',
'StatusReport': {
'Status': 'string',
'CheckedTime': datetime(2015, 1, 1)
}
},
]
}
Response Structure
|
get_hosted_zone
(**kwargs)¶To retrieve the delegation set for a hosted zone, send a GET
request to the 2013-04-01/hostedzone/*hosted zone ID*
resource. The delegation set is the four Route 53 name servers that were assigned to the hosted zone when you created it.
Request Syntax
response = client.get_hosted_zone(
Id='string'
)
Parameters: | Id (string) -- [REQUIRED] The ID of the hosted zone for which you want to get a list of the name servers in the delegation set. |
---|---|
Return type: | dict |
Returns: | Response Syntax{
'HostedZone': {
'Id': 'string',
'Name': 'string',
'CallerReference': 'string',
'Config': {
'Comment': 'string',
'PrivateZone': True|False
},
'ResourceRecordSetCount': 123
},
'DelegationSet': {
'Id': 'string',
'CallerReference': 'string',
'NameServers': [
'string',
]
},
'VPCs': [
{
'VPCRegion': 'us-east-1'|'us-west-1'|'us-west-2'|'eu-west-1'|'eu-central-1'|'ap-southeast-1'|'ap-southeast-2'|'ap-northeast-1'|'sa-east-1'|'cn-north-1',
'VPCId': 'string'
},
]
}
Response Structure
|
get_hosted_zone_count
()¶To retrieve a count of all your hosted zones, send a GET
request to the 2013-04-01/hostedzonecount
resource.
Request Syntax
response = client.get_hosted_zone_count()
Return type: | dict |
---|---|
Returns: | Response Syntax{
'HostedZoneCount': 123
}
Response Structure
|
get_paginator
(operation_name)¶Create a paginator for an operation.
Parameters: | operation_name (string) -- The operation name. This is the same name
as the method name on the client. For example, if the
method name is create_foo , and you'd normally invoke the
operation as client.create_foo(**kwargs) , if the
create_foo operation can be paginated, you can use the
call client.get_paginator("create_foo") . |
---|---|
Raises OperationNotPageableError: | |
Raised if the operation is not
pageable. You can use the client.can_paginate method to
check if an operation is pageable. |
|
Return type: | L{botocore.paginate.Paginator} |
Returns: | A paginator object. |
get_reusable_delegation_set
(**kwargs)¶To retrieve the reusable delegation set, send a GET
request to the 2013-04-01/delegationset/*delegation set ID*
resource.
Request Syntax
response = client.get_reusable_delegation_set(
Id='string'
)
Parameters: | Id (string) -- [REQUIRED] The ID of the reusable delegation set for which you want to get a list of the name server. |
---|---|
Return type: | dict |
Returns: | Response Syntax{
'DelegationSet': {
'Id': 'string',
'CallerReference': 'string',
'NameServers': [
'string',
]
}
}
Response Structure
|
get_waiter
(waiter_name)¶list_geo_locations
(**kwargs)¶To retrieve a list of supported geo locations, send a GET
request to the 2013-04-01/geolocations
resource. The response to this request includes a GeoLocationDetailsList
element with zero, one, or multiple GeoLocationDetails
child elements. The list is sorted by country code, and then subdivision code, followed by continents at the end of the list.
By default, the list of geo locations is displayed on a single page. You can control the length of the page that is displayed by using the MaxItems
parameter. If the list is truncated, IsTruncated
will be set to true and a combination of NextContinentCode, NextCountryCode, NextSubdivisionCode
will be populated. You can pass these as parameters to StartContinentCode, StartCountryCode, StartSubdivisionCode
to control the geo location that the list begins with.
Request Syntax
response = client.list_geo_locations(
StartContinentCode='string',
StartCountryCode='string',
StartSubdivisionCode='string',
MaxItems='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'GeoLocationDetailsList': [
{
'ContinentCode': 'string',
'ContinentName': 'string',
'CountryCode': 'string',
'CountryName': 'string',
'SubdivisionCode': 'string',
'SubdivisionName': 'string'
},
],
'IsTruncated': True|False,
'NextContinentCode': 'string',
'NextCountryCode': 'string',
'NextSubdivisionCode': 'string',
'MaxItems': 'string'
}
Response Structure
|
list_health_checks
(**kwargs)¶To retrieve a list of your health checks, send a GET
request to the 2013-04-01/healthcheck
resource. The response to this request includes a HealthChecks
element with zero, one, or multiple HealthCheck
child elements. By default, the list of health checks is displayed on a single page. You can control the length of the page that is displayed by using the MaxItems
parameter. You can use the Marker
parameter to control the health check that the list begins with.
Note
Amazon Route 53 returns a maximum of 100 items. If you set MaxItems to a value greater than 100, Amazon Route 53 returns only the first 100.
Request Syntax
response = client.list_health_checks(
Marker='string',
MaxItems='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'HealthChecks': [
{
'Id': 'string',
'CallerReference': 'string',
'HealthCheckConfig': {
'IPAddress': 'string',
'Port': 123,
'Type': 'HTTP'|'HTTPS'|'HTTP_STR_MATCH'|'HTTPS_STR_MATCH'|'TCP',
'ResourcePath': 'string',
'FullyQualifiedDomainName': 'string',
'SearchString': 'string',
'RequestInterval': 123,
'FailureThreshold': 123
},
'HealthCheckVersion': 123
},
],
'Marker': 'string',
'IsTruncated': True|False,
'NextMarker': 'string',
'MaxItems': 'string'
}
Response Structure
|
list_hosted_zones
(**kwargs)¶To retrieve a list of your hosted zones, send a GET
request to the 2013-04-01/hostedzone
resource. The response to this request includes a HostedZones
element with zero, one, or multiple HostedZone
child elements. By default, the list of hosted zones is displayed on a single page. You can control the length of the page that is displayed by using the MaxItems
parameter. You can use the Marker
parameter to control the hosted zone that the list begins with.
Note
Amazon Route 53 returns a maximum of 100 items. If you set MaxItems to a value greater than 100, Amazon Route 53 returns only the first 100.
Request Syntax
response = client.list_hosted_zones(
Marker='string',
MaxItems='string',
DelegationSetId='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'HostedZones': [
{
'Id': 'string',
'Name': 'string',
'CallerReference': 'string',
'Config': {
'Comment': 'string',
'PrivateZone': True|False
},
'ResourceRecordSetCount': 123
},
],
'Marker': 'string',
'IsTruncated': True|False,
'NextMarker': 'string',
'MaxItems': 'string'
}
Response Structure
|
list_hosted_zones_by_name
(**kwargs)¶To retrieve a list of your hosted zones in lexicographic order, send a GET
request to the 2013-04-01/hostedzonesbyname
resource. The response to this request includes a HostedZones
element with zero or more HostedZone
child elements lexicographically ordered by DNS name. By default, the list of hosted zones is displayed on a single page. You can control the length of the page that is displayed by using the MaxItems
parameter. You can use the DNSName
and HostedZoneId
parameters to control the hosted zone that the list begins with.
Note
Amazon Route 53 returns a maximum of 100 items. If you set MaxItems to a value greater than 100, Amazon Route 53 returns only the first 100.
Request Syntax
response = client.list_hosted_zones_by_name(
DNSName='string',
HostedZoneId='string',
MaxItems='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'HostedZones': [
{
'Id': 'string',
'Name': 'string',
'CallerReference': 'string',
'Config': {
'Comment': 'string',
'PrivateZone': True|False
},
'ResourceRecordSetCount': 123
},
],
'DNSName': 'string',
'HostedZoneId': 'string',
'IsTruncated': True|False,
'NextDNSName': 'string',
'NextHostedZoneId': 'string',
'MaxItems': 'string'
}
Response Structure
|
list_resource_record_sets
(**kwargs)¶Imagine all the resource record sets in a zone listed out in front of you. Imagine them sorted lexicographically first by DNS name (with the labels reversed, like "com.amazon.www" for example), and secondarily, lexicographically by record type. This operation retrieves at most MaxItems resource record sets from this list, in order, starting at a position specified by the Name and Type arguments:
Use ListResourceRecordSets to retrieve a single known record set by specifying the record set's name and type, and setting MaxItems = 1
To retrieve all the records in a HostedZone, first pause any processes making calls to ChangeResourceRecordSets. Initially call ListResourceRecordSets without a Name and Type to get the first page of record sets. For subsequent calls, set Name and Type to the NextName and NextType values returned by the previous response.
In the presence of concurrent ChangeResourceRecordSets calls, there is no consistency of results across calls to ListResourceRecordSets. The only way to get a consistent multi-page snapshot of all RRSETs in a zone is to stop making changes while pagination is in progress.
However, the results from ListResourceRecordSets are consistent within a page. If MakeChange calls are taking place concurrently, the result of each one will either be completely visible in your results or not at all. You will not see partial changes, or changes that do not ultimately succeed. (This follows from the fact that MakeChange is atomic)
The results from ListResourceRecordSets are strongly consistent with ChangeResourceRecordSets. To be precise, if a single process makes a call to ChangeResourceRecordSets and receives a successful response, the effects of that change will be visible in a subsequent call to ListResourceRecordSets by that process.
Request Syntax
response = client.list_resource_record_sets(
HostedZoneId='string',
StartRecordName='string',
StartRecordType='SOA'|'A'|'TXT'|'NS'|'CNAME'|'MX'|'PTR'|'SRV'|'SPF'|'AAAA',
StartRecordIdentifier='string',
MaxItems='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'ResourceRecordSets': [
{
'Name': 'string',
'Type': 'SOA'|'A'|'TXT'|'NS'|'CNAME'|'MX'|'PTR'|'SRV'|'SPF'|'AAAA',
'SetIdentifier': 'string',
'Weight': 123,
'Region': 'us-east-1'|'us-west-1'|'us-west-2'|'eu-west-1'|'eu-central-1'|'ap-southeast-1'|'ap-southeast-2'|'ap-northeast-1'|'sa-east-1'|'cn-north-1',
'GeoLocation': {
'ContinentCode': 'string',
'CountryCode': 'string',
'SubdivisionCode': 'string'
},
'Failover': 'PRIMARY'|'SECONDARY',
'TTL': 123,
'ResourceRecords': [
{
'Value': 'string'
},
],
'AliasTarget': {
'HostedZoneId': 'string',
'DNSName': 'string',
'EvaluateTargetHealth': True|False
},
'HealthCheckId': 'string'
},
],
'IsTruncated': True|False,
'NextRecordName': 'string',
'NextRecordType': 'SOA'|'A'|'TXT'|'NS'|'CNAME'|'MX'|'PTR'|'SRV'|'SPF'|'AAAA',
'NextRecordIdentifier': 'string',
'MaxItems': 'string'
}
Response Structure
|
list_reusable_delegation_sets
(**kwargs)¶To retrieve a list of your reusable delegation sets, send a GET
request to the 2013-04-01/delegationset
resource. The response to this request includes a DelegationSets
element with zero, one, or multiple DelegationSet
child elements. By default, the list of delegation sets is displayed on a single page. You can control the length of the page that is displayed by using the MaxItems
parameter. You can use the Marker
parameter to control the delegation set that the list begins with.
Note
Amazon Route 53 returns a maximum of 100 items. If you set MaxItems to a value greater than 100, Amazon Route 53 returns only the first 100.
Request Syntax
response = client.list_reusable_delegation_sets(
Marker='string',
MaxItems='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'DelegationSets': [
{
'Id': 'string',
'CallerReference': 'string',
'NameServers': [
'string',
]
},
],
'Marker': 'string',
'IsTruncated': True|False,
'NextMarker': 'string',
'MaxItems': 'string'
}
Response Structure
|
Request Syntax
response = client.list_tags_for_resource(
ResourceType='healthcheck'|'hostedzone',
ResourceId='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'ResourceTagSet': {
'ResourceType': 'healthcheck'|'hostedzone',
'ResourceId': 'string',
'Tags': [
{
'Key': 'string',
'Value': 'string'
},
]
}
}
Response Structure
|
Request Syntax
response = client.list_tags_for_resources(
ResourceType='healthcheck'|'hostedzone',
ResourceIds=[
'string',
]
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'ResourceTagSets': [
{
'ResourceType': 'healthcheck'|'hostedzone',
'ResourceId': 'string',
'Tags': [
{
'Key': 'string',
'Value': 'string'
},
]
},
]
}
Response Structure
|
update_health_check
(**kwargs)¶This action updates an existing health check.
To update a health check, send a POST
request to the 2013-04-01/healthcheck/*health check ID*
resource. The request body must include an XML document with an UpdateHealthCheckRequest
element. The response returns an UpdateHealthCheckResponse
element, which contains metadata about the health check.
Request Syntax
response = client.update_health_check(
HealthCheckId='string',
HealthCheckVersion=123,
IPAddress='string',
Port=123,
ResourcePath='string',
FullyQualifiedDomainName='string',
SearchString='string',
FailureThreshold=123
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'HealthCheck': {
'Id': 'string',
'CallerReference': 'string',
'HealthCheckConfig': {
'IPAddress': 'string',
'Port': 123,
'Type': 'HTTP'|'HTTPS'|'HTTP_STR_MATCH'|'HTTPS_STR_MATCH'|'TCP',
'ResourcePath': 'string',
'FullyQualifiedDomainName': 'string',
'SearchString': 'string',
'RequestInterval': 123,
'FailureThreshold': 123
},
'HealthCheckVersion': 123
}
}
Response Structure
|
update_hosted_zone_comment
(**kwargs)¶To update the hosted zone comment, send a POST
request to the 2013-04-01/hostedzone/*hosted zone ID*
resource. The request body must include an XML document with a UpdateHostedZoneCommentRequest
element. The response to this request includes the modified HostedZone
element.
Note
The comment can have a maximum length of 256 characters.
Request Syntax
response = client.update_hosted_zone_comment(
Id='string',
Comment='string'
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'HostedZone': {
'Id': 'string',
'Name': 'string',
'CallerReference': 'string',
'Config': {
'Comment': 'string',
'PrivateZone': True|False
},
'ResourceRecordSetCount': 123
}
}
Response Structure
|
The available paginators are:
Route53.Paginator.list_health_checks
Route53.Paginator.list_hosted_zones
Route53.Paginator.list_resource_record_sets
Route53.Paginator.
list_health_checks
¶paginator = client.get_paginator('list_health_checks')
paginate
(**kwargs)¶Creates an iterator that will paginate through responses from Route53.Client.list_health_checks()
.
Request Syntax
response_iterator = paginator.paginate(
PaginationConfig={
'MaxItems': 123,
'PageSize': 123,
'StartingToken': 'string'
}
)
Parameters: | PaginationConfig (dict) -- A dictionary that provides parameters to control pagination.
|
---|---|
Return type: | dict |
Returns: | Response Syntax{
'HealthChecks': [
{
'Id': 'string',
'CallerReference': 'string',
'HealthCheckConfig': {
'IPAddress': 'string',
'Port': 123,
'Type': 'HTTP'|'HTTPS'|'HTTP_STR_MATCH'|'HTTPS_STR_MATCH'|'TCP',
'ResourcePath': 'string',
'FullyQualifiedDomainName': 'string',
'SearchString': 'string',
'RequestInterval': 123,
'FailureThreshold': 123
},
'HealthCheckVersion': 123
},
],
'Marker': 'string',
'IsTruncated': True|False,
'MaxItems': 'string',
'NextToken': 'string'
}
Response Structure
|
Route53.Paginator.
list_hosted_zones
¶paginator = client.get_paginator('list_hosted_zones')
paginate
(**kwargs)¶Creates an iterator that will paginate through responses from Route53.Client.list_hosted_zones()
.
Request Syntax
response_iterator = paginator.paginate(
DelegationSetId='string',
PaginationConfig={
'MaxItems': 123,
'PageSize': 123,
'StartingToken': 'string'
}
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'HostedZones': [
{
'Id': 'string',
'Name': 'string',
'CallerReference': 'string',
'Config': {
'Comment': 'string',
'PrivateZone': True|False
},
'ResourceRecordSetCount': 123
},
],
'Marker': 'string',
'IsTruncated': True|False,
'MaxItems': 'string',
'NextToken': 'string'
}
Response Structure
|
Route53.Paginator.
list_resource_record_sets
¶paginator = client.get_paginator('list_resource_record_sets')
paginate
(**kwargs)¶Creates an iterator that will paginate through responses from Route53.Client.list_resource_record_sets()
.
Request Syntax
response_iterator = paginator.paginate(
HostedZoneId='string',
PaginationConfig={
'MaxItems': 123,
'PageSize': 123,
'StartingToken': 'string'
}
)
Parameters: |
|
---|---|
Return type: | dict |
Returns: | Response Syntax {
'ResourceRecordSets': [
{
'Name': 'string',
'Type': 'SOA'|'A'|'TXT'|'NS'|'CNAME'|'MX'|'PTR'|'SRV'|'SPF'|'AAAA',
'SetIdentifier': 'string',
'Weight': 123,
'Region': 'us-east-1'|'us-west-1'|'us-west-2'|'eu-west-1'|'eu-central-1'|'ap-southeast-1'|'ap-southeast-2'|'ap-northeast-1'|'sa-east-1'|'cn-north-1',
'GeoLocation': {
'ContinentCode': 'string',
'CountryCode': 'string',
'SubdivisionCode': 'string'
},
'Failover': 'PRIMARY'|'SECONDARY',
'TTL': 123,
'ResourceRecords': [
{
'Value': 'string'
},
],
'AliasTarget': {
'HostedZoneId': 'string',
'DNSName': 'string',
'EvaluateTargetHealth': True|False
},
'HealthCheckId': 'string'
},
],
'IsTruncated': True|False,
'MaxItems': 'string',
'NextToken': 'string'
}
Response Structure
|
The available waiters are:
Route53.Waiter.
resource_record_sets_changed
¶waiter = client.get_waiter('resource_record_sets_changed')
wait
(**kwargs)¶This polls Route53.Client.get_change()
every 30 seconds until a successful state is reached. An error is returned after 60 failed checks.
Request Syntax
waiter.wait(
Id='string'
)
Parameters: | Id (string) -- [REQUIRED] The ID of the change batch request. The value that you specify here is the value that |
---|---|
Returns: | None |