<?php

$inHttp = (isset($_GET['debug-iquesta'])) ? 1 : 0;

if(!$inHttp) {
    $_SERVER['REMOTE_ADDR'] = 'crontobeerasmus';
    require_once dirname(dirname(dirname(__DIR__))) . '/wp-load.php';
}

require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'vendor' . DIRECTORY_SEPARATOR . 'autoload.php');
use \App\IquestaToMyListingJob;

$iQuesta =  App\IquestaToMyListingJob::getInstance();

$iQuestaArgs = array('country_id' => 1, 'page' => 1, 'take' => 1);
$datas = $iQuesta->iQuestaOffers($iQuestaArgs);

if($inHttp)echo('<pre>');
print_r($datas);
if($inHttp)echo('</pre>');
exit("\n\nend\n\n");