Skip to main content
PATCH
Rename, move, turn off, or set plain http for an item
Takes a managing key (oc_key_...) or a signed-in session. See Custom connections for how a key is sent. Renames an item, moves a key to another vault you can use, turns it on or off for agents, or turns plain http on or off for it. A move resets the key’s permissions to the default on the new vault.
Availability: OneCLI Cloud and self-hosted.

Authorizations

Authorization
string
header
required

A managing key (oc_key_...), an older API key (oc_...), or a signed-in session.

Headers

if-match
string

The item's version as you read it. A newer one answers 409, and nothing changes.

Pattern: ^"?\d{1,9}"?$

Path Parameters

id
string
required

The item's id.

Required string length: 1 - 64

Body

application/json

Exactly one of name (rename), vaultId (move a key to another vault), allowPlainHttp (let the gateway send the item over plain http://) or enabled (turn the item on or off for agents).

name
string
required
Required string length: 1 - 255

Response

The item.

allowPlainHttp
boolean
required

The gateway may send this item over plain http://. Off unless a person turns it on.

createdAt
string
required

ISO 8601.

deletedAt
string | null
required

ISO 8601. When it was deleted. null: a live item. A deleted item is listed only with deleted=true.

enabled
boolean
required

Off: the gateway does not use the item for any agent, whatever its permissions say. Requests to its hosts go out with no credential.

hosts
string[]
required

The hosts the gateway uses this item for.

id
string
required
kind
enum<string>
required
Available options:
app,
api_key,
llm_key
lastUsedAt
string | null
required

ISO 8601. When the gateway last used it for a request, to the hour. null: never used.

name
string
required
permissionSummary
object
required
purgeAt
string | null
required

ISO 8601. When a deleted item is destroyed for good, unless restored first. null: a live item.

rotatedAt
string
required

ISO 8601. When the value was last set: made, given a new value, or refreshed by the gateway.

service
string | null
required

The app or LLM provider, for example github or anthropic. null for a plain API key.

state
enum<string>
required

ready, reauth_required (the app must be signed in again) or disconnected.

Available options:
ready,
reauth_required,
disconnected
vaultId
string
required
version
integer
required

A key's current version, for If-Match on a change. 0 for an app, which has no versions.