Skip to content

PersonalizeEventsClient#

Index > PersonalizeEvents > PersonalizeEventsClient

Auto-generated documentation for PersonalizeEvents type annotations stubs module types-aiobotocore-personalize-events.

PersonalizeEventsClient#

Type annotations and code completion for session.create_client("personalize-events") boto3 documentation

PersonalizeEventsClient usage example

from aiobotocore.session import get_session
from types_aiobotocore_personalize_events.client import PersonalizeEventsClient

session = get_session()
async with session.create_client("personalize-events") as client:
    client: PersonalizeEventsClient

Exceptions#

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

PersonalizeEventsClient.exceptions usage example

async with session.create_client("personalize-events") as client:
    try:
        do_something(client)
    except (
            client.ClientError,
        client.InvalidInputException,
        client.ResourceInUseException,
        client.ResourceNotFoundException,
    ) as e:
        print(e)
PersonalizeEventsClient usage type checking example

from types_aiobotocore_personalize_events.client import Exceptions

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

Methods#

can_paginate#

Check if an operation can be paginated.

Type annotations and code completion for session.create_client("personalize-events").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("personalize-events").close method. boto3 documentation

# close method definition

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

generate_presigned_url#

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

Type annotations and code completion for session.create_client("personalize-events").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:
    ...

put_events#

Records user interaction event data.

Type annotations and code completion for session.create_client("personalize-events").put_events method. boto3 documentation

# put_events method definition

await def put_events(
    self,
    *,
    trackingId: str,
    sessionId: str,
    eventList: Sequence[EventTypeDef],  # (1)
    userId: str = ...,
) -> EmptyResponseMetadataTypeDef:  # (2)
    ...
  1. See EventTypeDef
  2. See EmptyResponseMetadataTypeDef
# put_events method usage example with argument unpacking

kwargs: PutEventsRequestRequestTypeDef = {  # (1)
    "trackingId": ...,
    "sessionId": ...,
    "eventList": ...,
}

parent.put_events(**kwargs)
  1. See PutEventsRequestRequestTypeDef

put_items#

Adds one or more items to an Items dataset.

Type annotations and code completion for session.create_client("personalize-events").put_items method. boto3 documentation

# put_items method definition

await def put_items(
    self,
    *,
    datasetArn: str,
    items: Sequence[ItemTypeDef],  # (1)
) -> EmptyResponseMetadataTypeDef:  # (2)
    ...
  1. See ItemTypeDef
  2. See EmptyResponseMetadataTypeDef
# put_items method usage example with argument unpacking

kwargs: PutItemsRequestRequestTypeDef = {  # (1)
    "datasetArn": ...,
    "items": ...,
}

parent.put_items(**kwargs)
  1. See PutItemsRequestRequestTypeDef

put_users#

Adds one or more users to a Users dataset.

Type annotations and code completion for session.create_client("personalize-events").put_users method. boto3 documentation

# put_users method definition

await def put_users(
    self,
    *,
    datasetArn: str,
    users: Sequence[UserTypeDef],  # (1)
) -> EmptyResponseMetadataTypeDef:  # (2)
    ...
  1. See UserTypeDef
  2. See EmptyResponseMetadataTypeDef
# put_users method usage example with argument unpacking

kwargs: PutUsersRequestRequestTypeDef = {  # (1)
    "datasetArn": ...,
    "users": ...,
}

parent.put_users(**kwargs)
  1. See PutUsersRequestRequestTypeDef

__aenter__#

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

# __aenter__ method definition

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

__aexit__#

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

# __aexit__ method definition

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