Jobs¶
Overview¶
Job requests can be used to set and retrieve information for one or many Jobs.
Job requests support GET
, PUT
, POST
, and DELETE
request types.
For more about these request types and their uses see the Request Formats and Responses documentation.
Requests and Responses¶
List of possible requests for Jobs.
All PUT
and POST
requests may also return a 400 Bad Request Error if there was no message body in the request.
All PUT
requests may also return a 400 Bad Request Error message if the command key is not present in the message body’s JSON object.
All PUT
requests may also return a 500 Internal Server Error error message if the command key in the message body contained an invalid command.
Get All The Jobs¶
Get the Job information for all Jobs in the Repository.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
GET |
Message Body: |
N/A |
Response: |
JSON object containing all the Job information for every Job in the Repository. |
Possible Errors: |
500 Internal Server Error: An exception occurred within the Deadline code. |
Get Jobs In Specified State¶
Gets Jobs in the specified state(s).
Valid states are Active, Suspended, Completed, Failed, and Pending.
Note that Active covers both Queued and Rendering Jobs.
Specify more than one state by separating them with commas (ie: Active,Completed,Suspended).
URL: |
http://hostname:portnumber/api/jobs?States=states |
Request Type: |
GET |
Message Body: |
N/A |
Response: |
JSON object containing all the Jobs in the specified state(s). |
Possible Errors: |
500 Internal Server Error: An exception occurred within the Deadline code. |
Get All Job IDs¶
Get all the Job IDs in the Repository.
URL: |
http://hostname:portnumber/api/jobs?IdOnly=true |
Request Type: |
GET |
Message Body: |
N/A |
Response: |
JSON object containing all the Job IDs in the Repository. |
Possible Errors: |
500 Internal Server Error: An exception occurred within the Deadline code. |
Get Job¶
Gets Job info for the given Job ID.
URL: |
http://hostname:portnumber/api/jobs?JobID=validJobID |
Request Type: |
GET |
Message Body: |
N/A |
Response: |
JSON object containing all the Job information for the Job ID provided. |
Possible Errors: |
500 Internal Server Error: An exception occurred within the Deadline code. |
Save Job¶
Saves the Job info provided. Job info must be in JSON format.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Suspend Job¶
Puts the Job with the matching ID into the Suspended state.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Suspend Job: Non-rendering tasks¶
Puts the Job with the matching ID into the Suspended state.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Resume Job¶
Resumes the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Resume Failed Job¶
Resumes the failed Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Requeue Job¶
Requeues the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Archive Job¶
Archives the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Import Job¶
Imports the Job path provided.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
The Job IDs of the imported Jobs and of the Jobs that were not imported. |
Possible Errors: |
|
Pend Job¶
Puts the Job with the ID that matches the provided ID in the pending state.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Release Pending Job¶
Releases the Job with the ID that matches the provided ID from the pending state.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Complete Job¶
Marks the Job with the ID that matches the provided ID as complete.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Fail Job¶
Marks the Job with the ID that matches the provided ID as failed.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Update Job Submission Date¶
Updates the Submission Date for the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Set Job Machine Limit¶
Sets the Job Machine Limit for the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Add Workers To Job Machine Limit List¶
Adds the provided Workers to the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Remove Workers From Job Machine Limit List¶
Removes the provided Workers from the Job Machine Limit List for the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Set Job Machine Limit Listed Workers¶
Sets provided Workers as Job Machine Limit Listed Workers for the Job whose ID matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Set Job Machine Limit Allow List or Deny List Flag¶
Sets Job Machine Limit Allow List Flag for the Job with the ID that matches the provided ID.
The flag controls whether the Job’s machine limit uses a Worker allow list or deny list.
A value of true indicates an allow list, and the Workers in the list are the only Workers allowed to dequeue tasks for the Job.
A value of false indicates a deny list, and Workers in the list are not allowed to dequeue tasks for the Job.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Set Job Machine Limit¶
Sets Job Machine Limit Maximum for the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Set Job Frame Range¶
Sets the frame range for the Job with the ID that matches the provided ID.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Append Job Frame Range¶
Appends frames to the Job with the ID that matches the provided ID.
This adds new tasks without affecting the Job’s existing tasks.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Submit Job¶
Submits a Job using the Job info provided.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
POST |
Message Body: |
|
Response: |
JSON object containing the new Job that was submitted or the Job ID |
Possible Errors: |
|
Delete Jobs¶
Deletes the Job corresponding to the Job ID provided.
URL: |
http://hostname:portnumber/api/jobs?JobID=listOfJobIdsToDelete |
Request Type: |
DELETE |
Message Body: |
N/A |
Response: |
“Success” |
Possible Errors: |
|
Get Job Details¶
Gets the Job Details, similar to the Job Details panel, for the Jobs corresponding to the provided Job IDs.
URL: |
http://hostname:portnumber/api/jobs?JobID=listOfJobIds&Details=true |
Request Type: |
GET |
Message Body: |
N/A |
Response: |
A JSON object containing the Job Details. |
Possible Errors: |
|
Calculate Job Statistics¶
Calculates Job Statistics for the Job corresponding to the provided Job ID.
URL: |
http://hostname:portnumber/api/jobs?JobID=jobId&Statistics=true |
Request Type: |
GET |
Message Body: |
N/A |
Response: |
A JSON object containing the Job Statistics. |
Possible Errors: |
|
Get Deleted Jobs¶
Gets the Deleted Jobs that correspond to the provided Job IDs.
URL: |
http://hostname:portnumber/api/jobs?JobID=listOfJobIds&Deleted=true |
Request Type: |
GET |
Message Body: |
N/A |
Response: |
A JSON object containing the deleted Jobs. |
Possible Errors: |
|
Get All Deleted Jobs¶
Gets all the Deleted Jobs.
URL: |
http://hostname:portnumber/api/jobs?Deleted=true |
Request Type: |
GET |
Message Body: |
N/A |
Response: |
A JSON object containing the deleted Jobs. |
Possible Errors: |
500 Internal Server Error: An exception occurred within the Deadline code. |
Purge Deleted Jobs¶
Purges the Deleted Jobs that correspond to the provided Job IDs.
URL: |
http://hostname:portnumber/api/jobs?JobID=listOfJobIdsToDelete&Purge=true |
Request Type: |
DELETE |
Message Body: |
N/A |
Response: |
“Success” |
Possible Errors: |
|
Undelete Jobs¶
Undeletes the Deleted Jobs that correspond to the provided Job IDs.
URL: |
http://hostname:portnumber/api/jobs |
Request Type: |
PUT |
Message Body: |
|
Response: |
“Success” |
Possible Errors: |
|
Job Property Values¶
Values for some Job properties are represented by numbers. Those properties and their possible values are listed below.
- Stat (Status)
0 = Unknown
1 = Active
2 = Suspended
3 = Completed
4 = Failed
6 = Pending
Note
An active Job can either be idle or rendering. Use the RenderingChunks
property to determine if anything is rendering.
- Timeout (OnTaskTimeout)
0 = Both
1 = Error
2 = Notify
- OnComp (OnJobComplete)
0 = Archive
1 = Delete
2 = Nothing
- Schd (ScheduledType)
0 = None
1 = Once
2 = Daily