Respond to Interaction with Text

BlockInteractions

Send a text response to an interaction (slash command, button, etc.).

  • Only works in flows started by an interaction: a slash command, button, dropdown, modal or context menu.

Inputs

Message ContentRequired

Text content of the response.

Example: Hello world!

Allow Mentions

Choose which mention types should notify users. Empty only pings users; None disables all pings. None overrides other selections. Unselected mentions are displayed without pinging.

OptionsNoneEveryone/HereRolesUsers
Update Original Message

For component interactions and modals opened from a component, edit the original message instead of sending a new interaction response. Ignored otherwise.

Optionstruefalse
Ephemeral

Only visible to the user who triggered the interaction. Only applies to the initial response.

Optionstruefalse

Outputs

Message ID

ID of the sent or edited interaction response message.

Build a bot using blocks like Respond to Interaction with Text

Use this block in our visual flow editor. Bots are hosted 24/7 for free on inventor.bot.

Advanced Documentation

This documentation can be useful when using code mode. View as Markdown

ID: respond_interaction_text
  • Only works in flows started by an interaction trigger (slash commands, buttons, dropdowns, modals, context menus).

Inputs

FieldInventScript nameValue
Message Contentmessage_contente.g. "Hello world!"
Allow Mentionsallow_mentions"None", "Everyone/Here", "Roles", "Users"
Update Original Messageupdate_original_message"true", "false"
Ephemeralephemeral"true", "false"

Outputs

FieldInventScript nameValue
Message IDmessage_id

Example InventScript

interactionText := respond_interaction_text(Args{message_content: "Hello world!"})
send_text_message(Args{
	channel_id:      trigger.channel_id,
	message_content: "Message ID: " + interactionText.message_id,
})

More interactions blocks