Members
(constant) BANDWIDTH_QUALITY_LEVEL :number
Enumeration of the bandwidth quality level.
Properties:
| Name | Type | Description |
|---|---|---|
VERY_LOW |
number
|
bandwidth quality is very low. Default value is 0. |
LOW |
number
|
bandwidth quality is low. Default value is 1. |
NORMAL |
number
|
bandwidth quality is normal. Default value is 2. |
UNDEFINED |
number
|
bandwidth quality is unknown. If get this value, means the network diagnostic is not started yet or gets some exceptions. Default value is 255. |
Type:
-
number
(constant) BASIC_INFO_ATTR_INDEX :number
Enumeration of attribute index of the basic information.
Properties:
| Name | Type | Description |
|---|---|---|
BROWSER_NAME |
number
|
represents the name of the browser. Default value is 0. |
BROWSER_VERSION |
number
|
represents the version of the browser. Default value is 1. |
OS_NAME |
number
|
represents the name of the OS. Default value is 2. |
USER_AGENT |
number
|
represents the user agent. Default value is 3. |
HW_CONCURRENCY |
number
|
represents the hardware concurrency. Default value is 4. |
GPU_VENDOR |
number
|
represents the GPU vendor. Default value is 5. |
GPU_RENDERER |
number
|
represents the GPU renderer information. Default value is 6. |
VIDEOFRAME |
number
|
represents the VideoFrame API. Default value is 7. |
OFFSCREENCANVAS |
number
|
represents the OffscreenCanvas API. Default value is 8. |
SIMD |
number
|
represents the SIMD feature. Default value is 9. |
WEB_CODEC |
number
|
represents the web codec feature. Default value is 10. |
HW_ACC |
number
|
represents the hardware acceleration. Default value is 11. |
GRAPHICS_ACC |
number
|
represents the graphics acceleration in chromium system settings. Default value is 12. |
MIN_BROWSER_VERSION |
number
|
represents the minimum browser version. Default value is 13. |
SHARED_ARRAY_BUFFER |
number
|
represents the SharedArrayBuffer. Default value is 14. |
BUILD_BITNESS |
number
|
represents the build bitness(32bit or 64bit). Default value is 15. |
Type:
-
number
(constant) DEF_CONNECT_TIMEOUT
The default connection timeout, 20 seconds.
(constant) DEF_PROBE_DURATION
The default probing duration, 120 seconds.
(constant) ERR_CODE :number
Enumeration of a collection of customized error codes defined and used by ProberSDK.
Properties:
| Name | Type | Description |
|---|---|---|
OK |
number
|
Indicates a successful operation. Default value is 0. |
INVALID_ARGS |
number
|
Indicates invalid arguments passed to a function. Default value is -1. |
API_NOT_SUPPORTED |
number
|
Indicates that a specific API is not supported. Default value is -2. |
Type:
-
number
(constant) NETWORK_QUALITY_LEVEL :number
Enumeration of the network quality level.
Properties:
| Name | Type | Description |
|---|---|---|
VERY_BAD |
number
|
network quality is very bad. Default value is 0. |
BAD |
number
|
network quality is bad. Default value is 1. |
NOT_GOOD |
number
|
network quality is not good enough. Default value is 2. |
FAIR |
number
|
network quality is fine. Default value is 3. |
GOOD |
number
|
network quality is good. Default value is 4. |
EXCELLENT |
number
|
network quality is excellent. Default value is 5. |
UNDEFINED |
number
|
network quality is unknown. If get this value, means the network diagnostic is not started yet or gets some exceptions. Default value is 255. |
Type:
-
number
(constant) NET_PROBING_DATA_TYPE :number
Enumeration of the data type of the network diagnostic. It will be used to determine the type of data you received and how to handle them.
Properties:
| Name | Type | Description |
|---|---|---|
STATS |
number
|
indicates the realtime statistics of the network diagnostic. Default value is 1. |
REPORT |
number
|
indicates the final report of diagnostic, basic information and supported features. Default value is 2. |
Type:
-
number
(constant) PROTOCOL_TYPE :number
Enumeration of the protocol type that ProbeSDK checks in a network diagnostic.
Properties:
| Name | Type | Description |
|---|---|---|
HTTPS |
number
|
Hypertext Transfer Protocol Secure (https://) protocol. Value: 1. Critical requirement: If this diagnostic fails, the user environment cannot support the SDK. |
WEB_SOCKET |
number
|
WebSocket (wss://, ws://) protocol. Value: 2. Critical requirement: If this diagnostic fails, the user environment cannot support the SDK. |
DATA_CHANNEL |
number
|
Data channel for media communication. Value: 3. If this diagnostic fails, the SDK automatically switches to WebSocket protocol for communication. Users can still use the SDK with reduced performance. |
WEB_TRANSPORT |
number
|
WebTransport protocol. Value: 4. Currently not supported. The result of this diagnostic does not affect SDK functionality. |
Type:
-
number
(constant) RENDERER_TYPE :number
Enumeration of the rendering types supported by ProbeSDK.
Properties:
| Name | Type | Description |
|---|---|---|
VIDEO_TAG |
number
|
a video stream will be rendered on the video tag. Default value is 1. |
WEBGL |
number
|
a video stream will be rendered on a canvas with a WebGL renderer. Default value is 2. |
WEBGL_2 |
number
|
a video stream will be rendered on a canvas with a WebGL2 renderer. Default value is 3. |
WEBGPU |
number
|
a video stream will be rendered on a canvas with a WebGPU renderer. Default value is 4. |
Type:
-
number
(constant) SUPPORTED_FEATURE_INDEX :number
Enumeration of index of the supported features.
Properties:
| Name | Type | Description |
|---|---|---|
AUDIO_DENOISE |
number
|
feature index of audio denoise. Default value is 0. |
AEC |
number
|
feature index of audio echo cancellation. Default value is 1. |
AUDIO_STEREO |
number
|
feature index of audio stereo. Default value is 2. |
VIRTUAL_BACKGROUND |
number
|
feature index of video virtual background. Default value is 3. |
VIDEO_MASK |
number
|
feature index of video mask. Default value is 4. |
WEBGPU |
number
|
feature index of video WebGPU rendering. Default value is 5. |
VIDEO_SEND_HD |
number
|
feature index of video sending HD. Default value is 6. |
VIDEO_SEND_FULL_HD |
number
|
feature index of video sending full HD. Default value is 7. |
DT_GALLERY_VIEW_3x3 |
number
|
feature index of desktop supporting 3x3 gallery view. Default value is 8. |
DT_GALLERY_VIEW_5x5 |
number
|
feature index of desktop supporting 5x5 gallery view. Default value is 9. |
SCREEN_SHARING |
number
|
feature index of screen sharing. Default value is 10. |
Type:
-
number
Methods
cleanup()
Cleanup the resources created in ProbeSDK, like network connections, rendering resources, etc.
Example
prober.cleanup();
(async) diagnoseAudio(inputConstraints, outputConstraints, durationopt, mimeTypeopt) → {Promise.<DiagnosticResult>}
Performs an asynchronous audio diagnostic by recording audio from a specified input device and playing it back through a specified output device. Supports custom recording duration, MIME type selection, and captures all errors, returning them as a DiagnosticResult.
Parameters:
| Name | Type | Attributes | Default | Description | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
inputConstraints |
MediaStreamConstraints
|
|
||||||||||||||
outputConstraints |
Object
|
|
||||||||||||||
duration |
number
|
<optional> |
0 |
|
||||||||||||
mimeType |
string
|
<optional> |
'' |
|
Returns:
- Type:
-
Promise.<DiagnosticResult>
- Resolves to a DiagnosticResult object:
- On success:
{ code: ERR_CODE.OK, message: "audio diagnostic complete!" } - On failure: contains the appropriate error code and message (e.g. permission denied, initialization failure, AudioContext/MediaRecorder creation failure, etc.).
- On success:
Example
(async () => {
const input = { audio: { deviceId: 'default' }, video: false };
const output = { audio: { deviceId: 'xxxxxx' }, video: false };
const result = await diagnoseAudio(input, output, 10000, '');
if (result.code === ERR_CODE.OK) {
console.log('Diagnostic completed successfully');
} else {
console.error('Diagnostic failed:', result.message);
}
})();
(async) diagnoseScreenShare(optionsopt, progressListeneropt) → {Promise.<ScreenShareDiagnosticResult>}
Perform a full screen share diagnostic across three phases:
- Static environment checks (no user interaction)
- Permission capture via getDisplayMedia() (user selects share source)
- Frame quality analysis — luminance metrics only, no pixel storage
Parameters:
| Name | Type | Attributes | Description | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
object
|
<optional> |
|
||||||||||||||||||||
progressListener |
function
|
<optional> |
callback({ phase, state, message, data }) |
Returns:
- Type:
-
Promise.<ScreenShareDiagnosticResult>
Example
import { Prober, ERR_CODE } from "@zoom/probesdk";
const prober = new Prober();
const result = await prober.diagnoseScreenShare(
{ frameSampleCount: 10, frameSampleDurationMs: 3000 },
({ phase, state, message }) => {
console.log(`[${phase}] ${state}: ${message}`);
}
);
if (result.code === ERR_CODE.OK) {
console.log("Screen share diagnostic passed.");
} else if (result.code === ERR_CODE.SCREEN_SHARE_USER_CANCELLED) {
console.warn("User cancelled the share picker.");
} else if (result.code === ERR_CODE.SCREEN_SHARE_PERMISSION_DENIED) {
console.error("Permission denied:", result.suggestedAction);
} else if (result.code === ERR_CODE.SCREEN_SHARE_BLACK_SCREEN) {
console.error("Black screen detected:", result.suggestedAction);
} else if (result.code === ERR_CODE.SCREEN_SHARE_STATIC_CHECK_FAILED) {
console.error("Environment check failed:", result.message);
}
console.log("Engineering dump:", result.engineeringDump);
(async) diagnoseVideo(constraints, options) → {DiagnosticResult}
Diagnose video device like camera and show the result on a renderable object. You can select a camera by setting constraints and different renderer type by setting the parameter options. Four renderer types are supported by ProbeSDK. Please refer to the documentation of RENDERER_TYPE.
Once the video diagnostic is launched, a MediaStream object is saved to the field stream of DiagnosticResult.
It is necessary when you want to stop the video diagnostic, if not stopping it, the camera capturing currently is always working.
Different renderer types require different RendererOptions:
- VIDEO_TAG requires a video element(HTMLMediaElement)
- WebGL/WebGL2/WebGPU requires a canvas(HTMLCanvasElement) or an OffscreenCanvas(OffscreenCanvas)
Parameters:
| Name | Type | Description |
|---|---|---|
constraints |
MediaStreamConstraints
|
A camera constraints which is diagnosed. |
options |
RendererOptions
|
The options of how to render a video stream, includes the a renderer type and a target where to render. |
Throws:
-
If any parameters are invalid, a customized Error will be thrown, or some standard exceptions like DOMException will be thrown during the diagnostic
- Type
-
Error
Example
// for video tag case, you can:
// in your html file, to define a video tag
<video id="local_preview_video" width="640" height="480" autoplay hidden></video>
const preview_video = document.getElementById('local_preview_video');
const constraints = {
video: {
width: preview_video.width,
height: preview_video.height,
deviceId: document.getElementById("camera_list").value, // need a deviceId of a camera
},
};
const options = {
rendererType: 1, // 1 for video_tag
target: preview_video,
};
const diagnosticResult = await prober.diagnoseVideo(constraints, options);
console.log(diagnosticResult);
// for WebGL/WebGL2/WebGPU case, you can:
// in your html file, to define a canvas
<canvas id="local_preview_canvas" width="640" height="480"></canvas></br>
const preview_canvas = document.getElementById('local_preview_canvas');
const constraints = {
video: {
width: preview_canvas.width,
height: preview_canvas.height,
deviceId: document.getElementById("camera_list").value, // need a deviceId of a camera
},
};
const options = {
rendererType: 2, // WebGL
target: preview_canvas,
};
const result = await prober.diagnoseVideo(constraints, options);
console.log(result);
queryRid() → {string}
Query the trackingId(rid) of last round of probing.
Returns:
- Type:
-
string
rid a string is used to track the last round of network diagnosis. If the result is an empty string or undefined, it means that the last round of network diagnosis fails.
Example
const rid = prober.queryRid();
console.log(rid);
releaseMediaStream(stream) → {boolean}
Releases the resources associated with a given MediaStream.
This function stops all tracks in the provided MediaStream to release the hardware resources (e.g., camera, microphone) and removes them from the stream. It ensures that no resources are left in use after the MediaStream is no longer needed.
Note that ProbeSDK is not responsible for setting the stream you pass to null. So, the caller should maintain its lifecycle.
Parameters:
| Name | Type | Description |
|---|---|---|
stream |
MediaStream
|
The MediaStream object to release. |
Returns:
- Type:
-
boolean
- Returns
trueif the stream was successfully released, orfalseif the input was invalid (e.g., null or undefined).
Example
const stream = await navigator.mediaDevices.getUserMedia({ video: true });
let result = releaseMediaStream(stream);
console.log(result);
(async) reportBasicInfo(navigator) → {Promise.<{Array.<BasicInfoEntry>}>}
Report basic information of the target device, like browser information, OS, etc.
Parameters:
| Name | Type | Description |
|---|---|---|
navigator |
object
|
the state and the identity of the user agent. |
Returns:
- Type:
-
Promise.<{Array.<BasicInfoEntry>}>
A promise that resolves to an array of basic information entries.
Example
const reporter = new Reporter();
reporter.reportBasicInfo(navigator).then((info) => {
console.log(JSON.stringify(info));
});
(async) reportFeatures() → {Promise.<{Array.<FeatureEntry>}>}
Report whether the advanced features are supported or not on the target device.
Returns:
- Type:
-
Promise.<{Array.<FeatureEntry>}>
A promise that resolves to an array of advanced media features.
Example
const reporter = new Reporter();
reporter.reportFeatures().then((features) => {
console.log(JSON.stringify(features));
});
(async) requestMediaDevicePermission(constraints) → {Promise.<{stream: MediaStream, error: Error}>}
Requests media device permission asynchronously.
Parameters:
| Name | Type | Description |
|---|---|---|
constraints |
MediaStreamConstraints
|
The constraints for the requested media stream. |
Throws:
-
If the constraint argument is undefined.
- Type
-
Error
Returns:
- Type:
-
Promise.<{stream: MediaStream, error: Error}>
A promise that resolves to an object containing either the requested media stream or an error object. The error object may be an instance of DOMException or other standard system exceptions.
Example
import { Prober } from "@zoom/probesdk";
const prober = new Prober();
function getMediaDevices() {
prober.requestMediaDevices().then((result) => {
console.log(`error:${result.error}, devices=${result.devices}`);
});
}
(async) requestMediaDevices() → {Promise.<{devices: Array.<MediaDeviceInfo>, error: {code: number, message: string}}>}
Requests the media devices asynchronously.
This function checks if the enumerateDevices method is supported the browser's navigator.mediaDevices object.
If supported, it retrieves a list of available media devices. If not, it returns an object of PSDKError
indicating the lack of support.
Returns:
- Type:
-
Promise.<{devices: Array.<MediaDeviceInfo>, error: {code: number, message: string}}>
a promise that resolves to an object containing an array of available media devices or an error object. The error object may be an instance of DOMException or other standard system exceptions.
Example
prober.requestMediaDevices().then((result) => {
console.log(`error:${result.error}, devices=${result.devices}`);
});
(async) startCameraDump(optionsopt) → {Promise.<CameraDumpStartResult>}
Start a camera dump session for offline troubleshooting.
This feature is designed to help diagnose issues like camera preview flicker/black frames by:
- Recording the selected camera stream into a small
video.webm - Collecting per-frame luminance statistics (
frames.jsonl) to locate black frames precisely - Capturing basic track events (
events.jsonl) - Packaging everything into a single downloadable bundle (
.probe.taror.probe.tar.gz)
Chrome-only note: This API relies on MediaStreamTrackProcessor.
Properties:
| Name | Type | Attributes | Description |
|---|---|---|---|
code |
number
|
||
message |
string
|
||
session |
CameraDumpSession
|
<optional> |
An active camera dump session on success. |
stream |
MediaStream
|
<optional> |
The camera MediaStream on success (optional). |
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
options |
CameraDumpOptions
|
<optional> |
Optional. If omitted, defaults will be used. |
Returns:
- Type:
-
Promise.<CameraDumpStartResult>
Example
// Minimal: use browser default camera + default low-res/low-bitrate settings
const { code, session } = await prober.startCameraDump();
// Or specify a camera deviceId
const { code, session } = await prober.startCameraDump({ deviceId, durationMs: 120000, width: 320, height: 180 });
// ... later
await session.stop();
await session.downloadBundle();
startToDiagnose(jsUrlopt, wasmUrlopt, config, networkStatsListeneropt) → {Promise.<DiagnosticReport>}
Start a full diagnostic that includes the network diagnostic, basic information, and supported features report . It depends on the network diagnostic. Once it is called, the network diagnostic begins, and a report will be generated automatically after it ends.
Before the diagnosis starts, you need to specify the detection time, connection timeout time and other parameters. For the detection time, we recommend setting it at more than 2 minutes. This is because in network diagnosis, if a server is not connected, we will try to connect to an alternative server, which will lead to a connection timeout wait. It takes up most of the detection time, resulting in less detection time after the connection, resulting in inaccurate data. Therefore, we recommend that the detection time be set relatively large, more than 2 minutes, such as 3-5 minutes is OK. If you set the time too short, the results of the network diagnosis will not be very accurate and will not help you diagnose the problem.
Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
jsUrl |
string
|
<optional> |
prober.js |
a URL of javascript file used for a network diagnostic. |
wasmUrl |
string
|
<optional> |
prober.wasm |
a URL of WebAssembly file used for a network diagnostic. |
config |
NetworkDiagnosticConfig
|
indicates the configuration of a network diagnostic. |
||
networkStatsListener |
NetworkStatsListener
|
undefined
|
<optional> |
the listener to receive network diagnostic statistics, the listener can be set to undefined if you only care about the final network diagnostic. |
Returns:
- Type:
-
Promise.<DiagnosticReport>
a diagnostic report in a promise which includes a set of basic information, supported features, and a final network diagnostic report.
Example
const jsUrl = 'prober.js';
const wasmUrl = 'prober.wasm';
const config = { probeDuration: 120 * 1000, connectTimeout: 20 * 1000, domain: '[a Zoom or custom domain]' };
prober.startToDiagnose(jsUrl, wasmUrl, config, (stats) => {
console.log(stats);
}).then((report) => {
console.log(report);
});
(async) stopToDiagnose() → {Promise.<(DiagnosticReport|null)>}
Stop the ongoing network diagnostic that was initiated by the startToDiagnose method.
This function will immediately stop all network probing activities, cleanup all resources including network connections, timers, and WebAssembly instances. If a diagnostic is currently running, it will generate a final report with the data collected up to the point of stopping.
Returns:
- Type:
-
Promise.<(DiagnosticReport|null)>
A promise that resolves to a diagnostic report with the data collected before stopping, or null if no diagnostic was running.
Example
// Start diagnostic
const diagnosticPromise = prober.startToDiagnose(jsUrl, wasmUrl, config, (stats) => {
console.log(stats);
});
// Stop diagnostic after 30 seconds
setTimeout(async () => {
const partialReport = await prober.stopToDiagnose();
console.log('Diagnostic stopped, partial report:', partialReport);
}, 30000);
stopToDiagnoseVideo(streamopt) → {boolean}
Stops the video diagnostic that was started by the diagnoseVideo method.
The frontend or any caller can pass the MediaStream of DiagnosticResult to stop video diagnostic, like removing the video element or the canvas on the screen are necessary actions too. Note that, you can still call releaseMediaStream to manually destroy the MediaStream.
Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
stream |
MediaStream
|
<optional> |
null |
The MediaStream which will be destroyed. |
Returns:
- Type:
-
boolean
Returns true if the video diagnostic is stopped successfully, otherwise returns false.
Example
document.getElementById("btn_stop_preview").addEventListener("click", () =>{
let result = prober.stopToDiagnoseVideo(stream); // stream saved in the result of calling diagnoseVideo()
console.log(`stopToDiagnoseVideo() result: ${result}`);
});
Type Definitions
AffectedFeatureEntry
An object describes an entry of an affected feature.
Properties:
| Name | Type | Description |
|---|---|---|
featureName |
string
|
the name of an affected feature. |
Type:
-
object
AffectedFeatureEntry
An object describes an entry of an affected feature.
Properties:
| Name | Type | Description |
|---|---|---|
featureName |
string
|
the name of an affected feature. |
Type:
-
object
BasicInfoEntry
An object describes an entry of basic information.
Properties:
| Name | Type | Description |
|---|---|---|
index |
number
|
index of an attribute added to the basic information, refer to BASIC_INFO_ATTR_INDEX. |
attr |
string
|
name/label of an attribute. |
val |
string
|
value of an attribute. |
critical |
boolean
|
whether the attribute is critical or not. If true, the attribute is critical and a list of affected features will be attached to the affectedFeatures field. |
affectedFeatures |
Array.<AffectedFeatureEntry>
|
an array of affected features if the critical value is true, that is, a group of features might be affected if this attribute is not matched. |
Type:
-
object
BasicInfoEntry
An object describes an entry of basic information.
Properties:
| Name | Type | Description |
|---|---|---|
index |
number
|
index of an attribute added to the basic information, refer to BASIC_INFO_ATTR_INDEX. |
attr |
string
|
name/label of an attribute. |
val |
string
|
value of an attribute. |
critical |
boolean
|
whether the attribute is critical or not. If true, the attribute is critical and a list of affected features will be attached to the affectedFeatures field. |
affectedFeatures |
Array.<AffectedFeatureEntry>
|
an array of affected features if the critical value is true, that is, a group of features might be affected if this attribute is not matched. |
Type:
-
object
CheckItem
An object describes an entry of a supported feature checking.
Properties:
| Name | Type | Description |
|---|---|---|
index |
number
|
indicates a classification of the requirement, sometimes this field can be ignored. |
label |
string
|
the label of a requirement. |
matched |
boolean
|
indicates whether a condition of the requirement is matched or not. |
tip |
string
|
a tip will help if the condition is not matched. |
Type:
-
object
CheckItem
An object describes an entry of a supported feature checking.
Properties:
| Name | Type | Description |
|---|---|---|
index |
number
|
indicates a classification of the requirement, sometimes this field can be ignored. |
label |
string
|
the label of a requirement. |
matched |
boolean
|
indicates whether a condition of the requirement is matched or not. |
tip |
string
|
a tip will help if the condition is not matched. |
Type:
-
object
DiagnosticReport
An object describes a report of the entire diagnostic.
Properties:
| Name | Type | Description |
|---|---|---|
networkDiagnosticResult |
NetworkDiagnosticResult
|
the report of the network diagnostic part. |
basicInfo |
Array.<BasicInfoEntry>
|
a set of basic information, like browser, OS, hardware, etc. |
supportedFeatures |
Array.<FeatureEntry>
|
a set of features that are important to the user. |
Type:
-
object
DiagnosticResult
Diagnostic result object.
Properties:
| Name | Type | Attributes | Description |
|---|---|---|---|
code |
number
|
|
|
message |
string
|
|
|
stream |
MediaStream
|
<optional> |
|
Type:
-
object
FeatureEntry
An object describes a piece of supported feature.
Properties:
| Name | Type | Description |
|---|---|---|
index |
number
|
the index of a supported feature, refer to SUPPORTED_FEATURE_INDEX. |
featureName |
string
|
the name of a supported feature. |
isSupported |
boolean
|
whether the feature is supported or not. |
checkList |
Array.<CheckItem>
|
an array of CheckItem which are used to judge whether the conditions of a supported features are matched or not. |
Type:
-
object
FeatureEntry
An object describes a piece of supported feature.
Properties:
| Name | Type | Description |
|---|---|---|
index |
number
|
the index of a supported feature, refer to SUPPORTED_FEATURE_INDEX. |
featureName |
string
|
the name of a supported feature. |
isSupported |
boolean
|
whether the feature is supported or not. |
checkList |
Array.<CheckItem>
|
an array of CheckItem which are used to judge whether the conditions of a supported features are matched or not. |
Type:
-
object
NetworkDiagnosticConfig
An object represents the configuration of network diagnostic.
Properties:
| Name | Type | Description |
|---|---|---|
connectTimeout |
number
|
the timeout of the connections established in a network diagnostic. If not set, the default value is DEF_CONNECT_TIMEOUT. |
probeDuration |
number
|
the duration of how long a round of a network diagnostic. If not set, the default value is DEF_PROBE_DURATION. If set, the maximum value between DEF_PROBE_DURATION and probeDuration is used as the final probing duration. |
domain |
string
|
the domain of the prober server. Provide your own domain or use the default domain provided by Zoom if not set. |
Type:
-
object
NetworkDiagnosticResult
An object describes the report of the network diagnostic.
Properties:
| Name | Type | Description |
|---|---|---|
serviceZone |
string
|
indicates the service zone, it is a constant currently. |
protocols |
Array.<ProtocolEntry>
|
an array of protocols used in a network diagnostic. |
statistics |
NetworkDiagnosticStatsReport
|
the final report of the network diagnostic statistics. |
rid |
string
|
a string is used to track this round of network diagnosis. |
Type:
-
object
NetworkDiagnosticStats
An object describes the real-time network diagnostic statistics.
Properties:
| Name | Type | Description |
|---|---|---|
type |
number
|
indicates whether the data is a real-time statistics or the final report. Refer to NET_PROBING_DATA_TYPE for details. |
content |
NetworkDiagnosticStatsContent
|
indicates the content of the real-time statistics. |
Type:
-
object
NetworkDiagnosticStatsContent
An object describes the content/data part of the real-time network diagnostic statistics.
Properties:
| Name | Type | Description |
|---|---|---|
path |
string
|
indicates the statistics coming from uplink or downlink. |
statistics |
NetworkDiagnosticStatsData
|
the statistics of uplink or downlink. |
Type:
-
object
NetworkDiagnosticStatsData
An object describes the statistics of a network diagnostic.
Properties:
| Name | Type | Description |
|---|---|---|
bandwidth |
number
|
bandwidth(kb/s). |
bw_level |
number
|
the quality level of the bandwidth, refer to BANDWIDTH_QUALITY_LEVEL. |
jitter |
number
|
jitter(ms). |
lossRate |
number
|
the rate of package loss(%). |
rtt |
number
|
the round-trip time(ms). |
network_level |
number
|
the quality level of the network, refer to NETWORK_QUALITY_LEVEL. |
Type:
-
object
NetworkDiagnosticStatsReport
An object describes the report of the final and average statistics of a network diagnostic.
Properties:
| Name | Type | Description |
|---|---|---|
uplink_bandwidth |
number
|
the last uplink bandwidth, kb/s. |
uplink_avg_loss |
number
|
the average value of uplink package loss(%). |
uplink_avg_rtt |
number
|
the average value of uplink round-trip time(ms). |
uplink_avg_jitter |
number
|
the average value of uplink jitter(ms). |
uplink_bw_level |
number
|
the last uplink bandwidth quality level, refer to BANDWIDTH_QUALITY_LEVEL. |
uplink_network_level |
number
|
the last uplink network quality level, refer to NETWORK_QUALITY_LEVEL. |
downlink_bandwidth |
number
|
the last downlink bandwidth, kb/s. |
downlink_avg_loss |
number
|
the average value of downlink package loss(%). |
downlink_avg_rtt |
number
|
the average value of downlink round-trip time(ms). |
downlink_avg_jitter |
number
|
the average value of downlink jitter(ms). |
downlink_bw_level |
number
|
the last downlink bandwidth quality level, refer to BANDWIDTH_QUALITY_LEVEL. |
downlink_network_level |
number
|
the last downlink network quality level, refer to NETWORK_QUALITY_LEVEL. |
Type:
-
object
NetworkStatsListener
A function object is used as a listener to listen the network diagnostic statistics.
Properties:
| Name | Type | Description |
|---|---|---|
onStatsReceived |
function
|
callback function which receives an instance of NetworkDiagnosticStats. |
Type:
-
object
PSDKError
An object, indicates an error generated by ProberSDK.
Properties:
| Name | Type | Description |
|---|---|---|
code |
number
|
an error code defined by ERR_CODE. |
message |
string
|
the error message. |
Type:
-
object
ProtocolEntry
An object represents the details of protocols which are used in the network diagnostics.
Properties:
| Name | Type | Description |
|---|---|---|
type |
number
|
the type of the protocols, refer to PROTOCOL_TYPE. |
isBlocked |
boolean
|
indicates whether the protocol is blocked or not. |
port |
string
|
the port that a protocol uses. |
tip |
string
|
a tip will help if the protocol or port is blocked or not. |
error |
*
|
some customized errors or standard errors, like DOMException, will be thrown if any. If no exceptions, it is undefined. |
Type:
-
object
RendererOptions
An object describes how to render video streams.
Properties:
| Name | Type | Description |
|---|---|---|
rendererType |
number
|
the renderer type, refer to the values of RENDERER_TYPE. |
target |
HTMLMediaElement
|
HTMLCanvasElement
|
OffscreenCanvas
|
where to render a video stream. |
Type:
-
object