pagerduty-0.0.1.1: Client library for PagerDuty Integration and REST APIs.

Safe HaskellNone
LanguageHaskell2010

Network.PagerDuty.REST.Alerts

Contents

Description

When an incident is triggered or when it is escalated it creates an alert (also known as a notification). Alerts are messages containing the details of the incident, and can be sent through SMS, email, phone calls, and push notifications.

This API allows you to access read-only data regarding what alerts have been sent to your users.

See: http://developer.pagerduty.com/documentation/rest/alerts

Synopsis

List Alerts

data ListAlerts

Instances

Eq ListAlerts 
Show ListAlerts 
ToJSON ListAlerts 
HasDatatypeInfo ListAlerts 
Generic ListAlerts 
QueryLike ListAlerts 
Paginate ListAlerts 
type Code ListAlerts 

listAlerts

Arguments

:: Date

laSince

-> Date

laUntil

-> Request ListAlerts s [Alert] 

List existing alerts for a given time range, optionally filtered by type (SMS, Email, Phone, or Push).

GET /alerts

See: http://developer.pagerduty.com/documentation/rest/alerts/list

laSince :: Lens' (Request ListAlerts s b) UTCTime

The start of the date range over which you want to search.

laUntil :: Lens' (Request ListAlerts s b) UTCTime

The end of the date range over which you want to search. This should be in the same format as since.

The size of the date range must be less than 3 months.

laFilter :: Lens' (Request ListAlerts s b) (Maybe AlertType)

Returns only the alerts of the said AlertType type.

laTimeZone :: Lens' (Request ListAlerts s b) (Maybe TimeZone)

Time zone in which dates in the result will be rendered.

Default: account time zone.

Types

data AlertType

Constructors

SMS 
Email 
Phone 
Push 

Instances

data Alert

Instances

Eq Alert 
Show Alert 
ToJSON Alert 
FromJSON Alert 

alertStartedAt :: Lens' Alert Date