Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Data exchange with Magento Commerce
Message
De
02/03/2009 07:56:58
 
 
À
20/02/2009 14:08:48
Information générale
Forum:
Visual FoxPro
Catégorie:
Produits tierce partie
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows NT
Database:
MySQL
Application:
Desktop
Divers
Thread ID:
01383070
Message ID:
01384908
Vues:
50
>Can you not use the product API? http://www.magentocommerce.com/wiki/doc/webservices-api/api#product_api
>
Hi Hank...

Finally I found that docs wasn't updated..

specialty on:
$proxy 		= new SoapClient("http://www.domain.com/magento/index.php/api/soap/index/wsdl/1");
And far from it.. I found a limitation to consume that webservice with VFP.. VFP doesn't setup arrays using names as indexes

tks

>
>>>a quick search shows that Magento has a full-featured web service API. http://www.magentocommerce.com/support/magento_core_api
>>>
>>>Rather than have to reverse engineer their database, I'd suggest you use their API.
>>>
>>
>>Hank
>>
>>Seems cool.. but, I don't have any idea how to implement that PHP routine of a single product listing in VFP9
>>
>>
>>$proxy = new SoapClient('http://magentohost/api/soap/?wsdl');
>>$sessionId = $proxy->login('apiUser', 'apiKey');
>> 
>>$filters = array(
>>    'sku' => array('like'=>'zol%')
>>);
>> 
>>$products = $proxy->call($sessionId, 'product.list', array($filters));
>> 
>>var_dump($products);
>>
>>
>>I know by the use of PHP... The following one show how to task create/view/update/delete on Product table... Could someone translate that for vfp9?
>>
>>
>>$proxy = new SoapClient('http://magentohost/api/soap/?wsdl');
>>$sessionId = $proxy->login('apiUser', 'apiKey');
>> 
>>$attributeSets = $proxy->call($sessionId, 'product_attribute_set.list');
>>$set = current($attributeSets);
>> 
>> 
>>$newProductData = array(
>>    'name'              => 'name of product',
>>     // websites - Array of website ids to which you want to assign a new product
>>    'websites'          => array(1), // array(1,2,3,...)
>>    'short_description' => 'short description',
>>    'description'       => 'description',
>>    'price'             => 12.05
>>);
>> 
>>// Create new product
>>$proxy->call($sessionId, 'product.create', array('simple', $set['set_id'], 'sku_of_product', $newProductData));
>> 
>>// Get info of created product
>>var_dump($proxy->call($sessionId, 'product.info', 'sku_of_product'));
>> 
>>// Update product name on german store view
>>$proxy->call($sessionId, 'product.update', array('sku_of_product', array('name'=>'new name of product'), 'german'));
>> 
>>// Get info for default values
>>var_dump($proxy->call($sessionId, 'product.info', 'sku_of_product'));
>>// Get info for german store view
>> 
>>var_dump($proxy->call($sessionId, 'product.info', array('sku_of_product', 'german')));
>> 
>>// Delete product
>>$proxy->call($sessionId, 'product.delete', 'sku_of_product');
>> 
>>try {
>>    // Ensure that product deleted
>>    var_dump($proxy->call($sessionId, 'product.info', 'sku_of_product'));
>>} catch (SoapFault $e) {
>>    echo "Product already deleted";
>>}
>>
>>
>>tks
>>
>>>>I'm running under a task to integrate data exchange between our POS application and Magento e-commerce...
>>>>
>>>>http://www.magentocommerce.com/
>>>>
>>>>Does anyone here had some similar experience.. That mind to share here some SQLs code to import/export products, clients and orders programmactically via ODBC
"Now to him who is able to do immeasurably more than all we ask or imagine, according to his power that is at work within us, Ephesians 3:20
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform