Data Model
Database Schema
PostgreSQL database with 10 core tables. All tables use standard timestamps and follow consistent naming conventions.
Tables (10)
| Column | Type |
|---|---|
| id | SERIAL |
| name | VARCHAR(255) |
| type | ENUM |
| parent_id | INTEGER |
| contact_email | VARCHAR(255) |
| is_active | BOOLEAN |
| created_at | TIMESTAMP |
| Column | Type |
|---|---|
| id | SERIAL |
| organization_id | INTEGER |
| VARCHAR(255) | |
| password_hash | VARCHAR(255) |
| first_name | VARCHAR(100) |
| last_name | VARCHAR(100) |
| role | ENUM |
| is_active | BOOLEAN |
| Column | Type |
|---|---|
| id | SERIAL |
| organization_id | INTEGER |
| key_hash | VARCHAR(255) |
| key_prefix | VARCHAR(10) |
| label | VARCHAR(100) |
| is_active | BOOLEAN |
| last_used_at | TIMESTAMP |