curl --request PATCH \
--url https://api.example.com/api/v2/projects/{project_id}/evaluation-criteria/code/{criteria_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": null,
"description": null,
"sample_rate": null,
"generate_insights": null
}
'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"target_type": "prompt",
"target_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"criteria_type": "1-5",
"sample_rate": 123,
"is_enabled": true,
"generate_insights": true,
"deployed_version": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"version_number": 123,
"eval_code": "<string>",
"is_deployed": true,
"created_at": "<string>"
},
"latest_version": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"version_number": 123,
"eval_code": "<string>",
"is_deployed": true,
"created_at": "<string>"
}
}Update criteria-level metadata. Does not create a new version.
curl --request PATCH \
--url https://api.example.com/api/v2/projects/{project_id}/evaluation-criteria/code/{criteria_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": null,
"description": null,
"sample_rate": null,
"generate_insights": null
}
'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"description": "<string>",
"target_type": "prompt",
"target_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"criteria_type": "1-5",
"sample_rate": 123,
"is_enabled": true,
"generate_insights": true,
"deployed_version": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"version_number": 123,
"eval_code": "<string>",
"is_deployed": true,
"created_at": "<string>"
},
"latest_version": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"version_number": 123,
"eval_code": "<string>",
"is_deployed": true,
"created_at": "<string>"
}
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
CreateCodeEvalResponse(id: uuid.UUID, name: str, description: Optional[str], target_type: shared.common.TargetType, target_id: uuid.UUID, criteria_type: shared.sqlalchemy.models.AutoEvalCriteriaType, sample_rate: Optional[float], is_enabled: bool, generate_insights: bool, deployed_version: server.api_routes.code_eval_criteria_api_v2.CodeEvalVersionSummary, latest_version: server.api_routes.code_eval_criteria_api_v2.CodeEvalVersionSummary)
prompt, agent 1-5, 1-3, 1-100, yes-no, multi-select, text, auto-categorization, code-bool, code-float Show child attributes
Show child attributes