Home > @johndavisdev/discord-emcee > promptModal
Prompt a Discord user information via a MessageComponent.
Signature:
declare function promptModal<TShape extends sb.ModalRawShape = sb.ModalRawShape, Output extends ObjectOutput<TShape> = ObjectOutput<TShape>>(schema: sb.ModalSchema<TShape>, uiOptions: ModalPromptOptions, interaction: ChatInputCommandInteraction): Promise<Output>;
Parameter | Type | Description |
---|---|---|
schema | sb.ModalSchema<TShape> | the schema for the data you’re trying to get from the user |
uiOptions | ModalPromptOptions | rendering options |
interaction | ChatInputCommandInteraction | the Discord interaction object |
Returns:
Promise<Output>
a value staisfying the schema (as a Promise)