projects/shared/src/models/auth.model.ts and projects/shared/src/lib/users.service.ts.
Source
auth.model.ts
users.service.ts interfaces
UserRole type
All user accounts are assigned one of the following roles. The role controls what actions and views the user can access.
| Value | Description |
|---|---|
ADMIN | Full administrative access. Can manage users, tickets, configuration, and reports. |
MESA | Help desk agent. Can view and update all tickets in the queue. |
AREA | Area specialist. Typically scoped to tickets assigned to their department area. |
USUARIO | End user / requester. Can submit tickets and query their own ticket status via the public portal. |
AuthUser interface
The authenticated user object embedded in the login response and available throughout the session.
UUID that uniquely identifies the user account.
Email address used to log in.
Display name of the user.
Role assigned to the user. Controls access permissions throughout the application.
Department area associated with the user. Relevant for users with the
AREA role.LoginPayload interface
Send this payload to the login endpoint to authenticate a user.
The user’s registered email address.
The user’s password.
LoginResponse interface
Returned by the authentication endpoint on a successful login.
Bearer token to include in the
Authorization header for subsequent authenticated requests.Token scheme. Always
bearer.The authenticated user’s profile data.
UserDto interface
The full user object returned from the user management API. Use this when listing or displaying user accounts.
UUID that uniquely identifies the user.
User’s email address.
User’s display name.
Assigned role.
Associated department area.
User’s phone number.
Whether the account is currently active. Inactive accounts cannot log in.
UserCreatePayload interface
Use this payload when creating a new user account via the admin API.
Email address for the new account. Must be unique.
Display name for the new user.
Initial password for the account.
Role to assign to the new user.
Department area to associate with the user. Required for users with the
AREA role.Phone number for the user.
UserUpdatePayload interface
Use this payload to update an existing user account. All fields are optional — only include the fields you want to change.
You must be authenticated as an
ADMIN to update other user accounts.New email address for the account.
Updated display name.
New password for the account.
Updated role assignment.
Updated department area association.
Updated phone number.
Set to
false to deactivate the account without deleting it.