Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

MR approval settings Group Level #3165

Copy link
Copy link
@xakepnz

Description

@xakepnz
Issue body actions

Group MR approval settings

Feature Request to create the group-mr-approval-settings object on the Group class.

The ability exists over API to query this:

curl --header "PRIVATE-TOKEN: <your_access_token>" \
  --url "https://gitlab.example.com/api/v4/groups/:id/merge_request_approval_setting"
{
  "allow_author_approval": {
    "value": true,
    "locked": false,
    "inherited_from": null
  },
  "allow_committer_approval": {
    "value": true,
    "locked": false,
    "inherited_from": null
  },
  "allow_overrides_to_approver_list_per_merge_request": {
    "value": true,
...

e.g.

>>> group = gl.groups.get('56')
>>> pb = group.merge_request_approval_setting.get()
>>> from pprint import pprint
>>> pprint(pb)
{
  "allow_author_approval": {
    "value": true,
    "locked": false,
    "inherited_from": null
  },
  "allow_committer_approval": {
    "value": true,
    "locked": false,
    "inherited_from": null
  },
  "allow_overrides_to_approver_list_per_merge_request": {
    "value": true,
    "locked": false,
    "inherited_from": null
  },
  "retain_approvals_on_push": {
    "value": true,
    "locked": false,
    "inherited_from": null
...

ref: https://gitlab.com/gitlab-security-oss/cis/gitlabcis/-/issues/125

Specifications

  • python-gitlab version: 5.6.0
  • Gitlab server version (or gitlab.com): GitLab Enterprise Edition 17.11.0-pre 76ac92593a5
guerda and qerub

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.