/InspiroMeSlack

A conversational slash command for inspirations from awesome: http://inspirobot.me

Primary LanguageJavaScriptGNU General Public License v2.0GPL-2.0

InspiroBot

InspiroBotSlack

Slack integration with InspiroBot.me

Key Features:

  • Post a random image from Inspiro Bot to any given Slack channel in your workspace.
  • Before posting to a slack channel, only the person who invoked it can:
    • Shuffle for another image, if the current image does not suit your taste.
    • Cancel sending the image to the channel.
    • Send the current image to the channel for everyone to see.

Local development

Use ngrok (https://api.slack.com/tutorials/tunneling-with-ngrok) to test commands locally.

Slash Commands

This works in all channels, within Slack Integration Choose Slash Command and setup something similar to this: Create an App and enable slash command

Create a new slash command: Create a new Slash command

To configure request URL (indicated as 1, in image below), you have the following options:

  • Use my Heroku deployment with the following Request URL: https://inspirome-slack.herokuapp.com/slash
  • Clone the repo yourself and upload the Node.js app to your own private webserver and configure like it is below: Image of Slash Command Settings

Once added, when you call /inspire, you will be presented with following options visible only to yourself:

  • Send, send the image shown to channel, so that its visible for everyone.
  • Reshuffle, change the image from Inspirobot to something else, visible only to you.
  • Cancel, cancel sending an image. The message will be deleted without sending anything. Once added you have the ability to shuffle

Once you hit Send, the posted message looks this way:

Posted image

Image for Inspirobot Icon: http://inspirobot.me/website/images/inspirobot-dark-green.png

Contributing

PR's are always welcome! :)