> ## Documentation Index
> Fetch the complete documentation index at: https://docs.activeviam.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update the BPMN file

> How to update UserTask definitions in BPMN files to add custom workflow actions for the deprecated Atoti Limits legacy workflows, using workflowTaskActionBeans form properties to link Spring beans

## Update the BPMN file

A `UserTask` in a bpmn file in its simplest form looks as follows:

```xml theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
    <userTask id="editUserTask" name="EDIT" activiti:candidateGroups="MANAGERS,USERS,USER">
      ...
    </userTask>
```

Here we specify:

* the id of the task
* the name of the task
* the user roles (candidate groups) who may execute the task, which is managed by Activiti

To add a custom workflow action, add the following to your `UserTask`:

```xml theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
    <userTask id="editUserTask" name="EDIT" activiti:candidateGroups="MANAGERS,USERS,USER">
      <extensionElements>
        <activiti:formProperty id="workflowTaskActionBeans" type="enum">
          <activiti:value name="approveButtonWorkflowAction"/>
          <activiti:value name="rejectButtonWorkflowAction"/>
        </activiti:formProperty>
      </extensionElements>
    </userTask>
```

where

* the `formProperty` id = **`workflowTaskActionBeans`** tells Atoti Limits that it should pick up the contents of this `formProperty` to resolve one or more
  Spring Beans.

<Note>
  The id must be `workflowTaskActionBeans`, otherwise Atoti Limits will not resolve the tasks.
</Note>

* the `value`’s name tells Atoti Limits the name of the Spring Bean it should resolve.

<Note>
  Take care when selecting the name of the Spring Bean. These must be unique for each action and every other Spring Bean in the application.
  A good naming convention is to prefix/suffix the bean with something unique to the type of bean, for example, `ButtonWorkflowAction`.
</Note>

Now Atoti Limits can find the actions linked to each task. The next step is to [define the actions as Spring Beans](./custom-workflow-action-spring-bean).
