app.cookie_consent_events
TableRow level security on
Cookie banner decisions, stored server-side as the consent log (Section 14.3 ePrivacy). Strictly necessary cookies need no consent and are not recorded. Append-only; the latest decision per visitor applies.
Primary key: id
| Column | Type | Nullable | Description |
|---|---|---|---|
| id | uuid | No | Primary key, UUID v7. |
| org_id | uuid | Yes | Org whose white-labeled surface showed the banner, or null on platform surfaces (sign-in, marketing site).References app.organizations.id |
| person_id | uuid | Yes | Signed-in person who decided, or null for a visitor.References app.people.id |
| visitor_hash | bytea | No | SHA-256 of the random visitor id the banner cookie holds; the id itself is never stored. |
| functional | boolean | No | Preferences cookies allowed (legal/cookie-policy.md: language, theme, workspace and last-opened org kept for 12 months instead of the visit). |
| analytics | boolean | No | Performance cookies allowed. XOS sets none today; the banner records the choice so a future cookie starts blocked. |
| marketing | boolean | No | Marketing cookies allowed. XOS sets none and never offers them; always false. |
| banner_version | text | No | Version of the banner and Cookie Policy shown. |
| decided_at | timestamp with time zone | No | When the decision was made. Set by the database. |
| created_at | timestamp with time zone | No | When the row was inserted. Set by the database. |
| created_by | uuid | Yes | Person who inserted the row, or null for a platform process. Set by the database.References app.people.id |
| updated_at | timestamp with time zone | No | When the row last changed. Set by the database. |
| updated_by | uuid | Yes | Person who last changed the row, or null for a platform process. Set by the database.References app.people.id |
| deleted_at | timestamp with time zone | Yes | Soft delete time. A row with deleted_at set is ignored by every access helper. |