Cannot create new team on Teams

%3CLINGO-SUB%20id%3D%22lingo-sub-1522976%22%20slang%3D%22en-US%22%3ECannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1522976%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20everyone%2C%3C%2FP%3E%3CP%3EI'm%20trying%20to%20create%20new%20Team%20on%20existing%20Group%20but%20I%20keep%20getting%20error%20%3A%26nbsp%3B%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-applescript%22%3E%3CCODE%3E%7B%0A%20%20%22error%22%3A%20%7B%0A%20%20%20%20%22code%22%3A%20%22Forbidden%22%2C%0A%20%20%20%20%22message%22%3A%20%22Forbidden%22%2C%0A%20%20%20%20%22innerError%22%3A%20%7B%0A%20%20%20%20%20%20%22date%22%3A%20%222020-07-15T09%3A42%3A47%22%2C%0A%20%20%20%20%20%20%22request-id%22%3A%20%22fc95373a-26ea-4d3a-b180-662a42853e6d%22%0A%20%20%20%20%7D%0A%20%20%7D%0A%7D%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3ERequest%20is%20done%20using%20Application%20Token%20and%20this%20config%20%3A%26nbsp%3B%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-applescript%22%3E%3CCODE%3Eendpoint%20%3A%20PUT%20https%3A%2F%2Fgraph.microsoft.com%2Fv1.0%2Fgroups%2F%7BGroupID%7D%2Fteam%0Abody%20%3A%20%0A%7B%20%20%0A%20%20%22memberSettings%22%3A%20%7B%0A%20%20%20%20%22allowCreateUpdateChannels%22%3A%20true%0A%20%20%7D%2C%0A%20%20%22messagingSettings%22%3A%20%7B%0A%20%20%20%20%22allowUserEditMessages%22%3A%20true%2C%0A%20%20%20%20%22allowUserDeleteMessages%22%3A%20true%0A%20%20%7D%2C%0A%20%20%22funSettings%22%3A%20%7B%0A%20%20%20%20%22allowGiphy%22%3A%20true%2C%0A%20%20%20%20%22giphyContentRating%22%3A%20%22strict%22%0A%20%20%7D%0A%7D%3C%2FCODE%3E%3C%2FPRE%3E%3CP%3EIs%20there%20any%20issue%20on%20this%20endpoint%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1522976%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EAPI%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ETeams%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1525983%22%20slang%3D%22en-US%22%3ERe%3A%20Cannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1525983%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F720154%22%20target%3D%22_blank%22%3E%40DMarcolo%3C%2FA%3E%26nbsp%3BCould%20you%20please%20try%20this%20in%20the%20graph%20explorer%3F%20Also%20are%20you%20using%20Delegated%20permissions%20or%20Application%20permissions%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1526029%22%20slang%3D%22en-US%22%3ERe%3A%20Cannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1526029%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F359599%22%20target%3D%22_blank%22%3E%40Gousia_Begum%3C%2FA%3E%26nbsp%3B%20%2C%3C%2FP%3E%3CP%3Epermissions%20are%20under%20Application%20permissions%20and%20they%20are%20all%20Granted.%20If%20I%20run%20the%20same%20request%20from%20the%20Api%20explorer%20(%20logged%20)%20I%20got%20the%20same%20results%20%3A%20Unauthorized%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Screenshot%202020-07-16%20at%2011.54.49.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F205760i5BFEB5EEC3BB9F4A%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Screenshot%202020-07-16%20at%2011.54.49.png%22%20alt%3D%22Screenshot%202020-07-16%20at%2011.54.49.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1526057%22%20slang%3D%22en-US%22%3ERe%3A%20Cannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1526057%22%20slang%3D%22en-US%22%3E%3CP%3EHi%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F720154%22%20target%3D%22_blank%22%3E%40DMarcolo%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3Echeck%20your%20request%20once%20again%20and%20also%20check%20if%20you%20mentioned%20%3CSTRONG%3Econtent-type%3A%20application%2Fjson%26nbsp%3B%3C%2FSTRONG%3Ein%20request%20header.%3C%2FP%3E%3CP%3ERefer%20the%20link%20below.%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fapi%2Fteam-put-teams%3Fview%3Dgraph-rest-1.0%26amp%3Btabs%3Dhttp%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fapi%2Fteam-put-teams%3Fview%3Dgraph-rest-1.0%26amp%3Btabs%3Dhttp%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EEven%20if%20the%20request%20is%20correct%20and%20you%20still%20getthis%20error%2C%3C%2FP%3E%3CP%3EYou%20wouldn't%20be%20having%20access%20to%20the%20resource%20or%20the%20resource%20must%20have%20conditional%20access%3C%2FP%3E%3CP%3Eclick%20on%20below%20link%20for%20more%20info%20on%20errors.%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Ferrors%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Ferrors%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3Echeers.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1526069%22%20slang%3D%22en-US%22%3ERe%3A%20Cannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1526069%22%20slang%3D%22en-US%22%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F720154%22%20target%3D%22_blank%22%3E%40DMarcolo%3C%2FA%3E%20change%20your%20action%20from%20%22GET%22%20to%20%22PUT%22%20and%20try%20again%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1526114%22%20slang%3D%22en-US%22%3ERe%3A%20Cannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1526114%22%20slang%3D%22en-US%22%3EYes%20request%20was%20done%20using%20PUT%2C%20i%20refresh%20the%20page%20to%20not%20show%20the%20token%20that%20was%20on%20the%20request%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1526125%22%20slang%3D%22en-US%22%3ERe%3A%20Cannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1526125%22%20slang%3D%22en-US%22%3E%3CP%3EThanks%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F726607%22%20target%3D%22_blank%22%3E%40gk_vasudev%3C%2FA%3E%26nbsp%3B%2C%26nbsp%3B%3C%2FP%3E%3CP%3Ebut%20data%20format%20and%20request%20is%20correct%20and%20well%20formatted.%20I%20copy%2Fpaste%20the%20structure%20right%20from%20the%20sample%20on%20the%20create%20team%20page%20%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fapi%2Fteam-put-teams%3Fview%3Dgraph-rest-1.0%26amp%3Btabs%3Dhttp%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fapi%2Fteam-put-teams%3Fview%3Dgraph-rest-1.0%26amp%3Btabs%3Dhttp%3C%2FA%3E%3C%2FP%3E%3CP%3ESame%20results.%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22Screenshot%202020-07-16%20at%2012.38.57.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F205774iA59974C32A5731FC%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Screenshot%202020-07-16%20at%2012.38.57.png%22%20alt%3D%22Screenshot%202020-07-16%20at%2012.38.57.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3EToken%20is%20up-to-date%2C%20because%20via%20the%20app%20I'm%20working%20on%2C%20I'm%20able%20to%20get%20users%20list%2C%20groups%20list%2C%20create%20user%20%26amp%3B%20group.%20The%20Forbidden%20is%20a%20%22no%20sense%22%20to%20me%3A%20there%20is%20no%20policy%20of%20access%2C%20permissions%20are%20all%20granted%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1526169%22%20slang%3D%22en-US%22%3ERe%3A%20Cannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1526169%22%20slang%3D%22en-US%22%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fresolve-auth-errors%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fresolve-auth-errors%3C%2FA%3E%3CBR%20%2F%3E%3CBR%20%2F%3EHoping%20this%20might%20help!%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1527067%22%20slang%3D%22en-US%22%3ERe%3A%20Cannot%20create%20new%20team%20on%20Teams%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1527067%22%20slang%3D%22en-US%22%3EI'm%20still%20working%20on%20that.%20Now%20(%20i%20did%20not%20change%20a%20think%20on%20config%2Fapp%20code)%20i%20got%20a%20different%20error%2C%20says%20%3A%20Not%20Found.%20I%20think%20there%20is%20%2F%20there%20was%20something%20wrong%20on%20API%2FTeams%20side.%20The%20group%20is%20created%2C%20has%202%20owner%20already%20assigned.%20Why%20is%20saying%20not%20found%20now%3F%3CBR%20%2F%3E%3CBR%20%2F%3EThe%20more%20I%20work%20on%20it%2C%20the%20more%20I%20feel%20this%20service%20act%20%22strange%22%3C%2FLINGO-BODY%3E
Highlighted
Occasional Contributor

