import { JSONSchema, FromSchema } from 'json-schema-to-ts'; import { ValidateFunction } from 'ajv'; declare enum HttpHeaderKeysEnum { SIGNATURE = "x-novu-signature", ANONYMOUS = "x-novu-anonymous", EXECUTION_DURATION = "x-echo-execution-duration", SDK_VERSION = "x-echo-sdk", FRAMEWORK = "x-echo-framework", USER_AGENT = "user-agent", CONTENT_TYPE = "content-type", AUTHORIZATION = "authorization", ACCESS_CONTROL_ALLOW_ORIGIN = "access-control-allow-origin", ACCESS_CONTROL_ALLOW_METHODS = "access-control-allow-methods", ACCESS_CONTROL_ALLOW_HEADERS = "access-control-allow-headers", ACCESS_CONTROL_ALLOW_CREDENTIALS = "access-control-allow-credentials", ACCESS_CONTROL_MAX_AGE = "access-control-max-age" } declare enum ChannelStepEnum { EMAIL = "email", SMS = "sms", PUSH = "push", CHAT = "chat", IN_APP = "in_app" } declare enum ActionStepEnum { DIGEST = "digest", DELAY = "delay", CUSTOM = "custom" } type CodeResult = { code: string; }; type ClientConfig = { /** * Specify your Novu API key, to secure your Echo API endpoint. * Novu communicates securely with your endpoint using a signed HMAC header, * ensuring that only trusted requests from Novu are actioned by your Echo API. * The API key is used to sign the HMAC header. */ apiKey?: string; /** * Specify a custom Novu API URL. * Defaults to 'https://api.novu.co' */ backendUrl?: string; /** * Explicitly bypass HMAC signature verification in dev mode. * Setting this to `true` will enable Novu to communicate with your Echo API * without requiring a valid HMAC signature. * This is useful for local development and testing. * * You are strongly encouraged to specify an `apiKey` and set this to `false` in production, * to ensure that only trusted requests from Novu are actioned by your Echo API. * * Defaults to false. */ devModeBypassAuthentication?: boolean; }; type Schema = JSONSchema; declare const providerSchemas: { chat: { slack: { output: { readonly type: "object"; readonly properties: { readonly webhookUrl: { readonly type: "string"; readonly format: "uri"; }; readonly text: { readonly type: "string"; }; readonly blocks: { readonly type: "array"; readonly items: { readonly type: "object"; readonly properties: { readonly type: { readonly enum: readonly ["image", "context", "actions", "divider", "section", "input", "file", "header", "video", "rich_text"]; }; }; readonly required: readonly ["type"]; readonly additionalProperties: true; readonly allOf: readonly [{ readonly if: { readonly properties: { readonly type: { readonly const: "image"; }; }; }; readonly then: { readonly $ref: "#/definitions/ImageBlock"; }; }, { readonly if: { readonly properties: { readonly type: { readonly const: "context"; }; }; }; readonly then: { readonly $ref: "#/definitions/ContextBlock"; }; }, { readonly if: { readonly properties: { readonly type: { readonly const: "actions"; }; }; }; readonly then: { readonly $ref: "#/definitions/ActionsBlock"; }; }, { readonly if: { readonly properties: { readonly type: { readonly const: "divider"; }; }; }; readonly then: { readonly $ref: "#/definitions/DividerBlock"; }; }, { readonly if: { readonly properties: { readonly type: { readonly const: "section"; }; }; }; readonly then: { readonly $ref: "#/definitions/SectionBlock"; }; }, { readonly if: { readonly properties: { readonly type: { readonly const: "Input"; }; }; }; readonly then: { readonly $ref: "#/definitions/InputBlock"; }; }, { readonly if: { readonly properties: { readonly type: { readonly const: "Video"; }; }; }; readonly then: { readonly $ref: "#/definitions/VideoBlock"; }; }, { readonly if: { readonly properties: { readonly type: { readonly const: "rich_text"; }; }; }; readonly then: { readonly $ref: "#/definitions/RichTextBlock"; }; }]; }; }; }; readonly definitions: { readonly KnownBlock: { readonly oneOf: readonly [{ readonly $ref: "#/definitions/ImageBlock"; }, { readonly $ref: "#/definitions/ContextBlock"; }, { readonly $ref: "#/definitions/ActionsBlock"; }, { readonly $ref: "#/definitions/DividerBlock"; }, { readonly $ref: "#/definitions/SectionBlock"; }, { readonly $ref: "#/definitions/InputBlock"; }, { readonly $ref: "#/definitions/FileBlock"; }, { readonly $ref: "#/definitions/HeaderBlock"; }, { readonly $ref: "#/definitions/VideoBlock"; }, { readonly $ref: "#/definitions/RichTextBlock"; }]; }; readonly ImageBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "image"; readonly description: "The type of block. For an image block, `type` is always `image`."; }; readonly block_id: { readonly type: "string"; }; readonly image_url: { readonly type: "string"; readonly description: "The URL of the image to be displayed. Maximum length for this field is 3000 characters."; }; readonly alt_text: { readonly type: "string"; readonly description: "A plain-text summary of the image. This should not contain any markup.\nMaximum length for this field is 2000 characters."; }; readonly title: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "An optional title for the image in the form of a {@link PlainTextElement } object.\nMaximum length for the text in this field is 2000 characters."; }; }; readonly required: readonly ["alt_text", "image_url", "type"]; readonly additionalProperties: false; readonly description: "Displays an image. A simple image block, designed to make those cat photos really pop."; }; readonly PlainTextElement: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "plain_text"; readonly description: "The formatting to use for this text object."; }; readonly text: { readonly type: "string"; readonly description: "The text for the block. The minimum length is 1 and maximum length is 3000 characters."; }; readonly emoji: { readonly type: "boolean"; readonly description: "Indicates whether emojis in a text field should be escaped into the colon emoji format."; }; }; readonly required: readonly ["type", "text"]; readonly additionalProperties: false; readonly description: "Defines an object containing some text."; }; readonly ContextBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "context"; readonly description: "The type of block. For a context block, `type` is always `context`."; }; readonly block_id: { readonly type: "string"; }; readonly elements: { readonly type: "array"; readonly items: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/ImageElement"; }, { readonly $ref: "#/definitions/PlainTextElement"; }, { readonly $ref: "#/definitions/MrkdwnElement"; }]; }; readonly description: "An array of {@link ImageElement }, {@link PlainTextElement } or {@link MrkdwnElement } objects.\nMaximum number of items is 10."; }; }; readonly required: readonly ["elements", "type"]; readonly additionalProperties: false; readonly description: "Displays contextual info, which can include both images and text."; }; readonly ImageElement: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "image"; readonly description: "The type of element. In this case `type` is always `image`."; }; readonly image_url: { readonly type: "string"; readonly description: "The URL of the image to be displayed."; }; readonly alt_text: { readonly type: "string"; readonly description: "A plain-text summary of the image. This should not contain any markup."; }; }; readonly required: readonly ["type", "image_url", "alt_text"]; readonly additionalProperties: false; readonly description: "Displays an image as part of a larger block of content. Use this `image` block if you want a block with\nonly an image in it."; }; readonly MrkdwnElement: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "mrkdwn"; readonly description: "The formatting to use for this text object."; }; readonly text: { readonly type: "string"; readonly description: "The text for the block. This field accepts any of the standard text formatting markup.\nThe minimum length is 1 and maximum length is 3000 characters."; }; readonly verbatim: { readonly type: "boolean"; readonly description: "When set to `false` (as is default) URLs will be auto-converted into links, conversation names will\nbe converted to links, and certain mentions will be {@link https://api.slack.com/reference/surfaces/formatting#automatic-parsing automatically parsed}.\nUsing a value of `true` will skip any preprocessing of this nature, although you can still include\n{@link https://api.slack.com/reference/surfaces/formatting#advanced manual parsing strings}."; }; }; readonly required: readonly ["type", "text"]; readonly additionalProperties: false; readonly description: "Defines an object containing some text."; }; readonly ActionsBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "actions"; readonly description: "The type of block. For an actions block, `type` is always `actions`."; }; readonly block_id: { readonly type: "string"; readonly description: "A string acting as a unique identifier for a block. If not specified, a `block_id` will be generated.\nYou can use this `block_id` when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}.\nMaximum length for this field is 255 characters. `block_id` should be unique for each message and each iteration of\na message. If a message is updated, use a new `block_id`."; }; readonly elements: { readonly type: "array"; readonly items: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/Button"; }, { readonly $ref: "#/definitions/Checkboxes"; }, { readonly $ref: "#/definitions/Datepicker"; }, { readonly $ref: "#/definitions/DateTimepicker"; }, { readonly $ref: "#/definitions/MultiSelect"; }, { readonly $ref: "#/definitions/Overflow"; }, { readonly $ref: "#/definitions/RadioButtons"; }, { readonly $ref: "#/definitions/Select"; }, { readonly $ref: "#/definitions/Timepicker"; }, { readonly $ref: "#/definitions/WorkflowButton"; }, { readonly $ref: "#/definitions/RichTextInput"; }]; }; readonly description: "An array of {@link InteractiveElements } objects.\nThere is a maximum of 25 elements in each action block."; }; }; readonly required: readonly ["elements", "type"]; readonly additionalProperties: false; readonly description: "Holds multiple interactive elements."; }; readonly Button: { readonly type: "object"; readonly properties: { readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "button"; readonly description: "The type of element. In this case `type` is always `button`."; }; readonly action_id: { readonly type: "string"; }; readonly text: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } that defines the button's text. `text` may truncate with ~30 characters.\nMaximum length for the text in this field is 75 characters."; }; readonly value: { readonly type: "string"; readonly description: "The value to send along with the {@link https://api.slack.com/interactivity/handling#payloads interaction payload}.\nMaximum length for this field is 2000 characters."; }; readonly url: { readonly type: "string"; readonly description: "A URL to load in the user's browser when the button is clicked. Maximum length for this field is 3000\ncharacters. If you're using `url`, you'll still receive an {@link https://api.slack.com/interactivity/handling#payloads interaction payload}\nand will need to send an {@link https://api.slack.com/interactivity/handling#acknowledgment_response acknowledgement response}."; }; readonly style: { readonly type: "string"; readonly enum: readonly ["danger", "primary"]; readonly description: "Decorates buttons with alternative visual color schemes. Use this option with restraint.\n`primary` gives buttons a green outline and text, ideal for affirmation or confirmation actions. `primary` should\nonly be used for one button within a set.\n`danger` gives buttons a red outline and text, and should be used when the action is destructive. Use `danger` even\nmore sparingly than primary.\nIf you don't include this field, the default button style will be used."; }; readonly accessibility_label: { readonly type: "string"; readonly description: "A label for longer descriptive text about a button element. This label will be read out by screen\nreaders instead of the button `text` object. Maximum length for this field is 75 characters."; }; }; readonly required: readonly ["text", "type"]; readonly additionalProperties: false; readonly description: "Allows users a direct path to performing basic actions."; }; readonly Actionable: { readonly type: "object"; readonly additionalProperties: false; readonly properties: { readonly type: { readonly type: "string"; }; readonly action_id: { readonly type: "string"; }; }; readonly required: readonly ["type"]; }; readonly Action: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; }; readonly action_id: { readonly type: "string"; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; }; readonly Confirmable: { readonly type: "object"; readonly properties: { readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; }; readonly additionalProperties: false; }; readonly ConfirmationDialog: { readonly type: "object"; readonly additionalProperties: false; readonly properties: { readonly title: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } text object that defines the dialog's title.\nMaximum length for this field is 100 characters."; }; readonly text: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/PlainTextElement"; }, { readonly $ref: "#/definitions/MrkdwnElement"; }]; readonly description: "A {@link PlainTextElement } text object that defines the explanatory text that appears in the confirm\ndialog. Maximum length for the `text` in this field is 300 characters."; }; readonly confirm: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } text object to define the text of the button that confirms the action.\nMaximum length for the `text` in this field is 30 characters."; }; readonly deny: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } text object to define the text of the button that cancels the action.\nMaximum length for the `text` in this field is 30 characters."; }; readonly style: { readonly type: "string"; readonly enum: readonly ["primary", "danger"]; readonly description: "Defines the color scheme applied to the `confirm` button. A value of `danger` will display the button\nwith a red background on desktop, or red text on mobile. A value of `primary` will display the button with a green\nbackground on desktop, or blue text on mobile. If this field is not provided, the default value will be `primary`."; }; }; readonly required: readonly ["text"]; readonly description: "Defines a dialog that adds a confirmation step to interactive elements."; }; readonly Confirm: { readonly type: "object"; readonly properties: { readonly title: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } text object that defines the dialog's title.\nMaximum length for this field is 100 characters."; }; readonly text: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/PlainTextElement"; }, { readonly $ref: "#/definitions/MrkdwnElement"; }]; readonly description: "A {@link PlainTextElement } text object that defines the explanatory text that appears in the confirm\ndialog. Maximum length for the `text` in this field is 300 characters."; }; readonly confirm: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } text object to define the text of the button that confirms the action.\nMaximum length for the `text` in this field is 30 characters."; }; readonly deny: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } text object to define the text of the button that cancels the action.\nMaximum length for the `text` in this field is 30 characters."; }; readonly style: { readonly type: "string"; readonly enum: readonly ["primary", "danger"]; readonly description: "Defines the color scheme applied to the `confirm` button. A value of `danger` will display the button\nwith a red background on desktop, or red text on mobile. A value of `primary` will display the button with a green\nbackground on desktop, or blue text on mobile. If this field is not provided, the default value will be `primary`."; }; }; readonly required: readonly ["text"]; readonly additionalProperties: false; readonly description: "Defines a dialog that adds a confirmation step to interactive elements."; }; readonly Checkboxes: { readonly type: "object"; readonly properties: { readonly focus_on_load: { readonly type: "boolean"; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "checkboxes"; readonly description: "The type of element. In this case `type` is always `checkboxes`."; }; readonly action_id: { readonly type: "string"; }; readonly initial_options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/Option"; }; readonly description: "An array of {@link Option } objects that exactly matches one or more of the options within `options`.\nThese options will be selected when the checkbox group initially loads."; }; readonly options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/Option"; }; readonly description: "An array of {@link Option } objects. A maximum of 10 options are allowed."; }; }; readonly required: readonly ["options", "type"]; readonly additionalProperties: false; readonly description: "Allows users to choose multiple items from a list of options."; }; readonly Focusable: { readonly type: "object"; readonly properties: { readonly focus_on_load: { readonly type: "boolean"; }; }; readonly additionalProperties: false; }; readonly Option: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/MrkdwnOption"; }, { readonly $ref: "#/definitions/PlainTextOption"; }]; readonly description: "Defines a single item in a number of item selection elements. An object that represents a single\nselectable item in a select menu, multi-select menu, checkbox group, radio button group, or overflow menu."; }; readonly MrkdwnOption: { readonly type: "object"; readonly properties: { readonly value: { readonly type: "string"; readonly description: "A unique string value that will be passed to your app when this option is chosen.\nMaximum length for this field is 75 characters."; }; readonly url: { readonly type: "string"; readonly description: "Only available in overflow menus! A URL to load in the user's browser when the option is clicked.\nMaximum length for this field is 3000 characters."; }; readonly description: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } that defines a line of descriptive text shown below the `text` field.\nMaximum length for the `text` within this field is 75 characters."; }; readonly text: { readonly $ref: "#/definitions/MrkdwnElement"; readonly description: "A {@link MrkdwnElement } that defines the text shown in the option on the menu. To be used with\nradio buttons and checkboxes. Maximum length for the `text` in this field is 75 characters."; }; }; readonly required: readonly ["text"]; readonly additionalProperties: false; }; readonly PlainTextOption: { readonly type: "object"; readonly properties: { readonly value: { readonly type: "string"; readonly description: "A unique string value that will be passed to your app when this option is chosen.\nMaximum length for this field is 75 characters."; }; readonly url: { readonly type: "string"; readonly description: "Only available in overflow menus! A URL to load in the user's browser when the option is clicked.\nMaximum length for this field is 3000 characters."; }; readonly description: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } that defines a line of descriptive text shown below the `text` field.\nMaximum length for the `text` within this field is 75 characters."; }; readonly text: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } that defines the text shown in the option on the menu. To be used with\noverflow, select and multi-select menus. Maximum length for the `text` in this field is 75 characters."; }; }; readonly required: readonly ["text"]; readonly additionalProperties: false; }; readonly Datepicker: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "datepicker"; readonly description: "The type of element. In this case `type` is always `datepicker`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_date: { readonly type: "string"; readonly description: "The initial date that is selected when the element is loaded.\nThis should be in the format `YYYY-MM-DD`."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "Allows users to select a date from a calendar style UI."; }; readonly Placeholdable: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; }; readonly additionalProperties: false; }; readonly DateTimepicker: { readonly type: "object"; readonly properties: { readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "datetimepicker"; readonly description: "The type of element. In this case `type` is always `datetimepicker`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_date_time: { readonly type: "number"; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "Allows users to select both a date and a time of day, formatted as a Unix timestamp. On desktop\nclients, this time picker will take the form of a dropdown list and the date picker will take the form of a dropdown\ncalendar. Both options will have free-text entry for precise choices. On mobile clients, the time picker and date\npicker will use native UIs."; }; readonly MultiSelect: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/MultiUsersSelect"; }, { readonly $ref: "#/definitions/MultiStaticSelect"; }, { readonly $ref: "#/definitions/MultiConversationsSelect"; }, { readonly $ref: "#/definitions/MultiChannelsSelect"; }, { readonly $ref: "#/definitions/MultiExternalSelect"; }]; readonly description: "Allows users to select multiple items from a list of options.\nJust like regular {@link Select }, multi-select menus also include type-ahead functionality, where a user can type a\npart or all of an option string to filter the list.\nThere are different types of multi-select menu that depend on different data sources for their lists of options:\n{@link MultiStaticSelect }, {@link MultiExternalSelect }, {@link MultiUsersSelect }, {@link MultiConversationsSelect },\n{@link MultiChannelsSelect }."; }; readonly MultiUsersSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "multi_users_select"; readonly description: "The type of element. In this case `type` is always `multi_users_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_users: { readonly type: "array"; readonly items: { readonly type: "string"; }; readonly description: "An array of user IDs of any valid users to be pre-selected when the menu loads."; }; readonly max_selected_items: { readonly type: "number"; readonly description: "Specifies the maximum number of items that can be selected in the menu. Minimum number is `1`."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This multi-select menu will populate its options with a list of Slack users visible to the current user\nin the active workspace."; }; readonly MultiStaticSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "multi_static_select"; readonly description: "The type of element. In this case `type` is always `multi_static_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/PlainTextOption"; }; readonly description: "An array of option objects that exactly match one or more of the options within `options` or\n`option_groups`. These options will be selected when the menu initially loads."; }; readonly options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/PlainTextOption"; }; readonly description: "An array of {@link PlainTextOption }. Maximum number of options is 100. If `option_groups` is\nspecified, this field should not be."; }; readonly option_groups: { readonly type: "array"; readonly items: { readonly type: "object"; readonly properties: { readonly label: { readonly $ref: "#/definitions/PlainTextElement"; }; readonly options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/PlainTextOption"; }; }; }; readonly required: readonly ["label", "options"]; readonly additionalProperties: false; }; readonly description: "An array of option group objects. Maximum number of option groups is 100. If `options` is specified,\nthis field should not be."; }; readonly max_selected_items: { readonly type: "number"; readonly description: "Specifies the maximum number of items that can be selected in the menu. Minimum number is 1."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This is the simplest form of select menu, with a static list of options passed in when defining the\nelement."; }; readonly MultiConversationsSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "multi_conversations_select"; readonly description: "The type of element. In this case `type` is always `conversations_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_conversations: { readonly type: "array"; readonly items: { readonly type: "string"; }; readonly description: "An array of one or more IDs of any valid conversations to be pre-selected when the menu loads. If\n`default_to_current_conversation` is also supplied, `initial_conversation` will be ignored."; }; readonly max_selected_items: { readonly type: "number"; readonly description: "Specifies the maximum number of items that can be selected in the menu. Minimum number is 1."; }; readonly default_to_current_conversation: { readonly type: "boolean"; readonly description: "Pre-populates the select menu with the conversation that the user was viewing when they opened the\nmodal, if available. Default is `false`."; }; readonly filter: { readonly type: "object"; readonly properties: { readonly include: { readonly type: "array"; readonly items: { readonly type: "string"; readonly enum: readonly ["im", "mpim", "private", "public"]; }; }; readonly exclude_external_shared_channels: { readonly type: "boolean"; }; readonly exclude_bot_users: { readonly type: "boolean"; }; }; readonly additionalProperties: false; readonly description: "A filter object that reduces the list of available conversations using the specified criteria."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This multi-select menu will populate its options with a list of public and private channels, DMs, and\nMPIMs visible to the current user in the active workspace."; }; readonly MultiChannelsSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "multi_channels_select"; readonly description: "The type of element. In this case `type` is always `multi_channels_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_channels: { readonly type: "array"; readonly items: { readonly type: "string"; }; readonly description: "An array of one or more IDs of any valid public channel to be pre-selected when the menu loads."; }; readonly max_selected_items: { readonly type: "number"; readonly description: "Specifies the maximum number of items that can be selected in the menu. Minimum number is 1."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This multi-select menu will populate its options with a list of public channels visible to the current\nuser in the active workspace."; }; readonly MultiExternalSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "multi_external_select"; readonly description: "The type of element. In this case `type` is always `multi_external_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/PlainTextOption"; }; readonly description: "An array of options to be selected when the menu initially loads."; }; readonly min_query_length: { readonly type: "number"; readonly description: "When the typeahead field is used, a request will be sent on every character change. If you prefer\nfewer requests or more fully ideated queries, use the `min_query_length` attribute to tell Slack the fewest number\nof typed characters required before dispatch. The default value is `3`."; }; readonly max_selected_items: { readonly type: "number"; readonly description: "Specifies the maximum number of items that can be selected in the menu. Minimum number is 1."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This menu will load its options from an external data source, allowing for a dynamic list of options."; }; readonly Overflow: { readonly type: "object"; readonly properties: { readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "overflow"; readonly description: "The type of element. In this case `type` is always `number_input`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/PlainTextOption"; }; readonly description: "An array of up to 5 {@link PlainTextOption } to display in the menu."; }; }; readonly required: readonly ["options", "type"]; readonly additionalProperties: false; readonly description: "Allows users to press a button to view a list of options.\nUnlike the select menu, there is no typeahead field, and the button always appears with an ellipsis (\"…\") rather\nthan customizable text. As such, it is usually used if you want a more compact layout than a select menu, or to\nsupply a list of less visually important actions after a row of buttons. You can also specify simple URL links as\noverflow menu options, instead of actions."; }; readonly RadioButtons: { readonly type: "object"; readonly properties: { readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "radio_buttons"; readonly description: "The type of element. In this case `type` is always `radio_buttons`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_option: { readonly $ref: "#/definitions/Option"; readonly description: "An {@link Option } object that exactly matches one of the options within `options`. This option will\nbe selected when the radio button group initially loads."; }; readonly options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/Option"; }; readonly description: "An array of {@link Option } objects. A maximum of 10 options are allowed."; }; }; readonly required: readonly ["options", "type"]; readonly additionalProperties: false; readonly description: "Allows users to choose one item from a list of possible options."; }; readonly Select: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/UsersSelect"; }, { readonly $ref: "#/definitions/StaticSelect"; }, { readonly $ref: "#/definitions/ConversationsSelect"; }, { readonly $ref: "#/definitions/ChannelsSelect"; }, { readonly $ref: "#/definitions/ExternalSelect"; }]; readonly description: "Allows users to choose an option from a drop down menu.\nThe select menu also includes type-ahead functionality, where a user can type a part or all of an option string to\nfilter the list. There are different types of select menu elements that depend on different data sources for their\nlists of options: {@link StaticSelect }, {@link ExternalSelect }, {@link UsersSelect }, {@link ConversationsSelect },\n{@link ChannelsSelect }."; }; readonly UsersSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "users_select"; readonly description: "The type of element. In this case `type` is always `users_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_user: { readonly type: "string"; readonly description: "The user ID of any valid user to be pre-selected when the menu loads."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This select menu will populate its options with a list of Slack users visible to the current user in the\nactive workspace."; }; readonly StaticSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "static_select"; readonly description: "The type of element. In this case `type` is always `static_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_option: { readonly $ref: "#/definitions/PlainTextOption"; readonly description: "A single option that exactly matches one of the options within `options` or `option_groups`.\nThis option will be selected when the menu initially loads."; }; readonly options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/PlainTextOption"; }; readonly description: "An array of {@link PlainTextOption }. Maximum number of options is 100. If `option_groups` is\nspecified, this field should not be."; }; readonly option_groups: { readonly type: "array"; readonly items: { readonly type: "object"; readonly properties: { readonly label: { readonly $ref: "#/definitions/PlainTextElement"; }; readonly options: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/PlainTextOption"; }; }; }; readonly required: readonly ["label", "options"]; readonly additionalProperties: false; }; readonly description: "An array of option group objects. Maximum number of option groups is 100. If `options` is specified,\nthis field should not be."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This is the simplest form of select menu, with a static list of options passed in when defining the\nelement."; }; readonly ConversationsSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "conversations_select"; readonly description: "The type of element. In this case `type` is always `conversations_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_conversation: { readonly type: "string"; readonly description: "The ID of any valid conversation to be pre-selected when the menu loads. If\n`default_to_current_conversation` is also supplied, `initial_conversation` will take precedence."; }; readonly response_url_enabled: { readonly type: "boolean"; readonly description: "When set to `true`, the {@link https://api.slack.com/reference/interaction-payloads/views#view_submission `view_submission` payload}\nfrom the menu's parent view will contain a `response_url`. This `response_url` can be used for\n{@link https://api.slack.com/interactivity/handling#message_responses message responses}. The target conversation\nfor the message will be determined by the value of this select menu."; }; readonly default_to_current_conversation: { readonly type: "boolean"; readonly description: "Pre-populates the select menu with the conversation that the user was viewing when they opened the\nmodal, if available. Default is `false`."; }; readonly filter: { readonly type: "object"; readonly properties: { readonly include: { readonly type: "array"; readonly items: { readonly type: "string"; readonly enum: readonly ["im", "mpim", "private", "public"]; }; }; readonly exclude_external_shared_channels: { readonly type: "boolean"; }; readonly exclude_bot_users: { readonly type: "boolean"; }; }; readonly additionalProperties: false; readonly description: "A filter object that reduces the list of available conversations using the specified criteria."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This select menu will populate its options with a list of public and private channels, DMs, and MPIMs\nvisible to the current user in the active workspace."; }; readonly ChannelsSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "channels_select"; readonly description: "The type of element. In this case `type` is always `channels_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_channel: { readonly type: "string"; readonly description: "The ID of any valid public channel to be pre-selected when the menu loads."; }; readonly response_url_enabled: { readonly type: "boolean"; readonly description: "When set to `true`, the {@link https://api.slack.com/reference/interaction-payloads/views#view_submission `view_submission` payload}\nfrom the menu's parent view will contain a `response_url`. This `response_url` can be used for\n{@link https://api.slack.com/interactivity/handling#message_responses message responses}. The target channel\nfor the message will be determined by the value of this select menu."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This select menu will populate its options with a list of public channels visible to the current user\nin the active workspace."; }; readonly ExternalSelect: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "external_select"; readonly description: "The type of element. In this case `type` is always `external_select`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_option: { readonly $ref: "#/definitions/PlainTextOption"; readonly description: "A single option to be selected when the menu initially loads."; }; readonly min_query_length: { readonly type: "number"; readonly description: "When the typeahead field is used, a request will be sent on every character change. If you prefer\nfewer requests or more fully ideated queries, use the `min_query_length` attribute to tell Slack the fewest number\nof typed characters required before dispatch. The default value is `3`."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "This select menu will load its options from an external data source, allowing for a dynamic list of\noptions."; }; readonly Timepicker: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "timepicker"; readonly description: "The type of element. In this case `type` is always `timepicker`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_time: { readonly type: "string"; readonly description: "The initial time that is selected when the element is loaded. This should be in the format `HH:mm`,\nwhere `HH` is the 24-hour format of an hour (00 to 23) and `mm` is minutes with leading zeros (00 to 59),\nfor example 22:25 for 10:25pm."; }; readonly timezone: { readonly type: "string"; readonly description: "A string in the IANA format, e.g. \"America/Chicago\". The timezone is displayed to end users as hint\ntext underneath the time picker. It is also passed to the app upon certain interactions, such as view_submission."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "Allows users to choose a time from a rich dropdown UI. On desktop clients, this time picker will take\nthe form of a dropdown list with free-text entry for precise choices. On mobile clients, the time picker will use\nnative time picker UIs."; }; readonly WorkflowButton: { readonly type: "object"; readonly properties: { readonly confirm: { readonly $ref: "#/definitions/ConfirmationDialog"; readonly description: "A {@link Confirm } object that defines an optional confirmation dialog after the element is interacted\nwith."; }; readonly type: { readonly type: "string"; readonly const: "workflow_button"; readonly description: "The type of element. In this case `type` is always `workflow_button`."; }; readonly text: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } that defines the button's text. `text` may truncate with ~30 characters.\nMaximum length for the `text` in this field is 75 characters."; }; readonly workflow: { readonly type: "object"; readonly properties: { readonly trigger: { readonly type: "object"; readonly properties: { readonly url: { readonly type: "string"; readonly description: "The trigger URL of the {@link https://api.slack.com/automation/triggers/link#workflow_buttons link trigger}"; }; readonly customizable_input_parameters: { readonly type: "array"; readonly items: { readonly type: "object"; readonly properties: { readonly name: { readonly type: "string"; readonly description: "Name of the customizable input, which should be the name of a workflow input parameter for the\nmatching workflow of the link trigger."; }; readonly value: { readonly type: "string"; readonly description: "The value of the customizable input parameter. The type of the value is expected to match the\nspecified type for the matching workflow input parameter."; }; }; readonly required: readonly ["name", "value"]; readonly additionalProperties: false; }; readonly description: "List of customizable input parameters and their values. Should match input parameters specified on\nthe provided trigger."; }; }; readonly required: readonly ["url"]; readonly additionalProperties: false; readonly description: "Properties of the {@link https://api.slack.com/automation/triggers/link#workflow_buttons link trigger}that will be invoked via this button."; }; }; readonly required: readonly ["trigger"]; readonly additionalProperties: false; readonly description: "A workflow object that contains details about the workflow that will run when the button is clicked."; }; readonly style: { readonly type: "string"; readonly enum: readonly ["danger", "primary"]; readonly description: "Decorates buttons with alternative visual color schemes. Use this option with restraint.\n`primary` gives buttons a green outline and text, ideal for affirmation or confirmation actions. `primary` should\nonly be used for one button within a set.\n`danger` gives buttons a red outline and text, and should be used when the action is destructive. Use `danger` even\nmore sparingly than primary.\nIf you don't include this field, the default button style will be used."; }; readonly accessibility_label: { readonly type: "string"; readonly description: "A label for longer descriptive text about a button element. This label will be read out by screen\nreaders instead of the button `text` object. Maximum length for this field is 75 characters."; }; }; readonly required: readonly ["type", "text", "workflow"]; readonly additionalProperties: false; readonly description: "Allows users to run a {@link https://api.slack.com/automation/triggers/link#workflow_buttons link trigger} with customizable inputs."; }; readonly RichTextInput: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly dispatch_action_config: { readonly $ref: "#/definitions/DispatchActionConfig"; }; readonly type: { readonly type: "string"; readonly const: "rich_text_input"; readonly description: "The type of element. In this case `type` is always `rich_text_input`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_value: { readonly $ref: "#/definitions/RichTextBlock"; readonly description: "Initial contents of the input when it is loaded."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "A rich text input creates a composer/WYSIWYG editor for entering formatted text, offering nearly the\nsame experience you have writing messages in Slack."; }; readonly Dispatchable: { readonly type: "object"; readonly properties: { readonly dispatch_action_config: { readonly $ref: "#/definitions/DispatchActionConfig"; }; }; readonly additionalProperties: false; }; readonly DispatchActionConfig: { readonly type: "object"; readonly properties: { readonly trigger_actions_on: { readonly type: "array"; readonly items: { readonly type: "string"; readonly enum: readonly ["on_enter_pressed", "on_character_entered"]; }; readonly description: "An array of interaction types that you would like to receive a\n{@link https://api.slack.com/reference/interaction-payloads/block-actions `block_actions` payload} for. Should be\none or both of:\n`on_enter_pressed` — payload is dispatched when user presses the enter key while the input is in focus. Hint\ntext will appear underneath the input explaining to the user to press enter to submit.\n`on_character_entered` — payload is dispatched when a character is entered (or removed) in the input."; }; }; readonly additionalProperties: false; readonly description: "Defines when a {@link PlainTextElement } will return a {@link https://api.slack.com/reference/interaction-payloads/block-actions `block_actions` interaction payload}."; }; readonly RichTextBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "rich_text"; readonly description: "The type of block. For a rich text block, `type` is always `rich_text`."; }; readonly block_id: { readonly type: "string"; readonly description: "A string acting as a unique identifier for a block. If not specified, a `block_id` will be generated.\nYou can use this `block_id` when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}.\nMaximum length for this field is 255 characters. `block_id` should be unique for each message and each iteration of\na message. If a message is updated, use a new `block_id`."; }; readonly elements: { readonly type: "array"; readonly items: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/RichTextSection"; }, { readonly $ref: "#/definitions/RichTextList"; }, { readonly $ref: "#/definitions/RichTextQuote"; }, { readonly $ref: "#/definitions/RichTextPreformatted"; }]; }; }; }; readonly required: readonly ["elements", "type"]; readonly additionalProperties: false; }; readonly RichTextSection: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "rich_text_section"; readonly description: "The type of element. In this case `type` is always `rich_text_section`."; }; readonly elements: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/RichTextElement"; }; }; }; readonly required: readonly ["type", "elements"]; readonly additionalProperties: false; readonly description: "A section block within a rich text field."; }; readonly RichTextElement: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/RichTextBroadcastMention"; }, { readonly $ref: "#/definitions/RichTextColor"; }, { readonly $ref: "#/definitions/RichTextChannelMention"; }, { readonly $ref: "#/definitions/RichTextDate"; }, { readonly $ref: "#/definitions/RichTextEmoji"; }, { readonly $ref: "#/definitions/RichTextLink"; }, { readonly $ref: "#/definitions/RichTextTeamMention"; }, { readonly $ref: "#/definitions/RichTextText"; }, { readonly $ref: "#/definitions/RichTextUserMention"; }, { readonly $ref: "#/definitions/RichTextUsergroupMention"; }]; readonly description: "Union of rich text sub-elements for use within rich text blocks."; }; readonly RichTextBroadcastMention: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; }; readonly type: { readonly type: "string"; readonly const: "broadcast"; readonly description: "The type of element. In this case `type` is always `broadcast`."; }; readonly range: { readonly type: "string"; readonly enum: readonly ["here", "channel", "everyone"]; readonly description: "The range of the broadcast; can be one of `here`, `channel` and `everyone`."; }; }; readonly required: readonly ["type", "range"]; readonly additionalProperties: false; readonly description: "A broadcast mention element for use in a rich text message."; }; readonly RichTextStyleable: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; }; }; readonly additionalProperties: false; readonly description: "For use styling Rich Text message sub-elements."; }; readonly RichTextColor: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; }; readonly type: { readonly type: "string"; readonly const: "color"; readonly description: "The type of element. In this case `type` is always `color`."; }; readonly value: { readonly type: "string"; readonly description: "The hex value for the color."; }; }; readonly required: readonly ["type", "value"]; readonly additionalProperties: false; readonly description: "A hex color element for use in a rich text message."; }; readonly RichTextChannelMention: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; }; readonly type: { readonly type: "string"; readonly const: "channel"; readonly description: "The type of element. In this case `type` is always `channel`."; }; readonly channel_id: { readonly type: "string"; readonly description: "The encoded channel ID, e.g. C1234ABCD."; }; }; readonly required: readonly ["type", "channel_id"]; readonly additionalProperties: false; readonly description: "A channel mention element for use in a rich text message."; }; readonly RichTextDate: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; }; readonly type: { readonly type: "string"; readonly const: "date"; readonly description: "The type of element. In this case `type` is always `date`."; }; readonly timestamp: { readonly type: "number"; readonly description: "A UNIX timestamp for the date to be displayed in seconds."; }; readonly format: { readonly type: "string"; readonly description: "A template string containing curly-brace-enclosed tokens to substitute your provided `timestamp`\nin a particularly-formatted way. For example: `Posted at {date_long}`. The available date formatting tokens are:\n- `{day_divider_pretty}`: Shows `today`, `yesterday` or `tomorrow` if applicable. Otherwise, if the date is in\ncurrent year, uses the `{date_long}` format without the year. Otherwise, falls back to using the `{date_long}`\nformat.\n- `{date_num}`: Shows date as YYYY-MM-DD.\n- `{date_slash}`: Shows date as DD/MM/YYYY (subject to locale preferences).\n- `{date_long}`: Shows date as a long-form sentence including day-of-week, e.g. `Monday, December 23rd, 2013`.\n- `{date_long_full}`: Shows date as a long-form sentence without day-of-week, e.g. `August 9, 2020`.\n- `{date_long_pretty}`: Shows `yesterday`, `today` or `tomorrow`, otherwise uses the `{date_long}` format.\n- `{date}`: Same as `{date_long_full}` but without the year.\n- `{date_pretty}`: Shows `today`, `yesterday` or `tomorrow` if applicable, otherwise uses the `{date}` format.\n- `{date_short}`: Shows date using short month names without day-of-week, e.g. `Aug 9, 2020`.\n- `{date_short_pretty}`: Shows `today`, `yesterday` or `tomorrow` if applicable, otherwise uses the `{date_short}`\nformat.\n- `{time}`: Depending on user preferences, shows just the time-of-day portion of the timestamp using either 12 or\n24 hour clock formats, e.g. `2:34 PM` or `14:34`.\n- `{time_secs}`: Depending on user preferences, shows just the time-of-day portion of the timestamp using either 12\nor 24 hour clock formats, including seconds, e.g. `2:34:56 PM` or `14:34:56`.\n- `{ago}`: A human-readable period of time, e.g. `3 minutes ago`, `4 hours ago`, `2 days ago`.\nTODO: test/document `{member_local_time}`, `{status_expiration}` and `{calendar_header}`"; }; readonly url: { readonly type: "string"; readonly description: "URL to link the entire `format` string to."; }; readonly fallback: { readonly type: "string"; readonly description: "Text to display in place of the date should parsing, formatting or displaying fails."; }; }; readonly required: readonly ["type", "timestamp", "format"]; readonly additionalProperties: false; readonly description: "A date element for use in a rich text message."; }; readonly RichTextEmoji: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; }; readonly type: { readonly type: "string"; readonly const: "emoji"; readonly description: "The type of element. In this case `type` is always `emoji`."; }; readonly name: { readonly type: "string"; readonly description: "Name of emoji, without colons or skin tones, e.g. `wave`"; }; readonly unicode: { readonly type: "string"; readonly description: "Lowercase hexadecimal Unicode representation of a standard emoji (not for use with custom emoji)."; }; readonly url: { readonly type: "string"; readonly description: "URL of emoji asset. Only used when sharing custom emoji across workspaces."; }; }; readonly required: readonly ["type", "name"]; readonly additionalProperties: false; readonly description: "An emoji element for use in a rich text message."; }; readonly RichTextLink: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; readonly description: "A limited style object for styling rich text message elements\n(excluding pre-formatted, or code, elements)."; }; readonly type: { readonly type: "string"; readonly const: "link"; readonly description: "The type of element. In this case `type` is always `link`."; }; readonly text: { readonly type: "string"; readonly description: "The text to link."; }; readonly unsafe: { readonly type: "boolean"; readonly description: "TODO: ?"; }; readonly url: { readonly type: "string"; readonly description: "URL to link to."; }; }; readonly required: readonly ["type", "url"]; readonly additionalProperties: false; readonly description: "A link element for use in a rich text message."; }; readonly RichTextTeamMention: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; readonly description: "A limited style object for styling rich text message elements\n(excluding pre-formatted, or code, elements)."; }; readonly type: { readonly type: "string"; readonly const: "team"; readonly description: "The type of element. In this case `type` is always `team`."; }; readonly team_id: { readonly type: "string"; readonly description: "The encoded team ID, e.g. T1234ABCD."; }; }; readonly required: readonly ["type", "team_id"]; readonly additionalProperties: false; readonly description: "A workspace or team mention element for use in a rich text message."; }; readonly RichTextText: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; readonly description: "A limited style object for styling rich text message elements\n(excluding pre-formatted, or code, elements)."; }; readonly type: { readonly type: "string"; readonly const: "text"; readonly description: "The type of element. In this case `type` is always `text`."; }; readonly text: { readonly type: "string"; readonly description: "The text to render."; }; }; readonly required: readonly ["type", "text"]; readonly additionalProperties: false; readonly description: "A generic text element for use in a rich text message."; }; readonly RichTextUserMention: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; readonly description: "A limited style object for styling rich text message elements\n(excluding pre-formatted, or code, elements)."; }; readonly type: { readonly type: "string"; readonly const: "user"; readonly description: "The type of element. In this case `type` is always `user`."; }; readonly user_id: { readonly type: "string"; readonly description: "The encoded user ID, e.g. U1234ABCD."; }; }; readonly required: readonly ["type", "user_id"]; readonly additionalProperties: false; readonly description: "A user mention element for use in a rich text message."; }; readonly RichTextUsergroupMention: { readonly type: "object"; readonly properties: { readonly style: { readonly type: "object"; readonly properties: { readonly bold: { readonly type: "boolean"; }; readonly italic: { readonly type: "boolean"; }; readonly strike: { readonly type: "boolean"; }; readonly highlight: { readonly type: "boolean"; }; }; readonly additionalProperties: false; readonly description: "A limited style object for styling rich text message elements\n(excluding pre-formatted, or code, elements)."; }; readonly type: { readonly type: "string"; readonly const: "usergroup"; readonly description: "The type of element. In this case `type` is always `usergroup`."; }; readonly usergroup_id: { readonly type: "string"; readonly description: "The encoded usergroup ID, e.g. S1234ABCD."; }; }; readonly required: readonly ["type", "usergroup_id"]; readonly additionalProperties: false; readonly description: "A usergroup mention element for use in a rich text message."; }; readonly RichTextList: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "rich_text_list"; readonly description: "The type of element. In this case `type` is always `rich_text_list`."; }; readonly elements: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/RichTextSection"; }; readonly description: "An array of {@link RichTextSection } elements comprising each list item."; }; readonly style: { readonly type: "string"; readonly enum: readonly ["bullet", "ordered"]; readonly description: "The type of list. Can be either `bullet` (the list points are all rendered the same way) or `ordered`\n(the list points increase numerically from 1)."; }; readonly indent: { readonly type: "number"; readonly description: "The style of the list points. Can be a number from `0` (default) to `8`. Yields a different character\nor characters rendered as the list points. Also affected by the `style` property."; }; readonly border: { readonly type: "number"; readonly enum: readonly [0, 1]; readonly description: "Whether to render a quote-block-like border on the inline side of the list. `0` renders no border\nwhile `1` renders a border."; }; }; readonly required: readonly ["type", "elements", "style"]; readonly additionalProperties: false; readonly description: "A list block within a rich text field."; }; readonly RichTextQuote: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "rich_text_quote"; readonly description: "The type of element. In this case `type` is always `rich_text_quote`."; }; readonly elements: { readonly type: "array"; readonly items: { readonly $ref: "#/definitions/RichTextElement"; }; readonly description: "An array of {@link RichTextElement } comprising the quote block."; }; }; readonly required: readonly ["type", "elements"]; readonly additionalProperties: false; readonly description: "A quote block within a rich text field."; }; readonly RichTextPreformatted: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "rich_text_preformatted"; readonly description: "The type of element. In this case `type` is always `rich_text_preformatted`."; }; readonly elements: { readonly type: "array"; readonly items: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/RichTextText"; }, { readonly $ref: "#/definitions/RichTextLink"; }]; }; readonly description: "An array of either {@link RichTextLink } or {@link RichTextText } comprising the preformatted text."; }; readonly border: { readonly type: "number"; readonly enum: readonly [0, 1]; readonly description: "Whether to render a quote-block-like border on the inline side of the preformatted text.\n`0` renders no border, while `1` renders a border. Defaults to `0`."; }; }; readonly required: readonly ["type", "elements"]; readonly additionalProperties: false; readonly description: "A block of preformatted text within a rich text field."; }; readonly DividerBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "divider"; readonly description: "The type of block. For a divider block, `type` is always `divider`."; }; readonly block_id: { readonly type: "string"; readonly description: "A string acting as a unique identifier for a block. If not specified, a `block_id` will be generated.\nYou can use this `block_id` when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}.\nMaximum length for this field is 255 characters. `block_id` should be unique for each message and each iteration of\na message. If a message is updated, use a new `block_id`."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; }; readonly SectionBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "section"; readonly description: "The type of block. For a section block, `type` is always `section`."; }; readonly block_id: { readonly type: "string"; readonly description: "A string acting as a unique identifier for a block. If not specified, a `block_id` will be generated.\nYou can use this `block_id` when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}.\nMaximum length for this field is 255 characters. `block_id` should be unique for each message and each iteration of\na message. If a message is updated, use a new `block_id`."; }; readonly text: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/PlainTextElement"; }, { readonly $ref: "#/definitions/MrkdwnElement"; }]; readonly description: "The text for the block, in the form of a text object. Minimum length for the `text` in this field is\n1 and maximum length is 3000 characters. This field is not required if a valid array of `fields` objects is\nprovided instead."; }; readonly fields: { readonly type: "array"; readonly items: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/PlainTextElement"; }, { readonly $ref: "#/definitions/MrkdwnElement"; }]; }; readonly description: "Required if no `text` is provided. An array of text objects. Any text objects included with `fields`\nwill be rendered in a compact format that allows for 2 columns of side-by-side text. Maximum number of items is 10.\nMaximum length for the text in each item is 2000 characters.\n{@link https://app.slack.com/block-kit-builder/#%7B%22blocks%22:%5B%7B%22type%22:%22section%22,%22text%22:%7B%22text%22:%22A%20message%20*with%20some%20bold%20text*%20and%20_some%20italicized%20text_.%22,%22type%22:%22mrkdwn%22%7D,%22fields%22:%5B%7B%22type%22:%22mrkdwn%22,%22text%22:%22*Priority*%22%7D,%7B%22type%22:%22mrkdwn%22,%22text%22:%22*Type*%22%7D,%7B%22type%22:%22plain_text%22,%22text%22:%22High%22%7D,%7B%22type%22:%22plain_text%22,%22text%22:%22String%22%7D%5D%7D%5D%7D Click here for an example}."; }; readonly accessory: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/Button"; }, { readonly $ref: "#/definitions/Overflow"; }, { readonly $ref: "#/definitions/Datepicker"; }, { readonly $ref: "#/definitions/Timepicker"; }, { readonly $ref: "#/definitions/Select"; }, { readonly $ref: "#/definitions/MultiSelect"; }, { readonly $ref: "#/definitions/Actionable"; }, { readonly $ref: "#/definitions/ImageElement"; }, { readonly $ref: "#/definitions/RadioButtons"; }, { readonly $ref: "#/definitions/Checkboxes"; }]; readonly description: "One of the compatible element objects."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "Displays text, possibly alongside block elements. A section can be used as a simple text block, in\ncombination with text fields, or side-by-side with certain\n{@link https://api.slack.com/reference/messaging/block-elements block elements}."; }; readonly InputBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "input"; readonly description: "The type of block. For an input block, `type` is always `input`."; }; readonly block_id: { readonly type: "string"; readonly description: "A string acting as a unique identifier for a block. If not specified, a `block_id` will be generated.\nYou can use this `block_id` when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}.\nMaximum length for this field is 255 characters. `block_id` should be unique for each message and each iteration of\na message. If a message is updated, use a new `block_id`."; }; readonly label: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A label that appears above an input element in the form of a {@link PlainTextElement } object.\nMaximum length for the text in this field is 2000 characters."; }; readonly hint: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "An optional hint that appears below an input element in a lighter grey. It must be a\n{@link PlainTextElement object}. Maximum length for the `text` in this field is 2000 characters."; }; readonly optional: { readonly type: "boolean"; readonly description: "A boolean that indicates whether the input element may be empty when a user submits the modal.\nDefaults to `false`."; }; readonly element: { readonly anyOf: readonly [{ readonly $ref: "#/definitions/Select"; }, { readonly $ref: "#/definitions/MultiSelect"; }, { readonly $ref: "#/definitions/Datepicker"; }, { readonly $ref: "#/definitions/Timepicker"; }, { readonly $ref: "#/definitions/DateTimepicker"; }, { readonly $ref: "#/definitions/PlainTextInput"; }, { readonly $ref: "#/definitions/URLInput"; }, { readonly $ref: "#/definitions/EmailInput"; }, { readonly $ref: "#/definitions/NumberInput"; }, { readonly $ref: "#/definitions/RadioButtons"; }, { readonly $ref: "#/definitions/Checkboxes"; }, { readonly $ref: "#/definitions/RichTextInput"; }]; readonly description: "A block element."; }; readonly dispatch_action: { readonly type: "boolean"; readonly description: "A boolean that indicates whether or not the use of elements in this block should dispatch a\n{@link https://api.slack.com/reference/interaction-payloads/block-actions block_actions payload}. Defaults to `false`."; }; }; readonly required: readonly ["element", "label", "type"]; readonly additionalProperties: false; readonly description: "Collects information from users via block elements."; }; readonly PlainTextInput: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly dispatch_action_config: { readonly $ref: "#/definitions/DispatchActionConfig"; }; readonly type: { readonly type: "string"; readonly const: "plain_text_input"; readonly description: "The type of element. In this case `type` is always `plain_text_input`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_value: { readonly type: "string"; readonly description: "The initial value in the plain-text input when it is loaded."; }; readonly multiline: { readonly type: "boolean"; readonly description: "Indicates whether the input will be a single line (`false`) or a larger textarea (`true`).\nDefaults to `false`."; }; readonly min_length: { readonly type: "number"; readonly description: "The minimum length of input that the user must provide. If the user provides less, they will receive\nan error. Maximum value is 3000."; }; readonly max_length: { readonly type: "number"; readonly description: "The maximum length of input that the user can provide. If the user provides more,\nthey will receive an error."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "Allows users to enter freeform text data into a single-line or multi-line field."; }; readonly URLInput: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly dispatch_action_config: { readonly $ref: "#/definitions/DispatchActionConfig"; }; readonly type: { readonly type: "string"; readonly const: "url_text_input"; readonly description: "The type of element. In this case `type` is always `url_text_input`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_value: { readonly type: "string"; readonly description: "The initial value in the URL input when it is loaded."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "Allows user to enter a URL into a single-line field."; }; readonly EmailInput: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly dispatch_action_config: { readonly $ref: "#/definitions/DispatchActionConfig"; readonly description: "A {@link DispatchActionConfig } object that determines when during text input the element returns a\n{@link https://api.slack.com/reference/interaction-payloads/block-actions `block_actions` payload}."; }; readonly type: { readonly type: "string"; readonly const: "email_text_input"; readonly description: "The type of element. In this case `type` is always `email_text_input`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly initial_value: { readonly type: "string"; readonly description: "The initial value in the email input when it is loaded."; }; }; readonly required: readonly ["type"]; readonly additionalProperties: false; readonly description: "Allows user to enter an email into a single-line field."; }; readonly NumberInput: { readonly type: "object"; readonly properties: { readonly placeholder: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "A {@link PlainTextElement } object that defines the placeholder text shown on the element. Maximum\nlength for the `text` field in this object is 150 characters."; }; readonly focus_on_load: { readonly type: "boolean"; readonly description: "Indicates whether the element will be set to auto focus within the\n{@link https://api.slack.com/reference/surfaces/views `view` object}. Only one element can be set to `true`.\nDefaults to `false`."; }; readonly dispatch_action_config: { readonly $ref: "#/definitions/DispatchActionConfig"; readonly description: "A {@link DispatchActionConfig } object that determines when during text input the element returns a\n{@link https://api.slack.com/reference/interaction-payloads/block-actions `block_actions` payload}."; }; readonly type: { readonly type: "string"; readonly const: "number_input"; readonly description: "The type of element. In this case `type` is always `number_input`."; }; readonly action_id: { readonly type: "string"; readonly description: ": An identifier for this action. You can use this when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}. Should be unique\namong all other `action_id`s in the containing block. Maximum length for this field is 255 characters."; }; readonly is_decimal_allowed: { readonly type: "boolean"; readonly description: "Decimal numbers are allowed if this property is `true`, set the value to `false` otherwise."; }; readonly initial_value: { readonly type: "string"; readonly description: "The initial value in the input when it is loaded."; }; readonly min_value: { readonly type: "string"; readonly description: "The minimum value, cannot be greater than `max_value`."; }; readonly max_value: { readonly type: "string"; readonly description: "The maximum value, cannot be less than `min_value`."; }; }; readonly required: readonly ["is_decimal_allowed", "type"]; readonly additionalProperties: false; readonly description: "Allows user to enter a number into a single-line field. The number input element accepts both whole and\ndecimal numbers. For example, 0.25, 5.5, and -10 are all valid input values. Decimal numbers are only allowed when\n`is_decimal_allowed` is equal to `true`."; }; readonly FileBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "file"; readonly description: "The type of block. For a file block, `type` is always `file`."; }; readonly block_id: { readonly type: "string"; readonly description: "A string acting as a unique identifier for a block. If not specified, a `block_id` will be generated.\nYou can use this `block_id` when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}.\nMaximum length for this field is 255 characters. `block_id` should be unique for each message and each iteration of\na message. If a message is updated, use a new `block_id`."; }; readonly source: { readonly type: "string"; readonly description: "At the moment, source will always be `remote` for a remote file."; }; readonly external_id: { readonly type: "string"; readonly description: "The external unique ID for this file."; }; }; readonly required: readonly ["external_id", "source", "type"]; readonly additionalProperties: false; readonly description: "Displays a {@link https://api.slack.com/messaging/files/remote remote file}. You can't add this block to\napp surfaces directly, but it will show up when {@link https://api.slack.com/messaging/retrieving retrieving messages}\nthat contain remote files. If you want to add remote files to messages,\n{@link https://api.slack.com/messaging/files/remote follow our guide}."; }; readonly HeaderBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "header"; readonly description: "The type of block. For a header block, `type` is always `header`."; }; readonly block_id: { readonly type: "string"; readonly description: "A string acting as a unique identifier for a block. If not specified, a `block_id` will be generated.\nYou can use this `block_id` when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}.\nMaximum length for this field is 255 characters. `block_id` should be unique for each message and each iteration of\na message. If a message is updated, use a new `block_id`."; }; readonly text: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "The text for the block, in the form of a {@link PlainTextElement }.\nMaximum length for the text in this field is 150 characters."; }; }; readonly required: readonly ["text", "type"]; readonly additionalProperties: false; readonly description: "Displays a larger-sized text block. A `header` is a plain-text block that displays in a larger, bold\nfont. Use it to delineate between different groups of content in your app's surfaces."; }; readonly VideoBlock: { readonly type: "object"; readonly properties: { readonly type: { readonly type: "string"; readonly const: "video"; readonly description: "The type of block. For a video block, `type` is always `video`."; }; readonly block_id: { readonly type: "string"; readonly description: "A string acting as a unique identifier for a block. If not specified, a `block_id` will be generated.\nYou can use this `block_id` when you receive an interaction payload to\n{@link https://api.slack.com/interactivity/handling#payloads identify the source of the action}.\nMaximum length for this field is 255 characters. `block_id` should be unique for each message and each iteration of\na message. If a message is updated, use a new `block_id`."; }; readonly video_url: { readonly type: "string"; readonly description: "The URL to be embedded. Must match any existing\n{@link https://api.slack.com/reference/messaging/link-unfurling#configuring_domains unfurl domains} within the app\nand point to a HTTPS URL."; }; readonly thumbnail_url: { readonly type: "string"; readonly description: "The thumbnail image URL."; }; readonly alt_text: { readonly type: "string"; readonly description: "A tooltip for the video. Required for accessibility."; }; readonly title: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "Video title as a {@link PlainTextElement } object. `text` within must be less than 200 characters."; }; readonly title_url: { readonly type: "string"; readonly description: "Hyperlink for the title text. Must correspond to the non-embeddable URL for the video.\nMust go to an HTTPS URL."; }; readonly author_name: { readonly type: "string"; readonly description: "Author name to be displayed. Must be less than 50 characters."; }; readonly provider_name: { readonly type: "string"; readonly description: "The originating application or domain of the video, e.g. YouTube."; }; readonly provider_icon_url: { readonly type: "string"; readonly description: "Icon for the video provider, e.g. YouTube icon."; }; readonly description: { readonly $ref: "#/definitions/PlainTextElement"; readonly description: "Description for video using a {@link PlainTextElement } object."; }; }; readonly required: readonly ["alt_text", "thumbnail_url", "title", "type", "video_url"]; readonly additionalProperties: false; readonly description: "Displays an embedded video player. A video block is designed to embed videos in all app surfaces (e.g.\nlink unfurls, messages, modals, App Home) — anywhere you can put blocks! To use the video block within your app, you\nmust have the {@link https://api.slack.com/scopes/links.embed:write `links.embed:write` scope}."; }; }; readonly additionalProperties: false; }; }; }; sms: {}; email: { sendgrid: { output: { readonly type: "object"; readonly properties: { readonly ipPoolName: { readonly type: "string"; }; }; readonly required: readonly ["ipPoolName"]; readonly additionalProperties: false; }; }; }; push: {}; in_app: {}; }; declare const delayOutputSchema: { readonly type: "object"; readonly properties: { readonly type: { readonly enum: readonly ["regular"]; readonly default: "regular"; }; readonly amount: { readonly type: "number"; }; readonly unit: { readonly type: "string"; readonly enum: readonly ["seconds", "minutes", "hours", "days", "weeks", "months"]; }; }; readonly required: readonly ["amount", "unit"]; readonly additionalProperties: false; }; declare const delayResultSchema: { readonly type: "object"; readonly properties: { readonly duration: { readonly type: "number"; }; }; readonly required: readonly ["duration"]; readonly additionalProperties: false; }; declare const digestOutputSchema: { readonly type: "object"; readonly properties: { readonly amount: { readonly type: "number"; }; readonly unit: { readonly type: "string"; readonly enum: readonly ["seconds", "minutes", "hours", "days", "weeks", "months"]; }; }; readonly required: readonly ["amount", "unit"]; readonly additionalProperties: false; }; declare const digestResultSchema: { readonly type: "object"; readonly properties: { readonly events: { readonly type: "array"; readonly items: { readonly type: "object"; readonly properties: { readonly id: { readonly type: "string"; }; readonly time: { readonly type: "string"; }; readonly payload: { readonly type: "object"; }; }; readonly required: readonly ["id", "time", "payload"]; readonly additionalProperties: false; }; }; }; readonly required: readonly ["events"]; readonly additionalProperties: false; }; declare const channelStepSchemas: { chat: { output: { readonly type: "object"; readonly properties: { readonly body: { readonly type: "string"; }; }; readonly required: readonly ["body"]; readonly additionalProperties: false; }; result: { readonly type: "object"; readonly properties: {}; readonly required: readonly []; readonly additionalProperties: false; }; }; sms: { output: { readonly type: "object"; readonly properties: { readonly body: { readonly type: "string"; }; }; readonly required: readonly ["body"]; readonly additionalProperties: false; }; result: { readonly type: "object"; readonly properties: {}; readonly required: readonly []; readonly additionalProperties: false; }; }; push: { output: { readonly type: "object"; readonly properties: { readonly subject: { readonly type: "string"; }; readonly body: { readonly type: "string"; }; }; readonly required: readonly ["subject", "body"]; readonly additionalProperties: false; }; result: { readonly type: "object"; readonly properties: {}; readonly required: readonly []; readonly additionalProperties: false; }; }; email: { output: { readonly type: "object"; readonly properties: { readonly subject: { readonly type: "string"; }; readonly body: { readonly type: "string"; }; }; readonly required: readonly ["subject", "body"]; readonly additionalProperties: false; }; result: { readonly type: "object"; readonly properties: {}; readonly required: readonly []; readonly additionalProperties: false; }; }; in_app: { output: { readonly type: "object"; readonly properties: { readonly body: { readonly type: "string"; }; }; readonly required: readonly ["body"]; readonly additionalProperties: false; }; result: { readonly type: "object"; readonly properties: { readonly seen: { readonly type: "boolean"; }; readonly read: { readonly type: "boolean"; }; readonly lastSeenDate: { readonly type: "string"; readonly format: "date-time"; readonly nullable: true; }; readonly lastReadDate: { readonly type: "string"; readonly format: "date-time"; readonly nullable: true; }; }; readonly required: readonly ["seen", "read", "lastSeenDate", "lastReadDate"]; readonly additionalProperties: false; }; }; }; type Providers = { [K in keyof (typeof providerSchemas)[T_StepType]]: (step: { /** * The inputs for the step. */ inputs: T_Input; /** * The outputs of the step. */ outputs: T_Output; }) => Promise>; }; /** * A type that represents either `A` or `B`. Shared properties retain their * types and unique properties are marked as optional. */ type Either = Partial & Partial & (A | B); /** * A type that represents a value that may be a promise or a regular value. */ type Awaitable = T | Promise; type Skip = (inputs: T) => Awaitable; type ActionStepOptions = { skip?: Skip; inputSchema?: Schema; credentials?: (input: unknown) => Promise>; providers?: Record unknown | Promise>; preferences?: (input: unknown) => Promise>; }; declare enum JobStatusEnum { PENDING = "pending", QUEUED = "queued", RUNNING = "running", COMPLETED = "completed", FAILED = "failed", DELAYED = "delayed", CANCELED = "canceled", MERGED = "merged", SKIPPED = "skipped" } type StepContext = { /** The context of the step. */ _ctx: { /** The timestamp of the step. */ timestamp: number; /** The state of the step. */ state: { /** The status of the step. */ status: `${JobStatusEnum}`; /** A boolean flag to indicate if the step has errored. */ error: boolean; }; }; }; type StepOutput = Promise; type ActionStep = (name: string, resolve: (inputs: any) => Awaitable, options?: ActionStepOptions) => StepOutput; type CustomStep = < /** * The schema for the inputs of the step. */ T_InputSchema extends Schema, /** * The schema for the outputs of the step. */ T_OutputsSchema extends Schema, /** * The inputs for the step. */ T_Inputs = FromSchema, /** * The result for the step. */ T_Intermediary = FromSchema, T_Outputs extends T_Intermediary = T_Intermediary, T_Result extends T_Intermediary = T_Intermediary>( /** * The name of the step. This is used to identify the step in the workflow. */ name: string, /** * The function to resolve the step notification content for the step. * * @param inputs The inputs for the step. */ resolve: (inputs: T_Inputs) => Awaitable, /** * The options for the step. */ options?: { /** * Skip the step. If the skip function returns true, the step will be skipped. * * @param inputs The inputs for the step. */ skip?: Skip; /** * The schema for the inputs of the step. Used to validate the user-provided input from Novu Web. */ inputSchema?: T_InputSchema; outputSchema?: T_OutputsSchema; }) => Promise; type ChannelStep< /** * The type of channel step. */ T_StepType extends keyof typeof channelStepSchemas, /** * The outputs for the step. */ T_Outputs, /** * The result for the step. */ T_Result> = < /** * The schema for the inputs of the step. */ T_InputSchema extends Schema, /** * The inputs for the step. */ T_Inputs = FromSchema>( /** * The name of the step. This is used to identify the step in the workflow. */ name: string, /** * The function to resolve the step notification content for the step. * * @param inputs The inputs for the step. */ resolve: (inputs: T_Inputs) => Awaitable, /** * The options for the step. */ options?: { /** * Skip the step. If the skip function returns true, the step will be skipped. * * @param inputs The inputs for the step. */ skip?: Skip; /** * The schema for the inputs of the step. Used to validate the user-provided input from Novu Web. */ inputSchema?: T_InputSchema; /** * The providers for the step. Used to override the behaviour of the providers for the step. */ providers?: Providers; }) => Promise; type EmailOutput = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.EMAIL]['output']>; type EmailResult = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.EMAIL]['result']>; type SmsOutput = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.SMS]['output']>; type SmsResult = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.SMS]['result']>; type PushOutput = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.PUSH]['output']>; type PushResult = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.PUSH]['result']>; type ChatOutput = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.CHAT]['output']>; type ChatResult = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.CHAT]['result']>; type InAppOutput = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.IN_APP]['output']>; type InAppResult = FromSchema<(typeof channelStepSchemas)[ChannelStepEnum.IN_APP]['result']>; /** * The step type. */ type Step = { /** Send an email. */ email: ChannelStep; /** Send an SMS. */ sms: ChannelStep; /** Send a push notification. */ push: ChannelStep; /** Send a chat message. */ chat: ChannelStep; /** Send an in-app notification. */ inApp: ChannelStep; /** Aggregate events for a period of time. */ digest: ActionStep, FromSchema>; /** Delay the workflow for a period of time. */ delay: ActionStep, FromSchema>; /** Execute custom code */ custom: CustomStep; }; type Subscriber = { firstName?: string; lastName?: string; }; /** * The input for the workflow function. */ type ExecuteInput = { /** Define a step in your workflow. */ step: Step; /** The payload for the event, provided during trigger. */ payload: T_Payload; /** The subscriber for the event, provided during trigger. */ subscriber: Subscriber; /** The environment the workflow is running in. */ environment: Record; /** The inputs for the event. Provided via the UI. */ input: T_Input; }; /** * The function to execute the workflow. */ type Execute = (event: ExecuteInput) => Promise; /** * The options for the workflow. */ type WorkflowOptions = { /** The schema for the payload. */ payloadSchema?: T_PayloadSchema; /** The schema for the inputs. */ inputSchema?: T_InputSchema; }; type StepType = `${ChannelStepEnum | ActionStepEnum}`; type Validate = ValidateFunction; type DiscoverProviderOutput = { type: string; code: string; resolve: (stepInputs: unknown) => unknown | Promise; outputs: { schema: Schema; validate: Validate; }; }; type DiscoverStepOutput = { stepId: string; type: StepType; inputs: { schema: Schema; validate: Validate; }; outputs: { schema: Schema; validate: Validate; }; results: { schema: Schema; validate: Validate; }; code: string; resolve: (stepInputs: unknown) => unknown | Promise; providers: Array; options: ActionStepOptions; }; type DiscoverWorkflowOutput = { workflowId: string; execute: Execute; options: WorkflowOptions; code: string; steps: Array; data: { schema: Schema; validate: Validate; }; inputs: { schema: Schema; validate: Validate; }; }; type DiscoverOutput = { workflows: Array; }; interface IEvent { data: Record; workflowId: string; stepId: string; inputs: Record; state: IState[]; action: 'execute' | 'preview'; subscriber: Subscriber; } interface IState { stepId: string; outputs: any; state: { status: string; error?: string; }; } type ExecuteOutputMetadata = { status: string; error: boolean; /** * The duration of the step execution in milliseconds */ duration: number; }; type ExecuteOutput = { outputs: unknown; providers: unknown; options: unknown; metadata: ExecuteOutputMetadata; }; type SupportedFrameworkName = 'next' | 'express' | 'nuxt' | 'h3' | 'sveltekit' | 'remix'; type HealthCheck = { status: 'ok' | 'error'; version: string; discovered: { workflows: number; steps: number; }; }; declare class Echo { private discoveredWorkflows; private ajv; private templateEngine; private readonly backendUrl?; apiKey?: string; version: string; devModeBypassAuthentication: boolean; static NOVU_SIGNATURE_HEADER: HttpHeaderKeysEnum; constructor(config?: ClientConfig); healthCheck(): HealthCheck; /** * Define a new notification workflow. */ workflow, T_Input = FromSchema>(workflowId: string, execute: Execute, workflowOptions?: WorkflowOptions): Promise; private prettyPrintDiscovery; private discoverStepFactory; private discoverCustomStepFactory; private discoverProviders; private discoverWorkflow; private discoverStep; private getWorkflow; private getStep; private getRegisteredWorkflows; discover(): DiscoverOutput; private getHeaders; diff(echoUrl: string, anonymous?: string): Promise; sync(echoUrl: string, anonymous?: string, source?: string): Promise; /** * Mocks data based on the given schema. * The `default` value in the schema is used as the base data. * If no `default` value is provided, the data is generated using JSONSchemaFaker. * * @param schema * @returns mocked data */ private mock; private validate; private validateProvider; private validateStep; private validateEvent; private executeStepFactory; private shouldSkip; executeWorkflow(event: IEvent): Promise; private createExecutionInputs; private prettyPrintExecute; private executeProviders; private previewProvider; private executeProvider; private executeStep; private compileInputs; /** * Create the inputs for a step, taking both the event inputs and the default inputs into account * * @param step The step to create the input for * @param event The event that triggered the step * @returns The input for the step */ private createStepInputs; private previewStep; private getStepCode; private getWorkflowCode; getCode(workflowId: string, stepId?: string): CodeResult; } interface ServeHandlerOptions { client: Echo; } interface IEchoRequestHandlerOptions extends ServeHandlerOptions { frameworkName: string; client: Echo; handler: Handler; } type Handler = (...args: Input) => HandlerResponse; type HandlerResponse = { body: () => Awaitable; headers: (key: string) => Awaitable; method: () => Awaitable; queryString?: (key: string, url: URL) => Awaitable; url: () => Awaitable; transformResponse: (res: IActionResponse) => Output; }; interface IActionResponse { status: number; headers: Record; body: TBody; } declare class EchoRequestHandler { readonly frameworkName: string; readonly handler: Handler; readonly client: Echo; private readonly hmacEnabled; constructor(options: IEchoRequestHandlerOptions); createHandler(): (...args: Input) => Promise; private getStaticHeaders; private createResponse; private createError; private handleAction; private getPostActionMap; private getGetActionMap; private handlePostAction; private handleGetAction; private isClientError; private handleError; private validateHmac; private hashHmac; } export { type ActionStep, type ActionStepOptions, type Awaitable, type ChannelStep, type ChatOutput, type ChatResult, type ClientConfig, type CodeResult, type CustomStep, type DiscoverOutput, type DiscoverProviderOutput, type DiscoverStepOutput, type DiscoverWorkflowOutput, Echo, EchoRequestHandler, type Either, type EmailOutput, type EmailResult, type Execute, type ExecuteInput, type ExecuteOutput, type ExecuteOutputMetadata, type HealthCheck, type IEvent, type InAppOutput, type InAppResult, JobStatusEnum, type PushOutput, type PushResult, type ServeHandlerOptions, type SmsOutput, type SmsResult, type Step, type StepType, type Subscriber, type SupportedFrameworkName, type Validate, type WorkflowOptions };