SP.GroupCollection.getByName Method (sp.js)

Returns a cross-site group from the collection based on the name of the group.

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

SP.GroupCollection.getByName()

Parameters

  • name

Return value

SP.Group

Remarks

The name parameter value corresponds to the group name for the cross-site group, which is contained in the Microsoft.SharePoint.SPMember class.

REST resource endpoint

See GroupCollection resource for more information.

Endpoint URI structure

http://<sitecollection>/<site>/_api/web/sitegroups/getByName(name)

HTTP requests

This resource supports the following HTTP commands:

  • POST

GET syntax

GET http://<sitecollection>/<site>/_api/web/sitegroups/getByName(name)

POST syntax

POST http://<sitecollection>/<site>/_api/web/sitegroups/getByName(name)

Resource parameters

  • name