Create a score

Create a new evaluation score.

Headers

AuthorizationstringRequired

Bearer token. Use Bearer YOUR_API_KEY.

Request

This endpoint expects an object.
evaluator_idstringOptional

UUID of evaluator created in Respan. Either this or evaluator_slug must be provided.

evaluator_slugstringOptional

Custom string identifier for your evaluator. Either this or evaluator_id must be provided.

numerical_valuedoubleOptional

Numerical score value. Use when evaluator’s score_value_type is numerical.

string_valuestringOptional

String/text score value. Use when score_value_type is text or comment.

boolean_valuebooleanOptional

Boolean score value. Use when score_value_type is boolean.

categorical_valuelist of stringsOptional

Categorical score value. Use when score_value_type is single_select, multi_select, or categorical.

Response

Created score.
idstring
Score ID.
created_atdatetime
Creation timestamp.
typeenum
Evaluator type.
Allowed values:
environmentstring
Environment.
numerical_valuedouble or null
Numerical score value.
string_valuestring or null

String/text score value.

boolean_valueboolean or null
Boolean score value.
categorical_valuelist of strings or null

Categorical score value (array of strings).

is_passedboolean
Whether the score passes the evaluator's conditions.
costdouble
Cost of running the evaluation.
evaluator_idstring or null
UUID of the Respan platform evaluator.
evaluator_slugstring or null
Custom string identifier for the evaluator.
log_idstring or null
Associated span ID.
dataset_idstring or null
Associated dataset ID.

Errors

401
Unauthorized Error