WILLIAM GREENE Posted May 21 Share Posted May 21 Hi, I'm making great progress but am stuck trying to create a stock item. The code is below. It enters perfectly except it shows as Non-Stock. When I use the api to get the product details it shows catalog_item_type as {"id": "PRODUCT","displayed_as": "Non-stock","$path": "/catalog_item_types/PRODUCT"} Do I need to add some more info? Other stock items which I entered manually show as {"id": "STOCK_ITEM","displayed_as": "Stock","$path": "/catalog_item_types/STOCK_ITEM"} Many thanks, Bill {'product': { 'description': 'tomatoes', 'sales_ledger_account_id': 'db9b8a68106b11ef963b02a97020826f', 'purchase_ledger_account_id': 'db9a0a63106b11ef963b02a97020826f', 'item_code': 'toms_6pack', // must be unique 'notes': 'very tasty', 'sales_tax_rate_id': 'IE_ZERO', // 'usual_supplier_id':'', // 'purchase_tax_rate_id':'', // 'cost_price':'' // 'purchase_decription':'', 'active': true, 'catalog_item_type_id':'STOCK_ITEM', 'sales_prices': [ {'price_name': 'Sales Price','price': 2.34,'price_includes_tax': false,'product_sales_price_type_id': 'd666f161fe3d4643b1b39ff44b51ac08'} ] } } Link to comment Share on other sites More sharing options...
Steel, Mark Posted May 21 Share Posted May 21 Hi Bill, You need to use the stock_items API to create a stock_item. The products API will return stock_items but it cannot create or modify them. https://developer.sage.com/accounting/reference/products-services/#tag/Stock-Items Thanks Mark Link to comment Share on other sites More sharing options...
WILLIAM GREENE Posted May 21 Author Share Posted May 21 My goodness, that's incredible support! I just went off for a quick sandwich, come back and the answer is there. Many thanks, Bill Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now