-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AddProduct, AddProductType, and AddCategory fail (possibly bad error message) #17
Comments
It's starting to look like none of the addFoo() methods work. I started trying to add Categories and got a similar message:
After getting the JSON request, I tried sending it through curl on the command line. I got "Validation Error: Description: The field Description must be a string or array type with a maximum length of '500'.", so then I changed my category's description to be shorter and verified that it worked. I deleted the category in the sandbox so I could try again with the SDK. Even though the request object was well-formed, I got "Value can not be null." again. I can't tell if the problem is in MozuClient or Guzzle's Psr7 package, or what, but unless something changes, no one can use this SDK for projects more interesting than "list what I have in Mozu already". |
Can you provide a sample of the call you are doing ? |
There's a lot, even for a simple call because I'm adding in the authentication, so here's a gist. |
Thanks for the sample...i am looking into the issue |
Issue has been fixed in 1.17.2 release. issue was with content-length missing in guzzle request, causing guzzle to default to transfer-encoding: chucked. |
Whenever I try to use the
ProductResource::addProductAsync()
orProductTypeResource::addProductTypeAsync()
methods, I get an error message saying "Product can not be null" or "Value can not be null" respectively. I have verified that I am passing a non-emptyProduct
orProductType
object to those methods as appropriate, even going so far as to inspect the curl set up functions with a debugger, so I have no idea why it would be giving that error message.When I dumped my requests to JSON files and used curl from the command line, I got errors about specific fields being empty when they shouldn't be. Considering that the documentation doesn't actually tell me what fields are required, that makes sense. So I don't know if all POST methods don't work in the SDK or if it is just returning an unhelpful error message.
The text was updated successfully, but these errors were encountered: