Route53GlobalResolver / Client / create_access_token

create_access_token

Route53GlobalResolver.Client.create_access_token(**kwargs)

Creates an access token for a DNS view. Access tokens provide token-based authentication for DNS-over-HTTPS (DoH) and DNS-over-TLS (DoT) connections to the Route 53 Global Resolver.

See also: AWS API Documentation

Request Syntax

response = client.create_access_token(
    clientToken='string',
    dnsViewId='string',
    expiresAt=datetime(2015, 1, 1),
    name='string',
    tags={
        'string': 'string'
    }
)
Parameters:
  • clientToken (string) –

    A unique, case-sensitive identifier to ensure idempotency. This means that making the same request multiple times with the same clientToken has the same result every time.

    This field is autopopulated if not provided.

  • dnsViewId (string) –

    [REQUIRED]

    The ID of the DNS view to associate with this token.

  • expiresAt (datetime) – The date and time when the token expires. Tokens can have a minimum expiration of 30 days and maximum of 365 days from creation.

  • name (string) – A descriptive name for the access token.

  • tags (dict) –

    An array of user-defined keys and optional values. These tags can be used for categorization and organization.

    • (string) –

      • (string) –

Return type:

dict

Returns:

Response Syntax

{
    'id': 'string',
    'arn': 'string',
    'clientToken': 'string',
    'createdAt': datetime(2015, 1, 1),
    'dnsViewId': 'string',
    'expiresAt': datetime(2015, 1, 1),
    'name': 'string',
    'status': 'CREATING'|'OPERATIONAL'|'DELETING',
    'value': 'string'
}

Response Structure

  • (dict) –

    • id (string) –

      The unique identifier for the access token.

    • arn (string) –

      The Amazon Resource Name (ARN) of the access token.

    • clientToken (string) –

      The unique string that identifies the request and ensures idempotency.

    • createdAt (datetime) –

      The date and time when the access token was created.

    • dnsViewId (string) –

      The ID of the DNS view associated with this access token.

    • expiresAt (datetime) –

      The date and time when the access token expires.

    • name (string) –

      The name of the access token.

    • status (string) –

      The operational status of the access token.

    • value (string) –

      The access token value. This token should be included in DoH and DoT requests for authentication. Keep this value secure as it provides access to your Route 53 Global Resolver.

Exceptions

  • Route53GlobalResolver.Client.exceptions.InternalServerException

  • Route53GlobalResolver.Client.exceptions.ValidationException

  • Route53GlobalResolver.Client.exceptions.ConflictException

  • Route53GlobalResolver.Client.exceptions.ServiceQuotaExceededException

  • Route53GlobalResolver.Client.exceptions.AccessDeniedException

  • Route53GlobalResolver.Client.exceptions.ThrottlingException

  • Route53GlobalResolver.Client.exceptions.ResourceNotFoundException