Skip to navigation

Create a workflow

Creates a workflow. Its run keys cannot be the run keys of another workflow of the account, as an event would then count in both.

Authentication

AuthorizationBearer
API Key authentication using Bearer token

Headers

Paid-BetaenumRequired

This endpoint is in the workflows=v1 beta. Send this header to use it.

Allowed values:

Request

Body
namestringRequired1-255 characters
The workflow's name, as value receipts show it.
runKeyslist of stringsRequired

The event data fields whose values identify one run of the workflow, such as thread_ref. An event belongs to the workflow when it carries all of them, and their values are the run’s ID. Letters, digits and underscores only, without a dot. Set at creation and never changed: to use other run keys, delete the workflow and create a new one.

completionEventNamestring or nullOptional1-128 characters

The event that marks one run of the workflow as complete, such as offer_workflow_completed, or null.

runNameFieldstring or nullOptional1-512 characters

The event data field whose value names each run, such as candidate_name. A run takes the newest non-blank value among its events. Null names a run by its run noun and run ID.

runNounstring or nullOptional1-40 characters

Your word for one run, in the singular, such as candidate. Null shows runs as runs.

Response

201
idstring
The workflow's ID.
objectenum

The type of object. Always workflow.

Allowed values:
createdAtdatetime
When the object was created.
completionEventNamestring or null

The event that marks one run of the workflow as complete, such as offer_workflow_completed, or null.

livemodeboolean

true for an object on a live account, false on a test account.

namestring
The workflow's name, as value receipts show it.
runKeyslist of strings

The event data fields whose values identify one run of the workflow, such as thread_ref. An event belongs to the workflow when it carries all of them, and their values are the run’s ID. Letters, digits and underscores only, without a dot. Set at creation and never changed: to use other run keys, delete the workflow and create a new one.

runNameFieldstring or null

The event data field whose value names each run, such as candidate_name. A run takes the newest non-blank value among its events. Null names a run by its run noun and run ID.

runNounstring or null

Your word for one run, in the singular, such as candidate. Null shows runs as runs.

updatedAtdatetime
When the object was last changed.

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
409
Conflict Error
429
Too Many Requests Error
500
Internal Server Error