> For the complete documentation index, see [llms.txt](https://docs.work-relay.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.work-relay.com/automations/apex-code/apex-interfaces.md).

# Apex interfaces

There's a number of ways you can invoke a backend manipulation in Work-Relay:

* using out-of-the-box Work-Relay actions in Process builder - so you set them to run in relation to a step being completed;
* same Work-Relay actions, but designed as Global Actions (and even combining a number of actions in a sequence by use of Global Action group) - to call them independently of a Process step (ex. on a Form);
* you can call a Salesforce autolaunched Flow - by using the respective action in a Form, of indirectly by calling it from a Work-Relay action of respective type.

Yet, sometimes you still find that you need to execute Apex code. Often, this is because you would have some legacy Apex (perhaps some method from existing Utility class etc.) that you want to call somewhere in Work-Relay. Across the board, we would leave the way to do this, be it an Action, Rule, or step assignment - you would find the list below.

To be able to call cn Apex class in Work-Relay, you would need to implement a particular interface depending on where you wish to invoke Apex.

<details>

<summary>WR_BPM.WorkflowCallApexActionInterface</summary>

</details>

<details>

<summary>WR_BPM.WorkflowCallApexRuleInterface</summary>

</details>

<details>

<summary>WR_BPM.WorkflowDefineVariableActionInterface</summary>

</details>

<details>

<summary>WR_BPM.WorkflowAssigneeInterface</summary>

</details>

<details>

<summary>WR_BPM.FormBuilderService.FormBuilderApiInterface</summary>

</details>

<details>

<summary>WR_BPM.FunctionInterface</summary>

</details>

<details>

<summary>WR_BPM.FeverChartInterface</summary>

</details>
