Create one or more Job runs in a running Process#
Description#
Create one or more Job runs in a running Process. The Job runs can be added at a specific location in the Process run by specifying either a relative sibling Job run and/or a parent Group run. If neither is specified, the Job runs will be added to the end of the Process’ job run list
POST /processRuns/{processRunId}/jobRuns
Required OAuth Scopes
file:write
Parameters#
Parameter |
In |
Type |
Required |
Description |
|---|---|---|---|---|
X-Version |
header |
string |
true |
Version of the API (2026-04-01.processes.preview) |
processRunId |
path |
string |
true |
Identifier of the process run |
relativeSiblingId |
query |
string |
false |
If present, the job runs will be created relative to this sibling job or group id in the target parent group. |
parentGroupId |
query |
string |
false |
If present, the newly created job runs will be placed in this group. |
before |
query |
string |
false |
If true, new job runs will be inserted before relativeSiblingId. Defaults to true. |
Body parameter example#
[
{
"action": "sendTask",
"arguments": {
"sendTaskArgs": {
"assignee": {
"id": "user123",
"type": "user"
},
"dueDate": "2024-12-15",
"title": "Review Q4 financial report"
},
"type": "sendTask"
},
"triggerType": "whenEligible"
},
{
"action": "contentRequest",
"arguments": {
"contentRequestArgs": {
"approver": {
"id": "manager456",
"type": "user"
},
"assignee": {
"id": "user123",
"type": "user"
},
"document": "doc456",
"instructions": "Please fill out rows 1-10 in the spreadsheet.",
"section": "section-id-123",
"title": "Content Request 1"
},
"type": "contentRequest"
},
"triggerType": "whenEligible"
}
]
Code Samples#
curl -X POST https://api.app.wdesk.com/processRuns/{processRunId}/jobRuns \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {access-token}' \
-H 'X-Version: 2026-04-01.processes.preview'
http POST https://api.app.wdesk.com/processRuns/{processRunId}/jobRuns \
X-Version:2026-04-01.processes.preview \
Content-Type:application/json \
Accept:application/json \
Authorization:"Bearer {access-token}"
wget --method=POST "https://api.app.wdesk.com/processRuns/{processRunId}/jobRuns" \
--output-document - \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Authorization: Bearer {access-token}' \
--header 'X-Version: 2026-04-01.processes.preview'
import requests
headers = {
'X-Version': '2026-04-01.processes.preview',
'Content-Type': 'application/json',
'Accept': 'application/json',
'Authorization': 'Bearer {access-token}'
}
r = requests.post('https://api.app.wdesk.com/processRuns/{processRunId}/jobRuns', headers = headers)
print(r.json())
Returns#
201 - Job runs created successfully#
undefined
400 - Invalid request#
Standard error response returned by the API when a request fails. Provides detailed information about what went wrong including error codes, human-readable messages, and additional context to help diagnose and fix the issue.
401 - Unauthenticated request.#
Standard error response returned by the API when a request fails. Provides detailed information about what went wrong including error codes, human-readable messages, and additional context to help diagnose and fix the issue.
404 - Not found#
Standard error response returned by the API when a request fails. Provides detailed information about what went wrong including error codes, human-readable messages, and additional context to help diagnose and fix the issue.
409 - Collision#
Standard error response returned by the API when a request fails. Provides detailed information about what went wrong including error codes, human-readable messages, and additional context to help diagnose and fix the issue.
429 - Too Many Requests#
Standard error response returned by the API when a request fails. Provides detailed information about what went wrong including error codes, human-readable messages, and additional context to help diagnose and fix the issue.
500 - Server error#
Standard error response returned by the API when a request fails. Provides detailed information about what went wrong including error codes, human-readable messages, and additional context to help diagnose and fix the issue.
Example Responses#
[
{
"action": "sendTask",
"arguments": {
"sendTaskArgs": {
"approver": {
"id": "manager456",
"type": "user"
},
"assignee": {
"id": "user123",
"type": "user"
},
"document": "doc789",
"dueDate": "2024-12-15",
"title": "Review Q4 financial report"
},
"type": "sendTask"
},
"id": "job-new123",
"ordinal": 0,
"parent": "groupinstance-parent-789",
"triggerType": "whenEligible"
}
]
{
"code": "invalidUser",
"documentationUrl": "http://developerdocs.example.com",
"message": "The provided user is invalid.",
"meta": {
"argumentName": "assignee",
"jobId": "job1234"
},
"target": "assignee"
}
{
"code": "Unauthorized",
"message": "Bad credentials"
}
{
"code": "403",
"message": "Forbidden"
}
{
"code": "404",
"message": "Could not find process id 51bcc3ec3d0b4aadb69659e2a7ed767b"
}
resource on the server.
{
"code": "409",
"message": "Letter is not in a status that supports submissions"
}
No example available
{
"code": "429",
"message": "Rate limit of 1000 per 60 seconds exceeded for listJobs requests. Retry request in 10 seconds."
}
No example available
This is a generic error message, meaning the server cannot provide a more specific error code.
{
"code": "500",
"message": "unknown error"
}
No example available
maintenance. This status code implies that the server is functional and understands the request, but it cannot fulfill it at the moment.
{
"code": "503",
"message": "Service Unavailable."
}
No example available