REST API response says invalid parameters “Brands:”
-
So I have an API connection setup between my FileMaker solution and my website in order to upload/update products that are already in our FileMaker database. I am using cURL with a json array and it works great for everything in the base Woocommerce package but when I try to upload a product with the “Brands” parameter though I am getting this response:
Response: {“code”:”rest_invalid_param”,”message”:”Invalid parameter(s): brands”,”data”:{“status”:400,”params”:{“brands”:”brands[0] is not of type integer.”}}}
Response Code: 400
Response Header: HTTP/1.1 100 ContinueHTTP/1.1 400 Bad Request
The json array that I am trying to send looks like this:
}
],
“backorders” : “yes”,
“brands” :
[
{
“id” : 161
}
],
“button_text” : “”,
“catalog_visibility” : “visible”,
“categories” :
[
{
“id” : 182
}
],
“cross_sell_ids” : [],
“date_on_sale_from” : “”,I have looked through all the documentation including the REST API docs here: https://github.com/quadlayers/perfect-woocommerce-brands/wiki/REST-API-docs
I’m not sure how to use that though since the only way I have worked with the API so far is by using json arrays. Would anybody be able to help me figure out what the format/parameters would be to upload a brand along with the rest of the product information payload?
- The topic ‘REST API response says invalid parameters “Brands:”’ is closed to new replies.