slack-web-api-client v0.11.1
Slack Web API Client for TypeScript
The slack-web-api-client library is a type-safe Slack Web API client that provides several key benefits, including:
- A fetch-based implementation, which is compatible with most runtimes
- Strong types for Web API responses and Block Kit, which make coding enjoyable and predictable
- Zero additional dependencies, allowing developers to integrate this library into their projects without any obstacles
Getting Started
Working with the npm package
To install the slack-web-api-client library, simply use the standard npm/yarn command:
npm i slack-web-api-client@latest
Once you have added the slack-web-api-client library to your project's dependencies using the npm/yarn command, you can easily import any functionality you need from "slack-web-api-client"
in your TypeScript code:
import { SlackAPIClient } from "slack-web-api-client";
const client = new SlackAPIClient(process.env.SLACK_BOT_TOKEN);
const response = await client.chat.postMessage({
channel: "#random",
text: ":wave: what's up?",
});
The second argument of the constructor allows for optional customizations:
const client = new SlackAPIClient(process.env.SLACK_BOT_TOKEN, {
logLevel: "DEBUG", // default: "INFO"
throwSlackAPIError: false, // default: true
});
This argument, if provided, allows for further configuration of SlackAPIClient instance to fit your specific needs.
Working with the Deno module
Please refer to README for the Deno module.
16 days ago
17 days ago
25 days ago
28 days ago
27 days ago
27 days ago
29 days ago
29 days ago
1 month ago
30 days ago
1 month ago
1 month ago
2 months ago
3 months ago
4 months ago
4 months ago
4 months ago
5 months ago
6 months ago
6 months ago
6 months ago
6 months ago
7 months ago
6 months ago
6 months ago
7 months ago
6 months ago
7 months ago
7 months ago
8 months ago
9 months ago
8 months ago
10 months ago
9 months ago
12 months ago
8 months ago
8 months ago
9 months ago
12 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago