GET
Download a file from an inbox document
Scope:
inbox:inbox.readhttps://api.holded.com/api/v2/inbox/{incomingDocumentId}/files/{filename}/downloadReturns the raw content of a file attached to an incoming document. Use `?variant=inline` to display the file in-browser with 24-hour caching instead of triggering a download.
Parameters
Path parameters
incomingDocumentId
stringrequiredIncoming document identifier
filename
stringrequiredName of the file to retrieve
Query parameters
variant
stringoptional= downloadDelivery mode: download (attachment) or inline (display with cache)
"download""inline"Request
python
import requests
url = "https://api.holded.com/api/v2/inbox/507f1f77bcf86cd799439011/files/document.pdf/download?variant=download"
headers = {
"Authorization": "Bearer YOUR_API_KEY",
"Accept": "application/json",
}
response = requests.get(url, headers=headers)
print(response.json())Responses
Response
json
"string"Success responses
200File contentapplication/octet-streamstring<binary>
Error responses
401Invalid or missing API keyapplication/json403Insufficient permissionsapplication/json404Document or file not foundapplication/json429Rate limit exceededapplication/json