# Opsgenie

Create an Opsgenie alert when a Tailcove alert fires and close it when it resolves.

## Set it up

1. In Opsgenie, open **Settings > Integrations**, add an **API** integration and copy its API key.
2. In Tailcove, open an alert or a monitor, switch on **Opsgenie**, pick the region your Opsgenie account is in (United States or Europe) and paste the key.

The key is stored encrypted and never shown again; leave the field blank when you edit to keep it. Tailcove always sends to Opsgenie's own API host for the region you chose.

## What you get

A firing alert or a monitor that goes down creates an Opsgenie alert with the title as its message (cut to Opsgenie's 130 characters), the details as the description, the priority P2 (P3 for a warning), and the tag `tailcove`. Its alias is stable for that alert or monitor (`tailcove-alert-<id>`, `tailcove-monitor-<id>`, where `<id>` is its public id such as `alr_…` or `mon_…`), so repeats do not create duplicates, and the resolved alert or recovered monitor closes the Opsgenie alert by that alias.
