Skip to content

[BUG]: BranchProtectionSettingsUpdate type is missing a bool property for RequiredSignatures. #2855

@wesdevpro-ssb

Description

@wesdevpro-ssb

What happened?

There is no options to set required_signatures to true or false with the BranchProtectionSettingsUpdate.

{
  "url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection",
  "required_status_checks": {
    "url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/required_status_checks",
    "strict": true,
    "contexts": [
      "continuous-integration/travis-ci"
    ],
    "contexts_url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/required_status_checks/contexts",
    "checks": [
      {
        "context": "continuous-integration/travis-ci",
        "app_id": null
      }
    ]
  },
  "restrictions": {
    "url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/restrictions",
    "users_url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/restrictions/users",
    "teams_url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/restrictions/teams",
    "apps_url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/restrictions/apps",
    "users": [],
    "teams": [],
    "apps": []
  },
  "required_pull_request_reviews": {
    "url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/required_pull_request_reviews",
    "dismiss_stale_reviews": true,
    "require_code_owner_reviews": true,
    "required_approving_review_count": 2,
    "require_last_push_approval": true,
    "dismissal_restrictions": {
      "url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/dismissal_restrictions",
      "users_url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/dismissal_restrictions/users",
      "teams_url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/dismissal_restrictions/teams",
      "users": [],
      "teams": [],
      "apps": []
    }
  },
  "required_signatures": {
    "url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/required_signatures",
    "enabled": false
  },
  "enforce_admins": {
    "url": "https://api.github.com/repos/octocat/hello-world/branches/main/protection/enforce_admins",
    "enabled": true
  },
  "required_linear_history": {
    "enabled": true
  },
  "allow_force_pushes": {
    "enabled": true
  },
  "allow_deletions": {
    "enabled": true
  },
  "block_creations": {
    "enabled": true
  },
  "required_conversation_resolution": {
    "enabled": true
  },
  "lock_branch": {
    "enabled": true
  },
  "allow_fork_syncing": {
    "enabled": true
  }
}

(the above example is located here)

Versions

Octokit.net 9.1.0

Relevant log output

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: Up for grabsIssues that are ready to be worked on by anyoneType: FeatureNew feature or request

    Type

    No type

    Projects

    Status

    ✅ Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions