---
title: "Update Database Configuration"
method: PATCH
path: "/v1/organizations/{organizationSlug}/databases/{databaseName}/configuration"
---

# Update Database Configuration

`PATCH /v1/organizations/{organizationSlug}/databases/{databaseName}/configuration`

Update a database configuration belonging to the organization or user.

## Path parameters

- `organizationSlug` string, required
- `databaseName` string, required

## Request body

- DatabaseConfigurationInput
  - `size_limit` string — The maximum size of the database in bytes. Values with units are also accepted, e.g. 1mb, 256mb, 1gb.
  - `allow_attach` boolean — Allow or disallow attaching databases to the current database.
  - `block_reads` boolean — Block all database reads.
  - `block_writes` boolean — Block all database writes.
  - `delete_protection` boolean — Prevent the database from being deleted.
  - `allowed_ips` string[] — List of allowed IP addresses and CIDR blocks. Only connections from these sources are accepted. Pass an empty array to clear the list. Omit to leave unchanged.
  - `allowed_aws_vpc_ids` string[] — List of allowed AWS VPC endpoint IDs (vpce-...). Only connections arriving through these endpoints are accepted. Pass an empty array to clear the list. Omit to leave unchanged.

## Response `200`

Successful response

- DatabaseConfigurationResponse
  - `size_limit` string — The maximum size of the database in bytes. Values with units are also accepted, e.g. 1mb, 256mb, 1gb.
  - `allow_attach` boolean — Allow or disallow attaching databases to the current database.
  - `block_reads` boolean — The current status for blocked reads.
  - `block_writes` boolean — The current status for blocked writes.
  - `delete_protection` boolean — Prevent the database from being deleted.
  - `allowed_ips` string[] — List of allowed IP addresses and CIDR blocks. Empty means no IP restriction.
  - `allowed_aws_vpc_ids` string[] — List of allowed AWS VPC endpoint IDs. Empty means no VPC endpoint restriction.

---

[API](https://skmtc.dev/turso/apis/turso-platform-api.md) · [All operations](https://skmtc.dev/turso/apis/turso-platform-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/turso/turso-platform-api/revisions/6c99e4c88978/schema)
