Slack plug.dj User Lookup
A node.js utility to add a plug.dj user lookup integration on your Slack team.
Setup
Clone this repo to your desktop and run npm install to install its dependencies.
Slack
On config.json, do the following:
- Go to your Slack Integrations page and set up a Bot
- Now go back to
config.jsonand replace your-slack-token with your Bot Token - Replace your-slack-channel with the Channel ID of the Slack channel you're going to use
plug.dj
- Go to plug.dj and open your browser's Developer Console (usually F12)
- Go to the Developer Console's "Network" tab
- Do something on plug.dj such as opening the ban list of a room
- You should see the request for it on Developer Console's "Network" tab
- Click it and search for "Cookie" inside "Request Headers", and copy its session=[..your session cookie..] (it should be the last thing on Cookie)
- Go back to
config.jsonand replace your-plug.dj-session-cookie with it
Usage
- Run
node main.json your clone root directory to start the application. - Once the utility is running, invite your Slack bot to the channels you want him to work on.
- Use
!lookup [userid]in a channel the bot is on and he'll reply with the user details.
Notes
If you logout from your account on plug.dj (the account you got the session cookie from) by clicking the Logout button, your cookie will be invalidated by plug.dj and this utility won't work until you log in back.
Notice your account can be offline (disconnected), it just can't be logged out)
