Download one submitted file

gethttps://api.expiryedge.com/v1/getCollectionSubmissionFile
any role (admin, editor or viewer) in the organization60/min
Request
curl 'https://api.expiryedge.com/v1/getCollectionSubmissionFile?submissionId=sub_Qm3r&fieldId=fld_insurance&mode=preview' \
  -H "Authorization: Bearer $EXPIRYEDGE_API_KEY"
Response
<file>

Streams the file uploaded for fieldId, with the Content-Type recorded at upload. Pass historyIndex for a file replaced by a resubmission (field_history[fieldId][historyIndex]). Query string only. The handler does not check the HTTP method.

Query parameters

  • submissionIdstringrequired
  • fieldIdstringrequired
  • modestring
    download sends Content-Disposition: attachment, anything else inline.
    AllowedpreviewdownloadDefault preview
  • historyIndexinteger
    min: 0

Returns

200
The file bytes. The actual Content-Type is the uploaded file type (for example application/pdf or image/png).

file

Errors

400
The request is missing required fields or contains invalid values.
401
Missing, expired or invalid bearer token.
403
Your role does not allow this, or the record belongs to another organization ({"error": "Access denied"}).
404
The record does not exist or is not in your organization.
429
Too many requests for this endpoint from your IP. Wait Retry-After seconds.
500
Storage read failed mid-stream (no JSON body).