Tasks

Cancel async task

Cancels a queued asynchronous task when cancellation is supported for the selected task. Cancellation currently supports queued Seedance video tasks (seedance-2.0 and seedance-2.0-fast) while they are still waiting to run. Tasks that are already processing, completed, failed, expired, or unsupported are not cancelled.

delete/v1/tasks/{id}

Request

  • Base URL: https://api.tokenlab.sh
  • URL: https://api.tokenlab.sh/v1/tasks/{id}
  • Auth: HTTP bearer

Path parameters

idstring required

The async task ID returned by id / task_id, or embedded in poll_url

Response

Task cancelled. The task remains queryable and is represented as failed with cancelled: true for compatibility with existing async task status values.

idstring
status'pending' | 'processing' | 'completed' | 'failed'
progressinteger

Optional progress value returned only when a real progress value is available; use status to determine completion.

createdinteger
updatedinteger
modelstring
task_idstring
poll_urlstring
cancelledboolean

True when a queued async task was cancelled before execution. Cancelled tasks are represented with status: failed for compatibility with existing async task status values.

cancellation_status'cancelled'

Cancellation marker for tasks cancelled through the public async task endpoint.

billing_transaction_idstring
video_urlstring
videosobject[]
dataobject[]
audio_urlstring
titlestring
lyricsstring
model_urlstring
glb_urlstring
fbx_urlstring

Example response

{
  "media_retention": {
    "days": 30
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.