Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- error_reporting(E_ALL);
- ini_set('display_errors', '1');
- $client = new SoapClient('http://cssincusa.com/api/v2_soap?wsdl');
- $session = $client->login((object)array('username' => 'test', 'apiKey' => 'soapapi'));
- $result = $client->catalogProductCreate((object)array('sessionId' => $session->result, 'storeView'=>0, 'type' => 'simple', 'set' => '4', 'sku' => 'product_sku1',
- 'productData' => ((object)array(
- //'type' => 'simple',
- 'categories' => array(112),
- //'websites' => [1, 0],
- 'website_ids' => array(1),
- 'name' => 'Product name1',
- 'description' => 'Product description',
- 'short_description' => 'Product short description',
- 'weight' => 10,
- 'status' => 1,
- 'url_key' => 'product-url-key',
- 'url_path' => 'product-url-path',
- 'visibility' => 2,
- 'tax_class_id' => 0,
- 'meta_title' => 'Product meta title',
- 'meta_keyword' => 'Product meta keyword',
- 'meta_description' => 'Product meta description',
- 'stock_data' => array(
- 'is_in_stock ' => 1,
- 'qty' => 100,
- 'manage_stock' => 1,
- 'notify_stock_qty' => 1,
- 'backorders' => 1,
- 'use_config_backorders' => 1,
- )
- ))));
- var_dump($result);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement