No description
  • JavaScript 71.7%
  • TypeScript 28.3%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-10-06 22:48:03 +08:00
src feat: add create_pr_comment tool 2026-10-06 22:23:18 +08:00
.env.example feat: scaffold Forgejo MCP server with create_pull_request tool 2026-10-06 22:22:45 +08:00
.gitignore chore: update README 2026-10-06 22:48:03 +08:00
package.json feat: scaffold Forgejo MCP server with create_pull_request tool 2026-10-06 22:22:45 +08:00
README.md chore: update README 2026-10-06 22:48:03 +08:00
tsconfig.json feat: scaffold Forgejo MCP server with create_pull_request tool 2026-10-06 22:22:45 +08:00

forgejo-mcp

Model Context Protocol server for Forgejo (also works with Gitea).

Tools

  • create_pull_request — open a PR against a repository.
  • create_pr_comment — add a comment to a PR's conversation thread.

Configuration

Set these environment variables before launching the server:

Variable Description
FORGEJO_URL Base URL of the Forgejo instance (e.g. https://codeberg.org)
FORGEJO_TOKEN Personal access token with write:repository scope

Install & build

bun install
bun run build

Run

FORGEJO_URL=https://codeberg.org FORGEJO_TOKEN=xxx bun run dev

MCP client config

{
  "mcpServers": {
    "forgejo": {
      "command": "node",
      "args": ["/absolute/path/to/forgejo-mcp/dist/index.js"],
      "env": {
        "FORGEJO_URL": "https://code.vilor.com",
        "FORGEJO_TOKEN": "xxx"
      }
    }
  }
}