0

Is there any way that I could obtain Hubspot contact list size over time through the Hubspot API? I need the number of contacts in a list daily for last 30 day.

Engineero
  • 12,340
  • 5
  • 53
  • 75
Yog
  • 21
  • 3
  • Welcome to Stack Overflow! Please provide a minimal working example that illustrates your problem or it is unlikely that we will be able to help you. – Engineero Nov 06 '17 at 22:39

1 Answers1

0

There is no way that I know of to get the historical number of contacts through HubSpot API. However, what you can do is the following:

  • Create a script that gets the total number of contacts at the current moment. You can do this using the following code:

    https://api.hubapi.com/contacts/v1/contacts/statistics/?hapikey=your_api_key
    
  • Run the above script in a cron every night, and save its results in the database (along with the current day)

Hope this helps.

itoctopus
  • 4,133
  • 4
  • 32
  • 44