
List all workflows in a repository's .github/workflows directory. Returns workflow IDs needed for other Actions tools
Get a specific workflow by ID or filename (e.g. 'ci.yml'). Use list_workflows to discover workflow IDs and filenames
List workflow runs for a repository or specific workflow. Filter by branch, status, actor, event, head_sha, or created date range. Returns run history with status and conclusion
Get details for a specific workflow run including status, conclusion, and timing. Use listworkflowruns to find run IDs
Trigger a workflow dispatch event to manually run a workflow (it must have a workflowdispatch trigger). Returns the new run's ID/URL when the API provides them; if absent, find the run via listworkflowruns with workflowid, branch=ref, and event='workflow_dispatch'
List jobs for a workflow run. Each job represents a step in the workflow. Use getjoblogs to retrieve logs for a specific job
Get log content for a workflow job. Returns the last 500 lines by default; set taillines=0 for the full log, or maxbytes to cap the size. Use listworkflowjobs to find job IDs
Cancel a workflow run that is queued or in progress. Use listworkflowruns to find run IDs
Re-run all jobs in a workflow run, optionally with debug logging enabled. Use listworkflowruns to find run IDs; to retry only failures use rerunfailedjobs
Re-run only the failed jobs of a workflow run (and their dependents), optionally with debug logging enabled. Use listworkflowruns to find run IDs
List artifacts produced by a workflow run, optionally filtered by exact artifact name. Use listworkflowruns to find run IDs; pass artifact IDs to getartifactdownload_url
Get a short-lived download URL for a workflow run artifact's zip archive (the URL expires after about 1 minute). Use listworkflowrun_artifacts to find artifact IDs
List a repository's deployments, optionally filtered by commit SHA, ref or environment. Returns deployment IDs for listdeploymentstatuses, which is where the outcome of each deployment lives. A deployment record on its own does not say whether it succeeded
List the statuses recorded against one deployment, newest first. The first entry is the deployment's current state (success, failure, inprogress and so on). Use listdeployments to find deployment IDs
List the names of secrets configured on a repository environment. Names and timestamps only: GitHub never returns secret values through the API at any scope, so this cannot read a secret. Use it to check which secrets an environment expects
List the deployment environments configured on a repository. Use this to find valid environment names before calling listenvironmentsecrets or filtering list_deployments by environment; guessing a name returns the same 404 as a missing permission, which is hard to tell apart. Empty is normal for a repository with no environments
Get a short-lived download URL for a repository archive (zip or tar) at a branch, tag or commit. Returns the URL rather than the bytes, because a repository archive is far too large to pass through an agent's context. The URL is signed and expires within minutes, so use it promptly
List discussion categories in a repository. Call this first to get category node IDs and slugs for filtering list_discussions. Categories are also required when creating discussions
List discussions in a repository with server-side filters: category (node ID or slug, use listdiscussioncategories first), answered, state (OPEN/CLOSED), and sort by created/updated time. Cursor pagination via limit/cursor
Get a discussion by number including body, category, author, comment count, and answer info. Returns nodeid, which creatediscussioncomment uses internally. Use listdiscussions to find discussion numbers
Get a discussion's comments and their threaded replies, flattened with each reply after its parent (replytonodeid links them). Each comment includes its nodeid, needed by updatediscussioncomment and as replytocommentid. limit/cursor paginate top-level comments only. Use listdiscussions to find discussion numbers
Create a discussion in a repository. Call listdiscussioncategories first to get a valid category slug or node ID. Discussions must be enabled on the repo (set hasdiscussions via updaterepository). Returns the new discussion including its number for creatediscussioncomment
Add a comment to a discussion by number. Supports GitHub Markdown. Set replytocommentid (a comment nodeid from getdiscussioncomments) to reply in a thread. Returns the new comment including its node_id for later updates
Update the body of an existing discussion comment. commentid is the comment node ID (e.g. 'DC...') returned by getdiscussioncomments or creatediscussioncomment
Get file or directory contents from a repository. Files return base64 content and metadata; files over 1MB are re-fetched as raw text (encoding 'raw'). If size exceeds maxsizebytes (default 1MB), metadata is returned with content omitted and a message. Directories return a list of entries. Use ref for branch/tag/SHA
Create or update a single file in a repository. Provide sha of existing file to update it (get sha from getfilecontents). Content is plain UTF-8 text by default; set encoding='base64' if you are passing already-encoded content. Omitting branch commits to the repository's DEFAULT branch
Delete a file from a repository. Requires the file's current blob SHA (get sha from getfilecontents). Cannot delete directories. Omitting branch commits the deletion to the repository's DEFAULT branch
Push multiple files in a single commit using the Git Data API (atomic). Per-file content is plain UTF-8 text by default; set encoding='base64' on a file if you are passing already-encoded content. Omitting branch commits to the repository's DEFAULT branch. More efficient than createorupdate_file for multiple files
Get the file tree for a repository. Set recursive=true to include all files in all subdirectories in one call; on very large repositories the response may be cut off — truncated=true means partial results, so fetch subtrees individually by SHA instead. tree_sha can be a branch name, tag, or commit SHA
Read a file's raw content by its blob SHA. Use this when getrepositorytree returns truncated=true and you must fetch subtrees or files individually, or when you already hold a blob SHA. To read by path instead, use getfilecontents. Returns decoded text; binary blobs set is_binary=true and leave content null
List gists for the authenticated user or a specific user. Gists are public or secret code snippets stored on GitHub
Get a specific gist by ID including all file contents
Create a new gist with one or more files. Set public=true for a public gist visible to everyone, or public=false for a secret gist accessible only via its URL
Update a gist's description or file contents. To delete a file, set its value to null in the files map. Only the gist owner can update it
Delete a gist permanently. Only the gist owner can delete it
Get a single issue by number from a specific repository. Returns labels, assignees, milestone, and a comment count (use getissuecomments for comment bodies), plus the issue 'id' needed by sub-issue tools
Get a list of issues from a repository with filtering by state, labels, assignee, creator, and more. Supports pagination and sorting. Note: GitHub interleaves pull requests in this list; items with a 'pull_request' field are PRs — skip them when only issues are wanted
Search for issues across all accessible repositories using GitHub's search syntax. Supports advanced filtering and sorting options
Create a new issue with title, body, labels, assignees, milestone, and type. Milestone numbers come from listmilestones, assignable usernames from listassignees, issue type names from listissuetypes, label names from list_labels. Returns the created issue including its number and id
Update an issue's title, body, state, labels, assignees, milestone, or type. labels and assignees REPLACE the full existing set. Set removemilestone/removeassignees true to clear them. Milestone numbers: listmilestones; usernames: listassignees; type names: listissuetypes. To mark a duplicate, set statereason 'duplicate' and duplicateofissueid to the canonical issue's numeric id from get_issue (an id, not an issue number)
Close an issue by setting its state to closed. Optionally specify a statereason (completed, notplanned, duplicate); when statereason is 'duplicate', pass duplicateofissueid with the canonical issue's numeric id from get_issue (an id, not an issue number)
Reopen a closed issue by setting its state to open
Get comments for a specific issue. Supports filtering by date and pagination for issues with many comments
Create a new comment on an issue. Comments support GitHub markdown formatting
Update an existing issue comment's content. Only the comment author or repository owners can update comments
Delete an issue comment. Only the comment author or repository owners can delete comments
Add labels to an issue. Labels must already exist in the repository — use listlabels to browse them or createlabel to add new ones
Remove a specific label from an issue
Set labels on an issue, replacing all existing labels with the new set
Remove all labels from an issue
Lock an issue to prevent new comments. Only collaborators will be able to add new comments
Unlock an issue to allow new comments from all users
List labels for a repository with pagination
Get a single repository label by name. Use list_labels to browse all labels
Create a new label in a repository. Color must be a 6-character hex code without the # (e.g. 'f29513')
Update an existing repository label's name, color, or description. Use list_labels to find label names
Delete a label from a repository. This removes the label from all issues and pull requests that have it
List a repository's milestones with state, sort, and pagination options. Use the returned milestone 'number' as the milestone value in createissue/updateissue
List users who can be assigned to issues in a repository. Use the returned 'login' values as assignee/assignees in createissue/updateissue
List an organization's issue types (e.g. Bug, Task). Use the returned 'name' values as the type in createissue/updateissue. Only available for organization-owned repositories
List an issue's sub-issues with pagination. Returns full issue objects including the 'id' needed by addsubissue/removesubissue
Add an existing issue as a sub-issue of a parent issue. subissueid is the child issue's ID, NOT its number — getissue returns it as 'id'. Set replaceparent true to re-parent a sub-issue that already has a parent. Returns the parent issue
Remove a sub-issue from its parent issue. subissueid is the child issue's ID, NOT its number — getissue or listsub_issues return it as 'id'. The child issue itself is not deleted. Returns the parent issue
List issues across ALL repositories accessible to the authenticated user (assigned/created/mentioned/subscribed), unlike getissues which is scoped to one repository. Each item's 'repository' field identifies its repo; items with a 'pullrequest' field are PRs
List notifications for the authenticated user. Set all=true to include read notifications. Filter to a specific repo by providing owner and repo. Paginated: per_page max 100 (the API defaults to 50 when pagination is omitted)
Get details for a specific notification thread by ID. Use list_notifications to find thread IDs
Mark a notification thread as read. The thread stays in the inbox, marked read. Use marknotificationdone to remove it from the inbox, or dismiss_notification to stop receiving future notifications for it
Mark all notifications as read. Scope to one repository by providing BOTH owner and repo; providing only one is rejected. With neither, the ENTIRE account's notifications are marked read
Mark a notification thread as done, removing it from the inbox. Unlike marknotificationread (thread stays in the inbox as read) and dismissnotification (unsubscribes from future notifications). Use listnotifications to find thread IDs
Unsubscribe from a notification thread so you no longer receive future notifications for it. Does not mark existing notifications read or done. Use marknotificationread or marknotificationdone for those
Mute or unmute a notification thread. Set ignored=true to mute the thread (suppresses all future notifications), ignored=false to unmute. The thread endpoint only supports muting; to fully unsubscribe from a thread use dismiss_notification
Manage repository-level notification subscription. Set subscribed=true to watch all notifications, ignored=true to ignore all notifications for this repository
Get a single pull request by number from a specific repository. Returns detailed PR information including merge status, reviews, and file changes
Get a list of pull requests from a repository with filtering options by state, head/base branches, and sorting. Supports pagination
Create a pull request from head into base. Provide title, or issue (an issue number) to convert an existing issue into a PR. Use headrepo for cross-repository PRs in the same network. Supports draft PRs; to assign reviewers, call requestreviewers after creation
Update an existing pull request's title, body, state, base branch, and other properties
Merge a pull request using the specified merge method (merge, squash, or rebase). Fails if the PR is not mergeable; check mergeable via getpullrequest first if unsure
Close a pull request without merging it. The PR can be reopened later if needed
Reopen a closed pull request. The PR must not be merged to be reopened
Convert a pull request to draft status, preventing it from being merged until marked ready for review (markreadyfor_review)
Mark a draft pull request as ready for review, allowing it to be merged once approved. Use converttodraft to move it back to draft
Get reviews for a pull request including approval status, comments, and reviewer information
Create a pull request review. Set event to APPROVE, REQUESTCHANGES, or COMMENT to submit immediately; omit event to create a PENDING review, then publish it with submitpullrequestreview or discard it with deletependingreview
Submit a PENDING pull request review with APPROVE, REQUESTCHANGES, or COMMENT. Use getpullrequestreviews (state PENDING) or the ID returned by createpullrequest_review to find review IDs
Dismiss a submitted pull request review with a required message explaining why. Use getpullrequestreviews to find review IDs. Only submitted reviews can be dismissed; delete PENDING reviews with deletepending_review
Delete a PENDING (unsubmitted) pull request review and its draft comments. Use getpullrequestreviews (state PENDING) to find review IDs. Submitted reviews cannot be deleted; use dismisspullrequestreview instead
Create a review comment on a pull request for code review. Comments specific lines of code in pull request diffs
Request specific users or teams to review a pull request. Reviewers will be notified of the request
Remove review requests from specific users or teams for a pull request
Get the files changed in a pull request with additions, deletions, and change counts. Set includepatch=true for per-file diffs, or use getpullrequestdiff for the whole-PR diff
Check if a pull request has been merged and get merge details if applicable
Get commits in a pull request showing the individual changes that make up the PR. Supports pagination (up to 250 commits are listable); use has_more to fetch further pages
Update the head branch of a pull request to include the latest changes from the base branch
Get the combined status for a specific commit or ref (legacy statuses API). Returns a concise summary: state, per-context statuses, and counts
Get check runs for a specific commit or ref (Checks API). Filter by checkname or status, and choose latest or all attempts via filter. Paginated (perpage max 100); has_more signals further pages
List the check suites for a commit or ref. A suite is one CI provider's whole run; getcheckruns returns the individual checks across all suites, and getchecksuiteruns narrows to one suite. Filter by appid to see a single provider. Paginated (perpage max 100); hasmore signals further pages
List the check runs inside one check suite. Use getchecksuites to find the suite ID. Prefer getcheckruns when you want every check on a commit regardless of provider; use this to inspect a single provider's suite. Paginated (perpage max 100); hasmore signals further pages
Get a check run's annotations: the file, line range and message for each problem the check reported. This is how a failing check says WHICH line broke, which getcheckruns does not include. Use getcheckruns or getchecksuiteruns to find the checkrun_id. An empty list means the check published no annotations, not an error
Get an overall CI status summary for a PR's head commit, including checks and legacy status
Reply to an existing review comment on a pull request. Use listpullrequestreviewthreads (database_id on each comment) to find review comment IDs
Get the unified diff for a pull request as plain text. Large diffs are truncated at maxbytes (default 200000 bytes); truncated=true signals cut-off content. Use getpullrequestfiles for per-file stats
List review threads on a pull request with resolution status, file path, and comments. Returns thread node IDs for resolvereviewthread/unresolvereviewthread and comment databaseids for addreplytopullrequestcomment. Paginate by passing end_cursor as cursor
Resolve a pull request review thread, marking the conversation as addressed. Requires the thread node ID returned by listpullrequestreviewthreads
Reopen (unresolve) a resolved pull request review thread. Requires the thread node ID returned by listpullrequestreviewthreads
Get a single repository by owner and name. Returns detailed repository information including stats, settings, and metadata
List ONLY the authenticated user's repositories (owned, collaborator, or org member). Filter by type/visibility/affiliation, sort, and paginate. To find repositories owned by other users or orgs, use search_repositories with org: or user: qualifiers
Create a new repository. Can create private or public repositories with various settings like issues, wiki, etc
Create a new repository in an organization. Can create private or public repositories with various settings like issues, wiki, etc
Update an existing repository's settings, description, visibility, and other properties
Delete a repository permanently. This action cannot be undone. Use with extreme caution
Get repository branches with optional filtering by protection status. Includes commit information for each branch
Create a new branch from an existing commit. Requires the SHA of the commit to branch from
Get repository commits with filtering options by author, date range, file path, and branch/SHA
Get a single commit by SHA with detailed information including file changes, statistics, and parent commits. For large commits, the files list is paginated: up to 300 files per page (use page/per_page), 3,000 files max in total
Get repository releases including tags, assets, and release notes. Returns both published and draft releases
Get the latest release for a repository. Returns the most recent non-prerelease, non-draft release. Raises a not-found error if the repository has no releases; use get_releases to list drafts and prereleases
Check if the authenticated user has starred a repository
Star a repository for the authenticated user
Unstar a repository for the authenticated user
Fork a repository into the authenticated user's account or a specified organization. Forking is asynchronous: the fork's metadata is returned immediately, but its git data can take several minutes to provision, so reads/pushes against the fork may fail or look empty at first. Retry after a short wait
List collaborators for a repository. Filter by affiliation (outside, direct, all) and by minimum permission (pull, triage, push, maintain, admin)
Get a release by its tag name (e.g. 'v1.0.0'). Use get_releases to list all releases
List tags for a repository with pagination
Search for organizations on GitHub. Use qualifiers like location:, repos:>N, followers:>N. Sort by followers, repositories, or joined; supports pagination. 'type:org' is added automatically unless the query already has a type: qualifier
Create a release. tagname is required: use an existing tag from listtags, or a new tag name (created from targetcommitish, default branch if omitted). Set generatereleasenotes to auto-fill notes. Returns the release id, htmlurl, and upload_url. Binary asset upload is not supported
Update a release by releaseid (from getreleases, getreleasebytag, or createrelease). Only supplied fields change: tagname, name, body, draft, prerelease, makelatest, target_commitish
Delete a release by releaseid (from getreleases or getreleaseby_tag). Deletes only the release; the underlying git tag remains
Compare two commits, branches, or tags. basehead uses 'BASE...HEAD' syntax, e.g. 'main...my-feature' or 'v1.0.0...v2.0.0' (cross-fork: 'owner:branch'). Returns aheadby/behindby/status, the commits in range, and changed files. Paginate with pagination.page/per_page; files are capped at 300 per page
Get effective branch protection: classic branch protection, falling back to repository and organization rulesets. protectionsource says which applies ('classic', 'ruleset', 'none'); protected=false only when neither does. Use before mergepullrequest to explain why a merge is blocked. Use getbranches to list branch names
Search GitHub repositories using search syntax. Supports qualifiers like language:python, stars:>100, topic:machine-learning, user:octocat, org:github
Search code across GitHub repositories. Must include a qualifier: repo:, org:, user:, language:, path:, or extension:. Example: 'addClass in:file language:js repo:jquery/jquery'. Results include text_matches snippets showing the matching fragments, so you rarely need to fetch each file
Search commits across GitHub repositories. Use qualifiers like author:, committer:, author-date:, repo:, org:. Example: 'fix bug author:octocat'
Search GitHub users and organizations. Use qualifiers like type:user, type:org, location:, language:, followers:>N, repos:>N. Example: 'tom repos:>42 followers:>1000'
Search pull requests across GitHub repositories. Supports filtering by state, author, reviewer, label, base branch. Example: 'is:open review-requested:octocat base:main'
Get the authenticated user's profile information including public and private details
Get detailed information about any GitHub user by their username
Get detailed information about a GitHub organization by its name
Get a list of users who follow a specific user. Supports pagination for users with many followers
Get a list of users that a specific user follows. Supports pagination for users who follow many people
Check whether one user follows another user. Set targetuser to the user who may be followed. Omit username to check the authenticated (connected) user, or set it to check whether some other user follows targetuser
Follow a user as the authenticated user. The user will be notified of the follow. Requires the user:follow scope
Unfollow a user as the authenticated user. Requires the user:follow scope
Get members of an organization with filtering options by role and 2FA status
Get organizations that a user is publicly a member of
Get teams in an organization. Requires organization membership or public visibility
Get members of a specific team with filtering by role (member or maintainer)
Check a user's membership in a team, including its state (active vs pending invitation) and role
Add a user to a team with specified role (member or maintainer). Requires admin permissions
Remove a user from a team. Requires admin permissions
Create a team in an organization. Requires org admin permissions. permission accepts only pull or push; grant finer roles (triage, maintain, admin) per-repository afterwards
Get the authenticated user's organization memberships including private memberships. Filter by state (active or pending) and paginate for users in many organizations
Get public events for a user showing their recent GitHub activity. Supports pagination
Get repositories starred by a user, sorted by star time (created) or last push (updated), with pagination
Validate GitHub credentials. Verifies credentials during setup.

