Skip to main content
DELETE
Cancel a mid-upload attachment, or permanently delete an unbound one

Authorizations

Authorization
string
header
required

Clerk session token, Authorization: Bearer <token> — the first-party browser app's own auth. Used only by this internal /api/v1/* surface, never by /api/public/v1/*.

Path Parameters

attachmentId
string
required
Minimum string length: 1

Response

The cancelled or deleted attachment.

id
string
required
chatId
string | null
required
messageId
string | null
required
orderIndex
integer
required
Required range: x >= 0
status
enum<string>
required
Available options:
PENDING,
READY,
FAILED,
CANCELLED
mimeType
string | null
required
byteSize
integer | null
required
Required range: x >= 0
fileName
string | null
required
resultUrl
string<uri> | null
required
errorCode
string | null
required
errorMessage
string | null
required
createdAt
string
required
updatedAt
string
required
source
enum<string>
required
Available options:
uploaded,
generated