Package discord4j.rest.service
Class WebhookService
java.lang.Object
discord4j.rest.service.RestService
discord4j.rest.service.WebhookService
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionMono<discord4j.discordjson.json.WebhookData>createWebhook(long channelId, discord4j.discordjson.json.WebhookCreateRequest request, String reason) deleteWebhook(long webhookId, String reason) deleteWebhookMessage(long webhookId, String webhookToken, String messageId) deleteWebhookMessage(long webhookId, String webhookToken, String messageId, long threadId) deleteWebhookWithToken(long webhookId, String token) Mono<discord4j.discordjson.json.MessageData>executeWebhook(long webhookId, String token, boolean wait, boolean withComponents, MultipartRequest<? extends discord4j.discordjson.json.WebhookExecuteRequest> request) Executes the specified webhook.Mono<discord4j.discordjson.json.MessageData>executeWebhook(long webhookId, String token, boolean wait, long threadId, boolean withComponents, MultipartRequest<? extends discord4j.discordjson.json.WebhookExecuteRequest> request) Executes the specified webhook.Mono<discord4j.discordjson.json.MessageData>executeWebhook(long webhookId, String token, boolean wait, long threadId, MultipartRequest<? extends discord4j.discordjson.json.WebhookExecuteRequest> request) Executes the specified webhook.Mono<discord4j.discordjson.json.MessageData>executeWebhook(long webhookId, String token, boolean wait, MultipartRequest<? extends discord4j.discordjson.json.WebhookExecuteRequest> request) Executes the specified webhook.Flux<discord4j.discordjson.json.WebhookData>getChannelWebhooks(long channelId) Flux<discord4j.discordjson.json.WebhookData>getGuildWebhooks(long guildId) Mono<discord4j.discordjson.json.WebhookData>getWebhook(long webhookId) Mono<discord4j.discordjson.json.MessageData>getWebhookMessage(long webhookId, String webhookToken, String messageId) Mono<discord4j.discordjson.json.MessageData>getWebhookMessage(long webhookId, String webhookToken, String messageId, long threadId) Mono<discord4j.discordjson.json.WebhookData>getWebhookWithToken(long webhookId, String token) Mono<discord4j.discordjson.json.WebhookData>modifyWebhook(long webhookId, discord4j.discordjson.json.WebhookModifyRequest request, String reason) Mono<discord4j.discordjson.json.MessageData>modifyWebhookMessage(long webhookId, String webhookToken, String messageId, boolean withComponents, discord4j.discordjson.json.WebhookMessageEditRequest request) Mono<discord4j.discordjson.json.MessageData>modifyWebhookMessage(long webhookId, String webhookToken, String messageId, boolean withComponents, MultipartRequest<discord4j.discordjson.json.WebhookMessageEditRequest> request) Mono<discord4j.discordjson.json.MessageData>modifyWebhookMessage(long webhookId, String webhookToken, String messageId, long threadId, boolean withComponents, discord4j.discordjson.json.WebhookMessageEditRequest request) Mono<discord4j.discordjson.json.MessageData>modifyWebhookMessage(long webhookId, String webhookToken, String messageId, long threadId, boolean withComponents, MultipartRequest<discord4j.discordjson.json.WebhookMessageEditRequest> request) Mono<discord4j.discordjson.json.MessageData>modifyWebhookMessage(long webhookId, String webhookToken, String messageId, long threadId, discord4j.discordjson.json.WebhookMessageEditRequest request) Mono<discord4j.discordjson.json.MessageData>modifyWebhookMessage(long webhookId, String webhookToken, String messageId, long threadId, MultipartRequest<discord4j.discordjson.json.WebhookMessageEditRequest> request) Mono<discord4j.discordjson.json.MessageData>modifyWebhookMessage(long webhookId, String webhookToken, String messageId, discord4j.discordjson.json.WebhookMessageEditRequest request) Mono<discord4j.discordjson.json.MessageData>modifyWebhookMessage(long webhookId, String webhookToken, String messageId, MultipartRequest<discord4j.discordjson.json.WebhookMessageEditRequest> request) Mono<discord4j.discordjson.json.WebhookData>modifyWebhookWithToken(long webhookId, String token, discord4j.discordjson.json.WebhookModifyWithTokenRequest request) Methods inherited from class discord4j.rest.service.RestService
getRouter
-
Constructor Details
-
WebhookService
-
-
Method Details
-
createWebhook
-
getChannelWebhooks
-
getGuildWebhooks
-
getWebhook
-
getWebhookWithToken
-
modifyWebhook
-
modifyWebhookWithToken
-
deleteWebhook
-
deleteWebhookWithToken
-
executeWebhook
public Mono<discord4j.discordjson.json.MessageData> executeWebhook(long webhookId, String token, boolean wait, MultipartRequest<? extends discord4j.discordjson.json.WebhookExecuteRequest> request) Executes the specified webhook.- Parameters:
wait- true if you want to return message data and errors for the webhook.- Returns:
- If wait is true, a mono that contains the message information of the execution or an error if the webhook is unsuccessful. If wait is false, the mono completes as soon as the request is finished sending, and DOES NOT result in an error if the message is not saved.
-
executeWebhook
public Mono<discord4j.discordjson.json.MessageData> executeWebhook(long webhookId, String token, boolean wait, boolean withComponents, MultipartRequest<? extends discord4j.discordjson.json.WebhookExecuteRequest> request) Executes the specified webhook.- Parameters:
wait- true if you want to return message data and errors for the webhook.withComponents- true if you want to allow sending (non-interactive) components for non-application-owned webhooks- Returns:
- If wait is true, a mono that contains the message information of the execution or an error if the webhook is unsuccessful. If wait is false, the mono completes as soon as the request is finished sending, and DOES NOT result in an error if the message is not saved.
-
executeWebhook
public Mono<discord4j.discordjson.json.MessageData> executeWebhook(long webhookId, String token, boolean wait, long threadId, MultipartRequest<? extends discord4j.discordjson.json.WebhookExecuteRequest> request) Executes the specified webhook.- Parameters:
wait- true if you want to return message data and errors for the webhook.threadId- specify the thread id within a webhook's channel.- Returns:
- If wait is true, a mono that contains the message information of the execution or an error if the webhook is unsuccessful. If wait is false, the mono completes as soon as the request is finished sending, and DOES NOT result in an error if the message is not saved.
-
executeWebhook
public Mono<discord4j.discordjson.json.MessageData> executeWebhook(long webhookId, String token, boolean wait, long threadId, boolean withComponents, MultipartRequest<? extends discord4j.discordjson.json.WebhookExecuteRequest> request) Executes the specified webhook.- Parameters:
wait- true if you want to return message data and errors for the webhook.threadId- specify the thread id within a webhook's channel.withComponents- true if you want to allow sending (non-interactive) components for non-application-owned webhooks- Returns:
- If wait is true, a mono that contains the message information of the execution or an error if the webhook is unsuccessful. If wait is false, the mono completes as soon as the request is finished sending, and DOES NOT result in an error if the message is not saved.
-
getWebhookMessage
-
getWebhookMessage
-
modifyWebhookMessage
-
modifyWebhookMessage
-
modifyWebhookMessage
-
modifyWebhookMessage
-
modifyWebhookMessage
public Mono<discord4j.discordjson.json.MessageData> modifyWebhookMessage(long webhookId, String webhookToken, String messageId, boolean withComponents, MultipartRequest<discord4j.discordjson.json.WebhookMessageEditRequest> request) -
modifyWebhookMessage
public Mono<discord4j.discordjson.json.MessageData> modifyWebhookMessage(long webhookId, String webhookToken, String messageId, MultipartRequest<discord4j.discordjson.json.WebhookMessageEditRequest> request) -
modifyWebhookMessage
public Mono<discord4j.discordjson.json.MessageData> modifyWebhookMessage(long webhookId, String webhookToken, String messageId, long threadId, boolean withComponents, MultipartRequest<discord4j.discordjson.json.WebhookMessageEditRequest> request) -
modifyWebhookMessage
public Mono<discord4j.discordjson.json.MessageData> modifyWebhookMessage(long webhookId, String webhookToken, String messageId, long threadId, MultipartRequest<discord4j.discordjson.json.WebhookMessageEditRequest> request) -
deleteWebhookMessage
-
deleteWebhookMessage
-