curl --request GET \
--url https://api.yertle.com/orgs/{org_id}/nodes/{node_id}/branches/diff/{source_branch}..{target_branch}{
"source_branch": "<string>",
"target_branch": "<string>",
"source_commit": "<string>",
"target_commit": "<string>",
"can_merge": true,
"commits_ahead": 123,
"commits_behind": 123,
"merge_reason": "<string>",
"has_conflicts": false,
"comparison": {}
}Compare two branches to preview a potential pull request.
Reports whether the source branch can be fast-forward merged into the target, how many commits the source is ahead/behind, and whether any conflicts would arise. Typically called by the UI before opening a PR so the author can see what the merge would do.
Branches are identified in the URL as {source_branch}..{target_branch},
matching git diff syntax.
curl --request GET \
--url https://api.yertle.com/orgs/{org_id}/nodes/{node_id}/branches/diff/{source_branch}..{target_branch}{
"source_branch": "<string>",
"target_branch": "<string>",
"source_commit": "<string>",
"target_commit": "<string>",
"can_merge": true,
"commits_ahead": 123,
"commits_behind": 123,
"merge_reason": "<string>",
"has_conflicts": false,
"comparison": {}
}Documentation Index
Fetch the complete documentation index at: https://docs.yertle.com/llms.txt
Use this file to discover all available pages before exploring further.
Successful Response
Response model for branch comparison.
Source branch name
Target branch name
Source branch HEAD commit
Target branch HEAD commit
Whether branches can be merged via fast-forward
Number of commits source is ahead of target
Number of commits source is behind target
Reason if merge is not possible
Whether merge would have conflicts
Additional comparison data