From 0feaae8f1b39cef894a8eab82aaeee6733eb0434 Mon Sep 17 00:00:00 2001 From: Fedor Lapshin Date: Fri, 15 Jul 2022 00:40:21 +0300 Subject: [PATCH] feat(ApplicationCommandOption): min and max length (#1208) Implement min_length and max_length for string option type. --- interactions.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/interactions.go b/interactions.go index 70509cd..61a4e99 100644 --- a/interactions.go +++ b/interactions.go @@ -118,6 +118,10 @@ type ApplicationCommandOption struct { MinValue *float64 `json:"min_value,omitempty"` // Maximum value of number/integer option. MaxValue float64 `json:"max_value,omitempty"` + // Minimum length of string option. + MinLength *int `json:"min_length,omitempty"` + // Maximum length of string option. + MaxLength int `json:"max_length,omitempty"` } // ApplicationCommandOptionChoice represents a slash command option choice.