Geek Social — Documentação
API ReferenceEvents

POST /events

Criar um evento

POST/eventsAuth: accessToken

Cria um novo evento para o usuário autenticado.

Request

Body (JSON)

CampoTipoDescrição
title *stringTítulo do evento
descriptionstringDescrição do evento
date *string (ISO 8601)Data e hora do evento
locationstringLocal do evento
isOnlinebooleanSe o evento é online
maxParticipantsnumberNúmero máximo de participantes
coverUrlstringURL da imagem de capa

Response

201

{
  "id": "uuid",
  "title": "string",
  "description": "string | null",
  "date": "ISO 8601",
  "location": "string | null",
  "isOnline": false,
  "maxParticipants": "number | null",
  "coverUrl": "string | null",
  "createdAt": "ISO 8601",
  "ownerId": "uuid"
}

Erros

CódigoDescrição
401Não autenticado

Exemplos

curl -X POST 'https://geeksocialapi.homelab-cloud.com/events' \
  -H 'Authorization: Bearer SEU_ACCESS_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"title":"Game Night","date":"2025-12-01T20:00:00Z","isOnline":true}'
await fetch('https://geeksocialapi.homelab-cloud.com/events', {
  method: 'POST',
  headers: { Authorization: 'Bearer ' + accessToken, 'Content-Type': 'application/json' },
  body: JSON.stringify({"title":"Game Night","date":"2025-12-01T20:00:00Z","isOnline":true}),
})

On this page