Skip to content

Retrieve the entry criteria for a workflow.

GET/api/{version}/objects/{documents_or_binders}/{id}/versions/{major_version}/{minor_version}/lifecycle_actions/{name__v}/entry_requirements
NameDescription
Acceptapplication/json (default) or application/xml
NameDescription
{documents_or_binders}Choose to retrieve values for documents or binders.
{id}The document or binder id field value from which to retrieve available user actions.
{major_version}The major version number of the document or binder.
{minor_version}The minor version number of the document or binder.
{name__v}The lifecycle name__v field value from which to retrieve entry criteria. This is retrieved from the Retrieve User Actions request above.
curl -X GET -H "Authorization: {SESSION_ID}" \ https://myvault.veevavault.com/api/v20.1/objects/documents/17/versions/0/1/lifecycle_actions/start_approval__vs/entry_requirements
{ "responseStatus": "SUCCESS", "responseMessage": "Success", "properties": [ { "name": "user_control_multiple__vs", "description": "Approver", "type": [ "ObjectReference" ], "objectTypeReferenced": { "name": "User", "label": "User" }, "required": true, "editable": true, "repeating": true, "scope": "WorkflowActivation" }, { "name": "date_control__vs", "description": "Approval Due Date", "type": [ "Date" ], "required": true, "editable": true, "scope": "WorkflowActivation" } ] }
curl -X GET -H "Authorization: {SESSION_ID}" \ https://myvault.veevavault.com/api/v20.1/objects/documents/17/versions/0/1/lifecycle_actions/approve__vs/entry_requirements
{ "responseStatus": "SUCCESS", "responseMessage": "Success", "properties": [ { "name": "country__v", "description": "Country", "type": [ "ObjectReference" ], "objectTypeReferenced": { "name": "country__v", "label": "Country", "url": "/api/v20.1/metadata/vobjects/country__v", "label_plural": "Countries" }, "required": true, "editable": true, "repeating": true, "scope": "Document", "currentSetting": [ { "name": "00C000000000109", "label": "United States", "value": "/api/v20.1/vobjects/country__v/00C000000000109" } ], "records": "/api/v20.1/vobjects/country__v" } ] }

The example response shows two entry criteria to start the "Start Approval" workflow on this document: user_control_multiple__vs and date_control__vs.

  • You must assign an Approval Due Date and users/groups to the Approver role on the document when initiating the user action.
  • Unlike the response from the next example, the Scope for these fields is set to WorkflowActivation ("scope": "WorkflowActivation").
  • This scope means that you can initiate the user action by including these entry criteria as name-value pairs with the request.

See the Initiate User Action section below for more information.

curl -X GET -H "Authorization: {SESSION_ID}" \ https://myvault.veevavault.com/api/v20.1/objects/documents/17/versions/0/1/lifecycle_actions/start_approval__vs/entry_requirements
{ "responseStatus": "SUCCESS", "responseMessage": "Success", "properties": [ { "name": "user_control_multiple__vs", "description": "Approver", "type": [ "ObjectReference" ], "objectTypeReferenced": { "name": "User", "label": "User" }, "required": true, "editable": true, "repeating": true, "scope": "WorkflowActivation" }, { "name": "date_control__vs", "description": "Approval Due Date", "type": [ "Date" ], "required": true, "editable": true, "scope": "WorkflowActivation" } ] }
curl -X GET -H "Authorization: {SESSION_ID}" \ https://myvault.veevavault.com/api/v20.1/objects/documents/17/versions/0/1/lifecycle_actions/approve__vs/entry_requirements
{ "responseStatus": "SUCCESS", "responseMessage": "Success", "properties": [ { "name": "country__v", "description": "Country", "type": [ "ObjectReference" ], "objectTypeReferenced": { "name": "country__v", "label": "Country", "url": "/api/v20.1/metadata/vobjects/country__v", "label_plural": "Countries" }, "required": true, "editable": true, "repeating": true, "scope": "Document", "currentSetting": [ { "name": "00C000000000109", "label": "United States", "value": "/api/v20.1/vobjects/country__v/00C000000000109" } ], "records": "/api/v20.1/vobjects/country__v" } ] }

The example response shows one entry criteria to change the state of this document from "Draft" to "Approved": country__v.

  • You must assign a value to the Country document field before initiating the user action.
  • Unlike the response from the previous example, the Scope for this field is set to Document ("scope": "Document").
  • This scope means that you must first update this field on the document before initiating the user action.

See the Initiate User Action section below for more information.

The response may include the following metadata elements describing the properties for which values need to be specified: