Codumentor logo Codumentor Enterprise

Gitea Pull Request Review

Is it enabled for you? Ask the assistant "Do you have Gitea tools?" If it has none, your administrator has not enabled Gitea pull-request review or configured a Gitea server.

If your organization uses Gitea for source control, the assistant can look up pull requests, read their diffs and discussion, and — with your approval — post review comments back to Gitea, all from chat.

Connecting your Gitea account

Each person uses their own Gitea access token, so the assistant always acts as you — there is no shared account.

  1. In Gitea, go to Settings → Applications → Generate New Token. Grant repository read scope to look things up; add issue/PR write scope as well if you also want to post comments.
  2. In Codumentor, go to Settings → Extensions → User Secrets → Add, name the secret gitea_api_token (your administrator may have configured a different name), enable Host-only, and paste the token.

If you ask about a pull request before the token is set, the assistant tells you it's missing instead of trying and failing silently.

Sharing the token with SCM Push

For HTTPS pushes, select this same host-only secret in Settings → SCM Push and grant the token repository write scope as well as the PR scopes above. Push remote/branch restrictions and PR write approvals remain separate and unchanged.

To consolidate existing tokens, keep gitea_api_token (or set gitea_pr.args.api_token_secret to the name of your existing push secret), enable Host-only on it, and point the SCM Push credential binding at that same secret. Remove any shell bindings before enabling Host-only. After verifying both operations, delete the unused duplicate secret. Existing values and bindings are not automatically overwritten or deleted. Existing non-host-only PR secrets still resolve through the host reader, but must be marked Host-only to remove them from the agent-accessible registry.

Asking about a pull request

Once connected, just ask in a normal message:

"List the open pull requests on our backend repo."

"What does PR #42 change? Summarize the diff."

"Who commented on PR #17, and what did they say?"

These reads never ask for approval — the assistant can list pull requests, fetch a PR's details, diff, changed files, commits and existing comments freely, and will cross-reference them against the ingested codebase when useful. For a large pull request, it prefers pulling individual changed files over the full diff.

Posting comments and reviews

Ask the assistant to comment on or review a pull request, and it drafts findings grounded in the actual diff:

"Review PR #42 and leave comments on anything risky."

"Post a summary comment on PR #17 saying it looks good to merge."

Posting a comment, a line-level comment, or an overall review verdict (comment / approve / request changes) each go through the normal approval dialog before anything lands on Gitea — nothing is posted without you seeing it first. If the assistant re-reviews the same pull request later (for example after a new push), it skips comments it already posted rather than repeating itself.

Automatic review on a webhook

Separately from chat, an administrator can wire Gitea webhooks so that opening a pull request, pushing new commits to one, or asking for a review (a /review comment, or Gitea's own "request review" action) automatically starts a review conversation — no one has to open Codumentor and ask.

This automatic path is off by default and must be explicitly configured and turned on by an administrator; most setups will only offer the chat-initiated review described above.

Where it is enabled, an automatic review can still only post comments — it can summarize findings and leave line comments, but it never submits an approve or request-changes verdict on its own. Approving or requesting changes on a pull request always requires someone reviewing it interactively in chat and confirming through the approval dialog.