UBS/README.md

2.8 KiB

RTECH Unified Ban System

The UBS Project is brought to you by the RTECH Development Team. This project aims to solve a simple but crucial problem: managing bans across roblox and discord. And making it easy to impliment, to keep communities safe.

Join the RTECH Discord!

Server Status

UBS Status UBS Uptime UBS Response Time

Features

  • MariaDB database for storing ban data
  • REST API for querying bans
  • Web interface for querying bans
  • Admin web interface for managing bans
  • Mass import of bans
  • Mass export of bans
  • Ban appeal system
  • Ban appeal system admin interface
  • Discord integrations (Notifications, Appeals, Querying)

API Documentation

🔓 Unauthenticated Endpoints

GET /health - Healthcheck endpoint (For Uptime Kuma)

GET /v1/myIP - Get your IP address (As seen by the server. Useful for debugging)

GET /v1/info - Get information about the API (Version, All reason flags)

GET /api/v1/bans - Get all bans

GET /api/v1/ban/roblox/:robloxId - Get bans by Roblox ID

GET /api/v1/ban/discord/:discordId - Get bans by Discord ID

🔒 Authenticated Endpoints

GET /admin - Renders the admin dashboard.

GET /admin/edit/:id - Renders the edit ban page for a specific ban.

GET /admin/create - Renders the create ban page.

POST /admin/create - Creates a new ban.
Post Data:

{
	"robloxId": "string",
	"discordId": "string",
	"reason": "string",
	"duration": "number"
}

POST /admin/edit/:id - Edits an existing ban.
Post Data:

{
	"reason": "string",
	"duration": "number"
}

GET /admin/import - Renders the import page for uploading ban data.

POST /admin/import - Handles the import of ban data from a file.
Post Data:

  • fileInput: File upload (CSV format)
  • fileType: Type of the file being uploaded (e.g., 'csv', 'mfd')

GET /admin/uploadStatus - Renders the upload status page.

GET /admin/api/bans - Retrieves all bans.

GET /admin/api/uploads/:id - Retrieves the status of a specific upload.

GET /admin/api/uploads - Retrieves the status of all uploads.

GET /admin/login - Renders the admin login page.

POST /admin/login - Handles admin login.
Post Data:

{
	"username": "string",
	"password": "string",
	"totp": "string"
}

ALL /admin/logout - Logs out the admin.