{“success”:false,“error”:{“code”:“ACCESS_DENIED”,“message”:“Permission to perform the operation is denied for id”}}
if($challengeResult['success']) {
$accessKey = md5($challengeResult['result']['token']."FsMuMfcT4Iwp0ne");
$postArray = array('operation' => 'login', 'username' => 'admin', 'accessKey' => $accessKey);
print_r($postArray);
$loginResult = json_decode(sendPostRequest($site_URL."/webservice.php", $postArray), true);
the login is successfully but when i add some data.
$data = array(
'subject'=>'AutoGen PurchaseOrder',
'assigned_user_id' => vtws_getWebserviceEntityId('Users',1),
'postatus'=>'Created',
'bill_street'=>'325, 1st Floor, Sant Nagar',
'bill_city' => 'New Delhi',
'bill_state' => 'Delhi',
'bill_code' => '110065',
'bill_country' => 'India',
'ship_street'=>'325, 1st Floor, Sant Nagar',
'ship_city' => 'New Delhi',
'ship_state' => 'Delhi',
'ship_code' => '110065',
'ship_country' => 'India',
'cf_898' => '200140',
'vendor_id' => vtws_getWebserviceEntityId('Vendors',$_POST['fromwarehouse_id']), //
Products from
'cf_1054' => 'Normal', // PurchaseOrder type
'productid' => vtws_getWebserviceEntityId('Products',2),
'LineItems'=>$lineItems
);
the result i get is
"code":"ACCESS_DENIED","message":"Permission to perform the operation is denied for id"
Comments
Post a Comment