We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I created a new method to call from cordova based on android sdk:
//Android Sdk HuggyChat huggyChat = HuggyChat.getInstance(this.SDK_ID, YourChatActivity.this).setUpWebView(yourWebView); // Send message to chat huggyChat.callApiMethod("sendMessage", "Minha primeira mensagem");
//New Method for cordova public void callApiMethod(String methodName, String data, CallbackContext callbackContext) { try { HuggyChat.getInstance().callApiMethod(methodName, data); callbackContext.success(); } catch (Exception e) { callbackContext.error(e.getMessage()); } }
It's called after chat opened.
But doesnt work. The callApiMethod is receiving the data normally and the instance exists in debug, but it doesn't execute the method.
Example:
window.cordova.plugins.huggychat.openHuggyChat( "SKD-KEY", "Huggy Chat", (success) => { console.log('openHuggyChatSuccess', success); //It's logging setTimeout(() => { window.cordova.plugins.huggychat.callApiMethod('sendMessage', 'Minha primeira mensagem', (success) => { console.log('callApiMethodSuccess', success); //It's Logging }, (error) => { console.error('callApiMethodError', error); } ) }, 10000)}, (error) => { console.error('openHuggyChatError', error); } );
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I created a new method to call from cordova based on android sdk:
It's called after chat opened.
But doesnt work. The callApiMethod is receiving the data normally and the instance exists in debug, but it doesn't execute the method.
Example:
The text was updated successfully, but these errors were encountered: