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

# GitHub App

> Install the Ona GitHub App on your GitHub organization.

<Note>Available on the Core plan. [Contact sales](https://ona.com/contact/sales) to enable it for Enterprise.</Note>

This page is for the organization admin who installs the Ona GitHub App. For end-user usage, see [Mention Ona on a pull request](/ona/integrations/github-pr-mentions).

The GitHub App is a separate integration from [GitHub source control](/ona/source-control/github), which configures repository access for environments.

## Prerequisites

* You are an admin of an Ona organization.
* Your organization is on the Core plan. The integration is not enabled on Enterprise by default; [contact sales](https://ona.com/contact/sales) to turn it on for your organization.
* You have admin rights on the GitHub organization (or personal account) where the App will be installed.

## Install the Ona GitHub App

1. In Ona, go to **Organization Settings** > **Integrations**.
2. Find **GitHub App** and click **Install**.
3. GitHub opens. Choose the organization (or your personal account) to install the App on.
4. Choose which repositories the App can access:
   * **All repositories**: the App can be mentioned on every PR in the org.
   * **Only select repositories**: pick a subset. You can change this later from GitHub.
5. Approve the permissions request and finish the install on GitHub.
6. Ona shows the installation status on the integration page.

## Permissions

| Permission    | Access       | Why                                                                         |
| ------------- | ------------ | --------------------------------------------------------------------------- |
| Pull requests | Read & write | Read PR metadata and post agent status comments.                            |
| Issues        | Read & write | Read and post comments on PRs. GitHub treats PR comments as issue comments. |
| Contents      | Read         | Look up the repository associated with a PR.                                |
| Metadata      | Read         | Required by GitHub for any App.                                             |

If a permission is missing, Ona posts a `[!CAUTION]` comment on the PR:

> Ask an organization admin to update the Ona GitHub App installation and grant read & write access to **issues** and **pull requests**.

To fix it, open the App in GitHub, accept the new permissions, then ask the user to mention the agent again.

## Verify the installation

1. Open a pull request in a repository the App can access.
2. Post a comment containing `@ona-agent`.
3. Within a few seconds, the agent will react to your comment and post a reply with the running session.

If nothing happens, see [Troubleshooting](/ona/integrations/github-pr-mentions#troubleshooting).

## Change which repositories the App can access

1. Go to your GitHub organization's **Settings** > **GitHub Apps** > **Ona**.
2. Click **Configure**.
3. Under **Repository access**, add or remove repositories.
4. Save. The change takes effect immediately.

## Disable the App

Disable the integration if you want to stop Ona from responding to PR mentions without uninstalling the App on GitHub (for example, during a migration or incident).

1. In Ona, go to **Organization Settings** > **Integrations**.
2. Find **GitHub App** and toggle the switch off.

While disabled:

* The App stays installed on GitHub and keeps receiving webhook events, but Ona ignores them. No new agent sessions start for `@ona-agent` mentions.

To resume, toggle the switch back on.

## Uninstall the App

1. Go to your GitHub organization's **Settings** > **GitHub Apps** > **Ona**.
2. Click **Configure**, scroll to **Uninstall**, and confirm.

Uninstalling stops PR mention triggers for that GitHub organization. Sessions already running keep running. New sessions start again only when the App is reinstalled.

## Next steps

* [Mention Ona on a pull request](/ona/integrations/github-pr-mentions): what users do once the App is installed.
* [GitHub source control](/ona/source-control/github): repository access for environments.
* [Integrations overview](/ona/integrations/overview).
