使用 Aspose.Cells Cloud API 将一个 Excel 工作簿合并到另一个工作簿中

REST API

此 REST API 可将 Excel 工作簿合并到另一个工作簿中。

POST https://api.aspose.cloud/v3.0/cells/{name}/merge

安全与身份验证

Aspose.Cells Cloud API 安全可靠,需要使用 基于 JWT 令牌的身份验证

查询参数

参数名 类型 描述
folder string 包含原始工作簿的文件夹。
storageName string 存储空间名称。
mergeWith string 要合并到目标工作簿中的工作簿文件名。

响应

{
    "Status":"OK",
    "Code":200,
      "Workbook": {
    "FileName": "test.xlsx",
    "Links": [
      {
        "Href": "/test.xlsx",
        "Rel": "self",
        "Title": null,
        "Type": null
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为 CSV",
        "Type": "text/csv"
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为 HTML",
        "Type": "text/html"
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为 ODS",
        "Type": "application/vnd.oasis.opendocument.spreadsheet"
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为 PDF",
        "Type": "application/pdf"
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为表格分隔文本格式",
        "Type": "text/plain"
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为 TIFF",
        "Type": "image/tiff"
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为 Microsoft Excel 2003",
        "Type": "application/vnd.ms-excel"
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为 Microsoft Excel 2007",
        "Type": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
      },
      {
        "Href": "/test.xlsx",
        "Rel": "alternate",
        "Title": "下载为 XPS",
        "Type": "application/vnd.ms-xpsdocument"
      }
    ],
    "Worksheets": {
      "link": {
        "Href": "/worksheets",
        "Rel": "self",
        "Title": null,
        "Type": null
      }
    },
    "DefaultStyle": {
      "link": {
        "Href": "/defaultstyle",
        "Rel": "self",
        "Title": null,
        "Type": null
      }
    },
    "DocumentProperties": {
      "link": {
        "Href": "/documentproperties",
        "Rel": "self",
        "Title": null,
        "Type": null
      }
    },
    "Names": {
      "link": {
        "Href": "/names",
        "Rel": "self",
        "Title": null,
        "Type": null
      }
    },
    "Settings": {
      "link": {
        "Href": "/settings",
        "Rel": "self",
        "Title": null,
        "Type": null
      }
    },
    "IsWriteProtected": "False",
    "IsProtected": "False",
    "IsEncryption": "false",
    "Password": null
  }
}

HTTP 状态码

状态码 含义 描述
200 OK(成功) 过滤器应用成功;响应包含操作详情。
400 Bad Request(错误请求) 缺少或参数无效(例如,不支持的文件类型)。
401 Unauthorized(未授权) JWT 令牌无效或缺失。
413 Payload Too Large(请求实体过大) 上传文件大小超出限制。
500 Internal Server Error(内部服务器错误) 意外的服务器错误。

如何使用 PostWorkbooksMerge API 及 SDK

PostWorkbooksMerge API 规范

OpenAPI 规范 定义了一个公开可访问的编程接口,可让 API 直接从 Web 浏览器发起 REST 调用。

您可以使用 cURL 命令行工具轻松访问 Aspose.Cells Web 服务。以下示例展示了如何使用 cURL 调用云 API,包括必需的身份验证标头。

使用 Aspose.Cells Cloud SDK

使用 SDK 是加快开发速度的最佳方式。SDK 抽象了底层细节,让您专注于项目任务。请查看 GitHub 仓库,获取 Aspose.Cells Cloud SDK 的完整列表。

以下代码示例展示了如何使用各种 SDK 调用 Aspose.Cells Web 服务: