Get req API google script

Hi there,

Please don’t refer me to zapiar. (or any other tool like it for that matter)

I have 2 questions -

1. I want to get a costume property through my call. this is the property >>linkedin_profile

what should I add to the link so I’ll get this data? (this is the link -

“https://api.hubapi.com/contacts/v1/lists/all/contacts/all?hapikey=” + API_KEY

2. Did anybody already wrote something to parse this data to specific columns (using google app script) and don’t mind sharing?

)

@EShumely ,

adding &property=hs_linkedinid to the end of your call will return the LinkedIn ID.

I have not attempted to write something to send to a google sheet, though

Hi Dennis,

Thank you for your answer. my costume property is called “linkedin_profile”. it stored the linkedin profile URL of my contact. when I add this to my &property=linkedin_profile it doesn’t return the property. am I missing something?

@EShumely ,

The property will only be returned on records where there is a value for that property. Can you confirm with a contact record that has a value populated in that property?

I’ll check tomorrow to confirm when we get back to work but all of the contacts should have this value. just to double-check. this is what I added - > &property=linkedin_profile maybe I should have added something else? like this - > &property=hs_linkedin_profile the only reason I’m asking this is that I looked at your example, I’m not familiar with the property you mentioned so I don’t know if this → hs_ is what you add to the parameter to get the data

If you created the custom property, then you should use what you have (assuming the internal name of the property is consistent with that)

You can dm me the portal if you want and I can take a closer look.

Thanks, I can see it now. I didn’t find a way to parse this data so I can get the values that I want. the app script uses js any chance you have an example code to push the property values to an array? for v1/ response (I found an example online for v3 for a different get req but it doesn’t work for v1)

nm found this - https://medium.com/@alexisbedoret/how-to-retrieve-your-contacts-from-hubspot-in-google-spreadsheet-using-app-script-f8cb4a827826

hope it will help other ppl as well