> ## Documentation Index
> Fetch the complete documentation index at: https://docs.blinkops.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Event

This endpoint allows you to post events to the stream.
Tag them, set priority and event aggregate them with other events.

<Warning>
  This action does not support OAuth connections.
</Warning>

<Note>
  External Documentation

  To learn more, visit the [Datadog documentation](https://docs.datadoghq.com/api/latest/events/#post-an-event).
</Note>

## Basic Parameters

<div className="integrations-table">
  | Parameter     | Description                                                                                                                                                                                                                                        |
  | ------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | Alert Type    | If an alert event is enabled, set its type.<br />For example, `error`, `warning`, `info`, `success`, `user_update`,<br />`recommendation`, and `snapshot`.                                                                                         |
  | Date Happened | POSIX timestamp of the event. Must be sent as an integer (i.e. no quotes).<br />Limited to events no older than 7 days.                                                                                                                            |
  | Priority      | The priority of the event. For example, `normal` or `low`.                                                                                                                                                                                         |
  | Text          | The body of the event. Limited to 4000 characters. The text supports markdown.<br />To use markdown in the event text, start the text block with `%%% \n` and end the text block with `\n %%%`.<br />Use `msg_text` with the Datadog Ruby library. |
  | Title         | The event title. Limited to 100 characters. Use `msg_title` with the Datadog Ruby library.                                                                                                                                                         |
</div>

## Advanced Parameters

<div className="integrations-table">
  | Parameter        | Description                                                                                                                                                                                                                                                                     |
  | ---------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | Aggregation Key  | An arbitrary string to use for aggregation. Limited to 100 characters.<br />If you specify a key, all events using that key are grouped together in the Event Stream.                                                                                                           |
  | Device Name      | A device name.                                                                                                                                                                                                                                                                  |
  | Host             | Host name to associate with the event.<br />Any tags associated with the host are also applied to this event.                                                                                                                                                                   |
  | ID               | Integer ID of the event.                                                                                                                                                                                                                                                        |
  | Payload          | Payload of the event.                                                                                                                                                                                                                                                           |
  | Related Event ID | ID of the parent event. Must be sent as an integer (i.e. no quotes).                                                                                                                                                                                                            |
  | Source Type Name | The type of event being posted. Option examples include nagios, hudson, jenkins, my\_apps, chef, puppet, git, bitbucket, etc.<br />A complete list of source attribute values [available here](https://docs.datadoghq.com/integrations/faq/list-of-api-source-attribute-value). |
  | Tags             | A list of tags to apply to the event.                                                                                                                                                                                                                                           |
  | URL              | URL of the event.                                                                                                                                                                                                                                                               |
</div>

## Example Output

```json theme={"dark"}
{
	"status": "<string>",
	"event": {
		"id": 9180796796756298288,
		"id_str": "<string>",
		"title": "<string>",
		"text": "<string>",
		"date_happened": 1662347061,
		"handle": null,
		"priority": null,
		"related_event_id": null,
		"tags": null,
		"url": "<string>"
	}
}
```

## Workflow Library Example

[Create Event with Datadog and Send Results Via Email](https://library.blinkops.com/workflows/create-event-with-datadog-and-send-results-via-email)

<div className="iframe-wrapper">
  <div className="iframe-media">
    <img src="https://mintcdn.com/blinkops-2/ojHYuDeYX5FWuN8a/img/Icons/play-box.svg?fit=max&auto=format&n=ojHYuDeYX5FWuN8a&q=85&s=b8af968e71438a9499c3223c9bd29fb2" alt="Workflow Library" width="16" height="16" data-path="img/Icons/play-box.svg" />

    Preview this Workflow on desktop
  </div>

  <iframe className="iframe" src="https://library.blinkops.com/workflows/create-event-with-datadog-and-send-results-via-email/canvas" />
</div>
