Lokesh Jain
Lokesh Jain

Reputation: 579

How to get order review information in magento

I am making API for android app using magento website. So I am using Magento API. In my checkout process at last i want to show order review. In order review i want to show product name, price, quantity, subtotal, shipping charges, grand total. So how can i get whole information? It would be great if solution will be in Magento API.

Upvotes: 1

Views: 537

Answers (1)

Ankit
Ankit

Reputation: 259

use following code for review order in magento using soap api:

$client = new SoapClient("http://example.com/api/soap/?wsdl");
$session = $client->login('username', 'password'); //set session
$cartInfo=array();

$quoteId = $client->call($session, 'cart.create', array('default'));// for create cart 
$cartInfo['info'] = $client->call($session, 'cart.info', $quoteId); // for get all cart information
$cartInfo['total'] = $client->call($session, "cart.totals", array($quoteId)); get cart total and shipping charges
print_r($cartInfo);

Upvotes: 2

Related Questions