Hi everyone,

I'm trying to create new Team on existing Group but I keep getting error : 

 

{
  "error": {
    "code": "Forbidden",
    "message": "Forbidden",
    "innerError": {
      "date": "2020-07-15T09:42:47",
      "request-id": "fc95373a-26ea-4d3a-b180-662a42853e6d"
    }
  }
}

 

Request is done using Application Token and this config : 

 

endpoint : PUT https://graph.microsoft.com/v1.0/groups/{GroupID}/team
body : 
{  
  "memberSettings": {
    "allowCreateUpdateChannels": true
  },
  "messagingSettings": {
    "allowUserEditMessages": true,
    "allowUserDeleteMessages": true
  },
  "funSettings": {
    "allowGiphy": true,
    "giphyContentRating": "strict"
  }
}

 

On the Azure directory permissions : Group.ReadWrite.All, Directory.ReadWrite.All , are set and granted by admin

Is there any issue on this endpoint?

8 Replies
Highlighted

@DMarcolo Could you please try this in the graph explorer? Also are you using Delegated permissions or Application permissions?

Highlighted

Hi @Gousia_Begum  ,

permissions are under Application permissions and they are all Granted. If I run the same request from the Api explorer ( logged ) I got the same results : Unauthorized

Screenshot 2020-07-16 at 11.54.49.png

Highlighted

Hi @DMarcolo 

 

check your request once again and also check if you mentioned content-type: application/json in request header.

Refer the link below.

https://docs.microsoft.com/en-us/graph/api/team-put-teams?view=graph-rest-1.0&tabs=http

 

Even if the request is correct and you still getthis error,

You wouldn't be having access to the resource or the resource must have conditional access

click on below link for more info on errors.

https://docs.microsoft.com/en-us/graph/errors

 

cheers.

Highlighted
@DMarcolo change your action from "GET" to "PUT" and try again
Highlighted
Yes request was done using PUT, i refresh the page to not show the token that was on the request
Highlighted

Thanks @gk_vasudev , 

but data format and request is correct and well formatted. I copy/paste the structure right from the sample on the create team page : https://docs.microsoft.com/en-us/graph/api/team-put-teams?view=graph-rest-1.0&tabs=http

Same results.

Screenshot 2020-07-16 at 12.38.57.png

Token is up-to-date, because via the app I'm working on, I'm able to get users list, groups list, create user & group. The Forbidden is a "no sense" to me: there is no policy of access, permissions are all granted

Highlighted
Highlighted
I'm still working on that. Now ( i did not change a think on config/app code) i got a different error, says : Not Found. I think there is / there was something wrong on API/Teams side. The group is created, has 2 owner already assigned. Why is saying not found now?

The more I work on it, the more I feel this service act "strange"