---
title: "Update Workspace Toggle"
method: PATCH
path: "/api/billing/api-key/workspaces/{target_workspace_id}"
tags: ["billing", "billing"]
---

# Update Workspace Toggle

`PATCH /api/billing/api-key/workspaces/{target_workspace_id}`

## Request

- Base URL: `https://api.dialogbrain.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.dialogbrain.com/api/billing/api-key/workspaces/{target_workspace_id}`
- Auth: none declared

Update BYOK toggles for a specific workspace.

## Path parameters

- `target_workspace_id` integer, required

## Request body

- WorkspaceBYOKUpdate
  - `own_key_for_agents` boolean, nullable
  - `own_key_for_summaries` boolean, nullable
  - `own_key_for_kg_extraction` boolean, nullable

## Response `200`

Successful Response

- WorkspaceBYOKItem
  - `workspace_id` integer, required
  - `workspace_name` string, required
  - `own_key_for_agents` boolean, required
  - `own_key_for_summaries` boolean, required
  - `own_key_for_kg_extraction` boolean, required
  - `is_owner` boolean, required
  - `can_edit` boolean, required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway.md) · [All operations](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway/llms.txt) · [OpenAPI document](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway/revisions/d84e7dc9977d?raw)
