curl --request GET \
--url https://api.diversion.dev/v0/repos/{repo_id}/branches \
--header 'Authorization: Bearer <token>'{
"object": "Branch",
"items": [
{
"commit_id": "example_id",
"branch_name": "new-branch-name",
"branch_id": "<string>",
"author": {
"id": "<string>",
"image": "<string>",
"email": "[email protected]",
"full_name": "<string>",
"name": "<string>"
},
"time": 123,
"branch_description": "A description of the branch"
}
]
}Get a list of all branches in the repo
curl --request GET \
--url https://api.diversion.dev/v0/repos/{repo_id}/branches \
--header 'Authorization: Bearer <token>'{
"object": "Branch",
"items": [
{
"commit_id": "example_id",
"branch_name": "new-branch-name",
"branch_id": "<string>",
"author": {
"id": "<string>",
"image": "<string>",
"email": "[email protected]",
"full_name": "<string>",
"name": "<string>"
},
"time": 123,
"branch_description": "A description of the branch"
}
]
}This API uses OAuth 2 with the implicit grant flow
The repo ID of the repository. Repo name can be used instead of the ID, but usage of ID for permanent linking and API requests is preferred.
3 - 128"example_id"
Success
Branch Show child attributes
3 - 128"example_id"
1 - 128"new-branch-name"
Branch identifier in Diversion
Creation time
"A description of the branch"