Appearance
entity-compliance-config schema
One config row for the generic engine-entity.compliance-sweep job — evaluate a rule-engine boolean expression against every row of an entity and flag/escalate offenders.
Pull the full JSON Schema: erp schema pull entity-compliance-config · MCP: erp_get_schema {"name":"entity-compliance-config"}
Top-level properties
| Property | Type | Required | Notes |
|---|---|---|---|
compliance_code | string | yes | Stable identifier / natural key for idempotent seeding. |
source_entity | string | yes | Entity evaluated row-by-row. |
status_field | string | ||
when_status_in | string | Optional comma-separated status pre-filter. | |
filter_field | string | Optional single-column equality pre-filter. | |
filter_value | string | ||
related_count_entity | string | Optional: count child rows of this entity whose related_count_key_field equals the source row's id, and bind the result as related_count in the expression context. | |
related_count_key_field | string | The FK column on related_count_entity that points back to the source row's id. | |
related_count_status_field | string | ||
related_count_status_in | string | Optional comma-separated status filter for the related count. | |
condition_expr | string | yes | MVEL boolean expression evaluated against each row's fields (+ now, + related_count). Whitelisted functions only (daysBetween, now, etc.). True => apply the outcome. |
set_field | string | Flag outcome: column on the source row to write when the condition is true (idempotent — skipped if already equal to set_value). | |
set_value | string | Flag outcome: value written into set_field. | |
escalation_entity | string | Escalation outcome: create one row in this separate entity per violating source row, deduped by escalation_dedupe_field = source id. | |
escalation_dedupe_field | string | Column on escalation_entity that holds the source row id (used for dedupe). | |
escalation_timestamp_field | string | Optional column on escalation_entity that receives now on create. | |
field_map_json | object | Escalation outcome: {targetField: sourceField} — copies source row values into the new escalation row. | |
escalation_template_json | object | Escalation outcome: static fields set on every created escalation row. | |
seeded_by | string | ||
active | boolean | yes |