Skip to main content

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 /api/publication/app/getHomePublications

Returns a paginated feed of publications authored by users that the authenticated user follows. Results are ordered according to the Pageable parameters you supply. Auth: ROLE_USER (JWT Bearer token required)

Query Parameters

ParameterTypeDescription
pageintZero-based page index (default 0)
sizeintNumber of items per page (default 20)
sortstringSort expression, e.g. publicationDate.uploadDate,desc

Response — Page<PublicationHomeDto>

Each item in the page content array has the following shape:
FieldTypeDescription
publicationDataPublicationProfileDtoCore publication data (see fields below)
idUsuarioLongID of the publication author
fotoPerfilStringProfile picture URL of the author
nombrePerfilStringDisplay name of the author
PublicationProfileDto fields nested inside publicationData:
FieldTypeDescription
idLongPublication ID
fotoPublicacionStringSupabase signed URL for the media file
mensajeStringText caption of the post
cantidadLikesintTotal like count
cantidadComentariosintTotal comment count
fechaCalendarioLocalDateCalendar date assigned to the post (YYYY-MM-DD)
fechaPublicacionLocalDateTimeWall-clock timestamp when the post was uploaded
likebooleantrue if the authenticated user has liked this publication

Example

curl -X GET \
  "https://api.example.com/api/publication/app/getHomePublications?page=0&size=10&sort=publicationDate.uploadDate,desc" \
  -H "Authorization: Bearer <token>"

GET /api/publication/app/getProfilePosts

Returns a paginated list of publications for a specific user, filtered by a calendar month and year. Use this endpoint to power a user’s profile calendar view. Auth: ROLE_USER (JWT Bearer token required)

Query Parameters

ParameterTypeRequiredDescription
idUsuarioLongID of the user whose posts to retrieve
monthintCalendar month to filter by (112)
yearintCalendar year to filter by (e.g. 2024)
pageintZero-based page index (default 0)
sizeintItems per page (default 20)
sortstringSort expression

Response — Page<PublicationProfileDto>

FieldTypeDescription
idLongPublication ID
fotoPublicacionStringSupabase signed URL for the media file
mensajeStringText caption of the post
cantidadLikesintTotal like count
cantidadComentariosintTotal comment count
fechaCalendarioLocalDateCalendar date assigned to the post (YYYY-MM-DD)
fechaPublicacionLocalDateTimeWall-clock timestamp when the post was uploaded
likebooleantrue if the authenticated user has liked this publication

Example

curl -X GET \
  "https://api.example.com/api/publication/app/getProfilePosts?idUsuario=7&month=8&year=2024&page=0&size=20" \
  -H "Authorization: Bearer <token>"

GET /api/publication/app/getPostUrl

Creates a placeholder Publication record in the database and returns a short-lived Supabase Storage signed upload URL. This is step 1 of the three-step post creation flow — see the Overview for the full walkthrough. Auth: ROLE_USER (JWT Bearer token required)

Response — SignedUrlPostDto

FieldTypeDescription
idPostLongID of the placeholder publication created by this call; pass it to putPublicationData
urlStringShort-lived Supabase Storage signed upload URL; upload the media file directly to this URL

Example

curl -X GET \
  "https://api.example.com/api/publication/app/getPostUrl" \
  -H "Authorization: Bearer <token>"
{
  "idPost": 42,
  "url": "https://<project>.supabase.co/storage/v1/object/sign/publications/uuid.jpg?token=..."
}

PUT /api/publication/app/putPublicationData

Finalises a placeholder publication by attaching its text message, owner, and calendar date. This is step 3 of the three-step post creation flow and must be called after the media file has been uploaded directly to Supabase Storage. Auth: ROLE_USER (JWT Bearer token required)

Request Body — PostDataDto

{
  "idPost": 42,
  "message": "Beautiful sunset hike 🌄",
  "idUsuario": 7,
  "calendarDate": "2024-08-15"
}
FieldTypeRequiredDescription
idPostLongID of the placeholder publication returned by getPostUrl
messageStringText caption to attach to the publication
idUsuarioLongID of the user who owns the publication
calendarDateLocalDateCalendar date to associate with the post (YYYY-MM-DD)

Response

200 OK — empty body.

Example

curl -X PUT \
  "https://api.example.com/api/publication/app/putPublicationData" \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "idPost": 42,
    "message": "Beautiful sunset hike 🌄",
    "idUsuario": 7,
    "calendarDate": "2024-08-15"
  }'

DELETE /api/publication/app/deletePublication

Permanently deletes a publication. The authenticated user must be the owner of the publication — the handler enforces ownership before deletion. Auth: ROLE_USER (JWT Bearer token required)

Query Parameters

ParameterTypeRequiredDescription
idPublicacionLongID of the publication to delete

Response

200 OK — empty body.

Example

curl -X DELETE \
  "https://api.example.com/api/publication/app/deletePublication?idPublicacion=42" \
  -H "Authorization: Bearer <token>"

Build docs developers (and LLMs) love