sabi / lain

Make posts as a bot on Discord. Great for server announcements! Or script system outputs to Discord.

Home Page:https://sabisimple.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Lain

Sabi. Simple, Lightweight, but Not Beautiful.

Overview

  • Lain is a Linux command line utility that allows you to script messages to Discord.

Setup

  • Effortless install: sudo apt update && sudo apt install -y python3 python3-pip wget && pip3 install requests && wget https://raw.githubusercontent.com/sabi/lain/main/lain.py && python3 lain.py

  • python3 lain.py

  • Add webhooks to ~/.config/sabi/lain/webhooks.conf in the format:

    • channel-name = https://discord.com/api/123/123

Usage

  • Send a message
    • lain <channel> -msg <Replace with message>
    • lain friends -msg Let's love Lain!
  • Send an image
    • lain <channel> -img </path/to/image>
    • lain friends -img /home/lain/Pictures/selfie.jpg

How to create a Discord webhook

  • Open your Server Settings, then go to Integrations image

  • Create a new webhook for the appropriate channel, then copy the webhook to clipboard image

  • Finally add the webhook to ~/.config/sabi/lain/webhooks.conf in the format:

    • channel-name = https://discord.com/api/123/123

About

Make posts as a bot on Discord. Great for server announcements! Or script system outputs to Discord.

https://sabisimple.com/

License:MIT License


Languages

Language:Python 100.0%