Skip to content

Latest commit

 

History

History
30 lines (20 loc) · 915 Bytes

README.md

File metadata and controls

30 lines (20 loc) · 915 Bytes

Slack Strava Integration

A script for posting a leaderboard, fetched from Strava, to a dedicated Slack channel. Running the script on a weekly basis sums up the distance run by each user and posts it as a message in Slack.

Contributors

Requirements

Setup

  1. Copy the example.env file to .env.
  2. In .env, set the club_id to the desired Strava club id (ex: itchalmerslop) and set the hook_token to a Slack incoming web hook token to be used (could also print to command line while developing).
  3. Install dependencies with
npm install

Run the script with

node src/refresh_tokens.js # Creates/Refreshes tokens.json
node src/index.js          # Posts to slack