Matt Rutledge
2017-11-07T00:01:14Z
405 Sounds potentially like a security error. Although if you have the correct API key you should be good. Have you attempted to set the inventory levels to 0 with the ProductInventoryUpdate endpoint and then attempt a delete?
Will Strohl
2017-12-22T19:04:23Z
I'm not sure what's different, but I'm unable to reproduce the issues on Hotcakes 03.00.01 using the example code below.

using System;
using Hotcakes.CommerceDTO.v1.Client;

namespace ApiSample
{
    internal class Program
    {
        private static void Main(string[] args)
        {
            Console.WriteLine("This is an API Sample Program for Hotcakes");
            Console.WriteLine();

            var url = "http://hcc301.loc";
            var key = "1-9b2ccf0f-5642-418f-8537-cec3fb876f31";
            var proxy = new Api(url, key);

            var product = proxy.ProductsFindBySku("TEST0001").Content;

            if (product != null)
            {
                Console.WriteLine("Product was found...");
                Console.WriteLine("Attempting delete...");
                Console.WriteLine();

                try
                {
                    proxy.ProductsDelete(product.Bvin);
                    Console.WriteLine("GREAT SUCCESS, YES!!");
                    Console.WriteLine();
                }
                catch (Exception ex)
                {
                    Console.WriteLine("An error occurred!!!");
                    Console.WriteLine();

                    Console.WriteLine(ex.Message);
                    Console.WriteLine();
                }
            }
            else
            {
                Console.WriteLine("No product found!");
            }

            Console.WriteLine("Done - Press a key to continue");
            Console.ReadKey();
        }
    }
}

Will Strohl, Upendo Ventures
Hotcakes Cloud  | Get Support  | Code Support 
Official Cloud & Support provider for Hotcakes
Loading
  • Sign-up for the Hotcakes Community Newsletter: