Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save Tanver-Hasan/0af8e59ae6f62d702206eb97f4fa9193 to your computer and use it in GitHub Desktop.
Save Tanver-Hasan/0af8e59ae6f62d702206eb97f4fa9193 to your computer and use it in GitHub Desktop.
var managementClient = new ManagementClient({
clientId: '',
clientSecret: '',
domain: 'xxx.auth0.com',
retry: {
enabled : true
}
});
@Tanver-Hasan
Copy link
Author

Tanver-Hasan commented Jan 28, 2020

const ManagementClient = require("auth0").ManagementClient;

var client= new ManagementClient({
  domain: "[Auth0 Domain]",
  clientId: "[M2M Client ID ]",
  clientSecret: "[M2M Client secret]",
  audience: "https://[tenant_name].auth0.com/api/v2/",
  retry: {
    enabled : true
  }
});
client.getUser().then(res=>{
  console.log(res);
})

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment