---
title: "Update a vault"
method: POST
path: "/vaults/{vault_id}"
tags: ["Vaults"]
---

# Update a vault

`POST /vaults/{vault_id}`

Updates the name or metadata of an active vault. Omitted fields remain unchanged. See [vaults](https://developers.openai.com/api/docs/guides/agents-api/tools/vaults).

## Path parameters

- `vault_id` string, required

## Request body

- UpdateVaultParams — Fields to replace on an active vault.
  - `metadata` object — Replaces all metadata. Omit to leave unchanged, or pass {} to clear it. Up to 16 string key-value pairs, with keys up to 64 and values up to 512 characters.
  - `name` string, nullable — A replacement name. Omit to leave unchanged, or pass null to clear it. The name is trimmed before storage. It must contain 1 to 256 UTF-8 bytes after trimming.

## Response `200`

The updated vault.

- VaultResource — A collection of credentials for MCP servers and OpenAI-hosted environments.
  - `id` string, required — The ID of the vault.
  - `object` 'vault', required — The object type. Always `vault`.
  - `name` string, nullable, required — The human-readable name of the vault, if set.
  - `metadata` object, required — Key-value pairs associated with the vault, such as an application or team identifier.
  - `created_at` integer, required — The Unix timestamp, in seconds, when the vault was created.

## Other responses

- `400` — The request was invalid.
- `401` — Authentication or project context was missing.
- `403` — The API key lacks the required management permission.
- `404` — The requested vault or credential was not found.
- `409` — The request conflicted with the current vault state.
- `500` — An internal error occurred.
- `503` — The service is temporarily unavailable.

## Changes

- **2026-10-06** `96a5d2084d7e` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/openai/apis/openapi/changes/vaults/:vault_id/post.md)

---

[API](https://skmtc.dev/openai/apis/openapi.md) · [All operations](https://skmtc.dev/openai/apis/openapi/llms.txt) · [OpenAPI document](https://skmtc.dev/openai/apis/openapi/revisions/ca22e4f7ee15?raw)
