> ## Documentation Index
> Fetch the complete documentation index at: https://hub.hcompany.ai/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> H Platform has three products: the Agents API (managed computer-use agents, base URL https://agp.eu.hcompany.ai/api/v2 or https://agp.hcompany.ai/api/v2 for the US), the Models API (OpenAI-compatible Holo vision-language models at https://api.hcompany.ai/v1), and HoloTab (a free no-code Chrome extension that runs Holo in the user's browser, with recordable routines and schedules). The `holo` CLI (`pip install "hai-agents[cli]"`) runs Agents API agents from a terminal, drives the user's own desktop with `-a h/holo-desktop`, and serves coding agents through `holo mcp`.
> Authenticate with a bearer API key from the HAI_API_KEY environment variable. SDKs: `pip install hai-agents` (Python, `from hai_agents import Client`) and `npm install hai-agents` (TypeScript, `import { HaiAgentsClient } from "hai-agents"`). CLI: `holo`.
> Agents do work in a browser or on a desktop; describe the task as an imperative instruction. To run a task quickly, prefer the pre-built agent `h/web-surfer-flash`. Read results from the session's `latest_answer` after it reaches a terminal status.
> Sessions are the unit of work; wait for a terminal status (completed, failed, timed_out, interrupted) before reading the answer. Use webhooks or the `changes` long-poll endpoint to follow progress.

# Update an item

> Rename an H-hosted vault item, replace its sites, or set and remove individual values.

Only the fields you send change. Inside `values`, only the keys you send change: set a key to a string to replace that value, or to `null` to remove it.

**Returns** the updated [item object](https://hub.hcompany.ai/agents-api/vaults/retrieve-item.md#response).

Plaintext secrets in the request body

New values travel in clear text inside the body. Send them only over HTTPS and never log the request.

## Path parameters

**vault\_id** `string` *required*

The H-hosted vault's `id` (UUID).

**item\_id** `string` *required*

The item's `id` (UUID).

## Request body

**name** `string`

New label for the item, 1 to 255 characters.

**urls** `string[]`

Replaces the item's sites: 1 to 20 `http` or `https` URLs with a host.

**values** `object`

Values to set or remove, at least one key. Keys: `username`, `password`, `email`, `totp`, `api_key`. A string (1 to 4096 characters) sets that value; `null` removes it. Keys you leave out keep their value. The item must keep at least one value.

## Examples

```bash cURL theme={"system"}
curl -X PATCH https://agp.eu.hcompany.ai/api/v2/vaults/3b8d9c2e-6f1a-4e5b-8c7d-0a9b8c7d6e5f/items/7c1e4b2a-9d3f-4a6b-8e5c-2f1a0b9c8d7e \
  -H "Authorization: Bearer $HAI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"values": {"password": "n3w-s3cret", "totp": null}}'
```

```python Python theme={"system"}
from hai_agents import Client

client = Client()

item = client.vaults.update_vault_item(
    vault_id="3b8d9c2e-6f1a-4e5b-8c7d-0a9b8c7d6e5f",
    item_id="7c1e4b2a-9d3f-4a6b-8e5c-2f1a0b9c8d7e",
    values={"password": "n3w-s3cret", "totp": None},
)
print(item.fields)
```

```typescript TypeScript theme={"system"}
import { HaiAgentsClient } from "hai-agents";

const client = new HaiAgentsClient();

const item = await client.vaults.updateVaultItem({
  vaultId: "3b8d9c2e-6f1a-4e5b-8c7d-0a9b8c7d6e5f",
  itemId: "7c1e4b2a-9d3f-4a6b-8e5c-2f1a0b9c8d7e",
  values: { password: "n3w-s3cret", totp: null },
});
console.log(item.fields);
```

```json Response theme={"system"}
{
  "id": "7c1e4b2a-9d3f-4a6b-8e5c-2f1a0b9c8d7e",
  "vault_id": "3b8d9c2e-6f1a-4e5b-8c7d-0a9b8c7d6e5f",
  "name": "Example admin",
  "urls": ["https://example.com/login"],
  "fields": ["password", "username"],
  "created_at": "2026-05-08T09:15:00Z",
  "updated_at": "2026-05-09T11:02:00Z"
}
```

## Errors

| Status | Cause |
| - | - |
| `400` | The vault is not H-hosted, the new `totp` value is not a valid authenticator secret, or the update would leave the item with no values. |
| `404` | Vault or item not found, or you don't have access. |
| `422` | Body failed validation. Validation errors never echo the submitted values. |
| `502` | The item's stored values could not be read. Retry; nothing was changed. |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.