Jump to content

Personified Vengeance

Newbie
  • Posts

    3
  • Joined

  • Last visited

Profile Information

  • Language
    English
  • Software
    Invision
  • Version
    4.1

Recent Profile Visitors

642 profile views

Personified Vengeance's Achievements

Rookie

Rookie (2/14)

  • First Post
  • Week One Done
  • One Month Later
  • One Year In
  • Conversation Starter Rare

Recent Badges

2

Reputation

  1. I received an updated copy from the developer who said he was no longer going to work on this project so if anyone wants to take over feel free to. The main post will be updated to reflect these changes
  2. Sorry about the delay, took me longer than I'd like to admit to find the original source again. The github link is Shiroyuki Discord to IPB Bot
  3. Wasn't too sure if this is the right section, but this is where I felt it was most appropriate from the forum titles I could see. I in no way claim to own this as I just found it on a small forum and thought others may find it useful. I have edited the Read Me below to contain more up to date and relevant information. Thread is now updated to reflect the new changes I've been given Shiroyuki JavaScript IPB to Discord Bot. Summary: This is a JavaScript bot developed using Node.JS which connects to discord via the Eris library. This bot uses REST API to grab information like the latest threads, posts, and users from Invision Power Boards. This is only a basic bot and as such can only post latest threads, authors, and posts but I will be expanding it in future to include many other useful things. Features Uses REST API to grab Latest Thread Uses REST API to grab Latest Post Uses REST API to grab username of aforementioned things, and posts it in discord. URL Shortener (using https://goo.gl/) Syncing usernames on Discord with IPB Usernames (done via profile field on forums) To be implemented: automatic syncing of names. Installation Download LTS Version of NodeJS from NodeJS Download files. Setup your REST API. Setup Wamp or Xampp server as this new version uses MySQL (if you're not running this on your webhost) Open bot.js in your favorite editor eg Notepad++, Sublime, Atom etc. Edit the following sections and replace them with your own information. Setting up REST API Go to your Admin Control Panel -> System -> Underneath Site Features click "REST API" -> Create New and make it according to the image below. In regards to "Posts" Do the same as Topics with 4 Endpoints for it to gather information from. I just couldn't crop it out nicely and added this text as a result. Setting up the bot: Prerequisite Modules: open CMD and navigate to the directory of your bot. And type the following command(s) in: npm install eris && npm install goo.gl && npm install mysql && npm install request Now Replace in (bot.js): let erisAPI = "replace with your discord bot token"; //only replace the part in quotation marks. with your own token which can be gotten from ---> Discord Developers <--- Setting up Back end of Bot: Step 1: Go to http://127.0.0.1/phpmyadmin and log into your mysql database. Step 2: Create a database called ipb then import the SQL file in the zipped folder. Step 3: Go into the Config Table Step 4: Copy this code into your code editor and replace the information as needed INSERT INTO `config` (`googlAPI`, `erisAPI`, `ipbAPI`, `domain`, `botPrefix`, `postMessage`, `threadMessage`, `activityChannel`, `admins`, `welcomeChannel`, `autoRoleEnabled`, `roleId`) VALUES ('replace goo.gl api here', 'put discord bot token here', 'put ipb rest api here', 'your domain here', '!', 'your new post message here', 'your new thread message here', 'channel ID where bot posts about new threads and posts', 'admin id (your discord id)', 'Place where bot welcomes new members', '1 for yes 0 for no', 'member role id') Step 5: Go back to your PHPMyAdmin and click SQL Step 6: Paste your version of the code that you made in step 4 Step 7: Press Go. Step 8: Done. Running the bot: Step 1: Open command prompt. Step 2: Go to the location of the bot eg C:\Users\YourUsername\Desktop\IPB_to_Discord in command prompt via the CD command or just go to the folder normally press shift and right click and open it that way. (Assuming windows 7 windows 10 users will have to do it the long way) Step 3: type node bot.js Step 4: Congratulations your bot should now post something like the image below. Some of the text was removed for security, and because I felt like removing it. Issues: At the current time: NONE Download: IPB_to_Discord.rar
×
×
  • Create New...