Skip to content

文件秒传

标签文件

请求说明

字段
请求地址
https://openapi.wps.cn/v7/drives/{drive_id}/files/{parent_id}/rapid_upload
HTTP 方法
POST
接口描述
文件秒传(,公网更多信息可参考文档https://365.kdocs.cn/l/crFv0h0JW5oU)
签名方式
KSO-1
限频策略
权限要求
查询和管理文件(应用授权) kso.file.readwrite
查询和管理文件(用户授权) kso.file.readwrite

请求头 (Headers)

属性名类型是否必填描述可选值
X-Kso-Id-Type
string类型
* internal - 内部
* external - 外部
internal, external

路径参数 (Path)

属性名类型是否必填描述可选值
drive_id
string驱动盘id-
parent_id
string文件夹id(根目录时为0)-

请求体(Body)

请求体格式: application/json

没有可用的数据

请求体示例

json
{
  "display_size": 0,
  "file_id": "string",
  "hashes": [
    {
      "sum": "string",
      "type": "sha256"
    }
  ],
  "name": "string",
  "on_name_conflict": "fail",
  "parent_path": [
    "string"
  ],
  "proof": {
    "code": "string",
    "token": "string"
  },
  "size": 0
}

响应体(Response)

HTTP状态码: 200
响应体格式: application/json

没有可用的数据

响应体示例

json
{
  "data": {
    "created_by": {
      "avatar": "string",
      "company_id": "string",
      "id": "string",
      "name": "string",
      "type": "user"
    },
    "ctime": 0,
    "drive": {
      "allotee_id": "string",
      "allotee_type": "user",
      "company_id": "string",
      "created_by": {
        "avatar": "string",
        "company_id": "string",
        "id": "string",
        "name": "string",
        "type": "user"
      },
      "ctime": 0,
      "description": "string",
      "ext_attrs": [
        {
          "name": "string",
          "value": "string"
        }
      ],
      "id": "string",
      "mtime": 0,
      "name": "string",
      "quota": {
        "deleted": 0,
        "remaining": 0,
        "total": 0,
        "used": 0
      },
      "source": "string",
      "status": "inuse"
    },
    "drive_id": "string",
    "ext_attrs": [
      {
        "name": "string",
        "value": "string"
      }
    ],
    "id": "string",
    "link_id": "string",
    "link_url": "string",
    "modified_by": {
      "avatar": "string",
      "company_id": "string",
      "id": "string",
      "name": "string",
      "type": "user"
    },
    "mtime": 0,
    "name": "string",
    "parent_id": "string",
    "permission": {
      "comment": true,
      "copy": true,
      "copy_content": true,
      "delete": true,
      "download": true,
      "history": true,
      "list": true,
      "move": true,
      "new_empty": true,
      "perm_ctl": true,
      "preview": true,
      "print": true,
      "rename": true,
      "saveas": true,
      "secret": true,
      "share": true,
      "update": true,
      "upload": true
    },
    "shared": true,
    "size": 0,
    "type": "folder",
    "version": 0
  },
  "code": 0,
  "msg": "string"
}