Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

messaging-api-slack

Package Overview
Dependencies
Maintainers
1
Versions
78
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

messaging-api-slack - npm Package Compare versions

Comparing version 0.2.3 to 0.2.4

2

package.json
{
"name": "messaging-api-slack",
"description": "Messaging API client for Slack",
"version": "0.2.3",
"version": "0.2.4",
"engines": {

@@ -6,0 +6,0 @@ "node": ">=6"

@@ -5,2 +5,4 @@ # messaging-api-slack

<img src="https://cdn-images-1.medium.com/max/1200/1*TiKyhAN2gx4PpbOsiBhYcw.png" alt="Slack" width="150" />
## Table of Contents

@@ -29,7 +31,9 @@

```js
import { SlackClient } from 'messaging-api-slack';
const { SlackClient } = require('messaging-api-slack');
// get webhook URL by adding a Incoming Webhook integration to your team.
// https://my.slack.com/services/new/incoming-webhook/
const client = SlackClient.connect('https://hooks.slack.com/services/XXXXXXXX/YYYYYYYY/zzzzzZZZZZ');
const client = SlackClient.connect(
'https://hooks.slack.com/services/XXXXXXXX/YYYYYYYY/zzzzzZZZZZ'
);
```

@@ -41,8 +45,10 @@

### Send API
### Send API - [Official docs](https://api.slack.com/docs/messages)
[Official docs](https://api.slack.com/docs/messages)
#### sendRawBody(body)
###### body
Type: `Object`
```js

@@ -54,2 +60,6 @@ client.sendRawBody({ text: 'Hello!' });

###### text
Type: `String`
```js

@@ -59,6 +69,8 @@ client.sendText('Hello!');

#### sendAttachments(attachments)
#### sendAttachments(attachments) - [Official docs](https://api.slack.com/docs/message-attachments)
[Official docs](https://api.slack.com/docs/message-attachments)
###### attachments
Type: `Array<Object>`
```js

@@ -89,10 +101,12 @@ client.sendAttachments([

],
}
},
]);
```
#### sendAttachment(attachment)
#### sendAttachment(attachment) - [Official docs](https://api.slack.com/docs/message-attachments)
[Official docs](https://api.slack.com/docs/message-attachments)
###### attachment
Type: `Object`
```js

@@ -99,0 +113,0 @@ client.sendAttachment({

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc