Package discord4j.rest.interaction
Class TweetNaclFastInteractionValidator
- java.lang.Object
-
- discord4j.rest.interaction.TweetNaclFastInteractionValidator
-
- All Implemented Interfaces:
InteractionValidator
public class TweetNaclFastInteractionValidator extends Object implements InteractionValidator
-
-
Constructor Summary
Constructors Constructor Description TweetNaclFastInteractionValidator(String publicKey)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanvalidateSignature(String signature, String timestamp, String body)See https://discord.com/developers/docs/interactions/slash-commands#security-and-authorization
-
-
-
Constructor Detail
-
TweetNaclFastInteractionValidator
public TweetNaclFastInteractionValidator(String publicKey)
-
-
Method Detail
-
validateSignature
public boolean validateSignature(String signature, String timestamp, String body)
Description copied from interface:InteractionValidatorSee https://discord.com/developers/docs/interactions/slash-commands#security-and-authorization- Specified by:
validateSignaturein interfaceInteractionValidator- Parameters:
signature- the signature header of the requesttimestamp- the timestamp header of the requestbody- the body of the request- Returns:
trueif the request is valid,falseotherwise
-
-