Skip to content

Type definitions#

Index > PersonalizeEvents > Type definitions

Auto-generated documentation for PersonalizeEvents type annotations stubs module mypy-boto3-personalize-events.

TimestampTypeDef#

# TimestampTypeDef definition

TimestampTypeDef = Union[
    datetime,
    str,
]

ActionTypeDef#

# ActionTypeDef definition

class ActionTypeDef(TypedDict):
    actionId: str,
    properties: NotRequired[str],

ResponseMetadataTypeDef#

# ResponseMetadataTypeDef definition

class ResponseMetadataTypeDef(TypedDict):
    RequestId: str,
    HTTPStatusCode: int,
    HTTPHeaders: Dict[str, str],
    RetryAttempts: int,
    HostId: NotRequired[str],

MetricAttributionTypeDef#

# MetricAttributionTypeDef definition

class MetricAttributionTypeDef(TypedDict):
    eventAttributionSource: str,

ItemTypeDef#

# ItemTypeDef definition

class ItemTypeDef(TypedDict):
    itemId: str,
    properties: NotRequired[str],

UserTypeDef#

# UserTypeDef definition

class UserTypeDef(TypedDict):
    userId: str,
    properties: NotRequired[str],

ActionInteractionTypeDef#

# ActionInteractionTypeDef definition

class ActionInteractionTypeDef(TypedDict):
    actionId: str,
    sessionId: str,
    timestamp: TimestampTypeDef,
    eventType: str,
    userId: NotRequired[str],
    eventId: NotRequired[str],
    recommendationId: NotRequired[str],
    impression: NotRequired[Sequence[str]],
    properties: NotRequired[str],

PutActionsRequestRequestTypeDef#

# PutActionsRequestRequestTypeDef definition

class PutActionsRequestRequestTypeDef(TypedDict):
    datasetArn: str,
    actions: Sequence[ActionTypeDef],  # (1)
  1. See ActionTypeDef

EmptyResponseMetadataTypeDef#

# EmptyResponseMetadataTypeDef definition

class EmptyResponseMetadataTypeDef(TypedDict):
    ResponseMetadata: ResponseMetadataTypeDef,  # (1)
  1. See ResponseMetadataTypeDef

EventTypeDef#

# EventTypeDef definition

class EventTypeDef(TypedDict):
    eventType: str,
    sentAt: TimestampTypeDef,
    eventId: NotRequired[str],
    eventValue: NotRequired[float],
    itemId: NotRequired[str],
    properties: NotRequired[str],
    recommendationId: NotRequired[str],
    impression: NotRequired[Sequence[str]],
    metricAttribution: NotRequired[MetricAttributionTypeDef],  # (1)
  1. See MetricAttributionTypeDef

PutItemsRequestRequestTypeDef#

# PutItemsRequestRequestTypeDef definition

class PutItemsRequestRequestTypeDef(TypedDict):
    datasetArn: str,
    items: Sequence[ItemTypeDef],  # (1)
  1. See ItemTypeDef

PutUsersRequestRequestTypeDef#

# PutUsersRequestRequestTypeDef definition

class PutUsersRequestRequestTypeDef(TypedDict):
    datasetArn: str,
    users: Sequence[UserTypeDef],  # (1)
  1. See UserTypeDef

PutActionInteractionsRequestRequestTypeDef#

# PutActionInteractionsRequestRequestTypeDef definition

class PutActionInteractionsRequestRequestTypeDef(TypedDict):
    trackingId: str,
    actionInteractions: Sequence[ActionInteractionTypeDef],  # (1)
  1. See