# Update database (/docs/management-api/endpoints/databases/patch-databases-by-database-id)

Location: Management API > Endpoints > Databases > Update database

Updates the database with the given ID.

## API reference

### Update database

`PATCH /v1/databases/{databaseId}`

Updates the database with the given ID.

#### Parameters

- `databaseId` (path, string, required)

#### Request body

- `name` (string, optional): New display name for the database
- `branchId` (string | null, optional)
- `branchGitName` (string | null, optional)

#### Responses

- `200`: Updated the database.
- `401`: Missing or invalid authorization token.
- `403`: Actor does not have access to the database.
- `404`: Database with the given ID was not found.

## Related pages

- [`Create database`](https://www.prisma.io/docs/management-api/endpoints/databases/post-databases): Creates a new database in the specified project.
- [`Create database`](https://www.prisma.io/docs/management-api/endpoints/databases/post-projects-by-project-id-databases): Creates a new database for the given project.
- [`Delete database`](https://www.prisma.io/docs/management-api/endpoints/databases/delete-databases-by-database-id): Deletes the database with the given ID.
- [`Get database`](https://www.prisma.io/docs/management-api/endpoints/databases/get-databases-by-database-id): Returns the database with the given ID.
- [`Get list of databases`](https://www.prisma.io/docs/management-api/endpoints/databases/get-projects-by-project-id-databases): Returns databases for the given project.