update_oauth_client
Update an OAuth client's name, description, scopes, or IP allowlist. Replace scopes to adjust access; security changes apply to the next issued token.
Instructions
Change an API client's name, description, scopes or IP allowlist.
`id` is the client's record id from `list_oauth_clients`.
`scope_codenames` REPLACES the client's scopes rather than adding to them. To
add one, read the current set with `get_oauth_client` and send all of them plus
the new one — sending only the new one removes every other.
NARROWING SCOPES TAKES EFFECT ON THE NEXT TOKEN, not immediately. A token already
issued keeps the scopes it was minted with until it expires. If you are narrowing
a client because its secret leaked, narrowing alone is not enough: also
rotate the secret, and revoke any refresh token you know of.
Send `scope_codenames` OR `scope_preset`, not both.
The client's secret is NOT changed here and is not returned.
Requires the `clients:write` OAuth scope, and the `admin` capability profile.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| name | No | ||
| description | No | ||
| ip_allowlist | No | ||
| scope_preset | No | ||
| scope_codenames | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| name | No | ||
| warning | No | ||
| client_id | No | ||
| is_active | No | ||
| created_at | No | ||
| description | No | ||
| ip_allowlist | No | ||
| client_secret | No | ||
| scope_codenames | No |