GithubHelp home page GithubHelp logo

bahaminshahriari / referobot Goto Github PK

View Code? Open in Web Editor NEW

This project forked from alesslas/referobot

0.0 0.0 0.0 102 KB

Referral bot created for referral-based Discord servers. Uses Node/Express, Discord.js, ES6/Babel

JavaScript 100.00%

referobot's Introduction

Referobot

A referral bot, great for referral-based Discord servers. Currently, the only way to use it is to self-host, but I may consider hosting the bot at a later time. See installation and usage for self-hosting directions.

Commands

  • Admin = "Administrator" permission
  • Mod = "Manage Roles" permission
Command Description Permissions
help sends a list of all commands to the channel everyone
invites displays number of invites and number left until next role everyone
top <#> displays top <#> of inviters everyone
membercount displays total number of server members everyone
set <channel-name> set a specific channel for a bot to prevent spam admin
set default allow all channels to use the bot admin

Referobot also automatically updates user's roles.

Installation

  1. Download or clone this repo's files.
  2. cd into the Referobot directory.
  3. Run npm install to install dependencies.
  4. Run npm run build to build.
  5. Add your bot token to your_auth.json.
  6. Rename your_auth.json to auth.json.
  7. Run node lib/referobot.js.1

Usage

  1. Create a bot user and generate a token here and invite this bot to your server using its Client ID. The link should look like this: https://discordapp.com/oauth2/authorize?&client_id=YOUR_CLIENT_ID&scope=bot&permissions=268435464.
  2. Make sure your Referobot has the Manage Roles permission in your server. If for some reason this does not work, move the Referobot's role above all other user roles.
  3. To customize roles and role invite number thresholds, go to the roles.json file in the root Referobot directory. Fill in the roles and the invites required for those roles. You can customize up to six roles. Role names are case-sensitive. Make sure the role names you type exactly match the role names from your server.2

Invites Example

Footnotes

  1. If you need 24/7 hosting, you may need a VPS.
  2. For now, if you have more than six roles, any roles beyond six will not work. If you have less than six roles, fill in only the last roles and leave the other values at 0. For example, if I had four referral roles, I would customize as follows: {'RankOne': 0, 'RankTwo': 0, 'MyCustomRank': 6, ...}.

referobot's People

Contributors

brendacs avatar alesslas avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.