Skip to main content

We are unable to monitor a call using supervise api after JWT migration. Its working fine with password grand type authorization.
We could see subscription api's providing 200 response.

SubscriptionApi(Returning 200 response)

rc.restapi().subscription().list();


Team, Could you please let us know why call monitoring is not working in JWT flow?
Code(Java) :

rc = new RestClient(RINGCENTRAL_CLIENTID, RINGCENTRAL_CLIENTSECRET, RINGCENTRAL_SERVER);

rc.authorize(RINGCENTRAL_JWT);

superviseRequestAgent.agentExtensionId(extensionid);

superviseRequestAgent.supervisorDeviceId(sipdeviceid);

superviseRequestAgent.mode("Listen");

resultAgent = rc.restapi().account().telephony().sessions(telephonysessionId).parties(callparty).supervise().post(superviseRequestAgent);


We are getting below error

{

"errors" : [

{

"errorCode" : "TAS-120",

"message" : "Can't find registered deviceId for current user"

}

]

}


HTTP Request

============

HTTP POST https://platform.ringcentral.com/restapi/v1.0/account/~/telephony/sessions/s-a0d7966184bb3z18df39ea87az13b97230000/parties/p-a0d7966184bb3z18df39ea87az13b97230000-1/supervise


Authorization: ?? <-- (Why its showing ? mark in authorization)

X-User-Agent: RC-JAVA-SDK Java 1.8.0_382 Linux


Created JWT Token for prod and gave access to the particular application.

Make sure that you generate the JWT token for the right supervisor who owns the device. Simply login the RingCentral developer portal using the supervisor's username and password (the one you used before to authenticate the app) and generate the JWT token for that supervise.


Thank you @Phong Vu .
But we have total 14 sip phones for supervise calls in production. I don't have admin rights and don't know the credentials to login to the developers portal using that phone username and password.

Under organization tab , i could see supervise phone email's are not showing in part of Developer list.

so I have tried to login developer portal with rc username ,extension and rc password which is for one of the supervise phone we are using, But its redirecting us to password reset page.

Could you please let us know how can we generate JWT for each supervise phones.

Do we need to create JWT for all 14 phones in developer portal?


Unfortunately I don't know your group monitoring setup. But here are the fundamentals

- A call monitoring group can have multiple supervisors and multiple monitored agents

- A call supervisor is a user extension and a user extension can have multiple devices (phones). And a user extension must have its own login credentials (username/password). And a user extension can login the RingCentral developers portal to generate JWT for itself.

If those 14 SIP phones belong to a supervisor, then you need to generate just ONE JWT token to authenticate your app.

If those 14 SIP phones belong to 14 different supervisors, then of course each of the supervisors needs to generate its own JWT tokens. Thus, you need 14 JWT tokens. Each JWT token can be used to authenticate your app and can supervise calls on the SIP device which belongs to that supervisor.


Reply