APIs & Integrations

JReichenberger
Participant

Connect to Five9 iFrame URL in HubSpot Calling SDK

Hello! I'm trying to connect the Five9 IVR call agent with HubSpot's Calling SDK through an  iframe. Five9 has created an iframe url to for embedding their calling agent into a webpage (the Five9 link and its documentation: https://app.five9.com/dev/sdk/crm/latest/doc/tutorial-basicintegration.html) However, when trying to connect to HubSpot with Postman on this call: {{hostUrl}} /crm/v3/extensions/calling/:appId/setting?=(my hapikey). I have made successful connections through postman before on creating custom cards with the same Five9 iframe url, which is why I'm surprised it wouldn't work with the calling sdk? Below is a picture of the error: The module shows up, but the app won't connect to the iframe url. Does anyone understand why this is happening?

 

issue.PNG

0 Upvotes
8 Replies 8
dennisedson
HubSpot Product Team
HubSpot Product Team

Connect to Five9 iFrame URL in HubSpot Calling SDK

@JReichenberger , looking at this again, I see that the endpoints do require the developer api key, is that the key that you added into your call?

So it is a little confusing.  You will want your app to oauth with a portal and then when it makes it call on your server, you will use developer hapikey. Hope that helps!

0 Upvotes
MichaelC
Guide | Partner
Guide | Partner

Connect to Five9 iFrame URL in HubSpot Calling SDK

So the answe is:

If you need to use an APP ID (see url in this case) you can not authenticate via "hapi key". You need to use token via oauth in the request header. 

 

Please note that the hapi key and the oauth token are not the same. More info in how to aquire an oauth token and how that works in general can be found here: https://developers.hubspot.com/docs/api/working-with-oauth



Need further help with integrations or business development?



Want to help me?

Go to the following links and read through the ideas. If you like them - give the idea an upvote

Upvote the following ideas:

MichaelC
Guide | Partner
Guide | Partner

Connect to Five9 iFrame URL in HubSpot Calling SDK

Javascript has never been one of my strong sides @dennisedson .

 

But I get a bit confused by the URL used. You use both API Key as well as an APP ID. Correct me if Im wrong here Dennis but in order to connect with a developed app in HubSpot you need to do so through OAuth. When using OAuth you dont use the API Key - instead you use the token in the header of the post. To me it seemes strange to have both an app token and a hapitoken. I might be off here - im only using the hapikey myself for now - but I think I got a big picture there - but please dubblecheck my facts here Dennis. 



Need further help with integrations or business development?



Want to help me?

Go to the following links and read through the ideas. If you like them - give the idea an upvote

Upvote the following ideas:

dennisedson
HubSpot Product Team
HubSpot Product Team

Connect to Five9 iFrame URL in HubSpot Calling SDK

You are correct that the only way an app can connect with a portal is via an oauth connection.

JReichenberger
Participant

Connect to Five9 iFrame URL in HubSpot Calling SDK

Thank you @dennisedson  and @MichaelCfor all of the responses,

 

I was originally following HubSpot's Calling SDK postman collection:

JReichenberger_0-1623686670859.png

That looks like this:

JReichenberger_1-1623686738720.png

I tried connecting with oauth connection in Postman to the /crm/v3/extensions/calling url (I have successfully connected with oauth before in posting a custom card). And it actually produces the same result for me. Either way, the the name of the new module shows up:

JReichenberger_2-1623687625093.png

But it will not load, it just times out. What specifically would you recommend for changing my authentication technique?

0 Upvotes
dennisedson
HubSpot Product Team
HubSpot Product Team

Connect to Five9 iFrame URL in HubSpot Calling SDK

@JReichenberger ,

Are you seeing any errors in the console? 

@himanshurauthan , any thoughts on this one?

0 Upvotes
JReichenberger
Participant

Connect to Five9 iFrame URL in HubSpot Calling SDK

Thanks for replying Dennis,

I checked the console and there is a 404 error - but I am still not sure why?

 

404 Error404 ErrorThe Error is connected to this line in the codeThe Error is connected to this line in the code

I'm still new to JavaScript so anything helps!

dennisedson
HubSpot Product Team
HubSpot Product Team

Connect to Five9 iFrame URL in HubSpot Calling SDK

@MichaelC , is this in your wheelhouse?

0 Upvotes