Aspirerelease/17.0
Watch Aspire live streamsDocsTry Aspire

CreateChoiceInput

Method
📦 Aspire.Hosting v17.0.0
func (InteractionService) CreateChoiceInput(
name string,
options ...*CreateChoiceInputOptions,
) InteractionInputBuilder

Signature

methodCreateChoiceInput
Creates a choice input that selects from a list of options.
CreateChoiceInput(
name string,
options ...*CreateChoiceInputOptions,
) InteractionInputBuilder
namestringThe name of the input.
options...*CreateChoiceInputOptionsOptional settings, described under Options.

Optional parameters are passed in a trailing options ...*CreateChoiceInputOptions argument.

Choices[]*InteractionChoiceOptionThe available choices, in display order. Each option pairs a submitted value with a display label.
Options*CreateInteractionInputOptionsOptional configuration for the input.
InteractionInputBuilder

Returns a handle; failures surface later via Err().

Applies to

This method applies to the following types: