APIs & Integrations

basklomp
メンバー

API import: 409 error with existing contacts

解決

Hi,

Together with one of our partners, we set up an API integration to batch upload new contacts. Unfortunately we've been getting errors for all existing contacts. How can the existing contact be updated (by for instance logging the new interaction?

Details of error message
The error & message that they're seeing, is: error integrating with HubSpot. Message: Status code: 409 - {"status":"error","message":"Contact already exists","correlationId":"3dd6ce62-a0a4-4a3c-8e9f-170d71bee51a","identityProfile":{"vid":6182263,"identity" .....

We are using http://convertrmedia.com/ for the sync.

Best,
Bas

0 いいね!
1件の承認済みベストアンサー
danaketh
解決策
参加者

API import: 409 error with existing contacts

解決

You can update the contact by using the right endpoint. In your case, it might be easier to update contacts based on their e-mail address: https://developers.hubspot.com/docs/methods/contacts/update_contact-by-email

I'd probably implement this as a response to the error you get, so when a request to create new user is sent and the response is 409, it will run the update. There is a way to check for the contact first but that adds on more request to the logic.

元の投稿で解決策を見る

1件の返信
danaketh
解決策
参加者

API import: 409 error with existing contacts

解決

You can update the contact by using the right endpoint. In your case, it might be easier to update contacts based on their e-mail address: https://developers.hubspot.com/docs/methods/contacts/update_contact-by-email

I'd probably implement this as a response to the error you get, so when a request to create new user is sent and the response is 409, it will run the update. There is a way to check for the contact first but that adds on more request to the logic.