> For the complete documentation index, see [llms.txt](https://developer.topazlabs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.topazlabs.com/reference/video/cancel-estimate/estimate-cancellation-outcome.md).

# Estimate Cancellation Outcome

Preview the credit outcome of canceling a request without actually canceling it.

This uses the same settlement math as the cancel endpoint (DELETE /video/{requestId}), so the estimate reflects what you would be charged and refunded if you cancel now.

* If the request has not started processing, canceling refunds all reserved credits and charges nothing.
* If the request is partially processed, canceling commits a prorated amount (plus a small cancellation penalty) and refunds the remainder.
* If the request is already canceling or canceled, it is reported as not cancelable with a zeroed estimate.

Requests that have already completed or failed cannot be canceled and return a 400.

### Response body

| **Property**        | **Type** | **Description**                                             |
| ------------------- | -------- | ----------------------------------------------------------- |
| **requestId**       | UUID     | Unique request identifier                                   |
| **status**          | String   | Current processing status                                   |
| **cancelable**      | Boolean  | Whether the request can still be canceled                   |
| **progress**        | Integer  | Processing progress used for settlement (percentage, 0-100) |
| **creditsReserved** | Integer  | Credits currently reserved for the request                  |
| **creditsToCommit** | Integer  | Credits that would be charged if canceled now               |
| **creditsToRefund** | Integer  | Credits that would be refunded if canceled now              |
| **message**         | String   | Human-readable summary of the cancellation outcome          |

```json
{"openapi":"3.0.3","info":{"title":"Video API","version":"1.0.0"},"tags":[{"name":"Cancel Estimate","description":"This section allows you to preview the credit outcome of canceling a request\n"}],"servers":[{"url":"https://api.topazlabs.com","description":"Production API base URL"}],"security":[{"apiKey":[]}],"components":{"securitySchemes":{"apiKey":{"type":"apiKey","in":"header","name":"X-API-Key"}},"schemas":{"CancelEstimateResponse":{"type":"object","description":"Preview of the credit settlement that would occur if the request is canceled now.","properties":{"requestId":{"type":"string","format":"uuid"},"status":{"type":"string","enum":["requested","accepted","initializing","preprocessing","processing","postprocessing","complete","canceling","canceled","failed"]},"cancelable":{"type":"boolean","description":"False if the request is already canceling or canceled"},"progress":{"type":"integer","description":"Processing progress used for settlement, as a percentage (0-100)"},"creditsReserved":{"type":"integer","description":"Credits currently reserved for the request"},"creditsToCommit":{"type":"integer","description":"Credits that would be charged for work completed so far"},"creditsToRefund":{"type":"integer","description":"Credits that would be refunded"},"message":{"type":"string"}}}},"responses":{"BadRequest":{"description":"Bad request","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"errorCode":{"type":"string","enum":["INSUFFICIENT_CREDITS","INVALID_INPUT","FORBIDDEN","UNAUTHORIZED","SERVER_MAINTENANCE","SERVER_ERROR","UNKNOWN"]},"errors":{"type":"array","description":"Present when the request failed schema validation. One entry per offending field.","items":{"type":"object","properties":{"type":{"type":"string"},"path":{"type":"string"},"location":{"type":"string"},"msg":{"type":"string"},"value":{}}}}}}}}},"Unauthorized":{"description":"Unauthorized","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"errorCode":{"type":"string","enum":["INSUFFICIENT_CREDITS","INVALID_INPUT","FORBIDDEN","UNAUTHORIZED","SERVER_MAINTENANCE","SERVER_ERROR","UNKNOWN"]}}}}}},"Forbidden":{"description":"Forbidden","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"errorCode":{"type":"string","enum":["INSUFFICIENT_CREDITS","INVALID_INPUT","FORBIDDEN","UNAUTHORIZED","SERVER_MAINTENANCE","SERVER_ERROR","UNKNOWN"]}}}}}},"NotFound":{"description":"Enhancement request with the provided ID not found","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"errorCode":{"type":"string","enum":["INSUFFICIENT_CREDITS","INVALID_INPUT","FORBIDDEN","UNAUTHORIZED","SERVER_MAINTENANCE","SERVER_ERROR","UNKNOWN"]}}}}}},"InternalServerError":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"errorCode":{"type":"string","enum":["INSUFFICIENT_CREDITS","INVALID_INPUT","FORBIDDEN","UNAUTHORIZED","SERVER_MAINTENANCE","SERVER_ERROR","UNKNOWN"]}}}}}}}},"paths":{"/video/{requestId}/cancel-estimate":{"get":{"tags":["Cancel Estimate"],"summary":"Estimate Cancellation Outcome","operationId":"GetCancelEstimate","description":"Preview the credit outcome of canceling a request without actually canceling it.\n\nThis uses the same settlement math as the cancel endpoint (DELETE /video/{requestId}), so the estimate reflects what you would be charged and refunded if you cancel now.\n\n- If the request has not started processing, canceling refunds all reserved credits and charges nothing.\n- If the request is partially processed, canceling commits a prorated amount (plus a small cancellation penalty) and refunds the remainder.\n- If the request is already canceling or canceled, it is reported as not cancelable with a zeroed estimate.\n\nRequests that have already completed or failed cannot be canceled and return a 400.\n\n## Response body\n\n| **Property**        | **Type** | **Description**                                              |\n|---------------------|----------|-------------------------------------------------------------|\n| **requestId**       | UUID     | Unique request identifier                                   |\n| **status**          | String   | Current processing status                                   |\n| **cancelable**      | Boolean  | Whether the request can still be canceled                   |\n| **progress**        | Integer  | Processing progress used for settlement (percentage, 0-100) |\n| **creditsReserved** | Integer  | Credits currently reserved for the request                  |\n| **creditsToCommit** | Integer  | Credits that would be charged if canceled now               |\n| **creditsToRefund** | Integer  | Credits that would be refunded if canceled now              |\n| **message**         | String   | Human-readable summary of the cancellation outcome          |\n","parameters":[{"in":"path","name":"requestId","schema":{"type":"string","format":"uuid"},"required":true}],"responses":{"200":{"description":"Successful response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CancelEstimateResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/InternalServerError"}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://developer.topazlabs.com/reference/video/cancel-estimate/estimate-cancellation-outcome.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
