Class InteractionCreateEvent

    • Method Detail

      • createInteractionResponse

        protected Mono<Void> createInteractionResponse​(InteractionResponseType responseType,
                                                       @Nullable
                                                       discord4j.discordjson.json.InteractionApplicationCommandCallbackData data)
      • acknowledge

        public Mono<Void> acknowledge()
        Acknowledges the interaction indicating a response will be edited later. The user sees a loading state, visible to all participants in the invoking channel. For a "only you can see this" response, see acknowledgeEphemeral(), or to include a message, reply(String).withEphemeral(true)
        Returns:
        A Mono where, upon successful completion, emits nothing; acknowledging the interaction and indicating a response will be edited later. The user sees a loading state. If an error is received, it is emitted through the Mono.
      • acknowledgeEphemeral

        public Mono<Void> acknowledgeEphemeral()
        Acknowledges the interaction indicating a response will be edited later. Only the invoking user sees a loading state.
        Returns:
        A Mono where, upon successful completion, emits nothing, acknowledging the interaction and indicating a response will be edited later. If an error is received, it is emitted through the Mono.
      • reply

        public discord4j.core.spec.InteractionApplicationCommandCallbackReplyMono reply()
        Requests to respond to the interaction with a message. Properties specifying how to build the reply message to the interaction can be set via the withXxx methods of the returned InteractionApplicationCommandCallbackReplyMono.
        Returns:
        A InteractionApplicationCommandCallbackReplyMono where, upon successful completion, emits nothing; indicating the interaction response has been sent. If an error is received, it is emitted through the InteractionApplicationCommandCallbackMono.
      • reply

        public discord4j.core.spec.InteractionApplicationCommandCallbackReplyMono reply​(String content)
        Requests to respond to the interaction with a message initialized with the specified content. Properties specifying how to build the reply message to the interaction can be set via the withXxx methods of the returned InteractionApplicationCommandCallbackReplyMono.
        Parameters:
        content - a string to populate the message with
        Returns:
        A InteractionApplicationCommandCallbackReplyMono where, upon successful completion, emits nothing; indicating the interaction response has been sent. If an error is received, it is emitted through the InteractionApplicationCommandCallbackMono.
      • reply

        public Mono<Void> reply​(discord4j.core.spec.InteractionApplicationCommandCallbackSpec spec)
        Requests to respond to the interaction with a message.
        Parameters:
        spec - an immutable object that specifies how to build the reply message to the interaction
        Returns:
        A Mono where, upon successful completion, emits nothing; indicating the interaction response has been sent. If an error is received, it is emitted through the Mono.
      • getInteractionResponse

        public InteractionResponse getInteractionResponse()
        Gets a handler for common operations related to an interaction followup response associated with this event.
        Returns:
        A handler for common operations related to an interaction followup response associated with this event.