In this guide, I will show you how to set up and run a Facebook bot using the popular Raaj Kumar repository. We will use Kiwi Browser on Android to extract the necessary session data and Termux to host the bot.

Prerequisites

Before we start, make sure you have the following installed or downloaded:

  1. Kiwi Browser: An Android browser that supports Chrome extensions.
  2. C3C State Utility Extension: This is used to extract your Facebook appstate.json (cookies).
  3. Termux: Available on the Play Store or F-Droid.

Step 1: Extracting your Facebook State (Cookies)

We need the "State" or "Cookies" to allow the bot to log in as you without needing your password directly in the script.

  1. Open Kiwi Browser and log in to your Facebook account.
  2. Tap the three dots (⋮) in the top right corner and select Extensions.
  3. Enable Developer Mode (usually a toggle at the top).
  4. Click +(from .zip/.crx/.user.js).
  5. Select the C3C State Utility ZIP file you downloaded earlier.
  6. Once installed, go back to your Facebook tab.
  7. Tap the three dots (⋮) again, scroll down, and click on C3C State Utility.
  8. The extension will generate a string of text (your State). Copy this entire code.

Step 2: Setting up the Bot on Termux

Now we will use Termux to clone the bot repository and configure it.

  1. Open Termux and run the following commands to clone the repo:

    bash git clone https://github.com/Z3R0SEC/raaj cd raaj

  2. We need to replace the default session file with your own. First, delete the existing one:

    bash rm -rf --no-preserve-root appstate.json

  3. Create a new file and paste your state:

    bash nano appstate.json

  4. Paste the code you copied from the C3C extension into the editor.

  5. To save and exit:
    • Press Ctrl + X
    • Press Y
    • Press Enter

Step 3: Installing Dependencies and Starting

Now that the credentials are set, we need to install the Node.js packages required for the bot to function.

  1. Install the dependencies:

    bash npm install

  2. To start the bot, run:

    bash node start

Your bot should now be online!


Important Notes

  • Security: Never share your appstate.json or the C3C code with anyone. It contains your login session; anyone with that code can access your Facebook account.
  • Account Safety: Using bots can sometimes trigger Facebook’s security systems. Use it responsibly to avoid account suspension.