https://github.com/ph1p/outer
rocketchat slack
Last synced: 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/ph1p/outer
- Owner: ph1p
- License: mit
- Created: 2017-08-27T18:18:36.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2018-02-22T17:23:07.000Z (over 8 years ago)
- Last Synced: 2025-10-25T19:20:25.517Z (8 months ago)
- Topics: rocketchat, slack
- Language: JavaScript
- Size: 6.84 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
## outer
[](https://www.npmjs.com/package/outer)
This package connects your node application to your slack or rocket.chat server and send your logs to specific channels or users.
#### rocket.chat

#### slack

### Options
| Name | Description |
|---|---|
| adapter | rocket.chat or slack _(default)_ |
| channel | #channel or @username |
| alias | alias for username _(optional)_ |
| emoji | avatar emoji _(optional)_ |
#### rocket.chat specific
| Name | Description |
|---|---|
| username | username |
| password | password |
| url | URL from your rocket.chat server |
#### slack specific
| Name | Description |
|---|---|
| token | user token _(https://api.slack.com/custom-integrations/legacy-tokens)_ |
---
### Example
```javascript
const outer = require('outer');
// CONFIGURE ROCKET.CHAT LOGGER
const rocketChat = new outer({
adapter: 'rocket.chat',
url: 'https://chat.server.com',
channel: '@username',
emoji: ':smirk:',
username: 'username',
password: 'password'
});
// CONFIGURE SLACK LOGGER
const slack = new outer({
// https://api.slack.com/custom-integrations/legacy-tokens
token: 'xoxp-0000000000-00000000-000000000-00000000000',
channel: '#random',
alias: 'My custom username',
emoji: ':smirk:'
});
rocketChat.log('Message from your *app*. Hi Rocket.Chat!');
slack.log('Message from your *app*. Hi Slack!');
```