---
title: "abort_upload_session"
method: DELETE
path: "/v1/workspaces/{workspace_id}/upload-sessions/{session_id}"
tags: ["files"]
---

# abort_upload_session

`DELETE /v1/workspaces/{workspace_id}/upload-sessions/{session_id}`

## Request

- Base URL: `https://ndi-api.nace.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://ndi-api.nace.ai/v1/workspaces/{workspace_id}/upload-sessions/{session_id}`
- Auth: API key in header `X-Upload-Token`
- TypeScript: <https://skmtc.dev/nace/apis/ndi-service/docs/v1/workspaces/:workspace_id/upload-sessions/:session_id/delete.ts> (a function with typed inputs; its response is checked against the schema)

Abort a chunked upload and reclaim its staged parts. Cost class: **fast**.

Idempotent: a session that already completed or was already aborted
answers 204 without touching anything — this only ever removes staged
*parts*, never a landed artifact.

Args:
    session: Database session.
    auth: The resolved session context and row.

## Path parameters

- `workspace_id` string, uuid, required: Workspace identifier.
- `session_id` string, uuid, required: Upload session identifier.

## Response `204`

Successful Response

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `402`: Payment Required
- `403`: Forbidden
- `404`: Not Found
- `409`: Conflict
- `410`: Gone
- `413`: Request Entity Too Large
- `422`: Unprocessable Entity
- `424`: Failed Dependency
- `429`: Too Many Requests
- `500`: Internal Server Error
- `501`: Not Implemented
- `503`: Service Unavailable
- `504`: Gateway Timeout

---

[API](https://skmtc.dev/nace/apis/ndi-service.md) - [All operations](https://skmtc.dev/nace/apis/ndi-service/llms.txt) - [OpenAPI document](https://skmtc.dev/nace/apis/ndi-service/revisions/d9d1f8ec2207?raw)
