Replace an evaluator

Replace the current draft/latest evaluator configuration. Committed read-only versions cannot be edited.

Path parameters

evaluator_idstringRequired

Evaluator ID. To run a specific version, pass an ID with a version suffix where supported, for example evl_abc123:2.

Headers

AuthorizationstringRequired

Bearer token. Use Bearer YOUR_API_KEY for API key auth or Bearer <JWT> for dashboard auth.

Request

This endpoint expects an object.
namestringRequired
typeenumRequired
Allowed values:
score_value_typeenumRequired
evaluator_slugstringOptional

Organization-scoped evaluator slug.

eval_classenumOptional

Optional pre-built evaluator template.

Allowed values:
descriptionstring or nullOptional
score_configobjectOptional

Score configuration. For numerical/percentage scores, use min_score and max_score. For select scores, use choices.

passing_conditionsobject or nullOptional
Passing conditions in the standard Respan filter format.
llm_configobject or nullOptional
LLM grader configuration. The backend validates this against the selected evaluator form.
code_configobject or nullOptional
Code grader configuration.
configurationsmap from strings to anyOptional

Legacy user-facing configuration object. New clients should prefer llm_config, code_config, score_config, and passing_conditions.

categorical_choiceslist of objectsOptional
starredbooleanOptional

Response

Updated evaluator.
idstring
Stable evaluator ID shared by all versions.
namestring
typeenum
Allowed values:
score_value_typeenum
version_idstring
Unique ID for this evaluator version.
versioninteger
Version number. The first draft is version 0.
is_read_onlyboolean
Whether this version is committed and immutable.
version_descriptionstring
Commit message for this version.
evaluator_slugstring

Organization-scoped evaluator slug.

eval_classenum

Optional pre-built evaluator template.

Allowed values:
descriptionstring or null
score_configobject

Score configuration. For numerical/percentage scores, use min_score and max_score. For select scores, use choices.

passing_conditionsobject or null
Passing conditions in the standard Respan filter format.
llm_configobject or null
LLM grader configuration. The backend validates this against the selected evaluator form.
code_configobject or null
Code grader configuration.
configurationsmap from strings to any

Legacy user-facing configuration object. New clients should prefer llm_config, code_config, score_config, and passing_conditions.

categorical_choiceslist of objects or null
starredboolean
created_atdatetime
updated_atdatetime
created_byobject
updated_byobject
editorobject
tagslist of objects

Errors

400
Bad Request Error
401
Unauthorized Error
404
Not Found Error