---
title: "queryMonitoringEventsV2"
method: POST
path: "/v2/integrations/{integrationId}/monitoring/events"
tags: ["monitoring", "integrations"]
---

# queryMonitoringEventsV2

`POST /v2/integrations/{integrationId}/monitoring/events`

Query monitoring events from the unified erp_monitoring_v2 table.
Returns all event types (inbound, outbound, file_proxy, etc.) in a single list.
Replaces the separate v1 inbound-events and outbound-events endpoints.

## Path parameters

- `integrationId` string, uuid, required

## Request body

- QueryMonitoringEventsV2Request
  - `use_case_id` string — Filter by use case ID (UUID). Empty string matches "General" events. Special value "__unknown__" matches events whose use_case_id does not belong to any currently configured use case for this integration (excludes "General" events).
  - `use_case_type` 'inbound' | 'outbound' | 'file_proxy' | 'managed_call' | 'secure_proxy' — Filter by use case type (replaces direction)
  - `level` 'success' | 'error' | 'skipped' | 'warning' — Filter by event level
  - `code` string — Filter by taxonomy code (e.g. OAUTH2_TOKEN_FAILURE, HTTP_502)
  - `event_id` string — Filter by trigger/inbound event ID
  - `correlation_id` string — Filter by correlation ID for tracing
  - `from_date` string, date-time — Filter events from this date (inclusive)
  - `to_date` string, date-time — Filter events until this date (inclusive)
  - `limit` integer — Maximum number of results to return
  - `cursor` object — Cursor for pagination (from previous response's next_cursor)
    - `created_at` string, date-time
    - `id` string, uuid

## Response `200`

Monitoring events queried successfully

- object
  - `data` MonitoringEventV2[] — List of monitoring events
    - `id` string, uuid, required — Unique monitoring event ID
    - `org_id` string, required — Organization ID
    - `integration_id` string, required — Integration ID
    - `event_id` string, required — Trigger/inbound event ID (groups related monitoring events)
    - `correlation_id` string — Correlation ID for tracing. Empty when unavailable.
    - `use_case_id` string — Use case ID. Empty for system-level events ("General").
    - `use_case_type` 'inbound' | 'outbound' | 'file_proxy' | 'managed_call' | 'secure_proxy' | '', required — Use case type. Empty for system-level events.
    - `level` 'success' | 'error' | 'skipped' | 'warning', required — Event outcome level
    - `code` string — Taxonomy code (e.g. OAUTH2_TOKEN_FAILURE, HTTP_502). Empty for success.
    - `message` string — Human-readable message. Empty when not applicable.
    - `detail` object, nullable — Event-specific JSON data. Structure determined by `code`.
    - `created_at` string, date-time, required — When the monitoring event was created
  - `next_cursor` object, nullable — Cursor to fetch the next page. Null if no more results.
    - `created_at` string, date-time
    - `id` string, uuid
  - `has_more` boolean — Indicates if more results are available

## Other responses

- `400` — Bad request
- `401` — Unauthorized request
- `404` — Resource not found
- `500` — Internal Server Error

---

[API](https://skmtc.net/epilot/apis/integration-toolkit-api.md) · [All operations](https://skmtc.net/epilot/apis/integration-toolkit-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/epilot/integration-toolkit-api/versions/c24837d75096/schema)
