---
title: "Cancel Refinement"
method: POST
path: "/questionnaires/jobs/{job_id}/refine/cancel"
tags: ["questionnaires"]
---

# Cancel Refinement

`POST /questionnaires/jobs/{job_id}/refine/cancel`

## Request

- Base URL: `https://api.threadchain.pro` (the document declares no server; this is the origin it was published from)
- URL: `https://api.threadchain.pro/questionnaires/jobs/{job_id}/refine/cancel`
- Auth: OAuth 2
  - Password
  - Token URL: `auth/token`

Cancel an in-flight refinement operation for a specific side.

Behavior:
- Revokes matching Celery refine task(s) for this job/side.
- Attempts termination for already running tasks.
- Rolls back one refinement counter increment for this side so user can start over.

Allowed callers: session owner or an admin.

## Path parameters

- `job_id` string, uuid, required

## Request body `application/x-www-form-urlencoded`

- BodyCancelRefinementQuestionnairesJobsJobIdRefineCancelPost
  - `side` string, required: 'front' or 'back'
  - `asset` string: '3d' or '2d' — must match the refine being cancelled

## Response `200`

Successful Response

- unknown

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/threadchain/apis/threadchain-backend.md) - [All operations](https://skmtc.dev/threadchain/apis/threadchain-backend/llms.txt) - [OpenAPI document](https://skmtc.dev/threadchain/apis/threadchain-backend/revisions/8ee288a7e6bd?raw)
