Hello,
I’m starting with Ubidots API for php. I’m able to publish but not to get Values:
This is my php code:
<?php require 'vendor/autoload.php'; $api = new Ubidots\ApiClient($apikey = "xxxxxxxxxx"); $my_variable = $api->get_variable("yyyyyyyyyyy"); $new_value = $my_variable->save_value(json_encode(array('value' => 20))); $some_values = $my_variable->get_values(3); ?>And these the errors:
Warning : range(): step exceeds the specified range in D:\Mis webs\test\Ubidots\vendor\ubidots\ubidots\src\Ubidots\Paginator.php on line 29
Warning : Invalid argument supplied for foreach() in D:\Mis webs\test\Ubidots\vendor\ubidots\ubidots\src\Ubidots\Paginator.php on line 29
Warning : array_values() expects parameter 1 to be array, boolean given in D:\Mis webs\test\Ubidots\vendor\ubidots\ubidots\src\Ubidots\Paginator.php on line 132
Warning : array_slice() expects parameter 1 to be array, null given in D:\Mis webs\test\Ubidots\vendor\ubidots\ubidots\src\Ubidots\Paginator.php on line 103