Download File
GET
/web/v1/files/query/{fileBizId}/download JWT + TurnstileDownloads a file directly as a streamed binary response. The response includes appropriate Content-Disposition, Content-Type, and Content-Length headers.
Required Headers
| Header | Example Value | Description |
|---|---|---|
| Content-Type | application/json | Request content type |
| Accept | application/json | Expected response type |
| X-Client-Hash | Client device fingerprint | |
| Accept-Language | en, zh, zh-Hant, ja, vi | Response language (default: en) |
| Authorization | Bearer | JWT access token |
| X-Workspace-Id | Target workspace ID |
Request Parameters
| Name | Type | Required | In | Description |
|---|---|---|---|---|
fileBizId | string | Required | path | File business ID |
Success Response
The response is a binary file stream with the following headers:
| Header | Example Value |
|---|---|
Content-Disposition | attachment; filename="invoice.pdf" |
Content-Type | application/pdf |
Content-Length | 102400 |
Error Responses
Unauthorized 401
{
"success": false,
"code": "4010",
"message": "Invalid or expired token"
}Not Found 404
{
"success": false,
"code": "4040",
"message": "File not found"
}Notes
- The response body is a raw binary stream, not a JSON envelope.
- For large files, consider using Get Download URL instead to offload the download to object storage directly.
- The original filename is preserved in the
Content-Dispositionheader.