SP.Web.siteGroups property (sp.js)

Gets the collection of groups for the site collection.

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

var value = SP.Web.get_siteGroups ()

Return value

Type: SP.GroupCollection

A collection of SP.GroupCollection objects that represent the groups in the site collection.

REST resource endpoint

See Web resource for more information.

Endpoint URI structure

http://<sitecollection>/<site>/_api/web/siteGroups

HTTP requests

This resource supports the following HTTP commands:

  • POST

POST syntax

POST http://<sitecollection>/<site>/_api/web/siteGroups

GET syntax

GET http://<sitecollection>/<site>/_api/web/siteGroups