Skip to main content
Alerting & Response/Alert Routing & Policies
POSTAlertingSince 1.0SynchronousAuth Required

ReceivePlatformAlerts

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

Execution Availability

Try It Out

Submit a mock request using the current auth context and example-driven inputs.

Request Inputs

Body Fields

  • sourceStringRequired

    Source platform identifier

    Example: zstack

  • tokenStringRequired

    HMAC authentication token

    Example: hmac-token-abc123

  • alertsListRequired

    List of alert payloads from the platform

    Example: (nested array)

    • statusString

      Alert status: firing or resolved

      Example: firing

    • fingerprintString

      Unique fingerprint for deduplication

      Example: abc123def456

    • generatorUrlString

      URL to the alert source in the generator system

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

    • labelsLinkedHashMap

      Key-value labels attached to this resource

      Example: (nested object)

    • annotationsLinkedHashMap

      Arbitrary key-value annotations for metadata

      Example: (nested object)

    • startsAtString

      ISO 8601 timestamp when the alert started firing

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

    • endsAtString

      ISO 8601 timestamp when the alert was resolved

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

  • commonLabelsLinkedHashMapRequired

    Labels common to all alerts in this group

    Example: (nested object)

Responses

200 OK

On success, this API returns the following response structure.

  • receivedInteger

    Number of alerts received in the payload

    Example: 5

  • createdInteger

    Number of new alerts created

    Example: 3

  • updatedInteger

    Number of existing alerts updated

    Example: 1

  • skippedInteger

    Number of duplicate alerts skipped

    Example: 1

  • injectedInteger

    Number of alerts injected into the pipeline

    Example: 4

  • fallbackBoolean

    Whether fallback processing was used

    Example: false

  • fallbackReasonString

    Reason for fallback if applicable

    Example: primary channel unavailable

Endpoint

POST/api/v1/alerting/receive

/api/v1/alerting/receive

Operation ID

ReceivePlatformAlerts

Permalink

Request Example

curl -X POST '{host}/api/v1/alerting/receive' -H 'Authorization: Bearer {token}' -H 'Content-Type: application/json' -d '{"source":"zstack","token":"hmac-token-abc123","alerts":"(nested array)","commonLabels":"(nested object)"}'

Response Example

200
{
  "received": 5,
  "created": 3,
  "updated": 1,
  "skipped": 1,
  "injected": 4,
  "fallback": false,
  "fallbackReason": "primary channel unavailable"
}

Change History

This API has no change history records yet.

View all change history