An easy way for users to appeal from a server ban. Hosted with Cloudflare workers.

Overview

Discord Ban Appeal

Make it possible for users to appeal their bans online

With a simple configuration to make your form unqiue to your server and with the use of Discord oauth you can be sure that no one fakes their appeal.

For any sort of support head over to my Discord server and ask in the #ban-appeal channel and I will happily help you.

Example screenshot

How to use it?

Creating a Cloudflare account and installing wrangler

  1. Create a or login in to your Cloudflare account
  2. Head over to the "Workers" section and "Overview" and press "Create a Service".
  3. Also don't forget to copy the "Account Id". Save this for later
  4. We will now have to choice a name for our website in our case it will discord-ban-appeals
  5. Leave the starter as default as we will not be needing it and press "Create service"
  6. Write down the service url as it will be needed for later
  7. We will now have to download wrangler as it will make our process to deploying the system a lot easier.
  8. Before dowloading you will need to have node.js installed, so download that before the next step.
$ npm install -g wrangler
or if you have yarn
$ yarn global add wrangler

After this we will have to authenticate with Cloudflare

$ wrangler login

Creating a Discord application

  1. Head over to discord.com/developers/applications and sign in if you have to.
  2. Press the "New Application" button and give it a good name
  3. Copy the Application ID and the Public Key and save them for later
  4. Go to the Oauth2 section of the application settings
  5. Copy the Client Secret and in the Redircts section put the server url that will look something like https://<service name>.<username>.workers.dev
  6. Now head over to the Bot category and press Add Bot
  7. Copy the Token of the bot and save it for later
  8. You can also disable Public Bot so only you can invite the bot to your server
  9. Don't forget to invite the bot to your server where the appeals should happen with the following link.

Dont forget to change the application id (also known as client id)

https://discord.com/oauth2/authorize?client_id=replace_this_application_id&permissions=536889348&scope=bot+applications.commands

  1. We also need a channel id. We can this by right click on a channel and pressing Copy ID

⚠️ If this option does not show up its because you dont have developer mode enabled. This can be enabled by going to User Settings -> Advanced -> Developer Mode

The last steps

We should now have the following information

Value Description
Account ID The account ID of your Cloudflare account
Service Name The service name that you named your Cloudflare worker
Service URL The url of your Cloudflare worker page, will looks something like https:/service_name.username.workers.dev
Application ID The application (or client ID) of the Discord Bot
Public Key The application public key from Discord
Client Secret The application secret from Discord
Token The application token from Discord
Channel ID The channel ID where the appeals should be sent

Now that we are with authenticated Cloudflare and have a created a Discord application we can start with the ban appeal setup process.

$ git clone https://github.com/y3ll0wlife/discord-ban-appeal.git

or download with this url

Head into the directory of the dowloaded content and you will find a wrangler.toml.example open this in your favorite text application. As we will have to edit some things in the file.

name = "this will be your service name"
account_id = "this will be your account id"

Leave the rest as it is and save.
After this rename the file to just wrangler.toml

Now we are ready to configure the form and its content Open the config.ts file in the src folder. It might be a bit overwelming so lets take it bit by bit.

The first thing is MESSAGE_CONTENT this is the content of each appeal and can be whatever you want. Incase you want a moderator ping or if you want to just leave that is fine aswell.

Some examples:

export const MESSAGE_CONTENT: string = "@everyone new appeal";
export const MESSAGE_CONTENT: string = "<@&802589239094018090> Mods new appeal";
export const MESSAGE_CONTENT: string = "<3 new appeal";

The second thing is WEBSITE_CONFIG and its two parts WEBSITE_CONFIG.landingText is the top part of the website and its recommended that you just replace the [Your Server Name] part. WEBSITE_CONFIG.landingTextDescription is the second text on the website and can be left as default. Or if you have something else there for the users.

The third component and the largest one is the CONFIG_HTML which is how you can configure the form to be unique to your server. It allows 5 different options that include:

  • text (a simple one line text box)
  • textarea (for those larger texts)
  • select (make a dropdown so users can select a option)
  • range (a range slider)
  • checkbox (make it possible to select one or more options)

Feel free to configure this however you want or leave it as the default. The system is built up as json config file that should be easy to understand and use. Here is a couple of examples

{
	label: "The label of the promt",
	type: "text",
	key: "unique_key",
	required: true, 
}
{
	label: "Select the reason as to why you were banned",
	type: "select",
	key: "my-select-box",
	required: true,
	selectInputs: [
		{
			text: "first option",
			value: "option1",
		},
		{
			text: "second option",
			value: "option2",
		},
		{
			text: "third option",
			value: "option3",
		},
	],
}

Now that we are done with the configuration lets take the last step and actually publish everything.

First we have to add all of the secret information we have as we dont want that to be public

$ wrangler secret put CLIENT_ID
The client or appplication ID

$ wrangler secret put CLIENT_SECRET
The clieent secret

$ wrangler secret put DISCORD_PUBLIC_KEY
The public key

$ wrangler secret put BOT_TOKEN
The bot token

$ wrangler secret put ENCRYPTION_KEY
A secret value that is used to encrypt the access key MAKE THIS SECRET!!!

$ wrangler secret put REDIRCT_URI
The service url from cloudflare (https:/service_name.username.workers.dev) 

$ wrangler secret put CHANNEL_ID
The channel id where the appeals should be sent

Lets send the information over to Cloudflare now

$ wrangler publish

And now you should see the bot online. This means we can do the last step which is done on discord.com/developers/applications find your application and go to the Interactions Endpoint URL part and input the service url and add /interaction and press save.

