Skip to content

Commit

Permalink
feat: add is_anonymous claim to Auth hook jsonschema (supabase#1667)
Browse files Browse the repository at this point in the history
## What kind of change does this PR introduce?

Add is_anonymous claim to hook spec to ensure that generated tokens
always contain the is_anonymous claim.
  • Loading branch information
J0 authored and LashaJini committed Nov 13, 2024
1 parent 20f25b7 commit 4ed9fe0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/hooks/auth_hooks.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ const MinimumViableTokenSchema = `{
"type": "string"
}
},
"required": ["aud", "exp", "iat", "sub", "email", "phone", "role", "aal", "session_id"]
"required": ["aud", "exp", "iat", "sub", "email", "phone", "role", "aal", "session_id", "is_anonymous"]
}`

// AccessTokenClaims is a struct thats used for JWT claims
Expand Down

0 comments on commit 4ed9fe0

Please sign in to comment.