URL of a Form



I have created a process. Start --> Human Task (with form and DB connector) --> end

I wish to access this form from an email. In short I need a URL for this form. How can I get this? Do I need to create an API, or can I just access the form? I have read a lot of questions regarding this but I am new to Bonita. So I did not quite understand well how to do this.


2 answers



As Sean said, you have to start the process in the first place. Once the process is started and the human task has been instantiated you can build an url to access the form as described here. However, I'm not sure Bonita allow an anonymous user to access a task form.

Edit : Looks like you can access a form as anonymous user



Submitted by neha.potdar on Thu, 01/21/2016 - 19:41

Right. I tried to create an URL using the using link. Bit is it not for that particular process Id and activity instance? Whenever we run the project they change. How can we still use the link above? I need a permanent link for the form.

Submitted by Quentin Choulet on Fri, 01/22/2016 - 09:21

Yes, it is for a particular instance. You can't have a permanent link. The form is associated with a task and the task is associated with one (and only one) process instance (or activity instance, or case). If you want to access a form you HAVE to specify the instance id.

This id is available in your process as a variable called processInstanceId. Or, if you start the process using one of the API (java or REST), you can get it in the returned value of the function (for java) or the http response (for REST).

Who is going to start your process ? How ? Is someone starting it manually ? Should it be started automatically by another program ? When do you need to send your email ? Who is sending it ?

Submitted by neha.potdar on Tue, 01/26/2016 - 15:17

Thanks for the reply. Regarding the questions in your comment - I have made it simpler now. The form URL will be shared manually with someone. I am not getting into sending it via an email. The process should be started when someone clicks on that link shared. So basically I am guessing I need a Rest API or Java. I went through REST documentation but I still do not get how to start implementing it through Studio or Portal?


Not directly is the answer...

From what I'm reading you have this situation

  • User receives email (where?)
  • User clicks link in email
  • Form opens in browser to enable user to do something
  • User closes form

Is this correct?

If so then you can't get access to the form direct. You have to actually start the process and allow the process to open the form.

You would have to do it using a client program, for example Outlook VBA - executing either REST calls from JavaScript or from VBA.

See the following for thoughts...(for Microsoft products)


The minimum you will have to do in the program is:

  1. REST sign-in, get response
  2. REST start-Process, get response
  3. how you get the form - from your example - to open direct in the browser I'm not sure...can someone else help here?

However it might be easier to use an application:

  1. REST sign-in, get response
  2. Start Browser with Application Page
  3. Application Page then starts the process...

Hope this points you in the right direction


Submitted by neha.potdar on Tue, 01/19/2016 - 19:30

Yes you are right in understanding what I want.

user receives an email --> click a link in email --> opens a Form created in Bonitasoft--> data from the form is stored in a DB --> closes the form.

I went through the links you have shared. But they are not related to Bonitasoft. Do I have to create a REST API? Will this enable me to go to the form directly? Without any authentication.

Can you point me to some examples which are similar to this?


Submitted by Sean McP on Wed, 01/20/2016 - 03:48

No the links I gave are not related to Bonitasoft because what you asking is not about Bonitasoft, you're asking about how to make a link between an email client and Bonitasoft. A totally different thing.

You might have to create a Custom REST API for your needs yes. In this case you could make your link link to the custom API to do the work you want.

No, I don't believe you can go directly to the from, you have to logon and start the process. This is documented in the REST documentation ...

One thing to consider is, who do you want the user, when they click the link, to logon to the REST API as? The User or Anonymous? If the user then you need to pass this information in the link or take it from the client (an api). Anonymous still doesn't work for REST, not sure if it ever will, Bonitasoft haven't yet said so.

Examples? No Sorry I was just pointing you in the right direction...


Submitted by neha.potdar on Thu, 01/21/2016 - 19:44

Great. Thanks a lot for your comment/ answers. I am looking to develop this as a rest API. But do not see many online resources to help me in this. I am trying to do this through Studio. The REST documentation gives an idea how it will work. Where can I start from the Studio working on this?