> For the complete documentation index, see [llms.txt](https://docs.zerve.ai/zerve-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.zerve.ai/zerve-docs/git-and-version-control/git/github-enterprise-server.md).

# GitHub Enterprise Server

Connect Zerve to your GitHub Enterprise Server.

Connecting a self-hosted GitHub Enterprise Server (GHES) takes two parts: create a GitHub app for Zerve in your server, then give Zerve its details.

{% hint style="info" %}
GitHub Enterprise Server can only be connected for an organization, not for an individual.
{% endhint %}

## 1. Create a GitHub app for Zerve

In your GitHub Enterprise Server, go to your organization's **Settings → Developer Settings → GitHub Apps**, and select **New GitHub App**.

Enter these settings:

| Setting                | Value                                               |
| ---------------------- | --------------------------------------------------- |
| **GitHub App name**    | Zerve AI                                            |
| **Homepage URL**       | `https://zerve.ai`                                  |
| **Setup URL**          | `https://user.api.zerve.ai/github/post-install-url` |
| **Redirect on update** | On                                                  |
| **Webhook active**     | On                                                  |
| **Webhook URL**        | `https://user.api.zerve.ai/github/webhook`          |

Then:

1. **Generate a client secret**, and save it for later.
2. **Generate a private key**, and download it for later.
3. Under **Repository permissions**, set **Contents** and **Pull requests** to **Read and write**.
4. Under **Subscribe to events**, select **Installation target** and **Pull request**.

## 2. Give Zerve the app's details

1. In Zerve, go to your organization's **Settings → Git Integration**.
2. In **Git Management Service**, choose **GitHub Enterprise Server**.
3. Enter your GitHub app's details, including the client secret and private key, and save.

## 3. Grant access

Install the app and grant access to your repositories, as for [GitHub (cloud)](/zerve-docs/git-and-version-control/git/github-cloud.md).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.zerve.ai/zerve-docs/git-and-version-control/git/github-enterprise-server.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
