# Batch Upsert API error

**URL:** <https://community.hubspot.com/t/batch-upsert-api-error/122213>\
**Category:** APIs & Integrations\
**Tags:** php\
**Created:** [December 10, 2024, 11:05am UTC](https://community.hubspot.com/t/batch-upsert-api-error/122213 "2024-12-10T11:05:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![TTeks](https://avatars.discourse-cdn.com/v4/letter/t/aca169/32.png) [@TTeks](https://community.hubspot.com/u/TTeks)\
**Post date:** [December 10, 2024, 11:05am UTC](https://community.hubspot.com/t/batch-upsert-api-error/122213/1 "2024-12-10T11:05:51Z")

</div>

I am using [https://api.hubapi.com/crm/v3/objects/contacts/batch/upsert](https://api.hubapi.com/crm/v3/objects/contacts/batch/upsert) api to insert/update data to Hubspot.  
Request Body be like this  
{  
“inputs”: [  
{  
“id”: “[isabella@futureconnect.com](mailto:isabella@futureconnect.com)”,  
“idProperty”: “email”,  
“properties”: {  
“interest”: “EventNetworking, ProfessionalDevelopment”,  
“hs\_lead\_status”: “NEW”,  
“country”: “Algeria”,  
“firstname”: “Isabella”,  
“lastname”: “Andersonvv”,  
“email”: “[isabella@futureconnect.com](mailto:isabella@futureconnect.com)”  
}  
},  
{  
“id”: “[appstore@apple.com](mailto:appstore@apple.com)”,  
“idProperty”: “email”,  
“properties”: {  
“bio”: “Algeria”,  
“company”: “Algeria”,  
“seniority”: “Algeria”,  
“phone”: “Algeria”,  
“date\_of\_birth”: “Algeria”,  
“hs\_facebook\_click\_id”: “Algeria”,  
“twitterhandle”: “Algeria”,  
“hs\_linkedin\_url”: “Algeria”,  
“instagram”: “Algeria”,  
“hs\_whatsapp\_phone\_number”: “Algeria”,  
“text”: “Algeria”,  
“number\_input”: “Algeria”,  
“multi\_line\_input”: “Algeria”,  
“firstname”: “Don’t”,  
“lastname”: “Delete”,  
“email”: “[appstore@apple.com](mailto:appstore@apple.com)”  
}  
},  
{  
“id”: “dipika.kundu@teks.co.in”,  
“idProperty”: “email”,  
“properties”: {  
“interest”: “EventNetworking, IdeasThatShapeOurWorld”,  
“firstname”: “Cepheid”,  
“lastname”: “fdef”,  
“email”: “dipika.kundu@teks.co.in”  
}  
},  
{  
“id”: “vinay.kumar@teks.co.in”,  
“idProperty”: “email”,  
“properties”: {  
“interest”: “EventNetworking, NetworkingOpportunity, KnowledgeExchange”,  
“hs\_lead\_status”: “NEW”,  
“country”: “Afghanistan”,  
“firstname”: “Vinay Kumar”,  
“lastname”: “Pathak”,  
“email”: “vinay.kumar@teks.co.in”  
}  
},  
{  
“id”: “[k@n.com](mailto:k@n.com)”,  
“idProperty”: “email”,  
“properties”: {  
“bio”: “Afghanistan”,  
“company”: “Afghanistan”,  
“seniority”: “Afghanistan”,  
“phone”: “Afghanistan”,  
“date\_of\_birth”: “Afghanistan”,  
“interest”: “NetworkingOpportunity, KnowledgeExchange, IdeasThatShapeOurWorld”,  
“hs\_facebook\_click\_id”: “Afghanistan”,  
“twitterhandle”: “Afghanistan”,  
“hs\_linkedin\_url”: “Afghanistan”,  
“instagram”: “Afghanistan”,  
“hs\_whatsapp\_phone\_number”: “Afghanistan”,  
“text”: “Afghanistan”,  
“number\_input”: “Afghanistan”,  
“multi\_line\_input”: “Afghanistan”,  
“firstname”: “kyle”,  
“lastname”: “nick”,  
“email”: “[k@n.com](mailto:k@n.com)”  
}  
},  
{  
“id”: “[dk@test.com](mailto:dk@test.com)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “Dk”,  
“lastname”: “test”,  
“email”: “[dk@test.com](mailto:dk@test.com)”  
}  
},  
{  
“id”: “[s@s.com](mailto:s@s.com)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “spon”,  
“lastname”: “1”,  
“email”: “[s@s.com](mailto:s@s.com)”  
}  
},  
{  
“id”: “[a1@a.io](mailto:a1@a.io)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “Exbit”,  
“lastname”: “1”,  
“email”: “[a1@a.io](mailto:a1@a.io)”  
}  
},  
{  
“id”: “[a3@a.io](mailto:a3@a.io)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “A”,  
“lastname”: “3”,  
“email”: “[a3@a.io](mailto:a3@a.io)”  
}  
},  
{  
“id”: “[a5@a.io](mailto:a5@a.io)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “A”,  
“lastname”: “5”,  
“email”: “[a5@a.io](mailto:a5@a.io)”,  
“interest”: “KnowledgeExchange”  
}  
},  
{  
“id”: “[k@k.com](mailto:k@k.com)”,  
“idProperty”: “email”,  
“properties”: {  
“interest”: “EventNetworking, KnowledgeExchange, IdeasThatShapeOurWorld, InspiringLeaders”,  
“firstname”: “Test”,  
“lastname”: “Test”,  
“email”: “[k@k.com](mailto:k@k.com)”  
}  
},  
{  
“id”: “[new@test.com](mailto:new@test.com)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “dffd”,  
“lastname”: “hghg”,  
“email”: “[new@test.com](mailto:new@test.com)”,  
“interest”: “EventNetworking, KnowledgeExchange, ProfessionalDevelopment”  
}  
},  
{  
“id”: “[app@test.com](mailto:app@test.com)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “app”,  
“lastname”: “test”,  
“email”: “[app@test.com](mailto:app@test.com)”  
}  
},  
{  
“id”: “[web@test.com](mailto:web@test.com)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “web”,  
“lastname”: “test”,  
“email”: “[web@test.com](mailto:web@test.com)”  
}  
},  
{  
“id”: “[teks.teks2nd@gmail.com](mailto:teks.teks2nd@gmail.com)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “Teks”,  
“lastname”: “Teks2nd”,  
“email”: “[teks.teks2nd@gmail.com](mailto:teks.teks2nd@gmail.com)”,  
“interest”: “NetworkingOpportunity, IdeasThatShapeOurWorld”  
}  
},  
{  
“id”: “[db@eventify.io](mailto:db@eventify.io)”,  
“idProperty”: “email”,  
“properties”: {  
“interest”: “EventNetworking, NetworkingOpportunity, KnowledgeExchange, IndustryInsights, ProfessionalDevelopment”,  
“checkbox”: [  
“C2”,  
“C3”  
],  
“hs\_lead\_status”: “OPEN”,  
“country”: “Albania”,  
“firstname”: “B”,  
“lastname”: “Dips”,  
“email”: “[db@eventify.io](mailto:db@eventify.io)”  
}  
},  
{  
“id”: “[dkspk@test.com](mailto:dkspk@test.com)”,  
“idProperty”: “email”,  
“properties”: {  
“firstname”: “Dipikaspk”,  
“lastname”: “Dipikaspk”,  
“email”: “[dkspk@test.com](mailto:dkspk@test.com)”  
}  
},  
{  
“id”: “[new@at.com](mailto:new@at.com)”,  
“idProperty”: “email”,  
“properties”: {  
“bio”: “Albania”,  
“company”: “Albania”,  
“seniority”: “Albania”,  
“phone”: “Albania”,  
“date\_of\_birth”: “Albania”,  
“hs\_facebook\_click\_id”: “Albania”,  
“twitterhandle”: “Albania”,  
“hs\_linkedin\_url”: “Albania”,  
“instagram”: “Albania”,  
“hs\_whatsapp\_phone\_number”: “Albania”,  
“text”: “Albania”,  
“number\_input”: “Albania”,  
“multi\_line\_input”: “Albania”,  
“firstname”: “new”,  
“lastname”: “Attendee”,  
“email”: “[new@at.com](mailto:new@at.com)”  
}  
}  
]  
}  
I am getting error like  
{  
“status”: “error”,  
“message”: “Invalid input JSON on line 1, column 3301: Cannot deserialize value of type `java.lang.String` from Array value (token `JsonToken.START_ARRAY`)”,  
“correlationId”: “ace72d1f-79cd-4bb9-aab7-79a654c05178”  
}  
Can somebody please please help on this?

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [December 10, 2024, 6:07pm UTC](https://community.hubspot.com/t/batch-upsert-api-error/122213/2 "2024-12-10T18:07:34Z")

</div>

Hey, @TTeks 👋 It’s helpful for our community members if you include an example request that returns this error. It’s difficult to give an educated guess or definitive answer without more details.

Thanks! — Jaycee
