content: /*
   * Selling Partner API for Reports
   * The Selling Partner API for Reports lets you retrieve and manage a variety of reports that can help selling partners manage their businesses.
   *
   * OpenAPI spec version: 2021-06-30
   * 
   *
   * NOTE: This class is auto generated by the swagger code generator program.
   * https://github.com/swagger-api/swagger-codegen.git
   * Do not edit the class manually.
   */
  
  
  package io.swagger.client.api;
  
  import io.swagger.client.ApiCallback;
  import io.swagger.client.ApiClient;
  import io.swagger.client.ApiException;
  import io.swagger.client.ApiResponse;
  import io.swagger.client.Configuration;
  import io.swagger.client.Pair;
  import io.swagger.client.ProgressRequestBody;
  import io.swagger.client.ProgressResponseBody;
  import io.swagger.client.StringUtil;
  
  import com.google.gson.reflect.TypeToken;
  
  import java.io.IOException;
  
  
  import io.swagger.client.model.ReportsApi.CreateReportResponse;
  import io.swagger.client.model.ReportsApi.CreateReportScheduleResponse;
  import io.swagger.client.model.ReportsApi.CreateReportScheduleSpecification;
  import io.swagger.client.model.ReportsApi.CreateReportSpecification;
  import io.swagger.client.model.ReportsApi.GetReportsResponse;
  import io.swagger.client.model.ReportsApi.CreateReportResponse;
  import org.threeten.bp.OffsetDateTime;
  import io.swagger.client.model.ReportsApi.Report;
  import io.swagger.client.model.ReportsApi.ReportDocument;
  import io.swagger.client.model.ReportsApi.ReportSchedule;
  import io.swagger.client.model.ReportsApi.ReportScheduleList;
  
  import java.lang.reflect.Type;
  import java.util.ArrayList;
  import java.util.HashMap;
  import java.util.List;
  import java.util.Map;
  
  import com.amazon.SellingPartnerAPIAA.LWAAccessTokenCache;
  import com.amazon.SellingPartnerAPIAA.LWAAccessTokenCacheImpl;
  import com.amazon.SellingPartnerAPIAA.LWAAuthorizationCredentials;
  import com.amazon.SellingPartnerAPIAA.LWAAuthorizationSigner;
  import com.amazon.SellingPartnerAPIAA.RateLimitConfiguration;
  import com.amazon.SellingPartnerAPIAA.LWAException;
  
  public class ReportsApi {
      private ApiClient apiClient;
  
      ReportsApi() {
          this(Configuration.getDefaultApiClient());
      }
  
      public ReportsApi(ApiClient apiClient) {
          this.apiClient = apiClient;
      }
  
      public ApiClient getApiClient() {
          return apiClient;
      }
  
      public void setApiClient(ApiClient apiClient) {
          this.apiClient = apiClient;
      }
  
      /**
       * Build call for cancelReport
       * @param reportId The identifier for the report. This identifier is unique only in combination with a seller ID. (required)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call cancelReportCall(String reportId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = null;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/reports/{reportId}"
              .replaceAll("\\{" + "reportId" + "\\}", apiClient.escapeString(reportId.toString()));
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call cancelReportValidateBeforeCall(String reportId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
          // verify the required parameter 'reportId' is set
          if (reportId == null) {
              throw new ApiException("Missing the required parameter 'reportId' when calling cancelReport(Async)");
          }
          
  
          com.squareup.okhttp.Call call = cancelReportCall(reportId, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Cancels the report that you specify. Only reports with &#x60;processingStatus&#x3D;IN_QUEUE&#x60; can be cancelled. Cancelled reports are returned in subsequent calls to the &#x60;getReport&#x60; and &#x60;getReports&#x60; operations.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportId The identifier for the report. This identifier is unique only in combination with a seller ID. (required)
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public void cancelReport(String reportId) throws ApiException,LWAException {
          cancelReportWithHttpInfo(reportId);
      }
  
      /**
       * 
       * Cancels the report that you specify. Only reports with &#x60;processingStatus&#x3D;IN_QUEUE&#x60; can be cancelled. Cancelled reports are returned in subsequent calls to the &#x60;getReport&#x60; and &#x60;getReports&#x60; operations.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportId The identifier for the report. This identifier is unique only in combination with a seller ID. (required)
       * @return ApiResponse&lt;Void&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<Void> cancelReportWithHttpInfo(String reportId) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = cancelReportValidateBeforeCall(reportId, null, null);
          return apiClient.execute(call);
      }
  
      /**
       *  (asynchronously)
       * Cancels the report that you specify. Only reports with &#x60;processingStatus&#x3D;IN_QUEUE&#x60; can be cancelled. Cancelled reports are returned in subsequent calls to the &#x60;getReport&#x60; and &#x60;getReports&#x60; operations.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportId The identifier for the report. This identifier is unique only in combination with a seller ID. (required)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call cancelReportAsync(String reportId, final ApiCallback<Void> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = cancelReportValidateBeforeCall(reportId, progressListener, progressRequestListener);
          apiClient.executeAsync(call, callback);
          return call;
      }
      /**
       * Build call for cancelReportSchedule
       * @param reportScheduleId The identifier for the report schedule. This identifier is unique only in combination with a seller ID. (required)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call cancelReportScheduleCall(String reportScheduleId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = null;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/schedules/{reportScheduleId}"
              .replaceAll("\\{" + "reportScheduleId" + "\\}", apiClient.escapeString(reportScheduleId.toString()));
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call cancelReportScheduleValidateBeforeCall(String reportScheduleId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
          // verify the required parameter 'reportScheduleId' is set
          if (reportScheduleId == null) {
              throw new ApiException("Missing the required parameter 'reportScheduleId' when calling cancelReportSchedule(Async)");
          }
          
  
          com.squareup.okhttp.Call call = cancelReportScheduleCall(reportScheduleId, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Cancels the report schedule that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportScheduleId The identifier for the report schedule. This identifier is unique only in combination with a seller ID. (required)
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public void cancelReportSchedule(String reportScheduleId) throws ApiException,LWAException {
          cancelReportScheduleWithHttpInfo(reportScheduleId);
      }
  
      /**
       * 
       * Cancels the report schedule that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportScheduleId The identifier for the report schedule. This identifier is unique only in combination with a seller ID. (required)
       * @return ApiResponse&lt;Void&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<Void> cancelReportScheduleWithHttpInfo(String reportScheduleId) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = cancelReportScheduleValidateBeforeCall(reportScheduleId, null, null);
          return apiClient.execute(call);
      }
  
      /**
       *  (asynchronously)
       * Cancels the report schedule that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportScheduleId The identifier for the report schedule. This identifier is unique only in combination with a seller ID. (required)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call cancelReportScheduleAsync(String reportScheduleId, final ApiCallback<Void> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = cancelReportScheduleValidateBeforeCall(reportScheduleId, progressListener, progressRequestListener);
          apiClient.executeAsync(call, callback);
          return call;
      }
      /**
       * Build call for createReport
       * @param body Information required to create the report. (required)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call createReportCall(CreateReportSpecification body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = body;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/reports";
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call createReportValidateBeforeCall(CreateReportSpecification body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
          // verify the required parameter 'body' is set
          if (body == null) {
              throw new ApiException("Missing the required parameter 'body' when calling createReport(Async)");
          }
          
  
          com.squareup.okhttp.Call call = createReportCall(body, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Creates a report.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0167 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param body Information required to create the report. (required)
       * @return CreateReportResponse
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public CreateReportResponse createReport(CreateReportSpecification body) throws ApiException,LWAException {
          ApiResponse<CreateReportResponse> resp = createReportWithHttpInfo(body);
          return resp.getData();
      }
  
      /**
       * Creates a report.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0167 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       *
       * @param body Information required to create the report. (required)
       * @return ApiResponse&lt;CreateReportResponse&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<CreateReportResponse> createReportWithHttpInfo(CreateReportSpecification body) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = createReportValidateBeforeCall(body, null, null);
          Type localVarReturnType = new TypeToken<CreateReportResponse>(){}.getType();
          return apiClient.execute(call, localVarReturnType);
      }
  
      /**
       *  (asynchronously)
       * Creates a report.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0167 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param body Information required to create the report. (required)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call createReportAsync(CreateReportSpecification body, final ApiCallback<CreateReportResponse> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = createReportValidateBeforeCall(body, progressListener, progressRequestListener);
          Type localVarReturnType = new TypeToken<CreateReportResponse>(){}.getType();
          apiClient.executeAsync(call, localVarReturnType, callback);
          return call;
      }
      /**
       * Build call for createReportSchedule
       * @param body Information required to create the report schedule. (required)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call createReportScheduleCall(CreateReportScheduleSpecification body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = body;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/schedules";
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call createReportScheduleValidateBeforeCall(CreateReportScheduleSpecification body, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
          // verify the required parameter 'body' is set
          if (body == null) {
              throw new ApiException("Missing the required parameter 'body' when calling createReportSchedule(Async)");
          }
          
  
          com.squareup.okhttp.Call call = createReportScheduleCall(body, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Creates a report schedule. If a report schedule with the same report type and marketplace IDs already exists, it will be cancelled and replaced with this one.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param body Information required to create the report schedule. (required)
       * @return CreateReportScheduleResponse
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public CreateReportScheduleResponse createReportSchedule(CreateReportScheduleSpecification body) throws ApiException,LWAException {
          ApiResponse<CreateReportScheduleResponse> resp = createReportScheduleWithHttpInfo(body);
          return resp.getData();
      }
  
      /**
       * 
       * Creates a report schedule. If a report schedule with the same report type and marketplace IDs already exists, it will be cancelled and replaced with this one.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param body Information required to create the report schedule. (required)
       * @return ApiResponse&lt;CreateReportScheduleResponse&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<CreateReportScheduleResponse> createReportScheduleWithHttpInfo(CreateReportScheduleSpecification body) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = createReportScheduleValidateBeforeCall(body, null, null);
          Type localVarReturnType = new TypeToken<CreateReportScheduleResponse>(){}.getType();
          return apiClient.execute(call, localVarReturnType);
      }
  
      /**
       *  (asynchronously)
       * Creates a report schedule. If a report schedule with the same report type and marketplace IDs already exists, it will be cancelled and replaced with this one.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param body Information required to create the report schedule. (required)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call createReportScheduleAsync(CreateReportScheduleSpecification body, final ApiCallback<CreateReportScheduleResponse> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = createReportScheduleValidateBeforeCall(body, progressListener, progressRequestListener);
          Type localVarReturnType = new TypeToken<CreateReportScheduleResponse>(){}.getType();
          apiClient.executeAsync(call, localVarReturnType, callback);
          return call;
      }
      /**
       * Build call for getReport
       * @param reportId The identifier for the report. This identifier is unique only in combination with a seller ID. (required)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportCall(String reportId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = null;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/reports/{reportId}"
              .replaceAll("\\{" + "reportId" + "\\}", apiClient.escapeString(reportId.toString()));
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call getReportValidateBeforeCall(String reportId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
          // verify the required parameter 'reportId' is set
          if (reportId == null) {
              throw new ApiException("Missing the required parameter 'reportId' when calling getReport(Async)");
          }
          
  
          com.squareup.okhttp.Call call = getReportCall(reportId, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Returns report details (including the &#x60;reportDocumentId&#x60;, if available) for the report that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportId The identifier for the report. This identifier is unique only in combination with a seller ID. (required)
       * @return Report
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public Report getReport(String reportId) throws ApiException,LWAException {
          ApiResponse<Report> resp = getReportWithHttpInfo(reportId);
          return resp.getData();
      }
  
      /**
       * 
       * Returns report details (including the &#x60;reportDocumentId&#x60;, if available) for the report that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportId The identifier for the report. This identifier is unique only in combination with a seller ID. (required)
       * @return ApiResponse&lt;Report&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<Report> getReportWithHttpInfo(String reportId) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = getReportValidateBeforeCall(reportId, null, null);
          Type localVarReturnType = new TypeToken<Report>(){}.getType();
          return apiClient.execute(call, localVarReturnType);
      }
  
      /**
       *  (asynchronously)
       * Returns report details (including the &#x60;reportDocumentId&#x60;, if available) for the report that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 2 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportId The identifier for the report. This identifier is unique only in combination with a seller ID. (required)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportAsync(String reportId, final ApiCallback<Report> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = getReportValidateBeforeCall(reportId, progressListener, progressRequestListener);
          Type localVarReturnType = new TypeToken<Report>(){}.getType();
          apiClient.executeAsync(call, localVarReturnType, callback);
          return call;
      }
      /**
       * Build call for getReportDocument
       * @param reportDocumentId The identifier for the report document. (required)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportDocumentCall(String reportDocumentId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = null;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/documents/{reportDocumentId}"
              .replaceAll("\\{" + "reportDocumentId" + "\\}", apiClient.escapeString(reportDocumentId.toString()));
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call getReportDocumentValidateBeforeCall(String reportDocumentId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
          // verify the required parameter 'reportDocumentId' is set
          if (reportDocumentId == null) {
              throw new ApiException("Missing the required parameter 'reportDocumentId' when calling getReportDocument(Async)");
          }
          
  
          com.squareup.okhttp.Call call = getReportDocumentCall(reportDocumentId, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Returns the information required for retrieving a report document&#39;s contents.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0167 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportDocumentId The identifier for the report document. (required)
       * @return ReportDocument
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ReportDocument getReportDocument(String reportDocumentId) throws ApiException,LWAException {
          ApiResponse<ReportDocument> resp = getReportDocumentWithHttpInfo(reportDocumentId);
          return resp.getData();
      }
  
      /**
       * 
       * Returns the information required for retrieving a report document&#39;s contents.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0167 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportDocumentId The identifier for the report document. (required)
       * @return ApiResponse&lt;ReportDocument&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<ReportDocument> getReportDocumentWithHttpInfo(String reportDocumentId) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = getReportDocumentValidateBeforeCall(reportDocumentId, null, null);
          Type localVarReturnType = new TypeToken<ReportDocument>(){}.getType();
          return apiClient.execute(call, localVarReturnType);
      }
  
      /**
       *  (asynchronously)
       * Returns the information required for retrieving a report document&#39;s contents.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0167 | 15 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportDocumentId The identifier for the report document. (required)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportDocumentAsync(String reportDocumentId, final ApiCallback<ReportDocument> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = getReportDocumentValidateBeforeCall(reportDocumentId, progressListener, progressRequestListener);
          Type localVarReturnType = new TypeToken<ReportDocument>(){}.getType();
          apiClient.executeAsync(call, localVarReturnType, callback);
          return call;
      }
      /**
       * Build call for getReportSchedule
       * @param reportScheduleId The identifier for the report schedule. This identifier is unique only in combination with a seller ID. (required)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportScheduleCall(String reportScheduleId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = null;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/schedules/{reportScheduleId}"
              .replaceAll("\\{" + "reportScheduleId" + "\\}", apiClient.escapeString(reportScheduleId.toString()));
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call getReportScheduleValidateBeforeCall(String reportScheduleId, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
          // verify the required parameter 'reportScheduleId' is set
          if (reportScheduleId == null) {
              throw new ApiException("Missing the required parameter 'reportScheduleId' when calling getReportSchedule(Async)");
          }
          
  
          com.squareup.okhttp.Call call = getReportScheduleCall(reportScheduleId, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Returns report schedule details for the report schedule that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportScheduleId The identifier for the report schedule. This identifier is unique only in combination with a seller ID. (required)
       * @return ReportSchedule
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ReportSchedule getReportSchedule(String reportScheduleId) throws ApiException,LWAException {
          ApiResponse<ReportSchedule> resp = getReportScheduleWithHttpInfo(reportScheduleId);
          return resp.getData();
      }
  
      /**
       * 
       * Returns report schedule details for the report schedule that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportScheduleId The identifier for the report schedule. This identifier is unique only in combination with a seller ID. (required)
       * @return ApiResponse&lt;ReportSchedule&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<ReportSchedule> getReportScheduleWithHttpInfo(String reportScheduleId) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = getReportScheduleValidateBeforeCall(reportScheduleId, null, null);
          Type localVarReturnType = new TypeToken<ReportSchedule>(){}.getType();
          return apiClient.execute(call, localVarReturnType);
      }
  
      /**
       *  (asynchronously)
       * Returns report schedule details for the report schedule that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportScheduleId The identifier for the report schedule. This identifier is unique only in combination with a seller ID. (required)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportScheduleAsync(String reportScheduleId, final ApiCallback<ReportSchedule> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = getReportScheduleValidateBeforeCall(reportScheduleId, progressListener, progressRequestListener);
          Type localVarReturnType = new TypeToken<ReportSchedule>(){}.getType();
          apiClient.executeAsync(call, localVarReturnType, callback);
          return call;
      }
      /**
       * Build call for getReportSchedules
       * @param reportTypes A list of report types used to filter report schedules. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. (required)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportSchedulesCall(List<String> reportTypes, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = null;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/schedules";
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
          if (reportTypes != null)
          localVarCollectionQueryParams.addAll(apiClient.parameterToPairs("csv", "reportTypes", reportTypes));
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call getReportSchedulesValidateBeforeCall(List<String> reportTypes, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
          // verify the required parameter 'reportTypes' is set
          if (reportTypes == null) {
              throw new ApiException("Missing the required parameter 'reportTypes' when calling getReportSchedules(Async)");
          }
          
  
          com.squareup.okhttp.Call call = getReportSchedulesCall(reportTypes, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Returns report schedule details that match the filters that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportTypes A list of report types used to filter report schedules. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. (required)
       * @return ReportScheduleList
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ReportScheduleList getReportSchedules(List<String> reportTypes) throws ApiException,LWAException {
          ApiResponse<ReportScheduleList> resp = getReportSchedulesWithHttpInfo(reportTypes);
          return resp.getData();
      }
  
      /**
       * 
       * Returns report schedule details that match the filters that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportTypes A list of report types used to filter report schedules. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. (required)
       * @return ApiResponse&lt;ReportScheduleList&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<ReportScheduleList> getReportSchedulesWithHttpInfo(List<String> reportTypes) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = getReportSchedulesValidateBeforeCall(reportTypes, null, null);
          Type localVarReturnType = new TypeToken<ReportScheduleList>(){}.getType();
          return apiClient.execute(call, localVarReturnType);
      }
  
      /**
       *  (asynchronously)
       * Returns report schedule details that match the filters that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportTypes A list of report types used to filter report schedules. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. (required)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportSchedulesAsync(List<String> reportTypes, final ApiCallback<ReportScheduleList> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = getReportSchedulesValidateBeforeCall(reportTypes, progressListener, progressRequestListener);
          Type localVarReturnType = new TypeToken<ReportScheduleList>(){}.getType();
          apiClient.executeAsync(call, localVarReturnType, callback);
          return call;
      }
      /**
       * Build call for getReports
       * @param reportTypes A list of report types used to filter reports. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. When reportTypes is provided, the other filter parameters (processingStatuses, marketplaceIds, createdSince, createdUntil) and pageSize may also be provided. Either reportTypes or nextToken is required. (optional)
       * @param processingStatuses A list of processing statuses used to filter reports. (optional)
       * @param marketplaceIds A list of marketplace identifiers used to filter reports. The reports returned will match at least one of the marketplaces that you specify. (optional)
       * @param pageSize The maximum number of reports to return in a single call. (optional, default to 10)
       * @param createdSince The earliest report creation date and time for reports to include in the response, in &lt;a href&#x3D;&#39;https://developer-docs.amazon.com/sp-api/docs/iso-8601&#39;&gt;ISO 8601&lt;/a&gt; date time format. The default is 90 days ago. Reports are retained for a maximum of 90 days. (optional)
       * @param createdUntil The latest report creation date and time for reports to include in the response, in &lt;a href&#x3D;&#39;https://developer-docs.amazon.com/sp-api/docs/iso-8601&#39;&gt;ISO 8601&lt;/a&gt; date time format. The default is now. (optional)
       * @param nextToken A string token returned in the response to your previous request. &#x60;nextToken&#x60; is returned when the number of results exceeds the specified &#x60;pageSize&#x60; value. To get the next page of results, call the &#x60;getReports&#x60; operation and include this token as the only parameter. Specifying &#x60;nextToken&#x60; with any other parameters will cause the request to fail. (optional)
       * @param progressListener Progress listener
       * @param progressRequestListener Progress request listener
       * @return Call to execute
       * @throws ApiException If fail to serialize the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportsCall(List<String> reportTypes, List<String> processingStatuses, List<String> marketplaceIds, Integer pageSize, OffsetDateTime createdSince, OffsetDateTime createdUntil, String nextToken, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          Object localVarPostBody = null;
  
          // create path and map variables
          String localVarPath = "/reports/2021-06-30/reports";
  
          List<Pair> localVarQueryParams = new ArrayList<Pair>();
          List<Pair> localVarCollectionQueryParams = new ArrayList<Pair>();
          if (reportTypes != null)
          localVarCollectionQueryParams.addAll(apiClient.parameterToPairs("csv", "reportTypes", reportTypes));
          if (processingStatuses != null)
          localVarCollectionQueryParams.addAll(apiClient.parameterToPairs("csv", "processingStatuses", processingStatuses));
          if (marketplaceIds != null)
          localVarCollectionQueryParams.addAll(apiClient.parameterToPairs("csv", "marketplaceIds", marketplaceIds));
          if (pageSize != null)
          localVarQueryParams.addAll(apiClient.parameterToPair("pageSize", pageSize));
          if (createdSince != null)
          localVarQueryParams.addAll(apiClient.parameterToPair("createdSince", createdSince));
          if (createdUntil != null)
          localVarQueryParams.addAll(apiClient.parameterToPair("createdUntil", createdUntil));
          if (nextToken != null)
          localVarQueryParams.addAll(apiClient.parameterToPair("nextToken", nextToken));
  
          Map<String, String> localVarHeaderParams = new HashMap<String, String>();
  
          Map<String, Object> localVarFormParams = new HashMap<String, Object>();
  
          final String[] localVarAccepts = {
              "application/json"
          };
          final String localVarAccept = apiClient.selectHeaderAccept(localVarAccepts);
          if (localVarAccept != null) localVarHeaderParams.put("Accept", localVarAccept);
  
          final String[] localVarContentTypes = {
              "application/json"
          };
          final String localVarContentType = apiClient.selectHeaderContentType(localVarContentTypes);
          localVarHeaderParams.put("Content-Type", localVarContentType);
  
          if(progressListener != null) {
              apiClient.getHttpClient().networkInterceptors().add(new com.squareup.okhttp.Interceptor() {
                  @Override
                  public com.squareup.okhttp.Response intercept(com.squareup.okhttp.Interceptor.Chain chain) throws IOException {
                      com.squareup.okhttp.Response originalResponse = chain.proceed(chain.request());
                      return originalResponse.newBuilder()
                      .body(new ProgressResponseBody(originalResponse.body(), progressListener))
                      .build();
                  }
              });
          }
  
          String[] localVarAuthNames = new String[] {  };
          return apiClient.buildCall(localVarPath, "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarAuthNames, progressRequestListener);
      }
  
      @SuppressWarnings("rawtypes")
      private com.squareup.okhttp.Call getReportsValidateBeforeCall(List<String> reportTypes, List<String> processingStatuses, List<String> marketplaceIds, Integer pageSize, OffsetDateTime createdSince, OffsetDateTime createdUntil, String nextToken, final ProgressResponseBody.ProgressListener progressListener, final ProgressRequestBody.ProgressRequestListener progressRequestListener) throws ApiException, LWAException {
          
  
          com.squareup.okhttp.Call call = getReportsCall(reportTypes, processingStatuses, marketplaceIds, pageSize, createdSince, createdUntil, nextToken, progressListener, progressRequestListener);
          return call;
  
      }
  
      /**
       * 
       * Returns report details for the reports that match the filters that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportTypes A list of report types used to filter reports. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. When reportTypes is provided, the other filter parameters (processingStatuses, marketplaceIds, createdSince, createdUntil) and pageSize may also be provided. Either reportTypes or nextToken is required. (optional)
       * @param processingStatuses A list of processing statuses used to filter reports. (optional)
       * @param marketplaceIds A list of marketplace identifiers used to filter reports. The reports returned will match at least one of the marketplaces that you specify. (optional)
       * @param pageSize The maximum number of reports to return in a single call. (optional, default to 10)
       * @param createdSince The earliest report creation date and time for reports to include in the response, in &lt;a href&#x3D;&#39;https://developer-docs.amazon.com/sp-api/docs/iso-8601&#39;&gt;ISO 8601&lt;/a&gt; date time format. The default is 90 days ago. Reports are retained for a maximum of 90 days. (optional)
       * @param createdUntil The latest report creation date and time for reports to include in the response, in &lt;a href&#x3D;&#39;https://developer-docs.amazon.com/sp-api/docs/iso-8601&#39;&gt;ISO 8601&lt;/a&gt; date time format. The default is now. (optional)
       * @param nextToken A string token returned in the response to your previous request. &#x60;nextToken&#x60; is returned when the number of results exceeds the specified &#x60;pageSize&#x60; value. To get the next page of results, call the &#x60;getReports&#x60; operation and include this token as the only parameter. Specifying &#x60;nextToken&#x60; with any other parameters will cause the request to fail. (optional)
       * @return GetReportsResponse
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public GetReportsResponse getReports(List<String> reportTypes, List<String> processingStatuses, List<String> marketplaceIds, Integer pageSize, OffsetDateTime createdSince, OffsetDateTime createdUntil, String nextToken) throws ApiException,LWAException {
          ApiResponse<GetReportsResponse> resp = getReportsWithHttpInfo(reportTypes, processingStatuses, marketplaceIds, pageSize, createdSince, createdUntil, nextToken);
          return resp.getData();
      }
  
      /**
       * 
       * Returns report details for the reports that match the filters that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportTypes A list of report types used to filter reports. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. When reportTypes is provided, the other filter parameters (processingStatuses, marketplaceIds, createdSince, createdUntil) and pageSize may also be provided. Either reportTypes or nextToken is required. (optional)
       * @param processingStatuses A list of processing statuses used to filter reports. (optional)
       * @param marketplaceIds A list of marketplace identifiers used to filter reports. The reports returned will match at least one of the marketplaces that you specify. (optional)
       * @param pageSize The maximum number of reports to return in a single call. (optional, default to 10)
       * @param createdSince The earliest report creation date and time for reports to include in the response, in &lt;a href&#x3D;&#39;https://developer-docs.amazon.com/sp-api/docs/iso-8601&#39;&gt;ISO 8601&lt;/a&gt; date time format. The default is 90 days ago. Reports are retained for a maximum of 90 days. (optional)
       * @param createdUntil The latest report creation date and time for reports to include in the response, in &lt;a href&#x3D;&#39;https://developer-docs.amazon.com/sp-api/docs/iso-8601&#39;&gt;ISO 8601&lt;/a&gt; date time format. The default is now. (optional)
       * @param nextToken A string token returned in the response to your previous request. &#x60;nextToken&#x60; is returned when the number of results exceeds the specified &#x60;pageSize&#x60; value. To get the next page of results, call the &#x60;getReports&#x60; operation and include this token as the only parameter. Specifying &#x60;nextToken&#x60; with any other parameters will cause the request to fail. (optional)
       * @return ApiResponse&lt;GetReportsResponse&gt;
       * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public ApiResponse<GetReportsResponse> getReportsWithHttpInfo(List<String> reportTypes, List<String> processingStatuses, List<String> marketplaceIds, Integer pageSize, OffsetDateTime createdSince, OffsetDateTime createdUntil, String nextToken) throws ApiException,LWAException {
          com.squareup.okhttp.Call call = getReportsValidateBeforeCall(reportTypes, processingStatuses, marketplaceIds, pageSize, createdSince, createdUntil, nextToken, null, null);
          Type localVarReturnType = new TypeToken<GetReportsResponse>(){}.getType();
          return apiClient.execute(call, localVarReturnType);
      }
  
      /**
       *  (asynchronously)
       * Returns report details for the reports that match the filters that you specify.  **Usage Plan:**  | Rate (requests per second) | Burst | | ---- | ---- | | 0.0222 | 10 |  The &#x60;x-amzn-RateLimit-Limit&#x60; response header returns the usage plan rate limits that were applied to the requested operation, when available. The table above indicates the default rate and burst values for this operation. Selling partners whose business demands require higher throughput may see higher rate and burst values than those shown here. For more information, refer to [Usage Plans and Rate Limits in the Selling Partner API](https://developer-docs.amazon.com/sp-api/docs/usage-plans-and-rate-limits-in-the-sp-api).
       * @param reportTypes A list of report types used to filter reports. Refer to [Report Type Values](https://developer-docs.amazon.com/sp-api/docs/report-type-values) for more information. When reportTypes is provided, the other filter parameters (processingStatuses, marketplaceIds, createdSince, createdUntil) and pageSize may also be provided. Either reportTypes or nextToken is required. (optional)
       * @param processingStatuses A list of processing statuses used to filter reports. (optional)
       * @param marketplaceIds A list of marketplace identifiers used to filter reports. The reports returned will match at least one of the marketplaces that you specify. (optional)
       * @param pageSize The maximum number of reports to return in a single call. (optional, default to 10)
       * @param createdSince The earliest report creation date and time for reports to include in the response, in &lt;a href&#x3D;&#39;https://developer-docs.amazon.com/sp-api/docs/iso-8601&#39;&gt;ISO 8601&lt;/a&gt; date time format. The default is 90 days ago. Reports are retained for a maximum of 90 days. (optional)
       * @param createdUntil The latest report creation date and time for reports to include in the response, in &lt;a href&#x3D;&#39;https://developer-docs.amazon.com/sp-api/docs/iso-8601&#39;&gt;ISO 8601&lt;/a&gt; date time format. The default is now. (optional)
       * @param nextToken A string token returned in the response to your previous request. &#x60;nextToken&#x60; is returned when the number of results exceeds the specified &#x60;pageSize&#x60; value. To get the next page of results, call the &#x60;getReports&#x60; operation and include this token as the only parameter. Specifying &#x60;nextToken&#x60; with any other parameters will cause the request to fail. (optional)
       * @param callback The callback to be executed when the API call finishes
       * @return The request call
       * @throws ApiException If fail to process the API call, e.g. serializing the request body object
       * @throws LWAException If calls to fetch LWA access token fails
       */
      public com.squareup.okhttp.Call getReportsAsync(List<String> reportTypes, List<String> processingStatuses, List<String> marketplaceIds, Integer pageSize, OffsetDateTime createdSince, OffsetDateTime createdUntil, String nextToken, final ApiCallback<GetReportsResponse> callback) throws ApiException, LWAException {
  
          ProgressResponseBody.ProgressListener progressListener = null;
          ProgressRequestBody.ProgressRequestListener progressRequestListener = null;
  
          if (callback != null) {
              progressListener = new ProgressResponseBody.ProgressListener() {
                  @Override
                  public void update(long bytesRead, long contentLength, boolean done) {
                      callback.onDownloadProgress(bytesRead, contentLength, done);
                  }
              };
  
              progressRequestListener = new ProgressRequestBody.ProgressRequestListener() {
                  @Override
                  public void onRequestProgress(long bytesWritten, long contentLength, boolean done) {
                      callback.onUploadProgress(bytesWritten, contentLength, done);
                  }
              };
          }
  
          com.squareup.okhttp.Call call = getReportsValidateBeforeCall(reportTypes, processingStatuses, marketplaceIds, pageSize, createdSince, createdUntil, nextToken, progressListener, progressRequestListener);
          Type localVarReturnType = new TypeToken<GetReportsResponse>(){}.getType();
          apiClient.executeAsync(call, localVarReturnType, callback);
          return call;
      }
  
      public static class Builder {
          private LWAAuthorizationCredentials lwaAuthorizationCredentials;
          private String endpoint;
          private LWAAccessTokenCache lwaAccessTokenCache;
          private Boolean disableAccessTokenCache = false;
          private RateLimitConfiguration rateLimitConfiguration;
  
  
          public Builder lwaAuthorizationCredentials(LWAAuthorizationCredentials lwaAuthorizationCredentials) {
              this.lwaAuthorizationCredentials = lwaAuthorizationCredentials;
              return this;
          }
  
          public Builder endpoint(String endpoint) {
              this.endpoint = endpoint;
              return this;
          }
          
          public Builder lwaAccessTokenCache(LWAAccessTokenCache lwaAccessTokenCache) {
              this.lwaAccessTokenCache = lwaAccessTokenCache;
              return this;
          }
  		
  	   public Builder disableAccessTokenCache() {
              this.disableAccessTokenCache = true;
              return this;
          }
  
          public Builder rateLimitConfigurationOnRequests(RateLimitConfiguration rateLimitConfiguration){
              this.rateLimitConfiguration = rateLimitConfiguration;
              return this;
          }
          
          public Builder disableRateLimitOnRequests() {
              this.rateLimitConfiguration = null;
              return this;
          }
  
          public ReportsApi build() {
              if (lwaAuthorizationCredentials == null) {
                  throw new RuntimeException("LWAAuthorizationCredentials not set");
              }
  
              if (StringUtil.isEmpty(endpoint)) {
                  throw new RuntimeException("Endpoint not set");
              }
              
              LWAAuthorizationSigner lwaAuthorizationSigner = null;            
              if (disableAccessTokenCache) {
                  lwaAuthorizationSigner = new LWAAuthorizationSigner(lwaAuthorizationCredentials);
              }
              else {
                  if (lwaAccessTokenCache == null) {
                      lwaAccessTokenCache = new LWAAccessTokenCacheImpl();                  
                   }
                   lwaAuthorizationSigner = new LWAAuthorizationSigner(lwaAuthorizationCredentials,lwaAccessTokenCache);
              }
  
              return new ReportsApi(new ApiClient()
                  .setLWAAuthorizationSigner(lwaAuthorizationSigner)
                  .setBasePath(endpoint)
                  .setRateLimiter(rateLimitConfiguration));
          }
      }
  }
  