【问题标题】:Microsoft graph delta api for Documents of a specific folder?Microsoft graph delta api用于特定文件夹的文档?
【发布时间】:2017-10-11 13:01:13
【问题描述】:

我想使用图形增量 API 来跟踪驱动器特定文件夹中的更改。

文档提供了在根驱动器上使用 delta API 的示例。

当我尝试使用相同的 API 从“附件”文件夹中获取我的文档时出现错误。

我的请求 APIhttps://graph.microsoft.com/v1.0/users/userid/drive/root/delta:/Attachments:/children

错误响应

{
    "error": {
        "code": "BadRequest",
        "message": "The request URI is not valid. The segment 'delta' must be the last segment in the URI because it is one of the following: $ref, $batch, $count, $value, $metadata, a named media resource, an action, a noncomposable function, an action import, a noncomposable function import, an operation with void return type, or an operation import with void return type.",
        "innerError": {
            "request-id": "d98d91f1-f131-4d76-89bd-4c980b13f92d",
            "date": "2017-10-11T12:55:09"
        }
    }
}

此 API 调用中的错误是什么?

【问题讨论】:

    标签: java spring-boot microsoft-graph-api onedrive


    【解决方案1】:

    根据增量查询的文档 - 在 OneDrive for Business 和 SharePoint 中,仅根文件夹支持增量,驱动器内的其他文件夹不支持。

    参考 - https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/api/driveitem_delta

    【讨论】:

    • 这是正确的,但我还要指出,如果它确实有效,你会想要访问一个看起来像 https://graph.microsoft.com/v1.0/users/userid/drive/root:/Attachments:/delta 的 URL
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-12-06
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多