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

MSAzureAPI.Internal.Common

Contents

Description

Common functions for the MS Azure API

Synopsis

Documentation

data APIPlane Source #

Constructors

APManagement

Management plane (management.azure.com endpoints)

APData Text

Data plane e.g. FileREST API

get Source #

Arguments

:: FromJSON b 
=> APIPlane 
-> [Text]

URI path segments

-> Option 'Https 
-> AccessToken 
-> Req b 
GET

getLbs Source #

Arguments

:: APIPlane 
-> [Text]

URI path segments

-> Option 'Https 
-> AccessToken 
-> Req ByteString 

GET a ByteString e.g. a file

post Source #

Arguments

:: (FromJSON b, ToJSON a) 
=> APIPlane 
-> [Text]

URI path segments

-> Option 'Https 
-> a

request body

-> AccessToken 
-> Req b 
POST

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

JSON

data Collection a Source #

a collection of items with key value

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.1.0.0-IrNox3qYOEa7Wm8QFWK3jL" 'False) (C1 ('MetaCons "Collection" 'PrefixI 'True) (S1 ('MetaSel ('Just "cValue") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [a])))

aesonOptions Source #

Arguments

:: String

record prefix

-> Options 

drop the prefix and lowercase first character

e.g. userDisplayName -> displayName