2018-09-11 14:11:24 +03:00
Auth webhook samples
====================
2018-12-03 15:12:24 +03:00
.. contents :: Table of contents
:backlinks: none
:depth: 1
:local:
2019-01-04 17:01:18 +03:00
We have put together a `GitHub Node.js repo <https://github.com/hasura/graphql-engine/tree/master/community/boilerplates/auth-webhooks/nodejs-express> `__ that has some sample auth
2018-09-11 14:11:24 +03:00
webhooks configured.
You can deploy these samples using `glitch <https://glitch.com/> `__ :
.. image :: https://raw.githubusercontent.com/hasura/sample-auth-webhook/master/assets/deploy-glitch.png
:width: 200px
:alt: deploy_auth_webhook_with_glitch
:class: no-shadow
:target: http://glitch.com/edit/#!/import/github/hasura/sample-auth-webhook
Once deployed, you can use any of the following endpoints as your auth webhook in the GraphQL engine:
2019-01-04 17:01:18 +03:00
- `` /simple/webhook `` (`View source <https://github.com/hasura/graphql-engine/blob/master/community/boilerplates/auth-webhooks/nodejs-express/server.js> `__ )
- `` /firebase/webhook `` (`View source <https://github.com/hasura/graphql-engine/blob/master/community/boilerplates/auth-webhooks/nodejs-express/firebase/firebaseHandler.js> `__ )
2018-09-11 14:11:24 +03:00
.. note ::
2019-01-08 14:06:16 +03:00
If you are using `` firebase `` you will have to set the associated environment variables.