ms-azure-api-0.6.0.1: Microsoft Azure API
Safe HaskellSafe-Inferred
LanguageHaskell2010

MSAzureAPI

Synopsis

HTTP request helpers

tryReq :: Req a -> Req (Either HttpException a) Source #

Specialized version of try to HttpExceptions

This can be used to catch exceptions of composite Req statements, e.g. around a do block

run :: MonadIO m => HttpConfig -> Req a -> m (Either HttpException a) Source #

Run a Req computation

withTLS Source #

Arguments

:: MonadIO m 
=> (HttpConfig -> Manager -> m b)

user program

-> m b 

Create a new TLS manager, which should be reused throughout the program

Common types

Collection

data Collection a Source #

a collection of items with key value

NB : results are paginated, and subsequent chunks can be accessed by following the nextLink field

Instances

Instances details
FromJSON a => FromJSON (Collection a) Source # 
Instance details

Defined in MSAzureAPI.Internal.Common

Generic (Collection a) Source # 
Instance details

Defined in MSAzureAPI.Internal.Common

Associated Types

type Rep (Collection a) :: Type -> Type #

Methods

from :: Collection a -> Rep (Collection a) x #

to :: Rep (Collection a) x -> Collection a #

Show a => Show (Collection a) Source # 
Instance details

Defined in MSAzureAPI.Internal.Common

Eq a => Eq (Collection a) Source # 
Instance details

Defined in MSAzureAPI.Internal.Common

Methods

(==) :: Collection a -> Collection a -> Bool #

(/=) :: Collection a -> Collection a -> Bool #

type Rep (Collection a) Source # 
Instance details

Defined in MSAzureAPI.Internal.Common

type Rep (Collection a) = D1 ('MetaData "Collection" "MSAzureAPI.Internal.Common" "ms-azure-api-0.6.0.1-9AqtB8TNiqqGzZl2uZcaR4" 'False) (C1 ('MetaCons "Collection" 'PrefixI 'True) (S1 ('MetaSel ('Just "cValue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [a]) :*: S1 ('MetaSel ('Just "cNextLink") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Text))))

collectionValue :: Collection a -> [a] Source #

Get the collection items

collectionNextLink :: Collection a -> Maybe Text Source #

Get the next link for a Collection of paginated results

Location

data Location Source #

Azure regions

Constructors

LNorthEU

"North Europe"

LWestEU

"West Europe"

Instances

Instances details
ToJSON Location Source #

Renders the full name via locationDisplayName

Instance details

Defined in MSAzureAPI.Internal.Common

Show Location Source # 
Instance details

Defined in MSAzureAPI.Internal.Common

Eq Location Source # 
Instance details

Defined in MSAzureAPI.Internal.Common

showLocation :: Location -> Text Source #

Displays the short name, e.g. "westeu"

locationDisplayName :: Location -> Text Source #

Displays the full name, e.g. "West Europe"