Public | Automated Build

Last pushed: 2 years ago
Short Description
So Who Are They? Intercom sign ups pushed to Slack enriched with Clearbit APIs
Full Description

SWAT



So Who Are They?

Intercom sign ups to Slack enriched with Clearbit API

SWAT is a Rails 4 app

Ruby version

2.2.2

Requirements

  • PostgreSQL

  • Libpq-dev

  • NodeJS

Usage

  • Create an Intercom webhook

  • Create a Slack incoming webhook

  • Run SWAT:

$ CLEARBIT_API_KEY=key SLACK_WEBHOOK="slack_webhook" SLACK_CHANNEL=channel bundle exec rails s

CLEARBIT_API_KEY: It's your Clearbit key

SLACK_WEBHOOK: It's your url Slack webhook (ex : https://hooks.slack.com/services/T00000/B000000/XXXXXX)

SLACK_CHANNEL: It's your Slack channel where to push person details

Intercom Webhook

Webhook URL is the URL of your SWAT instance.

Configure notification only for the event User Created

<img src="http://take.ms/PuvON" width="600">

More information on how to create an Intercom webhook is available here to create an intercom webhook

Slack Incoming Webhook

Read this documentation to create a Slack incoming webhook

Docker

  • Run container
docker run -e "CLEARBIT_API_KEY=key" -e "SLACK_WEBHOOK=slack_webhook" -e "SLACK_CHANNEL=channel" -e "SECRET_KEY_BASE=abcd" -e "SECRET_TOKEN=abcd" -e "POSTGRES_HOST=ip" -p 3000:3000 -d predicsis/swat
  • Check production log
docker exec -it container_id tail -f log/production.log

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Ensure specs and Rubocop pass
  5. Push to the branch (git push origin my-new-feature)
  6. Create new Pull Request
Docker Pull Command
Owner
predicsis
Source Repository