Overview
Entity Events run a Flow when certain events occur to an Entity. Entity Events require a Data Structure with a Configuration Folder.
An example of an event could involve the saving and/or deleting of an Entity. A Flow may then run to send a notification message to a manager when a new Entity like a project quote or travel request is submitted or changed, so the manager can do a review. Another use case might be to insert an audit record into a database or directory when an Entity is deleted that records details such as who deleted the Entity.
| Type of Events | Function |
|---|---|
| After Delete Flow | A Flow runs after a 'Delete' is made to the Entity to save the changes. |
| After Save Flow | A Flow runs to save the changes after a flow is changed. |
| Before Delete Flow | A Flow runs before a Delete is made to an Entity to save the data. |
| Before Save Flow | A Flow runs before a save is made to an Entity to save the data. |
Example
To create an Entity Event, first create a Data Structure that will create a Configuration Folder when it is completed. For example, an Entity Data Structure will be used. It will be called "Person will fields:
| Person Entity | |
| Firstname | String |
| Lastname | String |
| DOB | DateTime |
| Age | Int32 |

- Open the Configuration Folder and click on ENTITY EVENTS
- Select an After Save Flow.

- Within this Flow, add the Show Popup step and give the input variables some values.
- Afterwards save and close the Flow.

- Next, create another Flow that will create the Entity records to trigger the Entity Event Flow.
- Find the step to create Entities in USER DEFINED TYPES > ENTITIES > PERSON > Create.
- Then pick a normal Folder to store the values in and set constant values to the user created data members.
- Save and close the Flow.

- Debug the Flow and then the Entity Event Flow will trigger.
