Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct way to use the JWT Token generated in API v2 if we want expanded scope #19

Closed
shankscoder opened this issue Jun 17, 2015 · 4 comments

Comments

@shankscoder
Copy link

Hi,
We're trying to build a small management admin dashboard for our Auth0 setup, and we want to give rights to our admins in this app to create new users and update existing user data.

We've generated the token in the API v2 section, but it's not clear on how to use this token with the Auth0 PHP SDK class.

Could you share some insight on the correct way to use this?

Thanks in advance.

@glena
Copy link
Contributor

glena commented Jun 29, 2015

Hi @shankscoder:

you should use

\Auth0\SDK\API\ApiUsers::create($domain, $token, $data)

Right now, only have a client for the users endpoints, let me know which ones do you need to use and I can add them (or you can shoot a PR based on the ApiUsers).

Sorry for the delay on the answer, didn't receive the notification.

@shankscoder
Copy link
Author

Thanks. We figured this out. We're using other API endpoints as well (mainly user and app metadata), so we're directly consuming the APIs in Guzzle.

It'd be great if you could have modular classes for each object type in the API (user, apps, etc.) so that we can pick and choose the necessary object we want to work with without having a bloated client.

@glena
Copy link
Contributor

glena commented Jul 17, 2015

Hi, just to let you know, we added support for several new api v2 endpoints :)
The new version released is 1.0.7.

@glena glena closed this as completed Jul 17, 2015
@github-actions
Copy link
Contributor

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 23, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants