Cancel a job
June 3, 2026
Table of contents
Cancel a running async job and free its concurrency slot. The job record is marked failed with error code user_cancelled (terminal records are simply removed from the running set).
https://api.useapi.net/v1/flowmusic/jobs/
jobid
jobidis URL-encoded in the path.
Request Headers
Authorization: Bearer {API token}
Content-Type: application/json
API tokenis required, see Setup useapi.net for details.
Responses
-
204 No Content — cancelled (or slot already freed). No body.
-
401 Unauthorized — invalid API token.
-
403 — the jobid does not belong to your account.
-
404 — no job with that id.
Model
A successful cancel returns 204 No Content with no body. Only the error responses (403 / 404) carry a JSON { error, code }.
Examples
-
JOBID="job:56ef7890-...-bot:flowmusic" curl -X DELETE -H "Authorization: Bearer YOUR_API_TOKEN" \ "https://api.useapi.net/v1/flowmusic/jobs/$(python3 -c "import urllib.parse,sys;print(urllib.parse.quote(sys.argv[1],safe=''))" "$JOBID")" -
import requests, urllib.parse jobid = 'job:56ef7890-...-bot:flowmusic' r = requests.delete('https://api.useapi.net/v1/flowmusic/jobs/' + urllib.parse.quote(jobid, safe=''), headers={'Authorization': 'Bearer YOUR_API_TOKEN'}) print(r.status_code) # 204