Hello,
I have got error after fetching from woo api
rest = new RestAPI(shop.ShopApiUrl, shop.KeyApi, secretId); wc = new WCObject(rest); var date = dateFrom.ToUniversalTime().AddMinutes(-3).ToString("u").Replace(" ", "T"); try { var ordersFromShop = await wc.Order.GetAll(new Dictionary<string, string>() { {"order", "desc" }, {"modified_after", date}, {"per_page", "100" }, {"status","pending,processing" } }); orders = ordersFromShop; } catch (Exception ex) { throw new Exception($"Ta linia powoduje błąd {ex.Message} {ex.InnerException} </br> {orders.ToString()}"); }
Error
'utf8' is not a supported encoding name. For information on defining a custom encoding, see the documentation for the Encoding.RegisterProvider method. (Parameter 'name')
System.Collections.Generic.List`1[WooCommerceNET.WooCommerce.v3.Order]
I check everything in woo. Has anyone encountered such an error?
I expect the problem is on the woocommerce side, as 2 other stores use the same C# method
Hello,
I have got error after fetching from woo api
rest = new RestAPI(shop.ShopApiUrl, shop.KeyApi, secretId); wc = new WCObject(rest); var date = dateFrom.ToUniversalTime().AddMinutes(-3).ToString("u").Replace(" ", "T"); try { var ordersFromShop = await wc.Order.GetAll(new Dictionary<string, string>() { {"order", "desc" }, {"modified_after", date}, {"per_page", "100" }, {"status","pending,processing" } }); orders = ordersFromShop; } catch (Exception ex) { throw new Exception($"Ta linia powoduje błąd {ex.Message} {ex.InnerException} </br> {orders.ToString()}"); }Error
'utf8' is not a supported encoding name. For information on defining a custom encoding, see the documentation for the Encoding.RegisterProvider method. (Parameter 'name')
System.Collections.Generic.List`1[WooCommerceNET.WooCommerce.v3.Order]
I check everything in woo. Has anyone encountered such an error?
I expect the problem is on the woocommerce side, as 2 other stores use the same C# method