cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
samtn
Regular Visitor

message: Unsupported resource type Directory Object for operation Create

[AzureAD-DirectoryObject] - I am trying to do a POST operation to add a directory object (device) to a group. ref: https://docs.microsoft.com/de-de/graph/api/group-post-members?view=graph-rest-1.0&tabs=http

 

Request:

Method: POST

URI: "https://graph.microsoft.com/v1.0/groups/<group-id>/members/"

Header: 

{
  "Content-Type""application/json"
}
 

Body: 

 

{
}
 
 
Response: 
 
Status code: 400
Response Body: 
{
  "error": {
    "code""Request_BadRequest",
    "message": "Unsupported resource type 'DirectoryObject' for operation 'Create'.",
    "innerError": {
      "date""2021-06-14T08:34:28",
      "request-id""***************************************",
      "client-request-id""*******************************"
    }
  }
}
 
 
Adding more info to narrow down the issue, like mentioned in this post https://stackoverflow.com/questions/56320640/adding-user-to-group-using-graph-api-b2c if I try from MSGraph explorer it works without an issue but the same not working with [Flow-Action-HTTP]. 
 
samtn_0-1623661599790.png

 

As you can see above it works perfectly with MSGraph. please assist 

 
here is my flow screenshot.
samtn_0-1623663158796.png

 

 
 
 
1 ACCEPTED SOLUTION

Accepted Solutions
samtn
Regular Visitor

Issue resolved. it was due to syntax error.

View solution in original post

1 REPLY 1
samtn
Regular Visitor

Issue resolved. it was due to syntax error.

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (2,066)