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

# 取消关联 GitHub App 仓库

> 移除关联到应用的 GitHub App 仓库。

<ParamField header="Authorization" type="string" placeholder="API Key" required>
  你账户的 API 密钥。你可以在[账户设置](https://squarecloud.app/zh/account/security)中找到它。
</ParamField>

该端点会移除通过[关联 GitHub App 仓库](/zh/api-reference/endpoint/apps/deploy/github-app-link)关联的仓库，此后推送到该分支将不再部署应用。已在运行的代码不受影响，Square Cloud GitHub App 会继续安装在仓库上，直到你在 GitHub 上将其移除。

它支持具有 `apps:deploy` 权限范围的 API 密钥，并且只有应用所有者可以调用。取消关联会使[获取当前部署](/zh/api-reference/endpoint/apps/deploy/info)的缓存响应失效。调用频率限制为每个用户每 60 秒 3 次，与关联共享该限额。

### 参数

<ParamField path="app_id" type="string" placeholder="Application ID" required>
  应用的 ID。你可以在应用控制台的 URL 中找到它。
</ParamField>

### 响应

<ResponseField name="status" type="string">
  指示调用是否成功。成功时为 `success`，否则为 `error`。
</ResponseField>

<ResponseExample>
  ```json theme={"system"}
  {
      "status": "success"
  }
  ```
</ResponseExample>

### 常见错误

| 代码                   | HTTP | 说明                      |
| -------------------- | ---- | ----------------------- |
| `GIT_NOT_CONFIGURED` | 400  | 该应用未关联任何 GitHub App 仓库。 |
| `APP_NOT_FOUND`      | 404  | 应用不存在，或你不是其所有者。         |
