Skip to content

create_branch

Create a new git branch in a project. Use this to start a scenario branch for testing alternative assumptions. Scenario workflow: (1) create_branch to start the scenario, (2) patch_file for small edits or update_file for larger changeson the scenario branch, (3) compare_branches to run both branches and diff the outputs, (4) merge_branch (Owner only) to adopt the winning scenario into main, or create_pull_request for team review before merging. Requires at least Editor role. Returns: project (str) — project name; branch (str) — new branch name; base_branch (str) — branch it was created from; sha (str) — HEAD commit SHA of the new branch.

NameTypeRequiredDefaultDescription
project_namestrYes
branch_namestrYes
base_branchstrNo'main'

Returns a structured object. Top-level fields:

  • project (string)
  • branch (string)
  • base_branch (string)
  • sha (string)

See the response example below for the full payload shape.

{
"name": "create_branch",
"arguments": {
"project_name": "forecasts",
"branch_name": "scenario/aggressive-growth",
"base_branch": "main"
}
}
{
"project": "forecasts",
"branch": "scenario/aggressive-growth",
"base_branch": "main",
"sha": "abc1234def5678901234567890abcdef12345678"
}
  • Module: Branches
  • Requires authentication via API token or Auth0 JWT.