interactivity type
This reference documents the Slack types at the platform level. Their availability and structure may differ in each SDK
Type: slack#/types/interactivity
| Property | Type | Description |
|---|---|---|
default | The type that is being described. | An optional parameter default value. |
description | string | An optional parameter description. |
examples | An array of the type being described. | An optional list of examples. |
hint | string | An optional parameter hint. |
title | string | An optional parameter title. |
type | string | String that defines the parameter type. |
interactivity_pointer | string | A pointer used to confirm user-initiated interactivity in a function. |
interactor | user_context | Context information of the user who initiated the interactivity. |
Declare the interactivity type:
- JSON manifest
- Deno Slack SDK
// ...
"input_parameters": {
"interactivity": {
"type": "slack#/types/interactivity"
}
}
// ...
// ...
properties: {
interactivity: {
type: Schema.slack.types.interactivity,
},
},
// ...
Interactivity example
In this example workflow, we specify that it is an interactive workflow.
import { DefineWorkflow, Schema } from "deno-slack-sdk/mod.ts";
const GreetingWorkflow = DefineWorkflow({
callback_id: "greeting_workflow",
title: "Send a greeting",
description: "Send a greeting to channel",
input_parameters: {
properties: {
interactivity: { type: Schema.slack.types.interactivity },
channel: { type: Schema.slack.types.channel_id },
},
required: ["interactivity"],
},
});