Skip to main content

Update Team

Update the name or access code of an existing team.

Endpoint

POST /api/teams/{teamId}

Headers

Authorization
string
required
Bearer token for authentication

Path Parameters

teamId
string
required
Team UUID

Request Body

name
string
Updated team name (max 50 characters)
accessCode
string
Updated access code for joining the team (max 50 characters)
All fields are optional. Only include fields you want to update.

Response

id
string
Team UUID
name
string
Updated team name
accessCode
string
Updated access code
updatedAt
string
ISO 8601 timestamp of update

Example Request

curl -X POST https://your-umami-instance.com/api/teams/660e8400-e29b-41d4-a716-446655440001 \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Updated Team Name"
  }'

Example Response

{
  "id": "660e8400-e29b-41d4-a716-446655440001",
  "name": "Updated Team Name",
  "accessCode": "team_abc123def456789",
  "updatedAt": "2024-03-15T16:45:00.000Z"
}

Regenerating Access Code

You can regenerate the team’s access code to invalidate the old one:
curl
curl -X POST https://your-umami-instance.com/api/teams/660e8400-e29b-41d4-a716-446655440001 \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "accessCode": "team_newcode9876543"
  }'
Changing the access code will invalidate any existing join links. Users with the old code will no longer be able to join the team.

Error Responses

401
error
Unauthorized - You must be the owner/manager of this team
404
error
Not Found - Team does not exist

Permissions

Only team owners and managers can update team settings.

Build docs developers (and LLMs) love