IoT / Paginator / ListCommandExecutions

ListCommandExecutions#

class IoT.Paginator.ListCommandExecutions#
paginator = client.get_paginator('list_command_executions')
paginate(**kwargs)#

Creates an iterator that will paginate through responses from IoT.Client.list_command_executions().

See also: AWS API Documentation

Request Syntax

response_iterator = paginator.paginate(
    namespace='AWS-IoT'|'AWS-IoT-FleetWise',
    status='CREATED'|'IN_PROGRESS'|'SUCCEEDED'|'FAILED'|'REJECTED'|'TIMED_OUT',
    sortOrder='ASCENDING'|'DESCENDING',
    startedTimeFilter={
        'after': 'string',
        'before': 'string'
    },
    completedTimeFilter={
        'after': 'string',
        'before': 'string'
    },
    targetArn='string',
    commandArn='string',
    PaginationConfig={
        'MaxItems': 123,
        'PageSize': 123,
        'StartingToken': 'string'
    }
)
Parameters:
  • namespace (string) – The namespace of the command.

  • status (string) – List all command executions for the device that have a particular status. For example, you can filter the list to display only command executions that have failed or timed out.

  • sortOrder (string) – Specify whether to list the command executions that were created in the ascending or descending order. By default, the API returns all commands in the descending order based on the start time or completion time of the executions, that are determined by the startTimeFilter and completeTimeFilter parameters.

  • startedTimeFilter (dict) –

    List all command executions that started any time before or after the date and time that you specify. The date and time uses the format yyyy-MM-dd'T'HH:mm.

    • after (string) –

      Filter to display command executions that started or completed only after a particular date and time.

    • before (string) –

      Filter to display command executions that started or completed only before a particular date and time.

  • completedTimeFilter (dict) –

    List all command executions that completed any time before or after the date and time that you specify. The date and time uses the format yyyy-MM-dd'T'HH:mm.

    • after (string) –

      Filter to display command executions that started or completed only after a particular date and time.

    • before (string) –

      Filter to display command executions that started or completed only before a particular date and time.

  • targetArn (string) – The Amazon Resource Number (ARN) of the target device. You can use this information to list all command executions for a particular device.

  • commandArn (string) – The Amazon Resource Number (ARN) of the command. You can use this information to list all command executions for a particular command.

  • 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

{
    'commandExecutions': [
        {
            'commandArn': 'string',
            'executionId': 'string',
            'targetArn': 'string',
            'status': 'CREATED'|'IN_PROGRESS'|'SUCCEEDED'|'FAILED'|'REJECTED'|'TIMED_OUT',
            'createdAt': datetime(2015, 1, 1),
            'startedAt': datetime(2015, 1, 1),
            'completedAt': datetime(2015, 1, 1)
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) –

    • commandExecutions (list) –

      The list of command executions.

      • (dict) –

        Summary information about a particular command execution.

        • commandArn (string) –

          The Amazon Resource Name (ARN) of the command execution.

        • executionId (string) –

          The unique identifier of the command execution.

        • targetArn (string) –

          The Amazon Resource Name (ARN) of the target device for which the command is being executed.

        • status (string) –

          The status of the command executions.

        • createdAt (datetime) –

          The date and time at which the command execution was created for the target device.

        • startedAt (datetime) –

          The date and time at which the command started executing on the target device.

        • completedAt (datetime) –

          The date and time at which the command completed executing on the target device.

    • NextToken (string) –

      A token to resume pagination.