Skip to content

list_vpc_endpoints_for_domain async

list_vpc_endpoints_for_domain(
    domain_name: DomainName,
    *,
    config_overrides: Optional[AsyncElasticsearchServiceClientConfig] = None,
    next_token: Optional[NextToken] = None,
) -> ListVpcEndpointsForDomainResponse

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

Parameters:

  • domain_name (DomainName) –

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

  • next_token (Optional[NextToken], default: None ) –

    Provides an identifier to allow retrieval of paginated results.

Raises:

  • BaseException –

    An error occurred while processing the request.

  • DisabledOperationException –

    An error occured because the client wanted to access a not supported operation. Gives http status code of 409.

  • InternalException –

    The request processing has failed because of an unknown error, exception or failure (the failure is internal to the service) . Gives http status code of 500.

  • ResourceNotFoundException –

    An exception for accessing or deleting a resource that does not exist. Gives http status code of 400.

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_elasticsearch_service/_services/async_elasticsearch_service.py
async def list_vpc_endpoints_for_domain(
    self,
    domain_name: "capo_elasticsearch_service.types.domain_name.DomainName",
    *,
    config_overrides: Optional[AsyncElasticsearchServiceClientConfig] = None,
    next_token: Optional[
        "capo_elasticsearch_service.types.next_token.NextToken"
    ] = None,
) -> "capo_elasticsearch_service.types.list_vpc_endpoints_for_domain_response.ListVpcEndpointsForDomainResponse":
    """<p>Retrieves all Amazon OpenSearch Service-managed VPC endpoints associated with a particular domain.</p>

    Args:
        domain_name: <p>Name of the ElasticSearch domain whose VPC endpoints are to be listed.</p>
        next_token: <p>Provides an identifier to allow retrieval of paginated results.</p>

    Raises:
        capo_elasticsearch_service.errors.base_exception.BaseException: <p>An error occurred while processing the request.</p>
        capo_elasticsearch_service.errors.disabled_operation_exception.DisabledOperationException: <p>An error occured because the client wanted to access a not supported operation. Gives http status code of 409.</p>
        capo_elasticsearch_service.errors.internal_exception.InternalException: <p>The request processing has failed because of an unknown error, exception or failure (the failure is internal to the service) . Gives http status code of 500.</p>
        capo_elasticsearch_service.errors.resource_not_found_exception.ResourceNotFoundException: <p>An exception for accessing or deleting a resource that does not exist. Gives http status code of 400.</p>
        capo_elasticsearch_service.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_elasticsearch_service.types.list_vpc_endpoints_for_domain_request.ListVpcEndpointsForDomainRequest]",
    ) -> AsyncOperationResponse[
        "capo_elasticsearch_service.types.list_vpc_endpoints_for_domain_response.ListVpcEndpointsForDomainResponse"
    ]:
        import capo_elasticsearch_service._operations.amazon_elasticsearch_service2015.list_vpc_endpoints_for_domain

        (
            output,
            http_response,
        ) = await capo_elasticsearch_service._operations.amazon_elasticsearch_service2015.list_vpc_endpoints_for_domain.async_list_vpc_endpoints_for_domain(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("ListVpcEndpointsForDomain")
    )
    input_: capo_elasticsearch_service.types.list_vpc_endpoints_for_domain_request.ListVpcEndpointsForDomainRequest = {
        "domain_name": domain_name
    }
    if next_token is not None:
        input_["next_token"] = next_token

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output