---
title: "Create or update a suggestion"
method: PUT
path: "/records/{record_id}/suggestions"
tags: ["records"]
---

# Create or update a suggestion

`PUT /records/{record_id}/suggestions`

## Path parameters

- `record_id` string, uuid, required

## Request body

- SuggestionCreate
  - `question_id` string, uuid, required
  - `type` 'model' | 'human' | 'selection'
  - `value` union, required
    - SpanQuestionResponseValueItem[]
      - `label` string, required
      - `start` integer, required
      - `end` integer, required
    - RankingQuestionResponseValueItem[]
      - `value` string, required
      - `rank` integer, nullable
    - string[]
    - integer
    - string
    - object
    - object[]
  - `agent` string, nullable — Agent used to generate the suggestion
  - `score` union — The score assigned to the suggestion
    - number
    - number[]

## Response `200`

Suggestion updated

- Suggestion
  - `question_id` string, uuid, required
  - `type` 'model' | 'human' | 'selection'
  - `value` unknown, required
  - `agent` string, nullable
  - `score` union
    - number
    - number[]
  - `id` string, uuid, required
  - `inserted_at` string, date-time, required
  - `updated_at` string, date-time, required

## Other responses

- `201` — Suggestion created
- `400` — Bad Request
- `403` — Forbidden
- `404` — Not Found
- `409` — Conflict
- `422` — Unprocessable Content
- `500` — Internal Server Error

## Changes

- **2026-08-24** `ca32894f988c` — 1 breaking, 1 info
  - removed `subschema #6, subschema #7` from the `value` request property `anyOf` list
  - added `subschema #6, subschema #7` to the `value` request property `anyOf` list
- **2026-08-08** `e9da3a893a88` — 1 info
  - added `subschema #7` to the `value` request property `anyOf` list

[Change history](https://skmtc.dev/hf/apis/extralit-v1/changes/records/:record_id/suggestions/put.md)

---

[API](https://skmtc.dev/hf/apis/extralit-v1.md) · [All operations](https://skmtc.dev/hf/apis/extralit-v1/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/hf/extralit-v1/revisions/ca32894f988c/schema)
