Sudden breaking change in PUT /products/:productId/variations/:variantId?

Hello,

When consuming the endpoint /products/:productId/variations/:variantId, we always passed a json like this:

{
   "name":"string",
   "prices":[
      {
         "price":decimal,
         "currency":"string"
      }
   ]
}

But now, when trying to consume the endpoint with the exact same structure, we get this error message:

{
   "success":false,
   "error":"body/prices/0 must have required property 'cost', body/prices/0 must have required property 'comment', body/prices/0 must have required property 'id', body/prices/0 must have required property 'cost', body/prices/0 must have required property 'comment', body/prices/0 must match a schema in anyOf",
   "error_info":"Acesse developers.pipedrive.com para mais informações sobre a API do Pipedrive.",
   "data":null,
   "additional_data":null
}

Was any change related to this endpoint made? Thanks in advance.

Hello @joaoHass and welcome to the community! :wave:

The endpoint you are using for updating product variations is an undocumented API endpoint, which we do not recommend using, because any changes to it are not actively supervised and communicated.

From the error message, it seems that you are missing required parameters in the prices object.

Sincerely,
Helena

Hoping the variants get further developed this year. I know a team is working on products module.

Variants are great but current state does not allow much flexibility.

I can see in the API their is a field for variant description but not accessed by user.

Hope to see that get used and tied into documents for when a proposal is generated from a template the variant description is used and not the main products.

Hard to use variants in current state when description is shared between all.

Hi, @jbuesking :wave:

Thank you for the feedback! I will make sure to forward your feedback about product variants to the concerned team!

In the meantime, I would suggest subscribing to our Changelog where we announce all new features of our API if you haven’t already. :slight_smile:

1 Like