Skip to main content
Alerting & Response/Alert Routing & Policies

ReceivePlatformAlerts

Receive alert notifications from managed platforms (ZStack/ZStone) Auth: HMAC(webhookToken, platformUUID) in query param 'token'.

POST/api/v1/alerting/receive

Operation ID

ReceivePlatformAlerts

Since

1.0.0

Execution Mode

Synchronous

Auth Context

Auth Required

Auth Context

Send these values as request headers when calling this API.

AuthorizationstringRequired

Bearer Token

X-Tenant-IDstring

X-Tenant-ID

Request Inputs

application/json

Body Fields

  • source
    StringRequired

    Source platform identifier

    Example: zstack

  • token
    StringRequired

    HMAC authentication token

    Example: hmac-token-abc123

  • alerts
    ListRequired

    List of alert payloads from the platform

    Example: (nested array)

    • status
      String

      Alert status: firing or resolved

      Example: firing

    • fingerprint
      String

      Unique fingerprint for deduplication

      Example: abc123def456

    • generatorURL
      String

      URL to the alert source in the generator system

      Example: http://prometheus:9090/graph?g0.expr=up

    • labels
      LinkedHashMap

      Key-value labels attached to this resource

      Example: (nested object)

    • annotations
      LinkedHashMap

      Arbitrary key-value annotations for metadata

      Example: (nested object)

    • startsAt
      String

      ISO 8601 timestamp when the alert started firing

      Example: 2024-01-15T09:30:00Z

    • endsAt
      String

      ISO 8601 timestamp when the alert was resolved

      Example: 2024-01-15T10:00:00Z

  • commonLabels
    LinkedHashMapRequired

    Labels common to all alerts in this group

    Example: (nested object)

Responses

200 OK
200 OK

On success, this API returns the following response structure.

  • received
    Integer

    Number of alerts received in the payload

    Example: 5

  • created
    Integer

    Number of new alerts created

    Example: 3

  • updated
    Integer

    Number of existing alerts updated

    Example: 1

  • skipped
    Integer

    Number of duplicate alerts skipped

    Example: 1

  • injected
    Integer

    Number of alerts injected into the pipeline

    Example: 4

  • fallback
    Boolean

    Whether fallback processing was used

    Example: false

  • fallbackReason
    String

    Reason for fallback if applicable

    Example: primary channel unavailable

  • Change Time

    AddedRequest body fields generatorURLDeletedRequest body fields generatorUrl
    View API