---
title: "Update Collection"
method: POST
path: "/library/{libraryId}/collections/{collectionId}"
tags: ["Manage Collections"]
---

# Update Collection

`POST /library/{libraryId}/collections/{collectionId}`

## Request

- Base URL: `https://video.bunnycdn.com`
- URL: `https://video.bunnycdn.com/library/{libraryId}/collections/{collectionId}`
- Auth: API key in header `AccessKey`
- TypeScript: <https://skmtc.dev/bunny/apis/stream-api/docs/library/:libraryId/collections/:collectionId/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `libraryId` integer, required
- `collectionId` string, required

## Request body

- UpdateCollectionModel
  - `name` string, nullable: The name to assign to the collection. Required, up to 255 characters.

## Response `200`

The collection was successfully updated

- StatusModel
  - `success` boolean: Determines if the request was successful
  - `message` string, nullable: Human-readable message describing the result, typically populated with error details when Success is false.
  - `statusCode` integer: The HTTP status code corresponding to the result of the request.

## Other responses

- `400`: The collection name was missing or longer than 255 characters
- `401`: The request authentication failed
- `403`: The request authorization failed
- `404`: The requested collection was not found
- `500`: Internal Server Error

## Changes

- **2026-11-12** `83116184952f`: 5 info
  - added the media type `application/json` for the response with the status `401`
  - added the media type `application/json` for the response with the status `403`
  - added the media type `application/json` for the response with the status `404`
  - added the media type `application/json` for the response with the status `500`
  - …1 more

[Operation history](https://skmtc.dev/bunny/apis/stream-api/changes/library/:libraryId/collections/:collectionId/post.md)

---

[API](https://skmtc.dev/bunny/apis/stream-api.md) - [All operations](https://skmtc.dev/bunny/apis/stream-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bunny/apis/stream-api/revisions/83116184952f?raw)
