Skip to content

Data Definition Document: Operations Security

Domain: Operations (maintenance, security, personnel, services) Logical Sub-Domain: Security (Safety & Access) Physical Packages: @sd/mod-operations/security Related Documents: Process Blueprint Context: This document defines the Data Structures for Access Control. Source: packages/modules/operations/src/security/access_schema.ts

0. Entity Relationship Diagram (ERD)

erDiagram
    DIRECTORY_PROFILE ||--o{ ACCESS_LOG : "generates"
    DIRECTORY_PROFILE ||--|| PRESENCE_RECORD : "has_status"
    INCIDENT_REPORT ||--o{ ACCESS_LOG : "may_reference"

    ACCESS_LOG {
        string id PK
        string profileId FK
        enum type "entry, exit, denied"
        enum method "key_fob, manual"
    }

    PRESENCE_RECORD {
        string profileId PK
        enum status "on_site, off_site"
        date entryTime
    }

    INCIDENT_REPORT {
        string id PK
        enum priority "low, critical"
        string location
    }

1. Primary Entities

Entity: AccessLog

An immutable record of movement.

Field Type Required Description
id string Yes Unique ID.
timestamp Timestamp Yes Time of event.
profileId string Yes Link to Registry.
type string Yes entry, exit, denied.
method string Yes key_fob, code, manual_check.
location string Yes e.g. "Main Gate".
authorizedBy string No Guard ID if manual.

Entity: PresenceRecord

Snapshot of current status.

Field Type Required Description
profileId string Yes Key.
status string Yes on_site, off_site.
entryTime Timestamp Yes When they arrived.

Entity: IncidentReport

Security Event.

Field Type Required Description
priority string Yes low, medium, critical.
reportedBy string Yes User ID.
status string Yes open, investigating, closed.

4. Changelog

Date Author Description Reference
2026-01-24 Antigravity Initial creation Implementation Plan