[POST] /file

[POST] /file

/api/dms/objects/{objectId}/contents/file

Description

To replace the content of a specific DMS object with the given {objectId}, send the request with metadata as request body. This endpoint accepts only one content file at a time. To update/replace multiple content files, use POST /api/dms/objects/{objectId}.
The result JSON contains information on the new content elements.

Request
Method

POST

Request
Header

Content type: application/octet-stream
Content-Disposition: attachment; filename=<filename>filename*=<filename-encoded>. To set the filename of the new content file. The parameters "filename" and "filename*" differ only in that "filename*" uses the encoding defined in RFC 5987. When both "filename" and "filename*" are present in a single header field value, "filename*" is preferred over "filename". This header is in the future required.

Response
Format

JSON

Minimum Version

3.0.0

Request
Example

The new content file is passed as binary in the request body.

Result
Example

[{ "cid":"1", "length":433994, "mimeType":"application/pdf", "fileName":"1.pdf" }]