2121import com .datadog .api .client .v1 .model .SyntheticsAssertionJavascriptType ;
2222import com .datadog .api .client .v1 .model .SyntheticsAssertionOperator ;
2323import com .datadog .api .client .v1 .model .SyntheticsAssertionTarget ;
24+ import com .datadog .api .client .v1 .model .SyntheticsAssertionTargetValue ;
2425import com .datadog .api .client .v1 .model .SyntheticsAssertionTimingsScope ;
2526import com .datadog .api .client .v1 .model .SyntheticsAssertionType ;
2627import com .datadog .api .client .v1 .model .SyntheticsAssertionXPathOperator ;
@@ -59,12 +60,12 @@ public static void main(String[] args) {
5960 new SyntheticsAssertionTarget ()
6061 .operator (SyntheticsAssertionOperator .IS )
6162 .property ("{{ PROPERTY }}" )
62- .target ("text/html" )
63+ .target (new SyntheticsAssertionTargetValue ( "text/html" ) )
6364 .type (SyntheticsAssertionType .HEADER )),
6465 new SyntheticsAssertion (
6566 new SyntheticsAssertionTarget ()
6667 .operator (SyntheticsAssertionOperator .LESS_THAN )
67- .target (2000 )
68+ .target (new SyntheticsAssertionTargetValue ( 2000.0 ) )
6869 .type (SyntheticsAssertionType .RESPONSE_TIME )
6970 .timingsScope (SyntheticsAssertionTimingsScope .WITHOUT_DNS )),
7071 new SyntheticsAssertion (
@@ -75,7 +76,7 @@ public static void main(String[] args) {
7576 new SyntheticsAssertionJSONPathTargetTarget ()
7677 .jsonPath ("topKey" )
7778 .operator ("isNot" )
78- .targetValue ("0" ))
79+ .targetValue (new SyntheticsAssertionTargetValue ( "0" ) ))
7980 .type (SyntheticsAssertionType .BODY )),
8081 new SyntheticsAssertion (
8182 new SyntheticsAssertionJSONPathTarget ()
@@ -86,7 +87,7 @@ public static void main(String[] args) {
8687 .elementsOperator ("atLeastOneElementMatches" )
8788 .jsonPath ("topKey" )
8889 .operator ("isNot" )
89- .targetValue ("0" ))
90+ .targetValue (new SyntheticsAssertionTargetValue ( "0" ) ))
9091 .type (SyntheticsAssertionType .BODY )),
9192 new SyntheticsAssertion (
9293 new SyntheticsAssertionJSONSchemaTarget ()
@@ -107,13 +108,13 @@ public static void main(String[] args) {
107108 .target (
108109 new SyntheticsAssertionXPathTargetTarget ()
109110 .xPath ("target-xpath" )
110- .targetValue ("0" )
111+ .targetValue (new SyntheticsAssertionTargetValue ( "0" ) )
111112 .operator ("contains" ))
112113 .type (SyntheticsAssertionType .BODY )),
113114 new SyntheticsAssertion (
114115 new SyntheticsAssertionBodyHashTarget ()
115116 .operator (SyntheticsAssertionBodyHashOperator .MD5 )
116- .target ("a" )
117+ .target (new SyntheticsAssertionTargetValue ( "a" ) )
117118 .type (SyntheticsAssertionBodyHashType .BODY_HASH )),
118119 new SyntheticsAssertion (
119120 new SyntheticsAssertionJavascript ()
0 commit comments