webex / webex-js-sdk

JavaScript SDK for Webex
https://webex.github.io/webex-js-sdk/
Other
174 stars 343 forks source link

fix(plugin-meetings): handle meetingInfo response without permission token #3541

Closed sreenara closed 5 months ago

sreenara commented 5 months ago

COMPLETES # SPARK-516464

This pull request addresses

Instant Connect is unable to show details in the app regarding these 2 topics:

This is occurring because the meetingInfo object within meeting does not get populated when using SDK 3.0. While using SDK 2.35.0, Instant Connect does not observe the issues stated above.

Instant connect uses the Conversation URL of a space to create an instant meeting and WbxAppAPI service returns the meetingInfo response without a permissions token.

This issue is reproducible in the Kitchen sink page of the SDK as well when trying to create a meeting object with the conversation URL.

logger.js:396 wx-js-sdk Meetings:index#createMeeting --> Info Unable to fetch meeting info for https://conversation-intb.ciscospark.com/conversation/api/v1/conversations/3755da40-fc84-11ee-b4a6-198bb1d302bd.
logger.js:396 wx-js-sdk Meetings:index#createMeeting --> Info assuming this destination is a 1:1 or wireless share

by making the following changes

The permissionToken is an optional parameter. Therefore, setPermissionTokenPayload() and setSelfUserPolicies() functions should also be called only when permissionToken is available.

Change Type

The following scenarios where tested

Get a guest token and conversation URL. Initialize the webex object and create a meeting with the conversation URL. Check if meeting.meetingInfo object is populated.

Collected logs and HAR files for both working and fixed scenarios.

meetingInfo-missing-error.har.txt meetingInfo-missing-error-console.log fix-working-console-permissiontoken.har.txt fix-working-console-permissiontoken.log

I certified that


Make sure to have followed the contributing guidelines before submitting.

aws-amplify-us-east-2[bot] commented 5 months ago

This pull request is automatically being deployed by Amplify Hosting (learn more).

Access this pull request here: https://pr-3541.d3m3l2kee0btzx.amplifyapp.com