Skip to content

ElasticInferenceClient#

Index > ElasticInference > ElasticInferenceClient

Auto-generated documentation for ElasticInference type annotations stubs module types-aiobotocore-elastic-inference.

ElasticInferenceClient#

Type annotations and code completion for session.create_client("elastic-inference") boto3 documentation

ElasticInferenceClient usage example

from aiobotocore.session import get_session
from types_aiobotocore_elastic_inference.client import ElasticInferenceClient

session = get_session()
async with session.create_client("elastic-inference") as client:
    client: ElasticInferenceClient

Exceptions#

aiobotocore client exceptions are generated in runtime. This class provides code completion for session.create_client("elastic-inference").exceptions structure.

ElasticInferenceClient.exceptions usage example

async with session.create_client("elastic-inference") as client:
    try:
        do_something(client)
    except (
            client.BadRequestException,
        client.ClientError,
        client.InternalServerException,
        client.ResourceNotFoundException,
    ) as e:
        print(e)
ElasticInferenceClient usage type checking example

from types_aiobotocore_elastic_inference.client import Exceptions

def handle_error(exc: Exceptions.BadRequestException) -> None:
    ...

Methods#

can_paginate#

Check if an operation can be paginated.

Type annotations and code completion for session.create_client("elastic-inference").can_paginate method. boto3 documentation

# can_paginate method definition

def can_paginate(
    self,
    operation_name: str,
) -> bool:
    ...

close#

Closes underlying endpoint connections.

Type annotations and code completion for session.create_client("elastic-inference").close method. boto3 documentation

# close method definition

await def close(
    self,
) -> None:
    ...

describe_accelerator_offerings#

Describes the locations in which a given accelerator type or set of types is present in a given region.

Type annotations and code completion for session.create_client("elastic-inference").describe_accelerator_offerings method. boto3 documentation

# describe_accelerator_offerings method definition

await def describe_accelerator_offerings(
    self,
    *,
    locationType: LocationTypeType,  # (1)
    acceleratorTypes: Sequence[str] = ...,
) -> DescribeAcceleratorOfferingsResponseTypeDef:  # (2)
    ...
  1. See LocationTypeType
  2. See DescribeAcceleratorOfferingsResponseTypeDef
# describe_accelerator_offerings method usage example with argument unpacking

kwargs: DescribeAcceleratorOfferingsRequestRequestTypeDef = {  # (1)
    "locationType": ...,
}

parent.describe_accelerator_offerings(**kwargs)
  1. See DescribeAcceleratorOfferingsRequestRequestTypeDef

describe_accelerator_types#

Describes the accelerator types available in a given region, as well as their characteristics, such as memory and throughput.

Type annotations and code completion for session.create_client("elastic-inference").describe_accelerator_types method. boto3 documentation

# describe_accelerator_types method definition

await def describe_accelerator_types(
    self,
) -> DescribeAcceleratorTypesResponseTypeDef:  # (1)
    ...
  1. See DescribeAcceleratorTypesResponseTypeDef

describe_accelerators#

Describes information over a provided set of accelerators belonging to an account.

Type annotations and code completion for session.create_client("elastic-inference").describe_accelerators method. boto3 documentation

# describe_accelerators method definition

await def describe_accelerators(
    self,
    *,
    acceleratorIds: Sequence[str] = ...,
    filters: Sequence[FilterTypeDef] = ...,  # (1)
    maxResults: int = ...,
    nextToken: str = ...,
) -> DescribeAcceleratorsResponseTypeDef:  # (2)
    ...
  1. See FilterTypeDef
  2. See DescribeAcceleratorsResponseTypeDef
# describe_accelerators method usage example with argument unpacking

kwargs: DescribeAcceleratorsRequestRequestTypeDef = {  # (1)
    "acceleratorIds": ...,
}

parent.describe_accelerators(**kwargs)
  1. See DescribeAcceleratorsRequestRequestTypeDef

generate_presigned_url#

Generate a presigned url given a client, its method, and arguments.

Type annotations and code completion for session.create_client("elastic-inference").generate_presigned_url method. boto3 documentation

# generate_presigned_url method definition

await def generate_presigned_url(
    self,
    ClientMethod: str,
    Params: Mapping[str, Any] = ...,
    ExpiresIn: int = 3600,
    HttpMethod: str = ...,
) -> str:
    ...

list_tags_for_resource#

Returns all tags of an Elastic Inference Accelerator.

Type annotations and code completion for session.create_client("elastic-inference").list_tags_for_resource method. boto3 documentation

# list_tags_for_resource method definition

await def list_tags_for_resource(
    self,
    *,
    resourceArn: str,
) -> ListTagsForResourceResultTypeDef:  # (1)
    ...
  1. See ListTagsForResourceResultTypeDef
# list_tags_for_resource method usage example with argument unpacking

kwargs: ListTagsForResourceRequestRequestTypeDef = {  # (1)
    "resourceArn": ...,
}

parent.list_tags_for_resource(**kwargs)
  1. See ListTagsForResourceRequestRequestTypeDef

tag_resource#

Adds the specified tags to an Elastic Inference Accelerator.

Type annotations and code completion for session.create_client("elastic-inference").tag_resource method. boto3 documentation

# tag_resource method definition

await def tag_resource(
    self,
    *,
    resourceArn: str,
    tags: Mapping[str, str],
) -> Dict[str, Any]:
    ...
# tag_resource method usage example with argument unpacking

kwargs: TagResourceRequestRequestTypeDef = {  # (1)
    "resourceArn": ...,
    "tags": ...,
}

parent.tag_resource(**kwargs)
  1. See TagResourceRequestRequestTypeDef

untag_resource#

Removes the specified tags from an Elastic Inference Accelerator.

Type annotations and code completion for session.create_client("elastic-inference").untag_resource method. boto3 documentation

# untag_resource method definition

await def untag_resource(
    self,
    *,
    resourceArn: str,
    tagKeys: Sequence[str],
) -> Dict[str, Any]:
    ...
# untag_resource method usage example with argument unpacking

kwargs: UntagResourceRequestRequestTypeDef = {  # (1)
    "resourceArn": ...,
    "tagKeys": ...,
}

parent.untag_resource(**kwargs)
  1. See UntagResourceRequestRequestTypeDef

__aenter__#

Type annotations and code completion for session.create_client("elastic-inference").__aenter__ method. boto3 documentation

# __aenter__ method definition

await def __aenter__(
    self,
) -> ElasticInferenceClient:
    ...

__aexit__#

Type annotations and code completion for session.create_client("elastic-inference").__aexit__ method. boto3 documentation

# __aexit__ method definition

await def __aexit__(
    self,
    exc_type: Any,
    exc_val: Any,
    exc_tb: Any,
) -> Any:
    ...

get_paginator#

Type annotations and code completion for session.create_client("elastic-inference").get_paginator method with overloads.