99import jakarta .ws .rs .core .GenericType ;
1010import java .util .ArrayList ;
1111import java .util .HashMap ;
12+ import java .util .List ;
1213import java .util .Map ;
1314import java .util .concurrent .CompletableFuture ;
1415
@@ -48,29 +49,35 @@ public void setApiClient(ApiClient apiClient) {
4849 *
4950 * <p>See {@link #getServiceListWithHttpInfo}.
5051 *
52+ * @param filterEnv Filter services by environment. Can be set to <code>*</code> to return all
53+ * services across all environments. (required)
5154 * @return ServiceList
5255 * @throws ApiException if fails to make API call
5356 */
54- public ServiceList getServiceList () throws ApiException {
55- return getServiceListWithHttpInfo ().getData ();
57+ public ServiceList getServiceList (String filterEnv ) throws ApiException {
58+ return getServiceListWithHttpInfo (filterEnv ).getData ();
5659 }
5760
5861 /**
5962 * Get service list.
6063 *
6164 * <p>See {@link #getServiceListWithHttpInfoAsync}.
6265 *
66+ * @param filterEnv Filter services by environment. Can be set to <code>*</code> to return all
67+ * services across all environments. (required)
6368 * @return CompletableFuture<ServiceList>
6469 */
65- public CompletableFuture <ServiceList > getServiceListAsync () {
66- return getServiceListWithHttpInfoAsync ()
70+ public CompletableFuture <ServiceList > getServiceListAsync (String filterEnv ) {
71+ return getServiceListWithHttpInfoAsync (filterEnv )
6772 .thenApply (
6873 response -> {
6974 return response .getData ();
7075 });
7176 }
7277
7378 /**
79+ * @param filterEnv Filter services by environment. Can be set to <code>*</code> to return all
80+ * services across all environments. (required)
7481 * @return ApiResponse<ServiceList>
7582 * @throws ApiException if fails to make API call
7683 * @http.response.details
@@ -81,18 +88,27 @@ public CompletableFuture<ServiceList> getServiceListAsync() {
8188 * <tr><td> 429 </td><td> Too many requests </td><td> - </td></tr>
8289 * </table>
8390 */
84- public ApiResponse <ServiceList > getServiceListWithHttpInfo () throws ApiException {
91+ public ApiResponse <ServiceList > getServiceListWithHttpInfo (String filterEnv ) throws ApiException {
8592 Object localVarPostBody = null ;
93+
94+ // verify the required parameter 'filterEnv' is set
95+ if (filterEnv == null ) {
96+ throw new ApiException (
97+ 400 , "Missing the required parameter 'filterEnv' when calling getServiceList" );
98+ }
8699 // create path and map variables
87100 String localVarPath = "/api/v2/apm/services" ;
88101
102+ List <Pair > localVarQueryParams = new ArrayList <Pair >();
89103 Map <String , String > localVarHeaderParams = new HashMap <String , String >();
90104
105+ localVarQueryParams .addAll (apiClient .parameterToPairs ("" , "filter[env]" , filterEnv ));
106+
91107 Invocation .Builder builder =
92108 apiClient .createBuilder (
93109 "v2.ApmApi.getServiceList" ,
94110 localVarPath ,
95- new ArrayList < Pair >() ,
111+ localVarQueryParams ,
96112 localVarHeaderParams ,
97113 new HashMap <String , String >(),
98114 new String [] {"application/json" },
@@ -113,22 +129,37 @@ public ApiResponse<ServiceList> getServiceListWithHttpInfo() throws ApiException
113129 *
114130 * <p>See {@link #getServiceListWithHttpInfo}.
115131 *
132+ * @param filterEnv Filter services by environment. Can be set to <code>*</code> to return all
133+ * services across all environments. (required)
116134 * @return CompletableFuture<ApiResponse<ServiceList>>
117135 */
118- public CompletableFuture <ApiResponse <ServiceList >> getServiceListWithHttpInfoAsync () {
136+ public CompletableFuture <ApiResponse <ServiceList >> getServiceListWithHttpInfoAsync (
137+ String filterEnv ) {
119138 Object localVarPostBody = null ;
139+
140+ // verify the required parameter 'filterEnv' is set
141+ if (filterEnv == null ) {
142+ CompletableFuture <ApiResponse <ServiceList >> result = new CompletableFuture <>();
143+ result .completeExceptionally (
144+ new ApiException (
145+ 400 , "Missing the required parameter 'filterEnv' when calling getServiceList" ));
146+ return result ;
147+ }
120148 // create path and map variables
121149 String localVarPath = "/api/v2/apm/services" ;
122150
151+ List <Pair > localVarQueryParams = new ArrayList <Pair >();
123152 Map <String , String > localVarHeaderParams = new HashMap <String , String >();
124153
154+ localVarQueryParams .addAll (apiClient .parameterToPairs ("" , "filter[env]" , filterEnv ));
155+
125156 Invocation .Builder builder ;
126157 try {
127158 builder =
128159 apiClient .createBuilder (
129160 "v2.ApmApi.getServiceList" ,
130161 localVarPath ,
131- new ArrayList < Pair >() ,
162+ localVarQueryParams ,
132163 localVarHeaderParams ,
133164 new HashMap <String , String >(),
134165 new String [] {"application/json" },
0 commit comments