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

# Incident.io 集成

> 将 Incident.io 连接到 Devin，通过 Incident.io 的告警和事件触发自动化和 Devin Oncall。

连接 Incident.io 后，一旦有告警触发或新事件创建，Devin 即可立即开始工作。Incident.io 的告警和事件会触发 Devin [自动化](https://docs.devinenterprise.com/zh/product-guides/automations.md)和 [Devin Oncall](https://docs.devinenterprise.com/zh/product-guides/devin-oncall.md)。

## 设置集成

1. 在 Incident.io 中创建一个可以查看数据的 API 密钥。添加 “create and manage on-call resources” 权限，以便 Devin 将其发现项作为笔记发布到告警中；如果你需要路由私有事件，还需添加 “act in private incidents” 权限。
2. 在 Devin 中，前往 [设置 > 连接 > Incident.io](https://app.devin.ai/settings/connections/incident-io)，点击 “连接”，然后粘贴该密钥。
3. 在 **Webhook** 部分中复制 webhook URL。
4. 在 Incident.io 中，前往 **Settings > Webhooks**，使用该 URL 创建一个 webhook，并订阅 **Webhook** 部分中列出的事件。
5. 将该 webhook 的签名密钥粘贴到 Devin 中，然后点击 “保存”。

> [!NOTE]
>
> 断开连接后，将不再接收告警和事件通知。重新连接会生成新的 webhook URL，因此需要在 Incident.io 中重新配置 webhook。

## 从 Incident.io 触发 Devin

在[自动化](https://docs.devinenterprise.com/zh/product-guides/automations.md)中添加触发器，选择 **Incident.io**，然后选择一个事件：

| 事件 | 条件 |
| - | - |
| 事件已创建、状态已更改、严重程度已更改、跟进事项已创建 | 团队、严重程度、状态、事件类型 |
| 告警已创建、告警已解决 | 告警来源、告警优先级、标题 |

除非开启 **Include private alerts** 或 **Include private incidents**，否则私有告警和私有事件始终不会被匹配。只有 Incident.io 管理员或所有者才能开启这些选项。

> [!NOTE]
>
> 要保存 Incident.io 触发器，您的 Devin 邮箱必须属于已连接的 Incident.io workspace 中的某个用户。

## Devin Oncall

* **响应器**负责调查 Incident.io 的告警或事件。请参阅[触发条件](https://docs.devinenterprise.com/zh/product-guides/devin-oncall.md#triggers)。
* **事件**从 Incident.io 创建的 Slack 频道中发起。请参阅[事件](https://docs.devinenterprise.com/zh/product-guides/devin-oncall.md#incidents)。


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.