This provides a sample code to make a getServerTime request using PHPToolkit 2012.2. The article requires a basic understanding of PHP and Web Services to get this working.
<?php
require_once './PHPToolkit/NetSuiteService.php';
$service = new NetSuiteService();
$request = new GetServerTimeRequest();
$response = $service->getServerTime($request);
echo '<pre>';
print_r($response);
echo '</pre>';
The script above produces an output like this:
GetServerTimeResponse Object
(
[getServerTimeResult] => GetServerTimeResult Object
(
[status] => Status Object
(
[statusDetail] =>
[isSuccess] => 1
)
[serverTime] => 2013-06-27T22:54:58.000-07:00
)
)
No comments:
Post a Comment