magentomagento-1.7magento-soap-api

Magento Api Error Fatal error: Uncaught SoapFault exception: [4] Resource path is not callable


When I run following code in magento root

<?php
$client = new SoapClient('http://localhost/mymagento/index.php/api/v2_soap/index?wsdl=1', array('cache_wsdl' => WSDL_CACHE_NONE));
$session = $client->login('testuser', 'testuser');              
    $result = $client->salesOrderList($session);                    
echo"<pre>";
    print_r($result);
echo"</pre>";
?>

I am getting following error

   Fatal error: Uncaught SoapFault exception: [4] Resource path is not callable. in /var/www/html/mymagento/sales_order.php:9
Stack trace:
#0 /var/www/html/mymagento/sales_order.php(9): SoapClient->__call('salesOrderList', Array)
#1 /var/www/html/mymagento/sales_order.php(9): SoapClient->salesOrderList('98850601ed8aa6f...')
#2 {main}
  thrown in /var/www/html/mymagento/sales_order.php on line 9

But when I run

$result = $client->salesOrderInfo($session,'100000030');   

No error comes.

How to fix this? Please help


Solution

  • That means you are trying to access a resource which is not available where it should be.Like the class file.

    In my project I got this error, one directory was not at proper location.Please check you directory structure which you are creating for the overriding the core files. Or check if the core files directory structure has been disturbed mistakenly.