Skip to main content
Glama
ddukbg

GitHub Enterprise MCP Server

merge-pull-request

Automatically merge pull requests on GitHub Enterprise by specifying the repository, owner, PR number, and desired merge method (merge, squash, or rebase). Simplifies integration via API for streamlined workflow management.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commit_messageNoExtra detail to append to automatic commit message
commit_titleNoTitle for the automatic commit message
merge_methodNoMerge method to usemerge
ownerYesRepository owner (user or organization)
pull_numberYesPull request number
repoYesRepository name

Implementation Reference

  • The handler function that executes the merge-pull-request tool logic by calling the GitHub PUT /pulls/{pull_number}/merge endpoint.
    export async function mergePullRequest( client: GitHubClient, params: MergePullRequestParams ): Promise<MergePullRequestResponse> { const { owner, repo, pull_number, ...data } = params; return client.put<MergePullRequestResponse>( `/repos/${owner}/${repo}/pulls/${pull_number}/merge`, data ); }
  • Input schema defining parameters for merging a pull request.
    export interface MergePullRequestParams { owner: string; repo: string; pull_number: number; commit_title?: string; commit_message?: string; merge_method?: 'merge' | 'squash' | 'rebase'; }
  • Output schema for the merge pull request response.
    export interface MergePullRequestResponse { sha: string; merged: boolean; message: string; }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ddukbg/github-enterprise-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server