diff --git a/config/alfresco/templates/webscripts/org/alfresco/repository/workflow/workflow-instances.get.desc.xml b/config/alfresco/templates/webscripts/org/alfresco/repository/workflow/workflow-instances.get.desc.xml
new file mode 100644
index 0000000000..ac680c6ba3
--- /dev/null
+++ b/config/alfresco/templates/webscripts/org/alfresco/repository/workflow/workflow-instances.get.desc.xml
@@ -0,0 +1,9 @@
+
+ Get Workflow Instance Collection
+ Retrieves all workflow instances, the returned list can be optionally filtered by the state of the workflow instance and by the authority that initiated the workflow instance.
+ /api/workflow-instances?state={state?}&initiator={initiator?}&priority={priority?}
+ /api/workflow-definitions/{workflow_definition_id}/workflow-instances?state={state?}&initiator={initiator?}&date={date?}&priority={priority?}
+
+ user
+ required
+
\ No newline at end of file
diff --git a/config/alfresco/templates/webscripts/org/alfresco/repository/workflow/workflow-instances.get.json.ftl b/config/alfresco/templates/webscripts/org/alfresco/repository/workflow/workflow-instances.get.json.ftl
new file mode 100644
index 0000000000..02facbe967
--- /dev/null
+++ b/config/alfresco/templates/webscripts/org/alfresco/repository/workflow/workflow-instances.get.json.ftl
@@ -0,0 +1,12 @@
+<#-- Workflow Instances collection -->
+
+<#import "task.lib.ftl" as taskLib />
+{
+ "data":
+ [
+ <#list workflowInstances as workflowInstance>
+ <@taskLib.workflowInstanceJSON workflowInstance=workflowInstance />
+ <#if workflowInstance_has_next>,#if>
+ #list>
+ ]
+}
\ No newline at end of file
diff --git a/config/alfresco/web-scripts-application-context.xml b/config/alfresco/web-scripts-application-context.xml
index b522357544..349c7d13f6 100644
--- a/config/alfresco/web-scripts-application-context.xml
+++ b/config/alfresco/web-scripts-application-context.xml
@@ -816,6 +816,11 @@
class="org.alfresco.repo.web.scripts.workflow.WorkflowInstanceGet"
parent="abstractWorkflowWebScript">
+
+
+
diff --git a/source/java/org/alfresco/repo/web/scripts/workflow/WorkflowInstancesGet.java b/source/java/org/alfresco/repo/web/scripts/workflow/WorkflowInstancesGet.java
new file mode 100644
index 0000000000..6815f0a79d
--- /dev/null
+++ b/source/java/org/alfresco/repo/web/scripts/workflow/WorkflowInstancesGet.java
@@ -0,0 +1,195 @@
+/*
+ * Copyright (C) 2005-2010 Alfresco Software Limited.
+ *
+ * This file is part of Alfresco
+ *
+ * Alfresco is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * Alfresco is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with Alfresco. If not, see .
+ */
+package org.alfresco.repo.web.scripts.workflow;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+import org.alfresco.model.ContentModel;
+import org.alfresco.repo.workflow.WorkflowModel;
+import org.alfresco.service.cmr.workflow.WorkflowDefinition;
+import org.alfresco.service.cmr.workflow.WorkflowInstance;
+import org.alfresco.service.cmr.workflow.WorkflowTask;
+import org.springframework.extensions.surf.util.ISO8601DateFormat;
+import org.springframework.extensions.webscripts.Cache;
+import org.springframework.extensions.webscripts.Status;
+import org.springframework.extensions.webscripts.WebScriptRequest;
+
+/**
+ * @author unknown
+ * @since 3.4
+ *
+ */
+public class WorkflowInstancesGet extends AbstractWorkflowWebscript
+{
+
+ public static final String PARAM_STATE = "state";
+ public static final String PARAM_INITIATOR = "initiator";
+ public static final String PARAM_DATE = "date";
+ public static final String PARAM_PRIORITY = "priority";
+ public static final String PARAM_DEFINITION_ID = "workflow_definition_id";
+
+ @Override
+ protected Map buildModel(WorkflowModelBuilder modelBuilder, WebScriptRequest req, Status status, Cache cache)
+ {
+ Map params = req.getServiceMatch().getTemplateVars();
+
+ // get request parameters
+ Map filters = new HashMap(4);
+ filters.put(PARAM_STATE, req.getParameter(PARAM_STATE));
+ filters.put(PARAM_INITIATOR, req.getParameter(PARAM_INITIATOR));
+ filters.put(PARAM_DATE, req.getParameter(PARAM_DATE));
+ filters.put(PARAM_PRIORITY, req.getParameter(PARAM_PRIORITY));
+
+ String workflowDefinitionId = params.get(PARAM_DEFINITION_ID);
+
+ List workflows = new ArrayList();
+
+ if (workflowDefinitionId != null)
+ {
+ // list workflows for specified workflow definition
+ workflows.addAll(workflowService.getWorkflows(workflowDefinitionId));
+ }
+ else
+ {
+ List workflowDefinitions = workflowService.getAllDefinitions();
+
+ // list workflows for all definitions
+ for (WorkflowDefinition workflowDefinition : workflowDefinitions)
+ {
+ workflows.addAll(workflowService.getWorkflows(workflowDefinition.getId()));
+ }
+ }
+
+ // filter result
+ List