To process badges with backpack and control api request and this class using for Open Badge API v2.1 methods.
More...
|
null | $backpackapiurl = '' |
| api URL of the backpack.
|
|
null | $backpackapiversion |
| version api of the backpack.
|
|
To process badges with backpack and control api request and this class using for Open Badge API v2.1 methods.
- Copyright
- 2020 Tung Thai
- License
- http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
◆ __construct()
core_badges\backpack_api2p1::__construct |
( |
|
$externalbackpack | ) |
|
backpack_api2p1 constructor.
- Parameters
-
object | $externalbackpack | object |
- Exceptions
-
◆ curl_request()
core_badges\backpack_api2p1::curl_request |
( |
|
$action, |
|
|
|
$postdata = null |
|
) |
| |
Make an api request.
- Parameters
-
string | $action | The api function. |
string | $postdata | The body of the api request. |
- Return values
-
◆ disconnect_backpack()
core_badges\backpack_api2p1::disconnect_backpack |
( |
|
$backpack | ) |
|
Disconnect the backpack from this user.
- Parameters
-
object | $backpack | to disconnect. |
- Return values
-
- Exceptions
-
◆ get_stored_token()
core_badges\backpack_api2p1::get_stored_token |
( |
|
$externalbackpackid | ) |
|
|
protected |
Get token.
- Parameters
-
int | $externalbackpackid | ID of external backpack. |
- Return values
-
oauth2::badge_backpack_oauth2|false|stdClass|null | |
◆ put_assertions()
core_badges\backpack_api2p1::put_assertions |
( |
|
$hash | ) |
|
Export a badge to the backpack site.
- Parameters
-
string | $hash | of badge issued. |
- Return values
-
- Exceptions
-
The documentation for this class was generated from the following file: