# Update a category

PATCH https://api.oletapp.com/your-store/v1/categories/{id}

`parent_id` is immutable: the strict schema refuses it in the body, matching the admin app. A foreign or unknown id is `404 NOT_FOUND`.

**Requires scope:** `catalog:write`

Required scope: `catalog:write`

## Parameters

| Name | In | Type | Required |
|---|---|---|---|
| `id` | path | string | yes |

## Request body

```
{
  name?: string
}
```

## Response (200)

```
{
  data: {
  depth: integer
  id: string
  name: string
  parent_id: string | null
  version: string
}
}
```

Errors follow the standard error envelope: https://getolet.com/resources/developers/errors.md

## Example

```bash
curl -X PATCH "https://api.oletapp.com/your-store/v1/categories/{id}" \
  -H "Authorization: Bearer olet_live_YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```
