Amazon Elasticsearch Service

2022/11/10 - Amazon Elasticsearch Service - 9 new api methods

Changes  Amazon OpenSearch Service now offers managed VPC endpoints to connect to your Amazon OpenSearch Service VPC-enabled domain in a Virtual Private Cloud (VPC). This feature allows you to privately access OpenSearch Service domain without using public IPs or requiring traffic to traverse the Internet.

UpdateVpcEndpoint (new) Link ¶

Modifies an Amazon OpenSearch Service-managed interface VPC endpoint.

See also: AWS API Documentation

Request Syntax

client.update_vpc_endpoint(
    VpcEndpointId='string',
    VpcOptions={
        'SubnetIds': [
            'string',
        ],
        'SecurityGroupIds': [
            'string',
        ]
    }
)
type VpcEndpointId:

string

param VpcEndpointId:

[REQUIRED]

Unique identifier of the VPC endpoint to be updated.

type VpcOptions:

dict

param VpcOptions:

[REQUIRED]

The security groups and/or subnets to add, remove, or modify.

  • SubnetIds (list) --

    Specifies the subnets for VPC endpoint.

    • (string) --

  • SecurityGroupIds (list) --

    Specifies the security groups for VPC endpoint.

    • (string) --

rtype:

dict

returns:

Response Syntax

{
    'VpcEndpoint': {
        'VpcEndpointId': 'string',
        'VpcEndpointOwner': 'string',
        'DomainArn': 'string',
        'VpcOptions': {
            'VPCId': 'string',
            'SubnetIds': [
                'string',
            ],
            'AvailabilityZones': [
                'string',
            ],
            'SecurityGroupIds': [
                'string',
            ]
        },
        'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'UPDATING'|'UPDATE_FAILED'|'DELETING'|'DELETE_FAILED',
        'Endpoint': 'string'
    }
}

Response Structure

  • (dict) --

    Contains the configuration and status of the VPC endpoint being updated.

    • VpcEndpoint (dict) --

      The endpoint to be updated.

      • VpcEndpointId (string) --

        The unique identifier of the endpoint.

      • VpcEndpointOwner (string) --

        The creator of the endpoint.

      • DomainArn (string) --

        The Amazon Resource Name (ARN) of the domain associated with the endpoint.

      • VpcOptions (dict) --

        Options to specify the subnets and security groups for an Amazon OpenSearch Service VPC endpoint.

        • VPCId (string) --

          The VPC Id for the Elasticsearch domain. Exists only if the domain was created with VPCOptions.

        • SubnetIds (list) --

          Specifies the subnets for VPC endpoint.

          • (string) --

        • AvailabilityZones (list) --

          The availability zones for the Elasticsearch domain. Exists only if the domain was created with VPCOptions.

          • (string) --

        • SecurityGroupIds (list) --

          Specifies the security groups for VPC endpoint.

          • (string) --

      • Status (string) --

        The current status of the endpoint.

      • Endpoint (string) --

        The connection endpoint ID for connecting to the domain.

DeleteVpcEndpoint (new) Link ¶

Deletes an Amazon OpenSearch Service-managed interface VPC endpoint.

See also: AWS API Documentation

Request Syntax

client.delete_vpc_endpoint(
    VpcEndpointId='string'
)
type VpcEndpointId:

string

param VpcEndpointId:

[REQUIRED]

The unique identifier of the endpoint to be deleted.

rtype:

dict

returns:

Response Syntax

{
    'VpcEndpointSummary': {
        'VpcEndpointId': 'string',
        'VpcEndpointOwner': 'string',
        'DomainArn': 'string',
        'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'UPDATING'|'UPDATE_FAILED'|'DELETING'|'DELETE_FAILED'
    }
}

Response Structure

  • (dict) --

    Container for response parameters to the DeleteVpcEndpoint operation. Contains the summarized detail of the VPC Endpoint being deleted.

    • VpcEndpointSummary (dict) --

      Information about the deleted endpoint, including its current status ( DELETING or DELETE_FAILED).

      • VpcEndpointId (string) --

        The unique identifier of the endpoint.

      • VpcEndpointOwner (string) --

        The creator of the endpoint.

      • DomainArn (string) --

        The Amazon Resource Name (ARN) of the domain associated with the endpoint.

      • Status (string) --

        The current status of the endpoint.

