Safe Haskell | None |
---|---|
Language | Haskell2010 |
SCIM errors
Synopsis
- data ScimErrorType
- data ScimError = ScimError {}
- newtype Status = Status {}
- notFound :: Text -> Text -> ScimError
- badRequest :: ScimErrorType -> Maybe Text -> ScimError
- conflict :: ScimError
- unauthorized :: Text -> ScimError
- forbidden :: Text -> ScimError
- serverError :: Text -> ScimError
- scimToServerError :: ScimError -> ServerError
Types
data ScimErrorType Source #
An ADT for error types in the SCIM specification. Not all possible SCIM
errors have a corresponding ScimErrorType
(for instance, authorization
is not covered by this type).
InvalidFilter | |
TooMany | |
Uniqueness | |
Mutability | |
InvalidSyntax | |
InvalidPath | |
NoTarget | |
InvalidValue | |
InvalidVers | |
Sensitive |
Instances
Instances
Eq ScimError Source # | |
Show ScimError Source # | |
Generic ScimError Source # | |
ToJSON ScimError Source # | |
Defined in Web.Scim.Schema.Error | |
Exception ScimError Source # | |
Defined in Web.Scim.Schema.Error toException :: ScimError -> SomeException # fromException :: SomeException -> Maybe ScimError # displayException :: ScimError -> String # | |
type Rep ScimError Source # | |
Defined in Web.Scim.Schema.Error type Rep ScimError = D1 ('MetaData "ScimError" "Web.Scim.Schema.Error" "hscim-0.3.6-JBBH5QJtoVCBhDdsGW2kZ7" 'False) (C1 ('MetaCons "ScimError" 'PrefixI 'True) ((S1 ('MetaSel ('Just "schemas") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [Schema]) :*: S1 ('MetaSel ('Just "status") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Status)) :*: (S1 ('MetaSel ('Just "scimType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe ScimErrorType)) :*: S1 ('MetaSel ('Just "detail") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Text))))) |
Constructors
:: ScimErrorType | Error type |
-> Maybe Text | Error details |
-> ScimError |
Servant interoperability
scimToServerError :: ScimError -> ServerError Source #
Convert a SCIM Error
to a Servant one by encoding it with the
appropriate headers.