{
  "opencollection": "1.0.0",
  "info": {
    "name": "Bitbucket Addon Branch restrictions API",
    "version": "2.0"
  },
  "items": [
    {
      "info": {
        "name": "Branch restrictions",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "List branch restrictions",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "{{baseUrl}}/repositories/:workspace/:repo_slug/branch-restrictions",
            "params": [
              {
                "name": "repo_slug",
                "value": "",
                "type": "path",
                "description": "This can either be the repository slug or the UUID of the repository,\nsurrounded by curly-braces, for example: `{repository UUID}`.\n"
              },
              {
                "name": "workspace",
                "value": "",
                "type": "path",
                "description": "This can either be the workspace ID (slug) or the workspace UUID\nsurrounded by curly-braces, for example: `{workspace UUID}`.\n"
              },
              {
                "name": "kind",
                "value": "",
                "type": "query",
                "description": "Branch restrictions of this type"
              },
              {
                "name": "pattern",
                "value": "",
                "type": "query",
                "description": "Branch restrictions applied to branches of this pattern"
              }
            ]
          },
          "docs": "Returns a paginated list of all branch restrictions on the\nrepository."
        },
        {
          "info": {
            "name": "Create a branch restriction rule",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "{{baseUrl}}/repositories/:workspace/:repo_slug/branch-restrictions",
            "params": [
              {
                "name": "repo_slug",
                "value": "",
                "type": "path",
                "description": "This can either be the repository slug or the UUID of the repository,\nsurrounded by curly-braces, for example: `{repository UUID}`.\n"
              },
              {
                "name": "workspace",
                "value": "",
                "type": "path",
                "description": "This can either be the workspace ID (slug) or the workspace UUID\nsurrounded by curly-braces, for example: `{workspace UUID}`.\n"
              }
            ]
          },
          "docs": "Creates a new branch restriction rule for a repository.\n\n`kind` describes what will be restricted. Allowed values include:\n`push`, `force`, `delete`, `restrict_merges`, `require_tasks_to_be_completed`,\n`require_approvals_to_merge`, `require_default_reviewer_approvals_to_merge`,\n`require_no_changes_requested`, `require_passing_builds_to_merge`, `require_commits_behind`,\n`reset_pullrequest_approvals_on_change`, `smart_reset_pullrequest_approvals`,\n`reset_pullrequest_changes_requested_on_change`, `"
        },
        {
          "info": {
            "name": "Get a branch restriction rule",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "{{baseUrl}}/repositories/:workspace/:repo_slug/branch-restrictions/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The restriction rule's id"
              },
              {
                "name": "repo_slug",
                "value": "",
                "type": "path",
                "description": "This can either be the repository slug or the UUID of the repository,\nsurrounded by curly-braces, for example: `{repository UUID}`.\n"
              },
              {
                "name": "workspace",
                "value": "",
                "type": "path",
                "description": "This can either be the workspace ID (slug) or the workspace UUID\nsurrounded by curly-braces, for example: `{workspace UUID}`.\n"
              }
            ]
          },
          "docs": "Returns a specific branch restriction rule."
        },
        {
          "info": {
            "name": "Update a branch restriction rule",
            "type": "http"
          },
          "http": {
            "method": "PUT",
            "url": "{{baseUrl}}/repositories/:workspace/:repo_slug/branch-restrictions/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The restriction rule's id"
              },
              {
                "name": "repo_slug",
                "value": "",
                "type": "path",
                "description": "This can either be the repository slug or the UUID of the repository,\nsurrounded by curly-braces, for example: `{repository UUID}`.\n"
              },
              {
                "name": "workspace",
                "value": "",
                "type": "path",
                "description": "This can either be the workspace ID (slug) or the workspace UUID\nsurrounded by curly-braces, for example: `{workspace UUID}`.\n"
              }
            ]
          },
          "docs": "Updates an existing branch restriction rule.\n\nFields not present in the request body are ignored.\n\nSee [`POST`](/cloud/bitbucket/rest/api-group-branch-restrictions/#api-repositories-workspace-repo-slug-branch-restrictions-post) for details."
        },
        {
          "info": {
            "name": "Delete a branch restriction rule",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "{{baseUrl}}/repositories/:workspace/:repo_slug/branch-restrictions/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "The restriction rule's id"
              },
              {
                "name": "repo_slug",
                "value": "",
                "type": "path",
                "description": "This can either be the repository slug or the UUID of the repository,\nsurrounded by curly-braces, for example: `{repository UUID}`.\n"
              },
              {
                "name": "workspace",
                "value": "",
                "type": "path",
                "description": "This can either be the workspace ID (slug) or the workspace UUID\nsurrounded by curly-braces, for example: `{workspace UUID}`.\n"
              }
            ]
          },
          "docs": "Deletes an existing branch restriction rule."
        }
      ]
    }
  ],
  "bundled": true
}