Updates either:
- An existing file entry with a new file supplied in the multipart HTTP call, retaining the fileId, references, createdBy, and uploaderId fields
- Existing file record properties with those received via query parameters
Request Parameters
Name | Type | Comments |
---|---|---|
file | File Field | (Optional) A single file to replace the existing file, supplied as a file field in the multipart POST request. |
uploaderId | Query Param | (Optional) Update/set the freetext identifier of the uploader (e.g. the site username) |
originalFileName | Query Param | (Optional) Update the file name for the stored file. |
mimeType | Query Param | (Optional) Update the mime type for the stored file. |
lastUpdatedBy | Query Param | (Optional) Update who last updated the file. |
Example Request
Example response - Success
Note that the file has been updated but the id is still the same.
{
"id": "c1c80e72-244c-4111-87cf-bdbbe5cd570b",
"filename": "pusheen.png",
"type": "image/png",
"hash": "ba44f7f8f88543fbf91f9b9eb0217cfe",
"size": 37029,
"references": [],
"created": "2016-02-22T11:40Z",
"createdBy": "Pusheen",
"lastUpdated": "2016-02-22T11:40Z",
"lastUpdatedBy": "Stormy"
}
Last modified on June 27, 2023