PHP code example of sammaye / yii2-netsuite

1. Go to this page and download the library: Download sammaye/yii2-netsuite library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

sammaye / yii2-netsuite example snippets


$service = Yii::$app->ns->service;

$request = new \GetDataCenterUrlsRequest();
$request->account = Yii::$app->ns->account;
$Response = $service->getDataCenterUrls($request);
	
if(!$Response->getDataCenterUrlsResult->status->isSuccess){
}else{
	$rest = $Response->getDataCenterUrlsResult->dataCenterUrls->restDomain;
	$system = $Response->getDataCenterUrlsResult->dataCenterUrls->systemDomain;
	$webservices = $Response->getDataCenterUrlsResult->dataCenterUrls->webservicesDomain;
}