Skip to main content

subscribers

Creates, updates, deletes, gets or lists a subscribers resource.

Overview

Namesubscribers
TypeResource
Idpagerduty.business_services.subscribers

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
subscriber_idstringThe ID of the entity being subscribed
subscriber_typestringThe type of the entity being subscribed

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_business_service_subscribersselectidAcceptRetrieve a list of Notification Subscribers on the Business Service.

<!-- theme: warning -->
> Users must be added through POST /business_services/&#123;id&#125;/subscribers to be returned from this endpoint.
Scoped OAuth requires: subscribers.read
create_business_service_notification_subscribersinsertid, data__subscribersAcceptSubscribe the given entities to the given Business Service.

Scoped OAuth requires: subscribers.write
_get_business_service_subscribersexecidAcceptRetrieve a list of Notification Subscribers on the Business Service.

<!-- theme: warning -->
> Users must be added through POST /business_services/&#123;id&#125;/subscribers to be returned from this endpoint.
Scoped OAuth requires: subscribers.read

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
idstringThe ID of the resource.
AcceptstringThe Accept header is used as a versioning header.

SELECT examples

Retrieve a list of Notification Subscribers on the Business Service.

<!-- theme: warning -->
> Users must be added through POST /business_services/&#123;id&#125;/subscribers to be returned from this endpoint.
Scoped OAuth requires: subscribers.read

SELECT
subscriber_id,
subscriber_type
FROM pagerduty.business_services.subscribers
WHERE id = '{{ id }}' -- required
AND Accept = '{{ Accept }}'
;

INSERT examples

Subscribe the given entities to the given Business Service.

Scoped OAuth requires: subscribers.write

INSERT INTO pagerduty.business_services.subscribers (
data__subscribers,
id,
Accept
)
SELECT
'{{ subscribers }}' /* required */,
'{{ id }}',
'{{ Accept }}'
RETURNING
subscriptions
;

Lifecycle Methods

Retrieve a list of Notification Subscribers on the Business Service.

<!-- theme: warning -->
> Users must be added through POST /business_services/&#123;id&#125;/subscribers to be returned from this endpoint.
Scoped OAuth requires: subscribers.read

EXEC pagerduty.business_services.subscribers._get_business_service_subscribers 
@id='{{ id }}' --required,
@Accept='{{ Accept }}'
;