Skip to content

andremaldonado/habitica-slack-integration

Repository files navigation

Codacy Badge

Habitica-Slack Integration

This a command-line app for slack that lets you create and retrieve your habitica todos.

Initial local environment configuration

  • Install Docker
  • Clone repo
  • Download ngrok
  • Navigate to the folder of the repo
  • Create docker image:
docker build -t habitica-slack .

Running the program

  • Start ngrok on the correct port;
./ngrok http 3394
  • Create a slack app with the same configuration this program uses;
    • Command: /habitica;
    • Request URL: your-ngrok-url;
    • Short description: for testing purposes, whenever you want;
    • Usage hint: for testing purposes, whenever you want.
  • Get client_id and client_secret from your slack app;
  • Get User ID and API Token from habitica;
  • Setup these enviroment variables in a file:
    • SLACK_CLIENTID
    • SLACK_CLIENTSECRET
    • HABITICA_USERID
    • HABITICA_APITOKEN
    • Tip: if you create a file named appenv to store your enviroment variables, git will ignore it!
  • Install your slack app in a slack team of your choice;
  • Run docker image with port forwarding and setting up your environment variables
docker run --env-file [your-file-here] -p 3394:3394 habitica-slack
  • Grab a cup of coffe and be happy.

How to test (in progress)

Just run:

npm test

And check the results.

About

Simple command-line integration for slack and habitica

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published