hasura / hasura/graphql-engine

[docs] Document examples of different JWT providers and their configurations

Open
#8,068 0 comments 1 reaction 0 assignees View on GitHub
c/docs cloud k/enhancement
Dominant language
TypeScript
Stars
32.1k
Forks
3k
PR merge metrics
PR metrics pending

Description

It would be great to have a source of truth of how to configure and get Hasura to work with different JWT providers.

1. What the `HASURA_GRAPHQL_JWT_SECRET` value should be
2. How to customize the role and user-id claims:
a. Option 1: Use hasura JWT claim customization (`claims_map`) which I think most of our users don't even know about!
b. Option 2: Use the identity providers customization feature (eg: auth0 hooks, firebase cloud functions)

I had 3 ideas on where this source of truth could be!

### Idea - 1
A nice docs page where the Hasura team and the community can keep contributing examples that have the subsections above

### Idea - 2
Enhance the hasura.io/jwt-config widget and make it oss so that becomes the single point of reference where everyone can contribute

### Idea - 3
Make this a feature on Hasura Cloud in the env var section (or embed the widget from Idea -2!)

Just some thoughts, but something that would be super helpful and a great time saver.

Some identity providers we commonly run in to:
1. Firebase
2. Auth0
3. Okta
3. Cognito
4. KeyCloak
5. Google Cloud Identity Provider
6. Azure AD
7. Fusion Auth

Contributor guide

Open the contributing guide

Research direction

No file or test is named. Start by reviewing the HASURA_GRAPHQL_JWT_SECRET, claims_map, and hasura.io/jwt-config references, then resolve whether the source of truth should be a docs page, an open-source widget, or a Hasura Cloud feature. Done would require an agreed approach and documented configurations for the listed identity providers.

Written by the indexing model from the issue text.

Assessment

Domain
authentication, documentation, security
Issue type
Documentation
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.