GET
/
monitoring-alerts
List monitoring alerts
curl --request GET \
  --url https://api.godiligent.ai/monitoring-alerts \
  --header 'X-API-KEY: <api-key>'
{
  "items": [
    {
      "id": "a1b2c3d4",
      "monitoring_id": "d6e3b214-30b1-4401-a1b8-a1bd3c6a84e4",
      "customer_id": "d6e3b214-30b1-4401-a1b8-a1bd3c6a84e4",
      "execution_result_id": "d6e3b214-30b1-4401-a1b8-a1bd3c6a84e4",
      "website": "https://example.com",
      "failed_checks": [
        {
          "check": "non_operational_website",
          "explanation": "No Website Data found",
          "method_used": "",
          "status": "FAILED"
        }
      ],
      "execution_time": "2022-01-01T00:00:00.000Z",
      "created_at": "2022-01-01T00:00:00.000Z",
      "acknowledged_at": "2025-08-01T06:12:47.905Z",
      "external_id": "123456"
    }
  ],
  "unacknowledged_count": 1,
  "next_token": "eyJjdXN0b21lcklkIjp7IlMiOiI2OWRmNWQ4MS0yYjc0LTRmNDItYTQwMS0xM2ViOTZiYTA2MTkifSwiZXhlY3V0aW9uVGltZSI6eyJTIjoiMjAyNS0wNy0zMVQxMjowMTozMC44OTFaIn19"
}

Overview

Retrieve a paginated list of monitoring alerts for the failed monitoring runs. Supports filtering by seen/unseen status and execution time, and provides an unseen alert count.

Request

  • Method: GET
  • Path: /monitoring-alerts
  • Query Parameters: Optional filters and pagination

Query Parameters

  • page_size (integer, optional) - Number of alerts per page
    • Default: 10
    • Range: 1-100
    • Must be a positive integer
  • next_token (string, optional) - Pagination token for next page
  • only_unacknowledged (boolean, optional) - If true, returns only unacknowledged alerts
  • acknowledged (boolean, optional) - If true, returns only acknowledged alerts
  • execution_time_before (ISO8601 string, optional) - Only include alerts executed before this time
  • execution_time_after (ISO8601 string, optional) - Only include alerts executed after this time

Example Request

GET /monitoring-alerts?page_size=20&only_unacknowledged=true

Success Response

  • Status: 200 OK

Response Body

  • items (array) - List of alert objects
    • id (string) - Unique identifier for the alert
    • monitoring_id (string) - ID of the monitoring that triggered this alert
    • customer_id (string) - ID of the customer that owns this monitoring
    • execution_result_id (string) - ID of the execution result
    • website (string) - URL of the monitored website
    • failed_checks (array) - List of checks that failed
      • check (string) - The type of check that failed
      • explanation (string) - Explanation of the failure
      • method_used (string) - Method used for checking
      • status (string) - Status of the check
    • execution_time (string) - ISO8601 timestamp of when the monitoring was executed
    • created_at (string) - ISO8601 timestamp of when the alert was created
    • acknowledged_at (string|null) - ISO8601 timestamp of when the alert was acknowledged, or null if not acknowledged
    • external_id (string, optional) - External reference ID
  • unacknowledged_count (integer) - Number of unacknowledged alerts for the customer
  • next_token (string|null) - Token for next page (null if no more pages)

Example Response

{
  "items": [
    {
      "id": "532ebbd3-269d-4c8f-b73b-2269eb83f1ae",
      "monitoring_id": "c3853e7e-46dc-4c1f-afb4-028b3bdfce19",
      "customer_id": "69df5d81-2b74-4f42-a401-13eb96ba0619",
      "execution_result_id": "e79a2fe0-041f-4357-8b3b-43aa8410ab0b",
      "website": "https://dokanstore-sa.com/",
      "failed_checks": [
        {
          "check": "non_operational_website",
          "explanation": "No Website Data found",
          "method_used": "",
          "status": "FAILED"
        }
      ],
      "execution_time": "2025-06-20T18:25:51.409Z",
      "created_at": "2025-06-20T20:45:48.460Z",
      "acknowledged_at": null,
      "external_id": "cb7f0fab-38b7-4043-bd7f-5976ed4b5e19"
    },
    {
      "id": "f085ca1e-8079-4a6c-8b1d-c17796c0aff5",
      "monitoring_id": "288888fc-b5b4-4131-bac8-d45c33e9e32b",
      "customer_id": "69df5d81-2b74-4f42-a401-13eb96ba0619",
      "execution_result_id": "bccc5556-96bf-492a-aa69-09a1faefed15",
      "website": "https://example-02.com/",
      "failed_checks": [
        {
          "check": "non_operational_website",
          "explanation": "No Website Data found",
          "method_used": "",
          "status": "FAILED"
        }
      ],
      "execution_time": "2025-06-20T18:25:45.215Z",
      "created_at": "2025-06-20T20:45:48.460Z",
      "acknowledged_at": null,
      "external_id": "cb7f0fab-38b7-4043-bd7f-5976ed4b5e19"
    }
  ],
  "unacknowledged_count": 2,
  "next_token": null
}

Error Handling

  • 400 Bad Request
    • Invalid query parameter values
    • Example: { "error": "page_size must be a positive integer between 1 and 100" }
  • 401 Unauthorized
    • Missing or invalid customer authentication
  • 500 Internal Server Error
    • Unexpected server error

Pagination

The API uses cursor-based pagination with Base64-encoded tokens:
  1. First request: Don’t include next_token
  2. Subsequent requests: Use the next_token from the previous response
  3. Last page: next_token will be null

Authorizations

X-API-KEY
string
header
required

Query Parameters

page_size
integer
default:10

Number of alerts per page (1-100, default 10)

Required range: 1 <= x <= 100
next_token
string

Pagination token for next page (Base64-encoded)

only_unacknowledged
enum<string>

If 'true', returns only unacknowledged alerts

Available options:
true,
false
acknowledged
enum<string>

If 'true', returns only acknowledged alerts

Available options:
true,
false
execution_time_before
string<date-time>

Only include alerts executed before this time (ISO8601)

execution_time_after
string<date-time>

Only include alerts executed after this time (ISO8601)

Response

200
application/json

OK

The response is of type object.