0
votes

I'm still pretty new to Camunda.

I would like to illustrate a workflow which can be seen as more than a status flow. This flow should not contain any Java logic but should be controlled via the REST API.

Now I have a problem with the XOR gateway and REST-engine handling (see picture).

Camunda BPM Example

My goal is, if my process instance is waiting at the user task Status 1, that I get information how to proceed. So that if I want to reach the next state I have to specify if test is true or false.

I know that in the body of the complete REST-Call you can give variables and so the path is decided. What I want is that I know in advance which options are available (here: true and false) and can choose one of them.

So to my question: Is there a REST-Call that can tell me at the point Status 1 that I can give either the variable "test": {"value": "true"} or the variable "test": {"value": "false"}?

1

1 Answers

0
votes

Short answer: No. In bpmn, you just know the current element, you cannot look ahead. The options are part of your business logic, so you will have to provide the rest method yourself.

(long answer: using the java BPMN API and some fancy model analysis, this would be possible. But still not advised and error prone.)