ManagedintegrationsforIoTDeviceManagement / Client / create_ota_task

create_ota_task#

ManagedintegrationsforIoTDeviceManagement.Client.create_ota_task(**kwargs)#

Create an over-the-air (OTA) task to update a device.

See also: AWS API Documentation

Request Syntax

response = client.create_ota_task(
    Description='string',
    S3Url='string',
    Protocol='HTTP',
    Target=[
        'string',
    ],
    TaskConfigurationId='string',
    OtaMechanism='PUSH',
    OtaType='ONE_TIME'|'CONTINUOUS',
    OtaTargetQueryString='string',
    ClientToken='string',
    OtaSchedulingConfig={
        'EndBehavior': 'STOP_ROLLOUT'|'CANCEL'|'FORCE_CANCEL',
        'EndTime': 'string',
        'MaintenanceWindows': [
            {
                'DurationInMinutes': 123,
                'StartTime': 'string'
            },
        ],
        'StartTime': 'string'
    },
    OtaTaskExecutionRetryConfig={
        'RetryConfigCriteria': [
            {
                'FailureType': 'FAILED'|'TIMED_OUT'|'ALL',
                'MinNumberOfRetries': 123
            },
        ]
    },
    Tags={
        'string': 'string'
    }
)
Parameters:
  • Description (string) – The description of the over-the-air (OTA) task.

  • S3Url (string) –

    [REQUIRED]

    The URL to the Amazon S3 bucket where the over-the-air (OTA) task is stored.

  • Protocol (string) – The connection protocol the over-the-air (OTA) task uses to update the device.

  • Target (list) –

    The device targeted for the over-the-air (OTA) task.

    • (string) –

  • TaskConfigurationId (string) – The identifier for the over-the-air (OTA) task configuration.

  • OtaMechanism (string) – The deployment mechanism for the over-the-air (OTA) task.

  • OtaType (string) –

    [REQUIRED]

    The frequency type for the over-the-air (OTA) task.

  • OtaTargetQueryString (string) – The query string to add things to the thing group.

  • ClientToken (string) –

    An idempotency token. If you retry a request that completed successfully initially using the same client token and parameters, then the retry attempt will succeed without performing any further actions.

    This field is autopopulated if not provided.

  • OtaSchedulingConfig (dict) –

    Over-the-air (OTA) task scheduling config.

    • EndBehavior (string) –

      Specifies the end behavior for all task executions after a task reaches the selected endTime. If endTime is not selected when creating the task, then endBehavior does not apply.

    • EndTime (string) –

      The time an over-the-air (OTA) task will stop.

    • MaintenanceWindows (list) –

      Maintenance window list for over-the-air (OTA) task scheduling config.

      • (dict) –

        Structure representing scheduling maintenance window.

        • DurationInMinutes (integer) –

          Displays the duration of the next maintenance window.

        • StartTime (string) –

          Displays the start time of the next maintenance window.

    • StartTime (string) –

      The time an over-the-air (OTA) task will start.

  • OtaTaskExecutionRetryConfig (dict) –

    Over-the-air (OTA) task retry config.

    • RetryConfigCriteria (list) –

      The list of retry config criteria.

      • (dict) –

        Structure representing one retry config criteria.

        • FailureType (string) –

          Over-the-air (OTA) retry criteria failure type.

        • MinNumberOfRetries (integer) –

          The number of retries allowed for a failure type for the over-the-air (OTA) task.

  • Tags (dict) –

    A set of key/value pairs that are used to manage the over-the-air (OTA) task.

    • (string) –

      • (string) –

Return type:

dict

Returns:

Response Syntax

{
    'TaskId': 'string',
    'TaskArn': 'string',
    'Description': 'string'
}

Response Structure

  • (dict) –

    • TaskId (string) –

      The identifier of the over-the-air (OTA) task.

    • TaskArn (string) –

      The Amazon Resource Name (ARN) of the over-the-air (OTA) task.

    • Description (string) –

      A description of the over-the-air (OTA) task.

Exceptions