post
https://{app-url}{}/api/v2/user-events
To add more information to the event use the properties field and add additional data with key-value objects.
Request Arguments
| Argument | Description |
|---|---|
| Title | Required. Event title. |
| Description | (Optional) Description of the event. |
| Category | Required. Name of the predefined category to which the event belongs (e.g., deployments, marketing_campaigns, holidays). If the required category does not exist, create one using the Create Event Category API. |
| Source | Required. Predefined source of the event (e.g., rest_api, Chef, Jenkins). If the required source does not exist, create one using the Create Event Source API. |
| Properties | (Optional) Additional event metadata represented as key-value pairs. Do not include fields already defined as request arguments, such as title, description, or category. Examples: severity: high, publisher: nyt, exchange: rubicon. |
| startDate | Required. Event start time as a Unix epoch timestamp in seconds. |
| endDate | (Optional) Event end time as a Unix epoch timestamp in seconds. |
| Type | (Optional) Event type. Possible values: DISPLAY – display the event only; INFLUENCE – use the event for event correlation; SUPPRESS – suppress specific metrics from an alert; OFFICE_HOURS – pause an alert for the specified period. SUPPRESS and OFFICE_HOURS events can also be used for display and event correlation. This field is required for SUPPRESS and OFFICE_HOURS events. |
| Action | (Optional) Indicates whether the event marks the beginning or end of the specified period. Possible values: START, END. This field is required for SUPPRESS events. |
Note the enhanced validationIf the event type is "OFFICE_HOURS", the event should include both "startDate" and "endDate".
If the event type is "SUPPRESS", the event should either include both "startDate" and "endDate"
OR, Have the "Action" field filled with START or END.
Pro tip - Using suppress eventsSee the examples on the right for the two ways to send suppress events.
As a single event with start and end times, or two events to indicate start and end times.
Response Fields
The response is an object similar to the request, enabling you to verify that the object was created successfully.
200