API 參考
替換檔案
以新檔案替換既有檔案的內容,短網址與檔案網址維持不變。
POST
multipart/form-data- body
file*fileThe new file. The key should be 'file' (alias 'smfile').
Format
binaryfile_id*integerID of the file to replace (the file_id returned by the upload API).
OK
application/json- response
code?integerResponse status code (200 indicates success)
data?File upload response
message?stringHuman-readable status message
curl -X POST 'https://s.ee/api/v1/file/replace' \ -H 'Authorization: string' \ -F 'file=string' \ -F 'file_id=0'Example Response200
{ "code": 0, "data": { "created_at": 0, "delete": "string", "file_id": 0, "filename": "string", "hash": "string", "height": 0, "mime_type": "string", "page": "string", "path": "string", "size": 0, "storename": "string", "thumb_url": "string", "upload_status": 0, "url": "string", "width": 0 }, "message": "string"}