v36

latestOpenAPI 3.1.0raw.githubusercontent.com2026-06-113513150.0 KB

Upsert Score

Create or update a Score for a given Record and MetricConfig. If a Score with the specified Record ID and MetricConfig ID already exists, it will be updated. Otherwise, a new Score will be created. The score provided should conform to the schema defined by the MetricConfig; otherwise, validation errors will be reported.

put/records/{recordId}/scores/{metricConfigId}

Path parameters

recordIdstring required
Example:777

The ID of the Record to upsert the Score for.

metricConfigIdstring uuid required
Example:a1b2c3d4-e5f6-7890-1234-567890abcdef

The ID of the MetricConfig.

Request body

scoreobject required

The score of the Record, as arbitrary JSON. This data should ideally conform to the output schema defined by the associated MetricConfig. If it doesn't, validation errors will be captured in the validationErrors field.

Response

Score upserted successfully.

recordIdstring required

The ID of the Record this Score is for.

metricConfigIdstring uuid required

The ID of the MetricConfig this Score is for.

scoreobject required

The score of the Record, as arbitrary JSON. This data should ideally conform to the output schema defined by the associated MetricConfig. If it doesn't, validation errors will be captured in the validationErrors field.

Example response

{
  "validationErrors": [
    {
      "path": "/data/question",
      "message": "Required field missing"
    }
  ]
}