#how to handle InteractionType::ApplicationCommandAutocomplete

1 messages · Page 1 of 1 (latest)

shy zenith
#

i am struggling to trade autocompletion, but i am still missing the final touch, namely the response

how exactly do I have to build it?

pub async fn autocomplete(interaction: &Box<InteractionCreate>, client: &Arc<Client>) {
    client
        .interaction(interaction.application_id)
        .create_response(
            interaction.id,
            &interaction.token,
            &InteractionResponse {
                data: Some(InteractionResponseDataBuilder::new()),
                kind: InteractionResponseType::ApplicationCommandAutocompleteResult,
            },
        )
        .await
        .unwrap();
}
buoyant shoal
#

Is there anything in particular you're wanting help with?