|
95 | 95 | import com.volcengine.organization.model.ListServiceControlPoliciesResponse; |
96 | 96 | import com.volcengine.organization.model.ListTagResourcesRequest; |
97 | 97 | import com.volcengine.organization.model.ListTagResourcesResponse; |
| 98 | +import com.volcengine.organization.model.ListTagsKeysRequest; |
| 99 | +import com.volcengine.organization.model.ListTagsKeysResponse; |
| 100 | +import com.volcengine.organization.model.ListTagsValuesRequest; |
| 101 | +import com.volcengine.organization.model.ListTagsValuesResponse; |
98 | 102 | import com.volcengine.organization.model.ListTargetsForPolicyRequest; |
99 | 103 | import com.volcengine.organization.model.ListTargetsForPolicyResponse; |
100 | 104 | import com.volcengine.organization.model.MoveAccountRequest; |
@@ -4363,6 +4367,254 @@ public void onRequestProgress(long bytesWritten, long contentLength, boolean don |
4363 | 4367 | apiClient.executeAsync(call, localVarReturnType, callback); |
4364 | 4368 | return call; |
4365 | 4369 | } |
| 4370 | + /** |
| 4371 | + * Build call for listTagsKeys |
| 4372 | + * @param body (required) |
| 4373 | + * @param progressListener Progress listener |
| 4374 | + * @param progressRequestListener Progress request listener |
| 4375 | + * @return Call to execute |
| 4376 | + * @throws ApiException If fail to serialize the request body object |
| 4377 | + */ |
| 4378 | + public com.squareup.okhttp.Call listTagsKeysCall(ListTagsKeysRequest body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 4379 | + Object localVarPostBody = body; |
| 4380 | + |
| 4381 | + // create path and map variables |
| 4382 | + String localVarPath = "/ListTagsKeys/2022-01-01/organization/post/application_json/"; |
| 4383 | + |
| 4384 | + List<Pair> localVarQueryParams = new ArrayList<Pair>(); |
| 4385 | + List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>(); |
| 4386 | + |
| 4387 | + Map<String, String> localVarHeaderParams = new HashMap<String, String>(); |
| 4388 | + |
| 4389 | + Map<String, Object> localVarFormParams = new HashMap<String, Object>(); |
| 4390 | + |
| 4391 | + final String[] localVarAccepts = { |
| 4392 | + "application/json" |
| 4393 | + }; |
| 4394 | + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); |
| 4395 | + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); |
| 4396 | + |
| 4397 | + final String[] localVarContentTypes = { |
| 4398 | + "text/plain" |
| 4399 | + }; |
| 4400 | + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); |
| 4401 | + localVarHeaderParams.put("Content-Type", localVarContentType); |
| 4402 | + |
| 4403 | + if(progressListener != null) { |
| 4404 | + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { |
| 4405 | + @Override |
| 4406 | + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { |
| 4407 | + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); |
| 4408 | + return originalResponse.newBuilder() |
| 4409 | + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) |
| 4410 | + .build(); |
| 4411 | + } |
| 4412 | + }); |
| 4413 | + } |
| 4414 | + |
| 4415 | + String[] localVarAuthNames = new String[] { "volcengineSign" }; |
| 4416 | + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); |
| 4417 | + } |
| 4418 | + |
| 4419 | + @SuppressWarnings("rawtypes") |
| 4420 | + private com.squareup.okhttp.Call listTagsKeysValidateBeforeCall(ListTagsKeysRequest body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 4421 | + // verify the required parameter 'body' is set |
| 4422 | + if (body == null) { |
| 4423 | + throw new ApiException("Missing the required parameter 'body' when calling listTagsKeys(Async)"); |
| 4424 | + } |
| 4425 | + |
| 4426 | + com.squareup.okhttp.Call call = listTagsKeysCall(body, progressListener, progressRequestListener); |
| 4427 | + return call; |
| 4428 | + |
| 4429 | + |
| 4430 | + |
| 4431 | + |
| 4432 | + |
| 4433 | + } |
| 4434 | + |
| 4435 | + /** |
| 4436 | + * |
| 4437 | + * |
| 4438 | + * @param body (required) |
| 4439 | + * @return ListTagsKeysResponse |
| 4440 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 4441 | + */ |
| 4442 | + public ListTagsKeysResponse listTagsKeys(ListTagsKeysRequest body) throws ApiException { |
| 4443 | + ApiResponse<ListTagsKeysResponse> resp = listTagsKeysWithHttpInfo(body); |
| 4444 | + return resp.getData(); |
| 4445 | + } |
| 4446 | + |
| 4447 | + /** |
| 4448 | + * |
| 4449 | + * |
| 4450 | + * @param body (required) |
| 4451 | + * @return ApiResponse<ListTagsKeysResponse> |
| 4452 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 4453 | + */ |
| 4454 | + public ApiResponse<ListTagsKeysResponse> listTagsKeysWithHttpInfo( @NotNull ListTagsKeysRequest body) throws ApiException { |
| 4455 | + com.squareup.okhttp.Call call = listTagsKeysValidateBeforeCall(body, null, null); |
| 4456 | + Type localVarReturnType = new TypeToken<ListTagsKeysResponse>(){}.getType(); |
| 4457 | + return apiClient.execute(call, localVarReturnType); |
| 4458 | + } |
| 4459 | + |
| 4460 | + /** |
| 4461 | + * (asynchronously) |
| 4462 | + * |
| 4463 | + * @param body (required) |
| 4464 | + * @param callback The callback to be executed when the API call finishes |
| 4465 | + * @return The request call |
| 4466 | + * @throws ApiException If fail to process the API call, e.g. serializing the request body object |
| 4467 | + */ |
| 4468 | + public com.squareup.okhttp.Call listTagsKeysAsync(ListTagsKeysRequest body, final ApiCallback<ListTagsKeysResponse> callback) throws ApiException { |
| 4469 | + |
| 4470 | + ProgressResponseBody.ProgressListener progressListener = null; |
| 4471 | + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; |
| 4472 | + |
| 4473 | + if (callback != null) { |
| 4474 | + progressListener = new ProgressResponseBody.ProgressListener() { |
| 4475 | + @Override |
| 4476 | + public void update(long bytesRead, long contentLength, boolean done) { |
| 4477 | + callback.onDownloadProgress(bytesRead, contentLength, done); |
| 4478 | + } |
| 4479 | + }; |
| 4480 | + |
| 4481 | + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { |
| 4482 | + @Override |
| 4483 | + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { |
| 4484 | + callback.onUploadProgress(bytesWritten, contentLength, done); |
| 4485 | + } |
| 4486 | + }; |
| 4487 | + } |
| 4488 | + |
| 4489 | + com.squareup.okhttp.Call call = listTagsKeysValidateBeforeCall(body, progressListener, progressRequestListener); |
| 4490 | + Type localVarReturnType = new TypeToken<ListTagsKeysResponse>(){}.getType(); |
| 4491 | + apiClient.executeAsync(call, localVarReturnType, callback); |
| 4492 | + return call; |
| 4493 | + } |
| 4494 | + /** |
| 4495 | + * Build call for listTagsValues |
| 4496 | + * @param body (required) |
| 4497 | + * @param progressListener Progress listener |
| 4498 | + * @param progressRequestListener Progress request listener |
| 4499 | + * @return Call to execute |
| 4500 | + * @throws ApiException If fail to serialize the request body object |
| 4501 | + */ |
| 4502 | + public com.squareup.okhttp.Call listTagsValuesCall(ListTagsValuesRequest body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 4503 | + Object localVarPostBody = body; |
| 4504 | + |
| 4505 | + // create path and map variables |
| 4506 | + String localVarPath = "/ListTagsValues/2022-01-01/organization/post/application_json/"; |
| 4507 | + |
| 4508 | + List<Pair> localVarQueryParams = new ArrayList<Pair>(); |
| 4509 | + List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>(); |
| 4510 | + |
| 4511 | + Map<String, String> localVarHeaderParams = new HashMap<String, String>(); |
| 4512 | + |
| 4513 | + Map<String, Object> localVarFormParams = new HashMap<String, Object>(); |
| 4514 | + |
| 4515 | + final String[] localVarAccepts = { |
| 4516 | + "application/json" |
| 4517 | + }; |
| 4518 | + final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts); |
| 4519 | + if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept); |
| 4520 | + |
| 4521 | + final String[] localVarContentTypes = { |
| 4522 | + "text/plain" |
| 4523 | + }; |
| 4524 | + final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes); |
| 4525 | + localVarHeaderParams.put("Content-Type", localVarContentType); |
| 4526 | + |
| 4527 | + if(progressListener != null) { |
| 4528 | + apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() { |
| 4529 | + @Override |
| 4530 | + public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException { |
| 4531 | + com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request()); |
| 4532 | + return originalResponse.newBuilder() |
| 4533 | + .body(new ProgressResponseBody(originalResponse.body(), progressListener)) |
| 4534 | + .build(); |
| 4535 | + } |
| 4536 | + }); |
| 4537 | + } |
| 4538 | + |
| 4539 | + String[] localVarAuthNames = new String[] { "volcengineSign" }; |
| 4540 | + return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener); |
| 4541 | + } |
| 4542 | + |
| 4543 | + @SuppressWarnings("rawtypes") |
| 4544 | + private com.squareup.okhttp.Call listTagsValuesValidateBeforeCall(ListTagsValuesRequest body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException { |
| 4545 | + // verify the required parameter 'body' is set |
| 4546 | + if (body == null) { |
| 4547 | + throw new ApiException("Missing the required parameter 'body' when calling listTagsValues(Async)"); |
| 4548 | + } |
| 4549 | + |
| 4550 | + com.squareup.okhttp.Call call = listTagsValuesCall(body, progressListener, progressRequestListener); |
| 4551 | + return call; |
| 4552 | + |
| 4553 | + |
| 4554 | + |
| 4555 | + |
| 4556 | + |
| 4557 | + } |
| 4558 | + |
| 4559 | + /** |
| 4560 | + * |
| 4561 | + * |
| 4562 | + * @param body (required) |
| 4563 | + * @return ListTagsValuesResponse |
| 4564 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 4565 | + */ |
| 4566 | + public ListTagsValuesResponse listTagsValues(ListTagsValuesRequest body) throws ApiException { |
| 4567 | + ApiResponse<ListTagsValuesResponse> resp = listTagsValuesWithHttpInfo(body); |
| 4568 | + return resp.getData(); |
| 4569 | + } |
| 4570 | + |
| 4571 | + /** |
| 4572 | + * |
| 4573 | + * |
| 4574 | + * @param body (required) |
| 4575 | + * @return ApiResponse<ListTagsValuesResponse> |
| 4576 | + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body |
| 4577 | + */ |
| 4578 | + public ApiResponse<ListTagsValuesResponse> listTagsValuesWithHttpInfo( @NotNull ListTagsValuesRequest body) throws ApiException { |
| 4579 | + com.squareup.okhttp.Call call = listTagsValuesValidateBeforeCall(body, null, null); |
| 4580 | + Type localVarReturnType = new TypeToken<ListTagsValuesResponse>(){}.getType(); |
| 4581 | + return apiClient.execute(call, localVarReturnType); |
| 4582 | + } |
| 4583 | + |
| 4584 | + /** |
| 4585 | + * (asynchronously) |
| 4586 | + * |
| 4587 | + * @param body (required) |
| 4588 | + * @param callback The callback to be executed when the API call finishes |
| 4589 | + * @return The request call |
| 4590 | + * @throws ApiException If fail to process the API call, e.g. serializing the request body object |
| 4591 | + */ |
| 4592 | + public com.squareup.okhttp.Call listTagsValuesAsync(ListTagsValuesRequest body, final ApiCallback<ListTagsValuesResponse> callback) throws ApiException { |
| 4593 | + |
| 4594 | + ProgressResponseBody.ProgressListener progressListener = null; |
| 4595 | + ProgressRequestBody.ProgressRequestListener progressRequestListener = null; |
| 4596 | + |
| 4597 | + if (callback != null) { |
| 4598 | + progressListener = new ProgressResponseBody.ProgressListener() { |
| 4599 | + @Override |
| 4600 | + public void update(long bytesRead, long contentLength, boolean done) { |
| 4601 | + callback.onDownloadProgress(bytesRead, contentLength, done); |
| 4602 | + } |
| 4603 | + }; |
| 4604 | + |
| 4605 | + progressRequestListener = new ProgressRequestBody.ProgressRequestListener() { |
| 4606 | + @Override |
| 4607 | + public void onRequestProgress(long bytesWritten, long contentLength, boolean done) { |
| 4608 | + callback.onUploadProgress(bytesWritten, contentLength, done); |
| 4609 | + } |
| 4610 | + }; |
| 4611 | + } |
| 4612 | + |
| 4613 | + com.squareup.okhttp.Call call = listTagsValuesValidateBeforeCall(body, progressListener, progressRequestListener); |
| 4614 | + Type localVarReturnType = new TypeToken<ListTagsValuesResponse>(){}.getType(); |
| 4615 | + apiClient.executeAsync(call, localVarReturnType, callback); |
| 4616 | + return call; |
| 4617 | + } |
4366 | 4618 | /** |
4367 | 4619 | * Build call for listTargetsForPolicy |
4368 | 4620 | * @param body (required) |
|
0 commit comments