---
title: "触发 Autopilot webhook"
method: POST
path: "/v2/autopilot/{projectId}/webhook"
language: "zh-Hans"
---

# 触发 Autopilot webhook

`POST /v2/autopilot/{projectId}/webhook`

## Request

- Base URL: `https://api.mintlify.com`
- URL: `https://api.mintlify.com/v2/autopilot/{projectId}/webhook`
- Auth: HTTP bearer

启动一次按照请求体中 prompt 执行的 Autopilot 运行。适用于从 CI/CD 流水线、发布脚本或内部工具中让 Autopilot 更新你的文档。

使用具有写入权限的组织 API 密钥进行身份验证。

## Path parameters

- `projectId` string, required

## Request body

- object
  - `prompt` string, required: 给 Autopilot 的指令，例如发生了哪些变化以及需要在文档中更新什么。

## Response `202`

Autopilot 运行已成功加入队列。

- object
  - `success` boolean: 运行加入队列时始终为 `true`。
  - `runId` string: 已加入队列的 Autopilot 运行的 ID。

## Other responses

- `400`: prompt 缺失、为空或超过 20,000 个字符，或项目 ID 格式不正确。
- `401`: API 密钥缺失或无效，或你的套餐不包含 Autopilot。
- `403`: 你的 API 密钥没有写入权限，或你的请求来自不在 API 密钥允许列表中的 IP 地址。
- `404`: 项目不存在或不属于你的组织，或该项目未设置 Autopilot。
- `429`: 你已超出每个组织每 10 秒 10 次请求的速率限制。此限制由触发部署、触发自动化和自动化 webhook 端点共享。
- `500`: 由于意外的服务器错误，无法将 Autopilot 运行加入队列。

## Changes

> 25 revisions in range; 2 not diffed.

- **2026-11-17** `16b7a7e40d59`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/mintlify/apis/mintlify-admin-api/zh/changes/v2/autopilot/:projectId/webhook/post.md)

---

[API](https://skmtc.dev/mintlify/apis/mintlify-admin-api/zh.md) - [All operations](https://skmtc.dev/mintlify/apis/mintlify-admin-api/zh/llms.txt) - [OpenAPI document](https://skmtc.dev/mintlify/apis/mintlify-admin-api/zh/revisions/16b7a7e40d59?raw)
