Partial Commit of Contacts Batch


#1

We’re using Hubspot API to push a list of contacts to Hubspot using below API endpoint –

https://api.hubapi.com/contacts/v1/contact/batch/

This end point accepts a batch not exceeding 1000 contacts, and pushes them all at once to Hubspot. According to the API documentation, If one record in the batch has issues, the whole batch is rejected and even the successful records are not committed to Hubspot.

Is there a way to enable the partial commit on Husbpot side(Valid contacts from the batch should be saved)? Perhaps by setting some property in the input JSON?


#2

Hey @jwalants, No that's not possible; if a contact in the batch is invalid, the whole batch fails. There's no property we can add to the JSON body to override this behavior. That said, the error message should have details about which contact(s) failed, so you can retry the batch without the invalid contact(s).