Introduction
The following summarizes the operations that can be performed with Workflows. All of them are in the Hermes module except for launching the final workflow step. For more details on the endpoints, see Swagger. There are also a series of advanced operations that can be performed via the Administrative API. To perform these actions, a token is required from a user who has been assigned a role containing the API administration permission (API_ADMIN).
Workflow Validation
Allows validating one or more workflows at a time using their identifiers
This is the call PUT https://{{host}}/gateway/api/v1/task/validate
Bulk Submission
Allows submitting multiple objects of the same subtype for validation.
This is the call POST https://{{host}}/api/v2/common/massiveSubmit/{{objectSubtype}} including in the body the ids of the objects and the role with which the workflows will be launched.
The response will include the ids that completed the operation successfully and those that did not, along with the reason why.
For this endpoint it is highly recommended to include the "x-language" header, since objects always contain translated values and multilanguage values. If it is not included, they will come in the application's default language.
As a way to help avoid having many errors, another endpoint is included that, given a list of ids, returns those that meet the conditions to be submitted; this endpoint is a POST https://{{host}}/api/v2/common/checkSubmit with the list of object ids and their subtype.
Get All Workflows
Allows retrieving a summary of all workflows according to the specified search criteria. If you do not want to filter by one of these criteria, it must be indicated with a null.
Allows retrieving all workflows launched in the system. This is the call:
POST https://{{host}}/gateway/api/admin/hermes/executions
Get a Specific Workflow
Allows retrieving the information related to a specific workflow, including the information of the different steps that make up the workflow, who validated each one, its status, etc.
This is the call:
GET https://{{host}}/gateway/api/admin/hermes/execution/{id}
Deleting a Specific Workflow
This endpoint allows deleting a specific workflow and all information related to it, both in the workflow engine and in Anjana.
DELETE https://{{host}}/gateway /api/admin/hermes/delete/workflow/{id}
Launching the Final Step of a Workflow
This service allows launching the last step of any workflow in the same way that happens when a workflow finishes in Activiti, mainly intended for cases where some desynchronization occurs and the last processes on the objects are not completed.
This is the following call:
PUT https://{{host}}/gateway/api/admin/kerno/workflow/finish/{workflowExecutionId}