Google Image Search bot for Slack
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.

For centuries, people have wondered: "What's the fastest way to get a JPEG into a Slack channel?" Scientists now believe that jpgtobot is the answer. To verify these findings, please

Up and running

  • Install Haskell (Windows, Mac, and Linux);
  • Install Stack;
  • git clone && cd jpegbot && stack build;
  • Create a Slack incoming token and save it to a file named hook;
  • Create a Google Custom Search API key and save it to a file named google-server-key (see this);
  • Create a Google Search Engine and save the ID to a file named google-search-engine-id (see this again);
  • stack exec jpgtobot.

And talking to Slack

  • Use ngrok to open a tunnel to port 3000 (ngrok 3000);
  • Copy down the ngrok URL;
  • Create a Slack custom command /jpeg POSTing to that URL;
  • In Slack, type /jpeg corgi.

If all goes well, you'll see something like this:

/jpgto Corgi

What is this, really?

A demo app for Network.Linklater, a library I wrote! It lets you write Slack bots very easily. Please check it out, whenever you have free time.