Skip to content
Subako Docs
English
Esc
↑↓navigate↵open⌘Jpreview

Update a vault

PATCH/v1/vaults/{vault_id}
Authorization
AuthorizationBearer token · headerrequired
Path parameters
vault_idstring<uuid>required
Vault id
Request body
requiredapplication/json
display_namestring
max length 200
external_idstring | null
A new external id, or `null` to remove it.
min length 1 · max length 255
metadataobject
Replaces every label the vault has, under the bounds `CreateVaultBody.metadata` states.
Responses
200The updated vault.
created_atstring<date-time>required
display_namestringrequired
external_idstring | nullrequired
The caller's own name for the vault, or `null` when it has none.
idstring<uuid>required
metadataobjectrequired
The vault's labels, by key.
workspace_idstring<uuid>required
400Malformed body, path parameter, or a display name, external id, or metadata outside its bounds.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
401Missing, malformed, or invalid bearer token.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
403Caller lacks vault.manage.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
404No such vault, or the caller cannot see it.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
409Another vault in the workspace already has this external_id.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
Try it
Server
Authorization
Parameters
Bodyapplication/json
Request
curl -X PATCH "https://api.us.cloud.subako.ai/v1/vaults/497f6eca-6276-4993-bfeb-53cbbbba6f08" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "display_name": "string",
  "external_id": "string",
  "metadata": {
    "property1": "string",
    "property2": "string"
  }
}'
Response
{
  "created_at": "2019-08-24T14:15:22Z",
  "display_name": "string",
  "external_id": "string",
  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  "metadata": {
    "property1": "string",
    "property2": "string"
  },
  "workspace_id": "0967198e-ec7b-4c6b-b4d3-f71244cadbe9"
}