Retrieve form key of message start event

In Camunda Modeler it is possible to define form data or a form key for all kinds of start events. I’m not sure this is intentional but I find it rather compelling to create a process that has one default blank start event that is used to start the process from the Camunda task list as well as other message start events that I can use via a custom application.

Now I’m wondering how to retrieve the form key that I have defined in the modeler. I’m happy to use the Java API but could only find methods to retrieve the form key of “one” blank start event or for tasks?

Hi @bentrm,

which api method are you referring to exactly?


I was looking at

  • the REST API that offers GET /process-definition/{id}/startForm as well as at
  • the Java APIs FormService which has getStartFormKey and getTaskFormKey.

getStartFormKey only accepts the processDefinitionId as a parameter, so I’m not sure how to retrieve the formKey of a second message start event as it defaults to the form key of the blank start event.

Hi @bentrm,

why would you have a message start event with a form on it? Start forms are intended to be filled out by a user and therefore this is a rather unusual usage. Could you describe your usecase a bit better? with message start event you can just pass variables.

To reply to your question, when model is getting parsed with 2 start events, one blanko and one message, blanko start event is considered as an initial event and is used to return a form key later on.


It would allow to “design” and deploy a form that a custom application may retrieve to trigger a process by messaging the user provided variables.
I understand it’s an unusual request as message events are meant to be triggered programmatically, but this would make it quite easy to implement alternative start sequences in the process definition.

Anyway, I guess it’s an anti-pattern. I just came up with it as it’s possible to fill out the form properties of any start event in Camunda Modeler right now.

I have been exploring this type of usage as well.

I think it starts to encroach into the CMMN space.

If we were to look at something like:

Where the Start Event is used as the parent process to “Start a long running instance”, and you have Message Events in Event-Subprocesses that that append data to the currently running process. There are a few other ways to model this such as using a loop and Event Gateway, but That starts to get messy.

If a Message Start Event could have a self-defined form key it would allow a external system to detect the form that should be filled out to submit that specific message (assuming that the message has a series of variables attached to it.) But again this seems like CMMN would solve this problem, BUT adding CMMN also seems like extra overhead.