Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Israel-Perez/Nuxt-Secure/llms.txt

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

GET /api/usuario Returns a paginated list of users joined with their profile name. Results are ordered by id descending, with a fixed page size of 5 records.

Query parameters

page
number
default:"1"
Page number to retrieve. Defaults to 1.
Case-insensitive substring filter applied to strNombreUsuario. Uses SQL ILIKE '%value%'.
idPerfil
number
Filter results to users belonging to the given profile ID.
estado
string
Filter by active status. Pass "true" for active users or "false" for inactive users. Omit to return all users regardless of status.

Response

success
boolean
required
true when the query completes without error.
data
object[]
required
Array of user objects for the requested page.
totalPages
number
required
Total number of pages available given the current filters and a page size of 5.

Error response

When an unexpected server error occurs the handler catches the exception and returns:
500
{
  "success": false,
  "message": "Ocurrió un error al consultar los usuarios."
}

Examples

curl --request GET \
  --url 'https://your-domain.com/api/usuario?page=1&search=admin&idPerfil=1&estado=true' \
  --cookie 'auth_token=<your-jwt>'

Success response

200
{
  "success": true,
  "data": [
    {
      "id": 5,
      "strNombreUsuario": "admin",
      "strCorreo": "admin@example.com",
      "strNumeroCelular": "555-1234",
      "imagenUrl": "https://res.cloudinary.com/demo/image/upload/usuarios_corp/sample.jpg",
      "idEstadoUsuario": true,
      "idPerfil": 1,
      "nombrePerfil": "Administrador"
    }
  ],
  "totalPages": 3
}