Skip to content

Latest commit

 

History

History
304 lines (230 loc) · 8.78 KB

File metadata and controls

304 lines (230 loc) · 8.78 KB

API Reference

⚠️ Platform Differences Notice

Zoom Meeting SDK behavior is not fully consistent across all platforms. Some functions or event streams may behave slightly differently or be unavailable depending on the target platform (macOS, iOS, Android, Windows). Always test platform-specific behavior thoroughly.

For returned status values, check platform-specific availability via inline hints in your IDE (e.g., /// mac | ios | android | windows). These hints indicate which platforms support the value.

VSCode Hint

Note: All the code values like statusCode, errorCode, and endReasonCode are returned directly from the Zoom Meeting SDK and represent enum values defined per platform. These enum values are not guaranteed to be consistent across platforms, so prefer using statusLabel or statusEnum when writing your code.


1. Functions

initZoom


authZoom

  • Description: Authenticate SDK using your JWT token.
  • Request:
    • jwtToken: String — The JWT token used for authentication.
  • Response: Future<FlutterZoomMeetingSdkActionResponse<AuthParamsResponse>>
  • Example:
    await FlutterZoomMeetingSdk().authZoom(jwtToken: jwtToken);

joinMeeting

  • Description: Join a meeting using a Meeting ID and password. For webinars or meetings with registration, you must also pass a webinarToken.
  • Request:
    • meetingNumber: String — The Zoom meeting ID.
    • password: String — The meeting password.
    • displayName: String — The participant's display name.
    • webinarToken: String(Optional) The webinar token for webinars or registered meetings.
  • Response: Future<FlutterZoomMeetingSdkActionResponse<JoinParamsResponse>>
  • Example:
    await FlutterZoomMeetingSdk().joinMeeting(ZoomMeetingSdkRequest(
      meetingNumber: _meetingNumber,
      password: _passCode,
      displayName: _userName,
      webinarToken: _webinarToken,
    ));

unInitZoom


getJWTToken

  • Description: Retrieve a JWT token (signature) from a custom authentication endpoint. This token is required to authenticate the Zoom Meeting SDK using JWT.
  • Request:
    • authEndpoint: String — The URL of your server that returns a Zoom JWT token.
    • meetingNumber: String — The Zoom meeting ID.
    • role: int — The user's role in the meeting:
      • 0: Participant
      • 1: Host / Co-Host
  • Response: Future<JwtResponse?>
  • Example:
    final result = await _zoomSdk.getJWTToken(
      authEndpoint: _authEndpoint,
      meetingNumber: _meetingNumber,
      role: _role,
    );
    
    final signature = result?.token;

2. Event Streams

onAuthenticationReturn

  • Description: Triggered when the SDK authentication succeeds or fails.
  • Response: Stream<FlutterZoomMeetingSdkEventResponse<EventAuthenticateReturnParams>>
  • Platform: macOS | iOS | android | windows
  • Example:
    FlutterZoomMeetingSdk().onAuthenticationReturn.listen((event) {
      if (event.params?.statusEnum == StatusZoomError.success) {
        joinMeeting();
      }
    });

onZoomAuthIdentityExpired

  • Description: Triggered when the JWT token is expired. Generate a new token.
  • Response: Stream<FlutterZoomMeetingSdkEventResponse>
  • Platform: macOS | iOS | android | windows
  • Example:
    FlutterZoomMeetingSdk().onZoomAuthIdentityExpired.listen((event) {
      // Refresh JWT token here
    });

onMeetingStatusChanged


onMeetingParameterNotification


onMeetingError

  • Description: Triggered when a meeting encounters an error (e.g., connection issues, invalid parameters).
  • Response: Stream<FlutterZoomMeetingSdkEventResponse<EventMeetingErrorParams>>
  • Platform: iOS only
  • Note: Only available on iOS due to SDK inconsistencies.
  • Example:
    FlutterZoomMeetingSdk().onMeetingError.listen((event) {
      // Handle meeting error
    });

onMeetingEndedReason

  • Description: Triggered when a meeting ends, providing the end reason.
  • Response: Stream<FlutterZoomMeetingSdkEventResponse<EventMeetingEndedReasonParams>>
  • Platform: iOS only
  • Note: Only available on iOS due to SDK inconsistencies.
  • Example:
    FlutterZoomMeetingSdk().onMeetingEndedReason.listen((event) {
      // Handle meeting end reason
    });

3. Types

3.1 Function Responses

FlutterZoomMeetingSdkActionResponse<T>

Generic wrapper for all SDK function responses.

  • Fields:
    • platform: PlatformTypeandroid, ios, macos, windows
    • action: ActionTypeinitZoom, authZoom, joinMeeting, unInitZoom
    • isSuccess: bool — Whether the action succeeded.
    • message: String — Message or error info.
    • params: T? — Optional platform-specific data.

InitParamsResponse

  • Fields:
    • statusCode: int?
    • statusLabel: String?

AuthParamsResponse

  • Fields:
    • statusCode: int?
    • statusLabel: String?

JoinParamsResponse

  • Fields:
    • statusCode: int?
    • statusLabel: String?

3.2 Event Responses

FlutterZoomMeetingSdkEventResponse<T>

Generic wrapper for all SDK events.

  • Fields:
    • platform: PlatformType
    • event: EventType
    • oriEvent: String — Original Zoom SDK event name (platform-specific).
    • params: T? — Optional function-specific parameters.

EventAuthenticateReturnParams

⚠️ Use statusLabel or statusEnum instead of statusCode as values may differ across platforms.

  • Fields:
    • statusCode: int
    • statusLabel: String
    • statusEnum: StatusZoomError

EventMeetingStatusChangedParams

⚠️ Behavior differs across platforms:

  • iOS: errorCode and endReasonCode are separate events.
  • android: endReasonCode not available.
  • windows: provides errorCode or endReasonCode based on status.
  • Fields:
    • statusCode: int
    • statusLabel: String
    • statusEnum: StatusZoomError
    • errorCode: int
    • errorLabel: String
    • errorEnum: StatusMeetingError
    • endReasonCode: int
    • endReasonLabel: String
    • endReasonEnum: StatusMeetingEndReason

EventMeetingParameterNotificationParams

  • Fields:
    • isAutoRecordingCloud: bool
    • isAutoRecordingLocal: bool
    • isViewOnly: bool
    • meetingHost: String
    • meetingTopic: String
    • meetingNumber: int
    • meetingType: int
    • meetingTypeLabel: String
    • meetingTypeEnum: StatusMeetingType

EventMeetingErrorParams

  • Fields:
    • errorCode: int
    • errorLabel: String
    • errorEnum: StatusMeetingError
    • message: String

EventMeetingEndedReasonParams

  • Fields:
    • endReasonCode: int
    • endReasonLabel: String
    • endReasonEnum: StatusMeetingEndReason