curl -X DELETE "$ATAI_API_ENDPOINT/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y" \
-H "Authorization: Bearer $ATAI_API_KEY"
import os
import requests
base_url = os.environ["ATAI_API_ENDPOINT"]
api_key = os.environ["ATAI_API_KEY"]
response = requests.delete(
f"{base_url}/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y",
headers={"Authorization": f"Bearer {api_key}"},
)
if response.status_code == 204:
print("Eval deleted")
elif response.status_code == 409:
print("Eval is not terminal — cancel it first")
else:
print(f"Error: {response.json()['errors']}")
const response = await fetch(
`${process.env.ATAI_API_ENDPOINT}/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y`,
{
method: 'DELETE',
headers: {
'Authorization': `Bearer ${process.env.ATAI_API_KEY}`
}
}
);
if (response.status === 204) {
console.log('Eval deleted');
} else if (response.status === 409) {
console.error('Eval is not terminal — cancel it first');
} else {
const body = await response.json();
console.error('Error:', body.errors);
}
{
"errors": [
{
"code": "<error_code>",
"message": "Eval not found.",
"suggestion": null,
"error_uid": "err-xxxxxxxx"
}
]
}
{
"errors": [
{
"code": "<error_code>",
"message": "Eval is not in a terminal state (cancel it first).",
"suggestion": null,
"error_uid": "err-xxxxxxxx"
}
]
}
Evals
Delete Eval
Delete a terminal eval by id
DELETE
/
agents
/
evals
/
{eval_id}
curl -X DELETE "$ATAI_API_ENDPOINT/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y" \
-H "Authorization: Bearer $ATAI_API_KEY"
import os
import requests
base_url = os.environ["ATAI_API_ENDPOINT"]
api_key = os.environ["ATAI_API_KEY"]
response = requests.delete(
f"{base_url}/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y",
headers={"Authorization": f"Bearer {api_key}"},
)
if response.status_code == 204:
print("Eval deleted")
elif response.status_code == 409:
print("Eval is not terminal — cancel it first")
else:
print(f"Error: {response.json()['errors']}")
const response = await fetch(
`${process.env.ATAI_API_ENDPOINT}/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y`,
{
method: 'DELETE',
headers: {
'Authorization': `Bearer ${process.env.ATAI_API_KEY}`
}
}
);
if (response.status === 204) {
console.log('Eval deleted');
} else if (response.status === 409) {
console.error('Eval is not terminal — cancel it first');
} else {
const body = await response.json();
console.error('Error:', body.errors);
}
{
"errors": [
{
"code": "<error_code>",
"message": "Eval not found.",
"suggestion": null,
"error_uid": "err-xxxxxxxx"
}
]
}
{
"errors": [
{
"code": "<error_code>",
"message": "Eval is not in a terminal state (cancel it first).",
"suggestion": null,
"error_uid": "err-xxxxxxxx"
}
]
}
Requires version 1.1.12 or later of the Archetype platform.
Overview
This endpoint deletes a finished eval by itsevl_ id. The eval’s output artifacts are removed
from file storage with it.
Only terminal evals (those whose status is
completed, failed, or cancelled) can be
deleted. An eval that is still pending or running returns HTTP status 409; cancel it
first with Cancel Eval.403 when you can see the
project but not modify it, and 404 when you cannot see the project.
Request
Response
Returns204 No Content with an empty body on success.
Check the status code for a
204 response rather than parsing a response.curl -X DELETE "$ATAI_API_ENDPOINT/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y" \
-H "Authorization: Bearer $ATAI_API_KEY"
import os
import requests
base_url = os.environ["ATAI_API_ENDPOINT"]
api_key = os.environ["ATAI_API_KEY"]
response = requests.delete(
f"{base_url}/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y",
headers={"Authorization": f"Bearer {api_key}"},
)
if response.status_code == 204:
print("Eval deleted")
elif response.status_code == 409:
print("Eval is not terminal — cancel it first")
else:
print(f"Error: {response.json()['errors']}")
const response = await fetch(
`${process.env.ATAI_API_ENDPOINT}/agents/evals/evl_01jcb0h2m6t4xr9nv3k7pdzs5y`,
{
method: 'DELETE',
headers: {
'Authorization': `Bearer ${process.env.ATAI_API_KEY}`
}
}
);
if (response.status === 204) {
console.log('Eval deleted');
} else if (response.status === 409) {
console.error('Eval is not terminal — cancel it first');
} else {
const body = await response.json();
console.error('Error:', body.errors);
}
{
"errors": [
{
"code": "<error_code>",
"message": "Eval not found.",
"suggestion": null,
"error_uid": "err-xxxxxxxx"
}
]
}
{
"errors": [
{
"code": "<error_code>",
"message": "Eval is not in a terminal state (cancel it first).",
"suggestion": null,
"error_uid": "err-xxxxxxxx"
}
]
}
Was this page helpful?