Skip to main content
PUT
/
api
/
projects
/
{projectId}
/
groups
/
{groupId}
Update group
curl --request PUT \
  --url https://api.example.com/api/projects/{projectId}/groups/{groupId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>",
  "permissions": [],
  "filePermissions": []
}
'
import requests

url = "https://api.example.com/api/projects/{projectId}/groups/{groupId}"

payload = {
"name": "<string>",
"description": "<string>",
"permissions": [],
"filePermissions": []
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.put(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
permissions: [],
filePermissions: []
})
};

fetch('https://api.example.com/api/projects/{projectId}/groups/{groupId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.example.com/api/projects/{projectId}/groups/{groupId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'permissions' => [

],
'filePermissions' => [

]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.example.com/api/projects/{projectId}/groups/{groupId}"

payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"permissions\": [],\n \"filePermissions\": []\n}")

req, _ := http.NewRequest("PUT", url, payload)

req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.put("https://api.example.com/api/projects/{projectId}/groups/{groupId}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"permissions\": [],\n \"filePermissions\": []\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.example.com/api/projects/{projectId}/groups/{groupId}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"permissions\": [],\n \"filePermissions\": []\n}"

response = http.request(request)
puts response.read_body
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "name": "<string>",
  "projectId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "permissions": [],
  "description": "<string>",
  "filePermissions": [
    {
      "actions": [],
      "id": "<string>",
      "patterns": "<string>"
    }
  ],
  "roleId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "role": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "name": "<string>",
    "description": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Personal access token is obtained through your profile

Path Parameters

groupId
string<uuid>
required

ID of the group to update

projectId
string<uuid>
required

ID of the project the group belongs to

Body

application/json
name
string
required

New name for the group

description
string

New description for the group

permissions
enum<string>[]

Updated list of permissions for the group

Available options:
owner,
documents,
releases,
releases:manage,
releases:deploy,
releases:delete,
integrations:manage,
documents:full,
documents:view-content,
documents:edit-content,
documents:edit-view,
branches,
branches:create,
branches:merge,
branches:delete,
project:manage,
environments,
environments:manage,
environments:delete
filePermissions
object[] | null

Updated file-level permissions for the group

Response

200 - application/json

The updated group

The updated group

id
string<uuid>
required

Unique identifier of the group

name
string
required

Name of the group

projectId
string<uuid>
required

ID of the project this group belongs to

permissions
enum<string>[] | null
required

List of permissions granted to this group

Available options:
owner,
documents,
releases,
releases:manage,
releases:deploy,
releases:delete,
integrations:manage,
documents:full,
documents:view-content,
documents:edit-content,
documents:edit-view,
branches,
branches:create,
branches:merge,
branches:delete,
project:manage,
environments,
environments:manage,
environments:delete
description
string

Description of the group

filePermissions
object[] | null

File-level permissions for this group

roleId
string<uuid>

ID of the access profile managing this group

role
object | null

Access profile that manages this group