# Updating a record

`PUT /api/v1/vaults/{vault}`

Every PUT follows one rule: send what you want to change, and leave out what you want to keep.

A field left out of the body keeps its stored value. A body holding only a new name renames the record and touches nothing else.

A field sent as null is cleared. Send null to remove a description, a date or an icon.

A field that cannot be empty, such as a name, a label or a cadence, refuses null with 422. Leave it out to keep it.

A boolean left out keeps its value. Send true or false to change it.

A list sent whole, such as tags, options, columns or the fields of a layout, follows the same rule: left out, the stored list stays as it is; sent, it replaces the stored list, so an empty list empties it.

Where an endpoint departs from this, its own page says so.

## Rate limit

Sixty requests per minute, per user, shared by every key and device. Every answer carries the budget left in `X-RateLimit-Remaining`.

## Request

```sh
curl https://my.monicahq.com/api/v1/vaults/dunder-mifflin \
  -X PUT \
  -H "Authorization: Bearer $MONICA_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
      "description": null
  }'
```

```javascript
const response = await fetch('https://my.monicahq.com/api/v1/vaults/dunder-mifflin', {
  method: 'PUT',
  headers: { Authorization: `Bearer ${token}`, 'Content-Type': 'application/json' },
  body: JSON.stringify({
    description: null,
  }),
})
const data = await response.json()
```

```php
$response = Http::withToken($token)->put('https://my.monicahq.com/api/v1/vaults/dunder-mifflin', [
    'description' => null,
]);
```

## Response

`200`, with no body.
