SP.GroupCollection.getById Method (sp.js)

Returns a group from the collection based on the member ID of the group.

Applies to: apps for SharePoint | SharePoint Foundation 2013 | SharePoint Server 2013

SP.GroupCollection.getById()

Parameters

  • id
    A 32-bit integer that specifies the member ID.

Return value

Type: SP.Group

REST resource endpoint

See GroupCollection resource for more information.

Endpoint URI structure

http://<sitecollection>/<site>/_api/web/sitegroups/getById(id)

HTTP requests

This resource supports the following HTTP commands:

  • POST

GET syntax

GET http://<sitecollection>/<site>/_api/web/sitegroups/getById(id)

POST syntax

POST http://<sitecollection>/<site>/_api/web/sitegroups/getById(id)

Resource parameters

  • id