MPOS/php-mpos

View on GitHub
include/pages/api/getcurrentworkers.inc.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php
$defflip = (!cfip()) ? exit(header('HTTP/1.1 401 Unauthorized')) : 1;

// Check if the API is activated
$api->isActive();

// Check user token
$user_id = $api->checkAccess($user->checkApiKey($_REQUEST['api_key']), @$_REQUEST['id']);

// Output JSON format
echo $api->get_json($worker->getCountAllActiveWorkers());

// Supress master template
$supress_master = 1;