View as Markdown

GitHub Integration

Manage GitHub repos, issues, and pull requests

The GitHub integration provides access to manage GitHub repos, issues, and pull requests through the Integrate MCP server.

Installation

The GitHub integration is included with the SDK:

import { githubIntegration } from "integrate-sdk/server";

Setup

1. Create a GitHub OAuth App

  1. Go to GitHub Developer Settings
  2. Create a new OAuth application
  3. Configure your redirect URI
  4. Note your Client ID and Client Secret

2. Configure the Integration on Your Server

Add the GitHub integration to your server configuration. The integration automatically reads GITHUB_CLIENT_ID and GITHUB_CLIENT_SECRET from your environment variables:

import { createMCPServer, githubIntegration } from "integrate-sdk/server";
 
export const { client: serverClient } = createMCPServer({
  apiKey: process.env.INTEGRATE_API_KEY,
  integrations: [
    githubIntegration({
    }),
  ],
});

You can override the environment variables by passing explicit values:

githubIntegration({
  clientId: process.env.CUSTOM_GITHUB_ID,
  clientSecret: process.env.CUSTOM_GITHUB_SECRET,
});

3. Client-Side Usage

The default client automatically includes all integrations. You can use it directly:

import { client } from "integrate-sdk";
 
await client.authorize("github");
const result = await client.github.createIssue({
  owner: "value",
});
 
console.log(result);

If you're using a custom client, add the integration to the integrations array:

import { createMCPClient, githubIntegration } from "integrate-sdk";
 
const customClient = createMCPClient({
  integrations: [githubIntegration()],
});

Configuration Options

export interface GitHubIntegrationConfig {
  /** GitHub OAuth client ID (defaults to GITHUB_CLIENT_ID env var) */
  clientId?: string;

Tools

github_create_issue

Create a new issue in a repository

export interface GithubCreateIssueParams {
    owner: string;

github_list_issues

List issues in a repository

export interface GithubListIssuesParams {
    owner: string;

github_get_issue

Get a specific issue

export interface GithubGetIssueParams {
    owner: string;

github_update_issue

Update an existing issue

export interface GithubUpdateIssueParams {
    owner: string;

github_close_issue

Close an issue

export interface GithubCloseIssueParams {
    owner: string;

github_create_pull_request

Create a pull request

export interface GithubCreatePullRequestParams {
    owner: string;

github_list_pull_requests

List pull requests in a repository

export interface GithubListPullRequestsParams {
    owner: string;

github_get_pull_request

Get a specific pull request

export interface GithubGetPullRequestParams {
    owner: string;

github_merge_pull_request

Merge a pull request

export interface GithubMergePullRequestParams {
    owner: string;

github_list_repos

List repositories (for a user or organization)

export interface GithubListReposParams {
    owner: string;

github_list_own_repos

List repositories for the authenticated user

export interface GithubListOwnReposParams {
    visibility?: "all" | "public" | "private";

github_get_repo

Get a specific repository

export interface GithubGetRepoParams {
    owner: string;

github_create_repo

Create a new repository

export interface GithubCreateRepoParams {
    name: string;

github_list_branches

List branches in a repository

export interface GithubListBranchesParams {
    owner: string;

github_create_branch

Create a new branch

export interface GithubCreateBranchParams {
    owner: string;

github_get_authenticated_user

Get information about the authenticated user

No parameters.

github_get_user

Get information about a user

export interface GithubGetUserParams {
    username: string;

github_list_commits

List commits in a repository

export interface GithubListCommitsParams {
    owner: string;

github_get_commit

Get a specific commit

export interface GithubGetCommitParams {
    owner: string;

github_list_issue_comments

List comments on an issue

export interface GithubListIssueCommentsParams {
    owner: string;

github_add_issue_comment

Add a comment to an issue

export interface GithubAddIssueCommentParams {
    owner: string;

github_update_issue_comment

Update an issue comment

export interface GithubUpdateIssueCommentParams {
    owner: string;

github_delete_issue_comment

Delete an issue comment

export interface GithubDeleteIssueCommentParams {
    owner: string;

github_list_pr_files

List pr files

No parameters.

github_list_pr_commits

List pr commits

No parameters.

github_list_pr_reviews

List pr reviews

No parameters.

github_create_pr_review

Create pr review

No parameters.

github_list_pr_review_comments

List pr review comments

No parameters.

github_get_file_contents

Get the contents of a file or directory in a repository

export interface GithubGetFileContentsParams {
    owner: string;

github_create_or_update_file

Create or update a file in a repository

export interface GithubCreateOrUpdateFileParams {
    owner: string;

github_delete_file

Delete a file from a repository

export interface GithubDeleteFileParams {
    owner: string;

github_list_releases

List releases in a repository

export interface GithubListReleasesParams {
    owner: string;

github_get_release

Get a specific release

export interface GithubGetReleaseParams {
    owner: string;

github_get_latest_release

Get the latest release for a repository

export interface GithubGetLatestReleaseParams {
    owner: string;

github_create_release

Create a release

export interface GithubCreateReleaseParams {
    owner: string;

github_list_labels

List labels for a repository

export interface GithubListLabelsParams {
    owner: string;

github_create_label

Create a label in a repository

export interface GithubCreateLabelParams {
    owner: string;

github_add_issue_labels

Add labels to an issue

export interface GithubAddIssueLabelsParams {
    owner: string;

github_list_collaborators

List collaborators for a repository

export interface GithubListCollaboratorsParams {
    owner: string;

github_fork_repo

Fork a repository

export interface GithubForkRepoParams {
    owner: string;

github_search_repos

Search repositories

export interface GithubSearchReposParams {
    q: string;

github_search_issues

Search issues and pull requests

export interface GithubSearchIssuesParams {
    q: string;

github_search_code

Search code

export interface GithubSearchCodeParams {
    q: string;

github_list_workflows

List workflows in a repository

export interface GithubListWorkflowsParams {
    owner: string;

github_list_workflow_runs

List workflow runs for a repository or workflow

export interface GithubListWorkflowRunsParams {
    owner: string;

github_trigger_workflow

Trigger a workflow dispatch event

export interface GithubTriggerWorkflowParams {
    owner: string;

github_list_milestones

List milestones for a repository

export interface GithubListMilestonesParams {
    owner: string;

github_create_milestone

Create a milestone

export interface GithubCreateMilestoneParams {
    owner: string;

Notes

  • Category: Engineering
  • Authentication mode: OAuth