These endpoints serve the authenticated app experience: fetching full or reduced user profiles, uploading avatar photos through Supabase Storage, retrieving the minimal data needed when posting comments, and reading or writing end-to-end encryption public keys.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Rubick65/calenderyBack/llms.txt
Use this file to discover all available pages before exploring further.
Get user by ID
Returns the completeUserDto for a user by their numeric ID. Requires an authenticated session.
Path parameters
Numeric user ID.
Response 200 OK
Numeric user ID.
Display name.
Email address.
Short bio (max 200 characters).
Hashed password / passphrase.
Profile photo URL.
E2E encryption public key.
Follower count.
Following count.
Whether the account is activated.
List of assigned
Rol objects.Get user by email
Returns the completeUserDto for a user identified by their email address. Requires an authenticated session.
Path parameters
The user’s email address.
Response 200 OK
Same fields as Get user by ID.
Get user profile
Returns a public-facing profile for the given user, including follower and following counts, whether the calling user follows them, and whether a chat already exists between the two. RequiresROLE_USER.
Internally this endpoint dispatches:
GetUserProfileByIdRequest— fetches core profile data.isFollowingRequest— checks whether the caller followsidUsuario.CheckIfChatExistsRequest— checks whether a direct chat exists between the caller andidUsuario.
Query parameters
Numeric ID of the user whose profile to fetch.
Response 200 OK
Display name.
Profile photo URL (signed Supabase URL).
Bio or description.
Total number of followers.
Total number of accounts followed.
true if the authenticated caller is following this user.true if a direct chat already exists between caller and this user.Response
Get upload profile-photo signed URL
Generates a short-lived Supabase Storage signed URL that allows the client toPUT a new profile photo directly into the Avatares bucket. Requires ROLE_USER.
The server:
- Resolves the calling user’s ID from the
Authenticationprincipal. - Constructs a
SupabaseStorageUploadUrlRequestfor theAvataresbucket keyed by the user’s ID. - Returns the pre-signed upload URL.
PUT the image binary directly to that URL — no additional CalenderyBack authentication is needed for the upload itself.
Response 200 OK
Supabase Storage signed upload URL. Valid for a short window; use it immediately.
Response
Get comment author data
Returns the minimal information needed to attribute a comment to the calling user: their profile photo URL and display name. RequiresROLE_USER.
Response 200 OK
Profile photo URL of the authenticated user.
Display name of the authenticated user.
Response
Get a user’s public key
Retrieves the E2E encryption public key stored for any user. RequiresROLE_USER. Typically called before initiating an encrypted message exchange.
Query parameters
Numeric ID of the user whose public key to retrieve.
Response 200 OK
The user’s E2E encryption public key as a string.
Response
Update the caller’s public key
Saves or replaces the E2E encryption public key for the authenticated user. RequiresROLE_USER and ownership (#userId == authentication.principal.idUsuario).
Query parameters
Numeric ID of the user whose public key to update. Must match the authenticated principal.
Request body
The new public key string to store.
Response
| Status | Meaning |
|---|---|
200 OK | Public key saved. Empty body. |
403 Forbidden | userId does not match the authenticated user. |
Check a user’s public key
Verifies that the provided public key string matches the one stored for the given user. RequiresROLE_USER and ownership (#userId == authentication.principal.idUsuario). Useful to detect key rotation or tampering before decrypting received messages.
Query parameters
Numeric ID of the user. Must match the authenticated principal.
The public key value to compare against the stored key.
Response
| Status | Meaning |
|---|---|
200 OK | Keys match. Empty body. |
403 Forbidden | idUsuario does not match the authenticated user. |
4xx | Keys do not match or user not found. |