Residents & users
Admin API patterns for resident and staff users.
Overview
Users cover admins, property managers, staff, and residents. Role is stored in role (admin, property_manager, staff, resident, …). Residents belong to a tenant and link to one or more units.
Endpoints (selected)
| Method | Path | Description |
|---|---|---|
GET | /api/admin/users | List users |
POST | /api/admin/users | Create |
GET | /api/admin/users/:id | Read |
PUT | /api/admin/users/:id | Update |
DELETE | /api/admin/users/:id | Delete |
GET | /api/admin/users/admin-users | Admin/PM accounts |
GET | /api/admin/users/customer-users | Resident accounts |
Auth identifiers
| Field | When populated |
|---|---|
workosUserId | SSO admin users |
clerkUserId | Clerk-authenticated PM / portal users |
password | Bcrypt hash for resident/password login |
Notification preferences
Residents may configure fallback channels:
fallbackCallEnabled— voice call on entry requestfallbackSmsEnabled— SMS with approve/deny linksforwardCallToResident— emergency forwarding path
Phone numbers must be E.164 in phoneNumber when SMS/voice fallbacks are used.
Devices
Each user may register multiple Device rows (push tokens). Use /api/admin/devices to audit or revoke compromised handsets.