Retry Batch Jobs
Retry all failed jobs in a batch.
This endpoint resets all jobs with state='error' back to state='pending', clears their output data, increments their retry count, and re-dispatches the first pending job of each affected task to the SQS queue.
Failed jobs whose input payload the retention sweep already cleared are
skipped and counted in jobs_skipped_expired — retrying them would
re-dispatch an empty payload. Retention is irreversible, so those jobs
stay in error.
No quota is consumed for retries - the retry_count field distinguishes retry attempts from new job executions.
Args: batch_id: The batch ID of the batch to retry
Returns: Response with retry statistics including jobs reset and tasks affected
Raises: 404: If batch not found 403: If user lacks permissions to retry this batch
HTTPBearerAuthorizationBearer <token>batch_id*Batch IdSuccessful Response
application/json- response
Response for retrying failed jobs in a batch.
message*Messagebatch_id*Batch Idjobs_reset*Jobs Resetjobs_skipped_expired?Jobs Skipped Expired0tasks_affected*Tasks Affectedcurl -X POST 'https://app.copyhero.app/api/v1/tasks/batch/0/retry'{ "message": "string", "batch_id": 0, "jobs_reset": 0, "jobs_skipped_expired": 0, "tasks_affected": 0}