---
title: "Webhook 连接器"
description: "Webhook 端点可用于投递的每个平台：各平台的字段、接受的事件，以及需要先在该平台上完成的设置。"
canonical: "https://bird.com/zh-sg/wendang/ai/webhook-connectors"
---

<!-- Code generated by beak gen:webhook-connectors from the connector definitions; DO NOT EDIT. -->

# Webhook 连接器

连接器会按照其平台要求的请求格式投递每个事件，而不是把原始事件发布到你托管的 URL。你可以在[控制台](https://bird.com/dashboard/w/webhooks/new)中设置连接器，也可以使用 `bird webhooks create --connector <id>`，或在[创建 webhook](/docs/api/reference/create-webhook) 时使用 `destination.connector`。Bird 会根据连接器及其字段生成端点的 URL，因此端点本身不需要 `url`。

非机密字段放在 `config` 中，机密字段放在 `credentials` 中。机密值只能写入，任何响应都不会包含它们。如果创建请求缺少连接器需要的字段，或提供了连接器不接受的字段，请求会被拒绝，并列出该连接器的字段。完整操作步骤请参阅[将消息路由到你的 AI 智能体](/docs/ai/route-messages-to-an-agent)。

## Claude Managed Agents

将你收到的每条消息发送给你的 Claude 托管智能体。其 ID 为 `claude_managed_agents`。

它接受 `whatsapp.received`、`sms.received`、`email_mailbox.message_received`、`amb.received`。

| 字段             | 放在          | 必填 | 说明                                                                           |
| ---------------- | ------------- | ---- | ------------------------------------------------------------------------------ |
| `agent_id`       | `config`      | 是   | 创建智能体时返回。会话使用其最新版本。                                         |
| `environment_id` | `config`      | 是   | 创建环境时返回。                                                               |
| `vault_id`       | `config`      | 否   | 智能体使用的凭据库，例如存放其 Bird MCP 凭据的凭据库，使其能够通过 Bird 回复。 |
| `api_key`        | `credentials` | 是   | 来自你的智能体所在的 Claude 工作区。                                           |

连接之前，先在该平台上完成以下操作：

1. **首先，在 Claude 中设置你的智能体。** 在 Claude Console 中，于同一工作区内创建智能体、其环境和一个 API 密钥，然后在 Bird 中填入它们的 ID 和该密钥。参见 [platform.claude.com](https://platform.claude.com/docs/en/managed-agents/quickstart#create-your-first-session)。
2. **创建 API 密钥。** 在你的智能体所在的 Claude 工作区中创建。参见 [platform.claude.com](https://platform.claude.com/settings/keys)。
3. **复制智能体和环境的 ID。** 每次创建都会返回对应的 ID。参见 [platform.claude.com](https://platform.claude.com/docs/en/managed-agents/quickstart#create-your-first-session)。
4. **（可选）添加凭据保管库。** 如需让智能体通过 Bird 回复，请将其 Bird MCP 凭据存入 Claude 凭据保管库，并在此处填写该保管库的 ID。每个会话都会获得该保管库。参见 [platform.claude.com](https://platform.claude.com/docs/en/managed-agents/vaults)。

## Grok Bot

将你收到的每条消息发送到一个 Grok Bot 例程。其 ID 为 `grok_bot`。

它接受 `whatsapp.received`、`sms.received`、`email_mailbox.message_received`、`amb.received`。

| 字段          | 位置          | 必填 | 说明                                                  |
| ------------- | ------------- | ---- | ----------------------------------------------------- |
| `webhook_url` | `config`      | 是   | 该例程的 webhook URL。                                |
| `sender_key`  | `credentials` | 是   | 该例程的发送方密钥。Bird 仅将其作为 Bearer 令牌发送。 |

连接之前，先在该平台上完成以下操作：

1. **首先，让 Grok Bot 创建一个 routine。** 让 Grok Bot 创建一个带有 webhook 触发器的 routine，然后将它提供给你的 webhook URL 和发送方密钥填入 Bird。请参阅 [cursor.com](https://cursor.com/help/grok-bot/routines#where-do-the-webhook-url-and-key-live-and-what-does-a-200-mean)。

## Related resources

- [Setting up your coding agent](/learn/basics/setting-up-your-coding-agent) (video)
- [What is an MCP server, and how does an agent use one to send messages?](/explained/platform/what-is-an-mcp-server-and-how-does-an-agent-send-messages) (answer)
- [Coding agents](/ai) (product)
- [Build with AI agents](/learn/paths/agents) (course)

[Get an implementation brief](/learn/workspace?topic=agents)
