Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/EricMartinez758/corpointa-frontend/llms.txt

Use this file to discover all available pages before exploring further.

User management gives administrators full control over who can access Corpointa and what they can do. From the /usuarios route, admins can view all accounts, create new users, reset passwords, toggle active status, and monitor when each person last accessed the system. Users authenticate with their cédula and contraseña — there are no email-based logins.
The Users module is restricted to administrator-level accounts. Standard users can manage their own profile and password from the Settings page but cannot access this module.

Data Model

Each user record contains the following fields:
FieldTypeConstraintsDescription
id_usuariointegerPrimary key, optional on createUnique numeric identifier for the user
cedulastringRequired, min 1 char, max 30 charsVenezuelan national identity number; used as the login username
nombre1stringRequired, max 50 charsFirst given name
nombre2stringOptional, max 50 charsSecond given name
apellido1stringRequired, max 50 charsFirst (paternal) surname
apellido2stringOptional, max 50 charsSecond (maternal) surname
clavestringMin 6 chars, write-onlyAccount password; never returned in API responses
activobooleanOptionalWhether the account is enabled for login
fecha_creacionstring (ISO 8601)Read-onlyTimestamp when the account was created
ultimo_accesostring (ISO 8601)Read-onlyTimestamp of the user’s most recent login
Passwords are write-only. The clave field is never included in any API response. It is only sent to the server on account creation or a password update. Never attempt to read or display it from the client.

Features

User Table with Last Login

The user list displays the full name, cédula, active status, creation date, and last login timestamp for every account, giving admins a quick activity overview.

Invite / Create Dialog

The New User dialog collects all required fields including the initial password. The clave field enforces a minimum of 6 characters at the form level.

Activate / Deactivate Toggle

Each row includes an activo toggle. Deactivated accounts cannot log in but are preserved in the database so that historical audit entries remain associated with the correct user.

Edit and Delete

Admins can update any user’s personal details or password via the edit dialog. Deleting a user is permanent; deactivation is the preferred approach for former staff.

API Reference

The users API resolves to the /users endpoint (note: the frontend route is /usuarios but the REST resource is /users).

List Users

GET /users
Usuario[]
Returns an array of all user accounts. The clave field is never included in the response.
GET /users
Response
[
  {
    "id_usuario": 3,
    "cedula": "V-12345678",
    "nombre1": "Carlos",
    "nombre2": null,
    "apellido1": "Martínez",
    "apellido2": "López",
    "activo": true,
    "fecha_creacion": "2024-01-15T09:00:00.000Z",
    "ultimo_acceso": "2025-11-06T14:32:10.000Z"
  }
]

Get Single User

GET /users/:id
Usuario
Returns a single user by their id_usuario.
GET /users/3

Create User

POST /users
Usuario
Creates a new user account. The id_usuario, fecha_creacion, and ultimo_acceso fields are managed by the server and must not be sent in the request body. The clave field is required on creation.
POST /users
Content-Type: application/json

{
  "cedula": "V-20789012",
  "nombre1": "María",
  "nombre2": "José",
  "apellido1": "González",
  "apellido2": null,
  "clave": "segura123",
  "activo": true
}

Update User

PUT /users/:id
Usuario
Updates an existing user. Send only the fields you wish to change. Include clave only when performing a password reset.
PUT /users/3
Content-Type: application/json

{
  "activo": false
}

Delete User

DELETE /users/:id
void
Permanently removes a user account.
DELETE /users/3

Field Validation

cedula
string
required
Venezuelan national identity number used as the login credential. Must be at least 1 character and no longer than 30 characters. Include the document prefix, e.g. V-12345678 or E-87654321.
nombre1
string
required
First given name. Required; max 50 characters.
apellido1
string
required
First (paternal) surname. Required; max 50 characters.
clave
string
Account password. Must be at least 6 characters. Required on create; optional on update (omit to leave the password unchanged). Never returned in any response.
nombre2
string
Second given name. Optional; max 50 characters.
apellido2
string
Second (maternal) surname. Optional; max 50 characters.
activo
boolean
Account enabled state. Set to false to prevent the user from logging in without deleting their record.

Build docs developers (and LLMs) love