Reputation: 43
Below is the request for adding web tab.
1)API ->
POST - https://graph.microsoft.com/v1.0/teams/{teamID}/channels/{channelID}/tabs
2)Body ->
{
"name":"[TabName]",
"teamsAppId":"com.microsoft.teamspace.tab.web",
"configuration":
{
"contentUrl":"[WebURL]",
"websiteUrl":"[WebURL]"
}
}
3)Error->
"code": "InvalidRequest",
"message": "The navigation bind for the teamsApp was missing in
request."
Tabs API is said to be GA already hence I'm posting this question.
GA Announcement link :
Please help me resolve this issue.
Upvotes: 2
Views: 3396
Reputation: 43
Please find the solution below.
As mentioned by Nick in the above answer V1.0 has teamsApp property which can be used to set tab types. In case of built in tab types ,set "[email protected]" property to "https://graph.microsoft.com/beta/appCatalogs/teamsApps/[Built In tab Id]"
Example Website tab, https://graph.microsoft.com/beta/appCatalogs/teamsApps/com.microsoft.teamspace.tab.web
Refernce: https://learn.microsoft.com/en-us/graph/teams-configuring-builtin-tabs, https://developer.microsoft.com/en-us/graph/blogs/30daysmsgraph-day-27-use-case-create-a-team/
Upvotes: 2
Reputation: 136
It's not a great error message. The root cause is that there's no teamsAppId property in v1 -- instead there's a teamsApp property. (Which is also there in beta, btw) See https://learn.microsoft.com/en-us/graph/api/teamstab-add?view=graph-rest-1.0 for details.
Upvotes: 0