v52

latestOpenAPI 3.0.0Apache 2.0raw.githubusercontent.com2026-08-03134119177.4 KB
repositories

get branch protection rules

get/repositories/{repository}/settings/branch_protection

Response

branch protection rules

patternstring required

fnmatch pattern for the branch name, supporting * and ? wildcards

Example response

[
  {
    "pattern": "stable_*"
  }
]