Object - Remove
Type identifier:
object:removeCategory: Object Operations
Description
Removes Records that match filter criteria. Supports querying by any property and removes matching Records along with their relationships. Returns the removed Records for downstream processing.
Input Handles
Handle | Data Type | Required | Description |
|---|---|---|---|
|
| Yes | Initiates the remove operation |
| Varies | Varies | Dynamic handles for filter variables |
Input Handle Details
Variable Handles
Input handles are dynamically generated based on the variables configuration:
- Handle ID: Variable's
idproperty - Type: Defined by the variable's type configuration
Notes:
- Variables are used in filter expressions
- Default variable is
idfor Record ID lookup
Output Handles
Handle | Data Type | Description |
|---|---|---|
|
| Triggered when removal succeeds |
|
| Triggered on any error |
|
| The removed Record(s) with metadata |
Output Handle Details
removed
- Type: Object (if
firstOnly) or Array (if multiple) Includes:
- All Record properties
id: Record IDschemaId: Schema IDcreatedAt: Creation timestampupdatedAt: Last update timestampcreatedById: Creator IDupdatedById: Last updater ID
- Notes: File entries are augmented with Record context
Configuration Options
Property | Type | Required | Default | Description |
|---|---|---|---|---|
|
| Yes |
| Display label for the node |
|
| Yes |
| CUID2 of the Schema to query |
|
| No | ID variable | Variable definitions for filtering |
|
| No | ID equals | Filter criteria for Record selection |
|
| No |
| Return single Record vs array |
|
| No |
| Maximum Records to remove |
|
| No |
| Skip N Records before removing |
|
| No |
| Sort order for selection |
|
| No |
| Property to sort by |
Configuration Details
variables
- Type:
array - Default: Single
idvariable with string type Notes:
- Each variable creates an input handle
- Used to populate filter expressions
- Built-in
spaceIdentityIdalways available
filter
- Type:
object Structure:
{ "path": "propertyName", "type": "property", "value": { "type": "contextValue", "valueId": "variableId" }, "operator": "eq" }- Notes: Supports complex nested filters with AND/OR logic
Behaviour
V2 Execution
The node supports filters, ordering, offset, and limit. Removal is bounded to at most 1000 Records per execution; an omitted limit defaults to 1000 in v2 (the node's configured default remains 1). Offset must be a non-negative integer. A filter may be omitted, in which case the bounded page is removed.
firstOnly changes the shape of the removed output; it does not change how many Records are removed. The default limit of 1 therefore removes one Record unless a different limit is configured. With no matches, removed is null when firstOnly is enabled and an empty array otherwise. Configured filter variables must be connected; an unconnected variable routes to error without removing anything. Expected validation and authorization failures route to error; unexpected infrastructure failures fail the execution.
Error Handling
Scenario | Behaviour |
|---|---|
Schema not found | Sets error result, triggers |
Invalid filter | Triggers |
Unexpected infrastructure error | Fails the execution; it does not emit the |
Examples
Remove by ID
{
"type": "object:remove",
"data": {
"label": "Remove User",
"schemaId": "user-schema-uuid",
"variables": [
{
"id": "id",
"type": { "name": "id", "type": "string", "required": true }
}
],
"filter": {
"path": "id",
"type": "property",
"value": { "type": "contextValue", "valueId": "id" },
"operator": "eq"
},
"firstOnly": true,
"limit": 1
}
}Remove by Status
{
"type": "object:remove",
"data": {
"label": "Remove Expired Orders",
"schemaId": "order-schema-uuid",
"variables": [
{
"id": "status",
"type": { "name": "status", "type": "string", "required": true }
}
],
"filter": {
"path": "status",
"type": "property",
"value": { "type": "contextValue", "valueId": "status" },
"operator": "eq"
},
"firstOnly": false,
"limit": 100
}
}Remove With Complex Filter
{
"type": "object:remove",
"data": {
"label": "Cleanup Old Records",
"schemaId": "log-schema-uuid",
"filter": {
"type": "and",
"filters": [
{
"path": "processed",
"type": "property",
"value": { "type": "literal", "value": true },
"operator": "eq"
},
{
"path": "createdAt",
"type": "property",
"value": { "type": "contextValue", "valueId": "cutoffDate" },
"operator": "lt"
}
]
},
"firstOnly": false,
"order": "asc",
"orderBy": "createdAt"
}
}