---
title: "Admin: create an alert for an expert"
method: POST
path: "/api/operator-alerts/admin"
tags: ["operator-alerts"]
---

# Admin: create an alert for an expert

`POST /api/operator-alerts/admin`

## Request

- Base URL: `https://api.corabea.it` (the document declares no server; this is the origin it was published from)
- URL: `https://api.corabea.it/api/operator-alerts/admin`
- Auth: HTTP bearer

Opens one alert of an admin-creatable type. The body carries ids only: the server checks they fit the type, resolves the metadata the expert's close needs and composes title and description. Admin only.

## Request body

- OperatorAlertAdminCreateRequest: An alert the admin opens by hand for one expert. Only the ids travel: the server resolves patient, appointment and leave, writes the metadata the expert's close needs, and composes title and description. Which fields are required depends on `type`; see `OperatorAlertAdminCreateService`.
  - `operator_id` string, uuid, required: Expert the alert is for
  - `type` 'modifica_stato_appuntamento' | 'conferma_stato_appuntamento' | 'conferma_stato_grave_paziente' | 'aggiungi_nota_stato_paziente' | 'frequenza_non_rispettata' | 'abbandono_parziale' | 'aggiungi_disponibilita' | 'aggiungi_fasce_orarie' | 'invia_fattura_mensile' | 'correggi_fattura' | 'conferma_riassegnazione_paziente' | 'report_multidisciplinari' | 'conferma_rientro_sostituzione' | 'carica_materiale_cassetta' | 'carica_video_presentazione' | 'sostituisci_video_presentazione' | 'richiesta_cambio_stato_paziente' | 'conferma_partecipazione_mini_equipe' | 'compila_verbale_mini_equipe' | 'compila_report_supervisione' | 'gestisci_andamento_supervisionato', required: Operator alert type constants.
  - `patient_id` string, uuid, nullable: Patient the alert is about (every type but the return one)
  - `appointment_id` string, uuid, nullable: DA_RIPROGRAMMARE appointment (conferma_stato_appuntamento)
  - `requested_status` string, nullable: Manual status the expert must set (richiesta_cambio_stato_paziente)
  - `status_note_id` string, uuid, nullable: The expert's status note on the patient they must rewrite (aggiungi_nota_stato_paziente)
  - `message` string, nullable: Optional note from the admin, appended to the description
  - `is_blocking` boolean, nullable: Force whether this alert can block portal access; defaults from type when omitted
  - `blocking_starts_at` string, date-time, nullable: When the alert should start blocking, in place of the default grace period. Stored as whole hours from creation, rounded up: it blocks at most an hour later, never earlier; a moment already past blocks at once

## Response `200`

Successful Response

- OperatorAlertResponse: Single operator alert row.
  - `id` string, uuid, nullable: Alert UUID
  - `operator_id` string, uuid, nullable: Operator UUID
  - `operator_name` string, nullable: The expert's full name; filled on the paged feed only.
  - `created_at` string, date-time, nullable: Creation timestamp
  - `updated_at` string, date-time, nullable: Last update timestamp
  - `status` string, nullable: Alert status
  - `type` string, nullable: Alert type
  - `title` string, nullable: Alert title
  - `description` string, nullable: Alert description
  - `metadata` union: Alert metadata JSON
    - object
    - unknown[]
      - unknown
  - `availability_progress` object, nullable: Live slot/day requirements for an open availability alert, over its own two-week window.
  - `trend_management` SuperviseeTrendManagement: Priority, deadline and hold of a gestisci_andamento_supervisionato avviso.
    - `supervised_operator_id` string, uuid, required
    - `supervisee_name` string, nullable
    - `priority` integer, required: 1 = Rischio (due in two weeks), 2 = Attenzione (due in a month)
    - `status` string, required: risk or attention
    - `criteria` SuperviseeTrendCriterion[]
      - `key` string, required
      - `label` string, required
    - `due_at` string, date-time, required
    - `is_overdue` boolean
    - `closed_reason` string, nullable: handled, superseded or no_longer_due once closed
    - `suspension` SuperviseeTrendSuspension: The hold on an avviso: why, who set it, and how far the wait has come.
      - `id` string, uuid, required
      - `reason` 'supervisione' | 'feedback_supervisionato' | 'mini_equipe' | 'altro', required: Why a supervisor put a gestisci_andamento_supervisionato alert on hold.
      - `note` string, nullable
      - `suspended_at` string, date-time, required
      - `suspended_by_name` string, nullable
      - `progress` SuperviseeTrendProgress, required: Where the event a hold waits for stands; `label` is ready to show.
        - `kind` string, required: programmata, svolta, da_programmare or in_attesa
        - `label` string, required
        - `at` string, date-time, nullable
  - `closed_at` string, date-time, nullable: Close timestamp
  - `duration_hours` integer, nullable: Alert duration in hours
  - `is_blocking` boolean: Whether this alert can block portal access once its grace period elapses
  - `is_currently_blocking` boolean, required: Whether this alert is blocking access right now (grace period considered)

## Other responses

- `422`: Validation Error

## Changes

- **2026-10-16** `12d5032b075e`: 1 info
  - added the optional property `operator_name` to the response with the `200` status
- **2026-10-10** `3076c10ab932`: 1 info
  - added the new `conferma_partecipazione_mini_equipe` enum value to the request property `type`
- **2026-10-06** `4d74c6bc8ec1`: 2 info
  - added the new `gestisci_andamento_supervisionato` enum value to the request property `type`
  - added the optional property `trend_management` to the response with the `200` status
- **2026-10-01** `6108ff351838`: 1 info
  - added the new `compila_report_supervisione` enum value to the request property `type`
- **2026-09-24** `aeb303ca3f10`: 4 info
  - added the new optional request property `blocking_starts_at`
  - added the new optional request property `status_note_id`
  - added the new `abbandono_parziale` enum value to the request property `type`
  - added the new `frequenza_non_rispettata` enum value to the request property `type`

[Operation history](https://skmtc.dev/corabea/apis/corabea-api/changes/api/operator-alerts/admin/post.md)

---

[API](https://skmtc.dev/corabea/apis/corabea-api.md) · [All operations](https://skmtc.dev/corabea/apis/corabea-api/llms.txt) · [OpenAPI document](https://skmtc.dev/corabea/apis/corabea-api/revisions/d8cdee1d5474?raw)
