Updating a dropdown(enum) column value from API

Hi,

Please let me know how can i update the dropdown value from the api update a deal endpoint .
i tried with textbox it updates the vale but when i try to update dropdown value it shows me 400.
please help asap

Hi Chander,

Can you share what PUT request you’re making?

{“id”:“3”,“d543cca81d9472464f9526f66fe272d621ce1503”:“10”}
we are sending this json
deal id and the custom field key with its option .
if we are doing wrong can you please suggest me how to update the enum field .

Hi again,

Could you tell me the endpoint you’re using though so I know how you’re trying to update?

Hi,
put request
https://api.pipedrive.com/v1//deals/3?api_token={token}
and in body
{

"d543cca81d9472464f9526f66fe272d621ce1503":"10"

}

dropdown key and its option value

i am using deals/{id}
to update dropdownvalue on pipedrive

Are you positive you’re using the correct API key for that Field? Also, is the value '10' already a predefined ID for that Field?

You can’t add new values with deals/{id}, you would first need to add the value with /dealFields/{id} if it doesn’t exist yet.

When i created the field with dealfield endpoint i entered the name of the dropdown type enum and there options . when i search for all fields with the endpoint i get the dropdown name and its options id also.

so, can you please let me know how can i update the dropdown value of the current existing deal . what endpoint i should use to update the option of the particular deal on pipedrive and what response is to be sent.

Hey Chander,

I noticed on your request ’ https://api.pipedrive.com/v1//deals/3?api_token={token}’ that you’ve got 2 "/"s between v1 and deals.

Perhaps that’s your issue? Otherwise, the only thing I can think is that you’re not using the correct API key for that Field as I’ve tested with no issue.

Thanks now its working

1 Like