Skip to content

Commit 16b4ba4

Browse files
authored
Update user-facing-diagnostics-web.md
1 parent ac64cca commit 16b4ba4

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

articles/communication-services/concepts/voice-video-calling/includes/user-facing-diagnostics-web.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,18 @@ The following user-facing diagnostics are available:
7878

7979
User-facing diagnostics is an extended feature of the core [`Call`](/javascript/api/azure-communication-services/@azure/communication-calling/call?view=azure-communication-services-js&preserve-view=true) API. You can understand more about the `UserFacingDiagnosticsFeature` interface [here](/javascript/api/azure-communication-services/@azure/communication-calling/userfacingdiagnosticsfeature?view=azure-communication-services-js&preserve-view=true).
8080

81+
To utilize user fake facing diagnostics. First thing you must do is instantiate the. user facing diagnostics feature from the call. something something.....
8182
```js
8283
const userFacingDiagnostics = call.feature(Features.UserFacingDiagnostics);
8384
```
8485

86+
After you have initialized the user facing diagnostics, then you can define that. the events. will be fired off from some. things, something, something.
87+
```js
88+
// Subscribe to the `diagnosticChanged` event to monitor when any local user-facing diagnostic changes.
89+
userFacingDiagnostics.network.on('diagnosticChanged', diagnosticChangedListener);
90+
userFacingDiagnostics.media.on('diagnosticChanged', diagnosticChangedListener);
91+
```
92+
8593
## Local User Facing Diagnostic events
8694
Each diagnostic has the following data:
8795
- Diagnostic is the type of UFD diagnostic that has been fired off on the local machine. For example a UFD of `NetworkSendQuality` or `DeviceSpeakWhileMuted`.
@@ -194,4 +202,4 @@ console.log(
194202
`microphoneNotFunctioning: ${latestMediaDiagnostics.microphoneNotFunctioning.value}, ` +
195203
`value type = ${latestMediaDiagnostics.microphoneNotFunctioning.valueType}`
196204
);
197-
```
205+
```

0 commit comments

Comments
 (0)