Skip to main content

Interface: InputBlock

Description

Collects information from users via block elements.

See

Extends

Properties

block_id?

optional block_id: string;

Description

A string acting as a unique identifier for a block. If not specified, a block_id will be generated. You can use this block_id when you receive an interaction payload to identify the source of the action. Maximum length for this field is 255 characters. block_id should be unique for each message and each iteration of a message. If a message is updated, use a new block_id.

Inherited from

Block.block_id

Defined in

block-kit/blocks.ts:39


dispatch_action?

optional dispatch_action: boolean;

Description

A boolean that indicates whether or not the use of elements in this block should dispatch a block_actions payload. Defaults to false.

Defined in

block-kit/blocks.ts:245


element

element: InputBlockElement;

Description

A block element.

Defined in

block-kit/blocks.ts:240


hint?

optional hint: PlainTextElement;

Description

An optional hint that appears below an input element in a lighter grey. It must be a object. Maximum length for the text in this field is 2000 characters.

Defined in

block-kit/blocks.ts:231


label

label: PlainTextElement;

Description

A label that appears above an input element in the form of a PlainTextElement object. Maximum length for the text in this field is 2000 characters.

Defined in

block-kit/blocks.ts:226


optional?

optional optional: boolean;

Description

A boolean that indicates whether the input element may be empty when a user submits the modal. Defaults to false.

Defined in

block-kit/blocks.ts:236


type

type: "input";

Description

The type of block. For an input block, type is always input.

Overrides

Block.type

Defined in

block-kit/blocks.ts:221