Activities
A class's activity calendar (lessons, shifts, practice sessions).
List a class's activities
GET /turmas/{turmaId}/atividades
Access: Requires the capability LER over class (params.turmaId). Success status: 200.
Path parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
turmaId | string (uuid) | yes | Class id. |
Query parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
busca | string | no | to 100 characters | Search text (name or email, depending on the route). |
limite | integer | no | 1…200; default: 50 | How many items per page (1 to 200; the default varies by route, usually 50). |
deslocamento | integer | no | 0…100000; default: 0 | How many items to skip, for paging (up to 100000). |
inativos | "true" | "false" | no | default: "false" | true also includes inactive records. |
de | string | no | ^\d{4}-\d{2}-\d{2}$ | Window start date (YYYY-MM-DD), inclusive. |
ate | string | no | ^\d{4}-\d{2}-\d{2}$ | Window end date (YYYY-MM-DD), inclusive. |
Response
list of AtividadeDto (+ total)
| Field | Type | Required | Constraints | Description |
|---|---|---|---|---|
id | string (uuid) | yes | ||
turmaId | string (uuid) | yes | ||
data | Data | yes | ||
horaInicio | Hora or null | yes | ||
horaFim | Hora or null | yes | ||
atividadeProfissionalId | string (uuid) or null | yes | ||
atividadeProfissionalNome | string or null | yes | Catalog item name (for lists and screens that do not load the catalog). | |
descricao | string or null | yes | ||
observacoes | string or null | yes | ||
local | string or null | yes | ||
obrigatoria | boolean | yes | ||
cancelada | boolean | yes | ||
cercaAtiva | boolean | yes | ||
cercaRaioM | integer or null | yes |
On error: ErroApi model.
Example
curl -X GET "$API/turmas/{turmaId}/atividades" -H "Authorization: Bearer $TOKEN"Create an activity in the class
POST /turmas/{turmaId}/atividades
Access: Requires the capability CADASTRAR over class (params.turmaId). Success status: 201.
Path parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
turmaId | string (uuid) | yes | Class id. |
Request body (AtividadeCriar)
| Field | Type | Required | Constraints | Description |
|---|---|---|---|---|
data | Data | yes | ||
atividadeProfissionalId | string (uuid) or null | no | ||
horaInicio | Hora or null | no | ||
horaFim | Hora or null | no | ||
descricao | string or null | no | to 2000 characters | |
observacoes | string or null | no | to 5000 characters | |
local | string or null | no | to 500 characters | |
obrigatoria | boolean | no | ||
cancelada | boolean | no | ||
cercaAtiva | boolean | no | ||
cercaRaioM | integer or null | no | 10…5000 | |
lat | number or null | no | -90…90 | |
lng | number or null | no | -180…180 |
Response
| Field | Type | Required | Constraints | Description |
|---|---|---|---|---|
id | string (uuid) | yes | ||
turmaId | string (uuid) | yes | ||
data | Data | yes | ||
horaInicio | Hora or null | yes | ||
horaFim | Hora or null | yes | ||
atividadeProfissionalId | string (uuid) or null | yes | ||
atividadeProfissionalNome | string or null | yes | Catalog item name (for lists and screens that do not load the catalog). | |
descricao | string or null | yes | ||
observacoes | string or null | yes | ||
local | string or null | yes | ||
obrigatoria | boolean | yes | ||
cancelada | boolean | yes | ||
cercaAtiva | boolean | yes | ||
cercaRaioM | integer or null | yes |
On error: ErroApi model.
Example
curl -X POST "$API/turmas/{turmaId}/atividades" -H "Authorization: Bearer $TOKEN" -H "Content-Type: application/json" -d '{"data":"2026-03-10"}'Read an activity
GET /turmas/{turmaId}/atividades/{atividadeId}
Access: Requires the capability LER over class (params.turmaId). Success status: 200.
Path parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
atividadeId | string (uuid) | yes | Activity id. | |
turmaId | string (uuid) | yes | Class id. |
Response
| Field | Type | Required | Constraints | Description |
|---|---|---|---|---|
id | string (uuid) | yes | ||
turmaId | string (uuid) | yes | ||
data | Data | yes | ||
horaInicio | Hora or null | yes | ||
horaFim | Hora or null | yes | ||
atividadeProfissionalId | string (uuid) or null | yes | ||
atividadeProfissionalNome | string or null | yes | Catalog item name (for lists and screens that do not load the catalog). | |
descricao | string or null | yes | ||
observacoes | string or null | yes | ||
local | string or null | yes | ||
obrigatoria | boolean | yes | ||
cancelada | boolean | yes | ||
cercaAtiva | boolean | yes | ||
cercaRaioM | integer or null | yes |
On error: ErroApi model.
Example
curl -X GET "$API/turmas/{turmaId}/atividades/{atividadeId}" -H "Authorization: Bearer $TOKEN"Remove an activity (if it has no attendance)
DELETE /turmas/{turmaId}/atividades/{atividadeId}
Only possible while the activity has no attendance; otherwise cancel it instead of removing it.
Access: Requires the capability CADASTRAR over class (params.turmaId). Success status: 204.
Path parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
atividadeId | string (uuid) | yes | Activity id. | |
turmaId | string (uuid) | yes | Class id. |
Response
No response body.
On error: ErroApi model.
Example
curl -X DELETE "$API/turmas/{turmaId}/atividades/{atividadeId}" -H "Authorization: Bearer $TOKEN"Update an activity
PATCH /turmas/{turmaId}/atividades/{atividadeId}
Access: Requires the capability CADASTRAR over class (params.turmaId). Success status: 200.
Path parameters
| Parameter | Type | Required | Constraints | Description |
|---|---|---|---|---|
atividadeId | string (uuid) | yes | Activity id. | |
turmaId | string (uuid) | yes | Class id. |
Request body (AtividadeAtualizar)
| Field | Type | Required | Constraints | Description |
|---|---|---|---|---|
data | Data | no | ||
atividadeProfissionalId | string (uuid) or null | no | ||
horaInicio | Hora or null | no | ||
horaFim | Hora or null | no | ||
descricao | string or null | no | to 2000 characters | |
observacoes | string or null | no | to 5000 characters | |
local | string or null | no | to 500 characters | |
obrigatoria | boolean | no | ||
cancelada | boolean | no | ||
cercaAtiva | boolean | no | ||
cercaRaioM | integer or null | no | 10…5000 | |
lat | number or null | no | -90…90 | |
lng | number or null | no | -180…180 |
Response
| Field | Type | Required | Constraints | Description |
|---|---|---|---|---|
id | string (uuid) | yes | ||
turmaId | string (uuid) | yes | ||
data | Data | yes | ||
horaInicio | Hora or null | yes | ||
horaFim | Hora or null | yes | ||
atividadeProfissionalId | string (uuid) or null | yes | ||
atividadeProfissionalNome | string or null | yes | Catalog item name (for lists and screens that do not load the catalog). | |
descricao | string or null | yes | ||
observacoes | string or null | yes | ||
local | string or null | yes | ||
obrigatoria | boolean | yes | ||
cancelada | boolean | yes | ||
cercaAtiva | boolean | yes | ||
cercaRaioM | integer or null | yes |
On error: ErroApi model.
Example
curl -X PATCH "$API/turmas/{turmaId}/atividades/{atividadeId}" -H "Authorization: Bearer $TOKEN" -H "Content-Type: application/json" -d '{}'