uploadSession 资源类型uploadSession resource type

命名空间:microsoft.graphNamespace: microsoft.graph

UploadSession资源提供了有关如何将大文件上载到 OneDrive、Onedrive for Business 或 SharePoint 文档库,或将 Outlook事件邮件项作为附件的信息。The uploadSession resource provides information about how to upload large files to OneDrive, OneDrive for Business, or SharePoint document libraries, or to Outlook event and message items as attachments.

JSON 表示形式JSON representation

下面是资源的 JSON 表示形式。Here is a JSON representation of the resource

{
  "uploadUrl": "https://sn3302.up.1drv.com/up/fe6987415ace7X4e1eF866337",
  "expirationDateTime": "2015-01-29T09:21:55.523Z",
  "nextExpectedRanges": ["0-"]
}

属性Properties

属性Property 类型Type 说明Description
expirationDateTimeexpirationDateTime DateTimeOffsetDateTimeOffset 以 UTC 表示的上载会话过期的日期和时间。在此过期时间之前必须上载完整的文件文件。The date and time in UTC that the upload session will expire. The complete file must be uploaded before this expiration time is reached.
nextExpectedRangesnextExpectedRanges String collectionString collection 字节范围集合,文件服务器缺失。A collection of byte ranges that the server is missing for the file. 这些区域索引均从零开始,格式为“开始-结束”(例如,“0-26”指示该文件的前 27 个字节)。These ranges are zero indexed and of the format "start-end" (e.g. "0-26" to indicate the first 27 bytes of the file). 将文件作为 Outlook 附件(而不是区域集合)上载时,此属性始终指示单个值 "{start}",即文件中应开始下一次上载的位置。When uploading files as Outlook attachments, instead of a collection of ranges, this property always indicates a single value "{start}", the location in the file where the next upload should begin.
uploadUrluploadUrl StringString 接受文件字节范围的 PUT 请求的 URL 端点。The URL endpoint that accepts PUT requests for byte ranges of the file.

另请参阅See also