Skip to content

Unprotect repository branches

DELETE
/api/v4/projects/{id}/protected_branches/{name}

Unprotects a specified protected branch or wildcard protected branch.

id
required
One of:
string

The ID or URL-encoded path of the project

Example
gitlab-org/gitlab
name
required
string

The name of the protected branch

Example
main

No Content

Bad Request

401 Unauthorized

404 Project Not Found