Labelling
Cancel labeling job
Request cancellation of a labeling job. Running work may stop asynchronously.
POST
/
v1
/
labeling
/
jobs
/
{job_id}
/
cancel
Cancel labeling job
curl --request POST \
--url https://api.sqwish.ai/v1/labeling/jobs/{job_id}/cancel \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sqwish.ai/v1/labeling/jobs/{job_id}/cancel"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sqwish.ai/v1/labeling/jobs/{job_id}/cancel', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "<string>",
"name": "<string>",
"source_id": "<string>",
"status": "queued",
"teacher_models": [
"<string>"
],
"rows": 123,
"completed_rows": 123,
"valid_rows": 123,
"agreement_rows": 123,
"error_rows": 123,
"created_at": 123,
"updated_at": 123,
"price_usd": "<string>",
"charge": "free",
"dataset_id": "<string>",
"error": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}Authorizations
Create an API key in the console.
Path Parameters
Response
Successful Response
deleted: you deleted its source, and with it the queries and the teachers' answers. The job and its counts stay.
Available options:
queued, running, cancelling, cancelled, review_ready, failed, finalized, discarded, deleted The job's fee, as exact USD: each of its teachers' price for a row, for every row.
What the fee is doing: held while the job runs, charged once its labels are ready for review, released if it fails or is cancelled first.
Available options:
free, reserved, charged, released Cancel labeling job
curl --request POST \
--url https://api.sqwish.ai/v1/labeling/jobs/{job_id}/cancel \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.sqwish.ai/v1/labeling/jobs/{job_id}/cancel"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.sqwish.ai/v1/labeling/jobs/{job_id}/cancel', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "<string>",
"name": "<string>",
"source_id": "<string>",
"status": "queued",
"teacher_models": [
"<string>"
],
"rows": 123,
"completed_rows": 123,
"valid_rows": 123,
"agreement_rows": 123,
"error_rows": 123,
"created_at": 123,
"updated_at": 123,
"price_usd": "<string>",
"charge": "free",
"dataset_id": "<string>",
"error": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"retryable": true,
"request_id": "<string>",
"details": [
{
"path": [
"<string>"
],
"message": "<string>",
"type": "<string>"
}
]
}
}