A Slack app that lets anyone in your workspace post to a Vestaboard. Supports two slash commands:
/vesta [message]— post any text to the Vestaboard (rate-limited to once per minute per user)/tides— post today's high and low tide times for Cohasset Harbor to the Vestaboard
- Node.js v22+
- A Slack app with Socket Mode enabled
- A Vestaboard Read/Write API token (Vestaboard app → Settings → Developer)
-
Go to api.slack.com/apps and click Create New App → From scratch.
-
Enable Socket Mode (Settings → Socket Mode → Enable). This avoids needing a public URL.
- Generate an App-Level Token with the
connections:writescope → save it asSLACK_APP_TOKEN.
- Generate an App-Level Token with the
-
Add Slash Commands (Features → Slash Commands → Create New Command). Add both:
Command Short Description Usage Hint /vestaPost a message to the Vestaboard [your message]/tidesPost today's Cohasset tide chart to the Vestaboard Leave Request URL blank for both — Socket Mode handles routing.
-
Set OAuth Scopes (Features → OAuth & Permissions → Bot Token Scopes):
commandschat:write
-
Install the app to your workspace (OAuth & Permissions → Install to Workspace).
- Copy the Bot User OAuth Token → save it as
SLACK_BOT_TOKEN.
- Copy the Bot User OAuth Token → save it as
-
Copy the Signing Secret (Basic Information → App Credentials) → save it as
SLACK_SIGNING_SECRET.
-
Clone and install dependencies:
git clone <your-repo-url> cd vestabot-slack npm install
-
Copy
.env.exampleto.envand fill in your credentials:cp .env.example .env
Variable Required Where to find it SLACK_BOT_TOKENYes OAuth & Permissions → Bot User OAuth Token ( xoxb-...)SLACK_SIGNING_SECRETYes Basic Information → App Credentials → Signing Secret SLACK_APP_TOKENYes Basic Information → App-Level Tokens ( xapp-...)VESTABOARD_TOKENYes Vestaboard app → Settings → Developer → Read/Write API token TIDE_STATIONNo NOAA station ID for /tides(defaults to8444762— Cohasset Harbor)
node index.jsYou should see:
⚡ Vestabot (Slack) is running!
/vesta Your message here— posts text to the Vestaboard/tides— fetches today's tide predictions from NOAA and posts a formatted chart to the Vestaboard
Build:
docker build -t vestabot-slack .Run:
docker run -d --restart unless-stopped --env-file .env --name vestabot-slack vestabot-slackRebuild after changes:
docker build -t vestabot-slack . && docker rm -f vestabot-slack && docker run -d --restart unless-stopped --env-file .env --name vestabot-slack vestabot-slackUseful commands:
docker logs vestabot-slack # view logs
docker restart vestabot-slack
docker stop vestabot-slack