invalid-file-type
HTTP 400 Bad Request
The uploaded file is not of a type this endpoint accepts. Nothing is stored. detail names the reason.
Triggers
- Files and DPP documents:
POST /v1/files/upload,PUT /v1/files/:idandPOST /v1/dpp/:id/documentsaccept PDF, PNG, JPEG, WebP, MP4, glTF/GLB and JSON. The API checks the first bytes of the file, not its name. It refuses any other type, a file whose content does not match its declaredContent-Type(a.pdfthat is not a PDF) and an empty file. - Product images:
POST /v1/dpp/:id/imagesaccepts only JPEG, PNG and WebP. - Code import:
POST /v1/codes/importaccepts only CSV or XLSX, recognised byContent-Typeor file extension.
{ "type": "https://docs.qr3.app/errors/invalid-file-type", "title": "Invalid File Type", "status": 400, "detail": "Magic bytes indicate PDF but Content-Type does not match"}