I want to get live rates of all shipping methods of TNT Lebanon between origin and delivery address. Like Road Express, Overnight Express, Overnight PAYU Satchel, 9:00 Express, 10:00 Express, etc.
I am using below code.
$url = 'http://app.thenetmanager.net/pos/POSWS.asmx?op=CalculatePOSOrderPrice';
$xmlRequest = "<? xml version = "1.0" encoding = "utf-8"?>
<soap12:Envelope xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
<soap12:Body>
<CalculatePOSOrderPrice xmlns="http://posws.org/">
<userIdentifier>69741684-B9DA-404D-833D-1DE02F11154E</userIdentifier>
<serviceID>70</serviceID>
<shipperCity>LEBANON</shipperCity>
<consigneeCountry>TRIPOLI</consigneeCountry>
<consigneeCity>opentext</consigneeCity>
<isDocument>false</isDocument>
<weight>0.6</weight>
<specialDelivery>-1</specialDelivery>
<goodsValue>10.0</goodsValue>
<goodsDescription>description</goodsDescription>
<addPacking>false</addPacking>
<addFumigation>false</addFumigation>
<addPermit>false</addPermit>
<addInsurance>false</addInsurance>
</CalculatePOSOrderPrice>
</soap12:Body>
</soap12:Envelope>";
$ch = curl_init();
curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/xml'));
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $xmlRequest);
curl_setopt($ch, CURLOPT_TIMEOUT, 30);
$xmlResponse = curl_exec($ch);
print_r($xmlResponse);
But gives me an empty message.