---
title: "Update an existing group"
method: PUT
path: "/groups/{id}"
tags: ["Groups"]
---

# Update an existing group

`PUT /groups/{id}`

## Request

- Base URL: `/v1` (relative, and the document’s source URL is not known)
- URL: `/v1/groups/{id}`
- Auth: API key in header `Authorization`

Update an existing group in Cognito user pool

## Path parameters

- `id` string, required

## Request body

- object
  - `name` string, required
  - `precedence` integer

## Response `200`

The group has been successfully updated

- NewGroup: The new group details for the response body
  - `id` string: The unique ID of the group
  - `name` string: The human readable name of the group
  - `precedence` integer: The precedence of the group

## Other responses

- `400`: Request rejected due to invalid parameters supplied
- `401`: Authentication information is missing or invalid
- `404`: Group resource to be updated cannot be found
- `500`: Failed to process the request due to an internal error

---

[API](https://skmtc.dev/office-of-national-statistics/apis/identity-api.md) - [All operations](https://skmtc.dev/office-of-national-statistics/apis/identity-api/llms.txt) - [OpenAPI document](https://skmtc.dev/office-of-national-statistics/apis/identity-api/revisions/6472459b6b03?raw)
