graphql-engine-1.0.0: GraphQL API over Postgres
Safe HaskellNone
LanguageHaskell2010

Hasura.Session

Synopsis

Documentation

newtype RoleName Source #

Constructors

RoleName 

Instances

Instances details
Eq RoleName Source # 
Instance details

Defined in Hasura.Session

Ord RoleName Source # 
Instance details

Defined in Hasura.Session

Show RoleName Source # 
Instance details

Defined in Hasura.Session

Generic RoleName Source # 
Instance details

Defined in Hasura.Session

Associated Types

type Rep RoleName :: Type -> Type #

Methods

from :: RoleName -> Rep RoleName x #

to :: Rep RoleName x -> RoleName #

NFData RoleName Source # 
Instance details

Defined in Hasura.Session

Methods

rnf :: RoleName -> () #

Hashable RoleName Source # 
Instance details

Defined in Hasura.Session

FromJSONKey RoleName Source # 
Instance details

Defined in Hasura.Session

Methods

fromJSONKey :: FromJSONKeyFunction RoleName

fromJSONKeyList :: FromJSONKeyFunction [RoleName]

FromJSON RoleName Source # 
Instance details

Defined in Hasura.Session

Methods

parseJSON :: Value -> Parser RoleName

parseJSONList :: Value -> Parser [RoleName]

ToJSONKey RoleName Source # 
Instance details

Defined in Hasura.Session

Methods

toJSONKey :: ToJSONKeyFunction RoleName

toJSONKeyList :: ToJSONKeyFunction [RoleName]

ToJSON RoleName Source # 
Instance details

Defined in Hasura.Session

Methods

toJSON :: RoleName -> Value

toEncoding :: RoleName -> Encoding

toJSONList :: [RoleName] -> Value

toEncodingList :: [RoleName] -> Encoding

ToTxt RoleName Source # 
Instance details

Defined in Hasura.Session

Methods

toTxt :: RoleName -> Text Source #

FromCol RoleName Source # 
Instance details

Defined in Hasura.Session

ToPrepArg RoleName Source # 
Instance details

Defined in Hasura.Session

Methods

toPrepVal :: RoleName -> PrepArg

Cacheable RoleName Source # 
Instance details

Defined in Hasura.Session

FromEnv RoleName Source # 
Instance details

Defined in Hasura.Server.Init.Env

type Rep RoleName Source # 
Instance details

Defined in Hasura.Session

