Developer Docs - Helix - Delete Entity
MOVED TO LAVA DOCS
Delete an entity from the database.
Introduction
Familiar with Lava's Entity command for data retrieval? The Delete Entity command extends its capabilities, allowing you to delete data directly from your database.
While the Delete Entity command is a powerful tool, it comes with significant security responsibilities. It's crucial to thoroughly understand and implement the security measures outlined in the following section before integrating this command into your Lava workflows.
The delete entity command allows you to delete a single entity in your database. Below is a very simple example where we are removing a connection request record.
{% assign requestId = 12 %}
{% deleteconnectionrequest id:'{{ requestId }}' %}
{% enddeleteconnectionrequest %}
Pretty cool right?! Let's look at some of the input options at your disposal.
Result Merge Fields
The properties and attributes you wish to modify should be specified within the Lava block. We will explore each of these in detail.
Below is some sample Lava showing error information.
{% if DeleteResult.Success == false %}
{{ DeleteResult.ErrorMessage }}
Validation Messages
{% for message in DeleteResult.ValidationErrors %}
- {{ message.ErrorMessage }}
{% endfor %}
{% endif %}