https://packagist.org/packages/infobird/openapi
- PHP 5.3+.
- cURL extension.
composer require infobird/openapi
index.php file you need to add
require './vendor/autoload.php';
use \Infobird\Openapi\Client;
$token = $this->_request->token;
$systemId = $this->_request->version_id;
$corpType = $this->_request->isfz?:0;
if(empty($token)){
echo 'token not found!';exit;
}
$c = new Client($token,$systemId,$corpType);
$res = $c->auth();
$res = json_decode($res,true);
if($res['code']!=='0'){
echo $res['msg'];exit;
}