The get profile endpoint returns the complete profile record for the user identified by the Bearer token in the request. The user object is attached to the request by the authentication middleware after the token is verified, and is returned directly without an additional database query. This endpoint exposes all stored profile fields, including the user’s role and account creation timestamp.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/floriansalvi/HEIG-VD_Ocha-api/llms.txt
Use this file to discover all available pages before exploring further.
This endpoint requires a valid JWT token. Include it as
Authorization: Bearer <token> in the request headers. Requests without a valid token are rejected with 401 Unauthorized.GET Path: /api/v1/users
Request
No request body or query parameters are required. Authentication is provided via theAuthorization header.
Response — 200 OK
The full profile object for the authenticated user.
Error codes
| Status | Meaning | Cause |
|---|---|---|
401 Unauthorized | Missing or invalid token | No Authorization header was sent, or the token is expired or malformed |