Skip to Content
Uptimeify Docs

SMTP Monitor Alert-Historie abrufen

Gibt die Benachrichtigungs-/Eskalationsversuche (Alert-Historie) für Vorfälle eines SMTP Monitors zurück.

GET /api/smtp-monitors/:smtpMonitorPublicId/alert-history

Authentifizierung

Erfordert eine gültige Session.

  • Header: Authorization: Bearer <token>

Parameter

  • smtpMonitorPublicId (Pfad, erforderlich): Öffentliche UUID des SMTP Monitors.

Query Parameter

  • page (number, optional): Seite (Default: 1).
  • limit (number, optional): Einträge pro Seite (Default: 25; Max 100). Wird bei format=csv oder download=1 durch die Export-Defaults ersetzt (Default 10000, Max 50000).
  • status (string, optional): sent oder failed.
  • from / to (ISO-Datumsstring, optional): Filter nach sentAt-Bereich.
  • format (string, optional): json (Default) oder csv.
  • download (string, optional): 1 erzwingt einen Attachment-Download, 0 (Default) liefert die Seite.
  • envelope (string, optional): items liefert die Antwort als { items, total, page, perPage }. Ab 18.01.2027 Standard.

Beispiel (cURL)

BASE_URL="https://uptimeify.io"
TOKEN="<dein-api-token>"

curl -X GET "$BASE_URL/api/smtp-monitors/11111111-1111-4111-8111-111111111111/alert-history?envelope=items" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Accept: application/json"

Beispiel-Antwort

{
  "items": [
    {
      "id": 987,
      "incidentId": 123,
      "type": "slack",
      "status": "sent",
      "channelName": "Ops Slack",
      "channelType": "slack",
      "channelConfig": null,
      "sentAt": "2026-02-26T12:11:00.000Z",
      "errorMessage": null
    }
  ],
  "total": 1,
  "page": 1,
  "perPage": 25
}

Listenform: Mit envelope=items kommt die Liste als { items, total, page, perPage } (perPage ist das limit). Ohne den Parameter antwortet der Endpunkt noch in der bisherigen Form { data, total, page, pageCount }; sie ist veraltet, ab dem 18.01.2027 ist { items, ... } der Standard.

Jeder Eintrag ist ein Zustellversuch an einen Benachrichtigungskanal. status ist sent oder failed (bei Fehler ist errorMessage gesetzt); channelType ist der Kanaltyp (z. B. email, slack, opsgenie). Bei channelConfig sind Secrets geschwärzt.

Bei format=csv (oder download=1) ist die Response ein text/csv-Attachment (bzw. application/json bei format=json&download=1) anstelle der paginierten JSON-Antwort oben.

Häufige Fehler

  • 400 SMTP monitor public ID (UUID) required wenn :smtpMonitorPublicId ungültig ist
  • 400 Bad Request (invalidRequestBody) wenn ein Query-Parameter ungültig ist: page/limit keine positive Ganzzahl, format weder json noch csv, download weder 0 noch 1, oder ein unbekannter Wert in status
  • 400 Bad Request (invalidDateRange) wenn from oder to kein Datum ist
  • 401 Unauthorized wenn du nicht angemeldet bist
  • 403 Forbidden wenn du keinen Zugriff auf den Monitor hast

Auf dieser Seite