[英]Microsoft Teams Graph API : Add Tab to teams channel API failing in V1.0 but working in Beta for built in tab types
下面是添加 web 选项卡的请求。
1)API ->
POST - https://graph.microsoft.com/v1.0/teams/{teamID}/channels/{channelID}/tabs
2)身体->
{
"name":"[TabName]",
"teamsAppId":"com.microsoft.teamspace.tab.web",
"configuration":
{
"contentUrl":"[WebURL]",
"websiteUrl":"[WebURL]"
}
}
3)错误->
"code": "InvalidRequest",
"message": "The navigation bind for the teamsApp was missing in
request."
据说 Tabs API 已经是 GA 了,因此我发布了这个问题。
GA公告链接:
请帮我解决这个问题。
请在下面找到解决方案。
正如 Nick 在上面的回答中提到的,V1.0 具有 teamApp 属性,可用于设置选项卡类型。 在内置选项卡类型的情况下,将“teamsApp@odata.bind”属性设置为“ https://graph.microsoft.com/beta/appCatalogs/teamsApps/[Built In tab Id]”
示例网站选项卡, https://graph.microsoft.com/beta/appCatalogs/teamsApps/com.microsoft.teamspace.tab.web
参考: https ://docs.microsoft.com/en-us/graph/teams-configuring-builtin-tabs,https: //developer.microsoft.com/en-us/graph/blogs/30daysmsgraph-day-27-用例创建团队/
这不是一个很好的错误消息。 根本原因是 v1 中没有 teamAppId 属性——而是有一个 teamApp 属性。 (顺便说一句,测试版中也有)有关详细信息,请参阅https://docs.microsoft.com/en-us/graph/api/teamstab-add?view=graph-rest-1.0 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.