Uptimeify Docs
OrganisationBerichte

Bericht erstellen

Erstellt eine organisationsweite Berichtskonfiguration. Erfordert einen Tarif mit Organisationsberichten und freies Berichtskontingent.

POST /api/organization/reports

Erstellt einen wiederkehrenden Organisationsbericht. Die Organisation wird aus Ihrer authentifizierten Sitzung oder Ihrem API-Token abgeleitet. Erfordert die Rolle admin der Organisation (API-Tokens gelten als Organisations-Admins). Nur-Lese-Benutzer können keine Berichte erstellen.

Request-Body

FeldTypErforderlichHinweise
namestringja1–200 Zeichen.
enabledbooleanneinStandard true.
frequency"daily" | "weekly" | "monthly"neinStandard monthly.
weekdayinteger 0–6bei weekly0 = Sonntag.
dayOfMonthinteger 1–28bei monthlyAuf 28 begrenzt.
sendHourinteger 0–23neinStandard 2, in timezone.
timezonestringneinIANA-Zeitzone, Standard Europe/Berlin.
scopeMode"all" | "customers" | "tags"neinStandard all.
scopeCustomerIdsinteger[]bei customersMüssen zu Ihrer Organisation gehören.
scopeTagIdsinteger[]bei tagsMüssen zu Ihrer Organisation gehören.
inclusionMode"all" | "problems" | "threshold"neinStandard all.
problemSignalsobjectnein{ incident, downtimeMinutes, sslDaysLt, responseBreach }.
thresholdUptimeLtnumberbei thresholdz. B. 99.9.
thresholdResponseGtinteger (ms)bei threshold
sendWhenEmptybooleannein„Alles in Ordnung"-Bericht senden, wenn keine Website zutrifft. Standard false.
sectionsobjectneinSechs Booleans zum Ein-/Ausschalten der Abschnitte.
monitorTypesstring[]neinWelche Monitor-Typen der Bericht umfasst. Ein oder mehrere aus website, dns, dnsbl, domain, icmp, smtp, ssh, tcp, ftp, imap. Standard: alle 10. Muss mindestens einen Eintrag enthalten.
sectionsByTypeobjectneinAbschnitts-Umschalter pro Typ: { "<monitorType>": { "<sectionKey>": boolean } }. Welche sectionKeys zulässig sind, hängt vom Typ ab — siehe Abschnitts-Schlüssel pro Monitor-Typ unten. Wird ein für seinen Typ unzulässiger Abschnitts-Schlüssel gesendet, schlägt die Anfrage mit 400 Bad Request fehl.
groupByCustomerbooleanneinUntergliedert die Tabelle jedes Monitor-Typs zusätzlich nach Kunde. Standard false.
format"email" | "email_pdf"neinStandard email_pdf.
recipientEmailsstring[]neinEmpfänger auf Agenturseite (max. 50).
recipientUserIdsstring[]neinBenutzer-IDs der Teammitglieder (max. 50).

Abschnitts-Schlüssel pro Monitor-Typ

Monitor-TypZulässige sectionKeys
website, dns, icmp, smtp, ssh, tcp, ftp, imapfleetSummary, worstPerformers, perMonitorTable, incidentLog
website (zusätzlich)sslExpiry
dnsbldnsblStatus
domaindomainExpiry

Beispiel (cURL)

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

curl -X POST "$BASE_URL/api/organization/reports" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Wöchentlicher Ops-Bericht",
    "frequency": "weekly",
    "weekday": 1,
    "scopeMode": "all",
    "inclusionMode": "problems",
    "format": "email_pdf",
    "recipientEmails": ["ops@agentur.io"]
  }'

Antwort

{
  "id": "3f1c9c1e-8d2a-4c7e-9b1a-2d5f6a7b8c90",
  "name": "Wöchentlicher Ops-Bericht",
  "enabled": true,
  "frequency": "weekly",
  "monitorTypes": ["website", "dns", "dnsbl", "domain", "icmp", "smtp", "ssh", "tcp", "ftp", "imap"],
  "sectionsByType": {},
  "groupByCustomer": false,
  "format": "email_pdf",
  "recipientEmails": ["ops@agentur.io"]
}

Häufige Fehler

  • 401 Unauthorized — nicht authentifiziert.
  • 403 Forbidden (forbidden) — kein Organisations-Admin.
  • 400 (invalidReportSchedule) — weekly ohne weekday oder monthly ohne dayOfMonth.
  • 400 (invalidReportScope) — Scope-IDs gehören nicht zu Ihrer Organisation, oder threshold ohne Schwellenwert.
  • 400 Bad Request — ein sectionsByType-Eintrag enthält einen sectionKey, der für seinen Monitor-Typ nicht zulässig ist (siehe Abschnitts-Schlüssel pro Monitor-Typ), oder monitorTypes ist ein leeres Array.

Auf dieser Seite