Skip to content

Commit c574129

Browse files
committed
Updated docs and dependencies. Fix json decode
1 parent c7c1f3f commit c574129

File tree

7 files changed

+18
-7
lines changed

7 files changed

+18
-7
lines changed

README.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,16 @@ Check our docs page to get a complete guide on how to install it in an existing
1111
1212
## News
1313

14-
The version 1.x of the PHP SDK now works with the Auth API v2 which adds lots of new [features and changes](https://auth0.com/docs/apiv2Changes).
14+
- The version 2.x of the PHP SDK was updated to work with Guzzle 6.1. For compatibility fith Guzzle 5, you should use 1.x branch.
15+
- The version 1.x of the PHP SDK now works with the Auth API v2 which adds lots of new [features and changes](https://auth0.com/docs/apiv2Changes).
1516

1617
### Backward compatibility breaks
1718

19+
2.x
20+
- Session storage now returns null (and null is expected by the sdk) if there is no info stored (this change was made since false is a valid value to be stored in session).
21+
- Guzzle 6.1 required
22+
23+
1.x
1824
- Now, all the SDK is under the namespace `\Auth0\SDK`
1925
- The exceptions were moved to the namespace `\Auth0\SDK\Exceptions`
2026
- The method `Auth0::getUserInfo` is deprecated and soon to be removed. We encourage to use `Auth0::getUser` to enforce the adoption of the API v2
@@ -55,6 +61,11 @@ $ composer install
5561
$ php -S localhost:3000
5662
```
5763

64+
## Migration guide from 1.x
65+
66+
1. If you use Guzzle (or some other dependency does), you will need to update it to work with Guzzle 6.1.
67+
2.
68+
5869
## Migration guide from 0.6.6
5970

6071
1. First is important to read the [API v2 changes document](https://auth0.com/docs/apiv2Changes) to catch up the latest changes to the API.

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
],
1212
"require": {
1313
"php": ">=5.4.0",
14-
"guzzlehttp/guzzle": "~6.1",
14+
"guzzlehttp/guzzle": "^6.1",
1515
"ext-json": "*",
1616
"adoy/oauth2": "~1.3",
1717
"firebase/php-jwt" : "~2.2"

examples/basic-api/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"bramus/router": "dev-master",
66
"adoy/oauth2": "dev-master",
77
"vlucas/phpdotenv": "1.1.1",
8-
"auth0/auth0-php": "~1.0"
8+
"auth0/auth0-php": "~2.0"
99
},
1010
"autoload": {
1111
"psr-4": {

examples/basic-oauth/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"require": {
55
"adoy/oauth2": "dev-master",
66
"vlucas/phpdotenv": "1.1.1",
7-
"auth0/auth0-php": "~1.0"
7+
"auth0/auth0-php": "~2.0"
88
},
99
"license": "MIT",
1010
"authors": [

examples/basic-webapp/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"require": {
55
"adoy/oauth2": "dev-master",
66
"vlucas/phpdotenv": "1.1.1",
7-
"auth0/auth0-php": "~1.0"
7+
"auth0/auth0-php": "~2.0"
88
},
99
"license": "MIT",
1010
"authors": [

examples/link-users/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"require": {
55
"adoy/oauth2": "dev-master",
66
"vlucas/phpdotenv": "1.1.1",
7-
"auth0/auth0-php": "~1.0"
7+
"auth0/auth0-php": "~2.0"
88
},
99
"license": "MIT",
1010
"authors": [

src/API/RequestBuilder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ public function call() {
9696
]);
9797
$body = (string) $response->getBody();
9898

99-
return $this->jsonDecode($body, true);
99+
return json_decode($body, true);
100100

101101
} catch (RequestException $e) {
102102
throw $e;

0 commit comments

Comments
 (0)