简体   繁体   English

通过Graph API从Microsoft Planner任务中检索附件

[英]Retrieving attachments from Microsoft Planner tasks through Graph API

I currently using Microsoft Graph to interface with PLanner and I am attempting to set up a program to be able to fully read in all data about Groups, Plans, Buckets and the Tasks. 我目前正在使用Microsoft Graph与PLanner进行交互,我正在尝试设置一个程序,以便能够完全读入有关组,计划,存储桶和任务的所有数据。

The API has a lot of power and so far I can read in everything (even each individual comment) but for the life of me, I can't seem to find a way to read in attachments of a task! API有很多功能,到目前为止我可以阅读所有内容(甚至是每个评论),但对于我的生活,我似乎无法找到一种阅读任务附件的方法!

The API documentation doesn't seem to indicate that there is any relationship between tasks and attachments either, implying that on Planner, there shouldn't even be an attachment. API文档似乎并不表示任务和附件之间存在任何关系,这意味着在Planner上甚至不应该有附件。

Planner Task Object Documentation: https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/resources/plannertask 规划师任务对象文档: https//developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/resources/plannertask

The closet the API has is Post attachments, in the comments section. API的壁橱是帖子附件,在评论部分。 (See this: https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/resources/post ) but no matter hwo i use that, it won't read in attachments to the task itself on planner as that List Attachments function simply returns empty for every post. (请参阅: https//developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/resources/post )但无论我使用它,它都不会读入附件规划器上的任务本身,因为List Attachments函数只是为每个帖子返回空。 (Because on Planner itself, the attachment is attached to the task, not an individual post) (因为在Planner本身,附件附加到任务,而不是单个帖子)

In fact, the Get Attachment documentation details the different ways you can get attachments (see: https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/api/attachment_get ) showing you can get it from calendar events, posts or events. 实际上,Get Attachment文档详细说明了获取附件的不同方法(请参阅: https//developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/api/attachment_get )可以从日历活动,帖子或活动中获取。 But not tasks, like Planner allows! 但不是像Planner允许的任务!

Is there something I am missing from the documentation or is this just something the API doesn't allow yet? 我在文档中是否缺少某些内容,或者这只是API不允许的内容? I also can't really find anyone else talking about it online. 我也找不到其他人在网上谈论它。

Planner attachments are just links to external resources, stored on the task details object of the task. 计划程序附件只是指向外部资源的链接,存储在任务的任务详细信息对象中。 On the task details, external references collection contains the URL of all the references of the task, which can be used to access the proper resource. 在任务详细信息上, 外部引用集合包含任务的所有引用的URL,可用于访问适当的资源。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM