FreeTier / Client / list_account_activities

list_account_activities

FreeTier.Client.list_account_activities(**kwargs)

Returns a list of activities that are available. This operation supports pagination and filtering by status.

See also: AWS API Documentation

Request Syntax

response = client.list_account_activities(
    filterActivityStatuses=[
        'NOT_STARTED'|'IN_PROGRESS'|'COMPLETED'|'EXPIRING',
    ],
    nextToken='string',
    maxResults=123,
    languageCode='en-US'|'en-GB'|'id-ID'|'de-DE'|'es-ES'|'fr-FR'|'ja-JP'|'it-IT'|'pt-PT'|'ko-KR'|'zh-CN'|'zh-TW'|'tr-TR'
)
Parameters:
  • filterActivityStatuses (list) –

    The activity status filter. This field can be used to filter the response by activities status.

    • (string) –

  • nextToken (string) – A token from a previous paginated response. If this is specified, the response includes records beginning from this token (inclusive), up to the number specified by maxResults.

  • maxResults (integer) – The maximum number of items to return for this request. To get the next page of items, make another request with the token returned in the output.

  • languageCode (string) – The language code used to return translated titles.

Return type:

dict

Returns:

Response Syntax

{
    'activities': [
        {
            'activityId': 'string',
            'title': 'string',
            'reward': {
                'credit': {
                    'amount': 123.0,
                    'unit': 'USD'
                }
            },
            'status': 'NOT_STARTED'|'IN_PROGRESS'|'COMPLETED'|'EXPIRING'
        },
    ],
    'nextToken': 'string'
}

Response Structure

  • (dict) –

    • activities (list) –

      A brief information about the activities.

      • (dict) –

        The summary of activities.

        • activityId (string) –

          A unique identifier that identifies the activity.

        • title (string) –

          The title of the activity.

        • reward (dict) –

          The reward for the activity.

          Note

          This is a Tagged Union structure. Only one of the following top level keys will be set: credit. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

          'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
          
          • credit (dict) –

            The credits gained by activity rewards.

            • amount (float) –

              The aggregated monetary amount of credits earned.

            • unit (string) –

              The unit that the monetary amount is given in.

        • status (string) –

          The current status of the activity.

    • nextToken (string) –

      The token to include in another request to get the next page of items. This value is null when there are no more items to return.

Exceptions