niconizer-slack
v3.1.19
Published
CLI that watch slack messages and send to niconizer.
Readme
niconizer-slack
Installation
$ npm i -g niconizer-slackSlack App Setup
To use niconizer-slack, you need to create a Slack App. You can use the provided manifest file to quickly set up the app:
- Go to Slack API: Your Apps and click "Create New App"
- Choose "From an app manifest"
- Select your workspace
- Copy the contents of
niconizer-slack-manifest.jsonand paste it into the JSON tab - Review and create the app
- After creation, go to "OAuth & Permissions" and install the app to your workspace
- Copy the "Bot User OAuth Token" (starts with
xoxb-) - this is your-t/--token - Go to "Basic Information" > "App-Level Tokens" and create a token with
connections:writescope - Copy this token (starts with
xapp-) - this is your-a/--app-token
The manifest configures the app with:
- Socket Mode enabled (required for the app)
- All necessary bot scopes for reading messages and user information
- Event subscriptions for message and emoji changes
Usage
Usage: niconizer-slack [options]
Options:
-t, --token <token> slack bot/user token (env: SLACK_TOKEN)
-a, --app-token <token> slack app token (env: SLACK_APP_TOKEN)
-u, --url <url> websocket server url (default: "ws://localhost:25252")
-c, --channel <channel> slack channel name/id to listen
-C, --exclude-channels <channel...> slack channel name/id to exclude
-U, --exclude-users <user...> slack user name/id to exclude
-T, --no-thread exclude thread reply
-B, --no-bot exclude bot user
--show-username show username in the message
-L, --no-logging disable logging
-j, --json enable json logging
-h, --help output usage information$ niconizer-slack -t SLACK_API_TOKEN_HERE -a SLACK_APP_TOKEN_HEREBoth token (-t) and app-token (-a) are required. Other options are optional.
If no channel was specified, all messages in the authorization scope of the token in the workspace are send to the niconizer.
Press Ctrl+C to exit.
