Skip to content

pieartsy/CreatiBot

Repository files navigation

CreatiBot

A Discord bot that generates random palettes. It used to generate random prompts before Reddit's API guidelines and verification process got a helluva lot stricter!

For palette generation, it uses colormind.io's API, thecolorapi.com, and Pillow to create palettes and send them to the channel you've typed the command into.

It also used reddit's API for the random prompts.

  • $palette to generate a random palette from colormind.io
  • $prompt to get a random prompt (out of the newest 50) from r/writingprompts

Palette process

  1. User types $palette into the discord channel.
  2. Creatibot gets a color palette from colormind.io. I am using this website because I want aesthetically pleasing palettes rather than literally random colors. This only returns the RGB values, however, and we need to make it into an image!
  3. Creatibot asks thecolorapi.com for SVG (vector) images using the RGB values from before. This gives me a color and its name.
  4. Creatibot converts the SVG to a .png image using svglib.
  5. Creatibot stitches the five .png images together using Pillow, and sends the palette to the channel.

This process takes a few seconds!

Prompt process [removed]

This one was far quicker and simpler. When the user types $prompt, all it does is make a list out of the newest 50 writing prompts from r/writingprompts and sends one of them to the channel.

About

discord bot that generates random palettes

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published