Cancel policy
Cancels a single policy; the other policies of the same order are not affected. Cancellation is always asynchronous and two-phase: the request puts the policy in cancellation_requested and the effective cancellation (canceled) only happens when the insurer confirms — until then, coverage remains in force.
To cancel all policies of an order at once, use the order cancellation on an emitted order.
Premium refund
At cancellation confirmation, QI Tech determines the basis and computes the refund amount automatically, over the gross premium (gross_premium_amount):
| Cancellation moment | Refund basis |
|---|---|
Within 7 calendar days of the issuance confirmation (issued) — cooling-off right | Full premium refund. |
| After 7 days | Refund proportional to the unelapsed coverage period (pro rata). |
The cancellation confirmation arrives through the cancellation webhook and the refund to the payer is executed by QI Tech.
Request
Path params
| Parameter | Type | Required | Description |
|---|---|---|---|
policy_key | string | required | Policy key. |
{
"reason": "Customer requested cancellation"
}
| Field | Type | Required | Description |
|---|---|---|---|
reason | string | optional | Cancellation reason, recorded in the event trail and echoed in the cancellation webhook. |
Response
{
"policy_key": "0b6e7c1a-9a4e-4c1e-b1d4-2f5a8c9e0d31",
"order_key": "5e2b3f60-7c4b-4c8e-9f1a-6d2e8b4a7c90",
"status": "cancellation_requested"
}
Completion arrives through the policy webhook with status canceled, and can be tracked through the policy retrieval.
Semantics per status
| Current policy status | Result |
|---|---|
issued | 202 — cancellation requested from the insurer. |
cancellation_requested | 202 — idempotent: no second request is produced and the same body is returned. |
issuance_requested | 409 — the policy is not in force yet. To undo the whole sale at this stage, cancel the order (the request is retained and cancels the policy automatically as soon as the issuance confirms); to cancel only this policy, wait for the issuance to confirm. |
canceled | 409 — already canceled. |
finished | 409 — the term has already ended. |
| another integration / nonexistent | 404 |
Possible errors
Every error (non-2xx) returns the standard body { "title", "description", "translation", "code" } — programmatically handle only the code field.
| Status | Code | Description |
|---|---|---|
401 / 403 | — | Authentication or authorization failure. |
404 | POL000001 | Policy nonexistent or belonging to another integration. |
409 | POL000010 | The policy has already been canceled. |
409 | POL000011 | The coverage term has already ended. |
409 | POL000012 | The policy is not in force yet. |
429 | — | Request limit exceeded — retry with backoff. |
500 | QIT000500 | Internal error — the request is idempotent, retry the call. |
503 | POL000030 | Service unavailable — the request is idempotent, retry the call. |