GitSettings

查询保护分支规则列表。List branch protection rules.

查询指定仓库中配置的所有保护分支规则列表。返回每条规则的匹配模式、合并要求、推送管控等信息。 List all configured branch protection rules in the specified repository. Returns the match pattern, merge requirements, push restrictions, etc. for each rule. 访问令牌调用此接口需包含以下权限。Required permissions for access token. repo-manage:r

get/{repo}/-/settings/branch-protections

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}/-/settings/branch-protections
  • Auth: API key in header Authorization

Path parameters

repostring required

不带.git后缀的仓库名称。格式:组织名称/仓库名称。Repository name without .git suffix. Format: org/repo.

Response

OK

Changes

No recorded changes to this operation across all 1 revision of this API.