psr18-adapter / mangopay-php-sdk-v2
0.1
2020-08-29 00:53 UTC
Requires
- php: >=7.0
- mangopay/php-sdk-v2: >=2.5.1
- psr/http-client: ^1.0
- psr/http-factory: ^1.0
This package is auto-updated.
Last update: 2024-10-29 05:53:50 UTC
README
Install
Via Composer
composer require psr18-adapter/mangopay-php-sdk-v2
Usage
$api = new \MangoPay\MangoPayApi(); $api->setHttpClient( new \Psr18Adapter\Mangopay\MangopayPsr18Client( $api, $psr18Client, $psrRequestFactory, $psrUriFactory, $psrStreamFactory ) );
Usage with teknoo/mango-pay-bundle
services: mangopay.sdk.http_client: class: Psr18Adapter\Mangopay\MangopayPsr18Client arguments: $root: '@mangopay.sdk.mango_pay_api.service' # This is not technically required. Define only if you are logging all requests in your http client, # so don't need mangopay client's stock logging. We are redefining original service to avoid setLogger call. mangopay.sdk.mango_pay_api.service: class: '%mangopay.sdk.mango_pay_api.class%' calls: - [setHttpClient, ['@mangopay.sdk.http_client']]
Licensing
MIT license. Please see License File for more information.