Skip to main content

Post Doc API

MethodAPIDescription
POST/{context}/{docId}/contentUpload the document specified by docId, where docId is the document ID in the third-party service. Returns the latest modification time of this document in JSON format.

The platform server uploads files through formData. Content type is multipart/form-data. Not form_url_encoded, nor x-www-form-urlencoded.

ParameterRequiredLocationDescriptionTypeDefault Value
docIdYesPathSpecifies the file ID. Note that the file ID cannot contain colon ':'string
Content-TypeYesHeaderFixed as multipart/form-datastring
fileYesBody(form data)The file itself, contains two attributes: filename (fixed as content, please ignore. Currently, file names will not be modified through this API), contentType (the file's mimeType, e.g., 'application/octet-stream')multipartfile

After successful upload, the latest file modification time needs to be returned.

For example:

{
"modified_at": "2020-03-25T02:57:38.000Z" // Required, this time should be the latest save time of this file in the business system, and this save is brought about by this API.
}