Get group

Important: APIs under the /beta version in Microsoft Graph are in preview and are subject to change. Use of these APIs in production applications is not supported.

Get the properties and relationships of a group object.

Default properties

The following represent the default set of properties that are returned when getting or listing groups. These are a subset of all available properties.

  • classification
  • createdDateTime
  • description
  • displayName
  • groupTypes
  • id
  • mail
  • mailEnabled
  • mailNickname
  • membershipRule
  • membershipRuleProcessingState
  • onPremisesLastSyncDateTime
  • onPremisesSecurityIdentifier
  • onPremisesSyncEnabled
  • preferredLanguage - Not supported; a value for this property cannot be set and returns null when called.
  • proxyAddresses
  • renewedDateTime
  • securityEnabled
  • theme
  • visibility

The following group properties are not returned by default:

  • accessType
  • allowExternalSenders
  • autoSubscribeNewMembers
  • hasMembersWithLicenseErrors
  • isSubscribedByMail
  • isFavorite
  • unseenConversationsCount
  • unseenCount
  • unseenMessagesCount

To get these properties (except isFavorite and hasMembersWithLicenseErrors), use the $select query parameter. The following are examples:

GET https://graph.microsoft.com/beta/groups/c28c1cc9-e1ab-4c4d-98d1-d8fdf128b60f?$select=allowExternalSenders,autoSubscribeNewMembers,isSubscribedByMail,unseenCount

GET https://graph.microsoft.com/beta/groups/c28c1cc9-e1ab-4c4d-98d1-d8fdf128b60f?$select=description,allowExternalSenders

To return groups containing members with license errors, use the $filter query parameter:

GET GET https://graph.microsoft.com/beta/groups?$filter=hasMembersWithLicenseErrors+eq+true

Since the group resource supports extensions, you can also use the GET operation to get custom properties and extension data in a group instance.

Permissions

One of the following permissions is required to call this API. To learn more, including how to choose permissions, see Permissions.

Permission type Permissions (from least to most privileged)
Delegated (work or school account) Group.Read.All, Group.ReadWrite.All
Delegated (personal Microsoft account) Not supported.
Application Group.Read.All, Group.ReadWrite.All

HTTP request

GET /groups/{id}

Optional query parameters

This method supports the OData Query Parameters to help customize the response.

Request headers

Name Type Description
Authorization string Bearer {token}. Required.

Request body

Do not supply a request body for this method.

Response

If successful, this method returns a 200 OK response code and group object in the response body.

Example

Request

The following is an example of the request.

GET https://graph.microsoft.com/beta/groups/{id}

Response

The following is an example of the response.

Note: The response object shown here might be shortened for readability. The default properties will be returned from an actual call, as described before.

HTTP/1.1 200 OK
Content-type: application/json
Content-length: xxx

{
  "id": "id-value",
  "description": "description-value",
  "displayName": "displayName-value",
  "groupTypes": [
    "groupTypes-value"
  ],
  "mail": "mail-value",
  "mailEnabled": true,
  "mailNickname": "mailNickname-value",
  "onPremisesLastSyncDateTime": "onPremisesLastSyncDateTime-value",
  "onPremisesSecurityIdentifier": "onPremisesSecurityIdentifier-value",
  "onPremisesSyncEnabled": true,
  "proxyAddresses": [
    "proxyAddresses-value"
   ],
   "securityEnabled": true,
   "visibility": "visibility-value"
}

See also