Recurring export to Google Spreadsheets

Hi all,

I’m working on a script enabling me to export data via the Hubspot API to a Google Spreadsheet. I’m having some issues with finding the right variablenames.

This is (part of) the JS script I have so far:


Jsscript

This returns the following output. I have the following questions:

- Why are all ownerid’s, teamid’s, and connected_to_partner (custom property) not returning the right values?

- How can I make the close date a real date value?


Google Spreadsheets

Hey @jpdt,

Let’s walk through your question one by one:

1. I believe the reson why the Owner ID, Team ID and Connected to partner properties are returning unknown because the internal value of the properties are as follows:

hubspot_owner_id, hubspot_team_id, connected_to_partner.

Based on your code, it looks like you’re missing the “_” for these properties.

2. When looking to convert unix milliseconds timestamp to date time, you can use the following formula:

=(A3/86400/1000)+25569

where A3 is the cell that contain the timestamp.

I referenced this stackoverflow.

@WendyGoh thank you very much :slightly_smiling_face: