Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERR_ZOOM_INITIALIZATION when ininitialize and joinMeeting not return anything #321

Open
lamlengend98 opened this issue Nov 21, 2023 · 5 comments

Comments

@lamlengend98
Copy link

Hi, as the title, after initializing i got ERR_ZOOM_INITIALIZATION, when I call init again I got the successfully, and then I call join meeting I did not get any error or log or something like this. I don't know what is happening

react-native-zoom-us@^6.18.1
[email protected]


  const initialize = async () => {
    try {
      if (!isInitialized) {
        const signature = sign(
          {
            sdkKey: Config.CLIENT_ID,
            iat: moment().unix(),
            exp: moment().add(2, "hour").unix(),
            mn: meetingId,
            role: "0",
          },
          Config.CLIENT_SECRET,
          { alg: "HS256" }
        );
        console.log("Config.CLIENT_ID", Config.CLIENT_ID);
        console.log("Config.CLIENT_SECRET", Config.CLIENT_SECRET);
        console.log(
          "🚀 ~ file: index.tsx:32 ~ initialize ~ signature:",
          signature
        );
        const result = await ZoomUs.initialize({
          clientKey: Config.CLIENT_ID ?? "",
          clientSecret: Config.CLIENT_SECRET ?? "",
        });
        console.log("🚀 ~ file: index.tsx:53 ~ initialize ~ result:", result);

        if (result.includes("successfully")) {
          dispatch(
            setIsInitialized({
              isInitialized: true,
            })
          );

          dispatch(
            setJwtToken({
              jwtToken: signature,
            })
          );
        }
      }
    } catch (error) {
      console.log("error", error);
    }
  };
  const joinMeeting = async (signature: string) => {
    try {
      // Join Meeting
      console.log("join", meetingId);
      await ZoomUs.joinMeeting({
        userName: userInfo.name,
        meetingNumber: meetingId,
        autoConnectAudio: true,
        zoomAccessToken: signature,
        noMeetingErrorMessage: true, // Set this to be able to show Alert.alert
      });
    } catch (error) {
      console.error("error", error);
    }
  };
image
@mieszko4
Copy link
Owner

Could you try with [email protected]? Note that you will need to use jwtToken because clientKey/clientSecret have been removed.

@yoonpyaepyaenyein
Copy link

Could you try with [email protected]? Note that you will need to use jwtToken because clientKey/clientSecret have been removed.

How can I get jwtToken .

@mieszko4
Copy link
Owner

See react-native-zoom-us-test for inspiration.

@princetoad1995
Copy link

@mieszko4
I'm using [email protected] and I tried to use react-native-pure-jwt for generating jwt code, but it still display this issue
Screenshot 2024-02-17 at 03 00 38

@mieszko4
Copy link
Owner

mieszko4 commented Sep 1, 2024

Yeah, this process is a bit confusing. Maybe this official doc will help you? https://developers.zoom.us/docs/meeting-sdk/auth/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants