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

Hasura.GraphQL.Execute.Action

Synopsis

Documentation

asSingleRowJsonResp :: Query -> [PrepArg] -> TxE QErr EncJSON Source #

This function is generally used on the result of selectQuerySQL, selectAggregateQuerySQL or connectionSelectSQL to run said query and get back the resulting JSON.

resolveActionExecution :: Environment -> Logger Hasura -> UserInfo -> AnnActionExecution Void -> ActionExecContext -> Maybe GQLQueryText -> ActionExecution Source #

Synchronously execute webhook handler and resolve response to action "output"

throwUnexpected :: MonadError QErr m => Text -> m () Source #

makeActionResponseNoRelations :: ActionFields -> GraphQLType -> ActionOutputFields -> Bool -> ActionWebhookResponse -> Value Source #

Build action response from the Webhook JSON response when there are no relationships defined

resolveActionMutationAsync :: MonadMetadataStorage m => AnnActionMutationAsync -> [Header] -> SessionVariables -> m ActionId Source #

Resolve asynchronous action mutation which returns only the action uuid

asyncActionsProcessor :: forall m. (MonadIO m, MonadBaseControl IO m, Forall (Pure m), HasReporter m, MonadMetadataStorage (MetadataStorageT m)) => Environment -> Logger Hasura -> IO SchemaCache -> TVar (Set LockedActionEventId) -> Manager -> Milliseconds -> Maybe GQLQueryText -> m (Forever m) Source #

Process async actions from hdb_catalog.hdb_action_log table. This functions is executed in a background thread. See Note [Async action architecture] above

insertActionTx :: ActionName -> SessionVariables -> [Header] -> Value -> TxE QErr ActionId Source #