SP.Site.eventReceivers property (sp.js)

Provides event receivers for events that occur at the scope of the site collection.

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

var value = SP.Site.get_eventReceivers ()

Return value

Returns an EventReceiverDefinitionCollection object.

Remarks

Items that are associated with a site collection for which you have registered this event receiver—for example, any lists that exist on the site—will have these site-level events bound to them.

REST resource endpoint

Endpoint URI structure

http://<sitecollection>/<site>/_api/site/eventReceivers

HTTP requests

This resource supports the following HTTP commands:

  • POST

POST syntax

POST http://<sitecollection>/<site>/_api/site/eventReceivers

GET syntax

GET http://<sitecollection>/<site>/_api/site/eventReceivers