Skip to content

Elixir Project 1: Update user's status icon in Slack based on the current weather forecast for Varna

Notifications You must be signed in to change notification settings

VarnaLab/slack-weather-status

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 

Repository files navigation

Elixir Project 1: Update user's status icon in Slack based on the current weather forecast for Varna

  1. Authenticate with Slack using this link, choose users.profile:write scope, and save the returned access token
  2. Create a script that makes GET request to https://api.darksky.net/forecast/[key]/[latitude],[longitude] where:
  1. Map the returned weather icon to emoji shortcode like:
crescent_moon sunny mostly_sunny partly_sunny barely_sunny partly_sunny_rain
cloud rain_cloud thunder_cloud_and_rain lightning snow_cloud fog
  1. Make POST request to https://api.slack.com/methods/users.profile.set using the access token and the emoji :shortcode:
  2. Push the code to https://github.com/VarnaLab/slack-weather-status in separate branch with your name
  3. Run the script with Crontab on every 5 minutes

Solutions

About

Elixir Project 1: Update user's status icon in Slack based on the current weather forecast for Varna

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published