cancel_job

Snowball.Client.cancel_job(**kwargs)

Cancels the specified job. You can only cancel a job before its JobState value changes to PreparingAppliance . Requesting the ListJobs or DescribeJob action returns a job's JobState as part of the response element data returned.

See also: AWS API Documentation

Request Syntax

response = client.cancel_job(
    JobId='string'
)
Parameters
JobId (string) --

[REQUIRED]

The 39-character job ID for the job that you want to cancel, for example JID123e4567-e89b-12d3-a456-426655440000 .

Return type
dict
Returns
Response Syntax
{}

Response Structure

  • (dict) --

Exceptions

  • Snowball.Client.exceptions.InvalidResourceException
  • Snowball.Client.exceptions.InvalidJobStateException
  • Snowball.Client.exceptions.KMSRequestFailedException

Examples

This operation cancels a job. You can only cancel a job before its JobState value changes to PreparingAppliance.

response = client.cancel_job(
    JobId='JID123e4567-e89b-12d3-a456-426655440000',
)

print(response)

Expected Output:

{
    'ResponseMetadata': {
        '...': '...',
    },
}