/wabot

Chat Bot

Primary LanguageJavaScript

Wabot Chrome Extension

Bot under development. Check out the Wiki for more information. Join the Discord at https://discord.gg/C7Txwmd for discussion

How it Works?

This extension has two main parts.

  • A background script containing the core logic of the bot waiting for incoming messages.
  • An injected script to process incoming messages.

The reason for the two separate scripts is due to the limited access different parts of the Chrome extensions have. This is explained further in the Wiki.

Goal

The main goal of this chat bot is to simply augment the user experience by developing additional functionality that is otherwise not provided. These features include autodownloading media, sport events tracker, games, and commands. Ultimately the aim is to eventually make this chat bot obsolete as the platform adds features to make it redundant.

Roadmap

  • Refactor majority of the code, priority is files in /web/.
    • Move repeated code to helper.js to minimise duplication.
    • Minimise dependencies.

     + Explore switching to something like Typescript to stay sane

  • Finalise applications feature to allow for functionality too complex for a one line command.
  • Look into separating the core of the chat bot into a local application and keep the chrome extension to send / receive messages.
  • Develop Wiki page to document the design of the extension.
    • This is an ongoing activity, and when redundancy is found, the changes are made to the code.

How to run

  • Clone the repository
  • Create config.js under the lib folder and follow the same format as config_example.js
  • Run the following:
npm install --save
webpack

This will install the dependencies and also build background.js which is required by the chrome extension. Afterwards, load the directory as an unpacked extension.

Todo

  • [ ] Add support for YouTube videos/ Streamable / Oddshot / Instagram
  • [ ] Add more games
  • [ ] Extension UI for easier configuration
  • [ ] Better logging

Terms and conditions

You will NOT use this API for marketing purposes (spam, etc.).

Legal

This code is in no way affiliated with, authorized, maintained, sponsored or endorsed by WhatsApp or any of its affiliates or subsidiaries. This is an independent and unofficial application. Use at your own risk.

Cryptography Notice

This distribution includes cryptographic software. The country in which you currently reside may have restrictions on the import, possession, use, and/or re-export to another country, of encryption software. BEFORE using any encryption software, please check your country’s laws, regulations and policies concerning the import, possession, or use, and re-export of encryption software, to see if this is permitted. See http://www.wassenaar.org/ for more information.

The U.S. Government Department of Commerce, Bureau of Industry and Security (BIS), has classified this software as Export Commodity Control Number (ECCN) 5D002.C.1, which includes information security software using or performing cryptographic functions with asymmetric algorithms. The form and manner of this distribution makes it eligible for export under the License Exception ENC Technology Software Unrestricted (TSU) exception (see the BIS Export Administration Regulations, Section 740.13) for both object code and source code.