whatsapp_bot_platform_interface library

Extensions

JsParser on dynamic
Use JsParse extension on data we pass in Javascript string

Functions

getMimeType(WhatsappFileType fileType) String
getMimeType returns default mimeType
parsePhone(String phone) String
_parsePhone will try to convert phone number in required format
validateConnection(WpClientInterface wpClient) Future
waitForLogin(WpClientInterface wpClient, {required dynamic onQrCode(String qrCodeUrl, Uint8List? qrCodeImage)?, int waitDurationSeconds = 60, dynamic onConnectionEvent(ConnectionEvent)?}) Future
waitForLogin will either complete with successful login or failed with timeout exception this method will automatically try to get the qrCode also it will make sure that we get the latest qrCode

Typedefs

OnNewEventFromListener = dynamic Function(String eventName, dynamic eventData)
Interface for creating a Whatsapp Client

Exceptions / Errors

WhatsappException