User Authentication
Create Session (Login)
Authenticate a user and create a new session.POST /api/auth/session
Request Parameters
Username of the user to authenticate
User’s password
UUID of the facility the user belongs to
Alternative to username - UUID of the user
Authentication token (used with user_id)
Response Fields
Session identifier (always “current”)
Authenticated user’s username
User’s full name
UUID of the user’s facility
Array of user roles/kinds
Whether the user has superuser permissions
Update Session
Update an existing session to keep it alive.PUT /api/auth/session/current
Delete Session (Logout)
End the current user session.DELETE /api/auth/session/current
Facility Users
List Facility Users
Retrieve a list of facility users with filtering and search capabilities.GET /api/auth/facilityuser
Query Parameters
Filter users by collection (classroom or facility) membership
Filter by user type:
learner, coach, admin, superuserSearch by username or full name
Number of results per page
Page number for pagination
Response Fields
User’s unique identifier
User’s username
User’s full name
UUID of the user’s facility
Array of role objects with collection, kind, and id
Whether user has superuser permissions
User’s gender
User’s birth year
ISO 8601 timestamp of when user joined
Get Facility User
Retrieve details of a specific facility user.GET /api/auth/facilityuser/:id
Create Facility User
Create a new facility user.POST /api/auth/facilityuser
Request Parameters
Unique username for the user
User’s full name
User’s password
UUID of the facility
User’s gender
User’s birth year
Update Facility User
Update an existing facility user.PATCH /api/auth/facilityuser/:id
Delete Facility User
Soft delete a facility user (marks as deleted, doesn’t remove from database).DELETE /api/auth/facilityuser/:id
User Sign Up
Sign Up New User
Allow users to self-register if facility settings permit.POST /api/auth/signup
Username Availability
Check Username
Check if a username is available in a facility.POST /api/auth/usernameavailable
Request Parameters
Username to check
Facility UUID to check within
Response
Returnstrue if username is available, or error array if already exists.