@@ -17,7 +17,7 @@ $sumup = new \SumUp\SumUp([
1717 'app_id' => 'YOUR-CLIENT-ID',
1818 'app_secret' => 'YOUR-CLIENT-SECRET',
1919 'grant_type' => 'authorization_code',
20- 'scope ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly'],
20+ 'scopes ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly'],
2121 'code' => 'YOUR-AUTHORIZATION-CODE'
2222]);
2323$accessToken = $sumup->getAccessToken();
@@ -38,7 +38,7 @@ $sumup = new \SumUp\SumUp([
3838 'app_id' => 'YOUR-CLIENT-ID',
3939 'app_secret' => 'YOUR-CLIENT-SECRET',
4040 'grant_type' => 'client_credentials',
41- 'scope ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly']
41+ 'scopes ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly']
4242]);
4343$accessToken = $sumup->getAccessToken();
4444$value = $accessToken->getValue();
@@ -55,7 +55,7 @@ $sumup = new \SumUp\SumUp([
5555 'app_id' => 'YOUR-CLIENT-ID',
5656 'app_secret' => 'YOUR-CLIENT-SECRET',
5757 'grant_type' => 'password',
58- 'scope ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly'],
58+ 'scopes ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly'],
5959 'username' => 'YOUR-SUMUP-USERNAME',
6060 'password' => 'YOUR-SUMUP-PASSWORD'
6161]);
@@ -71,7 +71,7 @@ Here is how to get a **new access token from a refresh token**:
7171$sumup = new \SumUp\SumUp([
7272 'app_id' => 'YOUR-CLIENT-ID',
7373 'app_secret' => 'YOUR-CLIENT-SECRET',
74- 'scope ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly'],
74+ 'scopes ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly'],
7575 'refresh_token' => 'REFRESH-TOKEN'
7676]);
7777// you need to call the method `refreshToken()` to get a new access token
@@ -89,7 +89,7 @@ If you already have a valid access token you can reuse it like this:
8989$sumup = new \SumUp\SumUp([
9090 'app_id' => 'YOUR-CLIENT-ID',
9191 'app_secret' => 'YOUR-CLIENT-SECRET',
92- 'scope ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly'],
92+ 'scopes ' => ['payments', 'transactions.history', 'user.app-settings', 'user.profile_readonly'],
9393 'access_token' => 'VALID-ACCESS-TOKEN'
9494]);
9595```
0 commit comments