GitHub
Issues, pull requests, reviews and checks, through GitHub's own hosted MCP server.
What a member can do
With GitHub bound, a member can work in the repositories its account can see: read and file issues, comment,
open and review pull requests, read branches and files, read check runs and Actions, run a workflow run's failed
jobs again, and bring a pull request's branch up to date with its base. Each task names the
GitHub tools it may call, such as github.issue_read or github.create_pull_request; a tool the task does not
name is refused, whatever the binding allows.
Code itself is written in a workspace: a throwaway copy of the repository for one run, pushed back to a branch.
Who connects it
Whoever binds GitHub decides which account a member acts as. GitHub's hosted MCP server acts as the account that created the token, so every issue, comment, review and pull request is attributed to that account.
A binding can sit on the enterprise, a team, a member, a role or a task, and the one further down replaces the one above: task, then role, then member, then team, then enterprise. A role is held across teams, so a binding on a role reaches the job's work on every team its holders sit on, over any of those teams' own bindings. Bind GitHub on a member, with a token created by that member's own GitHub account, and the member's work appears under its own name and avatar. Bind it on the enterprise with your own token, and everything any member does appears as you.
What waits for you
Merging is the decision to keep for yourself. A new GitHub binding marks the merge tool, github.merge_pull_request,
as one that must be approved, from the GitHub tool's settings, and keeps that list as its own. A connection made while
those settings held no such list started with none, and is not given one later: until you send mustGate with the
merge to PATCH /v1/tools/bindings/{id}, its merges do not wait for you. A task that names it
has to declare a gate on it, or it cannot be saved; with the gate, the run writes a summary of what goes live, and nothing
merges until you approve it on Gates. You can send it back with the changes you want instead.
Name GitHub tools one by one on a task that merges, rather than the whole GitHub toolset, so the merge is always the gated tool. Anything else a task does on GitHub goes ahead as the task allows, unless the task declares a gate on it too.
Setup
The server
Leave MCP server URL blank when you add the tool: it defaults to GitHub's hosted server,
https://api.githubcopilot.com/mcp/. The binding offers GitHub's issues, repositories, pull requests, checks,
Actions and labels toolsets. These defaults come from the GitHub tool's settings in the tool directory, which Zero
Human keeps, and fill only what you leave out. To narrow the toolsets, add the binding over the API
with toolsets, a comma-separated list such as issues,pull_requests; the portal's form has no field for it.
The token
Use a classic personal access token with these scopes:
repo read:org
Add workflow if a task changes files under .github/workflows/, and project if a task edits GitHub Projects.
The token is sent to GitHub as Authorization: Bearer <token>; the model never sees it.
Custom props, for workspaces
A workspace clones and pushes through the code host binding whose git.host matches the
repository's. To let workspaces use this binding for repositories on GitHub, open it on Tools, press
Custom props at the top right of the form, and add these keys (or send them as props over the
API):
| Key | Value |
|---|---|
git.host |
github.com |
git.username |
x-access-token |
git.repoTemplate |
https://github.com/{repo}.git |
git.repoTemplate lets a run name its repository as owner/name. Without git.host, a workspace offers this token
to no host: a public repository still clones, and nothing pushes.
Add git.repo too only when every run that reaches this binding works in one repository, for runs that name none:
https://github.com/acme/site.git.
A run reads the nearest GitHub binding it reaches, and only that one. Add the keys to every GitHub binding a run can reach first: the enterprise's, and each member's own. Tools flags a binding that lacks them while another GitHub binding has them.
While any active task works in a workspace, Tools also warns on a binding that lacks them as soon as it is connected,
and its Add git settings button adds them in one save. It copies the git.* keys of another GitHub binding on the
same MCP server that has them, git.repo included. Without one, a binding on GitHub's default MCP server gets the
three keys in the table above, which the GitHub tool's settings offer. The button never changes the token or a prop already saved. A binding on another server, such as GitHub
Enterprise Server, gets no defaults: add its keys under Custom props.
Actions for checks and out-of-date branches
A task that names its tools by the codehost tool slot reaches GitHub's tools through the
connection's action map. A new GitHub connection starts with the GitHub tool's
map from the tool directory, which maps these actions for clearing red and out-of-date pull requests:
| Action | What it does | GitHub tool | Method |
|---|---|---|---|
codehost.ci.runs.list |
Lists a branch's GitHub Actions runs | actions_list |
list_workflow_runs |
codehost.ci.jobs.list |
Lists the jobs of one run | actions_list |
list_workflow_jobs |
codehost.ci.job.log |
Reads the end of one job's log | get_job_logs |
none |
codehost.ci.run.rerun |
Asks GitHub to run a run's failed jobs again | actions_run_trigger |
rerun_failed_jobs |
codehost.pr.update_branch |
Asks GitHub to bring a pull request's branch up to date with its base | update_pull_request_branch |
none |
- Runs of a commit. GitHub's run filter takes a branch but not a commit, so a commit's runs are the runs listed
for its branch whose
head_shais that commit. The list comes a page at a time, so on a busy branch the runs of an older commit can be on a later page. - Reading a log. The call names the job by its
job_id, and passesreturn_content: truefor the log's text andtail_linesfor how many of its last lines to keep. - GitHub Actions only. The run list holds GitHub Actions runs. Checks that other CI apps report on a commit are not in it, and the rerun action cannot start them again.
- Failed jobs only. The rerun action is pinned to
rerun_failed_jobs, which reruns the run's failed jobs rather than the whole run. It never reaches the tool's other methods: starting a workflow, cancelling a run or deleting its logs.
Neither a rerun nor a branch update waits for approval: a task that names them uses them on its own, so a red or out-of-date pull request does not wait for a person. To have either wait for you, declare a gate on it in the task, as for any other tool (see What waits for you).
A GitHub connection made before these actions were in the map got them with the release that added them, as it would from a directory update, when it is on GitHub's own server: each of the five it didn't map yet was added, up to the most actions a map can hold, and an action it already mapped keeps the tool you gave it. A connection on another server, such as GitHub Enterprise Server, was left as it was, since its server may name its tools differently: map the five yourself in the connection's Actions on Tools, and a run that stopped on one of them starts again by itself.
Actions for reviewing a pull request
The GitHub tool's map also maps three actions for reviewing a pull request:
| Action | What it does | GitHub tool | Method |
|---|---|---|---|
codehost.pr.review |
Starts a review of a pull request, or posts it | pull_request_review_write |
create |
codehost.pr.review.comment |
Adds one inline comment to the pending review | add_comment_to_pending_review |
none |
codehost.pr.review.submit |
Posts the pending review | pull_request_review_write |
submit_pending |
A pr.review call that names an event (APPROVE, REQUEST_CHANGES or COMMENT) posts the review at once, with no
inline comments. A call without one leaves it pending. A review with inline comments takes the three in turn:
pr.reviewwith noeventstarts a pending review.pr.review.commentadds one inline comment to it, on a file'spathand aline(or a range of lines), on thesideof the diff it belongs to. Call it once for each comment.pr.review.submitposts the review with aneventand, if you like, abody.
A GitHub connection on GitHub's own server that was made before these actions were in the map got them with the release that added them: each of the three it didn't map yet was added, unless its map was full, and an action it already mapped keeps the tool you gave it. A connection on another server, such as GitHub Enterprise Server, was left as it was: map the actions yourself in the connection's Actions on Tools.
Giving a member its own GitHub account
A member joins GitHub the way a person would: its own account, signed up with its own Zero Human address, and added to your organisation as a member on a seat. GitHub's terms allow a person to run a machine account as well as their own; whoever sets it up accepts the terms for it and is responsible for what it does.
Every GitHub email for the member (the launch code, the invitation, sign-in codes) goes to the member's own address, and appears in the Inbox on its member page in the portal. When a step says GitHub has sent an email, open that Inbox.
Work in a separate browser profile or a private window: your usual browser is signed in to GitHub as you, and the token has to be created while GitHub is signed in as the member.
- Create the account. At github.com/signup, sign up with the member's email address. Choose a username that matches the member's name: it shows on every comment and commit. Enter the launch code from the member's Inbox. Stay on the free plan; the seat comes from your organisation.
- Turn on two-factor authentication. Settings → Password and authentication. Use an authenticator app, and keep the recovery codes with the password.
- Invite it to your organisation. As an owner, in your usual browser: People → Invite member, as a Member. Add it to the teams that reach the repositories it will work in: the MCP server only sees what the account can see. Accept the invitation in the separate profile.
- Set up the profile. Name, avatar, and the member's role as its bio. Make sure its email address is verified and primary: commits are only linked to an account whose verified address matches.
- Create the token. Settings → Developer settings → Personal access tokens → Tokens (classic). Name it
Zero Human OS, choose the longest expiry your organisation allows (and note the date: the binding stops working when it lapses), tick the scopes above, and copy the token. If your organisation uses SAML single sign-on, authorise the token for it. - Bind it. In the portal, on the member's page → Tools, remove any existing
githubbinding first, then Add tool: typegithub, auth Bearer token / PAT, and the token. - Check it. Run a task that comments on an issue or opens a pull request as the member. It should appear under the member's name and avatar, and the run page shows the call and its result.
Troubleshooting
| What you see | Why | What to do |
|---|---|---|
| A comment or pull request appears as you | The token was created while GitHub was signed in as you | Create a new token in the separate profile, then remove the binding and bind the new one |
| The launch code or invitation never arrives | The member's email address is wrong | Check the email on the member page |
Not Found on a repository the member should reach |
The account is not on a team with access, or the token is not authorised for single sign-on | Add it to the team, or authorise the token for your organisation |
not_mcp_url when saving |
The URL answered, but not as an MCP server: GitHub's REST API, for example | Leave the URL blank, or use https://api.githubcopilot.com/mcp/ |
| The invitation fails, or the member is removed | Your organisation requires two-factor authentication | Turn it on (step 2), then invite again |
| Calls fail with an auth error after working | The token expired or was revoked, or the account left the organisation | Create a new token and bind it |
A workspace run fails workspace_repo_no_clone_address, or its push is refused |
The binding the run reaches has no git.* custom props, so owner/name cannot be expanded or the token is not offered to github.com |
Add the custom props above, on every GitHub binding a run can reach first: each member's own binding too |