Hello, i tried to get list of customers with the specific service parameter. I was looking on the example here: http://docs.splynx.apiary.io/#reference/customers/custom-services-collection/list-custom-services-by-parameters and example on the wiki.
This is my php code:
<?php
include 'SplynxApi.php';
$splynx_url = 'URL';
$key = "key";
$secret = "secret";
$api = new SplynxAPI($splynx_url, $key, $secret);
$search = array(
'main_attributes' => array(
'status' => 'active'
)
);
$servicesApiUrl = "admin/customers/customer/0/custom-services?".http_build_query($search);
print "<pre>";
print "List locations\n";
$result = $api->api_call_get($servicesApiUrl);
print "Result: ";
if ($result) {
print "Ok!\n";
print_r($api->response);
} else {
print "Fail! Error code: $api->response_code\n";
print_r($api->response);
}
?>
I got response: OK but nothing to print.
Can you please advise me, where I have problem?
I have splynx version 1.2.
Thank you.