> ## 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.

# Unlink GitHub App Repository

> Remove the GitHub App repository linked to an application.

<ParamField header="Authorization" type="string" placeholder="API Key" required>
  The API key for your account. You can find this in your [account settings](https://squarecloud.app/en/account/security).
</ParamField>

This endpoint removes the repository linked through [Link GitHub App Repository](/en/api-reference/endpoint/apps/deploy/github-app-link), so pushes to that branch stop deploying the application. The code already running is not touched, and the Square Cloud GitHub App stays installed on the repository until you remove it on GitHub.

It works with an API key that has the `apps:deploy` scope, and only the application owner can call it. Unlinking invalidates the cached response from [Get Current Deployment](/en/api-reference/endpoint/apps/deploy/info). Calls are rate limited to 3 per 60 seconds per user, shared with linking.

### Parameters

<ParamField path="app_id" type="string" placeholder="Application ID" required>
  The ID of the application. You can find this in the URL of your application's dashboard.
</ParamField>

### Response

<ResponseField name="status" type="string">
  Indicates whether the call was successful.. `success` if successful, `error` if not.
</ResponseField>

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

### Common errors

| Code                 | HTTP | Meaning                                                  |
| -------------------- | ---- | -------------------------------------------------------- |
| `GIT_NOT_CONFIGURED` | 400  | The application has no GitHub App repository linked.     |
| `APP_NOT_FOUND`      | 404  | The application does not exist or you are not its owner. |
