Build forms with Modeler
Overview
The Camunda Forms feature allows you to easily design and configure forms. Once configured, they can be connected to a user task or start event to implement a task form in your application.
After deploying a diagram with a linked form, Tasklist imports this form schema and uses it to render the form on every task assigned to it.
Quickstart
Create new form
To start building a form, log in to your Camunda 8 account, and take the following steps:
- In Camunda Hub, open a workspace.
- In the workspace, create or open a project.
- In the project, click Create new > Form.
If using Desktop Modeler, under Create a new file, click Form.
Rename your form
Now you can start to build your form by dragging elements from the palette to the canvas, or by using the AI Form Generator at the bottom of the palette. For the purpose of this guide, we'll build a form from scratch.
Right after creating your form, rename it:
- In the top breadcrumb navigation, next to New form, click the vertical ellipsis menu.
- Click Rename.
- Enter
email-form. - Click Rename.
In this example, we'll build a form to help with a task in obtaining an email message.
Build your form
Within Forms, can add text fields, numerical values, checkboxes, radio elements, selection menus, text components, and buttons.
- From the Components palette on the left, drag and drop a Text area under Form definition.
- Select the Text area.
- In the properties panel on the right, open the General section.
- Provide the following data:
- Field label: "Email content"
- Field description: "The content of the email message"
Refer to the camunda forms reference to explore all form elements and configuration options in detail.
Save your form
To save your form in Camunda 8, you don't have to do anything. Camunda Hub autosaves every change you make.
Link your form to a BPMN diagram
Implement a task form into a diagram. In tandem, link your form to a user task or start event:
- In the same workspace that contains your form, open any project. This does not have to be the same project where you saved the form.
- In the project, select the diagram where you'd like to apply your form.
- Select the user task requiring the help of a form.
- In the floating menu, select the Link form icon.
- Navigate to the form you want to link and click Link.
When using Camunda Forms, any submit button present in the form schema is hidden so we can control when a user can complete a task.
Deploy a form
To deploy your latest form changes:
- Open the form.
- At the top right of the form editor, click Deploy.
- Select a stage and, optionally, a tenant ID.
- Choose whether to deploy All resources or Only this resource (the form).
- Click Deploy.
Deploy your diagram and start an instance
To execute your process diagram, click Deploy & run.
To avoid incidents:
- When deploying a project, if the links between resources are configured with the 'deployment' binding, the BPMN diagrams and their forms must be deployed together.
- When deploying a BPMN file separately, and linking resources using the 'latest' binding, ensure the forms are deployed beforehand.
You can now monitor your instances in Operate.
You have full control over when a form is deployed.
When deploying a project:
- If the form is saved in the project you're deploying, the form will be included in the deployment.
- If the form is saved in another project, you need to deploy it separately.
When deploying a diagram, not the form:
- If the form is saved in the same project as the diagram and you choose to deploy All resources, the form will be included in the deployment.
- If the form is saved in the same project as the diagram and you choose to deploy Only this resource, you need to deploy the form separately.
- If the form is saved in another project, you need to deploy it separately.
As linked forms are resolved to their latest version (unless you change the binding type), make sure the intended form version is available in the target cluster and the binding resolves to that version.
When deploying to a Camunda 8 cluster running a version earlier than 8.4, forms linked to user tasks or none start events will be automatically embedded in the user task to guarantee backwards compatibility.
Read more about the different ways to reference Camunda Forms in the user task forms reference.
To complete a user task, navigate to Tasklist.
Additional resources
Next steps
When building a form for a process, you can also use the Filepicker form component to allow users to upload files. Learn more in building a form for document upload.
You can also use the document preview component to display and allow document download with your form. Learn more in building a form for document preview and download.
Additionally, review the Camunda Academy course on using the AI-assisted form builder.