Title: merge_pull_request: support choosing the commit author email · Issue #3814 · github/github-mcp-server · GitHub
Open Graph Title: merge_pull_request: support choosing the commit author email · Issue #3814 · github/github-mcp-server
X Title: merge_pull_request: support choosing the commit author email · Issue #3814 · github/github-mcp-server
Description: Describe the feature or problem you’d like to solve merge_pull_request merges through the REST merge endpoint (client.PullRequests.Merge in pkg/github/pullrequests.go), which has no way to set the author email of the merge commit. For an...
Open Graph Description: Describe the feature or problem you’d like to solve merge_pull_request merges through the REST merge endpoint (client.PullRequests.Merge in pkg/github/pullrequests.go), which has no way to set the ...
X Description: Describe the feature or problem you’d like to solve merge_pull_request merges through the REST merge endpoint (client.PullRequests.Merge in pkg/github/pullrequests.go), which has no way to set the ...
Opengraph URL: https://github.com/github/github-mcp-server/issues/3814
X: @github
Domain: github.com
IPv4 address: 140.82.112.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"merge_pull_request: support choosing the commit author email","articleBody":"### Describe the feature or problem you’d like to solve\n\n`merge_pull_request` merges through the REST merge endpoint (`client.PullRequests.Merge` in `pkg/github/pullrequests.go`), which has no way to set the author email of the merge commit. For an account with more than one verified email (for example a work and a personal email), GitHub picks the email.\n\nIn our case the result was not consistent: four merges made the same way through this tool, from the same account, were recorded with different emails (three with the personal email, one with the work email), and mostly not with the account's primary email. The author email of the commits in the pull request did not matter either.\n\nThe web UI lets users pick the email in the merge dialog, and the GraphQL `mergePullRequest` mutation accepts `authorEmail`, but there is no way to do this through the MCP server.\n\nThis matters most with the remote GitHub MCP server. A local setup can fall back to `gh` or a direct GraphQL call, but a hosted agent that only has the remote server's tools has no other way to merge, so the email cannot be controlled at all.\n\n### Proposed solution\n\nAdd an optional `author_email` parameter to `merge_pull_request`.\n\n- When it is set, merge through the GraphQL `mergePullRequest` mutation with `authorEmail`, mapping the existing parameters to `commitHeadline`, `commitBody`, `mergeMethod` and `expectedHeadOid`.\n- When it is not set, keep the current REST behavior.\n\nThe server already uses a GraphQL client for other pull request tools (for example `update_pull_request` gets one from `deps.GetGQLClient` for the draft state mutations), so this should not need new plumbing.\n\nThis lets agents that merge on a user's behalf keep merge commits attributed to the right email, which matters for organizations that require commits to use a work email.\n\n### Example prompts or workflows (for tools/toolsets only)\n\n1. \"Merge PR #123 with a merge commit, using my work email as the commit author.\"\n2. \"Squash and merge PR #123 and attribute the commit to my noreply email.\"\n3. \"Merge every approved PR of mine in this repo, always using my work email for the merge commits.\"\n\n### Additional context\n\nRelated in that both come from `merge_pull_request` being REST-only: #3669 (merge queue support).\n","author":{"url":"https://github.com/kogangdon","@type":"Person","name":"kogangdon"},"datePublished":"2026-11-11T06:44:11Z","url":"https://github.com/github/github-mcp-server/issues/3814"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:f35bbdb0-9ae3-586a-6ca4-5782f8011348 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E13C:27D516:47E191:5DBFE8:6B061C53 |
| html-safe-nonce | 174fedfaddc8f56d91c89c00d93585f04983b33543981b399942109c625160b9 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFMTNDOjI3RDUxNjo0N0UxOTE6NURCRkU4OjZCMDYxQzUzIiwidmlzaXRvcl9pZCI6IjIxMzMzMDI3MDI4NzEyODg5MTUiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 817e80d5d03866469c3af7e3ed937bd16d4acef436ea2cdca9f624dd0f1ee2c0 |
| hovercard-subject-tag | issue:6323209832 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/github/github-mcp-server/3814/issue_layout |
| twitter:image | https://opengraph.githubassets.com/bd841430ff328c77270b08daac9a1643158702e6245b54b0e9bb7dc1b4aea704/github/github-mcp-server/issues/3814 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/bd841430ff328c77270b08daac9a1643158702e6245b54b0e9bb7dc1b4aea704/github/github-mcp-server/issues/3814 |
| og:image:alt | Describe the feature or problem you’d like to solve merge_pull_request merges through the REST merge endpoint (client.PullRequests.Merge in pkg/github/pullrequests.go), which has no way to set the ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | kogangdon |
| hostname | github.com |
| expected-hostname | github.com |
| None | 9a7c5824b75ea2ec5e3de73a483229c7bb9f32a774ffd401f010dd9bacf1483d |
| turbo-cache-control | no-preview |
| go-import | github.com/github/github-mcp-server git https://github.com/github/github-mcp-server.git |
| octolytics-dimension-user_id | 9919 |
| octolytics-dimension-user_login | github |
| octolytics-dimension-repository_id | 942771284 |
| octolytics-dimension-repository_nwo | github/github-mcp-server |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 942771284 |
| octolytics-dimension-repository_network_root_nwo | github/github-mcp-server |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | b25c3080e84402f75431d8dc7a96b2635219cec7 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width