I am completely new to Camunda and to this library, but I try to submit a form to complete a user task like that:
await camunda.UserTasks[taskInfo.Id]
.SubmitForm(new Camunda.Api.Client.UserTask.CompleteTask { Variables = variables, WithVariablesInReturn = true });
Given the WithVariablesInReturn propertty on CompleteTask, I would expect that .SubmitForm() should return the updated variables.
The same way as ProcessDefinitionResource.StartProcessInstance() does.
But .SubmitForm() returns a Task instead.
Am I missing something?
While trying to workaround this, I have managed to get the variables myself like so:
var resultVariable = await camunda.ProcessInstances[instanceInfo.Id].Variables.Get("result", false);
var result = JsonSerializer.Deserialize<Result>(resultVariable.Value as string, new JsonSerializerOptions { PropertyNameCaseInsensitive = true });
I am completely new to Camunda and to this library, but I try to submit a form to complete a user task like that:
Given the
WithVariablesInReturnpropertty onCompleteTask, I would expect that.SubmitForm()should return the updated variables.The same way as
ProcessDefinitionResource.StartProcessInstance()does.But
.SubmitForm()returns aTaskinstead.Am I missing something?
While trying to workaround this, I have managed to get the variables myself like so: