Customer's phone on top_bar location
How do I get customer's phone number on my app's top_bar, as soon as agent visits the User-page or ticket-page?
I am building a app, that will have call functionality,
So as soon as agent will visit the user profile page, I want to get user's phone number from there and put in on a dialer, which will be on top_bar location of my app
Hi Kumar! I'm surprised that there wasn't an easier method to get this information, but after research and talking with my team, it looks like the easiest way to get this is with the user identity object. Since it doesn't return a simple response, you'd need to iterate through the returned identities and probably look for the phone number that returns a `"primary": true` attribute and grab the number from there. I know it's not the easiest way to get this, but it will get you moving in the right direction!
If you are building a telephony app check out our Talk Partner Edition API. There are a couple of useful endpoints there to screen pop tickets and users and create voicemail tickets. One, that you might be interested in allows you to capture the event that is triggered every time someone clicks on a phone number on the agent workspace, so you can pop your own app to the user.
I have found a way around it.