Uptimeify Docs

ICMP Monitor aktualisieren

Aktualisiert einen ICMP Monitor. Dieser Endpunkt wird auch genutzt, um den Status zu wechseln.

PATCH /api/icmp-monitors/:icmpMonitorPublicId

Authentifizierung

Erfordert eine gültige Session.

  • Header: Authorization: Bearer <token>

Parameter

  • icmpMonitorPublicId (Pfad, erforderlich): Öffentliche UUID des ICMP Monitors.

Request Body

Alle Felder sind optional.

  • status (optional)
    • Erlaubt: active, maintenance, disabled, paused, inactive
    • Hinweis: paused / inactive werden zu disabled normalisiert.
  • name, hostname, checkInterval, timeoutSeconds (optional)
  • port (optional)
    • Wird von der API akzeptiert, aktuell aber nicht vom ICMP Worker genutzt.
  • allowedCheckCountryCodes (optional)
    • Wird auf Großbuchstaben normalisiert und dedupliziert.
  • icmpConfig (optional)
    • Alias für das gespeicherte config JSON.
  • config (optional)
    • Alternative Möglichkeit, das gleiche gespeicherte config JSON zu aktualisieren.

Hinweis: Read-only Nutzer dürfen nur status ändern (und das Senden anderer Felder führt zu 403).

{
  "status": "maintenance",
  "allowedCheckCountryCodes": ["DE", "US"]
}

Beispiel Konfiguration aktualisieren:

{
  "icmpConfig": {
    "packetSize": 56,
    "count": 3
  }
}

cURL

curl -X PATCH "https://YOUR_DOMAIN/api/icmp-monitors/22222222-2222-4222-8222-222222222222" \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "status": "disabled"
  }'

Response

{
  "id": 123,
  "status": "maintenance",
  "organizationId": 1,
  "customerId": 10,
  "name": "Core Router",
  "hostname": "10.0.0.1",
  "port": null,
  "checkInterval": 30,
  "timeoutSeconds": 30,
  "allowedCheckCountryCodes": ["DE", "US"],
  "notificationPhoneNumber": null,
  "notificationEmail": null,
  "lastCheckedAt": null,
  "createdAt": "2026-02-26T12:00:00.000Z",
  "updatedAt": "2026-02-26T12:05:00.000Z",
  "config": { "packetSize": 56, "count": 3 },
  "icmpConfig": { "packetSize": 56, "count": 3 }
}

Fehler

  • 400 Ungültiger Request Body, ungültiger Status oder ungültiger Hostname
  • 401 Unauthorized
  • 403 Forbidden (z. B. readonly oder global supporter)
  • 404 ICMP Monitor nicht gefunden

Auf dieser Seite