云空间服务 KOODRIVE-创建文件元数据:请求示例

时间:2024-10-25 10:26:02

请求示例

通过“分片上传”方式创建文件元数据,该示例指定了一个分片,后续响应会返回对应分片的上传地址,需要将对应分片通过PUT请求上传对应的分片。

POST /koodrive/ose/v1/files/create

Authorization:Bearer+10f88*********4791e9ff

{
    "containerId": "IAADfsBFCO6WtAtuA9add2fea594e4e75b8feb8474ef236",
    "parentFolder": [
        "root"
    ],
    "createdTime": "2020-05-18T01:43:49Z",
    "mimeType": "application/x-zip-compressed",
    "fileType": 35,
    "fileName": "demo.zip",
    "sha256": "08a784aeb181506391c20c6355f881dc363d8c3e0739d295e5d6f410d05dbc69",
    "length": 22106481,
    "uploadMode": "multipart",
    "uploadType": 1,
    "autoRename": 2,
    "multiParts": [
        {
            "partNumber": 1,
            "partOffset": 0,
            "partSize": 22106481
        }
    ],
    "description": ""
}
support.huaweicloud.com/api-koodrive/createFile.html