HubSpot / hubspot-api-php

HubSpot API PHP Client Libraries for V3 version of the API

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Create or update a group of contacts

AhmedAliGad opened this issue · comments

I need to Create or update a group of contacts
any documentation help me

Hi @AhmedAliGad .
You can use $client->crm()->contacts()->batchApi() for CRUD operations with group of contacts.
Create a group of contacts: $apiResponse = $client->crm()->contacts()->batchApi()->create().
Create a group of contacts: $apiResponse = $client->crm()->contacts()->batchApi()->update().
Link to docs for these methods.

I need to update the contact data if the contact email exists
or create the contact data if not exists

Currently Hubspot doesn't support method which could do it.
You can check if contacts exist and that update or create them.