2121/** Request body for filtering cost recommendations. */
2222@ JsonPropertyOrder ({
2323 RecommendationsFilterRequest .JSON_PROPERTY_FILTER ,
24+ RecommendationsFilterRequest .JSON_PROPERTY_SCOPE ,
2425 RecommendationsFilterRequest .JSON_PROPERTY_SORT ,
2526 RecommendationsFilterRequest .JSON_PROPERTY_VIEW
2627})
@@ -31,6 +32,9 @@ public class RecommendationsFilterRequest {
3132 public static final String JSON_PROPERTY_FILTER = "filter" ;
3233 private String filter ;
3334
35+ public static final String JSON_PROPERTY_SCOPE = "scope" ;
36+ private RecommendationsFilterRequestScope scope ;
37+
3438 public static final String JSON_PROPERTY_SORT = "sort" ;
3539 private List <RecommendationsFilterRequestSortItems > sort = null ;
3640
@@ -58,6 +62,32 @@ public void setFilter(String filter) {
5862 this .filter = filter ;
5963 }
6064
65+ public RecommendationsFilterRequest scope (RecommendationsFilterRequestScope scope ) {
66+ this .scope = scope ;
67+ this .unparsed |= !scope .isValid ();
68+ return this ;
69+ }
70+
71+ /**
72+ * Recommendations scope. Defaults to <code>ccm</code>; use <code>experiment</code> for
73+ * experimental recommendations or <code>*</code> for both.
74+ *
75+ * @return scope
76+ */
77+ @ jakarta .annotation .Nullable
78+ @ JsonProperty (JSON_PROPERTY_SCOPE )
79+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
80+ public RecommendationsFilterRequestScope getScope () {
81+ return scope ;
82+ }
83+
84+ public void setScope (RecommendationsFilterRequestScope scope ) {
85+ if (!scope .isValid ()) {
86+ this .unparsed = true ;
87+ }
88+ this .scope = scope ;
89+ }
90+
6191 public RecommendationsFilterRequest sort (List <RecommendationsFilterRequestSortItems > sort ) {
6292 this .sort = sort ;
6393 if (sort != null ) {
@@ -177,6 +207,7 @@ public boolean equals(Object o) {
177207 }
178208 RecommendationsFilterRequest recommendationsFilterRequest = (RecommendationsFilterRequest ) o ;
179209 return Objects .equals (this .filter , recommendationsFilterRequest .filter )
210+ && Objects .equals (this .scope , recommendationsFilterRequest .scope )
180211 && Objects .equals (this .sort , recommendationsFilterRequest .sort )
181212 && Objects .equals (this .view , recommendationsFilterRequest .view )
182213 && Objects .equals (
@@ -185,14 +216,15 @@ public boolean equals(Object o) {
185216
186217 @ Override
187218 public int hashCode () {
188- return Objects .hash (filter , sort , view , additionalProperties );
219+ return Objects .hash (filter , scope , sort , view , additionalProperties );
189220 }
190221
191222 @ Override
192223 public String toString () {
193224 StringBuilder sb = new StringBuilder ();
194225 sb .append ("class RecommendationsFilterRequest {\n " );
195226 sb .append (" filter: " ).append (toIndentedString (filter )).append ("\n " );
227+ sb .append (" scope: " ).append (toIndentedString (scope )).append ("\n " );
196228 sb .append (" sort: " ).append (toIndentedString (sort )).append ("\n " );
197229 sb .append (" view: " ).append (toIndentedString (view )).append ("\n " );
198230 sb .append (" additionalProperties: " )
0 commit comments