submit_handoff
The CodePanel MCP tool that tells the reviewers what your pull request changes, what you tested, what you are unsure of and what you left out.
On this page›
submit_handoff gives the reviewers of your pull request the note the diff can't: what you changed and why, what you tested, what you are unsure of and what you left out on purpose. The next review round reads it as a claim to check against the code. It needs repo, pr and text, and the reviews:write scope.
When to call it
- Before the round you want it read in. Submit it after you open the pull request, or before a push that starts a round. Submitting again replaces the last one.
- When your description can't carry it. A
codepanel-handoffblock in the pull request description takes precedence over a submitted note, so edit that block instead if you have one. - Not as a way to soften findings. Text asking reviewers to approve, skip or soften findings is ignored. "Left out on purpose" covers scope only, and a defect in code the change contains is still reported.
The format and the rules reviewers apply to it are in Handoffs.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
repo |
string | yes | Repository as owner/name |
pr |
integer | yes | Pull request number |
text |
string, at most 6000 characters | yes | The handoff, in plain text or Markdown: changed, tested, unsure, left out |
sha |
string | no | The head commit it describes; defaults to the PR's head as CodePanel saw it |
authorAgent |
string, at most 120 characters | no | Agent that wrote the code, e.g. Claude Code; self-reported. Requires full 40-character sha. |
authorModel |
string, at most 120 characters | no | Actual model that wrote the code, if known; never guess. Requires full 40-character sha. |
agent |
string | no | Your name, e.g. claude-code. Defaults to this MCP client's name |
It writes: the server marks it readOnlyHint: false and destructiveHint: true (it can change what is already there), so a client that asks before writes asks here.
text is plain text or Markdown, up to 6,000 characters. Write it as four short parts: Changed, Tested, Unsure and Left out on purpose. Links and commands are taken out before reviewers read it, so describe what you did in words and name files by path.
sha names the commit the note describes. It defaults to the head as CodePanel last saw it, and when the pull request has moved past it, reviewers are told the note may describe an earlier version. A sha must be 7 to 40 hex characters, or the call fails with sha must be a commit sha (7 to 40 hex characters).
authorAgent and authorModel say who wrote the code. They are self-reported, never inferred from the submitting client, and need the full 40-character sha:
authorAgent/authorModel require sha to be the full 40-character head commit
What it returns
| Field | Meaning |
|---|---|
ok |
true |
chars |
The length stored |
truncated |
true if the text was cut to fit |
headSha |
The commit the note is stored against |
usedBy |
Whether a round will read it, in a sentence |
authorshipUsedBy |
Only when you passed authorAgent or authorModel. Says the labels are read by the next review of that exact sha, whether or not handoff text is read |
usedBy depends on the deployment. Where handoffs are turned on, it reads the next review round of this pull request, unless its description has a codepanel-handoff block. Where they are off, as in the example below, the note is stored but reviewers are not shown it, and usedBy says so. Read it rather than assuming.
Examples
These responses come from a test account on a local backend, where handoffs are off.
{
"repo": "codepanel-dev/web-app",
"pr": 142,
"text": "Changed: limiter keys on req.ip with trust proxy 1. Tested: new spoofed-header case in rateLimit.test.ts. Unsure: staging has two proxy hops. Left out: F4, in a follow-up PR.",
"agent": "claude-code"
}
{
"ok": true,
"chars": 174,
"headSha": "b7d204e19c3f5a8b2e6d0c4f7a9b1e3d5c8f2a64",
"truncated": false,
"usedBy": "no review yet: this deployment does not read handoffs (REVIEW_HANDOFF is not 1)"
}
usedBy reads no review yet: this deployment does not read handoffs (REVIEW_HANDOFF is not 1). That is a property of this local backend. If it says that on your account, the note was saved and will not change a review.
The same step without MCP
| Surface | Form |
|---|---|
| Pull request description | A fenced block with the info string codepanel-handoff. It wins over a submitted note |
| CLI | codepanel handoff owner/name#123 --text "..." or --file <path|->, with --sha and --agent (CLI) |
| HTTP API | POST /reviews/handoff. It accepts up to 12,000 characters and reviews use the first 6,000, while this tool caps the text at 6,000 |
What the server tells your agent
The description your agent reads when it lists the tools:
Before review, tell CodePanel's reviewers about the pull request you wrote: what you changed and why, what you tested and how, what you are unsure of, and what you left out on purpose. The next review round reads it (a codepanel-handoff block in the PR description takes precedence). Reviewers check it against the code: a test you name gets its coverage checked, and something you left out on purpose is not reported unless leaving it out breaks the code. Submitting again replaces it. Pass authorAgent and authorModel explicitly for the code author, with the full head sha. The submitting client name alone does not establish authorship; author metadata is read even when handoff prompts are disabled.
Related
submit_local_review: your own review of the change, also stored as a claim.get_review:payload.handoffshows which handoff a round read.- Handoffs: format and rules.
- MCP server: install, sign-in and every other tool.