velser/ondato-api-php-client
最新稳定版本:0.2.1
Composer 安装命令:
composer require velser/ondato-api-php-client
包简介
Ondato API Client for PHP
README 文档
README
Ondato API Client for PHP. Used for KYC and Verifid integration with Ondato flows.
Requirements
- php7.1+
Installation
composer require velser/ondato-api-php-client
Usage
Kyc
$guzzleClient = new GuzzleHttp\Client([
'timeout' => 10,
'allow_redirects' => false,
'base_uri' => 'https://ondatourl',
'headers' => [
'Accept' => 'application/json'
]
]);
$kycApiClient = new Velser\OndatoApiClient\KycApiClient($guzzleClient, 'apikey');
Verifid
$guzzleClient = new GuzzleHttp\Client([
'timeout' => 10,
'allow_redirects' => false,
'base_uri' => 'https://ondatourl',
'headers' => [
'Accept' => 'application/json'
]
]);
$kycApiClient = new Velser\OndatoApiClient\VerifidApiClient(
$guzzleClient,
'username',
'password'
);
Notes
- Accept header is mandatory, as it otherwise server will return multipart response when sending multipart request;
- base_uri is root uri of Ondato API without specific path;
TODO
- add factory for quick client building via DI;
- tests;
- client exceptions remap to specific exceptions;
Contribution/Maintaining
- Library is maintainable as it's needed. Any contribution/fixes/improvements are appreciated;
- This library is not related to Ondato itself. It's just an integration. So only this repository related stuff is discussed within this repository;
License
MIT (Can be found in LICENSE file)
统计信息
- 总下载量: 6.14k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2018-12-19