@exotel-npm-dev/webrtc-client-sdk 1.0.19 → 1.0.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Changelog +6 -0
- package/dist/exotelsdk.js +19 -7
- package/dist/exotelsdk.js.map +1 -1
- package/package.json +2 -2
- package/src/listeners/ExWebClient.js +10 -3
package/Changelog
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
Change Log
|
|
2
2
|
|
|
3
|
+
## v1.0.21 05 March, 2025
|
|
4
|
+
-[VST-954] Added custom sip codes and reason phrase for when agent are disconnecting and sdk is disconnecting call
|
|
5
|
+
|
|
6
|
+
## v1.0.20 28 January, 2025
|
|
7
|
+
-[VST-940] Added checks for X-Exotel-Callsid, Call-ID, and LegSid headers in onRecieveInvite.
|
|
8
|
+
|
|
3
9
|
## v1.0.19 09 January, 2025
|
|
4
10
|
-[VST-865] Added option in websdk to select the codec preference
|
|
5
11
|
|
package/dist/exotelsdk.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
*
|
|
3
|
-
* WebRTC CLient SIP version 1.0.
|
|
3
|
+
* WebRTC CLient SIP version 1.0.21
|
|
4
4
|
*
|
|
5
5
|
*/
|
|
6
6
|
(function webpackUniversalModuleDefinition(root, factory) {
|
|
@@ -21112,8 +21112,10 @@ function postInit(onInitDoneCallback) {
|
|
|
21112
21112
|
} else if (s.state == SIP.SessionState.Established) {
|
|
21113
21113
|
s.bye();
|
|
21114
21114
|
} else if (s.reject) {
|
|
21115
|
-
s.reject(
|
|
21116
|
-
|
|
21115
|
+
s.reject({
|
|
21116
|
+
statusCode: 486,
|
|
21117
|
+
reasonPhrase: "Busy"
|
|
21118
|
+
});
|
|
21117
21119
|
} else if (s.cancel) {
|
|
21118
21120
|
s.cancel();
|
|
21119
21121
|
}
|
|
@@ -21453,7 +21455,10 @@ function registerPhoneEventListeners() {
|
|
|
21453
21455
|
_webrtcSIPPhoneEventDelegate__WEBPACK_IMPORTED_MODULE_2__["default"].onRecieveInvite(incomingSession);
|
|
21454
21456
|
_webrtcSIPPhoneEventDelegate__WEBPACK_IMPORTED_MODULE_2__["default"].sendWebRTCEventsToFSM("i_new_call", "CALL");
|
|
21455
21457
|
} else {
|
|
21456
|
-
incomingSession.reject(
|
|
21458
|
+
incomingSession.reject({
|
|
21459
|
+
statusCode: 480,
|
|
21460
|
+
reasonPhrase: "4001"
|
|
21461
|
+
});
|
|
21457
21462
|
}
|
|
21458
21463
|
};
|
|
21459
21464
|
|
|
@@ -24070,11 +24075,18 @@ function ExDelegationHandler(exClient_) {
|
|
|
24070
24075
|
};
|
|
24071
24076
|
this.onRecieveInvite = function (incomingSession) {
|
|
24072
24077
|
logger.log("delegationHandler: onRecieveInvite\n");
|
|
24078
|
+
const obj = incomingSession.incomingInviteRequest.message.headers;
|
|
24073
24079
|
exClient.callFromNumber = incomingSession.incomingInviteRequest.message.from.displayName;
|
|
24074
|
-
|
|
24075
|
-
|
|
24080
|
+
if (obj.hasOwnProperty("X-Exotel-Callsid")) {
|
|
24081
|
+
_api_callAPI_CallDetails__WEBPACK_IMPORTED_MODULE_9__.CallDetails.callSid = obj['X-Exotel-Callsid'][0].raw;
|
|
24082
|
+
}
|
|
24083
|
+
if (obj.hasOwnProperty("Call-ID")) {
|
|
24084
|
+
_api_callAPI_CallDetails__WEBPACK_IMPORTED_MODULE_9__.CallDetails.callId = obj['Call-ID'][0].raw;
|
|
24085
|
+
}
|
|
24086
|
+
if (obj.hasOwnProperty("LegSid")) {
|
|
24087
|
+
_api_callAPI_CallDetails__WEBPACK_IMPORTED_MODULE_9__.CallDetails.legSid = obj['LegSid'][0].raw;
|
|
24088
|
+
}
|
|
24076
24089
|
const result = {};
|
|
24077
|
-
const obj = incomingSession.incomingInviteRequest.message.headers;
|
|
24078
24090
|
for (let key in obj) {
|
|
24079
24091
|
if (obj.hasOwnProperty(key)) {
|
|
24080
24092
|
if (obj[key].length == 1) {
|