---
title: "Cancel a file's upload into a reply"
method: DELETE
path: "/hd/desks/{desk_id}/tickets/{number}/attachments/{attachment_id}"
tags: ["hd"]
---

# Cancel a file's upload into a reply

`DELETE /hd/desks/{desk_id}/tickets/{number}/attachments/{attachment_id}`

## Request

- Base URL: `https://api.sparkvault.com/v1`
- URL: `https://api.sparkvault.com/v1/hd/desks/{desk_id}/tickets/{number}/attachments/{attachment_id}`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/sparkvault/apis/sparkvault-api/docs/hd/desks/:desk_id/tickets/:number/attachments/:attachment_id/delete.ts> (a function with typed inputs; its response is checked against the schema)

Cancel one of the customer's own uploads into a reply on their request, a file they removed before sending the reply: the upload is deleted, and what it held of the customer's upload allowance is given back at once. For a request merged into another, the upload is looked for on the request its merges lead to as well. An id that names none of the customer's uploads waiting to be sent is answered the same, so a cancel sent again changes nothing.

## Path parameters

- `desk_id` string, required
- `number` string, required
- `attachment_id` string, required

## Headers

- `X-SV-Client` 'help-desk-portal', required

## Response `204`

No upload of the customer's under this id waits to be sent on the request.

## Other responses

- `401`: CUSTOMER_AUTH_REQUIRED — no bearer token, or one that is not a customer's of this desk now: unknown, expired, revoked, another desk's, or of the sign-in mode the desk no longer uses.
- `404`: NOT_FOUND — no such request, draft or file is the customer's: one that does not exist and one of another customer read the same, byte for byte.
- `409`: CONFLICT — the request kept changing while this was saved. Send it again.
- `503`: HELP_DESK_UNAVAILABLE — the desk does not take customers right now, or this customer is refused. INTERNAL_ERROR — the identity service's keys could not be read to verify a Secure Identity bearer. BUDGET_UNAVAILABLE — a budget the request spends could not be counted, so the request was refused rather than let through uncounted; `Retry-After` carries the seconds to wait before trying again.

## Changes

- **2026-10-28** `a9a10e328ba5`: 16 info
  - the response property `error/details` became required for the status `401`
  - the response property `error/details` became required for the status `404`
  - the response property `error/details` became required for the status `409`
  - the response property `error/details` became required for the status `503`
  - …12 more
- **2026-10-28** `56d7c265a77a`: 4 breaking
  - the response property `error/details` became nullable for the status `401`
  - the response property `error/details` became nullable for the status `404`
  - the response property `error/details` became nullable for the status `409`
  - the response property `error/details` became nullable for the status `503`
- **2026-10-28** `fecd5111028e`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/sparkvault/apis/sparkvault-api/changes/hd/desks/:desk_id/tickets/:number/attachments/:attachment_id/delete.md)

---

[API](https://skmtc.dev/sparkvault/apis/sparkvault-api.md) - [All operations](https://skmtc.dev/sparkvault/apis/sparkvault-api/llms.txt) - [OpenAPI document](https://skmtc.dev/sparkvault/apis/sparkvault-api/revisions/97cfadccd0c0?raw)
