Skill 126 · Zoom Meeting SDK Windows
Subchapter 126.2
references/interface-methods.mdMarkdown16 KBView on GitHub
The Zoom SDK requires implementing ALL pure virtual methods from interface classes, even platform-specific ones. Missing even a single method results in abstract class errors at compile time.
This guide shows how to find required methods and implement them correctly.
#if defined(WIN32) blocks# Find all pure virtual methods (ending with = 0)
grep "= 0" SDK/x64/h/*.h
# Find methods in specific interface
grep "= 0" SDK/x64/h/auth_service_interface.h
grep "= 0" SDK/x64/h/meeting_service_interface.hWhen you forget to implement a method, the compiler tells you:
error C2259: 'AuthServiceEventListener': cannot instantiate abstract class
note: see declaration of 'AuthServiceEventListener'
note: due to following members:
'void IAuthServiceEvent::onNotificationServiceStatus(SDKNotificationServiceStatus,SDKNotificationServiceError)':
is abstract at auth_service_interface.h(256)This tells you:
onNotificationServiceStatusSDKNotificationServiceStatus status, SDKNotificationServiceError errorauth_service_interface.hOpen the interface header and look for methods marked with = 0:
class IAuthServiceEvent {
public:
virtual ~IAuthServiceEvent() {}
virtual void onAuthenticationReturn(AuthResult ret) = 0; // <-- REQUIRED (= 0)
virtual void onLogout() = 0; // <-- REQUIRED (= 0)
};File: SDK/x64/h/auth_service_interface.h (lines 217-258)
class AuthServiceEventListener : public IAuthServiceEvent {
public:
// Method 1: Authentication result (JWT token validation)
void onAuthenticationReturn(AuthResult ret) override;
// Method 2: Login result with fail reason (for user login, not JWT)
void onLoginReturnWithReason(LOGINSTATUS ret, IAccountInfo* pAccountInfo, LoginFailReason reason) override;
// Method 3: Logout notification
void onLogout() override;
// Method 4: Zoom identity expired (need to regenerate token)
void onZoomIdentityExpired() override;
// Method 5: Zoom auth identity expiring soon (10 minutes warning)
void onZoomAuthIdentityExpired() override;
// Method 6: WIN32 ONLY - Notification service status
#if defined(WIN32)
void onNotificationServiceStatus(SDKNotificationServiceStatus status, SDKNotificationServiceError error) override;
#endif
};Important notes:
onAuthenticationReturn fires; others are for user loginFile: SDK/x64/h/meeting_service_interface.h (lines 830-897)
class MeetingServiceEventListener : public IMeetingServiceEvent {
public:
// Method 1: Meeting status changed (joined, ended, failed, etc.)
void onMeetingStatusChanged(MeetingStatus status, int iResult) override;
// Method 2: Meeting statistics warning (network issues, etc.)
void onMeetingStatisticsWarningNotification(StatisticsWarningType type) override;
// Method 3: Meeting parameters (right before meeting starts)
void onMeetingParameterNotification(const MeetingParameter* meeting_param) override;
// Method 4: Participants activities suspended
void onSuspendParticipantsActivities() override;
// Method 5: AI Companion status changed
void onAICompanionActiveChangeNotice(bool bActive) override;
// Method 6: Meeting topic changed
void onMeetingTopicChanged(const zchar_t* sTopic) override;
// Method 7: Meeting at capacity, provides livestream URL
void onMeetingFullToWatchLiveStream(const zchar_t* sLiveStreamUrl) override;
// Method 8: User network quality changed
void onUserNetworkStatusChanged(MeetingComponentType type, ConnectionQuality level, unsigned int userId, bool uplink) override;
// Method 9: WIN32 ONLY - App signal panel updated
#if defined(WIN32)
void onAppSignalPanelUpdated(IMeetingAppSignalHandler* pHandler) override;
#endif
};Important notes:
onMeetingStatusChanged)If you don’t need a method’s functionality, implement it as an empty stub:
void AuthServiceEventListener::onLogout() {
// We're not using user login, so this never fires
// Empty implementation is fine
}
void MeetingServiceEventListener::onAICompanionActiveChangeNotice(bool bActive) {
// We don't care about AI Companion status
// Empty implementation is fine
}Add basic logging to see when callbacks fire:
void AuthServiceEventListener::onZoomIdentityExpired() {
std::cout << "[AUTH] Zoom identity expired! Need to regenerate JWT token." << std::endl;
}
void MeetingServiceEventListener::onMeetingStatisticsWarningNotification(StatisticsWarningType type) {
std::cout << "[MEETING] Statistics warning: " << static_cast<int>(type) << std::endl;
}void MeetingServiceEventListener::onMeetingStatusChanged(MeetingStatus status, int iResult) {
switch (status) {
case MEETING_STATUS_IDLE:
std::cout << "[MEETING] Status: IDLE" << std::endl;
break;
case MEETING_STATUS_CONNECTING:
std::cout << "[MEETING] Status: CONNECTING" << std::endl;
break;
case MEETING_STATUS_INMEETING:
std::cout << "[MEETING] Status: IN MEETING" << std::endl;
if (onInMeetingCallback) {
onInMeetingCallback(); // Trigger custom logic
}
break;
case MEETING_STATUS_ENDED:
std::cout << "[MEETING] Status: ENDED (Reason: " << iResult << ")" << std::endl;
if (onMeetingEnded) {
onMeetingEnded(); // Trigger custom logic
}
break;
case MEETING_STATUS_FAILED:
std::cout << "[MEETING] Status: FAILED (Error: " << iResult << ")" << std::endl;
break;
default:
std::cout << "[MEETING] Status: UNKNOWN (" << status << ")" << std::endl;
break;
}
}#pragma once
#include <windows.h>
#include <cstdint>
#include <auth_service_interface.h>
#include <iostream>
using namespace ZOOM_SDK_NAMESPACE;
class AuthServiceEventListener : public IAuthServiceEvent {
public:
// Constructor with callback
AuthServiceEventListener(void (*onComplete)());
// All 6 required methods
void onAuthenticationReturn(AuthResult ret) override;
void onLoginReturnWithReason(LOGINSTATUS ret, IAccountInfo* info, LoginFailReason reason) override;
void onLogout() override;
void onZoomIdentityExpired() override;
void onZoomAuthIdentityExpired() override;
#if defined(WIN32)
void onNotificationServiceStatus(SDKNotificationServiceStatus status, SDKNotificationServiceError error) override;
#endif
private:
void (*onAuthComplete)();
};#include "AuthServiceEventListener.h"
AuthServiceEventListener::AuthServiceEventListener(void (*onComplete)())
: onAuthComplete(onComplete) {}
void AuthServiceEventListener::onAuthenticationReturn(AuthResult ret) {
if (ret == AUTHRET_SUCCESS) {
std::cout << "[AUTH] Authentication successful!" << std::endl;
if (onAuthComplete) {
onAuthComplete();
}
} else {
std::cout << "[AUTH] Authentication failed: " << ret << std::endl;
}
}
void AuthServiceEventListener::onLoginReturnWithReason(LOGINSTATUS ret, IAccountInfo* info, LoginFailReason reason) {
std::cout << "[AUTH] Login return (not used for JWT): " << ret << std::endl;
}
void AuthServiceEventListener::onLogout() {
std::cout << "[AUTH] Logout" << std::endl;
}
void AuthServiceEventListener::onZoomIdentityExpired() {
std::cout << "[AUTH] Zoom identity expired!" << std::endl;
}
void AuthServiceEventListener::onZoomAuthIdentityExpired() {
std::cout << "[AUTH] Zoom auth identity expiring soon!" << std::endl;
}
#if defined(WIN32)
void AuthServiceEventListener::onNotificationServiceStatus(SDKNotificationServiceStatus status, SDKNotificationServiceError error) {
std::cout << "[AUTH] Notification service status: " << status << ", error: " << error << std::endl;
}
#endifCause: You’re missing one or more pure virtual method implementations.
Solution:
override keyword to catch signature mismatchesExample error:
error C2259: 'AuthServiceEventListener': cannot instantiate abstract class
note: due to following members:
'void IAuthServiceEvent::onNotificationServiceStatus(...)': is abstractFix: Add the missing method:
// In .h file
#if defined(WIN32)
void onNotificationServiceStatus(SDKNotificationServiceStatus status, SDKNotificationServiceError error) override;
#endif
// In .cpp file
#if defined(WIN32)
void AuthServiceEventListener::onNotificationServiceStatus(SDKNotificationServiceStatus status, SDKNotificationServiceError error) {
// Empty implementation is fine if you don't need this
}
#endifCause: Method signature doesn’t match exactly (wrong parameter types, missing const, etc.).
Solution: Copy the signature EXACTLY from the SDK header file, including:
const qualifiers* vs &)Cause: Forgot #if defined(WIN32) wrapper.
Solution: Wrap WIN32-only methods in both .h and .cpp files:
#if defined(WIN32)
void onNotificationServiceStatus(...) override;
#endifThese interfaces are required when using Custom UI mode (ENABLE_CUSTOMIZED_UI_FLAG).
File: SDK/x64/h/customized_ui/customized_ui_mgr.h
class CustomUIMgrEventListener : public ICustomizedUIMgrEvent {
public:
// Method 1: Video container destroyed by SDK (e.g., meeting ended)
void onVideoContainerDestroyed(ICustomizedVideoContainer* pContainer) override;
// Method 2: Share render destroyed by SDK
void onShareRenderDestroyed(ICustomizedShareRender* pRender) override;
// Method 3: Immersive container destroyed by SDK
void onImmersiveContainerDestroyed() override;
};Important notes:
File: SDK/x64/h/customized_ui/customized_video_container.h
class VideoContainerEventListener : public ICustomizedVideoContainerEvent {
public:
// Method 1: User changed for a video render element
void onRenderUserChanged(IVideoRenderElement* pElement, unsigned int userid) override;
// Method 2: Data type changed (video, avatar, screen name)
void onRenderDataTypeChanged(IVideoRenderElement* pElement, VideoRenderDataType dataType) override;
// Method 3: Layout notification — container resized, recompute element positions
void onLayoutNotification(RECT wnd_client_rect) override;
// Method 4: A video render element was destroyed
void onVideoRenderElementDestroyed(IVideoRenderElement* pElement) override;
// Method 5: Window messages from SDK child HWND (mouse, keyboard)
void onWindowMsgNotification(UINT uMsg, WPARAM wParam, LPARAM lParam) override;
// Method 6: Video subscription failed for an element
void onSubscribeUserFail(ZoomSDKVideoSubscribeFailReason fail_reason, IVideoRenderElement* pElement) override;
};Important notes:
onLayoutNotification is where you re-layout video elements after container resizeonWindowMsgNotification forwards input from SDK’s child HWND (see Custom UI Architecture)VideoRenderDataType values: VideoRenderData_Video, VideoRenderData_Avatar, VideoRenderData_ScreenNameZoomSDKVideoSubscribeFailReason values: ViewOnly, NotInMeeting, HasSubscribe1080POr720, HasSubscribeTwo720P, HasSubscribeExceededLimit, TooFrequentCallFile: SDK/x64/h/customized_ui/customized_share_render.h
class ShareRenderEventListener : public ICustomizedShareRenderEvent {
public:
// Method 1: Started receiving shared content
void onSharingContentStartReceiving() override;
// Method 2: Share source changed or sharing closed
void onSharingSourceNotification(unsigned int nShareSourceID) override;
// Method 3: Window messages from share render's child HWND
void onWindowMsgNotification(UINT uMsg, WPARAM wParam, LPARAM lParam) override;
};Important notes:
onSharingSourceNotification fires with a new ID, call SetShareSourceID(nShareSourceID) and Show()nShareSourceID will be 0 — call Hide()| Interface | Methods | File |
|---|---|---|
ICustomizedUIMgrEvent | 3 | customized_ui/customized_ui_mgr.h |
ICustomizedVideoContainerEvent | 6 | customized_ui/customized_video_container.h |
ICustomizedShareRenderEvent | 3 | customized_ui/customized_share_render.h |
ICustomizedImmersiveContainerEvent | 1 | customized_ui/customized_immersive_container.h |
| Total Custom UI methods | 13 |
Different SDK versions may have different required methods. This guide is for SDK v6.7.2.26830.
If you’re using a different version:
grep "= 0" SDK/x64/h/auth_service_interface.h to see your version’s methodsgrep "= 0" SDK/x64/h/meeting_service_interface.h# List all pure virtual methods in SDK
grep "= 0" SDK/x64/h/*.h
# Count methods per interface
grep -c "= 0" SDK/x64/h/auth_service_interface.h # Should be 6
grep -c "= 0" SDK/x64/h/meeting_service_interface.h # Should be 9
# Find method signature
grep -A 5 "onAuthenticationReturn" SDK/x64/h/auth_service_interface.h
# Verify your implementation has all methods
grep "override" src/AuthServiceEventListener.h # Should match SDK countLast Updated: Based on Zoom Windows Meeting SDK v6.7.2.26830