API wrapper of Frekr.me
This is a PHP Library to recive data from Frekr.me API and convert to php objects. This reduce codification and abstract recive process
composer require pabloveintimilla/frekr
Include to autoload classes
<?php
require __DIR__.'/vendor/autoload.php';
use PabloVeintimilla\Frekr\Frekr;
You need apikey from Frekr.me
$frekr = new Frekr($apikey);
All methods return a array or a POPO (Plain Old PHP object) that represent basic entities: Employee, Event and Terminal
// Recive all employees
$employees = $frekr->getEmployees();
//Recive specific employee by id
$employee = $frekr->getEmployee($employee_id);
//Get first name of employee
$employee->getFirstname();
$events = $frekr->getEvents();
$event = $frekr->getEvent($event_id);
$events = $frekr->getEventsByEmployee($employee_id));
$events = $frekr->getEventsByTerminal($terminal_id);
$terminals = $frekr->getTerminals();
$terminal = $frekr->getTerminal($terminal_id));