Skip to content

app.access_scans

TablePartitioned by monthRow level security on

Append-only log of credential scans at zones. The result is decided by the database from the credential and the access grid at the scan time, never by the scanner.

Primary key: id, created_at

Columns of app.access_scans
ColumnTypeNullableDescription
iduuidNoPrimary key, UUID v7.
org_iduuidNoOwning org, derived from app.credentials on insert; never accepted from the caller and never changed.References app.organizations.id
credential_iduuidNoCredential scanned.References app.credentials.id
zone_iduuidNoZone entered.References app.zones.id
scanned_attimestamp with time zoneNoWhen the scan happened, set by the database.
resultapp.scan_resultNoGranted or Denied.
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
deleted_attimestamp with time zoneYesSoft delete time. A row with deleted_at set is ignored by every access helper.
device_scanned_attimestamp with time zoneYesWhen the device scanned, from the device clock; NULL for a scan decided online. scanned_at stays the server time.
offline_resultapp.scan_resultYesWhat the device decided offline from its cached access grid; NULL for a scan decided online. The database result is authoritative.
project_iduuidNoProject of the scanned credential, copied by the database for Compass sync.References app.projects.id