create_text_input
Function
Modal text field, short or paragraph.
from discord_interactions import create_text_inputSignature
def create_text_input( custom_id: str, label: str | None = None, style: str | int = 1, placeholder: str | None = None, min_length: int | None = None, max_length: int | None = None, required: bool = True, value: str | None = None, component_id: int | None = None,) -> Dict[str, Any]Parameters
| Name | Type | Default | Description |
|---|---|---|---|
custom_id | str | required | Key of the value in the submission. |
label | str | None | None | Title in the legacy format (ActionRow). Removed automatically inside a Label. |
style | str | int | 1 | "short" / TextInputStyle.Short or "paragraph" / TextInputStyle.Paragraph. |
placeholder | str | None | None | Hint text (100 characters max). |
min_length | int | None | None | Minimum length (0 to 4000). |
max_length | int | None | None | Maximum length (1 to 4000). |
required | bool | True | Field required. |
value | str | None | None | Pre-filled value. |
component_id | int | None | None |
Returns
Dict[str, Any]