C# Wrapper SDK Initialization Failed

I’m trying to run zoom_sdk_demo from c#
This is my code i used Publish (x86),Debug (x86),Release (x86) but application says error “SDKERR_UNINTIALİZE”
I Coded My Application in C# Windows Forms (Release x86)
My Code;
this.Text = “Waiting…”;
ZOOM_SDK_DOTNET_WRAP.CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().GetMeetingParticipantsController().Add_CB_onUserLeft(OnUserLeft);
ZOOM_SDK_DOTNET_WRAP.CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().GetMeetingParticipantsController().Add_CB_onUserNameChanged(OnUsernameChanged);
ZOOM_SDK_DOTNET_WRAP.CZoomSDKeDotNetWrap.Instance.GetMeetingServiceWrap().GetMeetingParticipantsController().Add_CB_onUserJoin(OnUserJoin);

            ZOOM_SDK_DOTNET_WRAP.AuthContext param = new ZOOM_SDK_DOTNET_WRAP.AuthContext();

            var tokenHandler = new System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler();
            var now = DateTime.UtcNow;
            var apiSecret = "MY API SECRET KEY IN HERE";
            byte[] symmetricKey = Encoding.ASCII.GetBytes(apiSecret);

            var tokenDescriptor = new SecurityTokenDescriptor
            {
                Issuer = "MY API KEY IN HERE",
                Expires = now.AddDays(1),
                SigningCredentials = new SigningCredentials(new SymmetricSecurityKey(symmetricKey), SecurityAlgorithms.HmacSha256),
            };
            var token = tokenHandler.CreateToken(tokenDescriptor);

            var tokenString = tokenHandler.WriteToken(token);
            param.jwt_token = tokenString;
            ZOOM_SDK_DOTNET_WRAP.SDKError f = ZOOM_SDK_DOTNET_WRAP.CZoomSDKeDotNetWrap.Instance.GetAuthServiceWrap().SDKAuth(param);
           
            //Hide();
            if(f == ZOOM_SDK_DOTNET_WRAP.SDKError.SDKERR_SUCCESS)
            {
                this.Text = "No Error Very Good";
            }
            else
            {
                this.Text = f.ToString();
            }

Hey @oyunmadenihd2,

Thanks for using the dev forum!

It looks like you have the correct configuration, but just to cover all the bases, the SDK needs to be run in release mode. It looks like the JWT creation is causing issues. Can you try creating a JWT at jwt.io then hardcoding it into your app to confirm?

Thanks!
Michael

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.