Error updating productAttribute

willianvlemmingswillianvlemmings Member Posts: 4

When trying to update an attribute with the API we get this error:

{"error":{"code":403,"method":"UPDATE","request":"\/nl\/products\/89607980\/attributes\/731997.json","message":"The server understood the request, but is refusing to fulfill it."}}array(1) {

 ["error"]=>

 array(4) {

  ["code"]=>

  int(403)

  ["method"]=>

  string(6) "UPDATE"

  ["request"]=>

  string(44) "/nl/products/89607980/attributes/731997.json"

  ["message"]=>

  string(65) "The server understood the request, but is refusing to fulfill it."

 }

}


Payload:

{

  "productAttribute":{

   "value":"Black"

  }

}


We checked the permissions by contacting the support desk (Tom) and they confirmed the permissions are fine.

Can you help us solving this problem?

7 comments

  • LucienVersendaalLucienVersendaal Moderator, Lightspeed Staff Posts: 351 moderator

    Hi @willianvlemmings,

    Thank you for contacting us.

    I did some test in my environment without any trouble. Can you tell me the shopID so I can test on that account?

  • willianvlemmingswillianvlemmings Member Posts: 4

    Thanks in advance! Our shopID is: 185213

  • LucienVersendaalLucienVersendaal Moderator, Lightspeed Staff Posts: 351 moderator

    Hi @willianvlemmings,

    What I see is that this is an OMNI account. Products cannot being written through the eCom API, this is read only. This because Retail is leading, every change that is made on Retail side will be pushed to eCom, if you have that set up.

  • willianvlemmingswillianvlemmings Member Posts: 4

    The problem is not all information that is provided and is needed for displaying in eCom is available in retail product options...

  • LucienVersendaalLucienVersendaal Moderator, Lightspeed Staff Posts: 351 moderator

    Okay I will fix this for you.

  • willianvlemmingswillianvlemmings Member Posts: 4

    Thanks, the api is indeed writeable at the moment.

    The attributes we are updating works fine for the dutch language, which is the default language. The problem is that the shop is multilanguage. How can we write the german value of the attribute?

  • LucienVersendaalLucienVersendaal Moderator, Lightspeed Staff Posts: 351 moderator

    You'll need to change the language code in the url. Now it's something like

    /nl/products.json
    

    For German you'll need to use

    /de/products.json
    

    I hope this helps.

Sign In or Register to comment.