06-14-2021 05:52 PM
Real simple, or should be, but how do I start a workflow via REST? I have tried to POST to
/alfresco/service/api/workflow-instances/{workflow-id} /alfresco/service/api/workflow-definitions/{workflow-id}
Both to no avail.
And is ther a better API reference than this:
https://hub.alfresco.com/t5/alfresco-content-services-hub/workflow-rest-api/ba-p/290146
06-15-2021 02:32 AM
Hi,
You should send a POST call to <alfresco-url>/alfresco/api/-default-/public/workflow/versions/1/processes.
If you go to <alfresco-url>/api-explorer, you will see all available endpoints and their explanation. Select "workflow API" from the dropdown at the top.
An example body could be:
{ "processDefinitionKey": "string", "variables": { "bpm_assignee": "string", "bpm_sendEMailNotifications": true, "bpm_workflowPriority": 0 } }
Hope it helps
06-15-2021 02:32 AM
Hi,
You should send a POST call to <alfresco-url>/alfresco/api/-default-/public/workflow/versions/1/processes.
If you go to <alfresco-url>/api-explorer, you will see all available endpoints and their explanation. Select "workflow API" from the dropdown at the top.
An example body could be:
{ "processDefinitionKey": "string", "variables": { "bpm_assignee": "string", "bpm_sendEMailNotifications": true, "bpm_workflowPriority": 0 } }
Hope it helps
06-15-2021 09:46 PM
That worked and I am unblocked so thank you. But I go to the api-exporer, and there is nothing on processes. I do a full text search on "processes" and I get nothing. Nothing on "workflow" either. How is there not one place a developer can go and get all the REST apis?
06-16-2021 06:51 AM
Hi @mangar
Have you tried the public API explorer? Authentication is admin/admin.
06-15-2021 08:57 AM
Hi @mangar
There is the Activiti github examples that might be useful.
HTH,
06-15-2021 12:12 PM
Thanks for the link! I will us that a lot I am sure. but I was after the REST api.
Explore our Alfresco products with the links below. Use labels to filter content by product module.