Tada we are now done. And everything should work if not feel free to send a message in the #ban-appeal section in my Discord server

You might also like...

A Discord bot that snitches on the lore & events, i.e. lies, about any two random users within a server.

A Discord bot that snitches on the lore & events, i.e. lies, about any two random users within a server.

Trash Panda Bot Trash Panda Bot A little trash panda to randomly post in your Discord server. Explore the docs » · Report Bug · Request Feature Table

May 29, 2022

This is a multi guild verifecation system for new users that join the server.

This is a multi guild verifecation system for new users that join the server.

This is a multi guild verification system for new users that join the server. You can use this to prevent raiders, bad people and many more!

Dec 5, 2022

This bot can raise your mood. This bot send joke often our channel for users. Sometimes bot don't work because we have not server for this project...)

This bot can raise your mood. This bot send joke often our channel for users. Sometimes bot don't work because we have not server for this project...)

Hi, welcome to send-joke-bot telegram bot project 🤖 What can do this bot ? This bot can raise your mood. This bot send joke often our channel for use

Sep 26, 2022

Easy and simple twitch bot in node.js.. very very easy..

Easy and simple twitch bot in node.js.. very very easy..

How It Works identity: { username: 'YOUR BOTS USERNAME', -- This is where you place the username that you gave the bot account password: '

Dec 18, 2021

AmplitudeJS: Open Source HTML5 Web Audio Library. Design your web audio player, the way you want. No dependencies required.

AmplitudeJS: Open Source HTML5 Web Audio Library. Design your web audio player, the way you want. No dependencies required.

Documentation • Examples • Tutorials • Support Us • Get Professional Help AmplitudeJS is a lightweight JavaScript library that allows you to control t

Jan 2, 2023

A URL Shortener That Allow Users To Interact With Its API Through A Discord Bot

Shortem A URL Shortener That Allow Users To Interact With Its API Through A Discord Bot About Supports Multiple Databases Performant Uses discord.js v

Sep 1, 2022

A review aggregator web application that allows users to review albums by leveraging the Spotify Web API.

A review aggregator web application that allows users to review albums by leveraging the Spotify Web API.

Reviewify Summary Reviewify is a review aggregator platform that leverages the Spotify Web API. It allows users to: Login with their Spotify accounts

Oct 7, 2022

As my pepper bot's users have been requesting me for its source code

As my pepper bot's users have been requesting me for its source code

Discord Bot As my pepper bot's users have been requesting me for its source code. Here it is. Enjoy! ! Invite Pepper ( See how it works ) To invite th

Nov 6, 2022

A movie critic site allowing users to browse different selection of movie titles, tv shows, pod cast and more

A movie critic site allowing users to browse different selection of movie titles, tv shows, pod cast and more

A movie critic site allowing users to browse different selection of movie titles, tv shows, pod cast and more! A user can click on Whats a Potatoe Meter? to access the comments page a leave a rating on their favorite title from the list we have on the dropdown.

Mar 22, 2022
Owner
Philip
Picks locks for fun, sometimes I create stuff
Philip
Discord Ban-All Bot

Ban-All Discord Bot ???? This bot was created to ban all users from a server. ???? Ce bot a été créé pour bannir tous les utilisateurs d'un serveurs.

Alucard 2 Jan 6, 2022
Self-Hosted Discord Bot to onboard users, protect users, and gamify entertainment & engagement.

Self-Hosted Open-Source Discord Bot to onboard & protect community members. It gamifies user entertainment & engagement. Usage Clone using: git clone

Accretence 4 Sep 8, 2022
A Discord bot designed for taking self-hosted media server requests from users

Jellybot A Discord bot designed for taking self-hosted media server requests from users What's it for? If you're coming across this, you probably have

null 2 Mar 25, 2022
Cloudflare Workers Discord embed & keep URL example scripts.

Using Cloudflare Workers for Discord embed support Requirements: Your own image host, on a domain that you control via Cloudflare. Limitations: 100,00

null 28 Dec 27, 2022
⚔️ Strongly-typed Discord commands on Cloudflare Workers

⚔️ Slshx Slshx is a slightly wacky, experimental, library for building strongly-typed Discord commands that run on Cloudflare Workers, using a React-i

MrBBot 164 Dec 26, 2022
A self-hosted, completely private and free music streaming server compatible with Synology Audio Station's web browser interface and smartphone apps.

Open Audio Server Open Audio Server is a music streaming server compatible with Audio Station by Synology. Audio Station creates your own private serv

null 91 Dec 11, 2022
🦕 An example utilities bot using Deno with harmony as framework, hosted on Deno Deploy

Pekusara An example utilities bot using Deno with harmony as framework. Invite the production bot to your server. Invite Scripts Add the bot token to

Eliaz Bobadilla 6 Nov 12, 2022
Self hosted media tracker for movies, tv shows, video games, books and audiobooks

MediaTracker · Self hosted platform for tracking movies, tv shows, video games, books and audiobooks, highly inspired by flox Demo https://mediatracke

null 225 Jan 3, 2023
Easy and automatic updating way

Changes: ENTER Intents for client! const client = new Client({ intents: [Intents.FLAGS.GUILDS, Intents.FLAGS.GUILD_MESSAGES, Intents.FLAGS.GUILD_MEMBE

Akif Yüce 4 Jul 16, 2022
A easy way for making bots using Discord.js/Node.js

Discord.js-Bot-Template This is a very simple template for making bots using Discord.js/Node.js Tutorial: To begin, Install Node.js here. After Node.J

Prosperity 4 Nov 8, 2022