getFocusedSession (JavaScript API Reference) for Dynamics 365 Channel Integration Framework 2.0
Note
This content applies only to Dynamics 365 Channel Integration Framework version 2.0.
Note
Session management APIs allow you to integrate multisession experiences in Customer Service workspace app only.
Returns the unique identifier of the session that is in focus, if it belongs to the channel provider else returns null. The session ID is null if the connector attempts to retrieve a focused session created using a different connector.
Syntax
Microsoft.CIFramework.getFocusedSession().then(successCallback, errorCallback);
Parameters
Name | Type | Required | Description |
---|---|---|---|
successCallback | Function | No | A function to call when the request for setting the panel state is successful |
errorCallback | Function | No | A function to call when the request for setting the panel state fails |
Return value
Promise with the value as String
Example
Microsoft.CIFramework.getFocusedSession().then(
function success(result) {
console.log(result);
// perform operations on session id value
},
function (error) {
console.log(error.message);
// handle error conditions
}
);
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應