CreateVpcEndpoint (new) Link ¶

Creates an Amazon OpenSearch Service-managed VPC endpoint.

See also: AWS API Documentation

Request Syntax

client.create_vpc_endpoint(
    DomainArn='string',
    VpcOptions={
        'SubnetIds': [
            'string',
        ],
        'SecurityGroupIds': [
            'string',
        ]
    },
    ClientToken='string'
)
type DomainArn:

string

param DomainArn:

[REQUIRED]

The Amazon Resource Name (ARN) of the domain to grant access to.

type VpcOptions:

dict

param VpcOptions:

[REQUIRED]

Options to specify the subnets and security groups for the endpoint.

  • SubnetIds (list) --

    Specifies the subnets for VPC endpoint.

    • (string) --

  • SecurityGroupIds (list) --

    Specifies the security groups for VPC endpoint.

    • (string) --

type ClientToken:

string

param ClientToken:

Unique, case-sensitive identifier to ensure idempotency of the request.

rtype:

dict

returns:

Response Syntax

{
    'VpcEndpoint': {
        'VpcEndpointId': 'string',
        'VpcEndpointOwner': 'string',
        'DomainArn': 'string',
        'VpcOptions': {
            'VPCId': 'string',
            'SubnetIds': [
                'string',
            ],
            'AvailabilityZones': [
                'string',
            ],
            'SecurityGroupIds': [
                'string',
            ]
        },
        'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'UPDATING'|'UPDATE_FAILED'|'DELETING'|'DELETE_FAILED',
        'Endpoint': 'string'
    }
}

Response Structure

  • (dict) --

    Container for response parameters to the CreateVpcEndpoint operation. Contains the configuration and status of the VPC Endpoint being created.

    • VpcEndpoint (dict) --

      Information about the newly created VPC endpoint.

      • VpcEndpointId (string) --

        The unique identifier of the endpoint.

      • VpcEndpointOwner (string) --

        The creator of the endpoint.

      • DomainArn (string) --

        The Amazon Resource Name (ARN) of the domain associated with the endpoint.

      • VpcOptions (dict) --

        Options to specify the subnets and security groups for an Amazon OpenSearch Service VPC endpoint.

        • VPCId (string) --

          The VPC Id for the Elasticsearch domain. Exists only if the domain was created with VPCOptions.

        • SubnetIds (list) --

          Specifies the subnets for VPC endpoint.

          • (string) --

        • AvailabilityZones (list) --

          The availability zones for the Elasticsearch domain. Exists only if the domain was created with VPCOptions.

          • (string) --

        • SecurityGroupIds (list) --

          Specifies the security groups for VPC endpoint.

          • (string) --

      • Status (string) --

        The current status of the endpoint.

      • Endpoint (string) --

        The connection endpoint ID for connecting to the domain.

RevokeVpcEndpointAccess (new) Link ¶

Revokes access to an Amazon OpenSearch Service domain that was provided through an interface VPC endpoint.

See also: AWS API Documentation

Request Syntax

client.revoke_vpc_endpoint_access(
    DomainName='string',
    Account='string'
)
type DomainName:

string

param DomainName:

[REQUIRED]

The name of the OpenSearch Service domain.

type Account:

string

param Account:

[REQUIRED]

The account ID to revoke access from.

rtype:

dict

returns:

Response Syntax

{}

Response Structure

  • (dict) --

    Container for response parameters to the RevokeVpcEndpointAccess operation. The response body for this operation is empty.

ListVpcEndpointAccess (new) Link ¶

Retrieves information about each principal that is allowed to access a given Amazon OpenSearch Service domain through the use of an interface VPC endpoint.

See also: AWS API Documentation

Request Syntax

client.list_vpc_endpoint_access(
    DomainName='string',
    NextToken='string'
)
type DomainName:

string

