curl --request GET \
--url https://api.letpiper.com/v1/orgs/{org_id}/scenarios/runs/by-session/{session_id} \
--header 'Authorization: Bearer <token>'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"scenario_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"scenario_name": "<string>",
"status": "pending",
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z",
"turn_results": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"turn_index": 123,
"stopped_early": true,
"passed": true,
"response_content": "<string>",
"criteria_results": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"criteria_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"verdict": "PASS",
"criteria_question": "<string>",
"criteria_type": "llm_evaluated",
"critique": "<string>",
"evidence": "<string>",
"input_tokens": 123,
"output_tokens": 123
}
]
}
]
}Get scenario run results for a given session ID.
Returns 404 if no scenario run exists for this session.
curl --request GET \
--url https://api.letpiper.com/v1/orgs/{org_id}/scenarios/runs/by-session/{session_id} \
--header 'Authorization: Bearer <token>'{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"scenario_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"scenario_name": "<string>",
"status": "pending",
"started_at": "2023-11-07T05:31:56Z",
"completed_at": "2023-11-07T05:31:56Z",
"turn_results": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"turn_index": 123,
"stopped_early": true,
"passed": true,
"response_content": "<string>",
"criteria_results": [
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"criteria_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"verdict": "PASS",
"criteria_question": "<string>",
"criteria_type": "llm_evaluated",
"critique": "<string>",
"evidence": "<string>",
"input_tokens": 123,
"output_tokens": 123
}
]
}
]
}Platform token (starts with pat_)
Successful Response
Scenario run detail returned when looking up by session ID.
Status of a scenario run.
pending, running, passed, failed, error Show child attributes