Skip to main content

GitHub Connection

The GitHub connection type enables automations to interact with GitHub repositories — reading commits and pull requests, triggering workflows, and managing issues. It supports both GitHub Cloud and GitHub Enterprise Server.

Connection Details

PropertyValue
Type IDGITHUB
CategoryVersion Control Systems
TestableYes

Friendly Example

What you enterExample
Connection nameGitHub - Automation Repo
Used forReading pull requests, commit status, and triggering workflow runs
Main details to collectPersonal access token and owner/organization name
Best person to provide itRepository or organization administrator

After it is saved, workflow builders select GitHub - Automation Repo in a node instead of entering these details again.

Mandatory Fields

FieldWhat It MeansExample
tokenGitHub personal access token (classic or fine-grained). Encrypted at rest.ghp_xxxxxxxxxxxxxxxxxxxx
ownerThe GitHub username or organization that owns the repositories the automation will access.acme-corp

Advanced Fields

FieldWhat It MeansExample
apiUrlBase URL for the GitHub API. Only required for GitHub Enterprise Server. Leave blank for GitHub Cloud.https://github.yourcompany.com/api/v3

Token Type Reference

Token TypeWhen to UseRequired Scopes
Classic PATBroad repository access across an organizationrepo, read:org
Fine-grained PATScoped access to specific repositories with granular permissionsSelect repositories and enable relevant permissions (Contents, Pull requests, Actions)
tip

Fine-grained tokens offer better security because they are scoped to specific repositories and expire on a set date. Use them when the automation targets a known set of repositories.

Setup Instructions

  1. Sign in to GitHub and click your profile picture in the top-right corner, then select Settings.

  2. Navigate to Developer settings (bottom of the left sidebar) and then select Personal access tokens.

  3. Choose the token type:

    • For a classic token: select Tokens (classic)Generate new token (classic). Under Scopes, check repo and read:org. Set an expiry and click Generate token.
    • For a fine-grained token: select Fine-grained tokensGenerate new token. Choose Resource owner (your org or account), set Repository access to the specific repositories the automation needs, and grant the required permissions under Repository permissions.
  4. Copy the token immediately. GitHub only displays it once.

  5. Create the connection in the Global Configurator, pasting the token into the Token field and entering the owner name. For GitHub Enterprise Server, also fill in the API URL field.

caution

Tokens with repo scope have read and write access to all private repositories owned by the account. Prefer fine-grained tokens with the minimum necessary permissions for production automations.

Troubleshooting

SymptomLikely Cause
401 UnauthorizedThe token has expired, been revoked, or was entered incorrectly
404 Not Found on a private repositoryThe token does not have repo scope, or the fine-grained token was not granted access to that repository
403 Forbidden on organization resourcesThe read:org scope is missing, or the organization requires OAuth app approval
Connection test fails for GitHub EnterpriseThe API URL is wrong or the server's TLS certificate is not trusted by the platform