Rerun Call Executions

Rerun call executions within a test execution. Choose eval_only to re-evaluate existing data or call_and_eval to re-run calls. Returns success and failure counts per call.

POST https://api.futureagi.com/simulate/test-executions/{test_execution_id}/rerun-calls/

Authentication

X-Api-Key API Key Required

Your Future AGI API key used to authenticate requests. You can find and manage your API keys in the Dashboard under Settings.

X-Secret-Key Secret Key Required

Your Future AGI secret key, used alongside the API key for request authentication. This is generated when you create an API key in the Dashboard.

Path parameters

test_execution_id UUID Required

The test execution ID. Must be in a terminal state (completed, failed, or cancelled).

Request body

rerun_type string Required

The type of rerun to perform. Use eval_only to re-evaluate existing call data without re-executing the actual calls — this is useful when you have updated your evaluation configurations and want to see updated scores without the cost of re-running calls. Use call_and_eval to fully re-execute the calls and then evaluate the new results — this produces fresh conversations and is useful when you have modified the agent under test. Note that text agents only support eval_only reruns; attempting call_and_eval on a text agent will return a 400 error.

call_execution_ids array of strings Optional

An array of call execution UUIDs to rerun. Required when select_all is false or not provided. Each ID must correspond to a valid call execution within the specified test execution. If a provided ID does not exist or does not belong to the test execution, it will appear in the failed_reruns array of the response.

select_all boolean Optional

When set to true, all call executions within the test execution will be rerun, and the call_execution_ids field is ignored. Defaults to false. You must provide either select_all: true or a non-empty call_execution_ids array — the request will fail with a 400 error if neither is specified.

Response

200 OK
message string

A human-readable confirmation message indicating that the rerun has been initiated. The actual rerun processing happens asynchronously after this response is returned.

test_execution_id string

The UUID of the test execution that the rerun was initiated for, echoed back for confirmation and reference.

rerun_type string

The type of rerun that was requested, either eval_only or call_and_eval. Echoed back from the request for confirmation.

total_processed integer

The total number of call executions that were processed by the rerun request. This includes both successful and failed reruns.

successful_reruns array

An array of call execution UUIDs that were successfully queued for rerun. These calls will be re-executed or re-evaluated asynchronously.

failed_reruns array

An array of objects describing call executions that could not be rerun. Each object contains a call_execution_id (the UUID of the failed call) and an error (a human-readable description of why the rerun failed, such as the call being in an incompatible state).

success_count integer

The number of call executions that were successfully queued for rerun. Equal to the length of the successful_reruns array.

failure_count integer

The number of call executions that failed to be queued for rerun. Equal to the length of the failed_reruns array.

Errors

400 Bad Request Optional

The rerun request could not be processed. This error occurs when: the rerun_type field is missing or contains an invalid value; neither call_execution_ids nor select_all was provided; the test execution is still in an active state (pending, running, or cancelling) and cannot accept reruns; or a call_and_eval rerun was requested for a text agent, which only supports eval_only reruns. Check the error message in the response body for specific details on which validation failed.

401 Unauthorized Optional

The request could not be authenticated. Verify that both X-Api-Key and X-Secret-Key headers are present and contain valid, non-expired credentials. Ensure the API key has access to the workspace that owns this test execution.

404 Not Found Optional

Test execution not found.

500 Internal Server Error Optional

Unexpected server error.

GET /
Authentication
REQUEST
 
RESPONSE