github_add_issue_labels
Add labels to an issue or pull request.
Read and change a GitHub repository from your assistant — files, branches, issues, pull requests, releases and labels — with an escape hatch to the raw REST API.
LABSCO SUMMARY
The coverage is wide enough that most GitHub work never needs a browser — file commits, branch creation, PR review requests and merges are all here — and the two generic REST tools mean an uncovered endpoint is not a dead end, with the write one requiring an explicit confirmation before it fires. The detail worth planning around is the SHA rule: updating or deleting a file needs the current SHA, so a read always precedes a write. Lazy tool loading exists for a real reason — forty-odd schemas is a lot of context to hand a client that only needs to read a file.
A broad GitHub server covering repository exploration and the full issue and pull-request lifecycle, with write operations that commit directly rather than only reading.
A GitHub personal access token in GITHUB_TOKEN or GITHUB_PERSONAL_ACCESS_TOKEN — a classic token with repo for private repositories and write operations, public_repo for read-only public access, and read:user for profile lookups. Passing it as a command-line flag is possible but exposes it to anyone who can run ps on the machine. Run it with npx github-mcp-server-kosta over stdio, from the npm package github-mcp-server-kosta, currently 3.1.0. --transport http serves a single Streamable HTTP endpoint, bound to 127.0.0.1 by default; if you bind anywhere else, set --http-auth-token and consider the host and origin allowlists, with --http-require-auth-on-public-bind refusing startup otherwise. An idle timeout exits the process after a period without requests, adjustable through MCP_IDLE_TIMEOUT_MS with 0 disabling it. In lazy tool mode only the bootstrap tools and the preloaded groups are exposed, defaulting to core and search.
One command plus a key — npm install -g github-mcp-server-kosta, then supply credentials
USE CASES
Read the metadata and README, then list the contents at the paths that look relevant.
Create a branch, commit the file change with its current SHA, open the pull request and request reviewers.
Compare it against the base branch, then open the individual commits with their diffs.
List the open issues by label, read the ones that matter, and relabel or comment as you go.
Search code within the repository, then read the files the results point at.
Check the previous releases for the tag pattern, then create the new one with its notes.
Call the REST API directly — reads go straight through, writes require the confirmation string.
Counted once with only startup setup. Other versions, modes or optional credentials may expose a different list.
github_add_issue_labelsAdd labels to an issue or pull request.
github_add_labelsAdd one or more labels to an issue or pull request without replacing existing labels.
github_compareCompare two git refs (branches, tags, or commits) and return the diff. Shows ahead/behind counts, commit list, and file changes. Useful for reviewing changes between releases or branches.
github_create_branchCreate a new branch in a GitHub repository from an existing ref. Resolves the source ref to a commit SHA, then creates the branch. Use before github_create_or_update_file for safe changes on a separate branch.
github_create_issueCreate a new issue in a GitHub repository. Requires a title; optionally set body (Markdown), labels, assignees, and milestone. Returns the created issue number and URL. Requires "repo" token scope.
github_create_issue_commentAdd a comment to an existing issue or pull request. Body supports GitHub-flavored Markdown. Works for both issues and PRs (they share the same comment API). Returns the comment ID and URL.
github_create_labelCreate a new label in a GitHub repository.
github_create_or_update_fileCreate a new file or update an existing file in a GitHub repository via a direct commit. For updates, you MUST provide the current file SHA (get it from github_get_file_content). Content should be the full file text (not a diff). Creates a commit on the specified branch.
github_create_pull_requestCreate a pull request in a repository.
github_create_releaseCreate a new release in a GitHub repository.
github_create_repoCreate a new GitHub repository under the authenticated account.
github_delete_branchDelete a branch from a GitHub repository.
github_delete_fileDelete a file via the GitHub Contents API. Requires the current file SHA.
github_fork_repoFork an existing GitHub repository to the authenticated account or organization.
github_get_commitRetrieve full details of a specific commit by SHA, including message, author, timestamp, parent SHAs, and the complete diff (files changed with patches). Use after github_list_commits to inspect a change.
github_get_file_contentRead the contents of a single file from a GitHub repository. Returns decoded UTF-8 text, the file SHA (needed for updates via github_create_or_update_file), size, and URL. Files over 1MB cannot be retrieved via this endpoint.
github_get_issueRetrieve full details of a specific issue by number, including title, body (Markdown), state, labels, assignees, milestone, and comments count. Use after github_list_issues to get complete information.
github_get_pullRetrieve full details of a specific pull request by number, including title, body, diff stats (additions/deletions/changed files), merge status, head/base branches, and review status.
github_get_readmeFetch and decode the README file of a GitHub repository. Automatically finds README regardless of casing or extension. Returns decoded content for quick project understanding.
github_list_branchesList all branches in a GitHub repository. Returns branch names, commit SHAs, and protection status. Use to discover branches before switching refs in other tools.
github_list_commitsList commits in a GitHub repository with optional filtering by file path, author, branch, and date range. Returns SHAs, messages, authors, and timestamps. Useful for understanding recent changes or tracking file history.
github_list_contentsList files and directories at a given path in a GitHub repository. Returns names, types (file/dir/submodule), and sizes. Use to explore repository structure before reading specific files with github_get_file_content.
github_list_issuesList issues in a GitHub repository with optional filtering by state, labels, and assignee. Returns titles, numbers, states, and labels. Note: GitHub API includes pull requests as issues; filter by absence of pull_request field for true issues.
github_list_labelsList labels in a GitHub repository.
github_list_pullsList pull requests in a GitHub repository with optional filtering by state, head branch, and base branch. Returns PR titles, numbers, states, authors, and branch info.
github_list_releasesList releases in a GitHub repository including names, tag names, publication dates, pre-release status, and release notes. Returns asset download URLs.
github_list_reposList repositories for a specific GitHub user or organization. Returns names, descriptions, languages, and star counts. Use github_search_repos for global search or this tool when you know the owner.
github_merge_pull_requestMerge a pull request.
github_remove_issue_labelRemove a label from an issue or pull request.
github_remove_labelRemove a single label from an issue or pull request.
github_repo_infoRetrieve metadata for a GitHub repository including stars, forks, open issues count, default branch, visibility, and language breakdown. Use as a starting point to understand a repository before exploring its contents.
github_request_reviewersRequest reviewers for a pull request.
github_rest_getPerform an arbitrary GET request against the GitHub REST API (path-based).
github_rest_mutatePerform an arbitrary write request against the GitHub REST API (guarded by an explicit confirmation string).
github_search_codeSearch for code matching a query within a specific GitHub repository. Returns file paths and text fragments. Supports GitHub qualifiers like language:, filename:, extension:, and path: in the query string.
github_search_issuesSearch issues and pull requests using GitHub Search Issues API. Use query qualifiers like "repo:owner/repo is:issue is:pr".
github_search_reposSearch GitHub repositories globally by keyword, language, stars, or other qualifiers. Returns matching repository names, descriptions, and star counts. Supports qualifiers like "language:", "stars:>100", "topic:", "org:".
github_set_issue_labelsReplace all labels for an issue or pull request.
github_tool_catalog_searchSearch available tool groups and tool names without loading full tool schemas.
github_tool_groups_listList available tool groups and whether they are loaded.
github_tool_groups_loadLoad one or more tool groups and notify the client that the tool list has changed.
github_update_issueUpdate an issue (or pull request) via the Issues API (edit title/body/state/labels/assignees/milestone).
github_update_pull_requestUpdate a pull request (title/body/state/base).
github_user_infoRetrieve a GitHub user's public profile: name, bio, company, location, public repo count, followers, and account creation date. Works for user and organization accounts.
BEFORE YOU INSTALL
44 tools when we connected. In --tool-mode lazy only bootstrap tools and preloaded groups load, and some clients will not refresh when more arrive. github_add_labels and github_remove_label are aliases; github_rest_mutate needs confirm: "CONFIRM_GITHUB_WRITE".
The documented client runs the server on your machine.
CONTEXT COST
Rated by the size of the 44 tool definitions that ride along on every turn, not by how many there are
INSTALLATION
npm install -g github-mcp-server-kosta{
"mcpServers": {
"github": {
"command": "npx",
"args": [
"github-mcp-server-kosta"
],
"env": {
"GITHUB_TOKEN": "<YOUR_GITHUB_TOKEN>"
}
}
}
}