Gradle version greater than 7.x.x If you are using gradle plugin 7.x.x, add the maven depency to settings.gradle file located under project’s root directory
dependencyResolutionManagement {repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositories {google()mavenCentral()jcenter()// Warning: this repository is going to shut down soon**// START Wise SDK maven { url "<https://wise-maven.s3.ap-south-1.amazonaws.com/android/releases>" }// END Wise SDK** }}
Download Zoom SDK and import them as modules in your project. After unzipping the downloaded file, you will find two folders mobilertc and commonlib inside.
Import the Zoom SDK by navigating to File → New → Import Module and select the folder. You need to do this step for both mobilertc and commonlib folders.
Open app/build.gradle and add Wise and Zoom SDK dependencies and sync the project.
In order to use the Wise SDK, it should be initialised first. This step can be done in your Application class or before starting / joining a meeting.
Set your Vendor ID and Namespace
Enable tracking meeting attentiveness
Set Lens icon
Enable / Disable screen capture
publicclassDemoApplication extends Application {@Overridepublic void onCreate() {super.onCreate();initSdk(); }private void initSdk() {// set vendor Id and namespace// Send an email to info@wiseapp.live to get your VENDOR_ID and NAMESPACE// to be used in the Android Integration steps below WiseSDK.Companion.getInstance(this) .init("5f72e04f121699872486dc80", "YOUR_NAMESPACE");// Tracking attentiveness in lens WiseSDK.Companion.getInstance(this).trackAttentiveness(this); }}
4. Joining a meeting
You can use joinMeeting() to join a meeting. The required {token} can be found in the {public link} of a classroom. To get the {public link} you should call /user/v2/classes/:classId API (documentation)
WiseSDKMeetingListener provides necessary callbacks to listen to meeting status.
interfaceWiseSDKMeetingListener { // Called when vendor ID is verified fun onInitialised()// Throws an error when vendor ID is missing fun onVendorIdError()// When SDK throws and error. See below error codes for possible reason fun onSDKError(wiseErrorCode: Int, errorCode: Int, internalErrorCode: Int)// meeting initialisation started fun onMeetingConnecting()// Meeting started/joined successfully. This can be called multiple times fun onMeetingStarted(isInMeeting: Boolean)// Meeting ended successfully. This can be called multiple times. // userId is the ID you pass while joining meeting fun onMeetingEnded(userId: String?)// Meeting ended by host fun onMeetingEndedByHost()// Meeting ended with an error fun onMeetingEndedWithError(message: String, errorCode: Int, internalErrorCode: Int)// Meeting requires a password or display name fun onMeetingNeedPasswordOrDisplayName()// Meeting not started by host fun onMeetingNotStartedByHostError()}
6. Error Codes
In case of an error, onSDKError() will be triggered with an error code.
Error Code
Description
1
JWT Token error has occurred. This can be due to invalid vendor Id.
2
Zoom SDK failed to initialise.
3
Wise SDK failed to communicate with it’s servers.
4
Error fetching the SDK config
7. Proguard Rules
Add the below proguard rules to your proguard-rules.pro when minification is enabled.