Safe Haskell | None |
---|---|
Language | Haskell2010 |
When a user is assigned an incident, the user's notification rules are used to determine which contact method will be used to alert the user and how long after the incident to do so.
Access and manipulate the notification rules for a user.
See: http://developer.pagerduty.com/documentation/rest/users/notification_rules
- listRules :: UserId -> Request Empty s Rule
- data CreateRule
- createRule :: UserId -> ContactId -> Int -> Request CreateRule s Rule
- crStartDelayInMinutes :: Lens' (Request CreateRule s b) Int
- crContactMethodId :: Lens' (Request CreateRule s b) ContactId
- getRule :: UserId -> NotificationRuleId -> Request Empty s Rule
- data UpdateRule
- updateRule :: UserId -> NotificationRuleId -> Request UpdateRule s Rule
- urStartDelayInMinutes :: Lens' (Request UpdateRule s b) (Maybe Int)
- urContactMethodId :: Lens' (Request UpdateRule s b) (Maybe ContactId)
- deleteRule :: UserId -> NotificationRuleId -> Request Empty s Empty
- data Rule
- rId :: Lens' Rule NotificationRuleId
- rStartDelayInMinutes :: Lens' Rule Int
- rContactMethod :: Lens' Rule Contact
List Rules
listRules :: UserId -> Request Empty s Rule Source
List existing notification rules for the specified user.
GET /users/:user_id/notification_rules
See: http://developer.pagerduty.com/documentation/rest/users/notification_rules/list
Create Rule
data CreateRule Source
createRule :: UserId -> ContactId -> Int -> Request CreateRule s Rule Source
Create a new notification rule for the specified user.
POST /users/:user_id/notification_rules
See: http://developer.pagerduty.com/documentation/rest/users/notification_rules/create
crStartDelayInMinutes :: Lens' (Request CreateRule s b) Int Source
Number of minutes it will take for the notification rule to be activated (from the time the incident is assigned to the owning user) and an alert be fired.
crContactMethodId :: Lens' (Request CreateRule s b) ContactId Source
The id of the contact method.
Get Rule
getRule :: UserId -> NotificationRuleId -> Request Empty s Rule Source
Get details for a notification rule.
GET /users/:user_id/notification_rules/:id
See: http://developer.pagerduty.com/documentation/rest/users/notification_rules/show
Update Rule
data UpdateRule Source
updateRule :: UserId -> NotificationRuleId -> Request UpdateRule s Rule Source
Update an existing notification rule.
PUT /users/:user_id/notification_rules/:id
See: http://developer.pagerduty.com/documentation/rest/users/notification_rules/update
urStartDelayInMinutes :: Lens' (Request UpdateRule s b) (Maybe Int) Source
Number of minutes it will take for the notification rule to be activated (from the time the incident is assigned to the owning user) and an alert be fired.
urContactMethodId :: Lens' (Request UpdateRule s b) (Maybe ContactId) Source
The id of the contact method.
Delete Rule
deleteRule :: UserId -> NotificationRuleId -> Request Empty s Empty Source
Remove a notification rule.
DELETE /users/:user_id/notification_rules/:id
See: http://developer.pagerduty.com/documentation/rest/users/notification_rules/delete