Create Pr
create_prOpens a pull request in a GitHub repository. Always returns a preview first — call with confirmed=false (default) to review, then confirmed=true to execute. Requires GitHub connector token with 'repo' scope. Use when: user wants to open a pull request to merge a branch into a target branch. Scope: remote GitHub API — write operation, requires token. Not for: creating issues (use manage_issue), pushing commits (use local git), or reviewing existing PRs (use get_repo_info).
How to use create_pr
Provide only the required inputs below. Start with the smallest scope that answers the task, then review the risk properties before an agent executes the call.
Risk and execution properties
Read only: no
Destructive: no
Idempotent: no
Open world: yes — can reach external systems
Inputs
repostringrequiredGitHub repo in 'owner/repo' format. Example: 'myorg/myrepo'
titlestringrequiredPull request title.
bodystringPull request description (markdown). Optional.
headstringrequiredThe branch containing your changes. Example: 'feature/my-feature' or 'username:branch' for forks.
basestringThe target branch to merge into. Default: repo's default branch (usually 'main').
Default: "main"
draftbooleanOpen as a draft PR. Default: false.
Default: false
confirmedbooleanMust be true to execute the write. When false (default), returns a preview without making any changes. Always review the preview before setting confirmed=true.
Default: false
Example input
{
"repo": "<string>",
"title": "<string>",
"body": "<string>",
"head": "<string>",
"base": "main",
"draft": false,
"confirmed": false
}Browse or search the full 74-tool reference to choose the smallest suitable capability.
Browse all tools →