ListCampaigns

class Personalize.Paginator.ListCampaigns
paginator = client.get_paginator('list_campaigns')
paginate(**kwargs)

Creates an iterator that will paginate through responses from Personalize.Client.list_campaigns().

See also: AWS API Documentation

Request Syntax

response_iterator = paginator.paginate(
    solutionArn='string',
    PaginationConfig={
        'MaxItems': 123,
        'PageSize': 123,
        'StartingToken': 'string'
    }
)
Parameters
  • solutionArn (string) -- The Amazon Resource Name (ARN) of the solution to list the campaigns for. When a solution is not specified, all the campaigns associated with the account are listed.
  • PaginationConfig (dict) --

    A dictionary that provides parameters to control pagination.

    • MaxItems (integer) --

      The total number of items to return. If the total number of items available is more than the value specified in max-items then a NextToken will be provided in the output that you can use to resume pagination.

    • PageSize (integer) --

      The size of each page.

    • StartingToken (string) --

      A token to specify where to start paginating. This is the NextToken from a previous response.

Return type

dict

Returns

Response Syntax

{
    'campaigns': [
        {
            'name': 'string',
            'campaignArn': 'string',
            'status': 'string',
            'creationDateTime': datetime(2015, 1, 1),
            'lastUpdatedDateTime': datetime(2015, 1, 1),
            'failureReason': 'string'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • campaigns (list) --

      A list of the campaigns.

      • (dict) --

        Provides a summary of the properties of a campaign. For a complete listing, call the DescribeCampaign API.

        • name (string) --

          The name of the campaign.

        • campaignArn (string) --

          The Amazon Resource Name (ARN) of the campaign.

        • status (string) --

          The status of the campaign.

          A campaign can be in one of the following states:

          • CREATE PENDING > CREATE IN_PROGRESS > ACTIVE -or- CREATE FAILED
          • DELETE PENDING > DELETE IN_PROGRESS
        • creationDateTime (datetime) --

          The date and time (in Unix time) that the campaign was created.

        • lastUpdatedDateTime (datetime) --

          The date and time (in Unix time) that the campaign was last updated.

        • failureReason (string) --

          If a campaign fails, the reason behind the failure.

    • NextToken (string) --

      A token to resume pagination.