PHP code example of kokos-api / kokos-activator-api
1. Go to this page and download the library: Download kokos-api/kokos-activator-api 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/ */
kokos-api / kokos-activator-api example snippets
namespace Example;
use KokosActivatorApi\KokosApiClient;
use KokosActivatorApi\Database\Types\UploadPack;
$client = new KokosApiClient(
token: '<token>',
);
$client->database->uploadCodes(
[
new UploadPack([
'denomination' => 60,
'codes' => [
'r3h4x2Jh2W2853g9g4',
'Nq7QDWZw2F2eZ4ndZd',
'Nq7QDHZA2Q2cZ7rdw3',
'Nq7QDYZa2N22Z0r0vc',
'Nq7QDDZ72U4738E64c',
],
]),
],
);