How can we use POST method for fetching the group data instead of GET

Oauthuser 0 Reputation points
2023-06-15T14:19:17.6133333+00:00

Hi Team,

For fetching the group one method is to us GET method and pass authorization Bearer access token under header .

To make it more secure instead of GET i want to use POST method .So is there any implication with the POST method from graph API and can i get one example using POST method to understand how to create payload & is there any difference in passing Bearer token in POST call ?

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
13,685 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. TH-4749-MSFT 3,315 Reputation points
    2023-06-15T15:47:14.9566667+00:00

    Hello Oauthuser,

    Thanks for reaching out. Using POST to get the properties of a group is not supported. You can find more information on the topic in article https://learn.microsoft.com/en-us/graph/api/group-get?view=graph-rest-1.0&tabs=http.

    The article provides a Group creation POST example along with payload https://learn.microsoft.com/en-us/graph/api/group-post-groups?view=graph-rest-1.0&tabs=http

    To call Microsoft Graph, the app makes an authorization request by attaching the access token as a Bearer token to the Authorization header in an HTTP request. You can find more information in article https://learn.microsoft.com/en-us/graph/auth/auth-concepts.

    Thanks.

    0 comments No comments

  2. TH-4749-MSFT 3,315 Reputation points
    2023-06-19T14:40:33.07+00:00

    Hello Oauthuser,

    Good Day. Hope all is well.

    If the reply is helpful, please click Accept Answer and kindly upvote it. If you have additional questions about this answer, please click Comment.

    Thanks


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.