|
29 | 29 |
|
30 | 30 | import com.volcengine.insight.model.ExpertInvokeAPIRequest; |
31 | 31 | import com.volcengine.insight.model.ExpertInvokeAPIResponse; |
| 32 | +import com.volcengine.insight.model.ListCustomSubsTaskRequest; |
| 33 | +import com.volcengine.insight.model.ListCustomSubsTaskResponse; |
32 | 34 | import com.volcengine.insight.model.ListSubsTaskAPIRequest; |
33 | 35 | import com.volcengine.insight.model.ListSubsTaskAPIResponse; |
34 | 36 | import com.volcengine.insight.model.PullPostRequest; |
35 | 37 | import com.volcengine.insight.model.PullPostResponse; |
| 38 | +import com.volcengine.insight.model.QueryClueInfoRequest; |
| 39 | +import com.volcengine.insight.model.QueryClueInfoResponse; |
36 | 40 |
|
37 | 41 | import java.lang.reflect.Type; |
38 | 42 | import java.util.ArrayList; |
@@ -183,6 +187,130 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don |
183 | 187 | apiClient.executeAsync(call, localVarReturnType, callback); |
184 | 188 | return call; |
185 | 189 | } |
| 190 | + /** |
| 191 | + * Build call for listCustomSubsTask |
| 192 | + * @param body (required) |
| 193 | + * @param progressListener Progress listener |
| 194 | + * @param progressRequestListener Progress request listener |
| 195 | + * @return Call to execute |
| 196 | + * @throws ApiException If fail to serialize the request body object |
| 197 | + */ |
| 198 | + public com.squareup.okhttp.Call listCustomSubsTaskCall(ListCustomSubsTaskRequest body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 199 | + Object localVarPostBody = body; |
| 200 | + |
| 201 | + // create path and map variables |
| 202 | + String localVarPath = "/ListCustomSubsTask/2025-09-05/insight/get/text_plain/"; |
| 203 | + |
| 204 | + List<Pair> localVarQueryParams = new ArrayList<Pair>(); |
| 205 | + List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>(); |
| 206 | + |
| 207 | + Map<String, String> localVarHeaderParams = new HashMap<String, String>(); |
| 208 | + |
| 209 | + Map<String, Object> localVarFormParams = new HashMap<String, Object>(); |
| 210 | + |
| 211 | + final String[] localVarAccepts = { |
| 212 | + "application/json" |
| 213 | + }; |
| 214 | + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); |
| 215 | + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); |
| 216 | + |
| 217 | + final String[] localVarContentTypes = { |
| 218 | + "text/plain" |
| 219 | + }; |
| 220 | + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); |
| 221 | + localVarHeaderParams.put("Content-Type", localVarContentType); |
| 222 | + |
| 223 | + if(progressListener != null) { |
| 224 | + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { |
| 225 | + @Override |
| 226 | + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { |
| 227 | + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); |
| 228 | + return originalResponse.newBuilder() |
| 229 | + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) |
| 230 | + .build(); |
| 231 | + } |
| 232 | + }); |
| 233 | + } |
| 234 | + |
| 235 | + String[] localVarAuthNames = new String[] { "volcengineSign" }; |
| 236 | + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); |
| 237 | + } |
| 238 | + |
| 239 | + @SuppressWarnings("rawtypes") |
| 240 | + private com.squareup.okhttp.Call listCustomSubsTaskValidateBeforeCall(ListCustomSubsTaskRequest body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 241 | + // verify the required parameter 'body' is set |
| 242 | + if (body == null) { |
| 243 | + throw new ApiException("Missing the required parameter 'body' when calling listCustomSubsTask(Async)"); |
| 244 | + } |
| 245 | + |
| 246 | + com.squareup.okhttp.Call call = listCustomSubsTaskCall(body, progressListener, progressRequestListener); |
| 247 | + return call; |
| 248 | + |
| 249 | + |
| 250 | + |
| 251 | + |
| 252 | + |
| 253 | + } |
| 254 | + |
| 255 | + /** |
| 256 | + * |
| 257 | + * |
| 258 | + * @param body (required) |
| 259 | + * @return ListCustomSubsTaskResponse |
| 260 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 261 | + */ |
| 262 | + public ListCustomSubsTaskResponse listCustomSubsTask(ListCustomSubsTaskRequest body) throws ApiException { |
| 263 | + ApiResponse<ListCustomSubsTaskResponse> resp = listCustomSubsTaskWithHttpInfo(body); |
| 264 | + return resp.getData(); |
| 265 | + } |
| 266 | + |
| 267 | + /** |
| 268 | + * |
| 269 | + * |
| 270 | + * @param body (required) |
| 271 | + * @return ApiResponse<ListCustomSubsTaskResponse> |
| 272 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 273 | + */ |
| 274 | + public ApiResponse<ListCustomSubsTaskResponse> listCustomSubsTaskWithHttpInfo( @NotNull ListCustomSubsTaskRequest body) throws ApiException { |
| 275 | + com.squareup.okhttp.Call call = listCustomSubsTaskValidateBeforeCall(body, null, null); |
| 276 | + Type localVarReturnType = new TypeToken<ListCustomSubsTaskResponse>(){}.getType(); |
| 277 | + return apiClient.execute(call, localVarReturnType); |
| 278 | + } |
| 279 | + |
| 280 | + /** |
| 281 | + * (asynchronously) |
| 282 | + * |
| 283 | + * @param body (required) |
| 284 | + * @param callback The callback to be executed when the API call finishes |
| 285 | + * @return The request call |
| 286 | + * @throws ApiException If fail to process the API call, e.g. serializing the request body object |
| 287 | + */ |
| 288 | + public com.squareup.okhttp.Call listCustomSubsTaskAsync(ListCustomSubsTaskRequest body, final ApiCallback<ListCustomSubsTaskResponse> callback) throws ApiException { |
| 289 | + |
| 290 | + ProgressResponseBody.ProgressListener progressListener = null; |
| 291 | + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; |
| 292 | + |
| 293 | + if (callback != null) { |
| 294 | + progressListener = new ProgressResponseBody.ProgressListener() { |
| 295 | + @Override |
| 296 | + public void update(long bytesRead, long contentLength, boolean done) { |
| 297 | + callback.onDownloadProgress(bytesRead, contentLength, done); |
| 298 | + } |
| 299 | + }; |
| 300 | + |
| 301 | + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { |
| 302 | + @Override |
| 303 | + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { |
| 304 | + callback.onUploadProgress(bytesWritten, contentLength, done); |
| 305 | + } |
| 306 | + }; |
| 307 | + } |
| 308 | + |
| 309 | + com.squareup.okhttp.Call call = listCustomSubsTaskValidateBeforeCall(body, progressListener, progressRequestListener); |
| 310 | + Type localVarReturnType = new TypeToken<ListCustomSubsTaskResponse>(){}.getType(); |
| 311 | + apiClient.executeAsync(call, localVarReturnType, callback); |
| 312 | + return call; |
| 313 | + } |
186 | 314 | /** |
187 | 315 | * Build call for listSubsTaskAPI |
188 | 316 | * @param body (required) |
@@ -431,4 +559,128 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don |
431 | 559 | apiClient.executeAsync(call, localVarReturnType, callback); |
432 | 560 | return call; |
433 | 561 | } |
| 562 | + /** |
| 563 | + * Build call for queryClueInfo |
| 564 | + * @param body (required) |
| 565 | + * @param progressListener Progress listener |
| 566 | + * @param progressRequestListener Progress request listener |
| 567 | + * @return Call to execute |
| 568 | + * @throws ApiException If fail to serialize the request body object |
| 569 | + */ |
| 570 | + public com.squareup.okhttp.Call queryClueInfoCall(QueryClueInfoRequest body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 571 | + Object localVarPostBody = body; |
| 572 | + |
| 573 | + // create path and map variables |
| 574 | + String localVarPath = "/QueryClueInfo/2025-09-05/insight/get/text_plain/"; |
| 575 | + |
| 576 | + List<Pair> localVarQueryParams = new ArrayList<Pair>(); |
| 577 | + List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>(); |
| 578 | + |
| 579 | + Map<String, String> localVarHeaderParams = new HashMap<String, String>(); |
| 580 | + |
| 581 | + Map<String, Object> localVarFormParams = new HashMap<String, Object>(); |
| 582 | + |
| 583 | + final String[] localVarAccepts = { |
| 584 | + "application/json" |
| 585 | + }; |
| 586 | + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); |
| 587 | + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); |
| 588 | + |
| 589 | + final String[] localVarContentTypes = { |
| 590 | + "text/plain" |
| 591 | + }; |
| 592 | + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); |
| 593 | + localVarHeaderParams.put("Content-Type", localVarContentType); |
| 594 | + |
| 595 | + if(progressListener != null) { |
| 596 | + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { |
| 597 | + @Override |
| 598 | + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { |
| 599 | + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); |
| 600 | + return originalResponse.newBuilder() |
| 601 | + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) |
| 602 | + .build(); |
| 603 | + } |
| 604 | + }); |
| 605 | + } |
| 606 | + |
| 607 | + String[] localVarAuthNames = new String[] { "volcengineSign" }; |
| 608 | + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); |
| 609 | + } |
| 610 | + |
| 611 | + @SuppressWarnings("rawtypes") |
| 612 | + private com.squareup.okhttp.Call queryClueInfoValidateBeforeCall(QueryClueInfoRequest body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 613 | + // verify the required parameter 'body' is set |
| 614 | + if (body == null) { |
| 615 | + throw new ApiException("Missing the required parameter 'body' when calling queryClueInfo(Async)"); |
| 616 | + } |
| 617 | + |
| 618 | + com.squareup.okhttp.Call call = queryClueInfoCall(body, progressListener, progressRequestListener); |
| 619 | + return call; |
| 620 | + |
| 621 | + |
| 622 | + |
| 623 | + |
| 624 | + |
| 625 | + } |
| 626 | + |
| 627 | + /** |
| 628 | + * |
| 629 | + * |
| 630 | + * @param body (required) |
| 631 | + * @return QueryClueInfoResponse |
| 632 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 633 | + */ |
| 634 | + public QueryClueInfoResponse queryClueInfo(QueryClueInfoRequest body) throws ApiException { |
| 635 | + ApiResponse<QueryClueInfoResponse> resp = queryClueInfoWithHttpInfo(body); |
| 636 | + return resp.getData(); |
| 637 | + } |
| 638 | + |
| 639 | + /** |
| 640 | + * |
| 641 | + * |
| 642 | + * @param body (required) |
| 643 | + * @return ApiResponse<QueryClueInfoResponse> |
| 644 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 645 | + */ |
| 646 | + public ApiResponse<QueryClueInfoResponse> queryClueInfoWithHttpInfo( @NotNull QueryClueInfoRequest body) throws ApiException { |
| 647 | + com.squareup.okhttp.Call call = queryClueInfoValidateBeforeCall(body, null, null); |
| 648 | + Type localVarReturnType = new TypeToken<QueryClueInfoResponse>(){}.getType(); |
| 649 | + return apiClient.execute(call, localVarReturnType); |
| 650 | + } |
| 651 | + |
| 652 | + /** |
| 653 | + * (asynchronously) |
| 654 | + * |
| 655 | + * @param body (required) |
| 656 | + * @param callback The callback to be executed when the API call finishes |
| 657 | + * @return The request call |
| 658 | + * @throws ApiException If fail to process the API call, e.g. serializing the request body object |
| 659 | + */ |
| 660 | + public com.squareup.okhttp.Call queryClueInfoAsync(QueryClueInfoRequest body, final ApiCallback<QueryClueInfoResponse> callback) throws ApiException { |
| 661 | + |
| 662 | + ProgressResponseBody.ProgressListener progressListener = null; |
| 663 | + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; |
| 664 | + |
| 665 | + if (callback != null) { |
| 666 | + progressListener = new ProgressResponseBody.ProgressListener() { |
| 667 | + @Override |
| 668 | + public void update(long bytesRead, long contentLength, boolean done) { |
| 669 | + callback.onDownloadProgress(bytesRead, contentLength, done); |
| 670 | + } |
| 671 | + }; |
| 672 | + |
| 673 | + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { |
| 674 | + @Override |
| 675 | + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { |
| 676 | + callback.onUploadProgress(bytesWritten, contentLength, done); |
| 677 | + } |
| 678 | + }; |
| 679 | + } |
| 680 | + |
| 681 | + com.squareup.okhttp.Call call = queryClueInfoValidateBeforeCall(body, progressListener, progressRequestListener); |
| 682 | + Type localVarReturnType = new TypeToken<QueryClueInfoResponse>(){}.getType(); |
| 683 | + apiClient.executeAsync(call, localVarReturnType, callback); |
| 684 | + return call; |
| 685 | + } |
434 | 686 | } |
0 commit comments