Mayur
Mayur

Reputation: 13

How to provide Custom workflow title while starting a workflow programmatically in AEM

I am trying to provide the workflow title which should appear in the "Workflow" column of AEM Inbox, when I start a workflow from the servlet using the method - workflowSession.startWorkflow(1,2,3);

There is no field to provide a title in the Workflow API

I can provide the workflow title when I start a workflow from the create option available under http://localhost:4502/sites.html/content

workflowSession.startWorkflow(wfModel, wfData, metaDataMap);

I should be able to provide my own title which will be displaying under "Workflow" column at http://localhost:4502/aem/inbox.

Upvotes: 1

Views: 497

Answers (1)

Sudheer Donaboina
Sudheer Donaboina

Reputation: 416

In metaDataMap you should be able to provide your custom title.

final Map<String, Object> metaDataMap= new HashMap<>();
//This title will display in the workflow column of inbox items
metaDataMap.put("workflowTitle", "Custom Title for the workflow instance");


Upvotes: 2

Related Questions