MINARA

Set up GitHub access for Coding

Register and install a GitHub App, configure its Client ID, and connect Minara for HTTPS Git and pull requests

This guide connects Coding to GitHub through a repository-scoped GitHub App. After setup, Minara can authenticate HTTPS Git operations and create pull requests with the GitHub account you authorize.

Check the GitHub remote

Confirm that the repository points to GitHub:

git remote -v

Both [email protected]:owner/repo.git and https://github.com/owner/repo.git are supported. Minara uses the GitHub account you authorize and performs the authenticated network operation over HTTPS, without changing the checkout's configured remote.

Prerequisites

  • Permission to create a GitHub App under a personal account or organization.
  • Permission to install the app on the target repository. An organization owner may need to approve the installation.
  • A source checkout of Minara Agent if you are configuring a development build.

1. Register the GitHub App

  1. Open GitHub Settings.
  2. Select Developer settings.
  3. Select GitHub Apps.
  4. Select New GitHub App.
  5. Choose the owner that owns the repositories Minara must reach. For an organization repository, create the app under that organization when possible.

Configure the registration form as follows:

SettingValue
GitHub App nameA unique name such as Minara Coding
Homepage URLYour product, organization, or repository URL
Callback URLLeave empty. Device Flow does not use it
Expire user authorization tokensKeep enabled
Request user authorization during installationLeave disabled
Enable Device FlowEnable
Webhook ActiveDisable
Where can this GitHub App be installed?Only on this account for one owner, otherwise Any account

Minara uses Device Flow because Desktop starts authorization locally and the user confirms it in a browser.

2. Set repository permissions

Under Repository permissions, configure only these permissions:

PermissionAccessUsed for
ContentsRead and writeFetching and pushing Git objects over HTTPS
Pull requestsRead and writeFinding and creating pull requests
MetadataRead-onlyRepository identity and metadata

Leave unrelated repository, organization, and account permissions at No access. Select Create GitHub App when the form is complete.

3. Install the app on the repository

  1. Open the new GitHub App's settings page.
  2. Select Install App.
  3. Select the personal account or organization that owns the repository.
  4. Choose Only select repositories.
  5. Select every repository that Minara should access.
  6. Select Install. If GitHub shows Request, an organization owner must approve the request before Minara can use the repository.

Installation grants repository access. The later Minara sign-in authorizes one user to act through that installation. Both are required.

4. Copy the Client ID

Return to the GitHub App settings page and copy Client ID. Do not copy App ID. GitHub App Client IDs commonly look like this:

Iv1.8a61f9b3a7aba766

The Client ID is public application metadata. Minara's Device Flow does not need a Client Secret or GitHub App private key.

5. Configure a Minara development build

Add the Client ID to the repository root .env file:

MINARA_GITHUB_APP_CLIENT_ID=Iv1.8a61f9b3a7aba766

Replace the example with the Client ID copied from GitHub. Fully quit and restart Minara Desktop so the Gateway registers the provider during startup:

pnpm dev:desktop

Production distributions should ship a configured public Client ID. End users should not need to register a separate app for every installation.

6. Connect GitHub in Minara

  1. Open Settings in Minara.
  2. Select Git access.
  3. Under Connect GitHub, select Connect GitHub.
  4. Minara opens GitHub's device page and displays a one-time code.
  5. Enter the code, confirm the GitHub account, and approve the app.
  6. Return to Minara. The account appears with Ready status.

Verification

  1. Confirm the GitHub account shows Ready under Git access.
  2. Confirm the target Git remote points to github.com using SSH or HTTPS.
  3. Ask Coding to fetch or push the branch.
  4. For pull requests, confirm the app is installed on the repository and has Pull requests: Read and write.

Troubleshooting

SymptomResolution
Connect GitHub is unavailableSet MINARA_GITHUB_APP_CLIENT_ID, then fully restart Desktop
GitHub says the Client ID is invalidCopy Client ID, not App ID or Client Secret
GitHub does not show a device pageEnable Device Flow in the GitHub App registration
Authorization succeeds but the repository returns 403 or 404Install the app on that repository and approve pending organization access
Push is deniedSet Contents to Read and write and approve the changed permission
Pull request creation is deniedSet Pull requests to Read and write

Security model

  • Minara stores the user access token in its encrypted credential store, not in SQLite or the conversation transcript.
  • Device codes expire and are single-use.
  • The app can reach only repositories included in its installation.
  • The user's own repository permission and the app permission both apply.
  • Disconnecting the GitHub profile removes Minara's stored credential.

On this page