| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Hasura.RQL.Types.Eventing
Description
This module contains types which are common to event triggers and scheduled triggers.
Synopsis
- newtype EventId = EventId {
- unEventId :: Text
- data TriggerTypes
- data WebhookRequest = WebhookRequest {
- _rqPayload :: Value
- _rqHeaders :: [HeaderConf]
- _rqVersion :: Text
- data WebhookResponse = WebhookResponse {}
- newtype ClientError = ClientError {}
- data Response (a :: TriggerTypes)
- type InvocationVersion = Text
- invocationVersionET :: InvocationVersion
- invocationVersionST :: InvocationVersion
- data Invocation (a :: TriggerTypes) = Invocation {}
- newtype PGTextArray = PGTextArray {
- unPGTextArray :: [Text]
- data OpVar
Documentation
Instances
| Eq EventId Source # | |
| Ord EventId Source # | |
Defined in Hasura.RQL.Types.Eventing | |
| Show EventId Source # | |
| Generic EventId Source # | |
| NFData EventId Source # | |
Defined in Hasura.RQL.Types.Eventing | |
| Hashable EventId Source # | |
Defined in Hasura.RQL.Types.Eventing | |
| FromJSON EventId Source # | |
Defined in Hasura.RQL.Types.Eventing | |
| ToJSONKey EventId Source # | |
Defined in Hasura.RQL.Types.Eventing | |
| ToJSON EventId Source # | |
Defined in Hasura.RQL.Types.Eventing Methods toEncoding :: EventId -> Encoding toJSONList :: [EventId] -> Value toEncodingList :: [EventId] -> Encoding | |
| ToTxt EventId Source # | |
Defined in Hasura.RQL.Types.Eventing | |
| FromCol EventId Source # | |
Defined in Hasura.RQL.Types.Eventing Methods fromCol :: Maybe ByteString -> Either Text EventId | |
| ToPrepArg EventId Source # | |
Defined in Hasura.RQL.Types.Eventing | |
| Cacheable EventId Source # | |
| type Rep EventId Source # | |
Defined in Hasura.RQL.Types.Eventing | |
data TriggerTypes Source #
There are two types of events: EventType (for event triggers) and ScheduledType (for scheduled triggers)
Constructors
| EventType | |
| ScheduledType |
data WebhookRequest Source #
Constructors
| WebhookRequest | |
Fields
| |
Instances
| ToJSON WebhookRequest Source # | |
Defined in Hasura.RQL.Types.Eventing Methods toJSON :: WebhookRequest -> Value toEncoding :: WebhookRequest -> Encoding toJSONList :: [WebhookRequest] -> Value toEncodingList :: [WebhookRequest] -> Encoding | |
data WebhookResponse Source #
Constructors
| WebhookResponse | |
Fields
| |
Instances
| ToJSON WebhookResponse Source # | |
Defined in Hasura.RQL.Types.Eventing Methods toJSON :: WebhookResponse -> Value toEncoding :: WebhookResponse -> Encoding toJSONList :: [WebhookResponse] -> Value toEncodingList :: [WebhookResponse] -> Encoding | |
newtype ClientError Source #
Constructors
| ClientError | |
Fields | |
Instances
| ToJSON ClientError Source # | |
Defined in Hasura.RQL.Types.Eventing Methods toJSON :: ClientError -> Value toEncoding :: ClientError -> Encoding toJSONList :: [ClientError] -> Value toEncodingList :: [ClientError] -> Encoding | |
data Response (a :: TriggerTypes) Source #
Constructors
| ResponseHTTP WebhookResponse | |
| ResponseError ClientError |
Instances
| ToJSON (Response 'EventType) Source # | |
Defined in Hasura.RQL.Types.Eventing Methods toJSON :: Response 'EventType -> Value toEncoding :: Response 'EventType -> Encoding toJSONList :: [Response 'EventType] -> Value toEncodingList :: [Response 'EventType] -> Encoding | |
| ToJSON (Response 'ScheduledType) Source # | |
Defined in Hasura.RQL.Types.Eventing Methods toJSON :: Response 'ScheduledType -> Value toEncoding :: Response 'ScheduledType -> Encoding toJSONList :: [Response 'ScheduledType] -> Value toEncodingList :: [Response 'ScheduledType] -> Encoding | |
type InvocationVersion = Text Source #
data Invocation (a :: TriggerTypes) Source #
Constructors
| Invocation | |
newtype PGTextArray Source #
PGTextArray is only used for PG array encoding
Constructors
| PGTextArray | |
Fields
| |
Instances
| Eq PGTextArray Source # | |
Defined in Hasura.RQL.Types.Eventing | |
| Show PGTextArray Source # | |
Defined in Hasura.RQL.Types.Eventing Methods showsPrec :: Int -> PGTextArray -> ShowS # show :: PGTextArray -> String # showList :: [PGTextArray] -> ShowS # | |
| ToPrepArg PGTextArray Source # | |
Defined in Hasura.RQL.Types.Eventing Methods toPrepVal :: PGTextArray -> PrepArg | |
Used to construct the payload of Event Trigger
OLD: Depicts the old database row value for UPDATE/DELETE trigger operations. This is used to construct the 'data.old' field of the event trigger payload. The value of 'data.old' is null in INSERT trigger operation.
NEW: Depicts the new database row value for INSERT/UPDATE trigger operations. This is used to construct the 'data.new' field of the event trigger payload. The value of 'data.new' is null in DELETE trigger operation.