Updates the workflow definition for an envelope
Updates the specified envelope's workflow.
You can use this endpoint to add scheduled sending to a draft envelope. You can also update the scheduled sending for a sent envelope if the scheduled sending countdown is in progress. In that case, the envelope will be reset to a draft state.
You can also add delayed routing to a draft envelope or a sent envelope that has not started workflow processing.
Authorization
OAuth2 OAuth 2.0 access token obtained via Authorization Code Grant or JWT Grant.
In: header
Path Parameters
The external account number (int) or account ID GUID.
The envelope's GUID.
Example: 93be49ab-xxxx-xxxx-xxxx-f752070d71ec
Request Body
application/json
Describes the workflow for an envelope.
The workflowStepId of the current step.
This is not an index into the workflowSteps array in this object.
See the workflowStep object.
The ISO 8601 timestamp of when the envelope is scheduled to be sent, if applicable. Its value is the maximum of the resumeDate property on scheduledSending and the resumeDate property on the current workflowStep.
This property is read-only.
A complex element that specifies the scheduled sending settings for the envelope.
The status of the workflow:
pausedif the workflow is pausedin_progressif the workflow is in progress
An array of workflow steps.
Response Body
application/json
application/json
curl -X PUT "https://example.com/v2.1/accounts/string/envelopes/string/workflow" \ -H "Content-Type: application/json" \ -d '{}'{ "currentWorkflowStepId": "string", "resumeDate": "string", "scheduledSending": { "bulkListId": "string", "resumeDate": "string", "rules": [ { "delay": "string", "resumeDate": "string" } ], "status": "string" }, "workflowStatus": "string", "workflowSteps": [ { "action": "string", "completedDate": "string", "delayedRouting": { "resumeDate": "string", "rules": [ { "delay": "string", "resumeDate": "string" } ], "status": "string" }, "itemId": "string", "recipientRouting": { "rules": { "conditionalRecipients": [ { "conditions": [ { "filters": [ { "operator": "string", "recipientId": "string", "scope": "string", "tabId": "string", "tabLabel": "string", "tabType": "string", "value": "string" } ], "order": "string", "recipientLabel": "string" } ], "order": "string", "recipientGroup": { "groupMessage": "string", "groupName": "string", "recipients": [ { "email": "string", "name": "string", "recipientLabel": "string", "roleName": "string", "signingGroupId": "string" } ] }, "recipientId": "string" } ] } }, "status": "string", "triggeredDate": "string", "triggerOnItem": "string", "workflowStepId": "string" } ]}Delete the workflow definition for an envelope DELETE
Deletes the specified envelope's workflow definition if it has one. **Note:** If the envelope was scheduled to be sent, this endpoint will cancel the scheduled send and the envelope status will be reset to `created`. To resend the envelope, call the update the status to `sent` with the [Envelopes::Update](https://developers.docusign.com/docs/esign-rest-api/reference/envelopes/envelopes/update/) method.
Returns the scheduled sending rules for an envelope's workflow definition GET
Given a template and a workflow step, returns the scheduled sending rules for that workflow step. **Note:** If the workflow step does not have a scheduled sending object, this method returns a 404.