type Rep RoleName = D1 ('MetaData "RoleName" "Hasura.Session" "graphql-engine-1.0.0-inplace" 'True) (C1 ('MetaCons "RoleName" 'PrefixI 'True) (S1 ('MetaSel ('Just "getRoleTxt") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 NonEmptyText)))

newtype SessionVariable Source #

Constructors

SessionVariable 

Fields

Instances

Instances details
Eq SessionVariable Source # 
Instance details

Defined in Hasura.Session

Data SessionVariable Source # 
Instance details

Defined in Hasura.Session

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SessionVariable -> c SessionVariable #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SessionVariable #

toConstr :: SessionVariable -> Constr #

dataTypeOf :: SessionVariable -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c SessionVariable) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SessionVariable) #

gmapT :: (forall b. Data b => b -> b) -> SessionVariable -> SessionVariable #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SessionVariable -> r #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SessionVariable -> r #

gmapQ :: (forall d. Data d => d -> u) -> SessionVariable -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SessionVariable -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SessionVariable -> m SessionVariable #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SessionVariable -> m SessionVariable #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SessionVariable -> m SessionVariable #

Ord SessionVariable Source # 
Instance details

Defined in Hasura.Session

Show SessionVariable Source # 
Instance details

Defined in Hasura.Session

IsString SessionVariable Source # 
Instance details

Defined in Hasura.Session

NFData SessionVariable Source # 
Instance details

Defined in Hasura.Session

Methods

rnf :: SessionVariable -> () #

Hashable SessionVariable Source # 
Instance details

Defined in Hasura.Session

FromJSONKey SessionVariable Source # 
Instance details

Defined in Hasura.Session

Methods

fromJSONKey :: FromJSONKeyFunction SessionVariable

fromJSONKeyList :: FromJSONKeyFunction [SessionVariable]

FromJSON SessionVariable Source # 
Instance details

Defined in Hasura.Session

Methods

parseJSON :: Value -> Parser SessionVariable

parseJSONList :: Value -> Parser [SessionVariable]

ToJSONKey SessionVariable Source # 
Instance details

Defined in Hasura.Session

Methods

toJSONKey :: ToJSONKeyFunction SessionVariable

toJSONKeyList :: ToJSONKeyFunction [SessionVariable]

ToJSON SessionVariable Source # 
Instance details

Defined in Hasura.Session

Methods

toJSON :: SessionVariable -> Value

toEncoding :: SessionVariable -> Encoding

toJSONList :: [SessionVariable] -> Value

toEncodingList :: [SessionVariable] -> Encoding

ToTxt SessionVariable Source # 
Instance details

Defined in Hasura.Session

Methods

toTxt :: SessionVariable -> Text Source #

Cacheable SessionVariable Source # 
Instance details

Defined in Hasura.Session

sessionVariableToGraphQLName :: SessionVariable -> Maybe Name Source #

Converts a SessionVariable value to a GraphQL name. This will fail if the session variable contains characters that are not valid for a graphql names. It is the caller's responsibility to decide what to do in such a case.

newtype SessionVariables Source #

Instances

Instances details
Eq SessionVariables Source # 
Instance details

Defined in Hasura.Session

Show SessionVariables Source # 
Instance details

Defined in Hasura.Session

Semigroup SessionVariables Source # 
Instance details

Defined in Hasura.Session

Monoid SessionVariables Source # 
Instance details

Defined in Hasura.Session

Hashable SessionVariables Source # 
Instance details

Defined in Hasura.Session

FromJSON SessionVariables Source # 
Instance details

Defined in Hasura.Session

Methods

parseJSON :: Value -> Parser SessionVariables

parseJSONList :: Value -> Parser [SessionVariables]

ToJSON SessionVariables Source # 
Instance details

Defined in Hasura.Session

data UserAdminSecret Source #

Represent the admin secret state; whether the secret is sent in the request or if actually authorization is not configured.

Instances

Instances details
Eq UserAdminSecret Source # 
Instance details

Defined in Hasura.Session

Show UserAdminSecret Source # 
Instance details

Defined in Hasura.Session

data BackendOnlyFieldAccess Source #

Represents the 'X-Hasura-Use-Backend-Only-Permissions' session variable and request made with 'X-Hasura-Admin-Secret' if any auth configured. For more details see Note [Backend only permissions]

Instances

Instances details
Eq BackendOnlyFieldAccess Source # 
Instance details

Defined in Hasura.Session

Show BackendOnlyFieldAccess Source # 
Instance details

Defined in Hasura.Session

Generic BackendOnlyFieldAccess Source # 
Instance details

Defined in Hasura.Session

Associated Types

type Rep BackendOnlyFieldAccess :: Type -> Type #

Hashable BackendOnlyFieldAccess Source # 
Instance details

Defined in Hasura.Session

type Rep BackendOnlyFieldAccess Source # 
Instance details

Defined in Hasura.Session

type Rep BackendOnlyFieldAccess = D1 ('MetaData "BackendOnlyFieldAccess" "Hasura.Session" "graphql-engine-1.0.0-inplace" 'False) (C1 ('MetaCons "BOFAAllowed" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "BOFADisallowed" 'PrefixI 'False) (U1 :: Type -> Type))

data UserInfo Source #

Instances

Instances details
Eq UserInfo Source # 
Instance details

Defined in Hasura.Session

Show UserInfo Source # 
Instance details

Defined in Hasura.Session

Generic UserInfo Source # 
Instance details

Defined in Hasura.Session

Associated Types

type Rep UserInfo :: Type -> Type #

Methods

from :: UserInfo -> Rep UserInfo x #

to :: Rep UserInfo x -> UserInfo #

Hashable UserInfo Source # 
Instance details

Defined in Hasura.Session

type Rep UserInfo Source # 
Instance details

Defined in Hasura.Session

type Rep UserInfo = D1 ('MetaData "UserInfo" "Hasura.Session" "graphql-engine-1.0.0-inplace" 'False) (C1 ('MetaCons "UserInfo" 'PrefixI 'True) (S1 ('MetaSel ('Just "_uiRole") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 RoleName) :*: (S1 ('MetaSel ('Just "_uiSession") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 SessionVariables) :*: S1 ('MetaSel ('Just "_uiBackendOnlyFieldAccess") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 BackendOnlyFieldAccess))))

class Monad m => UserInfoM m where Source #

Instances

Instances details
UserInfoM m => UserInfoM (TraceT m) Source # 
Instance details

Defined in Hasura.Session

UserInfoM m => UserInfoM (MetadataT m) Source # 
Instance details

Defined in Hasura.RQL.Types.SchemaCache.Build

Monad m => UserInfoM (RunT m) Source # 
Instance details

Defined in Hasura.RQL.Types.Run

UserInfoM m => UserInfoM (CacheRWT m) Source # 
Instance details

Defined in Hasura.RQL.DDL.Schema.Cache

UserInfoM m => UserInfoM (ExceptT r m) Source # 
Instance details

Defined in Hasura.Session

UserInfoM m => UserInfoM (ReaderT r m) Source # 
Instance details

Defined in Hasura.Session

UserInfoM m => UserInfoM (StateT s m) Source # 
Instance details

Defined in Hasura.Session

UserInfoM m => UserInfoM (TableCacheRT b m) Source # 
Instance details

Defined in Hasura.RQL.Types.SchemaCache

data UserRoleBuild Source #

Represents how to build a role from the session variables

Constructors

URBFromSessionVariables

Look for `x-hasura-role` session variable value and absence will raise an exception

URBFromSessionVariablesFallback !RoleName

Look for `x-hasura-role` session variable value, if absent fall back to given role

URBPreDetermined !RoleName

Use only the pre-determined role

Instances

Instances details
Eq UserRoleBuild Source # 
Instance details

Defined in Hasura.Session

Show UserRoleBuild Source # 
Instance details

Defined in Hasura.Session