Regular Contributor

Hi friends,


We're setting up a private connection for our app to chat with Hubspot. The issue is that we're trying to create timeline events regarding what a customer is doing in our app in their hubspot profile.


So, the live user (the customer) wouldn't be able to authorize the connection.


To do this, we authorized our private hubspot dev app in our account and were using the code to do refreshes every 6 hours (per docs) so that we could run the call without the user being shown an error message due to missing authorization.


The only issue is, the call back code we got from running the initial hubspot app auth process.


We tried using that code; however, it seems to only be good for one use?


How can we do it where we get a code that'll last, we need to be able to run authorization without the interaction of a human.


Please let me know how we can do this! Thanks in advance and apologies for the non-technical explanation (I am a marketer trying to be a developer, haha).

1 Reply 1
Community Manager

Hi @chriscardone,


I hope all is well with you Smiley Happy


No worries at all, let me break it down here for you:


When initiating the integration for the first time, the code query parameter will be appended to the URL and we will use this code to get an access token and refresh token. 

You will only have to use the code once and thereafter it's about using the refresh token and access token.


Hope this helps to clarify further and do let me know if there's any further queries here. Happy to help!