CustomerProfiles / Client / list_segment_subscription_events

list_segment_subscription_events

CustomerProfiles.Client.list_segment_subscription_events(**kwargs)

Returns the most recent membership events for a segment. Each event represents a profile that entered or exited the segment.

This operation is paginated.

See also: AWS API Documentation

Request Syntax

response = client.list_segment_subscription_events(
    DomainName='string',
    SegmentDefinitionName='string',
    MaxResults=123,
    NextToken='string'
)
Parameters:
  • DomainName (string) –

    [REQUIRED]

    The unique name of the domain.

  • SegmentDefinitionName (string) –

    [REQUIRED]

    The unique name of the segment definition.

  • MaxResults (integer) – The maximum number of events to return per page.

  • NextToken (string) – The pagination token from the previous call to retrieve the next page of results.

Return type:

dict

Returns:

Response Syntax

{
    'Events': [
        {
            'ProfileId': 'string',
            'UpdatedAt': datetime(2015, 1, 1),
            'EventType': 'LIVE'|'SCHEDULE',
            'Event': 'JOINED'|'LEFT'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) –

    • Events (list) –

      A list of segment membership events.

      • (dict) –

        Represents a single segment membership event.

        • ProfileId (string) –

          The unique identifier of a customer profile.

        • UpdatedAt (datetime) –

          The timestamp of when the membership change was detected.

        • EventType (string) –

          The type of event that triggered the membership change. The following are valid values:

          • LIVE: Real-time event triggered by a profile or calculated attribute change (Classic segments only).

          • SCHEDULE: Event generated during a scheduled execution.

        • Event (string) –

          Whether the profile joined or left the segment. The following are valid values:

          • JOINED: The profile joined the segment.

          • LEFT: The profile left the segment.

    • NextToken (string) –

      The pagination token to use to retrieve the next page of results.

Exceptions

  • CustomerProfiles.Client.exceptions.ResourceNotFoundException

  • CustomerProfiles.Client.exceptions.InternalServerException

  • CustomerProfiles.Client.exceptions.BadRequestException

  • CustomerProfiles.Client.exceptions.ThrottlingException

  • CustomerProfiles.Client.exceptions.AccessDeniedException