twilio-0.3.0.0: Twilio REST API library for Haskell

Copyright(C) 2017- Mark Andrus Roberts
LicenseBSD-style (see the file LICENSE)
MaintainerMark Andrus Roberts <markandrusroberts@gmail.com>
Stabilityprovisional
Safe HaskellNone
LanguageHaskell98

Twilio.Calls

Contents

Description

 

Synopsis

Resource

data Calls #

Instances

Eq Calls # 

Methods

(==) :: Calls -> Calls -> Bool #

(/=) :: Calls -> Calls -> Bool #

Show Calls # 

Methods

showsPrec :: Int -> Calls -> ShowS #

show :: Calls -> String #

showList :: [Calls] -> ShowS #

FromJSON Calls # 

Methods

parseJSON :: Value -> Parser Calls

parseJSONList :: Value -> Parser [Calls]

Get0 Calls # 

Methods

get0 :: MonadThrow m => TwilioT m Calls #

List Calls Call # 

get :: MonadThrow m => TwilioT m Calls #

Get Calls.

For example, you can fetch the Calls resource in the IO monad as follows:

module Main where

import Control.Monad.IO.Class (liftIO)
import System.Environment (getEnv)
import Twilio.Calls as Calls
import Twilio.Types

-- | Print calls.
main :: IO ()
main = runTwilio' (getEnv "ACCOUNT_SID")
                  (getEnv "AUTH_TOKEN")
     $ Calls.get >>= liftIO . print

post :: MonadThrow m => PostCalls -> TwilioT m Call #

data PostCalls #

Constructors

PostCalls 

Fields

Instances

Orphan instances

Post3 Text Text URI Call # 

Methods

post3 :: MonadThrow m => Text -> Text -> URI -> TwilioT m Call #