Skip to main content

action_services

Creates, updates, deletes, gets or lists an action_services resource.

Overview

Nameaction_services
TypeResource
Idpagerduty.automation_actions.action_services

Fields

The following fields are returned by SELECT queries:

Service reference

NameDatatypeDescription
idstring
html_urlstring (url)a URL at which the entity is uniquely displayed in the Web app
selfstring (url)the API show URL at which the object is accessible
summarystringA short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to name, though it is not intended to be an identifier.
typestringA string that determines the schema of the object. This must be the standard name for the entity, suffixed by _reference if the object is a reference.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectid, service_idGets the details of a Automation Action / service relation
listselectidGets all service references associated with an Automation Action
createinsertid, serviceAssociate an Automation Action with a service<br />
deletedeleteid, service_idDisassociate an Automation Action from a service<br />

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.
service_idstringThe service ID

SELECT examples

Gets the details of a Automation Action / service relation

SELECT
id,
html_url,
self,
summary,
type
FROM pagerduty.automation_actions.action_services
WHERE id = '{{ id }}' -- required
AND service_id = '{{ service_id }}' -- required
;

INSERT examples

Associate an Automation Action with a service<br />

INSERT INTO pagerduty.automation_actions.action_services (
service,
id
)
SELECT
'{{ service }}' /* required */,
'{{ id }}'
RETURNING
service
;

DELETE examples

Disassociate an Automation Action from a service<br />

DELETE FROM pagerduty.automation_actions.action_services
WHERE id = '{{ id }}' --required
AND service_id = '{{ service_id }}' --required
;