A Guide to Integrating LivServ Chat with HubSpot

Recently, Znbound had a chance to assist the 1st ever integration of HubSpot with Livserv (a chat service that provides an agent as well, mostly operating in India). Thanks to our customers, we keep getting challenges and we love them.

This integration was for one of our most prestigious clients – International City, Sobha Ltd. International City is using Livserv chat services since a long time. The website visitors who became leads via the online chat were sent to Team at Sobha International City via email.

A few months ago, International City moved to HubSpot to manage their online marketing and sales activities. They started using HubSpot platform to capture leads. The leads who would come by filling forms created in HubSpot were directly entered into the system, but the ones captured by the chat system were still following the old route. It was time to integrate the Livserv chat system and HubSpot.

The Integration was not simple. We faced issues at each and every step, but we researched, retried and completed the integration successfully. Today, the leads from Livserv chat are directly updated in HubSpot using the API along with a full chat history. Our sincere thanks to Livserv team. Now we know Livserv and HubSpot integration is possible.

Here are the steps we followed:

Create an App within HubSpotThe first and foremost step is to create an App in HubSpot. The HubSpot developers documentation is available here

When an App is created in HubSpot, here are the four ids / Keys that are generated

  1. App ID
  2. Client ID
  3. Client Secret
  4. HubSpot API Key

All those are confidential information, so can’t be published here.


A “Contacts API” needs to be used to integrate LiveChat responses in HubSpot. The detailed documentation of this API is available here In order to create or update a contact in HubSpot, a “Contact JSON” needs to be passed along with the API link.

A sample JSON that needs to carry contacts information is available at the linkAnd a sample API URL to which contacts data needs to be POSTED is here. There are 2 required parameters which are

  • HubSpot API Key and
  • Contact JSON

HubSpot API Guidelines

There are certain limits by which a single integration can consume the HubSpot Public APIs.

For eg:,

Integrations cannot consume the HubSpot API at a rate greater than 10 requests/second. If your integration is doing so, you may get Timeout errors.

Refer HubSpot API Guidelines before starting integration

Integration Testing

HubSpot provides a test portal which is available freely to try out all developments. The integration can be tested in the HubSpot test portal for which the login details are provided.

Success HubSpot Responses

  • Incase of new leads, If successful, the request will return the unique identifier (VID) of the contact and whether or not the request was a create or an update. For eg. {“vid”:xxxxx,”isNew”:true}
  • Incase of repeat leads, If successful, the request will return the unique identifier (VID) of the contact and whether or not the request was a create or an update. For eg. {“vid”:xxxxx,”isNew”:false}

Common Errors and Resolution

And finally, as expected, we faced errors and here they are:

  1. java.io.IOException: Server returned HTTP response code: 400 for URL – The most common error received when API URL has a syntax or a logical error. Look at your API Link to figure out possible issues and try again.
  2. “error”:”PROPERTY_DOESNT_EXIST” – This is another common error that occurs when API is trying to update a property which doesn’t exist in the portal. So, make sure that all the properties that need to be updated have been created in the portal beforehand.
  3. java.net.ConnectException: Connection timed out – If you’re using the batch create/update endpoint, it may timeout if you’re sending more than 100 contact records in a single request, or if you’re trying to populate hundreds of properties per contact for a large number of contacts.  If you’re seeing consistent timeouts, you may need to lower your batch size.
  4. You may also run into timeouts if you’re making a large number of requests in a short period of time (near the 10 requests per second rate limit).  Usually these timeouts will be temporary, and the request will usually succeed if you wait for a few seconds and then retry.

Finally, after all these attempts and hurdles, we had a successful integration. International City Contacts are now flowing from LivServ instantly to HubSpot. Znbound thanks LivServ team for all their support and hard work.

Next is Livserv and LeadSquared integration ….and Team Znbound is excited for this new challenge. Let’s go!

Team Znbound
Table of Contents