import { NativeModules } from 'react-native'; import type { Errors } from '../native/ZoomVideoSdk'; const { RNZoomVideoSdkCmdChannel } = NativeModules; /** * The command channel allows users to send commands or data (such as plain text or a binary encoded into a string) to other users in the same session. */ export type ZoomVideoSdkCmdChannelType = { /** * Send custom commands or data to other users in the current session. Limit: up to 2 custom commands per second. */ sendCommand: (receiverId: string, strCmd: string) => Promise; }; export class ZoomVideoSdkCmdChannel { async sendCommand(receiverId: string, strCmd: string) { return await RNZoomVideoSdkCmdChannel.sendCommand(receiverId, strCmd); } }