Assign a task to group of users

Hi everyone,

I have a requirement where i have to assign a task to candidate users (ie: based on role the task will be assigned to the user whoever having that role). once the task is assigned to lets say from user A to candidate user B i should be able to get the assigned task of candidate user B and show the taskAssigne of the completed task of the user A(ie-> task assigned to whom).

I am able to get the task assinge if the task is assigned to user directly but not for the candidate user.

Could someone help me out please?

Thanks in Advance,
Adithyan

If you are using camunda Java API, you can use like below

execution.getProcessEngineServices().getTaskService().createTaskQuery().taskCandidateUserExpression(candidateUserExpression);

(or)

execution.getProcessEngineServices().getTaskService().createTaskQuery().taskCandidateUser(candidateUser)

If you use REST api, you can refer this taskHadCandidateUser field from this historic-task-query