JSON development

Greetings everyone!
I’m trying to develop a program that uses the JSON that is produced by the flowable modeler, but as i was coding the program, i got to a point where i didn’t know how to code the diferent types of BPMN gateways, since the JSON does not have any information regarding them and how to see which is which. Can i get a helping hand, or am i missing something?

Hi,

Can’t you use json’s stencil.id:

 "stencil": {
        "id": "EventGateway"
      },
...
"stencil": {
        "id": "InclusiveGateway"
      },
...
"stencil": {
        "id": "ParallelGateway"
      },
...
"stencil": {
        "id": "ExclusiveGateway"
      },

Martin

My problem is that we’re using the “{{url}}/repository/process-definitions/:id/model” endpoint from your rest api, and not your front end itself, can i have access to that stencil id from here?

The problem is that default json serializer is used to transform BpmnModel to Json. That’s why types are omitted.

Model rest API can provide you content from modeler.