Skip to content

Commit

Permalink
Updating api.js, documentation, and build files (#704)
Browse files Browse the repository at this point in the history
Updated ChatConnection.getConnectionToken to use current contactId
Updated ccpAckTimeout, ccpSynTimeout, ccpLoadTimeout, and disableEchoCancellation definitions
Updated build files
Updated npm version

---------

Co-authored-by: Andy Wang <[email protected]>
  • Loading branch information
andywang219 and Andy Wang authored Jul 17, 2023
1 parent 932ad6a commit 6abf460
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 10 deletions.
12 changes: 7 additions & 5 deletions Documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -256,8 +256,9 @@ and made available to your JS client code.
ringtone audio that is played when a call is incoming.
* `ringtoneUrl`: If the ringtone is not disabled, this allows for overriding
the ringtone with any browser-supported audio file accessible by the user.
* `disableEchoCancellation`: This option allows you to initialize a custom or
embedded CCP with echo cancellation disabled.
* `disableEchoCancellation`: This option is only applicable in Chrome and allows you to initialize a custom or
embedded CCP with echo cancellation disabled. Setting this to `true` will disable **ALL** audio processing done by Chrome including Auto Gain Control.
* Please see this link https://docs.aws.amazon.com/prescriptive-guidance/latest/patterns/improve-call-quality-on-agent-workstations-in-amazon-connect-contact-centers.html for possible alternative options in approving auto quality.
* `pageOptions`: This object is optional and allows you to configure which configuration sections are displayed in the settings tab.
* `enableAudioDeviceSettings`: If `true`, the settings tab will display a section for configuring audio input and output devices for the agent's local
machine. If `false`, or if `pageOptions` is not provided, the agent will not be able to change audio device settings from the settings tab. will not be
Expand All @@ -267,9 +268,10 @@ and made available to your JS client code.
* `enablePhoneTypeSettings`: If `true`, or if `pageOptions` is not provided, the settings tab will display a section for configuring the agent's phone type
and deskphone number. If `false`, the agent will not be able to change the phone type or deskphone number from the settings tab.
* `shouldAddNamespaceToLogs`: prepends `[CCP]` to all logs logged by the CCP. Important note: there are a few logs made by the CCP before the namespace is prepended.
* `ccpAckTimeout`: A timeout in ms that indicates how long streams will wait for the iframed CCP to respond to its `SYNCHRONIZE` event emissions. These happen continuously from the first time `initCCP` is called. They should only appear when there is a problem that requires a refresh or a re-login.
* `ccpSynTimeout`: A timeout in ms that indicates how long streams will wait to send a new `SYNCHRONIZE` event to the iframed CCP. These happens continuously from the first time `initCCP` is called.
* `ccpLoadTimeout`: A timeout in ms that indicates how long streams will wait for the initial `ACKNOWLEDGE` event from the shared worker while the CCP is still standing itself up.
* `ccpAckTimeout`: A timeout in ms that tells CCP how long it should wait for an `ACKNOWLEDGE` message from the shared worker after CCP has sent a `SYNCHRONIZE` message to the shared worker. This is important because an `ACKNOWLEDGE` message is only sent back to CCP if the shared worker is initialized and a shared worker is only initialized if the agent is logged in. Moreover, this check happens continuously.
* `ccpSynTimeout`: A timeout in ms that tells CCP how long to wait before sending another `SYNCHRONIZE` message to the shared worker, which should trigger the shared worker to send back an `ACKNOWLEDGE` if initialized. This event essentially checks if the shared worker was initialized aka agent is logged in. This check happens continuously as well.
* `ccpLoadTimeout`: A timeout in ms that tells CCP how long to wait before sending the very first `SYNCHRONIZE` message. The user experience here is that on the first CCP initialization, the login flow is delayed by this timeout.
* As an example, if this timeout was set to 10 seconds, then the login pop-up will not open up until 10 seconds has pass.

#### A few things to note:
* You have the option to show or hide the pre-built UI by showing or hiding the
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "amazon-connect-streams",
"version": "2.5.0",
"version": "2.5.1",
"description": "Amazon Connect Streams Library",
"engines": {
"node": ">=12.0.0"
Expand Down
2 changes: 1 addition & 1 deletion release/connect-streams-min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion release/connect-streams.js
Original file line number Diff line number Diff line change
Expand Up @@ -2354,7 +2354,7 @@
var transportDetails = {
transportType: connect.TRANSPORT_TYPES.CHAT_TOKEN,
participantId: this.connectionId,
contactId: contactData.initialContactId || this.contactId
contactId: this.contactId
};
return new Promise(function (resolve, reject) {
client.call(connect.ClientMethods.CREATE_TRANSPORT, transportDetails, {
Expand Down
2 changes: 1 addition & 1 deletion src/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -2161,7 +2161,7 @@
var transportDetails = {
transportType: connect.TRANSPORT_TYPES.CHAT_TOKEN,
participantId: this.connectionId,
contactId: contactData.initialContactId || this.contactId
contactId: this.contactId
};
return new Promise(function (resolve, reject) {
client.call(connect.ClientMethods.CREATE_TRANSPORT, transportDetails, {
Expand Down

0 comments on commit 6abf460

Please sign in to comment.