I am trying to find the next user task Id, when initiate a process or complete a user task. Please find below the model.
using task graphQL API, I can not do that. Because we can not not fetch task based on process instance Id.
Can you please suggest, how we can do it?
Hello @Waseem_Ahmad ,
this is not directly possible using the GraphQL API.
Instead, you could create a zeebe worker that fetches user tasks by the user task type.
This task will contain information about the process instance that can be mapped in your backend and forwarded to the client.
Jonathan
1 Like
Thanks Jonathan for quick reply, its really helpful.
1 Like
one more query related to UserTasks, I tried to save user task information using zeebe worker, however after doing that taskState is getting set to null, because of that I can not complete that task.
Please see in the above diagram, there is a active task but it is not appearing in task list, because somehow its state is set to null.
While claiming or completing that task getting below error. For creating zeebe worker, I have used GitHub - camunda-community-hub/zeebe-client-csharp: Contains an Zeebe C# client implementation. NuGet package.
“message”: “Cannot invoke “io.camunda.tasklist.entities.TaskState.equals(Object)” because the return value of “io.camunda.tasklist.entities.TaskEntity.getState()” is null”,