I want to use the Auth0 Permissions you can set to an user as scope Keys for displaying serveral things on my frontend. An example JWT looks like this:
{
"iss": "https://xxxxx.eu.auth0.com/",
"sub": "github|xxxxx",
"aud": [
"https://xxxxx.app/api/secret",
"https://xxxx.eu.auth0.com/userinfo"
],
"iat": 1594843242,
"exp": 1543243234,
"azp": "lLKv8g6Z43423423421eJjO4n",
"scope": "openid profile email",
"permissions": [
"admin",
"read:users"
]
}
Now I added scopeKey to my auth configuration in my nuxt.config.js
auth: {
scopeKey: 'permissions',
[...]
}
In my application
this.$auth.hasScope('admin')
is always returning false.
Am I am missing somethings or did I get something wrong? Is it not possible because it is not space separated like the normal "scope"? Thanks in advance!