cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
370
Views
0
Helpful
0
Replies

Event Notification Subscription

bsukumaran
Level 1
Level 1

Hello All,
We are trying to subscribe Finesse events into our independent web application, which is hosted outside of Cisco. The goal is to notify and display any server events, such as state or status changes, on our web application. Client Single Sign-On (SSO) is used for logging into the web application. The Cisco sandbox (XXXX.wx028.webexcce.com) is configured for standard call control, which we manage using the Finesse API. We have configured the Cisco certificate, We were unsuccessful in subscribing to the event Please help.

Below are the approach tried
Approach 1 using Strophe.JS :
BOSH_SERVICE = 'wss://XXXX.wx028.webexcce.com:8445/ws';
this.con = new Strophe.Strophe.Connection(this.BOSH_SERVICE);
this.con.connect('<<What could be the value for user>>', '', this.onConnect.bind(this));

Getting below error
WebSocket connection to 'wss://XXXX.wx028.webexcce.com:8445/ws' failed:

Websocket error {"isTrusted":true} Zone - WebSocket.addEventListener:error

Websocket closed unexcectedly

Approach 2 using XMPP
Below is the code snipper and always going to "client.on('offline', ()"

const jid = '<webex extension>@XXXX.wx028.webexcce.com' //NOT Sure what values to provide
const password = ''// Since we are using SSO we can't pass password
const xmppServer = 'XXXX.wx028.webexcce.com'; // what could be the correct XMPP server address
const port = 5223 // what could be the port

const client = new Client({
jid: jid, password: password, host: xmppServer, port: port,
tls: true // true if using TLS
});

client.on('online', (data) => {
console.log('Connected as:', data.jid.toString());
client.send(new xmpp.Element('presence', { type: 'available' })
.c('show').t('chat')
.up().c('status').t('Available'));
});

client.on('offline', () => {
console.log('Disconnected from the server');
});

0 Replies 0