PHP code example of xhkj-supply / edu-php-sdk
1. Go to this page and download the library: Download xhkj-supply/edu-php-sdk library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
xhkj-supply / edu-php-sdk example snippets
/**
* Created by PhpStorm.
* User: huidaoli
* Date: 2023/10/23
* Time: 2:04 PM
*/
use Xhkj\Edu\EduClient;
$appKey = "your appkey";
$appSecret = "your appSecret";
try {
$eduClient = new EduClient($appKey,$appSecret);
} catch (OssException $e) {
printf(__FUNCTION__ . "creating eduClient instance: FAILED\n");
printf($e->getMessage() . "\n");
return null;
}
$param = [
];
$response = json_decode($eduClient->getApiResponse("post","/ssologin/refreshtoken",$param));
bash
$ composer