CLS4WEQQ7DRG2WZZ6NFTVTCGI7N77TRH
application / json, application / xml, text / json, text / x-json, text / javascript, text / xml
<? xml version = "1.0" encoding = "UTF-8"?>
<prestashop xmlns: xlink = "http://www.w3.org/1999/xlink">
<errors>
<error>
<code> <! [CDATA [25]]> </ code>
<message> <! [CDATA [Method POST is not allowed for the resource with this authentication key]]> </ message>
</ error>
</ errors>
</ prestashop>
HttpStatusCode: MethodNotAllowed
Call:
public static void AddImage (product p, string imgPatch)
{
// test 1 //
var imgFact = new ImageFactory (BaseUrl, Account, Password);
var c = RestSharpFactory.ImageToBinary (imgPatch);
imgFact.AddProductImage (p.id.Value, c);
// test 2 //
ImageFactory factory = new ImageFactory (BaseUrl, Account, Password);
string image = @"C:\temp\MyImage.jpg";
var result = factory.AddProductImage (p.id.Value, image);
////// IN BOTH CASES THE SAME ERROR //////
}
Prestashop 1.7.2.4 hosted on 1&1
RestSharp 106.2.1.0
I receive this error when I try to add an image
Call:
Prestashop 1.7.2.4 hosted on 1&1 RestSharp 106.2.1.0
Any ideas?
Thank you.