Track a tag on StackOverflow and push to Slack.
1.1K
ifdef::env-github[] :status: :outfilesuffix: .adoc :caution-caption: :fire: :important-caption: :exclamation: :note-caption: :paperclip: :tip-caption: :bulb: :warning-caption: :warning: endif::[]
= StackOverflow Slack Integration
image:https://travis-ci.org/ldez/stackoverflow-slack-bot.svg?branch=master["Build Status", link="https://travis-ci.org/ldez/stackoverflow-slack-bot"] image:https://img.shields.io/docker/build/ldez/stackoverflow-slack-bot.svg["Docker Build Status", link="https://hub.docker.com/r/ldez/stackoverflow-slack-bot/builds/"]
This is a basic script to keep track a tag on StackOverflow and push accurate links to Slack.
== How to use
npm install.config.jsonnpm run start every 15 minutes (StackOverflow quota is 300 requests by day)// [horizontal]
tags:: name of the tags to track (separate by ;),
so.apiBaseURL:: URL of the StackOverflow API.
so.minuteBack:: number of minutes previous now, use for create the first query.
so.hourBack:: number of hours previous now, use for create the first query.
so.dayBack:: number of days previous now, use for create the first query.
so.key:: an API key from https://stackapps.com/apps/oauth/register/submit to increase your per-day quota from 300 to 10000
slack.apiBaseUrl:: URL of Slack API.
slack.token:: Slack token, only for dev purpose. DON'T USE IN PRODUCTION.
slack.channel:: Name of the channel to publish. (must start with #)
slack.botName:: your bot account name.
slack.botIcon:: your bot emoji icon. (can be blank.)
slack.icons.xxx:: emoji for each situation. (can be blank.)
lastEndFileName:: name of file use for store the last query date.
dryRun:: if true, display the Slack payload without send it.
IMPORTANT: In production, use environment variable to set your Slack token (SLACK_API_TOKEN).
Thanks to link:https://github.com/cwi-swat[@cwi-swat] for link:https://github.com/cwi-swat/stackoverflow-slack-plugin[inspiration].
Content type
Image
Digest
Size
23.5 MB
Last updated
over 7 years ago
docker pull ldez/stackoverflow-slack-bot