param DomainName:

[REQUIRED]

The name of the OpenSearch Service domain to retrieve access information for.

type NextToken:

string

param NextToken:

Provides an identifier to allow retrieval of paginated results.

rtype:

dict

returns:

Response Syntax

{
    'AuthorizedPrincipalList': [
        {
            'PrincipalType': 'AWS_ACCOUNT'|'AWS_SERVICE',
            'Principal': 'string'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    Container for response parameters to the ListVpcEndpointAccess operation. Returns a list of accounts id and account type authorized to manage VPC endpoints.

    • AuthorizedPrincipalList (list) --

      List of AuthorizedPrincipal describing the details of the permissions to manage VPC endpoints against the specified domain.

      • (dict) --

        Information about an account or service that has access to an Amazon OpenSearch Service domain through the use of an interface VPC endpoint.

        • PrincipalType (string) --

          The type of principal.

        • Principal (string) --

          The IAM principal that is allowed access to the domain.

    • NextToken (string) --

      Provides an identifier to allow retrieval of paginated results.

AuthorizeVpcEndpointAccess (new) Link ¶

Provides access to an Amazon OpenSearch Service domain through the use of an interface VPC endpoint.

See also: AWS API Documentation

Request Syntax

client.authorize_vpc_endpoint_access(
    DomainName='string',
    Account='string'
)
type DomainName:

string

param DomainName:

[REQUIRED]

The name of the OpenSearch Service domain to provide access to.

type Account:

string

param Account:

[REQUIRED]

The account ID to grant access to.

rtype:

dict

returns:

Response Syntax

{
    'AuthorizedPrincipal': {
        'PrincipalType': 'AWS_ACCOUNT'|'AWS_SERVICE',
        'Principal': 'string'
    }
}

Response Structure

  • (dict) --

    Container for response parameters to the AuthorizeVpcEndpointAccess operation. Contains the account ID and the type of the account being authorized to access the VPC endpoint.

    • AuthorizedPrincipal (dict) --

      Information about the account or service that was provided access to the domain.

      • PrincipalType (string) --

        The type of principal.

      • Principal (string) --

        The IAM principal that is allowed access to the domain.

ListVpcEndpoints (new) Link ¶

Retrieves all Amazon OpenSearch Service-managed VPC endpoints in the current account and Region.

See also: AWS API Documentation

Request Syntax

client.list_vpc_endpoints(
    NextToken='string'
)
type NextToken:

string

param NextToken:

Identifier to allow retrieval of paginated results.

rtype:

dict

returns:

Response Syntax

{
    'VpcEndpointSummaryList': [
        {
            'VpcEndpointId': 'string',
            'VpcEndpointOwner': 'string',
            'DomainArn': 'string',
            'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'UPDATING'|'UPDATE_FAILED'|'DELETING'|'DELETE_FAILED'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    Container for response parameters to the ListVpcEndpoints operation. Returns a list containing summarized details of the VPC endpoints.

    • VpcEndpointSummaryList (list) --

      Information about each endpoint.

      • (dict) --

        Summary information for an Amazon OpenSearch Service-managed VPC endpoint.

        • VpcEndpointId (string) --

          The unique identifier of the endpoint.

        • VpcEndpointOwner (string) --

          The creator of the endpoint.

        • DomainArn (string) --

          The Amazon Resource Name (ARN) of the domain associated with the endpoint.

        • Status (string) --

          The current status of the endpoint.

    • NextToken (string) --

      Provides an identifier to allow retrieval of paginated results.

DescribeVpcEndpoints (new) Link ¶

Describes one or more Amazon OpenSearch Service-managed VPC endpoints.

See also: AWS API Documentation

Request Syntax

client.describe_vpc_endpoints(
    VpcEndpointIds=[
        'string',
    ]
)
type VpcEndpointIds:

list

param VpcEndpointIds:

[REQUIRED]

The unique identifiers of the endpoints to get information about.

  • (string) --

rtype:

dict

returns:

Response Syntax

{
    'VpcEndpoints': [
        {
            'VpcEndpointId': 'string',
            'VpcEndpointOwner': 'string',
            'DomainArn': 'string',
            'VpcOptions': {
                'VPCId': 'string',
                'SubnetIds': [
                    'string',
                ],
                'AvailabilityZones': [
                    'string',
                ],
                'SecurityGroupIds': [
                    'string',
                ]
            },
            'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'UPDATING'|'UPDATE_FAILED'|'DELETING'|'DELETE_FAILED',
            'Endpoint': 'string'
        },
    ],
    'VpcEndpointErrors': [
        {
            'VpcEndpointId': 'string',
            'ErrorCode': 'ENDPOINT_NOT_FOUND'|'SERVER_ERROR',
            'ErrorMessage': 'string'
        },
    ]
}

Response Structure

  • (dict) --

    Container for response parameters to the DescribeVpcEndpoints operation. Returns a list containing configuration details and status of the VPC Endpoints as well as a list containing error responses of the endpoints that could not be described

    • VpcEndpoints (list) --

      Information about each requested VPC endpoint.

      • (dict) --

        The connection endpoint for connecting to an Amazon OpenSearch Service domain through a proxy.

        • VpcEndpointId (string) --

          The unique identifier of the endpoint.

        • VpcEndpointOwner (string) --

          The creator of the endpoint.

        • DomainArn (string) --

          The Amazon Resource Name (ARN) of the domain associated with the endpoint.

        • VpcOptions (dict) --

          Options to specify the subnets and security groups for an Amazon OpenSearch Service VPC endpoint.

          • VPCId (string) --

            The VPC Id for the Elasticsearch domain. Exists only if the domain was created with VPCOptions.

          • SubnetIds (list) --

            Specifies the subnets for VPC endpoint.

            • (string) --

          • AvailabilityZones (list) --

            The availability zones for the Elasticsearch domain. Exists only if the domain was created with VPCOptions.

            • (string) --

          • SecurityGroupIds (list) --

            Specifies the security groups for VPC endpoint.

            • (string) --

        • Status (string) --

          The current status of the endpoint.

        • Endpoint (string) --

          The connection endpoint ID for connecting to the domain.

    • VpcEndpointErrors (list) --

      Any errors associated with the request.

      • (dict) --

        Error information when attempting to describe an Amazon OpenSearch Service-managed VPC endpoint.

        • VpcEndpointId (string) --

          The unique identifier of the endpoint.

        • ErrorCode (string) --

          The code associated with the error.

        • ErrorMessage (string) --

          A message describing the error.

ListVpcEndpointsForDomain (new) Link ¶

Retrieves all Amazon OpenSearch Service-managed VPC endpoints associated with a particular domain.

See also: AWS API Documentation

Request Syntax

client.list_vpc_endpoints_for_domain(
    DomainName='string',
    NextToken='string'
)
type DomainName:

string

param DomainName:

[REQUIRED]

Name of the ElasticSearch domain whose VPC endpoints are to be listed.

type NextToken:

string

param NextToken:

Provides an identifier to allow retrieval of paginated results.

rtype:

dict

returns:

Response Syntax

{
    'VpcEndpointSummaryList': [
        {
            'VpcEndpointId': 'string',
            'VpcEndpointOwner': 'string',
            'DomainArn': 'string',
            'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'UPDATING'|'UPDATE_FAILED'|'DELETING'|'DELETE_FAILED'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    Container for response parameters to the ListVpcEndpointsForDomain operation. Returns a list containing summarized details of the VPC endpoints.

    • VpcEndpointSummaryList (list) --

      Provides list of VpcEndpointSummary summarizing details of the VPC endpoints.

      • (dict) --

        Summary information for an Amazon OpenSearch Service-managed VPC endpoint.

        • VpcEndpointId (string) --

          The unique identifier of the endpoint.

        • VpcEndpointOwner (string) --

          The creator of the endpoint.

        • DomainArn (string) --

          The Amazon Resource Name (ARN) of the domain associated with the endpoint.

        • Status (string) --

          The current status of the endpoint.

    • NextToken (string) --

      Information about each endpoint associated with the domain.