I’m using Auth0 on an Angular 2 SPA, so it’s using auth0-js. I’m trying to enable the Management API so that I can create new users from the application without enabling public sign-ups, but it won’t assign any scopes to my token besides openid and profile. This is the code I use to initialize auth0:
auth0 = new auth0.WebAuth({
clientID: AUTH_CONFIG.clientID,
domain: “[domain name].auth0.com”,
responseType: ‘token id_token’,
audience: https://[domain name].auth0.com/api/v2/",
redirectUri: AUTH_CONFIG.callbackURL,
scope: "openid profile read:user "
});
I also tried to assign the scope in the authorize() function, but that doesn’t change anything.
I can assign scopes from a custom API, but not the management API.