Cancel a batch

Stops what has not started. Keeps what has landed.

POSThttps://api.easydata.win/v1/batches/{id}/cancel
free

Stops items that have not started yet. Anything already delivered stays delivered and stays readable, and anything in flight finishes rather than being thrown away half-scraped - you were going to be charged for that fetch either way, so you may as well have the record.

Request #

FieldTypeNotes
idrequiredpathThe batch id.

Call it #

cURL
curl -X POST "https://api.easydata.win/v1/batches/{id}/cancel" \
  -H "X-API-Key: $API_KEY"

Response #

JSON
{
  "data": { "batch_id": "afec9131-080b-4b96-b3bb-726249e4bbf8", "status": "cancelled", "...": "Batch" },
  "meta": { "requestId": "req_8f2ka91x" }
}

Errors #

StatusTypeWhen
401invalid_api_keyMissing, malformed, revoked or expired key. Never metered.
404not_foundNo such batch.
409conflictThe batch has already finished.

Every failure uses the same envelope, and none of them is metered - see Errors.