Magento API, use in Android, Iphone, Windows Phone

There are two types of API to use in Magento –

* SOAP
* REST

SOAP

The Magento SOAP API provides ability to manage eCommerce stores by providing calls for working with resources such as customers, categories, products, and sales orders. It also allows to manage shopping carts and inventory.

http://yourmagentohost/api/?wsdl
http://yourmagentohost/api/soap/?wsdl

where yourmagentohost is the domain for your Magento host.

The following PHP example shows you how to make SOAP calls to the Magento API:

$client = new SoapClient('http://yourmagentohost/soap/api/?wsdl');

// If somestuff requires api authentification,
// then get a session token
$session = $client->login('apiUserName', 'apiKey');

$result = $client->call($session, 'stuff.method');
$result = $client->call($session, 'stuff.method', 'arg1');
$result = $client->call($session, 'stuff.method', array('arg1', 'arg2', 'arg3'));
$result = $client->multiCall($session, array(
     array('stuff.method'),
     array('stuff.method', 'arg1'),
     array('stuff.method', array('arg1', 'arg2'))
));


// If you don't need the session anymore
$client->endSession($session);