Git
获取分支。Get branch.
根据分支名称获取指定分支的详细信息,包括分支名称、最近提交、保护状态等。 Get detailed information of the specified branch by name, including branch name, latest commit, and protection status. 访问令牌调用此接口需包含以下权限。Required permissions for access token. repo-code:r
get/{repo}/-/git/branches/{branch}
Request
- Base URL: https://api.cnb.cool (the document declares no server; this is the origin it was published from)
- URL: https://api.cnb.cool/{repo}/-/git/branches/{branch}
- Auth: API key in header Authorization
Path parameters
repostring required
不带.git后缀的仓库名称。格式:组织名称/仓库名称。Repository name without .git suffix. Format: org/repo.
branchstring required
分支名称。Branch name.
Response
OK
Changes
No recorded changes to this operation across all 1 revision of this API.