Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/luiss811/Backend-Airguide/llms.txt

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

Use this endpoint to create a new AirGuide account. After a successful registration, your account is created with estado: "pendiente" and rol: "alumno". You cannot log in until an administrator approves your account. See the authentication overview for the full account lifecycle.

Endpoint

POST /api/auth/register

Request body

correo
string
required
The email address for your account. Must be unique — registration fails if the email is already in use.
password
string
required
Your account password. Must pass the server-side validation rules defined in the auth validator.
nombre
string
required
Your full name as it will appear in the system.
matricula
string
Your student ID number. Optional, but must be unique if provided — registration fails if the matricula is already registered.

Response

A 201 Created response with the following fields:
message
string
A human-readable confirmation: "Registro exitoso. Tu cuenta está pendiente de validación por un administrador."
usuario
object
The newly created user record.

Example

curl -X POST https://your-api.example.com/api/auth/register \
  -H "Content-Type: application/json" \
  -d '{
    "correo": "estudiante@universidad.edu",
    "password": "MySecurePassword1!",
    "nombre": "María García",
    "matricula": "A12345678"
  }'
Your account is automatically assigned estado: "pendiente" and rol: "alumno". An administrator must validate your account before you can log in. Until then, any login attempt returns 403 Forbidden.

Build docs developers (and LLMs) love