Skip to content

app.incidents

TableRow level security on

Incidents of a project (Incident CAD log). A critical incident cannot be relabeled and closed in one statement, and closing requires sign-off (invariant 22).

Primary key: id

Columns of app.incidents
ColumnTypeNullableDescription
iduuidNoPrimary key, UUID v7.
org_iduuidNoOwning org, derived from app.projects on insert; never accepted from the caller and never changed.References app.organizations.id
project_iduuidNoProject.References app.projects.id
incident_numberbigintNoNumber from the project's display key sequence.
titletextNoWhat happened.
severity_enum_idtextNoSeverity: a row of the canon Incident Severity enumeration; Level 1 - Critical is critical.References xpms.std_enumeration.record_id
zone_iduuidYesZone where it happened.References app.zones.id
occurred_attimestamp with time zoneNoWhen it happened.
reported_byuuidYesReporter, from the session.References app.people.id
incident_stateapp.incident_stateNoIncident state. Changes only through the incident RPCs.
closed_signed_off_byuuidYesPerson who signed off the closure.References app.people.id
deleted_attimestamp with time zoneYesSoft delete time. A row with deleted_at set is ignored by every access helper.
created_attimestamp with time zoneNoWhen the row was inserted. Set by the database.
created_byuuidYesPerson who inserted the row, or null for a platform process. Set by the database.References app.people.id
updated_attimestamp with time zoneNoWhen the row last changed. Set by the database.
updated_byuuidYesPerson who last changed the row, or null for a platform process. Set by the database.References app.people.id
latitudenumeric(9,6)YesLatitude where the incident was reported (WGS 84), when the reporter's device gave one.
longitudenumeric(9,6)YesLongitude where the incident was reported (WGS 84), when the reporter's device gave one.
accuracy_mnumeric(8,1)YesHorizontal accuracy of the location in meters, as the device reported it.
device_reported_attimestamp with time zoneYesWhen the reporter filed the report on the device; differs from created_at when the report was queued offline.