Error on product update from dashboard

products

#1

Hi there !

I tried to update my product price from the dashboard but something seems to be broken as it returns an error each time I try to udpate my product.
I inspected my web browser and the returned error is about the product slug, like it is bad because it accept only letter, numbers and dashes.
Here is the exact error message :

"The data.slug may only contain letters, numbers, and dashes."

Thing is that my product slug is using the slug_builder variation modifier feature so it looks like this : test-{key}.

Can anybody help me on this ?

Thanks


#2

Hi @NeilujD,

Could you post the payload you are sending to the API, please?

Thanks,

Drew


#3

I have the payload here from @jonathan.

      "relationships":{
         "categories":{
            "data":[
               {
                  "type":"categories",
                  "id":"47e583fc-2560-4ef7-b58a-5f98659aaaa2"
               }
            ]
         }
      },
      "type":"products",
      "commodity_type":"physical",
      "description":"Pop Holder for smartphone",
      "manage_stock":true,
      "name":"Pop Holder",
      "sku":"POP-{COLOR}-{DESIGN}",
      "slug":"pop-{COLOR}-{DESIGN}",
      "status":"live",
      "price":[
         {
            "amount":990,
            "currency":"EUR",
            "includes_tax":true
         }
      ]
   }
}
And the response :

{
   "errors":[
      {
         "title":"Failed Validation",
         "detail":"The data.slug may only contain letters, numbers, and dashes."
      }
   ]
}

Are you experiencing this in the dashboard also?


#4

Hi @drew !
I experienced that in the dashboard and using Postman.


#5

Thanks, @NeilujD I will try and replicate and feedback to you ASAP.