Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tchapi/slack-he
Slack History Extended — A bot that stores all messages and enables full deep search via in-app commands.
https://github.com/tchapi/slack-he
bot history search slack
Last synced: 19 days ago
JSON representation
Slack History Extended — A bot that stores all messages and enables full deep search via in-app commands.
- Host: GitHub
- URL: https://github.com/tchapi/slack-he
- Owner: tchapi
- License: mit
- Created: 2016-05-08T18:25:47.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-01-09T13:18:56.000Z (almost 2 years ago)
- Last Synced: 2024-10-07T17:12:55.845Z (30 days ago)
- Topics: bot, history, search, slack
- Language: JavaScript
- Homepage:
- Size: 276 KB
- Stars: 7
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Slack History Extended
---A bot that stores all messages and enables full deep search and statistics via in-app commands.
#### Installation
npm install
sqlite3 db.sqlite < structure.sqliteYou must as well copy `config.json.dist` to `config.json` and edit the relevant configuration herein.
#### Run
node index.js
#### Tokens
You must configure the Slack payload token that will be used to grant access to POST request from Slack, and also a token for GET access for the standalone pages.
If you plan on using the commands, you must as well configure the Slack command token.
All tokens reside in `config.json`.
#### Full history
A complete history (_excluding bots, and emoji reactions_) of each channel is available here :
http://your.host/[channel]
#### Search command
The search command is `/history "search terms or phrase"`.
It is a full-text search which is performed against the whole database through SQLite's [FTS4](https://www.sqlite.org/fts3.html#section_1).
A "see more" link will redirect to the backend for the actual search, and will display all results. You can access this view directly at :
http://your.host/search/[channel]/[terms_url_encoded]
#### Stats command
The global statistics command is `/stats`.
The following stat block will be displayed :
| User | Most common word | Messages total |
--------------------------------------------------------------------------
| @user1 | oklm (1492 occurences) | 56 023 (3/d.avg)|
| @user2 | oklm (1492 occurences) | 34 195 (3/d.avg)|
...
| @userN | oklm (1492 occurences) | 123 475 (3/d.avg)|#### License
MIT.