Microsoft Graph不会检索组的计划ID [英] Microsoft Graph does not retrieve the Group's Plan Id
问题描述
在主体上使用POST /v1.0/groups
创建组后:
After creating a Group using POST /v1.0/groups
with the body:
{
"description": "hello",
"displayName": "group_for_restore",
"groupTypes": [
"Unified"
],
"mailEnabled": true,
"mailNickname": "group_for_restore",
"securityEnabled": false,
"visibility": "Public"
}
对GET /v1.0/groups/{group-id}/planner/plans
的请求不会检索任何计划.
A request to GET /v1.0/groups/{group-id}/planner/plans
does not retrieve any plans.
据我所知,在创建组后,还将创建一个计划.在Web界面上,您可以看到该计划已正确创建和显示,但未显示在JSON响应中:
As far as I know, after creating a Group, a Plan will be created too. On the web interface you can see that this plan is correctly created and shown, but it does not appear in JSON response:
{
"@odata.context": "https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.plannerPlan)",
"@odata.count": 0,
"value": []
}
在网络界面中单击它之后,您可以使用上面的请求轻松获得该计划.
After clicking on it in the web interface you can easily get the plan using the request above.
可以采取这样的魔术步骤来获取计划ID吗?
Is it ok to do such magic steps to fetch plan id?
推荐答案
首次尝试访问Web App时,该Web App正在为其配置组计划".但是,通过API创建网上论坛时,您需要自己创建一个新的计划:
The Web App is provisioning the Group's Plan the first time you attempt to access it. When creating a Group through the API however, you'll need to create a new Plan yourself:
POST https://graph.microsoft.com/v1.0/planner/plans
Content-type: application/json
{
"owner": "group-id",
"title": "title-value"
}