freebox_api_php/exemple/download/Trackers.php

22 lines
597 B
PHP
Raw Normal View History

2016-05-26 22:38:44 +02:00
<?php
/// Require Composer AutoLoader
require_once '../../vendor/autoload.php';
/// Define our application
$App = new \alphayax\freebox\utils\Application( 'com.alphayax.freebox.download', 'PHP API Example (Download)', '1.0.0');
$App->authorize();
$App->openSession();
/// List of all downloads
$DownloadService = new \alphayax\freebox\api\v3\services\download\Download( $App);
$Downloads = $DownloadService->getAll();
print_r( $Downloads);
$TrackerService = new \alphayax\freebox\api\v3\services\download\Tracker( $App);
$a = $TrackerService->getAll( $Downloads[1]->getId());
print_r( $a);