FLOW_ExecuteValidationRules.DTO_Request
Class
global inherited sharing class FLOW_ExecuteValidationRules.DTO_RequestRequest DTO for the Execute Validation Rules invocable action. Contains the records to validate and the trigger context for rule evaluation.
Since: 1.0
Fields
| Field | Description |
|---|---|
| global List oldRecords | The previous record values before the change. |
| global List records | The new/current records to validate. |
| global String triggerContext | The trigger operation context that determines which validation rules to execute. |
Field Details
oldRecords
@InvocableVariable(description='The previous record values before the change. Required for BEFORE_UPDATE and AFTER_UPDATE to enable change detection in validation formulas. Leave empty for insert, delete, and undelete operations.' label='Old Records') global List<SObject> oldRecordsType: List
The previous record values before the change. Required for BEFORE_UPDATE and AFTER_UPDATE operations to enable change detection in validation formulas (e.g., ISCHANGED, PRIORVALUE functions). Leave empty for insert, delete, and undelete operations. In Record-Triggered Flows, use {!$Record__Prior} to populate this field.
Since: 1.0
records
@InvocableVariable(required=true description='The new/current records to validate. For insert: the records being created. For update: the records with new values. For delete: the records being deleted.' label='Records') global List<SObject> recordsType: List
The new/current records to validate. For insert operations, these are the records being created. For update operations, these are the records with their new field values. For delete operations, these are the records being deleted. This field is required.
Since: 1.0
triggerContext
@InvocableVariable(description='The trigger operation context matching TriggerOperation enum: BEFORE_INSERT, BEFORE_UPDATE, BEFORE_DELETE, AFTER_INSERT, AFTER_UPDATE, AFTER_DELETE, or AFTER_UNDELETE.' label='Trigger Context') global String triggerContextType: String
The trigger operation context that determines which validation rules to execute. Must match a TriggerOperation enum value: BEFORE_INSERT, BEFORE_UPDATE, BEFORE_DELETE, AFTER_INSERT, AFTER_UPDATE, AFTER_DELETE, or AFTER_UNDELETE. Defaults to BEFORE_INSERT if not specified.
Since: 1.0