

- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
Alfresco provides different BPM engines:
- Alfresco Embedded Activiti Engine for ACS, that is integrated with the Alfresco Repository service. There is UI support using Share web application, but ADF applications (like ACA and ADW) are not supporting this engine. It's available for both Community and Enterprise versions of ACS.
- Alfresco Process Services (APS) is an additional product that provides an AngularJS UI working with an independent Activiti Engine. It may be integrated with ACS to read, modify or create documents in the Repository. This product is Enteprise and it requires licensing.
- Alfresco Process Automation (APA) is a Cloud Native BPM engine that is only available via PaaS and requires subscription.
Alfresco Embedded Activiti Engine
Workflow definitions, using BPMN standard notation, are deployed to the Alfresco Repository using different approaches:
- Create a Repository Alfresco addon (JAR or AMP packaging) that includes the process definition and additional resources. Building this kind of addons is described by Jeff Potts on his Alfresco Developer Series Tutorial. Once deployed, the new workflow definition is registered in the workflowBootstrap Spring Bean.
- Upload a XML file with the BPMN definition to Repository > Data Dictionary > Workflow Definitions folder in the Alfresco Repository. Once the property Workflow Deployed of this file is checked, the workflow definition is available in the Repository.
Processes or Workflows are created from workflow definitions by starting a new instance. BPMN activities and variables definitions are taken by users to populate the values and to attach Repository documents (items).
ACS Workflow Development APIs
There is a number of APIs that can be used within the Repository to manage workflow operations.
Java API
- https://docs.alfresco.com/content-services/latest/develop/reference/java-
foundation-ref/#workflowservice - It can be used from Alfresco Repository addons or via JavaScript Console
The following sample list workflow definitions using workflowBootstrap Spring Bean from JavaScript Console.
var context =
Packages.org.springframework.web.context.ContextLoader.getCurrentWebApplicationContext(); var workflowBootstrap =
context.getBean('workflowBootstrap', Packages.org.alfresco.repo.workflow.WorkflowDeployer); logger.log(workflowBootstrap.getWorkflowDefinitions());
Workflow Admin Console
- http://localhost:8080/alfresco/s/admin/admin-workflowconsole
- UI command console that provides different operations for workflow definitions and processes
# Show workflow definitions show definitions all # Show running processes show workflows all # Show running processes for workflow definition activitiAdhoc show workflows 'activiti$activitiAdhoc v1' # Show running paths for process activiti$101 show paths activiti$101 # Get information (values, items, users) from process activiti$101 desc workflow activiti$101 # Show running tasks for process activiti$101 show tasks activiti$101 # Get information (values, items, users) from task activiti$147 desc task activiti$147 # Get all running tasks (COMPLETED state is not working, use REST API v1 for that) query task taskState=IN_PROGRESS
REST API v0
- http://localhost:8080/alfresco/s/index/package/org/alfresco/repository/workflow
- The legacy REST API includes methods to work with workflow definitions, processes (workflow instances) and tasks
/api/workflow-definitions /api/workflow-definitions/{workflowDefinitionId} /api/workflow-definitions/{workflow_definition_id}/workflow-instances /api/workflow-instances /api/workflow-instances/{workflow_instance_id} /api/workflow-instances/{workflow_instance_id}/diagram /api/workflow-instances/{workflow_instance_id}/task-instances /api/workflow/task/end/{taskId} /api/workflow/task/end/{taskId}/{transitionId}
You can even get the diagram representation of a running process, that is not available in any other API.
REST API v1
- http://localhost:8080/api-explorer/?urls.primaryName=Workflow%20API
- The REST API includes methods to work with workflow definitions (process definitions), processes and tasks
http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/deployments http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/process-definitions http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/process-definitions/activitiAdhoc:1:4/image http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/processes http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/processes/460/variables http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/processes/460/items http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/processes/460/tasks http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/tasks/506/candidates
http://localhost:8080/alfresco/api/-default-/public/workflow/versions/1/processes?where=(status=completed)
This is the only API to get workflow definition diagram (using the "image" endpoint) and to get the processes that has been completed (using the where=(status=completed) filter).
Video recording
Additional details are available in the following video recording:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.