# Update menu

_Cms / Menus_

`PUT /cms/menus/{bucketId}`

## Parameters

- `id` (number, required) — The unique identifier of the menu to update
- `name` (string, required) — The name of the menu
- `categoryId` (number, optional) — The category identifier this menu belongs to
- `isPublished` (boolean, optional) — Whether the menu is published or not

## Responses

### `200` — Menu updated successfully

Type: `GenericResultResponse<boolean>`



## Code Examples

### curl

```curl
curl --request PUT \
 --url https://apis-spb.konso.io/cms/menus/{bucketId} \
 --header 'Content-Type: application/json' \
 --header 'x-api-key: {your-api-key}' \
 --data '{
 "id": 123456,
 "name": "Updated Navigation",
 "categoryId": 1,
 "isPublished": true
 }'
```

### javascript

```js
const options = {
 method: 'PUT',
 headers: {
 'Content-Type': 'application/json',
 'x-api-key': '{your-api-key}'
 },
 body: JSON.stringify({
 id: 123456,
 name: 'Updated Navigation',
 categoryId: 1,
 isPublished: true
 })
};

fetch('https://apis-spb.konso.io/cms/menus/{bucketId}', options)
 .then(response => response.json())
 .then(response => console.log(response))
 .catch(err => console.error(err));
```

### Request Body Example

```json
{
  "id": 12345,
  "name": "Example Name",
  "categoryId": 12345,
  "isPublished": true
}
```

### Response Example (200)

```json
{
 "result": true
}
```
