integrations/workplace/slack/dist¶
Interfaces¶
NormalizeSlackChannelEventInput¶
Properties¶
defaultChannelId?¶
receivedAt?¶
signedRequest¶
ParseSlackSignedRequestInput¶
Extends¶
Properties¶
nowSeconds?¶
Inherited from¶
ParseSlackSignedRequestOptions.nowSeconds
request¶
requireSignature?¶
Inherited from¶
ParseSlackSignedRequestOptions.requireSignature
signingSecret?¶
Inherited from¶
ParseSlackSignedRequestOptions.signingSecret
timestampToleranceSeconds?¶
Inherited from¶
ParseSlackSignedRequestOptions.timestampToleranceSeconds
ParseSlackSignedRequestOptions¶
Extended by¶
Properties¶
nowSeconds?¶
requireSignature?¶
signingSecret?¶
timestampToleranceSeconds?¶
SlackApiResponse¶
Extended by¶
SlackAuthTestResponseSlackCompleteUploadExternalResponseSlackConversationsRepliesResponseSlackGetUploadUrlExternalResponseSlackPostEphemeralResponseSlackPostMessageResponseSlackUpdateMessageResponse
Indexable¶
Properties¶
error?¶
needed?¶
ok¶
provided?¶
response_metadata?¶
optional response_metadata?: {
[key: string]: SlackWorkplaceProviderExtensionValue;
messages?: string[];
next_cursor?: string;
warnings?: string[];
};
Index Signature¶
messages?¶
next_cursor?¶
warnings?¶
warning?¶
SlackAuthTestResponse¶
Extends¶
Indexable¶
Properties¶
bot_id?¶
enterprise_id?¶
error?¶
Inherited from¶
needed?¶
Inherited from¶
ok¶
Inherited from¶
provided?¶
Inherited from¶
response_metadata?¶
optional response_metadata?: {
[key: string]: SlackWorkplaceProviderExtensionValue;
messages?: string[];
next_cursor?: string;
warnings?: string[];
};
Index Signature¶
messages?¶
next_cursor?¶
warnings?¶
Inherited from¶
SlackApiResponse.response_metadata
team?¶
team_id?¶
url?¶
user?¶
user_id?¶
warning?¶
Inherited from¶
SlackCompleteUploadExternalInput¶
Extends¶
Properties¶
channelId?¶
files¶
id¶
title?¶
initialComment?¶
signal?¶
Inherited from¶
SlackProviderRequestOptions.signal
threadTs?¶
SlackCompleteUploadExternalResponse¶
Extends¶
Indexable¶
Properties¶
error?¶
Inherited from¶
files?¶
needed?¶
Inherited from¶
ok¶
Inherited from¶
provided?¶
Inherited from¶
response_metadata?¶
optional response_metadata?: {
[key: string]: SlackWorkplaceProviderExtensionValue;
messages?: string[];
next_cursor?: string;
warnings?: string[];
};
Index Signature¶
messages?¶
next_cursor?¶
warnings?¶
Inherited from¶
SlackApiResponse.response_metadata
warning?¶
Inherited from¶
SlackConversationsRepliesInput¶
Extends¶
Properties¶
channel¶
cursor?¶
inclusive?¶
latest?¶
limit?¶
oldest?¶
signal?¶
Inherited from¶
SlackProviderRequestOptions.signal
ts¶
SlackConversationsRepliesResponse¶
Extends¶
Indexable¶
Properties¶
error?¶
Inherited from¶
has_more?¶
messages?¶
needed?¶
Inherited from¶
ok¶
Inherited from¶
provided?¶
Inherited from¶
response_metadata?¶
optional response_metadata?: {
[key: string]: SlackWorkplaceProviderExtensionValue;
messages?: string[];
next_cursor?: string;
warnings?: string[];
};
Index Signature¶
messages?¶
next_cursor?¶
warnings?¶
Inherited from¶
SlackApiResponse.response_metadata
warning?¶
Inherited from¶
SlackCredentialStatusInput¶
Extends¶
Properties¶
botToken?¶
Inherited from¶
SlackWorkplaceCredentials.botToken
expiresAt?¶
scopes?¶
signingSecret?¶
Inherited from¶
SlackWorkplaceCredentials.signingSecret
SlackFileResource¶
Indexable¶
Properties¶
filetype?¶
id?¶
mimetype?¶
name?¶
title?¶
url_private?¶
SlackGetUploadUrlExternalInput¶
Extends¶
Extended by¶
Properties¶
altTxt?¶
filename¶
length¶
signal?¶
Inherited from¶
SlackProviderRequestOptions.signal
snippetType?¶
SlackGetUploadUrlExternalResponse¶
Extends¶
Indexable¶
Properties¶
error?¶
Inherited from¶
file_id?¶
needed?¶
Inherited from¶
ok¶
Inherited from¶
provided?¶
Inherited from¶
response_metadata?¶
optional response_metadata?: {
[key: string]: SlackWorkplaceProviderExtensionValue;
messages?: string[];
next_cursor?: string;
warnings?: string[];
};
Index Signature¶
messages?¶
next_cursor?¶
warnings?¶
Inherited from¶
SlackApiResponse.response_metadata
upload_url?¶
warning?¶
Inherited from¶
SlackLiveCheckOptions¶
Extends¶
Omit\<SlackWorkplaceClientOptions,"client">
Properties¶
apiBaseUrl?¶
Inherited from¶
SlackWorkplaceClientOptions.apiBaseUrl
botToken?¶
Inherited from¶
SlackWorkplaceCredentials.botToken
client?¶
fetch?¶
Call Signature¶
Parameters¶
| Parameter | Type |
|---|---|
input |
URL | RequestInfo |
init? |
RequestInit |
Returns¶
Promise\<Response>
Call Signature¶
Parameters¶
| Parameter | Type |
|---|---|
input |
string | Request | URL |
init? |
RequestInit |
Returns¶
Promise\<Response>
Inherited from¶
SlackWorkplaceClientOptions.fetch
signal?¶
Inherited from¶
SlackWorkplaceClientOptions.signal
signingSecret?¶
Inherited from¶
SlackWorkplaceCredentials.signingSecret
webClientOptions?¶
Inherited from¶
SlackWorkplaceClientOptions.webClientOptions
SlackMessageResource¶
Indexable¶
Properties¶
attachments?¶
blocks?¶
channel?¶
subtype?¶
text?¶
thread_ts?¶
ts?¶
type?¶
user?¶
username?¶
SlackPostEphemeralInput¶
Extends¶
Properties¶
attachments?¶
blocks?¶
channel¶
mrkdwn?¶
signal?¶
Inherited from¶
SlackProviderRequestOptions.signal
text?¶
threadTs?¶
user¶
SlackPostEphemeralResponse¶
Extends¶
Indexable¶
Properties¶
error?¶
Inherited from¶
message_ts?¶
needed?¶
Inherited from¶
ok¶
Inherited from¶
provided?¶
Inherited from¶
response_metadata?¶
optional response_metadata?: {
[key: string]: SlackWorkplaceProviderExtensionValue;
messages?: string[];
next_cursor?: string;
warnings?: string[];
};
Index Signature¶
messages?¶
next_cursor?¶
warnings?¶
Inherited from¶
SlackApiResponse.response_metadata
warning?¶
Inherited from¶
SlackPostMessageInput¶
Extends¶
Properties¶
attachments?¶
blocks?¶
channel¶
metadata?¶
mrkdwn?¶
replyBroadcast?¶
signal?¶
Inherited from¶
SlackProviderRequestOptions.signal
text?¶
threadTs?¶
unfurlLinks?¶
unfurlMedia?¶
SlackPostMessageResponse¶
Extends¶
Indexable¶
Properties¶
channel?¶
error?¶
Inherited from¶
message?¶
needed?¶
Inherited from¶
ok¶
Inherited from¶
provided?¶
Inherited from¶
response_metadata?¶
optional response_metadata?: {
[key: string]: SlackWorkplaceProviderExtensionValue;
messages?: string[];
next_cursor?: string;
warnings?: string[];
};
Index Signature¶
messages?¶
next_cursor?¶
warnings?¶
Inherited from¶
SlackApiResponse.response_metadata
ts?¶
warning?¶
Inherited from¶
SlackProviderRequestOptions¶
Extended by¶
SlackCompleteUploadExternalInputSlackConversationsRepliesInputSlackGetUploadUrlExternalInputSlackPostEphemeralInputSlackPostMessageInputSlackUpdateMessageInputSlackUploadExternalFileBytesInput
Properties¶
signal?¶
SlackSignedRequest¶
Properties¶
contentType?¶
form?¶
json?¶
payload?¶
rawBody¶
validSignature?¶
SlackUpdateMessageInput¶
Extends¶
Properties¶
attachments?¶
blocks?¶
channel¶
metadata?¶
signal?¶
Inherited from¶
SlackProviderRequestOptions.signal
text?¶
ts¶
SlackUpdateMessageResponse¶
Extends¶
Indexable¶
Properties¶
channel?¶
error?¶
Inherited from¶
message?¶
needed?¶
Inherited from¶
ok¶
Inherited from¶
provided?¶
Inherited from¶
response_metadata?¶
optional response_metadata?: {
[key: string]: SlackWorkplaceProviderExtensionValue;
messages?: string[];
next_cursor?: string;
warnings?: string[];
};
Index Signature¶
messages?¶
next_cursor?¶
warnings?¶
Inherited from¶
SlackApiResponse.response_metadata
text?¶
ts?¶
warning?¶
Inherited from¶
SlackUploadExternalFileBytesInput¶
Extends¶
Properties¶
body¶
contentType?¶
signal?¶
Inherited from¶
SlackProviderRequestOptions.signal
uploadUrl¶
SlackUploadExternalFileInput¶
Extends¶
Properties¶
altTxt?¶
Inherited from¶
SlackGetUploadUrlExternalInput.altTxt
body¶
channelId?¶
contentType?¶
filename¶
Inherited from¶
SlackGetUploadUrlExternalInput.filename
initialComment?¶
length¶
Inherited from¶
SlackGetUploadUrlExternalInput.length
signal?¶
Inherited from¶
SlackGetUploadUrlExternalInput.signal
snippetType?¶
Inherited from¶
SlackGetUploadUrlExternalInput.snippetType
threadTs?¶
title?¶
SlackWorkplaceClient¶
Properties¶
webClient¶
Methods¶
apiCall()¶
Type Parameters¶
| Type Parameter | Default type |
|---|---|
T |
SlackApiResponse |
Parameters¶
| Parameter | Type |
|---|---|
method |
string |
options? |
SlackWorkplaceJsonObject |
Returns¶
Promise\<T>
authTest()¶
Parameters¶
| Parameter | Type |
|---|---|
input? |
SlackProviderRequestOptions |
Returns¶
Promise\<SlackAuthTestResponse>
completeUploadExternal()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackCompleteUploadExternalInput |
Returns¶
Promise\<SlackCompleteUploadExternalResponse>
conversationsReplies()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackConversationsRepliesInput |
Returns¶
Promise\<SlackConversationsRepliesResponse>
getUploadUrlExternal()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackGetUploadUrlExternalInput |
Returns¶
Promise\<SlackGetUploadUrlExternalResponse>
postEphemeralMessage()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackPostEphemeralInput |
Returns¶
Promise\<SlackPostEphemeralResponse>
postInternalAssistMessage()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackPostEphemeralInput |
Returns¶
Promise\<SlackPostEphemeralResponse>
postMessage()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackPostMessageInput |
Returns¶
Promise\<SlackPostMessageResponse>
updateMessage()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackUpdateMessageInput |
Returns¶
Promise\<SlackUpdateMessageResponse>
uploadExternalFile()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackUploadExternalFileInput |
Returns¶
Promise\<SlackCompleteUploadExternalResponse>
uploadExternalFileBytes()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackUploadExternalFileBytesInput |
Returns¶
Promise\<Response>
SlackWorkplaceClientOptions¶
Extends¶
Properties¶
apiBaseUrl?¶
botToken?¶
Inherited from¶
SlackWorkplaceCredentials.botToken
client?¶
fetch?¶
Call Signature¶
Parameters¶
| Parameter | Type |
|---|---|
input |
URL | RequestInfo |
init? |
RequestInit |
Returns¶
Promise\<Response>
Call Signature¶
Parameters¶
| Parameter | Type |
|---|---|
input |
string | Request | URL |
init? |
RequestInit |
Returns¶
Promise\<Response>
signal?¶
signingSecret?¶
Inherited from¶
SlackWorkplaceCredentials.signingSecret
webClientOptions?¶
SlackWorkplaceCredentials¶
Extended by¶
Properties¶
botToken?¶
signingSecret?¶
SlackWorkplaceJsonObject¶
Indexable¶
ValidateSlackRequestSignatureInput¶
Properties¶
nowSeconds?¶
rawBody¶
signature¶
signingSecret?¶
timestamp¶
timestampToleranceSeconds?¶
version?¶
Type Aliases¶
SlackChannelEvent¶
SlackWorkplaceJsonPrimitive¶
SlackWorkplaceJsonValue¶
type SlackWorkplaceJsonValue =
| SlackWorkplaceJsonPrimitive
| SlackWorkplaceJsonObject
| readonly SlackWorkplaceJsonValue[];
SlackWorkplaceProviderExtensionValue¶
Functions¶
createSlackWorkplaceClient()¶
Parameters¶
| Parameter | Type |
|---|---|
options |
SlackWorkplaceClientOptions |
Returns¶
createSlackWorkplaceIntegration()¶
function createSlackWorkplaceIntegration(options): DefinedIntegration<{
capabilities: [{
audiences: ["internal-support", "mixed"];
capability: "receive";
description: "Validates and parses Slack Events API and interactivity payloads for SDK-user-owned support flows.";
exposesSensitiveData: true;
label: "Receive Slack events";
providerObjects: [{
kind: "slackEvent";
label: "Slack Event";
}, {
kind: "workplaceMessage";
label: "Workplace Message";
}];
requiresCredential: true;
}, {
audiences: ["internal-support", "mixed"];
capability: "send";
description: "Posts channel-visible support messages through @slack/web-api chat.postMessage.";
exposesSensitiveData: true;
label: "Post Slack messages";
providerObjects: [{
kind: "workplaceMessage";
label: "Workplace Message";
}];
requiresCredential: true;
sideEffect: true;
}, {
audiences: ["internal-support"];
capability: "notify";
description: "Posts Slack ephemeral messages for internal agent-assist workflows when Slack provides a target user.";
exposesSensitiveData: true;
label: "Post Slack agent-assist notifications";
providerObjects: [{
kind: "workplaceMessage";
label: "Workplace Message";
}];
requiresCredential: true;
sideEffect: true;
}];
category: "workplace";
channelAudiences: ["internal-support", "mixed"];
coverage: {
evidence: [{
label: "Slack Web API package";
url: "https://www.npmjs.com/package/@slack/web-api";
}, {
label: "Slack Web API methods";
url: "https://docs.slack.dev/reference/methods/";
}, {
label: "Slack chat.postMessage";
url: "https://docs.slack.dev/reference/methods/chat.postMessage/";
}, {
label: "Slack chat.update";
url: "https://docs.slack.dev/reference/methods/chat.update/";
}];
notes: ["Coverage is a Cognidesk support workflow adapter backed by Slack's official @slack/web-api package.", "Typed operations cover Slack Events API/interactivity request parsing, signed request validation, chat.postMessage, chat.postEphemeral, chat.update, conversations.replies, the external file upload sequence, and auth.test readiness.", "This package intentionally does not clone Slack's archived generated Web API spec and does not claim full Slack platform coverage.", "Slack Socket Mode, OAuth installation flows, incoming webhook delivery, SCIM, Audit Logs, Legal Holds, workflow runtime behavior, and broad admin APIs are separate extension surfaces or future packages."];
scope: "support-workflow-subset";
};
credentialRequirements: [{
description: "Server-side bot token used by @slack/web-api for Web API calls.";
id: "slack-bot-token";
label: "Slack bot token";
metadata: {
scopeKind: "provider-oauth-scopes";
};
required: true;
scopes: ["chat:write", "chat:write.public", "channels:history", "groups:history", "im:history", "mpim:history", "files:write"];
}, {
description: "Server-side signing secret used to validate Slack Events API and interactivity requests.";
id: "slack-signing-secret";
label: "Slack signing secret";
required: true;
}];
directions: ["receive-only", "send-only", "bidirectional"];
id: "workplace.slack";
limitations: ["Available Slack operations depend on the SDK user's app scopes, workspace policy, channel membership, Enterprise Grid policy, and user targets for ephemeral messages.", "Slack rate limits vary by method, workspace, Marketplace approval, commercial distribution, and install date; SDK users own pagination, Retry-After handling, retry, and backoff policy.", "Customer visibility, agent-assist routing, approval, retention, redaction, and escalation behavior remain SDK-user configuration."];
maintainers: [{
name: "Cognidesk";
type: "official";
}];
metadata: {
channelCoverage: {
authReadiness: "sdk-owned-read";
chatMessages: "sdk-owned-post-update";
ephemeralMessages: "sdk-owned-post";
eventsInteractivity: "typed-parse-verify";
externalFileUpload: "sdk-owned-upload";
incomingWebhooks: "not-covered";
oauth: "not-covered";
socketMode: "not-covered";
threadReplies: "sdk-owned-read";
};
providerClient: {
importPolicy: "runtime-entrypoint-only";
package: "@slack/web-api";
versionRange: "^7.17.0";
};
};
name: "Slack";
operations: [{
alias: "workplace.message.receive";
capability: "receive";
exposesSensitiveData: true;
inputSchemaName: "ParseSlackSignedRequestInput";
outputSchemaName: "SlackSignedRequest";
providerObject: "workplaceMessage";
requiresCredential: true;
}, {
alias: "workplace.thread.read";
capability: "read-provider-object";
exposesSensitiveData: true;
inputSchemaName: "SlackConversationsRepliesInput";
outputSchemaName: "SlackConversationsRepliesResponse";
providerObject: "workplaceThread";
providerOperation: "conversations.replies";
requiresCredential: true;
}, {
alias: "workplace.message.send";
capability: "send";
exposesSensitiveData: true;
externallyVisible: true;
inputSchemaName: "SlackPostMessageInput";
outputSchemaName: "SlackPostMessageResponse";
providerObject: "workplaceMessage";
providerOperation: "chat.postMessage";
requiresCredential: true;
sideEffect: true;
}];
packageName: "@cognidesk/integration-workplace-slack";
privacyNotes: ["Slack messages, channel identifiers, user identifiers, event payloads, interaction payloads, files, and workspace metadata can contain internal support context and customer data.", "Slack bot tokens and signing secrets stay server-side and are represented in Studio only as credential readiness."];
provider: "slack";
trustLevel: "official";
}, SlackWorkplaceCredentials, {
slack.request-signature: (input) => Promise<boolean>;
workplace.file.upload: (input, context) => Promise<SlackCompleteUploadExternalResponse>;
workplace.message.receive: (input) => Promise<SlackSignedRequest>;
workplace.message.reply: (input, context) => Promise<SlackPostMessageResponse>;
workplace.message.send: (input, context) => Promise<SlackPostMessageResponse>;
workplace.message.update: (input, context) => Promise<SlackUpdateMessageResponse>;
workplace.notification.send: (input, context) => Promise<SlackPostEphemeralResponse>;
workplace.thread.read: (input, context) => Promise<SlackConversationsRepliesResponse>;
}>;
Parameters¶
| Parameter | Type |
|---|---|
options |
SlackWorkplaceIntegrationOptions |
Returns¶
DefinedIntegration\<{
capabilities: [{
audiences: ["internal-support", "mixed"];
capability: "receive";
description: "Validates and parses Slack Events API and interactivity payloads for SDK-user-owned support flows.";
exposesSensitiveData: true;
label: "Receive Slack events";
providerObjects: [{
kind: "slackEvent";
label: "Slack Event";
}, {
kind: "workplaceMessage";
label: "Workplace Message";
}];
requiresCredential: true;
}, {
audiences: ["internal-support", "mixed"];
capability: "send";
description: "Posts channel-visible support messages through @slack/web-api chat.postMessage.";
exposesSensitiveData: true;
label: "Post Slack messages";
providerObjects: [{
kind: "workplaceMessage";
label: "Workplace Message";
}];
requiresCredential: true;
sideEffect: true;
}, {
audiences: ["internal-support"];
capability: "notify";
description: "Posts Slack ephemeral messages for internal agent-assist workflows when Slack provides a target user.";
exposesSensitiveData: true;
label: "Post Slack agent-assist notifications";
providerObjects: [{
kind: "workplaceMessage";
label: "Workplace Message";
}];
requiresCredential: true;
sideEffect: true;
}];
category: "workplace";
channelAudiences: ["internal-support", "mixed"];
coverage: {
evidence: [{
label: "Slack Web API package";
url: "https://www.npmjs.com/package/@slack/web-api";
}, {
label: "Slack Web API methods";
url: "https://docs.slack.dev/reference/methods/";
}, {
label: "Slack chat.postMessage";
url: "https://docs.slack.dev/reference/methods/chat.postMessage/";
}, {
label: "Slack chat.update";
url: "https://docs.slack.dev/reference/methods/chat.update/";
}];
notes: ["Coverage is a Cognidesk support workflow adapter backed by Slack's official @slack/web-api package.", "Typed operations cover Slack Events API/interactivity request parsing, signed request validation, chat.postMessage, chat.postEphemeral, chat.update, conversations.replies, the external file upload sequence, and auth.test readiness.", "This package intentionally does not clone Slack's archived generated Web API spec and does not claim full Slack platform coverage.", "Slack Socket Mode, OAuth installation flows, incoming webhook delivery, SCIM, Audit Logs, Legal Holds, workflow runtime behavior, and broad admin APIs are separate extension surfaces or future packages."];
scope: "support-workflow-subset";
};
credentialRequirements: [{
description: "Server-side bot token used by @slack/web-api for Web API calls.";
id: "slack-bot-token";
label: "Slack bot token";
metadata: {
scopeKind: "provider-oauth-scopes";
};
required: true;
scopes: ["chat:write", "chat:write.public", "channels:history", "groups:history", "im:history", "mpim:history", "files:write"];
}, {
description: "Server-side signing secret used to validate Slack Events API and interactivity requests.";
id: "slack-signing-secret";
label: "Slack signing secret";
required: true;
}];
directions: ["receive-only", "send-only", "bidirectional"];
id: "workplace.slack";
limitations: ["Available Slack operations depend on the SDK user's app scopes, workspace policy, channel membership, Enterprise Grid policy, and user targets for ephemeral messages.", "Slack rate limits vary by method, workspace, Marketplace approval, commercial distribution, and install date; SDK users own pagination, Retry-After handling, retry, and backoff policy.", "Customer visibility, agent-assist routing, approval, retention, redaction, and escalation behavior remain SDK-user configuration."];
maintainers: [{
name: "Cognidesk";
type: "official";
}];
metadata: {
channelCoverage: {
authReadiness: "sdk-owned-read";
chatMessages: "sdk-owned-post-update";
ephemeralMessages: "sdk-owned-post";
eventsInteractivity: "typed-parse-verify";
externalFileUpload: "sdk-owned-upload";
incomingWebhooks: "not-covered";
oauth: "not-covered";
socketMode: "not-covered";
threadReplies: "sdk-owned-read";
};
providerClient: {
importPolicy: "runtime-entrypoint-only";
package: "@slack/web-api";
versionRange: "^7.17.0";
};
};
name: "Slack";
operations: [{
alias: "workplace.message.receive";
capability: "receive";
exposesSensitiveData: true;
inputSchemaName: "ParseSlackSignedRequestInput";
outputSchemaName: "SlackSignedRequest";
providerObject: "workplaceMessage";
requiresCredential: true;
}, {
alias: "workplace.thread.read";
capability: "read-provider-object";
exposesSensitiveData: true;
inputSchemaName: "SlackConversationsRepliesInput";
outputSchemaName: "SlackConversationsRepliesResponse";
providerObject: "workplaceThread";
providerOperation: "conversations.replies";
requiresCredential: true;
}, {
alias: "workplace.message.send";
capability: "send";
exposesSensitiveData: true;
externallyVisible: true;
inputSchemaName: "SlackPostMessageInput";
outputSchemaName: "SlackPostMessageResponse";
providerObject: "workplaceMessage";
providerOperation: "chat.postMessage";
requiresCredential: true;
sideEffect: true;
}];
packageName: "@cognidesk/integration-workplace-slack";
privacyNotes: ["Slack messages, channel identifiers, user identifiers, event payloads, interaction payloads, files, and workspace metadata can contain internal support context and customer data.", "Slack bot tokens and signing secrets stay server-side and are represented in Studio only as credential readiness."];
provider: "slack";
trustLevel: "official";
}, SlackWorkplaceCredentials, {
slack.request-signature: (input) => Promise\<boolean>;
workplace.file.upload: (input, context) => Promise\<SlackCompleteUploadExternalResponse>;
workplace.message.receive: (input) => Promise\<SlackSignedRequest>;
workplace.message.reply: (input, context) => Promise\<SlackPostMessageResponse>;
workplace.message.send: (input, context) => Promise\<SlackPostMessageResponse>;
workplace.message.update: (input, context) => Promise\<SlackUpdateMessageResponse>;
workplace.notification.send: (input, context) => Promise\<SlackPostEphemeralResponse>;
workplace.thread.read: (input, context) => Promise\<SlackConversationsRepliesResponse>;
}>
createSlackWorkplaceLiveChecks()¶
function createSlackWorkplaceLiveChecks(options): {
description: string;
id: string;
requiredCredentialIds: string[];
run: Promise<{
details: {
botId: string;
team: string;
teamId: string;
user: string;
userId: string;
};
}>;
}[];
Parameters¶
| Parameter | Type |
|---|---|
options |
SlackLiveCheckOptions |
Returns¶
{
description: string;
id: string;
requiredCredentialIds: string[];
run: Promise\<{
details: {
botId: string;
team: string;
teamId: string;
user: string;
userId: string;
};
}>;
}[]
createSlackWorkplaceOperationHandlers()¶
function createSlackWorkplaceOperationHandlers(options): {
slack.request-signature: (input) => Promise<boolean>;
workplace.file.upload: (input, context) => Promise<SlackCompleteUploadExternalResponse>;
workplace.message.receive: (input) => Promise<SlackSignedRequest>;
workplace.message.reply: (input, context) => Promise<SlackPostMessageResponse>;
workplace.message.send: (input, context) => Promise<SlackPostMessageResponse>;
workplace.message.update: (input, context) => Promise<SlackUpdateMessageResponse>;
workplace.notification.send: (input, context) => Promise<SlackPostEphemeralResponse>;
workplace.thread.read: (input, context) => Promise<SlackConversationsRepliesResponse>;
};
Parameters¶
| Parameter | Type |
|---|---|
options |
SlackWorkplaceIntegrationOptions |
Returns¶
{
slack.request-signature: (input) => Promise<boolean>;
workplace.file.upload: (input, context) => Promise<SlackCompleteUploadExternalResponse>;
workplace.message.receive: (input) => Promise<SlackSignedRequest>;
workplace.message.reply: (input, context) => Promise<SlackPostMessageResponse>;
workplace.message.send: (input, context) => Promise<SlackPostMessageResponse>;
workplace.message.update: (input, context) => Promise<SlackUpdateMessageResponse>;
workplace.notification.send: (input, context) => Promise<SlackPostEphemeralResponse>;
workplace.thread.read: (input, context) => Promise<SlackConversationsRepliesResponse>;
}
| Name | Type |
|---|---|
slack.request-signature() |
(input) => Promise\<boolean> |
workplace.file.upload() |
(input, context) => Promise\<SlackCompleteUploadExternalResponse> |
workplace.message.receive() |
(input) => Promise\<SlackSignedRequest> |
workplace.message.reply() |
(input, context) => Promise\<SlackPostMessageResponse> |
workplace.message.send() |
(input, context) => Promise\<SlackPostMessageResponse> |
workplace.message.update() |
(input, context) => Promise\<SlackUpdateMessageResponse> |
workplace.notification.send() |
(input, context) => Promise\<SlackPostEphemeralResponse> |
workplace.thread.read() |
(input, context) => Promise\<SlackConversationsRepliesResponse> |
normalizeSlackChannelEvent()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
NormalizeSlackChannelEventInput |
Returns¶
parseSlackSignedRequest()¶
Parameters¶
| Parameter | Type |
|---|---|
request |
Request |
options? |
ParseSlackSignedRequestOptions |
Returns¶
Promise\<SlackSignedRequest>
slackWorkplaceCredentialStatuses()¶
function slackWorkplaceCredentialStatuses(input): {
expiresAt?: string;
message?: string;
providerPackageId?: string;
requirementId: string;
scopes?: string[];
state: | "required"
| "configured"
| "permission-blocked"
| "not-required"
| "missing"
| "expired"
| "insufficient-scope"
| "unavailable";
}[];
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackCredentialStatusInput |
Returns¶
{
expiresAt?: string;
message?: string;
providerPackageId?: string;
requirementId: string;
scopes?: string[];
state: | "required"
| "configured"
| "permission-blocked"
| "not-required"
| "missing"
| "expired"
| "insufficient-scope"
| "unavailable";
}[]
stripUndefined()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
SlackWorkplaceJsonObject |
Returns¶
validateSlackRequestSignature()¶
Parameters¶
| Parameter | Type |
|---|---|
input |
ValidateSlackRequestSignatureInput |
Returns¶
boolean
References¶
slackWorkplaceManifestInput¶
Re-exports slackWorkplaceManifestInput
slackWorkplaceOperationAliases¶
Re-exports slackWorkplaceOperationAliases
slackWorkplaceProviderManifest¶
Re-exports slackWorkplaceProviderManifest