Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/alfonsoolavarria/florilegio/llms.txt

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

Users can personalise their profile by selecting an avatar from the profile page (GET /perfil/). The page renders all available images from static/avatares/ and lets the user pick one. When a selection is made, the chosen image path is sent to this endpoint, which saves it to the avatar_url field on the user’s UserProfile. Sending an empty string clears the avatar and reverts the profile to its default appearance.

POST /api/perfil/avatar/

Updates the avatar URL stored on the authenticated user’s profile. Authentication: Login required (@login_required) Rate limit: 10 requests / hour per user_or_ip Method: POST — JSON body, CSRF token required

Request body

avatar
string
default:""
URL path to the chosen avatar image, e.g. "/static/avatares/avatar1.webp". Passing an empty string ("") clears the current avatar. If the field is omitted entirely, it defaults to an empty string and the avatar is cleared.

Response

Success — HTTP 200
{
  "status": "success",
  "avatar": "/static/avatares/avatar1.webp"
}
The avatar field in the response echoes back exactly the value that was saved to UserProfile.avatar_url.
Avatar images are pre-loaded into static/avatares/ and served as static files. Accepted formats are .webp, .png, .jpg, .jpeg, and .gif. Custom image uploads are not supported — only paths pointing to pre-loaded avatars should be submitted. The full list of available avatars is rendered on the profile page (GET /perfil/).

Example

curl -X POST https://florilegiodelafe.com/api/perfil/avatar/ \
  -H "Content-Type: application/json" \
  -H "X-CSRFToken: <csrf_token>" \
  --cookie "sessionid=<session_cookie>" \
  -d '{"avatar": "/static/avatares/avatar1.webp"}'
To clear the avatar:
curl -X POST https://florilegiodelafe.com/api/perfil/avatar/ \
  -H "Content-Type: application/json" \
  -H "X-CSRFToken: <csrf_token>" \
  --cookie "sessionid=<session_cookie>" \
  -d '{"avatar": ""}'

Build docs developers (and LLMs) love