Skip to content

olxver2025/Koil

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

Koil Bot

A Nextcord (Discord) bot to manage and send pre-created FAQ snippets ("koils"). Moderators can add, view, delete, and send short messages that answer common questions.

Features

  • Manage reusable FAQ messages per server (SQLite-backed).
  • Send by ID or by exact name.
  • Clean, consistent embed responses for all actions.
  • Moderator-only controls using Manage Messages permission.

Setup

  • Python 3.10+
  • Install deps: pip install nextcord python-dotenv
  • Create .env:
    • DISCORD_TOKEN=your-bot-token
  • Run locally: python bot.py

Discord App Notes

  • Add the bot to your server with the bot scope and permissions to send messages and use slash commands.
  • Message Content intent is enabled in code; ensure it is toggled on in the Developer Portal if required for your use case.
  • Slash command updates can take a minute to propagate after startup.

Commands

  • /koil help: Show help for all koil commands.
  • /koil add name:<text> description:<text>: Create a koil. Limits: name ≤ 50 chars, description ≤ 100 chars. (mods)
  • /koil view: List all koils in this server (ephemeral). (mods)
  • /koil delete koil_id:<id>: Delete a koil by ID. (mods)
  • /koil send query:<id or name>: Send a koil to the channel by ID or exact name. (mods)
  • /ping: Show bot latency (ephemeral).

Permissions

  • By default, the entire /koil command group requires the Manage Messages permission (moderators).
  • To allow broader access (e.g., everyone can use /koil send), remove the @application_checks.has_permissions(manage_messages=True) decorator from that subcommand in bot.py.

Data Storage

  • SQLite database file: koils.db (created automatically).
  • Table: koils(id TEXT PRIMARY KEY, name TEXT, description TEXT, servID INTEGER).
  • Koils are namespaced per server via servID.

Tips

  • Use /koil view to copy IDs for /koil send or /koil delete.
  • If /koil send finds multiple exact-name matches, it asks you to use a specific ID.

About

Easily manage your tickets with pre-written FAQ messages.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages