Forgejo MCP Server
A Model Context Protocol server for Forgejo, the community-run, self-hostable Git forge that also powers Codeberg. It lets AI assistants like Claude browse and change repositories, files and branches, triage issues, open, review and merge pull requests, check CI status, run Forgejo Actions, publish releases, edit wikis and manage organizations on your own instance, Codeberg or any other Forgejo server (most tools also work on Gitea). Its 118 tools are grouped into 16 toolsets with 55 everyday tools on by default; you switch on the rest per connection, or make a connection read-only. It can also import or mirror repositories from GitHub, GitLab and Gitea. Your instance URL and access token are stored encrypted in the MCP Key Service instead of your client config.
Base endpoint (requires API key):
https://mcp.techmavie.digital/forgejo/mcpNeed help setting up? Follow the official setup guides:
Features
Works with self-hosted Forgejo, Codeberg and other Forgejo instances (most tools also work on Gitea)
118 tools in 16 toolsets, with 55 everyday tools on by default; add more per connection with ?toolsets=default,actions,releases or ?toolsets=all
Read-only mode (?read_only=true) hides every tool that writes, whatever toolsets are enabled
Explore code without a search API: full repository trees with path filters, and file reads with line ranges
Multi-file commits that create, update, rename and delete files in one go, optionally on a new branch
Labels and milestones by name, e.g. "label it bug and put it in v1.0"
Pull requests end to end: open, read the diff, check CI, review with inline comments, merge or schedule auto-merge
Global triage: issues and PRs assigned to you, waiting for your review or mentioning you, across all repositories
Import or mirror repositories from GitHub, GitLab or Gitea, and keep push mirrors in sync
Version-aware: features from newer Forgejo releases say what they need instead of failing with an unexplained error
Every tool is annotated read-only or destructive, so clients know when to ask before acting
Available Tools
forgejo_helloConnection check: your account, Forgejo version and active toolsets
forgejo_get_user / forgejo_search_usersUser profiles and user search
forgejo_list_repos / forgejo_search_repos / forgejo_get_repoFind and inspect repositories
forgejo_create_repo / forgejo_fork_repo / forgejo_update_repoCreate, fork, rename, archive or reconfigure repositories
forgejo_migrate_repoImport or mirror a repository from GitHub, GitLab, Gitea and more, with issues, PRs, releases and wiki
forgejo_get_tree / forgejo_get_file_contentsList every file in a repository and read files with line ranges
forgejo_push_files / forgejo_create_or_update_file / forgejo_delete_fileMulti-file or single-file commits, optionally on a new branch
forgejo_list_branches / forgejo_create_branch / forgejo_delete_branchBranches
forgejo_list_commits / forgejo_get_commit / forgejo_compare_refsCommit history and comparisons
forgejo_get_commit_status / forgejo_list_tags / forgejo_create_tagCI status and tags
forgejo_list_issues / forgejo_get_issue / forgejo_create_issue / forgejo_update_issueIssues
forgejo_search_issuesIssues and PRs across all repositories: assigned to you, review requested, mentioning you
forgejo_update_issue_labels / forgejo_list_labels / forgejo_list_milestonesLabels and milestones by name
forgejo_list_issue_comments / forgejo_add_issue_comment / forgejo_edit_issue_comment / forgejo_delete_issue_commentComments on issues and pull requests
forgejo_list_pull_requests / forgejo_get_pull_request / forgejo_create_pull_request / forgejo_update_pull_requestPull requests, including drafts and reviewers
forgejo_get_pull_request_diff / forgejo_list_pull_request_files / forgejo_list_pull_request_commitsPR diffs (trimmed per file for big PRs), files and commits
forgejo_merge_pull_request / forgejo_update_pull_request_branchMerge with any method, schedule auto-merge or update the branch
forgejo_list_pull_reviews / forgejo_get_pull_review / forgejo_create_pull_review / forgejo_submit_pull_review / forgejo_dismiss_pull_review / forgejo_delete_pull_review / forgejo_request_pull_reviewersFull review workflow with inline comments
forgejo_list_notifications / forgejo_get_notification_thread / forgejo_mark_notifications_readNotification inbox
?toolsets=actionsForgejo Actions: workflows, dispatch, runs, job logs, cancel, rerun and artifacts (8 tools)
?toolsets=actions_adminActions secrets and variables for repositories, organizations and users (6 tools)
?toolsets=releasesReleases and tag deletion (6 tools)
?toolsets=wikiWiki pages and revisions (6 tools)
?toolsets=labelsCreate, update and delete labels and milestones (6 tools)
?toolsets=orgsOrganizations, members and teams (11 tools)
?toolsets=repo_adminCollaborators, branch protection, webhooks, push and pull mirrors, repository deletion (14 tools)
?toolsets=packagesPackage registry (3 tools)
?toolsets=adminSite administration for instance admins (3 tools)
Highlights
Requirements
- MCP Key Service API key (register at mcpkeys.techmavie.digital)
- A Forgejo access token and your instance URL, e.g. https://codeberg.org or your own server (registered via MCP Key Service)
- Token scopes: repository, issue, notification and user (read or write); add organization, package or admin for those toolsets
- The hosted server connects to public HTTPS instances only; use local stdio mode for http:// or LAN instances