zoho / SalesIQ-Mobilisten-ReactNative

Your mobile app's ideal live chat partner. Power up your mobile App with the SalesIQ Mobilisten SDK for React-Native.
https://mobilisten.io/
8 stars 12 forks source link

How can I Implement Android and iOS with the same app key and different access key. #44

Closed hrajaei76 closed 2 years ago

hrajaei76 commented 2 years ago

hey, I have a problem.

can the iOS bundle Id be the same as the Android bundle Id? In this case, we have the same app key for the ios and the android!

I did this and only iOS works.

bhahirathan-mb-11956 commented 2 years ago

Hi @hrajaei76,

Thank you for writing us. Yes, the bundle ID can be same for both iOS and Android. However, the access key differs please verify before providing them.

To know more about installation steps for Mobilisten react-native, please visit our help guide here.

Best regards, Bhahirathan

hrajaei76 commented 2 years ago

Hey, dear @DavidBhahirathan Thank you very much.

I've implemented "react-native-zohosalesiq-mobilisten": "4.2.9" on "react-native": "0.67.1".

Although It works very well on iOS, The ZohoSalesIQ.initWithCallback get failed on Android.

ZohoSalesIQ.initWithCallback(
    appKey,
    accessKey,
    (success: boolean) => {
      if (success) {
        ZohoSalesIQ.setLauncherVisibility(true);
      } else {
          console.log('Failed to initialize Zoho SalesIQ');        
      }
    },
  );
bhahirathan-mb-11956 commented 2 years ago

Hi @hrajaei76,

Thank you for writing us. Please verify that whether have you've used the below code snippet for initialisation.

var appKey;
var accessKey;

if (Platform.OS === 'ios') {
    appKey = "ios_appKey";
    accessKey = "ios_accessKey";
} else {
    appKey = "android_appKey";
    accessKey = "android_accessKey";
}

ZohoSalesIQ.initWithCallback(appKey, accessKey, ...)

If not please try this. Write us at [support@zohosalesiq.com] along with the Github issue ID for further assistance.

Have a nice day!

Best regards, Bhahirathan Zoho SalesIQ