GitHub integration

Connect GitHub to let your Agents create issues, manage pull requests, read files, search code, and work with repositories. GitHub provides built-in Agent tools, not Flow steps.

Before you begin

Create a personal access token in GitHub before you connect the integration. Choose a fine-grained personal access token when it supports your use case, then select the repositories and permissions that the tools need. For a classic token, select the repo scope for private repository access and the read:org scope to read organization membership.

Treat the token as a password. Do not share it or commit it to source control.

Connect GitHub

Choose one of the following setup paths:

  • Use the tool picker while you configure an Agent.
  • Use Settings > Integrations to configure the credential before you select tools.

Use the tool picker

To connect GitHub while you configure an Agent, follow these steps:

  1. In the Agent editor, open the tool picker.
  2. Select GitHub. If GitHub has no credential, the setup form opens.
  3. Enter your token in Personal access token.
  4. Click Connect GitHub. Runtype saves the credential and refreshes the available GitHub tools.

Use integration settings

To configure the credential before you add GitHub tools to an Agent, follow these steps:

  1. Open Settings > Integrations.
  2. Find GitHub, then click Configure.
  3. Enter your token in Personal access token.
  4. Click Save. Runtype stores the credential for the selected integration environment.
  5. In the Agent editor, add GitHub tools from the tool picker.

Runtype stores the token with the GitHub integration, not in the Agent’s tool configuration. The Agent’s tool configuration selects which GitHub tools it can call.

Available tools

GitHub provides the following tools for your Agents.

Repositories

Use these tools to list repositories and view repository details:

  • list_repos: Lists repositories for the authenticated account or an organization.
  • get_repo: Gets repository details.

Issues

Use these tools to create, list, and update issues:

  • create_issue: Creates an issue with optional labels, assignees, and a milestone.
  • list_issues: Lists issues with state, label, assignee, and pagination filters.
  • update_issue: Updates an issue’s title, body, state, or labels.

Pull requests

Use these tools to create, list, inspect, and comment on pull requests:

  • create_pull_request: Creates a pull request from a head branch to a base branch.
  • list_pull_requests: Lists pull requests with state, head branch, base branch, and pagination filters.
  • get_pull_request: Gets pull request details.
  • create_pr_comment: Adds a comment to a pull request.

Files

Use these tools to inspect and change repository files:

  • get_file_content: Reads a file from a repository. The ref parameter accepts a branch, tag, or commit SHA and defaults to the repository’s default branch.
  • list_directory: Lists files and subdirectories at the repository root or a directory path. Use ref to inspect a branch, tag, or commit.
  • get_repository_tree: Returns a Git tree for a branch, tag, commit, or tree SHA. Set recursive to list nested paths; very large repository trees can return a truncated result.
  • commit_files: Writes and deletes 1–100 paths in one atomic commit, then fast-forwards the selected branch. Use expected_head_sha to reject a stale write when another commit moves the branch first.
  • search_code: Searches for code across GitHub repositories.

Enable the tools that you want to use in the tool picker.

Use cases

Use GitHub tools for these tasks:

  • Bug tracking: File issues from error reports.
  • Code review: Add comments to pull requests.
  • Documentation: Create issues for missing documentation.
  • Release automation: Update issues when you deploy.

Remove GitHub access

To stop an Agent from using GitHub, remove the GitHub tools from that Agent in the tool picker. To remove the stored credential, open Settings > Integrations, find GitHub, and click Remove. Revoke the token in your GitHub token settings after you remove it from Runtype.

Next steps

Continue with one of these pages: