/plushcap/analysis/hasura/custom-auth-with-netlify

Custom auth for Hasura with Netlify

What's this blog post about?

In this tutorial, we will create an authentication solution for Hasura using Netlify. The main difference between this and previous solutions is that Netlify Identity supports JWT but does not support custom claims, which are crucial to make Hasura work with JWT tokens. We will use a custom Auth webhook to verify the JWT token provided by Netlify Identity, extract data from it, and send this data in a format Hasura can parse and use in its permission system. The tutorial covers setting up Hasura on Heroku, creating two tables (posts and users), getting users into Hasura, creating a Netlify site, and creating signup and custom auth webhooks. It also discusses signing in with Google or other providers and provides a summary of the live coding solution for real-world problems.

Company
Hasura

Date published
Aug. 1, 2019

Author(s)
Vladimir

Word count
789

Hacker News points
None found.

Language
English


By Matt Makai. 2021-2024.