Backend server using webrtc sdk

Hi, I need to develop callbot functions on my backend server program developed with Go on linux.

Questions :

  1. Is it possible to develop webrtc agent on backend linux server (not web browser) with genesys webrtc sdk?

  2. If 1 is possible, is it possible to use webrtc sdk (typescript library) on my Go server?

  3. Are there any other genesys webrtc sdk developed with another languages such as Go or Python?

Thanks.

@Queen25 no it is not really possible. The sdk was designed to work against Genesys' servers and there are a lot of assumptions made based on our implementation. This is our only sdk and it was written in typescript because we needed something that would transpile easily for browsers.

Webrtc implementations are not really portable. There are a lot of pieces that are composable with open source libraries but there's a pretty good chance you're going to be writing or customize quite a bit of code.

Thanks for your answer. I see about that.

In the appfoundry, there are some callbots on linux server working outside genesys cloud. They might use genesys cloud api/sdk for call handling and rtp media. And they might not use bot connector for their callbot because bot connector only supports messaging as I know from genesys documents.

Is there any genesys cloud api/sdk for rtp media except webrtc sdk? Can I make callbot on 3rd-party linux server with genesys cloud platform api/sdk or others which can handle rtp media? If not, do I have to handle rtp media on my own without genesys api/sdk?

Thanks.

Hello,

Currently, the approach to integrate a voice bot with Genesys Cloud (that needs to get access to the audio) is to transfer the call to the bot via SIP (using a BYOC Cloud SIP Trunk).
You need to have a SIP capable device that can manage the incoming call - over public internet (SIP end-to-end) so that you can receive necessary headers like User-to-User information (UUI) or the x-inin-cnv (that carries the Genesys Cloud Conversation ID), and trigger a transfer back to Genesys Cloud if the bot requires to escalate to an ACD Queue/Contact Center Agent (using SIP REFER).
The following blog describes the necessary flow/configuration (from SIP perspective).

Regards,

Thanks.

As your blog, you suggested the way that a call incoming into genesys cloud should be transferred to external device using BYOC cloud SIP external trunking. I think the disadvantage to use the way is that the transferred call would not be tracked with the conversation in the genesys cloud and also the media would not be recorded because media channel will be opened directly between caller and voicebot.

I would like to track the call between caller and voice bot like the one between caller and normal agent device and record the voice media in genesys cloud would also be needed. Also I need to place my voice bot in genesys cloud queue like normal agent and distribute calls to my voice bot with genesys cloud ACD.

I'm wondering if it's possible to register my voicebot to genesys cloud using BYOC cloud sip trunking as normal agent device registers itself to genesys cloud with SIP REGISTER in the BYOC premise environment.

If it's not possible, assuming that I reestablish BYOC premise environment in my org, can genesys EDGE device in BYOC premise accept REGISTER message from my voicebot (which is not the managed device of genesys cloud) so that I can ACD, track and record calls?

Regards.

Hello,

"I think the disadvantage to use the way is that the transferred call would not be tracked with the conversation in the genesys cloud and also the media would not be recorded because media channel will be opened directly between caller and voicebot."
When a call is transferred to an external number, choosing to bridge the transfer via Genesys Cloud, the external number will be tracked in the Conversation Details as a participant (purpose=external with segment start time and end time).
Regarding recording, you can enable the "Continue on External Bridged Transfer" toggle at the Trunk configuration level (in your BYOC Cloud Trunk configuration - under Media - Recording section - Continue on External Bridged Transfer).

"Also I need to place my voice bot in genesys cloud queue like normal agent and distribute calls to my voice bot with genesys cloud ACD."
You would have to check that all the Platform API requests you need are available when using an OAuth Client Credentials Grant token (server context).
Several of the Platform API endpoints related to conversation handling are reserved to "user context" token (Token Implicit Grant, Authorization Code Grant, SAML2 Bearer Grant). Not all but several. Attempting to invoke such API request will result in a 400 or 403 response (need user credentials).

"I'm wondering if it's possible to register my voicebot to genesys cloud using BYOC cloud sip trunking as normal agent device registers itself to genesys cloud with SIP REGISTER in the BYOC premise environment."
No, it is not possible with BYOC Cloud.
BYOC Cloud does not support Unmanaged Phones (Generic SIP).
See Phone category comparison matrix and Managed phones: models and features matrix.

"can genesys EDGE device in BYOC premise accept REGISTER"
Yes, BYOC Premise (Edge on Premise) supports Unamanged Phones (Generic SIP).
What I don't know, as I don't have a Premise Edge in my environment (and a Generic SIP Phone), is what the platform will do when a second call is sent to the phone and is answered.
I mean that I don't know if the platform will automatically put the first call on hold or not.
You would have to try/test.

Regards,

Very Thanks for your answer!

Summing up,

If I would like my voicebot to work like normal agent device which can be placed in queue or distributed by ACD as well as tracking and recording calls, there would be 2 ways as below:

  1. In BYOC cloud environment, genesys cloud API/SDK must be used for call handling because unmanaged phone like my voicebot cannot register with genesys cloud via BYOC cloud SIP trunking. In using API/SDK, implicit or auth code grant should be used for authentication/authorization. In this case, my voicebot cannot use genesys cloud webrtc sdk for media handling because of the os/browser and language dependency so I'm wondering if it is possible that my voicebot can use platform api for call handling and another 3rd-party lib/sdk for webrtc media handling.

  2. In BYOC premise environment, genesys EDGE supports unamaged phone registration and call handling (some issues should be resolved as you said) so my voicebot with SIP capability can register with genesys EDGE and handle calls via SIP phone trunking. In this case my voice bot also must handle rtp media on my own.

If I would like my voicebot just to handle calls and media outside of the genesys cloud and don't need the features of normal agent device such as queueing or ACD, there would be also 2 ways below:

  1. In BYOC cloud environment, my voicebot could receive calls from genesys cloud via BYOC cloud sip trunking and transfer calls back to genesys cloud if needed. In this case my voicebot could be tracked in conversation by using UUI or x-inin-cnv.

  2. In BYOC premise environment, all would be same with BYOC cloud environment as 3.

Anything wrong?

Regards,

Hello,

I still don't think that trying to mimic an agent for this is a good idea. And I don't know if there is a chance it works. But I can't prevent you from trying.

"1. and 2."
a) You would be subject to agent capacity/utilization.
b) Depending on what Platform API requests your bot will need to manage the conversation/call, it is likely that you require a "user context" token (Implicit Grant, Authorization Code Grant, SAML2 Bearer Grant) as some of the call control API endpoints are reserved to a user-context token/credentials and will be rejected with a server-context token (Client Credentials Grant).
c) As I explained, I don't know how the platform will manage multiple calls to the same "agent phone". I mean if the Genesys Cloud platform will allow all calls to be active or if it will keep one of them active and will force the other to hold.

"1."
It is not about switching to another sdk for webrtc handling. WebRTC does not cover everything like the session management part.
What the Genesys Cloud WebRTC SDK do is not documented (at protocol/messaging level).
So if you find another sdk that manages webrtc, you would still need to adapt it so that it fits into the expected Genesys Cloud model. I can't say what would be needed - the Genesys Cloud WebRTC SDK is not publicly documented (in details).

"2."
Yes, BYOC Premise/Edges on Premise allow a Generic SIP Phone to register.
You'll still need to mimic what a Genesys Desktop would do when a user logs in and make himself available with a specific phone (Platform API).

"3. and 4."
Yes/correct.

Regards,

This topic was automatically closed after 30 days. New replies are no longer allowed.