Skip to content

sachinr/channel-naming-template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Channel Naming Slack App Template

An example app that helps enforce channel naming conventions.

channel-naming

Setup

Create a Slack app

  1. Create an app at api.slack.com/apps
  2. Click on OAuth & Permissions
  3. Add the channels:read and chat:write:bot permissions
  4. Click on Install App in the sidebar
  5. Install the app and copy the xoxp- token

Run locally or Remix on Glitch

  1. Get the code
  2. Set the following environment variables in .env (copy from .env.sample):
    • SLACK_TOKEN: Your app's xoxp- token (available on the Install App page)
    • PORT: The port that you want to run the web server on
    • SLACK_VERIFICATION_TOKEN: Your app's Verification Token (available on the Basic Information page)
  3. If you're running the app locally:
    1. Start the app (npm start)
    2. In another windown, start ngrok on the same port as your webserver (ngrok http $PORT)

Enable the Events API

  1. Go back to the app settings and click on Events Subscriptions
  2. Set the Request URL to your ngrok or Glitch URL + /events
  3. On the same page, subscribe to the channel_created and channel_rename events

Enable Interactive Messages

  1. In the app settings, click on Interactive Messages
  2. Set the Request URL to your ngrok or Glitch URL + /interactive-message

In Slack

  1. Create a new channel

About

Add to enforce channel naming conventions

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published