curl --request POST \
--url https://api.diversion.dev/v0/repos/{repo_id}/default_branch \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"branch_id": "<string>"
}
'{
"status": 123,
"detail": "<string>",
"title": "<string>",
"type": "<string>"
}Change default branch for a repository
curl --request POST \
--url https://api.diversion.dev/v0/repos/{repo_id}/default_branch \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"branch_id": "<string>"
}
'{
"status": 123,
"detail": "<string>",
"title": "<string>",
"type": "<string>"
}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"
The branch ID to set as the default branch
Request completed successfully