Open a review of a pushed branch
open_reviewOpens a review of a branch the person pushed (with a push code token from create_code_token, or to the workspace's own GitHub), as a pull request does on GitHub: CodeGene opens the branch's review, builds its preview at exactly headSha, and the new task moves to Try it once the preview is ready. A later push to the branch moves the review to the new commit and rebuilds its preview (the task returns to Try it once that preview is ready), as a pull request follows its branch; going live merges the commit the preview shows. A branch alone builds no preview. Needs the branch name and the full commit id it was pushed at (git rev-parse HEAD). Never the branch the project goes live from. In a project of several parts, part names the one the change is about. The same branch and commit answer the same task.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"projectId": "<projectId>",
"branch": "<branch>",
"headSha": "<headSha>",
"title": "<title>",
"reason": "<reason>"
},
"name": "open_review"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| part | No | For a project of several parts (for example its app and its marketing site): the slug of the part the change is about, so its preview opens on that part. Left out, a project with one part uses it, and in a project of several the preview opens on the newest part the branch built. An unknown slug is refused with the slugs the project has. | |
| title | Yes | What the change does, as the task's title. | |
| branch | Yes | The pushed branch that holds the work. | |
| detail | No | More about the change, kept on the task. | |
| reason | Yes | Why, in a sentence: kept in the workspace's activity. | |
| headSha | Yes | The full 40-character commit id the branch was pushed at. | |
| projectId | Yes | The project the work is for. | |
| workspace_id | No | Workspace id from whoami; omit when there is one. |