Video SDK problem when creating session (playing with sample)

I have started learning Video SDK and have failure in creating session.
When I run the sample program and create the session, it shows the camera capture for a short time, then shows a message:
Unable to join or create session.Please
try again.(Error Code: 2009)

The SDK documentation says about this error code:
ZoomVideoSDKErrors_Meeting_Not_Started 2009 The Session that you are trying to start did not start successfully. Please try again.

I tried again many times and the code is still the same.

Could you please tell me what should I do to proceed?

Hi @jacob281, thanks for using the dev forum.

Can you please provide some additional context around how you’re trying to join the session? At a minimum, we would need the JWT you’re passing into the SDK, the session name, and the version of the SDK you’re using.

Thanks!

Hi.
I am running exactly the demo app as is, without any modifications: zoom-video-sdk-windows-1.2.2\Sample-Libs\x86\demo\videosdk_demo\videosdk_demo.sln.

SDK version is v1.2.2 (1185), as shown in the file zoom-video-sdk-windows-1.2.2\version.txt.

Session name is s1.

Token:
eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJhcHBfa2V5IjoiOVJWdVNGZk5QamNhT3VMVjk2Zk5sbjZRVkUxREEzOElKMEFxIiwidmVyc2lvbiI6MSwicm9sZV90eXBlIjowLCJpYXQiOjE2NDgwNjc4MzAsImV4cCI6MTY0ODE1NDIzMCwidHBjIjoiczEifQ.iYzaMUfxnJon5j7Onn88NghnwqP517nGAr6TlvdJ-eQ

Thank you.

Hi @jacob281,

Thanks for the additional information. You are seeing this error due to the role_type field being set to 0. Currently, if you try joining a session as a regular participant, it will fail unless the host has already started the session. If you change the role_type value to 1, you should be able to start the session.

It is also worth noting that the SDK’s behavior will change in a future release to allow regular participants to join sessions before the host has started them.

Thanks!

Thank you very much.
I changed role_type to 1 and it worked.

You’re welcome, glad to hear that fixed it!

Please don’t hesitate to reach back out in a new topic with any additional questions. :slightly_smiling_face: