Skip to content

1. Setting up your bot

rainy w/rain edited this page May 8, 2024 · 10 revisions

πŸŽ›οΈ Setting up enviroment

1. You need to download this tool below (some is optional):

2. Next, you need to register a database (If you don't want to use connection db or already have installed MongoDB or MySQL above, skip this step)

πŸ’Ύ Database (If you nether use MongoDB nor MySQL, skip this step)

πŸƒ MongoDB

-------------------- Local --------------------

  • After you install MongoDB, open MongoDBCompass
  • Click on Save and Connect
  • Give it a name
  • After that, you copy the connection string (you will need this later)

-------------------- MongoDB Atlas --------------------

  • After done every register, go to network access
  • Click Add IP address
  • In Access List Entry field, add this IP address 0.0.0.0/0 (This will allow connect to every devices. If you don't want, you can skip this step or add your devices IP)
  • After that, click on Save
  • Then, click back to Overview
  • Now, click on Connect button
  • In here, click on Drivers button
  • Scroll down and copy the connection string (Note: Replace <password> with your user password, do not include <>)
  • After you copy the connection string, save it for later. You will need this later

🐬 MySQL

-------------------- Local --------------------

  • After you install MySQL, go to cmd
  • Type: mysql -u root -p
  • Type your password
  • After that, use this command to create your database: CREATE DATABASE <your_db_name>; (Note: Replace <your_db_name> with your name whatever you want, do not include <>)
  • Then, save the db name for use later

-------------------- www.freemysqlhosting.net --------------------

  • After done every register, go to MySQL Hosting
  • Follow their introduction and click Complete my registration
  • Click Start new database (This will take a while for their setting up)
  • If you follow correctly, they will send your email with their credentials
  • Save that for later use.

πŸ› οΈ Config and run bot

  1. Extract ByteBlaze Binary that you've downloaded
  2. Now, config the app.yml file. File example avalible here

If you want to use environment variables from .env file, you can use the ${} in app.yml file.

Examples:

NODE_AUTH=foo
bar: ${NODE_AUTH}

Output: { bar: foo }

  1. After that, save your app.yml in your bot dir
  2. Now, click on Start.bat file if you're using Windows (you can type ./Start.bat in cmd windows also) or type sh ./start.sh if you're using Mac/Linux to run your bot