Skip to content
This repository has been archived by the owner on Jun 18, 2018. It is now read-only.

Latest commit

 

History

History
37 lines (25 loc) · 1.28 KB

README.md

File metadata and controls

37 lines (25 loc) · 1.28 KB

Notice: This project is discontinued and no longer maintained nor supported by Tresorit. This repository only exists for archival purposes.


ZeroKit-PHP-admin-api-client

Build Status

Small client lib to call ZeroKit's administrative API from PHP. This lib provides a special HTTP client which automatically signs the administrative requests for your ZeroKit tenant's admin API.

More information about ZeroKit encryption platform: https://tresorit.com/zerokit

ZeroKit management portal: https://manage.tresorit.io

Example

<?php

require_once 'ZeroKitAdminApiClient.php';

use Zerokit\ZeroKitAdminApiClient;

// Provider your zeroKit tenant's settings
$client = new ZeroKitAdminApiClient($ZKIT_SERVICE_URL, $ZKIT_ADMIN_KEY);

// Assemble call and do the request
$response = $client->doJsonCall(
            "POST",
            "/api/v4/admin/user/init-user-registration");

// Use returned data
echo "Generated user id: " . $response->UserId . 
     "Registration session: " . $response->RegSessionId .
     "Registration session verifier: " . $response->RegSessionVerifier;

?>