Mangopay / mangopay2-php-sdk

PHP SDK for MANGOPAY
https://packagist.org/packages/mangopay/php-sdk-v2
MIT License
122 stars 133 forks source link

OAuth2 authentication #617

Closed glegarand closed 9 months ago

glegarand commented 10 months ago

As Mangopay will deprecate the Basic Auth on January 1st 2024, has someone already integrated OAuth2 with a Bearer token ?

AntoineLemaire commented 10 months ago

Hello, I'm interested also on that question. That means that this code won't work after January 1st 2024? @fredericdelordm

$api = new MangoPay\MangoPayApi();

// configuration
$api->Config->ClientId = 'your-client-id';
$api->Config->ClientPassword = 'your-client-password';
$api->Config->TemporaryFolder = '/some/path/';

$users = $api->Users->GetAll();
fredericdelordm commented 9 months ago

Hello @glegarand and @AntoineLemaire ,

You have nothing to do. The SDK supports OAuth2 and does not use Basic auth.