Skip to main content

Elements

Generated from the actual Rust signatures and rustdoc comments. Builders validate on build(); into_builder() preserves omissions. Error categories and paths are stable; prose may improve.

ButtonElement​

An interactive button that sends a payload or opens a URL.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> ButtonElementBuilder

Related types: ButtonElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> ButtonElementBuilder

Related types: ButtonElementBuilder

text​

Borrows or copies text. Sets the button label.

fn text(&self) -> &PlainText

Related types: PlainText

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

url​

Borrows or copies url. Sets a URL opened in the user's browser when the button is clicked. Slack still sends an interaction payload.

fn url(&self) -> Option<&str>

value​

Borrows or copies value. Sets the application-defined value sent in interaction payloads.

fn value(&self) -> Option<&str>

style​

Borrows or copies style. Sets the button's emphasis. Omit it for the default neutral style.

fn style(&self) -> Option<ButtonStyle>

Related types: ButtonStyle

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

accessibility_label​

Borrows or copies accessibility_label. Sets the label read by screen readers in place of the visible text.

fn accessibility_label(&self) -> Option<&str>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

ButtonElementBuilder​

Consuming builder for ButtonElement. Validation runs in Self::build.

text​

Sets the button label.

fn text(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

url​

Sets a URL opened in the user's browser when the button is clicked. Slack still sends an interaction payload.

fn url(mut self, value: impl Into<String>) -> Self

clear_url​

Omits url, including any model default.

fn clear_url(mut self) -> Self

value​

Sets the application-defined value sent in interaction payloads.

fn value(mut self, value: impl Into<String>) -> Self

clear_value​

Omits value, including any model default.

fn clear_value(mut self) -> Self

style​

Sets the button's emphasis. Omit it for the default neutral style.

fn style(mut self, value: ButtonStyle) -> Self

Related types: ButtonStyle

clear_style​

Omits style, including any model default.

fn clear_style(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

accessibility_label​

Sets the label read by screen readers in place of the visible text.

fn accessibility_label(mut self, value: impl Into<String>) -> Self

clear_accessibility_label​

Omits accessibility_label, including any model default.

fn clear_accessibility_label(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<ButtonElement, ValidationError>

Related types: ButtonElement, ValidationError

ChannelMultiSelectElement​

A menu for selecting multiple public channels.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> ChannelMultiSelectElementBuilder

Related types: ChannelMultiSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> ChannelMultiSelectElementBuilder

Related types: ChannelMultiSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_channels​

Borrows or copies initial_channels. Adds channel IDs that are selected when the menu loads.

fn initial_channels(&self) -> Option<&[String]>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

max_selected_items​

Borrows or copies max_selected_items. Sets the maximum number of items a user can select.

fn max_selected_items(&self) -> Option<i64>

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

ChannelMultiSelectElementBuilder​

Consuming builder for ChannelMultiSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_channels​

Adds channel IDs that are selected when the menu loads. Replaces the collection; order is preserved.

fn initial_channels<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<String>,

initial_channel​

Appends one item to the collection.

fn initial_channel(mut self, value: impl Into<String>) -> Self

clear_initial_channels​

Omits initial_channels, including any model default.

fn clear_initial_channels(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

max_selected_items​

Sets the maximum number of items a user can select.

fn max_selected_items(mut self, value: i64) -> Self

clear_max_selected_items​

Omits max_selected_items, including any model default.

fn clear_max_selected_items(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<ChannelMultiSelectElement, ValidationError>

Related types: ChannelMultiSelectElement, ValidationError

ChannelSelectElement​

A menu for selecting one public channel.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> ChannelSelectElementBuilder

Related types: ChannelSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> ChannelSelectElementBuilder

Related types: ChannelSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_channel​

Borrows or copies initial_channel. Sets the channel ID selected when the menu loads.

fn initial_channel(&self) -> Option<&str>

response_url_enabled​

Borrows or copies response_url_enabled. Sets whether the selected conversation receives a response URL in the view submission payload. Only valid in modals.

fn response_url_enabled(&self) -> Option<bool>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

ChannelSelectElementBuilder​

Consuming builder for ChannelSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_channel​

Sets the channel ID selected when the menu loads.

fn initial_channel(mut self, value: impl Into<String>) -> Self

clear_initial_channel​

Omits initial_channel, including any model default.

fn clear_initial_channel(mut self) -> Self

response_url_enabled​

Sets whether the selected conversation receives a response URL in the view submission payload. Only valid in modals.

fn response_url_enabled(mut self, value: bool) -> Self

clear_response_url_enabled​

Omits response_url_enabled, including any model default.

fn clear_response_url_enabled(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<ChannelSelectElement, ValidationError>

Related types: ChannelSelectElement, ValidationError

CheckboxesElement​

A group of checkboxes.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> CheckboxesElementBuilder

Related types: CheckboxesElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> CheckboxesElementBuilder

Related types: CheckboxesElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

options​

Borrows or copies options. Adds selectable options in display order.

fn options(&self) -> &[SelectOption]

Related types: SelectOption

initial_options​

Borrows or copies initial_options. Adds options that are selected when the element loads. Each must match an option in the element.

fn initial_options(&self) -> Option<&[SelectOption]>

Related types: SelectOption

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

CheckboxesElementBuilder​

Consuming builder for CheckboxesElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

options​

Adds selectable options in display order. Replaces the collection; order is preserved.

fn options<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOption>,

Related types: SelectOption

option​

Appends one item to the collection.

fn option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

initial_options​

Adds options that are selected when the element loads. Each must match an option in the element. Replaces the collection; order is preserved.

fn initial_options<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOption>,

Related types: SelectOption

initial_option​

Appends one item to the collection.

fn initial_option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

clear_initial_options​

Omits initial_options, including any model default.

fn clear_initial_options(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<CheckboxesElement, ValidationError>

Related types: CheckboxesElement, ValidationError

ConversationMultiSelectElement​

A menu for selecting multiple conversations.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> ConversationMultiSelectElementBuilder

Related types: ConversationMultiSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> ConversationMultiSelectElementBuilder

Related types: ConversationMultiSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_conversations​

Borrows or copies initial_conversations. Adds conversation IDs that are selected when the menu loads.

fn initial_conversations(&self) -> Option<&[String]>

default_to_current_conversation​

Borrows or copies default_to_current_conversation. Sets whether the menu pre-selects the conversation the user is viewing.

fn default_to_current_conversation(&self) -> Option<bool>

filter​

Borrows or copies filter. Sets which conversation types the menu offers.

fn filter(&self) -> Option<&ConversationFilter>

Related types: ConversationFilter

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

max_selected_items​

Borrows or copies max_selected_items. Sets the maximum number of items a user can select.

fn max_selected_items(&self) -> Option<i64>

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

ConversationMultiSelectElementBuilder​

Consuming builder for ConversationMultiSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_conversations​

Adds conversation IDs that are selected when the menu loads. Replaces the collection; order is preserved.

fn initial_conversations<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<String>,

initial_conversation​

Appends one item to the collection.

fn initial_conversation(mut self, value: impl Into<String>) -> Self

clear_initial_conversations​

Omits initial_conversations, including any model default.

fn clear_initial_conversations(mut self) -> Self

default_to_current_conversation​

Sets whether the menu pre-selects the conversation the user is viewing.

fn default_to_current_conversation(mut self, value: bool) -> Self

clear_default_to_current_conversation​

Omits default_to_current_conversation, including any model default.

fn clear_default_to_current_conversation(mut self) -> Self

filter​

Sets which conversation types the menu offers.

fn filter(mut self, value: impl Into<ConversationFilter>) -> Self

Related types: ConversationFilter

clear_filter​

Omits filter, including any model default.

fn clear_filter(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

max_selected_items​

Sets the maximum number of items a user can select.

fn max_selected_items(mut self, value: i64) -> Self

clear_max_selected_items​

Omits max_selected_items, including any model default.

fn clear_max_selected_items(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<ConversationMultiSelectElement, ValidationError>

Related types: ConversationMultiSelectElement, ValidationError

ConversationSelectElement​

A menu for selecting one conversation.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> ConversationSelectElementBuilder

Related types: ConversationSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> ConversationSelectElementBuilder

Related types: ConversationSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_conversation​

Borrows or copies initial_conversation. Sets the conversation ID selected when the menu loads.

fn initial_conversation(&self) -> Option<&str>

default_to_current_conversation​

Borrows or copies default_to_current_conversation. Sets whether the menu pre-selects the conversation the user is viewing.

fn default_to_current_conversation(&self) -> Option<bool>

filter​

Borrows or copies filter. Sets which conversation types the menu offers.

fn filter(&self) -> Option<&ConversationFilter>

Related types: ConversationFilter

response_url_enabled​

Borrows or copies response_url_enabled. Sets whether the selected conversation receives a response URL in the view submission payload. Only valid in modals.

fn response_url_enabled(&self) -> Option<bool>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

ConversationSelectElementBuilder​

Consuming builder for ConversationSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_conversation​

Sets the conversation ID selected when the menu loads.

fn initial_conversation(mut self, value: impl Into<String>) -> Self

clear_initial_conversation​

Omits initial_conversation, including any model default.

fn clear_initial_conversation(mut self) -> Self

default_to_current_conversation​

Sets whether the menu pre-selects the conversation the user is viewing.

fn default_to_current_conversation(mut self, value: bool) -> Self

clear_default_to_current_conversation​

Omits default_to_current_conversation, including any model default.

fn clear_default_to_current_conversation(mut self) -> Self

filter​

Sets which conversation types the menu offers.

fn filter(mut self, value: impl Into<ConversationFilter>) -> Self

Related types: ConversationFilter

clear_filter​

Omits filter, including any model default.

fn clear_filter(mut self) -> Self

response_url_enabled​

Sets whether the selected conversation receives a response URL in the view submission payload. Only valid in modals.

fn response_url_enabled(mut self, value: bool) -> Self

clear_response_url_enabled​

Omits response_url_enabled, including any model default.

fn clear_response_url_enabled(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<ConversationSelectElement, ValidationError>

Related types: ConversationSelectElement, ValidationError

DatePickerElement​

A calendar date picker.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> DatePickerElementBuilder

Related types: DatePickerElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> DatePickerElementBuilder

Related types: DatePickerElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_date​

Borrows or copies initial_date. Sets the initially selected date, formatted as YYYY-MM-DD.

fn initial_date(&self) -> Option<&str>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

DatePickerElementBuilder​

Consuming builder for DatePickerElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_date​

Sets the initially selected date, formatted as YYYY-MM-DD.

fn initial_date(mut self, value: impl Into<String>) -> Self

clear_initial_date​

Omits initial_date, including any model default.

fn clear_initial_date(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<DatePickerElement, ValidationError>

Related types: DatePickerElement, ValidationError

DateTimePickerElement​

A combined date and time picker.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> DateTimePickerElementBuilder

Related types: DateTimePickerElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> DateTimePickerElementBuilder

Related types: DateTimePickerElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_date_time​

Borrows or copies initial_date_time. Sets the initially selected moment as a UNIX timestamp in seconds.

fn initial_date_time(&self) -> Option<i64>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

DateTimePickerElementBuilder​

Consuming builder for DateTimePickerElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_date_time​

Sets the initially selected moment as a UNIX timestamp in seconds.

fn initial_date_time(mut self, value: i64) -> Self

clear_initial_date_time​

Omits initial_date_time, including any model default.

fn clear_initial_date_time(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<DateTimePickerElement, ValidationError>

Related types: DateTimePickerElement, ValidationError

EmailInputElement​

A single-line input that accepts an email address.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> EmailInputElementBuilder

Related types: EmailInputElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> EmailInputElementBuilder

Related types: EmailInputElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_value​

Borrows or copies initial_value. Sets the value present when the input loads.

fn initial_value(&self) -> Option<&str>

dispatch_action_config​

Borrows or copies dispatch_action_config. Sets which user interactions send a block_actions payload.

fn dispatch_action_config(&self) -> Option<&DispatchActionConfiguration>

Related types: DispatchActionConfiguration

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

EmailInputElementBuilder​

Consuming builder for EmailInputElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_value​

Sets the value present when the input loads.

fn initial_value(mut self, value: impl Into<String>) -> Self

clear_initial_value​

Omits initial_value, including any model default.

fn clear_initial_value(mut self) -> Self

dispatch_action_config​

Sets which user interactions send a block_actions payload.

fn dispatch_action_config(
mut self,
value: impl Into<DispatchActionConfiguration>,
) -> Self

Related types: DispatchActionConfiguration

clear_dispatch_action_config​

Omits dispatch_action_config, including any model default.

fn clear_dispatch_action_config(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<EmailInputElement, ValidationError>

Related types: EmailInputElement, ValidationError

ExternalMultiSelectElement​

A menu for selecting multiple options loaded from your app.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> ExternalMultiSelectElementBuilder

Related types: ExternalMultiSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> ExternalMultiSelectElementBuilder

Related types: ExternalMultiSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

min_query_length​

Borrows or copies min_query_length. Sets how many characters the user must type before Slack queries your options endpoint.

fn min_query_length(&self) -> Option<i64>

initial_options​

Borrows or copies initial_options. Adds options that are selected when the element loads. Each must match an option in the element.

fn initial_options(&self) -> Option<&[SelectOption]>

Related types: SelectOption

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

max_selected_items​

Borrows or copies max_selected_items. Sets the maximum number of items a user can select.

fn max_selected_items(&self) -> Option<i64>

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

ExternalMultiSelectElementBuilder​

Consuming builder for ExternalMultiSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

min_query_length​

Sets how many characters the user must type before Slack queries your options endpoint.

fn min_query_length(mut self, value: i64) -> Self

clear_min_query_length​

Omits min_query_length, including any model default.

fn clear_min_query_length(mut self) -> Self

initial_options​

Adds options that are selected when the element loads. Each must match an option in the element. Replaces the collection; order is preserved.

fn initial_options<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOption>,

Related types: SelectOption

initial_option​

Appends one item to the collection.

fn initial_option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

clear_initial_options​

Omits initial_options, including any model default.

fn clear_initial_options(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

max_selected_items​

Sets the maximum number of items a user can select.

fn max_selected_items(mut self, value: i64) -> Self

clear_max_selected_items​

Omits max_selected_items, including any model default.

fn clear_max_selected_items(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<ExternalMultiSelectElement, ValidationError>

Related types: ExternalMultiSelectElement, ValidationError

ExternalSelectElement​

A menu for selecting one option loaded from your app.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> ExternalSelectElementBuilder

Related types: ExternalSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> ExternalSelectElementBuilder

Related types: ExternalSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

min_query_length​

Borrows or copies min_query_length. Sets how many characters the user must type before Slack queries your options endpoint.

fn min_query_length(&self) -> Option<i64>

initial_option​

Borrows or copies initial_option. Sets the option selected when the element loads. It must match an option in the element.

fn initial_option(&self) -> Option<&SelectOption>

Related types: SelectOption

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

ExternalSelectElementBuilder​

Consuming builder for ExternalSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

min_query_length​

Sets how many characters the user must type before Slack queries your options endpoint.

fn min_query_length(mut self, value: i64) -> Self

clear_min_query_length​

Omits min_query_length, including any model default.

fn clear_min_query_length(mut self) -> Self

initial_option​

Sets the option selected when the element loads. It must match an option in the element.

fn initial_option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

clear_initial_option​

Omits initial_option, including any model default.

fn clear_initial_option(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<ExternalSelectElement, ValidationError>

Related types: ExternalSelectElement, ValidationError

FeedbackButtonsElement​

A pair of thumbs-up and thumbs-down feedback buttons.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> FeedbackButtonsElementBuilder

Related types: FeedbackButtonsElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> FeedbackButtonsElementBuilder

Related types: FeedbackButtonsElementBuilder

positive_button​

Borrows or copies positive_button. Sets the button for positive feedback.

fn positive_button(&self) -> &FeedbackButton

Related types: FeedbackButton

negative_button​

Borrows or copies negative_button. Sets the button for negative feedback.

fn negative_button(&self) -> &FeedbackButton

Related types: FeedbackButton

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

FeedbackButtonsElementBuilder​

Consuming builder for FeedbackButtonsElement. Validation runs in Self::build.

positive_button​

Sets the button for positive feedback.

fn positive_button(mut self, value: impl Into<FeedbackButton>) -> Self

Related types: FeedbackButton

negative_button​

Sets the button for negative feedback.

fn negative_button(mut self, value: impl Into<FeedbackButton>) -> Self

Related types: FeedbackButton

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<FeedbackButtonsElement, ValidationError>

Related types: FeedbackButtonsElement, ValidationError

FileInputElement​

An input that lets users upload files.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> FileInputElementBuilder

Related types: FileInputElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> FileInputElementBuilder

Related types: FileInputElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

filetypes​

Borrows or copies filetypes. Adds accepted file extensions, such as pdf or png.

fn filetypes(&self) -> Option<&[String]>

max_files​

Borrows or copies max_files. Sets the maximum number of files a user can upload.

fn max_files(&self) -> Option<i64>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

FileInputElementBuilder​

Consuming builder for FileInputElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

filetypes​

Adds accepted file extensions, such as pdf or png. Replaces the collection; order is preserved.

fn filetypes<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<String>,

filetype​

Appends one item to the collection.

fn filetype(mut self, value: impl Into<String>) -> Self

clear_filetypes​

Omits filetypes, including any model default.

fn clear_filetypes(mut self) -> Self

max_files​

Sets the maximum number of files a user can upload.

fn max_files(mut self, value: i64) -> Self

clear_max_files​

Omits max_files, including any model default.

fn clear_max_files(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<FileInputElement, ValidationError>

Related types: FileInputElement, ValidationError

IconButtonElement​

A button that shows an icon instead of text.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> IconButtonElementBuilder

Related types: IconButtonElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> IconButtonElementBuilder

Related types: IconButtonElementBuilder

text​

Borrows or copies text. Sets the text used as the button's accessible name.

fn text(&self) -> &PlainText

Related types: PlainText

icon​

Borrows or copies icon. Sets the icon shown on the button.

fn icon(&self) -> IconButtonIcon

Related types: IconButtonIcon

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

value​

Borrows or copies value. Sets the application-defined value sent in interaction payloads.

fn value(&self) -> Option<&str>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

accessibility_label​

Borrows or copies accessibility_label. Sets the label read by screen readers in place of the visible text.

fn accessibility_label(&self) -> Option<&str>

visible_to_user_ids​

Borrows or copies visible_to_user_ids. Adds the IDs of users who can see this button.

fn visible_to_user_ids(&self) -> Option<&[String]>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

IconButtonElementBuilder​

Consuming builder for IconButtonElement. Validation runs in Self::build.

text​

Sets the text used as the button's accessible name.

fn text(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

icon​

Sets the icon shown on the button.

fn icon(mut self, value: IconButtonIcon) -> Self

Related types: IconButtonIcon

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

value​

Sets the application-defined value sent in interaction payloads.

fn value(mut self, value: impl Into<String>) -> Self

clear_value​

Omits value, including any model default.

fn clear_value(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

accessibility_label​

Sets the label read by screen readers in place of the visible text.

fn accessibility_label(mut self, value: impl Into<String>) -> Self

clear_accessibility_label​

Omits accessibility_label, including any model default.

fn clear_accessibility_label(mut self) -> Self

visible_to_user_ids​

Adds the IDs of users who can see this button. Replaces the collection; order is preserved.

fn visible_to_user_ids<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<String>,

visible_to_user_id​

Appends one item to the collection.

fn visible_to_user_id(mut self, value: impl Into<String>) -> Self

clear_visible_to_user_ids​

Omits visible_to_user_ids, including any model default.

fn clear_visible_to_user_ids(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<IconButtonElement, ValidationError>

Related types: IconButtonElement, ValidationError

ImageElement​

An image displayed inside a section, context, or card.

Slack reference. Provide exactly one of an image URL or a Slack file.

builder​

Starts a builder with the documented model defaults.

fn builder() -> ImageElementBuilder

Related types: ImageElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> ImageElementBuilder

Related types: ImageElementBuilder

alt_text​

Borrows or copies alt_text. Sets a plain-text summary of the image or video for assistive technology.

fn alt_text(&self) -> &str

image_url​

Borrows or copies image_url. Sets the publicly accessible URL of the image. Cannot be combined with a Slack file.

fn image_url(&self) -> Option<&str>

slack_file​

Borrows or copies slack_file. Sets a file hosted in Slack as the image source. Cannot be combined with an image URL.

fn slack_file(&self) -> Option<&SlackFile>

Related types: SlackFile

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

ImageElementBuilder​

Consuming builder for ImageElement. Validation runs in Self::build.

alt_text​

Sets a plain-text summary of the image or video for assistive technology.

fn alt_text(mut self, value: impl Into<String>) -> Self

image_url​

Sets the publicly accessible URL of the image. Cannot be combined with a Slack file.

fn image_url(mut self, value: impl Into<String>) -> Self

clear_image_url​

Omits image_url, including any model default.

fn clear_image_url(mut self) -> Self

slack_file​

Sets a file hosted in Slack as the image source. Cannot be combined with an image URL.

fn slack_file(mut self, value: impl Into<SlackFile>) -> Self

Related types: SlackFile

clear_slack_file​

Omits slack_file, including any model default.

fn clear_slack_file(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<ImageElement, ValidationError>

Related types: ImageElement, ValidationError

NumberInputElement​

An input that accepts whole or decimal numbers.

Slack reference. The minimum value cannot exceed the maximum value.

builder​

Starts a builder with the documented model defaults.

fn builder() -> NumberInputElementBuilder

Related types: NumberInputElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> NumberInputElementBuilder

Related types: NumberInputElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

is_decimal_allowed​

Borrows or copies is_decimal_allowed. Sets whether the input accepts decimal numbers.

fn is_decimal_allowed(&self) -> bool

initial_value​

Borrows or copies initial_value. Sets the number present when the input loads, as a string such as 42 or 3.5.

fn initial_value(&self) -> Option<&str>

min_value​

Borrows or copies min_value. Sets the smallest accepted number.

fn min_value(&self) -> Option<f64>

max_value​

Borrows or copies max_value. Sets the largest accepted number.

fn max_value(&self) -> Option<f64>

dispatch_action_config​

Borrows or copies dispatch_action_config. Sets which user interactions send a block_actions payload.

fn dispatch_action_config(&self) -> Option<&DispatchActionConfiguration>

Related types: DispatchActionConfiguration

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

NumberInputElementBuilder​

Consuming builder for NumberInputElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

is_decimal_allowed​

Sets whether the input accepts decimal numbers.

fn is_decimal_allowed(mut self, value: bool) -> Self

initial_value​

Sets the number present when the input loads, as a string such as 42 or 3.5.

fn initial_value(mut self, value: impl Into<String>) -> Self

clear_initial_value​

Omits initial_value, including any model default.

fn clear_initial_value(mut self) -> Self

min_value​

Sets the smallest accepted number.

fn min_value(mut self, value: f64) -> Self

clear_min_value​

Omits min_value, including any model default.

fn clear_min_value(mut self) -> Self

max_value​

Sets the largest accepted number.

fn max_value(mut self, value: f64) -> Self

clear_max_value​

Omits max_value, including any model default.

fn clear_max_value(mut self) -> Self

dispatch_action_config​

Sets which user interactions send a block_actions payload.

fn dispatch_action_config(
mut self,
value: impl Into<DispatchActionConfiguration>,
) -> Self

Related types: DispatchActionConfiguration

clear_dispatch_action_config​

Omits dispatch_action_config, including any model default.

fn clear_dispatch_action_config(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<NumberInputElement, ValidationError>

Related types: NumberInputElement, ValidationError

OverflowElement​

A compact menu of up to five options.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> OverflowElementBuilder

Related types: OverflowElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> OverflowElementBuilder

Related types: OverflowElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

options​

Borrows or copies options. Adds selectable options in display order.

fn options(&self) -> &[SelectOption]

Related types: SelectOption

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

OverflowElementBuilder​

Consuming builder for OverflowElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

options​

Adds selectable options in display order. Replaces the collection; order is preserved.

fn options<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOption>,

Related types: SelectOption

option​

Appends one item to the collection.

fn option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<OverflowElement, ValidationError>

Related types: OverflowElement, ValidationError

PlainTextInputElement​

A single-line or multi-line free-text input.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> PlainTextInputElementBuilder

Related types: PlainTextInputElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> PlainTextInputElementBuilder

Related types: PlainTextInputElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_value​

Borrows or copies initial_value. Sets the value present when the input loads.

fn initial_value(&self) -> Option<&str>

multiline​

Borrows or copies multiline. Sets whether the input is a multi-line text area.

fn multiline(&self) -> Option<bool>

min_length​

Borrows or copies min_length. Sets the minimum number of characters the user must enter.

fn min_length(&self) -> Option<i64>

max_length​

Borrows or copies max_length. Sets the maximum number of characters the user can enter.

fn max_length(&self) -> Option<i64>

dispatch_action_config​

Borrows or copies dispatch_action_config. Sets which user interactions send a block_actions payload.

fn dispatch_action_config(&self) -> Option<&DispatchActionConfiguration>

Related types: DispatchActionConfiguration

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

PlainTextInputElementBuilder​

Consuming builder for PlainTextInputElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_value​

Sets the value present when the input loads.

fn initial_value(mut self, value: impl Into<String>) -> Self

clear_initial_value​

Omits initial_value, including any model default.

fn clear_initial_value(mut self) -> Self

multiline​

Sets whether the input is a multi-line text area.

fn multiline(mut self, value: bool) -> Self

clear_multiline​

Omits multiline, including any model default.

fn clear_multiline(mut self) -> Self

min_length​

Sets the minimum number of characters the user must enter.

fn min_length(mut self, value: i64) -> Self

clear_min_length​

Omits min_length, including any model default.

fn clear_min_length(mut self) -> Self

max_length​

Sets the maximum number of characters the user can enter.

fn max_length(mut self, value: i64) -> Self

clear_max_length​

Omits max_length, including any model default.

fn clear_max_length(mut self) -> Self

dispatch_action_config​

Sets which user interactions send a block_actions payload.

fn dispatch_action_config(
mut self,
value: impl Into<DispatchActionConfiguration>,
) -> Self

Related types: DispatchActionConfiguration

clear_dispatch_action_config​

Omits dispatch_action_config, including any model default.

fn clear_dispatch_action_config(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<PlainTextInputElement, ValidationError>

Related types: PlainTextInputElement, ValidationError

RadioButtonsElement​

A group of radio buttons.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> RadioButtonsElementBuilder

Related types: RadioButtonsElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> RadioButtonsElementBuilder

Related types: RadioButtonsElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

options​

Borrows or copies options. Adds selectable options in display order.

fn options(&self) -> &[SelectOption]

Related types: SelectOption

initial_option​

Borrows or copies initial_option. Sets the option selected when the element loads. It must match an option in the element.

fn initial_option(&self) -> Option<&SelectOption>

Related types: SelectOption

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

RadioButtonsElementBuilder​

Consuming builder for RadioButtonsElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

options​

Adds selectable options in display order. Replaces the collection; order is preserved.

fn options<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOption>,

Related types: SelectOption

option​

Appends one item to the collection.

fn option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

initial_option​

Sets the option selected when the element loads. It must match an option in the element.

fn initial_option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

clear_initial_option​

Omits initial_option, including any model default.

fn clear_initial_option(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<RadioButtonsElement, ValidationError>

Related types: RadioButtonsElement, ValidationError

RichTextInputElement​

An input that accepts formatted rich text.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> RichTextInputElementBuilder

Related types: RichTextInputElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> RichTextInputElementBuilder

Related types: RichTextInputElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> &str

initial_value​

Borrows or copies initial_value. Sets the rich text present when the input loads.

fn initial_value(&self) -> Option<&RichTextBlock>

Related types: RichTextBlock

dispatch_action_config​

Borrows or copies dispatch_action_config. Sets which user interactions send a block_actions payload.

fn dispatch_action_config(&self) -> Option<&DispatchActionConfiguration>

Related types: DispatchActionConfiguration

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

min_lines​

Borrows or copies min_lines. Sets the minimum visible height of the input, in lines.

fn min_lines(&self) -> Option<i64>

max_lines​

Borrows or copies max_lines. Sets the maximum visible height of the input, in lines.

fn max_lines(&self) -> Option<i64>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

RichTextInputElementBuilder​

Consuming builder for RichTextInputElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

initial_value​

Sets the rich text present when the input loads.

fn initial_value(mut self, value: impl Into<RichTextBlock>) -> Self

Related types: RichTextBlock

clear_initial_value​

Omits initial_value, including any model default.

fn clear_initial_value(mut self) -> Self

dispatch_action_config​

Sets which user interactions send a block_actions payload.

fn dispatch_action_config(
mut self,
value: impl Into<DispatchActionConfiguration>,
) -> Self

Related types: DispatchActionConfiguration

clear_dispatch_action_config​

Omits dispatch_action_config, including any model default.

fn clear_dispatch_action_config(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

min_lines​

Sets the minimum visible height of the input, in lines.

fn min_lines(mut self, value: i64) -> Self

clear_min_lines​

Omits min_lines, including any model default.

fn clear_min_lines(mut self) -> Self

max_lines​

Sets the maximum visible height of the input, in lines.

fn max_lines(mut self, value: i64) -> Self

clear_max_lines​

Omits max_lines, including any model default.

fn clear_max_lines(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<RichTextInputElement, ValidationError>

Related types: RichTextInputElement, ValidationError

StaticMultiSelectElement​

A menu for selecting multiple options defined in the payload.

Slack reference. Use options or option groups, not both.

builder​

Starts a builder with the documented model defaults.

fn builder() -> StaticMultiSelectElementBuilder

Related types: StaticMultiSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> StaticMultiSelectElementBuilder

Related types: StaticMultiSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

options​

Borrows or copies options. Adds selectable options in display order.

fn options(&self) -> Option<&[SelectOption]>

Related types: SelectOption

option_groups​

Borrows or copies option_groups. Adds labelled groups of options in display order. Cannot be combined with ungrouped options.

fn option_groups(&self) -> Option<&[SelectOptionGroup]>

Related types: SelectOptionGroup

initial_options​

Borrows or copies initial_options. Adds options that are selected when the element loads. Each must match an option in the element.

fn initial_options(&self) -> Option<&[SelectOption]>

Related types: SelectOption

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

max_selected_items​

Borrows or copies max_selected_items. Sets the maximum number of items a user can select.

fn max_selected_items(&self) -> Option<i64>

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

StaticMultiSelectElementBuilder​

Consuming builder for StaticMultiSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

options​

Adds selectable options in display order. Replaces the collection; order is preserved.

fn options<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOption>,

Related types: SelectOption

option​

Appends one item to the collection.

fn option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

clear_options​

Omits options, including any model default.

fn clear_options(mut self) -> Self

option_groups​

Adds labelled groups of options in display order. Cannot be combined with ungrouped options. Replaces the collection; order is preserved.

fn option_groups<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOptionGroup>,

Related types: SelectOptionGroup

option_group​

Appends one item to the collection.

fn option_group(mut self, value: impl Into<SelectOptionGroup>) -> Self

Related types: SelectOptionGroup

clear_option_groups​

Omits option_groups, including any model default.

fn clear_option_groups(mut self) -> Self

initial_options​

Adds options that are selected when the element loads. Each must match an option in the element. Replaces the collection; order is preserved.

fn initial_options<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOption>,

Related types: SelectOption

initial_option​

Appends one item to the collection.

fn initial_option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

clear_initial_options​

Omits initial_options, including any model default.

fn clear_initial_options(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

max_selected_items​

Sets the maximum number of items a user can select.

fn max_selected_items(mut self, value: i64) -> Self

clear_max_selected_items​

Omits max_selected_items, including any model default.

fn clear_max_selected_items(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<StaticMultiSelectElement, ValidationError>

Related types: StaticMultiSelectElement, ValidationError

StaticSelectElement​

A menu for selecting one option defined in the payload.

Slack reference. Use options or option groups, not both.

builder​

Starts a builder with the documented model defaults.

fn builder() -> StaticSelectElementBuilder

Related types: StaticSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> StaticSelectElementBuilder

Related types: StaticSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

options​

Borrows or copies options. Adds selectable options in display order.

fn options(&self) -> Option<&[SelectOption]>

Related types: SelectOption

option_groups​

Borrows or copies option_groups. Adds labelled groups of options in display order. Cannot be combined with ungrouped options.

fn option_groups(&self) -> Option<&[SelectOptionGroup]>

Related types: SelectOptionGroup

initial_option​

Borrows or copies initial_option. Sets the option selected when the element loads. It must match an option in the element.

fn initial_option(&self) -> Option<&SelectOption>

Related types: SelectOption

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

StaticSelectElementBuilder​

Consuming builder for StaticSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

options​

Adds selectable options in display order. Replaces the collection; order is preserved.

fn options<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOption>,

Related types: SelectOption

option​

Appends one item to the collection.

fn option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

clear_options​

Omits options, including any model default.

fn clear_options(mut self) -> Self

option_groups​

Adds labelled groups of options in display order. Cannot be combined with ungrouped options. Replaces the collection; order is preserved.

fn option_groups<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<SelectOptionGroup>,

Related types: SelectOptionGroup

option_group​

Appends one item to the collection.

fn option_group(mut self, value: impl Into<SelectOptionGroup>) -> Self

Related types: SelectOptionGroup

clear_option_groups​

Omits option_groups, including any model default.

fn clear_option_groups(mut self) -> Self

initial_option​

Sets the option selected when the element loads. It must match an option in the element.

fn initial_option(mut self, value: impl Into<SelectOption>) -> Self

Related types: SelectOption

clear_initial_option​

Omits initial_option, including any model default.

fn clear_initial_option(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<StaticSelectElement, ValidationError>

Related types: StaticSelectElement, ValidationError

TimePickerElement​

A time-of-day picker.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> TimePickerElementBuilder

Related types: TimePickerElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> TimePickerElementBuilder

Related types: TimePickerElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_time​

Borrows or copies initial_time. Sets the initially selected time, formatted as HH:mm in 24-hour time.

fn initial_time(&self) -> Option<&str>

timezone​

Borrows or copies timezone. Sets the IANA time zone used to display the time, such as Australia/Brisbane.

fn timezone(&self) -> Option<&str>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

TimePickerElementBuilder​

Consuming builder for TimePickerElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_time​

Sets the initially selected time, formatted as HH:mm in 24-hour time.

fn initial_time(mut self, value: impl Into<String>) -> Self

clear_initial_time​

Omits initial_time, including any model default.

fn clear_initial_time(mut self) -> Self

timezone​

Sets the IANA time zone used to display the time, such as Australia/Brisbane.

fn timezone(mut self, value: impl Into<String>) -> Self

clear_timezone​

Omits timezone, including any model default.

fn clear_timezone(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<TimePickerElement, ValidationError>

Related types: TimePickerElement, ValidationError

UrlInputElement​

A single-line input that accepts a URL.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> UrlInputElementBuilder

Related types: UrlInputElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> UrlInputElementBuilder

Related types: UrlInputElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_value​

Borrows or copies initial_value. Sets the value present when the input loads.

fn initial_value(&self) -> Option<&str>

dispatch_action_config​

Borrows or copies dispatch_action_config. Sets which user interactions send a block_actions payload.

fn dispatch_action_config(&self) -> Option<&DispatchActionConfiguration>

Related types: DispatchActionConfiguration

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

UrlInputElementBuilder​

Consuming builder for UrlInputElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_value​

Sets the value present when the input loads.

fn initial_value(mut self, value: impl Into<String>) -> Self

clear_initial_value​

Omits initial_value, including any model default.

fn clear_initial_value(mut self) -> Self

dispatch_action_config​

Sets which user interactions send a block_actions payload.

fn dispatch_action_config(
mut self,
value: impl Into<DispatchActionConfiguration>,
) -> Self

Related types: DispatchActionConfiguration

clear_dispatch_action_config​

Omits dispatch_action_config, including any model default.

fn clear_dispatch_action_config(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<UrlInputElement, ValidationError>

Related types: UrlInputElement, ValidationError

UserMultiSelectElement​

A menu for selecting multiple workspace users.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> UserMultiSelectElementBuilder

Related types: UserMultiSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> UserMultiSelectElementBuilder

Related types: UserMultiSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_users​

Borrows or copies initial_users. Adds user IDs that are selected when the menu loads.

fn initial_users(&self) -> Option<&[String]>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

max_selected_items​

Borrows or copies max_selected_items. Sets the maximum number of items a user can select.

fn max_selected_items(&self) -> Option<i64>

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

UserMultiSelectElementBuilder​

Consuming builder for UserMultiSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_users​

Adds user IDs that are selected when the menu loads. Replaces the collection; order is preserved.

fn initial_users<I, T>(mut self, values: I) -> Self
where
I: IntoIterator<Item = T>,
T: Into<String>,

initial_user​

Appends one item to the collection.

fn initial_user(mut self, value: impl Into<String>) -> Self

clear_initial_users​

Omits initial_users, including any model default.

fn clear_initial_users(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

max_selected_items​

Sets the maximum number of items a user can select.

fn max_selected_items(mut self, value: i64) -> Self

clear_max_selected_items​

Omits max_selected_items, including any model default.

fn clear_max_selected_items(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<UserMultiSelectElement, ValidationError>

Related types: UserMultiSelectElement, ValidationError

UserSelectElement​

A menu for selecting one workspace user.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> UserSelectElementBuilder

Related types: UserSelectElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> UserSelectElementBuilder

Related types: UserSelectElementBuilder

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> Option<&str>

initial_user​

Borrows or copies initial_user. Sets the user ID selected when the menu loads.

fn initial_user(&self) -> Option<&str>

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

focus_on_load​

Borrows or copies focus_on_load. Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(&self) -> Option<bool>

placeholder​

Borrows or copies placeholder. Sets the placeholder text shown before a value is chosen.

fn placeholder(&self) -> Option<&PlainText>

Related types: PlainText

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

UserSelectElementBuilder​

Consuming builder for UserSelectElement. Validation runs in Self::build.

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

clear_action_id​

Omits action_id, including any model default.

fn clear_action_id(mut self) -> Self

initial_user​

Sets the user ID selected when the menu loads.

fn initial_user(mut self, value: impl Into<String>) -> Self

clear_initial_user​

Omits initial_user, including any model default.

fn clear_initial_user(mut self) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

focus_on_load​

Sets whether the element receives focus when the view opens. Only one element per view may do so.

fn focus_on_load(mut self, value: bool) -> Self

clear_focus_on_load​

Omits focus_on_load, including any model default.

fn clear_focus_on_load(mut self) -> Self

placeholder​

Sets the placeholder text shown before a value is chosen.

fn placeholder(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

clear_placeholder​

Omits placeholder, including any model default.

fn clear_placeholder(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<UserSelectElement, ValidationError>

Related types: UserSelectElement, ValidationError

WorkflowButtonElement​

A button that starts a workflow through a link trigger.

Slack reference.

builder​

Starts a builder with the documented model defaults.

fn builder() -> WorkflowButtonElementBuilder

Related types: WorkflowButtonElementBuilder

into_builder​

Moves every field into an editable builder, preserving explicit omissions.

fn into_builder(self) -> WorkflowButtonElementBuilder

Related types: WorkflowButtonElementBuilder

text​

Borrows or copies text. Sets the button label.

fn text(&self) -> &PlainText

Related types: PlainText

workflow​

Borrows or copies workflow. Sets the workflow started when the button is clicked.

fn workflow(&self) -> &Workflow

Related types: Workflow

action_id​

Borrows or copies action_id. Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(&self) -> &str

confirm​

Borrows or copies confirm. Sets a confirmation dialog shown before the action is sent.

fn confirm(&self) -> Option<&ConfirmationDialogue>

Related types: ConfirmationDialogue

style​

Borrows or copies style. Sets the button's emphasis. Omit it for the default neutral style.

fn style(&self) -> Option<ButtonStyle>

Related types: ButtonStyle

accessibility_label​

Borrows or copies accessibility_label. Sets the label read by screen readers in place of the visible text.

fn accessibility_label(&self) -> Option<&str>

extensions​

Borrows checked, unmodeled JSON extension fields.

fn extensions(&self) -> &Map<String, Value>

WorkflowButtonElementBuilder​

Consuming builder for WorkflowButtonElement. Validation runs in Self::build.

text​

Sets the button label.

fn text(mut self, value: impl Into<PlainTextInput>) -> Self

Related types: PlainTextInput

workflow​

Sets the workflow started when the button is clicked.

fn workflow(mut self, value: impl Into<Workflow>) -> Self

Related types: Workflow

action_id​

Sets the identifier Slack returns in interaction payloads when a user acts on this element. It must be unique among the elements of its block.

fn action_id(mut self, value: impl Into<String>) -> Self

confirm​

Sets a confirmation dialog shown before the action is sent.

fn confirm(mut self, value: impl Into<ConfirmationDialogue>) -> Self

Related types: ConfirmationDialogue

clear_confirm​

Omits confirm, including any model default.

fn clear_confirm(mut self) -> Self

style​

Sets the button's emphasis. Omit it for the default neutral style.

fn style(mut self, value: ButtonStyle) -> Self

Related types: ButtonStyle

clear_style​

Omits style, including any model default.

fn clear_style(mut self) -> Self

accessibility_label​

Sets the label read by screen readers in place of the visible text.

fn accessibility_label(mut self, value: impl Into<String>) -> Self

clear_accessibility_label​

Omits accessibility_label, including any model default.

fn clear_accessibility_label(mut self) -> Self

extension​

Adds or replaces an unmodeled extension; reserved names fail at build time.

fn extension(mut self, key: impl Into<String>, value: impl Into<Value>) -> Self

build​

Validates all fields and their receiving context.

Errors Returns a ValidationError for missing fields, invalid values, reserved extension names, or unsupported field combinations and child contexts.

fn build(self) -> Result<WorkflowButtonElement, ValidationError>

Related types: ValidationError, WorkflowButtonElement