We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents cb02dbf + 64eae20 commit ca3e22cCopy full SHA for ca3e22c
examples/basic-api/src/Main.php
@@ -27,14 +27,15 @@ public function publicPing(){
27
28
public function privatePing(){
29
30
- $userData = \Auth0\SDK\Api\ApiUsers::get(getenv('AUTH0_DOMAIN'),$this->token, $this->tokenInfo->sub);
31
-
+ $auth0Api = new \Auth0\SDK\Auth0Api($this->token, getenv('AUTH0_DOMAIN'));
+ $userData = $auth0Api->users->get($this->tokenInfo->sub);
32
+
33
return array(
34
"status" => 'ok',
35
"message" => 'Shh, it\' secret',
36
"user" => array(
37
"email" => $userData["email"],
- "username" => $userData["username"]
38
+ "name" => $userData["name"]
39
)
40
);
41
}
0 commit comments