# Update personal vocabulary

Update the editable content of one personal vocabulary entry. Learning state changes only through recorded review results.

- Capability ID: `vocabulary.personal.update`
- Operation: `ielts_vocabulary_personal_update`
- Category: 词汇
- Endpoint: `POST /api/v1/agent/capabilities/ielts_vocabulary_personal_update`
- Authentication: Bearer Token（通过 /api/v1/agent-bindings 绑定账号）
- Required scopes: vocabulary:write
- Side effect: write
- Human documentation: https://ieltsbuddy.igopx.cn/developers/api/ielts_vocabulary_personal_update

## Request parameters

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `example` | string | 否 | example |
| `expansion` | unknown[] | 否 | expansion |
| `id` | number | 是 | id |
| `meaning` | string | 否 | meaning |
| `partOfSpeech` | string | 否 | partOfSpeech |
| `phrase` | string | 否 | phrase |
| `usage` | string | 否 | usage |

## Request example

```bash
curl -X POST \
  'https://work.ieltsbuddy.igopx.cn/api/v1/agent/capabilities/ielts_vocabulary_personal_update' \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer $IELTS_BUDDY_TOKEN' \
  --data '{"id":1}'
```

## Request schema

```json
{
  "type": "object",
  "properties": {
    "example": {
      "type": "string"
    },
    "expansion": {
      "maxItems": 30,
      "type": "array",
      "items": {
        "type": "string",
        "minLength": 1
      }
    },
    "id": {
      "type": "integer",
      "exclusiveMinimum": 0,
      "maximum": 9007199254740991
    },
    "meaning": {
      "type": "string"
    },
    "partOfSpeech": {
      "type": "string"
    },
    "phrase": {
      "type": "string",
      "minLength": 1,
      "maxLength": 300
    },
    "usage": {
      "type": "string"
    }
  },
  "required": [
    "id"
  ],
  "additionalProperties": false
}
```

## Response envelope

```json
{
  "code": 0,
  "data": {},
  "message": "ok"
}
```

## Errors

| HTTP | Code | Meaning |
| --- | --- | --- |
| 400 | `40001` | 请求参数不符合接口契约 |
| 401 | `40101` | 缺少或使用了无效的访问令牌 |
| 403 | `40301` | 访问令牌不包含接口所需权限 |
| 404 | `40401` | 接口或目标资源不存在 |
