1.0.36 • Published 3 years ago

operata v1.0.36

Weekly downloads
8
License
ISC
Repository
-
Last release
3 years ago

Operata JS library integration

If you want your own branding or softphone features then you will need to host your own Amazon Connect Softphone (CPP) and add the Operata JS library as shown in the steps below:

1. Source the Amazon Connect softphone, host it in your environment and test.

2. Once this is working, add the operata.js (or import operata) to softphone page, as below:

Loading the JS library

Load the Operata JS script in the <head> of your application

<script src="https://static.operata.io/operata.js"></script>

or use our npm package (if you are using a javascript bundler like webpack or parcel)

Installation

npm i operata

Load library

import {Operata} from 'operata';

3. Initialise the AWS softphone with the reference set to your Amazon connect instance.

<script>
const softphoneDiv = document.getElementById('softphone');
const yourCCPPage = '<ccp url>';
const softphoneParams = { 
    "ccpUrl": yourCCPPage, 
    "loginPopup": true, 
    "softphone": { "allowFramedSoftphone": false } 
};
connect.core.initCCP(softphoneDiv, softphoneParams);
connect.core.initSoftphoneManager({ allowFramedSoftphone: true });
</script>      

4. Configure Operata options to your group instance and add the script tag contents at the bottom of the <body> tag in your softphone deployment.

<script>
const operataOptions = {
    awsCCPUrl: '<Your CCP URL>',
    operataGroupID: '<Your Operata Group ID',
    operataGroupSecret: '<Your Operata Group Secret>',
    loadSoftphone: false, // This is optional. Enable a softphone here <defaults to false>. Skip step 3 if you set this options to true. 
};

Operata(operataOptions).then(() => {
    //execute anything after operata has been initialised.
}).catch((err) => {
    //handle operata initialisation error.
});
</script>

5. Use your AWS console to allow https://softphone.operata.io to Integrate with your Amazon Connect instance, the Operata Help Centre has details.

Testing

To test stats collection, make a call from your Amazon Connect softphone and you will see the statistics updated every 10 seconds.

If you see 'Welcome to Operata Agent Assist' when you select the Operata Icon, then this is working.

If you have any issues then email us at help@operata.com

Browser Support

Current browser support is limited to

Desktop

  • Chrome: Latest

API

Initialisation Options

optionoptionaldefaultdescription
awsCCPUrlfalsenonethe required CCP URL is defined in your connect instance on AWS
operataGroupIDfalsenonethe required groupID field defined by Operata in your account
operataGroupSecretfalsenonethe required security token issued for you Operata group
loadSoftphonetruefalseenables a integrated softphone by simply setting a flag to true
loadAgentMessengertruefalseenables Operata Agent Messenger widget
locationtrue''set the location of this softphone. this can be used for filtering of data
ccpLogCollectiontruenoneenables CCP log collection. Can be one of: "TRACE", "DEBUG", "INFO", "LOG", "WARN", "ERROR", "CRITICAL"

Agent Issue Reporting

You can send an Agent reported issue via Operata stats collector API. This is done by sending an event on the Operata eventBus. Here is an example:

    // Obtain a reference to the eventBus when Operata stats collection is initialised.
    let eventBus = null;
    Operata(operataOptions).then((eb) => {
        console.log("Loaded Operata Softphone");
        eventBus = eb;
    }).catch((err) => {
        console.error(err);
    });

    // ....
    // Send the issue via the eventBus
    eventBus.emit("agent-reported-issue", 'Missed call, Softphone did not ring', 'Default',
             {extraField: 'Some optional data'}, function(sent){
        if (sent){
            alert('Issue submitted.');
        }else{
            alert('An error occurred while submitting the issue.');
        }
    });

eventBus.emit method accepts following arguments

ArgumentMandatoryDescription
eventNameyesPlease use "agent-reported-issue" for Agent issue reporting.
causeyesCause of the issue. Customer defined.
severitynoSeverity of the issue. Customer defined.
extranoAn object of extra data. Customer defined.
callbacknoA callback method. This is called once the issue is submitted.

Operata associates Agent reported issues with the callContactId using the following rules: 1. Issue reported before taking the first call after going offline - associate with no callContactId 2. Issue reported before taking the next call - associate with the last callContactId 3. Issue reported while on a call - associate with the current callContactId 4. Issue reported after taking a call - associate with the last callContactId

Recommended Versions of Amazon Connect Libraries

The versions below have been tested with the Operata library and are recommended.

CCPconnect-streamsconnect-rtc
v21.5.11.1.7

Built With

Authors

  • Operata Dev Team - Initial work - Operata
1.0.36

3 years ago

1.0.35

3 years ago

1.0.34

3 years ago

1.0.33

3 years ago

1.0.32

3 years ago

1.0.31

4 years ago

1.0.30

4 years ago

1.0.29

4 years ago

1.0.28

4 years ago

1.0.27

5 years ago

1.0.26

5 years ago

1.0.25

5 years ago

1.0.24

5 years ago

1.0.23

5 years ago

1.0.22

5 years ago

1.0.21

5 years ago

1.0.20

5 years ago

1.0.19

5 years ago

1.0.18

5 years ago

1.0.17

5 years ago

1.0.16

5 years ago

1.0.5

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago