@@ -23,6 +23,8 @@ type ApplicationSecurityWafCustomRuleConditionParameters struct {
2323 Options * ApplicationSecurityWafCustomRuleConditionOptions `json:"options,omitempty"`
2424 // Regex to use with the condition. Only used with match_regex and !match_regex operator.
2525 Regex * string `json:"regex,omitempty"`
26+ // The type of the value to compare against. Only used with the equals and !equals operator.
27+ Type * ApplicationSecurityWafCustomRuleConditionParametersType `json:"type,omitempty"`
2628 // Store the captured value in the specified tag name. Only used with the capture_data operator.
2729 Value * string `json:"value,omitempty"`
2830 // UnparsedObject contains the raw value of the object if there was an error when deserializing into the struct
@@ -183,6 +185,34 @@ func (o *ApplicationSecurityWafCustomRuleConditionParameters) SetRegex(v string)
183185 o .Regex = & v
184186}
185187
188+ // GetType returns the Type field value if set, zero value otherwise.
189+ func (o * ApplicationSecurityWafCustomRuleConditionParameters ) GetType () ApplicationSecurityWafCustomRuleConditionParametersType {
190+ if o == nil || o .Type == nil {
191+ var ret ApplicationSecurityWafCustomRuleConditionParametersType
192+ return ret
193+ }
194+ return * o .Type
195+ }
196+
197+ // GetTypeOk returns a tuple with the Type field value if set, nil otherwise
198+ // and a boolean to check if the value has been set.
199+ func (o * ApplicationSecurityWafCustomRuleConditionParameters ) GetTypeOk () (* ApplicationSecurityWafCustomRuleConditionParametersType , bool ) {
200+ if o == nil || o .Type == nil {
201+ return nil , false
202+ }
203+ return o .Type , true
204+ }
205+
206+ // HasType returns a boolean if a field has been set.
207+ func (o * ApplicationSecurityWafCustomRuleConditionParameters ) HasType () bool {
208+ return o != nil && o .Type != nil
209+ }
210+
211+ // SetType gets a reference to the given ApplicationSecurityWafCustomRuleConditionParametersType and assigns it to the Type field.
212+ func (o * ApplicationSecurityWafCustomRuleConditionParameters ) SetType (v ApplicationSecurityWafCustomRuleConditionParametersType ) {
213+ o .Type = & v
214+ }
215+
186216// GetValue returns the Value field value if set, zero value otherwise.
187217func (o * ApplicationSecurityWafCustomRuleConditionParameters ) GetValue () string {
188218 if o == nil || o .Value == nil {
@@ -230,6 +260,9 @@ func (o ApplicationSecurityWafCustomRuleConditionParameters) MarshalJSON() ([]by
230260 if o .Regex != nil {
231261 toSerialize ["regex" ] = o .Regex
232262 }
263+ if o .Type != nil {
264+ toSerialize ["type" ] = o .Type
265+ }
233266 if o .Value != nil {
234267 toSerialize ["value" ] = o .Value
235268 }
@@ -243,12 +276,13 @@ func (o ApplicationSecurityWafCustomRuleConditionParameters) MarshalJSON() ([]by
243276// UnmarshalJSON deserializes the given payload.
244277func (o * ApplicationSecurityWafCustomRuleConditionParameters ) UnmarshalJSON (bytes []byte ) (err error ) {
245278 all := struct {
246- Data * string `json:"data,omitempty"`
247- Inputs * []ApplicationSecurityWafCustomRuleConditionInput `json:"inputs"`
248- List []string `json:"list,omitempty"`
249- Options * ApplicationSecurityWafCustomRuleConditionOptions `json:"options,omitempty"`
250- Regex * string `json:"regex,omitempty"`
251- Value * string `json:"value,omitempty"`
279+ Data * string `json:"data,omitempty"`
280+ Inputs * []ApplicationSecurityWafCustomRuleConditionInput `json:"inputs"`
281+ List []string `json:"list,omitempty"`
282+ Options * ApplicationSecurityWafCustomRuleConditionOptions `json:"options,omitempty"`
283+ Regex * string `json:"regex,omitempty"`
284+ Type * ApplicationSecurityWafCustomRuleConditionParametersType `json:"type,omitempty"`
285+ Value * string `json:"value,omitempty"`
252286 }{}
253287 if err = datadog .Unmarshal (bytes , & all ); err != nil {
254288 return datadog .Unmarshal (bytes , & o .UnparsedObject )
@@ -258,7 +292,7 @@ func (o *ApplicationSecurityWafCustomRuleConditionParameters) UnmarshalJSON(byte
258292 }
259293 additionalProperties := make (map [string ]interface {})
260294 if err = datadog .Unmarshal (bytes , & additionalProperties ); err == nil {
261- datadog .DeleteKeys (additionalProperties , & []string {"data" , "inputs" , "list" , "options" , "regex" , "value" })
295+ datadog .DeleteKeys (additionalProperties , & []string {"data" , "inputs" , "list" , "options" , "regex" , "type" , " value" })
262296 } else {
263297 return err
264298 }
@@ -272,6 +306,11 @@ func (o *ApplicationSecurityWafCustomRuleConditionParameters) UnmarshalJSON(byte
272306 }
273307 o .Options = all .Options
274308 o .Regex = all .Regex
309+ if all .Type != nil && ! all .Type .IsValid () {
310+ hasInvalidField = true
311+ } else {
312+ o .Type = all .Type
313+ }
275314 o .Value = all .Value
276315
277316 if len (additionalProperties ) > 0 {
0 commit comments