In an mcp.json file, add the configuration below, and restart Cursor.
Learn more in the official documentation ↗
1{
2 "mcpServers": {
3 "agent-handler": {
4 "url": "https://ah-api-develop.merge.dev/api/v1/tool-packs/{TOOL_PACK_ID}/registered-users/{REGISTERED_USER_ID}/mcp",
5 "headers": {
6 "Authorization": "Bearer yMt*****"
7 }
8 }
9 }
10}
11Open your Claude Desktop configuration file and add the server configuration below. You'll also need to restart the application for the changes to take effect.
Make sure Claude is using the Node v20+.
Learn more in the official documentation ↗
1{
2 "mcpServers": {
3 "agent-handler": {
4 "command": "npx",
5 "args": [
6 "-y",
7 "mcp-remote@latest",
8 "https://ah-api-develop.merge.dev/api/v1/tool-packs/{TOOL_PACK_ID}/registered-users/{REGISTERED_USER_ID}/mcp",
9 "--header",
10 "Authorization: Bearer ${AUTH_TOKEN}"
11 ],
12 "env": {
13 "AUTH_TOKEN": "yMt*****"
14 }
15 }
16 }
17}Open your Windsurf MCP configuration file and add the server configuration below.
Click on the refresh button in the top right of the Manage MCP server page or in the top right of the chat box in the box icon.
Learn more in the official documentation ↗
1{
2 "mcpServers": {
3 "agent-handler": {
4 "command": "npx",
5 "args": [
6 "-y",
7 "mcp-remote@latest",
8 "https://ah-api.merge.dev/api/v1/tool-packs/<tool-pack-id>/registered-users/<registered-user-id>/mcp",
9 "--header",
10 "Authorization: Bearer ${AUTH_TOKEN}"
11 ],
12 "env": {
13 "AUTH_TOKEN": "<ah-production-access-key>"
14 }
15 }
16 }
17 }In Command Palette (Cmd+Shift+P on macOS, Ctrl+Shift+P on Windows), run "MCP: Open User Configuration".
You can then add the configuration below and press "start" right under servers. Enter the auth token when prompted.
Learn more in the official documentation ↗
1{
2 "inputs": [
3 {
4 "type": "promptString",
5 "id": "agent-handler-auth",
6 "description": "Agent Handler AUTH_TOKEN", // "yMt*****" when prompt
7 "password": true
8 }
9 ],
10 "servers": {
11 "agent-handler": {
12 "type": "stdio",
13 "command": "npx",
14 "args": [
15 "-y",
16 "mcp-remote@latest",
17 "https://ah-api-develop.merge.dev/api/v1/tool-packs/{TOOL_PACK_ID}/registered-users/{REGISTERED_USER_ID}/mcp",
18 "--header",
19 "Authorization: Bearer ${input:agent-handler-auth}"
20 ]
21 }
22 }
23}Here are just a few use cases worth implementing:
Here are some popular tools across data types:
Merge Agent Handler provides several platform-level advantages over standalone MCP servers:
Yes, you can set custom security rules for any GitHub tool calls to block or redact sensitive data. You can also log tool calls, allowing the agent to make them while providing your team with real-time visibility whenever this happens.
Here are some specific examples:
Here are all the steps you’ll need to take to integrate your agent with the MCP server:
1. Create a free Agent Handler account. Sign up here to access the Agent Handler dashboard.
2. Create a Tool Pack. Tool Packs define which connectors and tools your agent can access. This involves navigating to Tool Packs in the dashboard, clicking Create Tool Pack, adding the GitHub connector, and choosing your authentication mode (Individual or Shared).
3. Set up a Registered User. Go to Registered Users in the dashboard; each Registered User represents a person or system identity that your agent runs as. When a user needs to authenticate with GitHub, Merge Agent Handler will automatically display a guided authorization prompt—no custom OAuth code required.
4. Test in the Playground. Before integrating into your app, validate everything works. This means opening the Sandbox for your Tool Pack and testing GitHub tool calls.
5. Integrate with your application. Connect your agent to Agent Handler to access the tools. You can do this in two ways:
Whether you're an engineer experimenting with agents or a product manager looking to add tools, you can get started for free now