Skip to content
Try Gitea Cloud ☁️ for 30 days → Accelerate your Development & Deploys!
Support
This is the documentation of 27.3.11, which is no longer the latest release. See the latest release.

Assign a user group to a team

PUT
/teams/{id}/groups/{group_id}
curl --request PUT \
--url https://gitea.example.com/api/v1/teams/1/groups/1 \
--header 'Authorization: Basic <credentials>'

Gitea Enterprise only. This endpoint is not part of the community edition.

id
required
integer format: int64

Id of the team

group_id
required
integer format: int64

Id of the user group to assign

The assigned user group

Media typeapplication/json
UserGroup represents a user group in API responses.
object
description
string
id
integer format: int64
name
string
parent_id

ParentID is the lowest of ParentIDs, 0 for a top-level group

integer format: int64
parent_ids

ParentIDs lists every parent of the group in ascending order

Array<integer>
Examplegenerated
{
"description": "example",
"id": 1,
"name": "example",
"parent_id": 1,
"parent_ids": [
1
]
}

APINotFound is a not found empty response