---
title: "Admin team management — rename a workspace (audit-logged)"
method: PATCH
path: "/api/v1/admin/teams/{team_id}"
tags: ["admin"]
---

# Admin team management — rename a workspace (audit-logged)

`PATCH /api/v1/admin/teams/{team_id}`

## Request

- Base URL: `https://api.badgeia.com`
- URL: `https://api.badgeia.com/api/v1/admin/teams/{team_id}`
- Auth: none declared

Rename a workspace. Idempotent: renaming to the current name is a no-op.

Only the name is editable — plan / seats / ownership each have their own
enforcement path and are not reachable from here (see `AdminTeamRename`).

Auth: anonymous → 401, non-admin → 403, admin → 200. Flag-off → 404.
404 when the team doesn't exist. 409 when the name is already taken
(`teams.name` is UNIQUE).

## Path parameters

- `team_id` string, uuid, required

## Request body

- AdminTeamRename: Body for PATCH /admin/teams/{team_id}. Rename only. Plan, seats, and ownership are deliberately NOT editable here: each is an entitlement with its own enforcement path (`plan_limits`, `ensure_seat_available`, `create_team`), and letting an operator poke them from a console would route around every one of those checks. A name is the one field with no downstream semantics — nothing authorizes on it. `teams.name` is UNIQUE, so the handler converts an IntegrityError into a 409 rather than surfacing a driver error.
  - `name` string, required

## Response `200`

Successful Response

- object

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/badgeia/apis/badge.md) · [All operations](https://skmtc.dev/badgeia/apis/badge/llms.txt) · [OpenAPI document](https://skmtc.dev/badgeia/apis/badge/revisions/7e7f7fee8b77?raw)
