Connect GitHub
Connect GitHub when you want AI in type.com to work in your repositories: read code, open issues, review changes, and create pull requests. To start an automation when something happens in GitHub, also see GitHub triggers.
Before you start
Section titled “Before you start”- GitHub is a Team connection. It uses the type.com GitHub App, installed on a GitHub organization or user account. The repositories the app can reach are the ones you choose when you install it on GitHub.
- To install the app on a GitHub organization, you need permission to install apps there. If you don’t have it, a GitHub organization owner can install it or approve your request.
- After you connect, choose which Spaces and people can use the connection. See Control who can use a connection.
Connect GitHub
Section titled “Connect GitHub”- Open Connections in the sidebar and select Add connection.
- Search for GitHub, open it, and select Connect to GitHub.
- Sign in to GitHub.
- If the type.com GitHub App isn’t installed yet, GitHub asks you to install it. Choose the organization or account, then pick All repositories or only the repositories AI should use.
- You return to type.com. The connection shows the account and repository access, for example “Connected to organization acme with 3 selected repositories.”
If you connect from Space settings → Connections, the new connection is added to that Space for you.
Connect more than one GitHub account
Section titled “Connect more than one GitHub account”You can connect the GitHub App on several organizations or user accounts, for example one connection per GitHub organization.
- In Connections, select Add connection.
- Choose Add GitHub connection.
- On GitHub, pick the organization or account that doesn’t have a connection yet, and install the app.
Each GitHub connection shows its GitHub account name, for example “GitHub (acme)”, so you can tell them apart.
Use multiple repositories in one Space
Section titled “Use multiple repositories in one Space”A Space can use several GitHub connections, including repositories from different owners. Add each connection to the Space in Space settings → Connections, or give the Space access to it from Connections in the sidebar.
Choose a default repository
Section titled “Choose a default repository”The default repository is the one AI uses when a request doesn’t name a repository. Each Space has one default repository, even if it uses several GitHub connections.
- Make sure the GitHub connection is added to the Space.
- Open Space settings → Connections and select the GitHub connection.
- Under Default repository, choose the repository.
- Select Save (or Update).
Choosing a default under a different GitHub connection replaces the Space’s current default. Changing the default keeps the Space’s other GitHub connections.
If a Space can reach only one repository, AI uses that one. If there are several and no default, AI asks which owner/repository to use.
To work with a different repository, include its full owner/repository name in your request. A named repository always takes precedence over the default.
For browser verification of web app changes, see Verify Web Apps with Construct. The agent checks the requested repository’s setup and test environment, including when it differs from the Space’s default.
Author pull requests with your own account
Section titled “Author pull requests with your own account”By default, pull requests are created by the type.com GitHub App. Each teammate can add their own GitHub sign-in to the Team connection so the pull requests they ask for are authored by them:
- Open Connections and select the GitHub connection your Space uses.
- Under Your GitHub account, select Connect my GitHub account.
- Sign in to GitHub with your own account and authorize access.
- Return to type.com and ask for the pull request.
Only you can use your personal sign-in, and the team’s connection stays in place. Your GitHub account needs access to the GitHub App installation and the repository.
type.com uses your sign-in for requests you start when your account can reach the repository. Otherwise it uses the GitHub App, so the pull request is authored by the app.
If your sign-in expires or is revoked, the connection shows Personal authorization needs attention. Select Reconnect my GitHub account. Until you do, pull requests you ask for in chat are authored by the app.
Automations use the GitHub App unless their creator chooses their own GitHub account under Runs as. See Connections in automations.
Confirm it worked
Section titled “Confirm it worked”In a Space that has the GitHub connection, ask:
List the five most recent open pull requests in our default repository.
AI should name the repository and list the pull requests. If it asks which repository to use, set a default repository or name one in your request.
What AI can do with GitHub
Section titled “What AI can do with GitHub”AI works with GitHub through the git and GitHub command line tools in its sandbox, using the connection’s access. It can:
- Read code, issues, pull requests, and file diffs.
- Create branches and commits, and open or update pull requests.
- Open, comment on, and close issues.
Everything AI can do is limited by the repositories the GitHub App can reach. Read-only access doesn’t limit GitHub in chat: AI can still make changes, so control what it can change through the repositories the app can reach and your GitHub permissions. Automation commands get GitHub credentials only from GitHub connections attached to the automation’s Space with Full access. They don’t inherit the access AI has in chat.
Keep it working
Section titled “Keep it working”- Add or remove repositories: change the GitHub App’s repository access in GitHub. type.com picks up the change automatically. Saving in type.com doesn’t change it.
- Reconnect: if the connection shows Needs reconnection in Space settings → Connections, open it and sign in again.
- Disconnect: open the connection in Connections and select Disconnect for team. Workspace owners and admins and the connection’s managers can disconnect it. Uninstalling the GitHub App in GitHub also disconnects it.
Troubleshoot
Section titled “Troubleshoot”| What you see | What to do |
|---|---|
| Your GitHub account cannot access this connection. | Sign in with a GitHub account that has access to the GitHub App installation and the repositories you want to use. |
| No new GitHub installation was found for the selected GitHub account. | Every installation for that account is already connected. Choose another GitHub account, or install the app on another organization or user account. |
| Multiple new GitHub installations are available. | Choose a GitHub account that has only one installation that isn’t connected yet. |
| AI can’t find a repository | Check that the GitHub App can reach it in GitHub, and that the Space has the GitHub connection for that owner. Name it as owner/repository. |
| Default repository isn’t shown | Add the GitHub connection to the Space first. |
| A pull request was authored by the app, not you | Connect or reconnect under Your GitHub account, and check that your GitHub account can reach the repository. |
| GitHub command credentials require Full access for this automation. | Give the Space Full access to the GitHub connection. See Control who can use a connection. |
| The connection stopped working | The GitHub App may have been suspended or uninstalled. If it was suspended, unsuspend it in GitHub and the connection comes back. If it was uninstalled, reinstall it, then connect again. |
Frequently asked questions
Section titled “Frequently asked questions”Can pull requests from type.com be authored by my own GitHub account?
Yes. See Author pull requests with your own account.
Which account do automations use?
The type.com GitHub App by default. The automation’s creator can choose their own GitHub account under Runs as, and that choice always wins. A Sidekick automation that its owner created, with no Runs as choice, uses the owner’s own GitHub sign-in if they have one. If the Space does not allow that account, it uses the App.
Does Read-only access stop AI from changing GitHub?
Not in chat. See What AI can do with GitHub.