Explorar o código

Prettier - include autogenerated files

Leszek Wiesner %!s(int64=3) %!d(string=hai) anos
pai
achega
623562fb08

+ 0 - 1
distributor-node/.prettierignore

@@ -1,4 +1,3 @@
-/**/generated
 /**/mock.graphql
 lib
 local

+ 4 - 4
distributor-node/src/services/networking/query-node/codegen.yml

@@ -16,8 +16,8 @@ generates:
   src/services/networking/query-node/generated/schema.ts:
     hooks:
       afterOneFileWrite:
-        - prettier --write
-        - eslint --fix
+        - yarn prettier --write
+        - yarn eslint --fix
     plugins:
       - typescript
   src/services/networking/query-node/generated/queries.ts:
@@ -26,8 +26,8 @@ generates:
       typesPath: ./schema
     hooks:
       afterOneFileWrite:
-        - prettier --write
-        - eslint --fix
+        - yarn prettier --write
+        - yarn eslint --fix
     plugins:
       - typescript-operations
       - typescript-document-nodes

A diferenza do arquivo foi suprimida porque é demasiado grande
+ 481 - 478
distributor-node/src/services/networking/query-node/generated/schema.ts


+ 676 - 626
distributor-node/src/services/networking/storage-node/generated/api.ts

@@ -12,165 +12,175 @@
  * Do not edit the class manually.
  */
 
-
-import { Configuration } from './configuration';
-import globalAxios, { AxiosPromise, AxiosInstance } from 'axios';
+import { Configuration } from './configuration'
+import globalAxios, { AxiosPromise, AxiosInstance } from 'axios'
 // Some imports not used depending on template conditions
 // @ts-ignore
-import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common';
+import {
+  DUMMY_BASE_URL,
+  assertParamExists,
+  setApiKeyToObject,
+  setBasicAuthToObject,
+  setBearerAuthToObject,
+  setOAuthToObject,
+  setSearchParams,
+  serializeDataIfNeeded,
+  toPathString,
+  createRequestFunction,
+} from './common'
 // @ts-ignore
-import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base';
+import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError } from './base'
 
 /**
- * 
+ *
  * @export
  * @interface DataStatsResponse
  */
 export interface DataStatsResponse {
-    /**
-     * 
-     * @type {number}
-     * @memberof DataStatsResponse
-     */
-    totalSize: number;
-    /**
-     * 
-     * @type {number}
-     * @memberof DataStatsResponse
-     */
-    objectNumber: number;
-    /**
-     * 
-     * @type {number}
-     * @memberof DataStatsResponse
-     */
-    tempDirSize?: number;
-    /**
-     * 
-     * @type {number}
-     * @memberof DataStatsResponse
-     */
-    tempDownloads?: number;
+  /**
+   *
+   * @type {number}
+   * @memberof DataStatsResponse
+   */
+  totalSize: number
+  /**
+   *
+   * @type {number}
+   * @memberof DataStatsResponse
+   */
+  objectNumber: number
+  /**
+   *
+   * @type {number}
+   * @memberof DataStatsResponse
+   */
+  tempDirSize?: number
+  /**
+   *
+   * @type {number}
+   * @memberof DataStatsResponse
+   */
+  tempDownloads?: number
 }
 /**
- * 
+ *
  * @export
  * @interface ErrorResponse
  */
 export interface ErrorResponse {
-    /**
-     * 
-     * @type {string}
-     * @memberof ErrorResponse
-     */
-    type?: string;
-    /**
-     * 
-     * @type {string}
-     * @memberof ErrorResponse
-     */
-    message: string;
+  /**
+   *
+   * @type {string}
+   * @memberof ErrorResponse
+   */
+  type?: string
+  /**
+   *
+   * @type {string}
+   * @memberof ErrorResponse
+   */
+  message: string
 }
 /**
- * 
+ *
  * @export
  * @interface InlineResponse201
  */
 export interface InlineResponse201 {
-    /**
-     * 
-     * @type {string}
-     * @memberof InlineResponse201
-     */
-    id?: string;
+  /**
+   *
+   * @type {string}
+   * @memberof InlineResponse201
+   */
+  id?: string
 }
 /**
- * 
+ *
  * @export
  * @interface InlineResponse2011
  */
 export interface InlineResponse2011 {
-    /**
-     * 
-     * @type {string}
-     * @memberof InlineResponse2011
-     */
-    token?: string;
+  /**
+   *
+   * @type {string}
+   * @memberof InlineResponse2011
+   */
+  token?: string
 }
 /**
- * 
+ *
  * @export
  * @interface TokenRequest
  */
 export interface TokenRequest {
-    /**
-     * 
-     * @type {TokenRequestData}
-     * @memberof TokenRequest
-     */
-    data: TokenRequestData;
-    /**
-     * 
-     * @type {string}
-     * @memberof TokenRequest
-     */
-    signature: string;
+  /**
+   *
+   * @type {TokenRequestData}
+   * @memberof TokenRequest
+   */
+  data: TokenRequestData
+  /**
+   *
+   * @type {string}
+   * @memberof TokenRequest
+   */
+  signature: string
 }
 /**
- * 
+ *
  * @export
  * @interface TokenRequestData
  */
 export interface TokenRequestData {
-    /**
-     * 
-     * @type {number}
-     * @memberof TokenRequestData
-     */
-    memberId: number;
-    /**
-     * 
-     * @type {string}
-     * @memberof TokenRequestData
-     */
-    accountId: string;
-    /**
-     * 
-     * @type {number}
-     * @memberof TokenRequestData
-     */
-    dataObjectId: number;
-    /**
-     * 
-     * @type {number}
-     * @memberof TokenRequestData
-     */
-    storageBucketId: number;
-    /**
-     * 
-     * @type {string}
-     * @memberof TokenRequestData
-     */
-    bagId: string;
+  /**
+   *
+   * @type {number}
+   * @memberof TokenRequestData
+   */
+  memberId: number
+  /**
+   *
+   * @type {string}
+   * @memberof TokenRequestData
+   */
+  accountId: string
+  /**
+   *
+   * @type {number}
+   * @memberof TokenRequestData
+   */
+  dataObjectId: number
+  /**
+   *
+   * @type {number}
+   * @memberof TokenRequestData
+   */
+  storageBucketId: number
+  /**
+   *
+   * @type {string}
+   * @memberof TokenRequestData
+   */
+  bagId: string
 }
 /**
- * 
+ *
  * @export
  * @interface VersionResponse
  */
 export interface VersionResponse {
-    /**
-     * 
-     * @type {string}
-     * @memberof VersionResponse
-     */
-    version: string;
-    /**
-     * 
-     * @type {string}
-     * @memberof VersionResponse
-     */
-    userAgent?: string;
+  /**
+   *
+   * @type {string}
+   * @memberof VersionResponse
+   */
+  version: string
+  /**
+   *
+   * @type {string}
+   * @memberof VersionResponse
+   */
+  userAgent?: string
 }
 
 /**
@@ -178,313 +188,277 @@ export interface VersionResponse {
  * @export
  */
 export const FilesApiAxiosParamCreator = function (configuration?: Configuration) {
-    return {
-        /**
-         * Get auth token from a server.
-         * @param {TokenRequest} [tokenRequest] Token request parameters,
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        publicApiAuthTokenForUploading: async (tokenRequest?: TokenRequest, options: any = {}): Promise<RequestArgs> => {
-            const localVarPath = `/authToken`;
-            // use dummy base URL string because the URL constructor only accepts absolute URLs.
-            const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
-            let baseOptions;
-            if (configuration) {
-                baseOptions = configuration.baseOptions;
-            }
-
-            const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
-            const localVarHeaderParameter = {} as any;
-            const localVarQueryParameter = {} as any;
-
-
-    
-            localVarHeaderParameter['Content-Type'] = 'application/json';
-
-            setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
-            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
-            localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
-            localVarRequestOptions.data = serializeDataIfNeeded(tokenRequest, localVarRequestOptions, configuration)
-
-            return {
-                url: toPathString(localVarUrlObj),
-                options: localVarRequestOptions,
-            };
-        },
-        /**
-         * Returns a media file.
-         * @param {string} id Data object ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        publicApiGetFile: async (id: string, options: any = {}): Promise<RequestArgs> => {
-            // verify required parameter 'id' is not null or undefined
-            assertParamExists('publicApiGetFile', 'id', id)
-            const localVarPath = `/files/{id}`
-                .replace(`{${"id"}}`, encodeURIComponent(String(id)));
-            // use dummy base URL string because the URL constructor only accepts absolute URLs.
-            const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
-            let baseOptions;
-            if (configuration) {
-                baseOptions = configuration.baseOptions;
-            }
-
-            const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
-            const localVarHeaderParameter = {} as any;
-            const localVarQueryParameter = {} as any;
-
-
-    
-            setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
-            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
-            localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
-
-            return {
-                url: toPathString(localVarUrlObj),
-                options: localVarRequestOptions,
-            };
-        },
-        /**
-         * Returns a media file headers.
-         * @param {string} id Data object ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        publicApiGetFileHeaders: async (id: string, options: any = {}): Promise<RequestArgs> => {
-            // verify required parameter 'id' is not null or undefined
-            assertParamExists('publicApiGetFileHeaders', 'id', id)
-            const localVarPath = `/files/{id}`
-                .replace(`{${"id"}}`, encodeURIComponent(String(id)));
-            // use dummy base URL string because the URL constructor only accepts absolute URLs.
-            const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
-            let baseOptions;
-            if (configuration) {
-                baseOptions = configuration.baseOptions;
-            }
-
-            const localVarRequestOptions = { method: 'HEAD', ...baseOptions, ...options};
-            const localVarHeaderParameter = {} as any;
-            const localVarQueryParameter = {} as any;
-
-
-    
-            setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
-            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
-            localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
-
-            return {
-                url: toPathString(localVarUrlObj),
-                options: localVarRequestOptions,
-            };
-        },
-        /**
-         * Upload data
-         * @param {string} dataObjectId Data object runtime ID
-         * @param {string} storageBucketId Storage bucket ID
-         * @param {string} bagId Bag ID
-         * @param {any} [file] Data file
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        publicApiUploadFile: async (dataObjectId: string, storageBucketId: string, bagId: string, file?: any, options: any = {}): Promise<RequestArgs> => {
-            // verify required parameter 'dataObjectId' is not null or undefined
-            assertParamExists('publicApiUploadFile', 'dataObjectId', dataObjectId)
-            // verify required parameter 'storageBucketId' is not null or undefined
-            assertParamExists('publicApiUploadFile', 'storageBucketId', storageBucketId)
-            // verify required parameter 'bagId' is not null or undefined
-            assertParamExists('publicApiUploadFile', 'bagId', bagId)
-            const localVarPath = `/files`;
-            // use dummy base URL string because the URL constructor only accepts absolute URLs.
-            const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
-            let baseOptions;
-            if (configuration) {
-                baseOptions = configuration.baseOptions;
-            }
-
-            const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
-            const localVarHeaderParameter = {} as any;
-            const localVarQueryParameter = {} as any;
-            const localVarFormParams = new ((configuration && configuration.formDataCtor) || FormData)();
-
-            // authentication UploadAuth required
-            await setApiKeyToObject(localVarHeaderParameter, "x-api-key", configuration)
-
-
-            if (file !== undefined) { 
-                localVarFormParams.append('file', file as any);
-            }
-    
-            if (dataObjectId !== undefined) { 
-                localVarFormParams.append('dataObjectId', dataObjectId as any);
-            }
-    
-            if (storageBucketId !== undefined) { 
-                localVarFormParams.append('storageBucketId', storageBucketId as any);
-            }
-    
-            if (bagId !== undefined) { 
-                localVarFormParams.append('bagId', bagId as any);
-            }
-    
-    
-            localVarHeaderParameter['Content-Type'] = 'multipart/form-data';
-    
-            setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
-            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
-            localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
-            localVarRequestOptions.data = localVarFormParams;
-
-            return {
-                url: toPathString(localVarUrlObj),
-                options: localVarRequestOptions,
-            };
-        },
-    }
-};
+  return {
+    /**
+     * Get auth token from a server.
+     * @param {TokenRequest} [tokenRequest] Token request parameters,
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    publicApiAuthTokenForUploading: async (tokenRequest?: TokenRequest, options: any = {}): Promise<RequestArgs> => {
+      const localVarPath = `/authToken`
+      // use dummy base URL string because the URL constructor only accepts absolute URLs.
+      const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
+      let baseOptions
+      if (configuration) {
+        baseOptions = configuration.baseOptions
+      }
+
+      const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options }
+      const localVarHeaderParameter = {} as any
+      const localVarQueryParameter = {} as any
+
+      localVarHeaderParameter['Content-Type'] = 'application/json'
+
+      setSearchParams(localVarUrlObj, localVarQueryParameter, options.query)
+      let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
+      localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
+      localVarRequestOptions.data = serializeDataIfNeeded(tokenRequest, localVarRequestOptions, configuration)
+
+      return {
+        url: toPathString(localVarUrlObj),
+        options: localVarRequestOptions,
+      }
+    },
+    /**
+     * Returns a media file.
+     * @param {string} id Data object ID
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    publicApiGetFile: async (id: string, options: any = {}): Promise<RequestArgs> => {
+      // verify required parameter 'id' is not null or undefined
+      assertParamExists('publicApiGetFile', 'id', id)
+      const localVarPath = `/files/{id}`.replace(`{${'id'}}`, encodeURIComponent(String(id)))
+      // use dummy base URL string because the URL constructor only accepts absolute URLs.
+      const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
+      let baseOptions
+      if (configuration) {
+        baseOptions = configuration.baseOptions
+      }
+
+      const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }
+      const localVarHeaderParameter = {} as any
+      const localVarQueryParameter = {} as any
+
+      setSearchParams(localVarUrlObj, localVarQueryParameter, options.query)
+      let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
+      localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
+
+      return {
+        url: toPathString(localVarUrlObj),
+        options: localVarRequestOptions,
+      }
+    },
+    /**
+     * Returns a media file headers.
+     * @param {string} id Data object ID
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    publicApiGetFileHeaders: async (id: string, options: any = {}): Promise<RequestArgs> => {
+      // verify required parameter 'id' is not null or undefined
+      assertParamExists('publicApiGetFileHeaders', 'id', id)
+      const localVarPath = `/files/{id}`.replace(`{${'id'}}`, encodeURIComponent(String(id)))
+      // use dummy base URL string because the URL constructor only accepts absolute URLs.
+      const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
+      let baseOptions
+      if (configuration) {
+        baseOptions = configuration.baseOptions
+      }
+
+      const localVarRequestOptions = { method: 'HEAD', ...baseOptions, ...options }
+      const localVarHeaderParameter = {} as any
+      const localVarQueryParameter = {} as any
+
+      setSearchParams(localVarUrlObj, localVarQueryParameter, options.query)
+      let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
+      localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
+
+      return {
+        url: toPathString(localVarUrlObj),
+        options: localVarRequestOptions,
+      }
+    },
+    /**
+     * Upload data
+     * @param {string} dataObjectId Data object runtime ID
+     * @param {string} storageBucketId Storage bucket ID
+     * @param {string} bagId Bag ID
+     * @param {any} [file] Data file
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    publicApiUploadFile: async (
+      dataObjectId: string,
+      storageBucketId: string,
+      bagId: string,
+      file?: any,
+      options: any = {}
+    ): Promise<RequestArgs> => {
+      // verify required parameter 'dataObjectId' is not null or undefined
+      assertParamExists('publicApiUploadFile', 'dataObjectId', dataObjectId)
+      // verify required parameter 'storageBucketId' is not null or undefined
+      assertParamExists('publicApiUploadFile', 'storageBucketId', storageBucketId)
+      // verify required parameter 'bagId' is not null or undefined
+      assertParamExists('publicApiUploadFile', 'bagId', bagId)
+      const localVarPath = `/files`
+      // use dummy base URL string because the URL constructor only accepts absolute URLs.
+      const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
+      let baseOptions
+      if (configuration) {
+        baseOptions = configuration.baseOptions
+      }
+
+      const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options }
+      const localVarHeaderParameter = {} as any
+      const localVarQueryParameter = {} as any
+      const localVarFormParams = new ((configuration && configuration.formDataCtor) || FormData)()
+
+      // authentication UploadAuth required
+      await setApiKeyToObject(localVarHeaderParameter, 'x-api-key', configuration)
+
+      if (file !== undefined) {
+        localVarFormParams.append('file', file as any)
+      }
+
+      if (dataObjectId !== undefined) {
+        localVarFormParams.append('dataObjectId', dataObjectId as any)
+      }
+
+      if (storageBucketId !== undefined) {
+        localVarFormParams.append('storageBucketId', storageBucketId as any)
+      }
+
+      if (bagId !== undefined) {
+        localVarFormParams.append('bagId', bagId as any)
+      }
+
+      localVarHeaderParameter['Content-Type'] = 'multipart/form-data'
+
+      setSearchParams(localVarUrlObj, localVarQueryParameter, options.query)
+      let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
+      localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
+      localVarRequestOptions.data = localVarFormParams
+
+      return {
+        url: toPathString(localVarUrlObj),
+        options: localVarRequestOptions,
+      }
+    },
+  }
+}
 
 /**
  * FilesApi - functional programming interface
  * @export
  */
-export const FilesApiFp = function(configuration?: Configuration) {
-    const localVarAxiosParamCreator = FilesApiAxiosParamCreator(configuration)
-    return {
-        /**
-         * Get auth token from a server.
-         * @param {TokenRequest} [tokenRequest] Token request parameters,
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        async publicApiAuthTokenForUploading(tokenRequest?: TokenRequest, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2011>> {
-            const localVarAxiosArgs = await localVarAxiosParamCreator.publicApiAuthTokenForUploading(tokenRequest, options);
-            return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
-        },
-        /**
-         * Returns a media file.
-         * @param {string} id Data object ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        async publicApiGetFile(id: string, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
-            const localVarAxiosArgs = await localVarAxiosParamCreator.publicApiGetFile(id, options);
-            return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
-        },
-        /**
-         * Returns a media file headers.
-         * @param {string} id Data object ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        async publicApiGetFileHeaders(id: string, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
-            const localVarAxiosArgs = await localVarAxiosParamCreator.publicApiGetFileHeaders(id, options);
-            return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
-        },
-        /**
-         * Upload data
-         * @param {string} dataObjectId Data object runtime ID
-         * @param {string} storageBucketId Storage bucket ID
-         * @param {string} bagId Bag ID
-         * @param {any} [file] Data file
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        async publicApiUploadFile(dataObjectId: string, storageBucketId: string, bagId: string, file?: any, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse201>> {
-            const localVarAxiosArgs = await localVarAxiosParamCreator.publicApiUploadFile(dataObjectId, storageBucketId, bagId, file, options);
-            return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
-        },
-    }
-};
+export const FilesApiFp = function (configuration?: Configuration) {
+  const localVarAxiosParamCreator = FilesApiAxiosParamCreator(configuration)
+  return {
+    /**
+     * Get auth token from a server.
+     * @param {TokenRequest} [tokenRequest] Token request parameters,
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    async publicApiAuthTokenForUploading(
+      tokenRequest?: TokenRequest,
+      options?: any
+    ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2011>> {
+      const localVarAxiosArgs = await localVarAxiosParamCreator.publicApiAuthTokenForUploading(tokenRequest, options)
+      return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)
+    },
+    /**
+     * Returns a media file.
+     * @param {string} id Data object ID
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    async publicApiGetFile(
+      id: string,
+      options?: any
+    ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<any>> {
+      const localVarAxiosArgs = await localVarAxiosParamCreator.publicApiGetFile(id, options)
+      return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)
+    },
+    /**
+     * Returns a media file headers.
+     * @param {string} id Data object ID
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    async publicApiGetFileHeaders(
+      id: string,
+      options?: any
+    ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
+      const localVarAxiosArgs = await localVarAxiosParamCreator.publicApiGetFileHeaders(id, options)
+      return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)
+    },
+    /**
+     * Upload data
+     * @param {string} dataObjectId Data object runtime ID
+     * @param {string} storageBucketId Storage bucket ID
+     * @param {string} bagId Bag ID
+     * @param {any} [file] Data file
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    async publicApiUploadFile(
+      dataObjectId: string,
+      storageBucketId: string,
+      bagId: string,
+      file?: any,
+      options?: any
+    ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse201>> {
+      const localVarAxiosArgs = await localVarAxiosParamCreator.publicApiUploadFile(
+        dataObjectId,
+        storageBucketId,
+        bagId,
+        file,
+        options
+      )
+      return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)
+    },
+  }
+}
 
 /**
  * FilesApi - factory interface
  * @export
  */
 export const FilesApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
-    const localVarFp = FilesApiFp(configuration)
-    return {
-        /**
-         * Get auth token from a server.
-         * @param {TokenRequest} [tokenRequest] Token request parameters,
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        publicApiAuthTokenForUploading(tokenRequest?: TokenRequest, options?: any): AxiosPromise<InlineResponse2011> {
-            return localVarFp.publicApiAuthTokenForUploading(tokenRequest, options).then((request) => request(axios, basePath));
-        },
-        /**
-         * Returns a media file.
-         * @param {string} id Data object ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        publicApiGetFile(id: string, options?: any): AxiosPromise<any> {
-            return localVarFp.publicApiGetFile(id, options).then((request) => request(axios, basePath));
-        },
-        /**
-         * Returns a media file headers.
-         * @param {string} id Data object ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        publicApiGetFileHeaders(id: string, options?: any): AxiosPromise<void> {
-            return localVarFp.publicApiGetFileHeaders(id, options).then((request) => request(axios, basePath));
-        },
-        /**
-         * Upload data
-         * @param {string} dataObjectId Data object runtime ID
-         * @param {string} storageBucketId Storage bucket ID
-         * @param {string} bagId Bag ID
-         * @param {any} [file] Data file
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        publicApiUploadFile(dataObjectId: string, storageBucketId: string, bagId: string, file?: any, options?: any): AxiosPromise<InlineResponse201> {
-            return localVarFp.publicApiUploadFile(dataObjectId, storageBucketId, bagId, file, options).then((request) => request(axios, basePath));
-        },
-    };
-};
-
-/**
- * FilesApi - object-oriented interface
- * @export
- * @class FilesApi
- * @extends {BaseAPI}
- */
-export class FilesApi extends BaseAPI {
+  const localVarFp = FilesApiFp(configuration)
+  return {
     /**
      * Get auth token from a server.
      * @param {TokenRequest} [tokenRequest] Token request parameters,
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
-     * @memberof FilesApi
      */
-    public publicApiAuthTokenForUploading(tokenRequest?: TokenRequest, options?: any) {
-        return FilesApiFp(this.configuration).publicApiAuthTokenForUploading(tokenRequest, options).then((request) => request(this.axios, this.basePath));
-    }
-
+    publicApiAuthTokenForUploading(tokenRequest?: TokenRequest, options?: any): AxiosPromise<InlineResponse2011> {
+      return localVarFp
+        .publicApiAuthTokenForUploading(tokenRequest, options)
+        .then((request) => request(axios, basePath))
+    },
     /**
      * Returns a media file.
      * @param {string} id Data object ID
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
-     * @memberof FilesApi
      */
-    public publicApiGetFile(id: string, options?: any) {
-        return FilesApiFp(this.configuration).publicApiGetFile(id, options).then((request) => request(this.axios, this.basePath));
-    }
-
+    publicApiGetFile(id: string, options?: any): AxiosPromise<any> {
+      return localVarFp.publicApiGetFile(id, options).then((request) => request(axios, basePath))
+    },
     /**
      * Returns a media file headers.
      * @param {string} id Data object ID
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
-     * @memberof FilesApi
      */
-    public publicApiGetFileHeaders(id: string, options?: any) {
-        return FilesApiFp(this.configuration).publicApiGetFileHeaders(id, options).then((request) => request(this.axios, this.basePath));
-    }
-
+    publicApiGetFileHeaders(id: string, options?: any): AxiosPromise<void> {
+      return localVarFp.publicApiGetFileHeaders(id, options).then((request) => request(axios, basePath))
+    },
     /**
      * Upload data
      * @param {string} dataObjectId Data object runtime ID
@@ -493,280 +467,356 @@ export class FilesApi extends BaseAPI {
      * @param {any} [file] Data file
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
-     * @memberof FilesApi
      */
-    public publicApiUploadFile(dataObjectId: string, storageBucketId: string, bagId: string, file?: any, options?: any) {
-        return FilesApiFp(this.configuration).publicApiUploadFile(dataObjectId, storageBucketId, bagId, file, options).then((request) => request(this.axios, this.basePath));
-    }
+    publicApiUploadFile(
+      dataObjectId: string,
+      storageBucketId: string,
+      bagId: string,
+      file?: any,
+      options?: any
+    ): AxiosPromise<InlineResponse201> {
+      return localVarFp
+        .publicApiUploadFile(dataObjectId, storageBucketId, bagId, file, options)
+        .then((request) => request(axios, basePath))
+    },
+  }
 }
 
+/**
+ * FilesApi - object-oriented interface
+ * @export
+ * @class FilesApi
+ * @extends {BaseAPI}
+ */
+export class FilesApi extends BaseAPI {
+  /**
+   * Get auth token from a server.
+   * @param {TokenRequest} [tokenRequest] Token request parameters,
+   * @param {*} [options] Override http request option.
+   * @throws {RequiredError}
+   * @memberof FilesApi
+   */
+  public publicApiAuthTokenForUploading(tokenRequest?: TokenRequest, options?: any) {
+    return FilesApiFp(this.configuration)
+      .publicApiAuthTokenForUploading(tokenRequest, options)
+      .then((request) => request(this.axios, this.basePath))
+  }
+
+  /**
+   * Returns a media file.
+   * @param {string} id Data object ID
+   * @param {*} [options] Override http request option.
+   * @throws {RequiredError}
+   * @memberof FilesApi
+   */
+  public publicApiGetFile(id: string, options?: any) {
+    return FilesApiFp(this.configuration)
+      .publicApiGetFile(id, options)
+      .then((request) => request(this.axios, this.basePath))
+  }
+
+  /**
+   * Returns a media file headers.
+   * @param {string} id Data object ID
+   * @param {*} [options] Override http request option.
+   * @throws {RequiredError}
+   * @memberof FilesApi
+   */
+  public publicApiGetFileHeaders(id: string, options?: any) {
+    return FilesApiFp(this.configuration)
+      .publicApiGetFileHeaders(id, options)
+      .then((request) => request(this.axios, this.basePath))
+  }
+
+  /**
+   * Upload data
+   * @param {string} dataObjectId Data object runtime ID
+   * @param {string} storageBucketId Storage bucket ID
+   * @param {string} bagId Bag ID
+   * @param {any} [file] Data file
+   * @param {*} [options] Override http request option.
+   * @throws {RequiredError}
+   * @memberof FilesApi
+   */
+  public publicApiUploadFile(dataObjectId: string, storageBucketId: string, bagId: string, file?: any, options?: any) {
+    return FilesApiFp(this.configuration)
+      .publicApiUploadFile(dataObjectId, storageBucketId, bagId, file, options)
+      .then((request) => request(this.axios, this.basePath))
+  }
+}
 
 /**
  * StateApi - axios parameter creator
  * @export
  */
 export const StateApiAxiosParamCreator = function (configuration?: Configuration) {
-    return {
-        /**
-         * Returns all local data objects.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        stateApiGetAllLocalDataObjects: async (options: any = {}): Promise<RequestArgs> => {
-            const localVarPath = `/state/data-objects`;
-            // use dummy base URL string because the URL constructor only accepts absolute URLs.
-            const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
-            let baseOptions;
-            if (configuration) {
-                baseOptions = configuration.baseOptions;
-            }
-
-            const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
-            const localVarHeaderParameter = {} as any;
-            const localVarQueryParameter = {} as any;
-
-
-    
-            setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
-            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
-            localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
-
-            return {
-                url: toPathString(localVarUrlObj),
-                options: localVarRequestOptions,
-            };
-        },
-        /**
-         * Returns local data objects for the bag.
-         * @param {string} bagId Bag ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        stateApiGetLocalDataObjectsByBagId: async (bagId: string, options: any = {}): Promise<RequestArgs> => {
-            // verify required parameter 'bagId' is not null or undefined
-            assertParamExists('stateApiGetLocalDataObjectsByBagId', 'bagId', bagId)
-            const localVarPath = `/state/bags/{bagId}/data-objects`
-                .replace(`{${"bagId"}}`, encodeURIComponent(String(bagId)));
-            // use dummy base URL string because the URL constructor only accepts absolute URLs.
-            const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
-            let baseOptions;
-            if (configuration) {
-                baseOptions = configuration.baseOptions;
-            }
-
-            const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
-            const localVarHeaderParameter = {} as any;
-            const localVarQueryParameter = {} as any;
-
-
-    
-            setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
-            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
-            localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
-
-            return {
-                url: toPathString(localVarUrlObj),
-                options: localVarRequestOptions,
-            };
-        },
-        /**
-         * Returns local uploading directory stats.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        stateApiGetLocalDataStats: async (options: any = {}): Promise<RequestArgs> => {
-            const localVarPath = `/state/data`;
-            // use dummy base URL string because the URL constructor only accepts absolute URLs.
-            const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
-            let baseOptions;
-            if (configuration) {
-                baseOptions = configuration.baseOptions;
-            }
-
-            const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
-            const localVarHeaderParameter = {} as any;
-            const localVarQueryParameter = {} as any;
-
-
-    
-            setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
-            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
-            localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
-
-            return {
-                url: toPathString(localVarUrlObj),
-                options: localVarRequestOptions,
-            };
-        },
-        /**
-         * Returns server version.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        stateApiGetVersion: async (options: any = {}): Promise<RequestArgs> => {
-            const localVarPath = `/version`;
-            // use dummy base URL string because the URL constructor only accepts absolute URLs.
-            const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
-            let baseOptions;
-            if (configuration) {
-                baseOptions = configuration.baseOptions;
-            }
-
-            const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
-            const localVarHeaderParameter = {} as any;
-            const localVarQueryParameter = {} as any;
-
-
-    
-            setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
-            let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
-            localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
-
-            return {
-                url: toPathString(localVarUrlObj),
-                options: localVarRequestOptions,
-            };
-        },
-    }
-};
+  return {
+    /**
+     * Returns all local data objects.
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    stateApiGetAllLocalDataObjects: async (options: any = {}): Promise<RequestArgs> => {
+      const localVarPath = `/state/data-objects`
+      // use dummy base URL string because the URL constructor only accepts absolute URLs.
+      const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
+      let baseOptions
+      if (configuration) {
+        baseOptions = configuration.baseOptions
+      }
+
+      const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }
+      const localVarHeaderParameter = {} as any
+      const localVarQueryParameter = {} as any
+
+      setSearchParams(localVarUrlObj, localVarQueryParameter, options.query)
+      let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
+      localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
+
+      return {
+        url: toPathString(localVarUrlObj),
+        options: localVarRequestOptions,
+      }
+    },
+    /**
+     * Returns local data objects for the bag.
+     * @param {string} bagId Bag ID
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    stateApiGetLocalDataObjectsByBagId: async (bagId: string, options: any = {}): Promise<RequestArgs> => {
+      // verify required parameter 'bagId' is not null or undefined
+      assertParamExists('stateApiGetLocalDataObjectsByBagId', 'bagId', bagId)
+      const localVarPath = `/state/bags/{bagId}/data-objects`.replace(`{${'bagId'}}`, encodeURIComponent(String(bagId)))
+      // use dummy base URL string because the URL constructor only accepts absolute URLs.
+      const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
+      let baseOptions
+      if (configuration) {
+        baseOptions = configuration.baseOptions
+      }
+
+      const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }
+      const localVarHeaderParameter = {} as any
+      const localVarQueryParameter = {} as any
+
+      setSearchParams(localVarUrlObj, localVarQueryParameter, options.query)
+      let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
+      localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
+
+      return {
+        url: toPathString(localVarUrlObj),
+        options: localVarRequestOptions,
+      }
+    },
+    /**
+     * Returns local uploading directory stats.
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    stateApiGetLocalDataStats: async (options: any = {}): Promise<RequestArgs> => {
+      const localVarPath = `/state/data`
+      // use dummy base URL string because the URL constructor only accepts absolute URLs.
+      const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
+      let baseOptions
+      if (configuration) {
+        baseOptions = configuration.baseOptions
+      }
+
+      const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }
+      const localVarHeaderParameter = {} as any
+      const localVarQueryParameter = {} as any
+
+      setSearchParams(localVarUrlObj, localVarQueryParameter, options.query)
+      let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
+      localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
+
+      return {
+        url: toPathString(localVarUrlObj),
+        options: localVarRequestOptions,
+      }
+    },
+    /**
+     * Returns server version.
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    stateApiGetVersion: async (options: any = {}): Promise<RequestArgs> => {
+      const localVarPath = `/version`
+      // use dummy base URL string because the URL constructor only accepts absolute URLs.
+      const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL)
+      let baseOptions
+      if (configuration) {
+        baseOptions = configuration.baseOptions
+      }
+
+      const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options }
+      const localVarHeaderParameter = {} as any
+      const localVarQueryParameter = {} as any
+
+      setSearchParams(localVarUrlObj, localVarQueryParameter, options.query)
+      let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}
+      localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers }
+
+      return {
+        url: toPathString(localVarUrlObj),
+        options: localVarRequestOptions,
+      }
+    },
+  }
+}
 
 /**
  * StateApi - functional programming interface
  * @export
  */
-export const StateApiFp = function(configuration?: Configuration) {
-    const localVarAxiosParamCreator = StateApiAxiosParamCreator(configuration)
-    return {
-        /**
-         * Returns all local data objects.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        async stateApiGetAllLocalDataObjects(options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<string>>> {
-            const localVarAxiosArgs = await localVarAxiosParamCreator.stateApiGetAllLocalDataObjects(options);
-            return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
-        },
-        /**
-         * Returns local data objects for the bag.
-         * @param {string} bagId Bag ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        async stateApiGetLocalDataObjectsByBagId(bagId: string, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<string>>> {
-            const localVarAxiosArgs = await localVarAxiosParamCreator.stateApiGetLocalDataObjectsByBagId(bagId, options);
-            return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
-        },
-        /**
-         * Returns local uploading directory stats.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        async stateApiGetLocalDataStats(options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<DataStatsResponse>> {
-            const localVarAxiosArgs = await localVarAxiosParamCreator.stateApiGetLocalDataStats(options);
-            return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
-        },
-        /**
-         * Returns server version.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        async stateApiGetVersion(options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<VersionResponse>> {
-            const localVarAxiosArgs = await localVarAxiosParamCreator.stateApiGetVersion(options);
-            return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
-        },
-    }
-};
+export const StateApiFp = function (configuration?: Configuration) {
+  const localVarAxiosParamCreator = StateApiAxiosParamCreator(configuration)
+  return {
+    /**
+     * Returns all local data objects.
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    async stateApiGetAllLocalDataObjects(
+      options?: any
+    ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<string>>> {
+      const localVarAxiosArgs = await localVarAxiosParamCreator.stateApiGetAllLocalDataObjects(options)
+      return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)
+    },
+    /**
+     * Returns local data objects for the bag.
+     * @param {string} bagId Bag ID
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    async stateApiGetLocalDataObjectsByBagId(
+      bagId: string,
+      options?: any
+    ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<string>>> {
+      const localVarAxiosArgs = await localVarAxiosParamCreator.stateApiGetLocalDataObjectsByBagId(bagId, options)
+      return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)
+    },
+    /**
+     * Returns local uploading directory stats.
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    async stateApiGetLocalDataStats(
+      options?: any
+    ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<DataStatsResponse>> {
+      const localVarAxiosArgs = await localVarAxiosParamCreator.stateApiGetLocalDataStats(options)
+      return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)
+    },
+    /**
+     * Returns server version.
+     * @param {*} [options] Override http request option.
+     * @throws {RequiredError}
+     */
+    async stateApiGetVersion(
+      options?: any
+    ): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<VersionResponse>> {
+      const localVarAxiosArgs = await localVarAxiosParamCreator.stateApiGetVersion(options)
+      return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)
+    },
+  }
+}
 
 /**
  * StateApi - factory interface
  * @export
  */
 export const StateApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
-    const localVarFp = StateApiFp(configuration)
-    return {
-        /**
-         * Returns all local data objects.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        stateApiGetAllLocalDataObjects(options?: any): AxiosPromise<Array<string>> {
-            return localVarFp.stateApiGetAllLocalDataObjects(options).then((request) => request(axios, basePath));
-        },
-        /**
-         * Returns local data objects for the bag.
-         * @param {string} bagId Bag ID
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        stateApiGetLocalDataObjectsByBagId(bagId: string, options?: any): AxiosPromise<Array<string>> {
-            return localVarFp.stateApiGetLocalDataObjectsByBagId(bagId, options).then((request) => request(axios, basePath));
-        },
-        /**
-         * Returns local uploading directory stats.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        stateApiGetLocalDataStats(options?: any): AxiosPromise<DataStatsResponse> {
-            return localVarFp.stateApiGetLocalDataStats(options).then((request) => request(axios, basePath));
-        },
-        /**
-         * Returns server version.
-         * @param {*} [options] Override http request option.
-         * @throws {RequiredError}
-         */
-        stateApiGetVersion(options?: any): AxiosPromise<VersionResponse> {
-            return localVarFp.stateApiGetVersion(options).then((request) => request(axios, basePath));
-        },
-    };
-};
-
-/**
- * StateApi - object-oriented interface
- * @export
- * @class StateApi
- * @extends {BaseAPI}
- */
-export class StateApi extends BaseAPI {
+  const localVarFp = StateApiFp(configuration)
+  return {
     /**
      * Returns all local data objects.
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
-     * @memberof StateApi
      */
-    public stateApiGetAllLocalDataObjects(options?: any) {
-        return StateApiFp(this.configuration).stateApiGetAllLocalDataObjects(options).then((request) => request(this.axios, this.basePath));
-    }
-
+    stateApiGetAllLocalDataObjects(options?: any): AxiosPromise<Array<string>> {
+      return localVarFp.stateApiGetAllLocalDataObjects(options).then((request) => request(axios, basePath))
+    },
     /**
      * Returns local data objects for the bag.
      * @param {string} bagId Bag ID
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
-     * @memberof StateApi
      */
-    public stateApiGetLocalDataObjectsByBagId(bagId: string, options?: any) {
-        return StateApiFp(this.configuration).stateApiGetLocalDataObjectsByBagId(bagId, options).then((request) => request(this.axios, this.basePath));
-    }
-
+    stateApiGetLocalDataObjectsByBagId(bagId: string, options?: any): AxiosPromise<Array<string>> {
+      return localVarFp.stateApiGetLocalDataObjectsByBagId(bagId, options).then((request) => request(axios, basePath))
+    },
     /**
      * Returns local uploading directory stats.
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
-     * @memberof StateApi
      */
-    public stateApiGetLocalDataStats(options?: any) {
-        return StateApiFp(this.configuration).stateApiGetLocalDataStats(options).then((request) => request(this.axios, this.basePath));
-    }
-
+    stateApiGetLocalDataStats(options?: any): AxiosPromise<DataStatsResponse> {
+      return localVarFp.stateApiGetLocalDataStats(options).then((request) => request(axios, basePath))
+    },
     /**
      * Returns server version.
      * @param {*} [options] Override http request option.
      * @throws {RequiredError}
-     * @memberof StateApi
      */
-    public stateApiGetVersion(options?: any) {
-        return StateApiFp(this.configuration).stateApiGetVersion(options).then((request) => request(this.axios, this.basePath));
-    }
+    stateApiGetVersion(options?: any): AxiosPromise<VersionResponse> {
+      return localVarFp.stateApiGetVersion(options).then((request) => request(axios, basePath))
+    },
+  }
 }
 
-
+/**
+ * StateApi - object-oriented interface
+ * @export
+ * @class StateApi
+ * @extends {BaseAPI}
+ */
+export class StateApi extends BaseAPI {
+  /**
+   * Returns all local data objects.
+   * @param {*} [options] Override http request option.
+   * @throws {RequiredError}
+   * @memberof StateApi
+   */
+  public stateApiGetAllLocalDataObjects(options?: any) {
+    return StateApiFp(this.configuration)
+      .stateApiGetAllLocalDataObjects(options)
+      .then((request) => request(this.axios, this.basePath))
+  }
+
+  /**
+   * Returns local data objects for the bag.
+   * @param {string} bagId Bag ID
+   * @param {*} [options] Override http request option.
+   * @throws {RequiredError}
+   * @memberof StateApi
+   */
+  public stateApiGetLocalDataObjectsByBagId(bagId: string, options?: any) {
+    return StateApiFp(this.configuration)
+      .stateApiGetLocalDataObjectsByBagId(bagId, options)
+      .then((request) => request(this.axios, this.basePath))
+  }
+
+  /**
+   * Returns local uploading directory stats.
+   * @param {*} [options] Override http request option.
+   * @throws {RequiredError}
+   * @memberof StateApi
+   */
+  public stateApiGetLocalDataStats(options?: any) {
+    return StateApiFp(this.configuration)
+      .stateApiGetLocalDataStats(options)
+      .then((request) => request(this.axios, this.basePath))
+  }
+
+  /**
+   * Returns server version.
+   * @param {*} [options] Override http request option.
+   * @throws {RequiredError}
+   * @memberof StateApi
+   */
+  public stateApiGetVersion(options?: any) {
+    return StateApiFp(this.configuration)
+      .stateApiGetVersion(options)
+      .then((request) => request(this.axios, this.basePath))
+  }
+}

+ 25 - 22
distributor-node/src/services/networking/storage-node/generated/base.ts

@@ -12,24 +12,23 @@
  * Do not edit the class manually.
  */
 
-
-import { Configuration } from "./configuration";
+import { Configuration } from './configuration'
 // Some imports not used depending on template conditions
 // @ts-ignore
-import globalAxios, { AxiosPromise, AxiosInstance } from 'axios';
+import globalAxios, { AxiosPromise, AxiosInstance } from 'axios'
 
-export const BASE_PATH = "http://localhost:3333/api/v1".replace(/\/+$/, "");
+export const BASE_PATH = 'http://localhost:3333/api/v1'.replace(/\/+$/, '')
 
 /**
  *
  * @export
  */
 export const COLLECTION_FORMATS = {
-    csv: ",",
-    ssv: " ",
-    tsv: "\t",
-    pipes: "|",
-};
+  csv: ',',
+  ssv: ' ',
+  tsv: '\t',
+  pipes: '|',
+}
 
 /**
  *
@@ -37,8 +36,8 @@ export const COLLECTION_FORMATS = {
  * @interface RequestArgs
  */
 export interface RequestArgs {
-    url: string;
-    options: any;
+  url: string
+  options: any
 }
 
 /**
@@ -47,15 +46,19 @@ export interface RequestArgs {
  * @class BaseAPI
  */
 export class BaseAPI {
-    protected configuration: Configuration | undefined;
+  protected configuration: Configuration | undefined
 
-    constructor(configuration?: Configuration, protected basePath: string = BASE_PATH, protected axios: AxiosInstance = globalAxios) {
-        if (configuration) {
-            this.configuration = configuration;
-            this.basePath = configuration.basePath || this.basePath;
-        }
+  constructor(
+    configuration?: Configuration,
+    protected basePath: string = BASE_PATH,
+    protected axios: AxiosInstance = globalAxios
+  ) {
+    if (configuration) {
+      this.configuration = configuration
+      this.basePath = configuration.basePath || this.basePath
     }
-};
+  }
+}
 
 /**
  *
@@ -64,8 +67,8 @@ export class BaseAPI {
  * @extends {Error}
  */
 export class RequiredError extends Error {
-    name: "RequiredError" = "RequiredError";
-    constructor(public field: string, msg?: string) {
-        super(msg);
-    }
+  name: 'RequiredError' = 'RequiredError'
+  constructor(public field: string, msg?: string) {
+    super(msg)
+  }
 }

+ 66 - 54
distributor-node/src/services/networking/storage-node/generated/common.ts

@@ -12,10 +12,9 @@
  * Do not edit the class manually.
  */
 
-
-import { Configuration } from "./configuration";
-import { RequiredError, RequestArgs } from "./base";
-import { AxiosInstance } from 'axios';
+import { Configuration } from './configuration'
+import { RequiredError, RequestArgs } from './base'
+import { AxiosInstance } from 'axios'
 
 /**
  *
@@ -29,9 +28,12 @@ export const DUMMY_BASE_URL = 'https://example.com'
  * @export
  */
 export const assertParamExists = function (functionName: string, paramName: string, paramValue: unknown) {
-    if (paramValue === null || paramValue === undefined) {
-        throw new RequiredError(paramName, `Required parameter ${paramName} was null or undefined when calling ${functionName}.`);
-    }
+  if (paramValue === null || paramValue === undefined) {
+    throw new RequiredError(
+      paramName,
+      `Required parameter ${paramName} was null or undefined when calling ${functionName}.`
+    )
+  }
 }
 
 /**
@@ -39,12 +41,11 @@ export const assertParamExists = function (functionName: string, paramName: stri
  * @export
  */
 export const setApiKeyToObject = async function (object: any, keyParamName: string, configuration?: Configuration) {
-    if (configuration && configuration.apiKey) {
-        const localVarApiKeyValue = typeof configuration.apiKey === 'function'
-            ? await configuration.apiKey(keyParamName)
-            : await configuration.apiKey;
-        object[keyParamName] = localVarApiKeyValue;
-    }
+  if (configuration && configuration.apiKey) {
+    const localVarApiKeyValue =
+      typeof configuration.apiKey === 'function' ? await configuration.apiKey(keyParamName) : await configuration.apiKey
+    object[keyParamName] = localVarApiKeyValue
+  }
 }
 
 /**
@@ -52,9 +53,9 @@ export const setApiKeyToObject = async function (object: any, keyParamName: stri
  * @export
  */
 export const setBasicAuthToObject = function (object: any, configuration?: Configuration) {
-    if (configuration && (configuration.username || configuration.password)) {
-        object["auth"] = { username: configuration.username, password: configuration.password };
-    }
+  if (configuration && (configuration.username || configuration.password)) {
+    object['auth'] = { username: configuration.username, password: configuration.password }
+  }
 }
 
 /**
@@ -62,25 +63,32 @@ export const setBasicAuthToObject = function (object: any, configuration?: Confi
  * @export
  */
 export const setBearerAuthToObject = async function (object: any, configuration?: Configuration) {
-    if (configuration && configuration.accessToken) {
-        const accessToken = typeof configuration.accessToken === 'function'
-            ? await configuration.accessToken()
-            : await configuration.accessToken;
-        object["Authorization"] = "Bearer " + accessToken;
-    }
+  if (configuration && configuration.accessToken) {
+    const accessToken =
+      typeof configuration.accessToken === 'function'
+        ? await configuration.accessToken()
+        : await configuration.accessToken
+    object['Authorization'] = 'Bearer ' + accessToken
+  }
 }
 
 /**
  *
  * @export
  */
-export const setOAuthToObject = async function (object: any, name: string, scopes: string[], configuration?: Configuration) {
-    if (configuration && configuration.accessToken) {
-        const localVarAccessTokenValue = typeof configuration.accessToken === 'function'
-            ? await configuration.accessToken(name, scopes)
-            : await configuration.accessToken;
-        object["Authorization"] = "Bearer " + localVarAccessTokenValue;
-    }
+export const setOAuthToObject = async function (
+  object: any,
+  name: string,
+  scopes: string[],
+  configuration?: Configuration
+) {
+  if (configuration && configuration.accessToken) {
+    const localVarAccessTokenValue =
+      typeof configuration.accessToken === 'function'
+        ? await configuration.accessToken(name, scopes)
+        : await configuration.accessToken
+    object['Authorization'] = 'Bearer ' + localVarAccessTokenValue
+  }
 }
 
 /**
@@ -88,20 +96,20 @@ export const setOAuthToObject = async function (object: any, name: string, scope
  * @export
  */
 export const setSearchParams = function (url: URL, ...objects: any[]) {
-    const searchParams = new URLSearchParams(url.search);
-    for (const object of objects) {
-        for (const key in object) {
-            if (Array.isArray(object[key])) {
-                searchParams.delete(key);
-                for (const item of object[key]) {
-                    searchParams.append(key, item);
-                }
-            } else {
-                searchParams.set(key, object[key]);
-            }
+  const searchParams = new URLSearchParams(url.search)
+  for (const object of objects) {
+    for (const key in object) {
+      if (Array.isArray(object[key])) {
+        searchParams.delete(key)
+        for (const item of object[key]) {
+          searchParams.append(key, item)
         }
+      } else {
+        searchParams.set(key, object[key])
+      }
     }
-    url.search = searchParams.toString();
+  }
+  url.search = searchParams.toString()
 }
 
 /**
@@ -109,13 +117,12 @@ export const setSearchParams = function (url: URL, ...objects: any[]) {
  * @export
  */
 export const serializeDataIfNeeded = function (value: any, requestOptions: any, configuration?: Configuration) {
-    const nonString = typeof value !== 'string';
-    const needsSerialization = nonString && configuration && configuration.isJsonMime
-        ? configuration.isJsonMime(requestOptions.headers['Content-Type'])
-        : nonString;
-    return needsSerialization
-        ? JSON.stringify(value !== undefined ? value : {})
-        : (value || "");
+  const nonString = typeof value !== 'string'
+  const needsSerialization =
+    nonString && configuration && configuration.isJsonMime
+      ? configuration.isJsonMime(requestOptions.headers['Content-Type'])
+      : nonString
+  return needsSerialization ? JSON.stringify(value !== undefined ? value : {}) : value || ''
 }
 
 /**
@@ -123,16 +130,21 @@ export const serializeDataIfNeeded = function (value: any, requestOptions: any,
  * @export
  */
 export const toPathString = function (url: URL) {
-    return url.pathname + url.search + url.hash
+  return url.pathname + url.search + url.hash
 }
 
 /**
  *
  * @export
  */
-export const createRequestFunction = function (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) {
-    return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
-        const axiosRequestArgs = {...axiosArgs.options, url: (configuration?.basePath || basePath) + axiosArgs.url};
-        return axios.request(axiosRequestArgs);
-    };
+export const createRequestFunction = function (
+  axiosArgs: RequestArgs,
+  globalAxios: AxiosInstance,
+  BASE_PATH: string,
+  configuration?: Configuration
+) {
+  return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
+    const axiosRequestArgs = { ...axiosArgs.options, url: (configuration?.basePath || basePath) + axiosArgs.url }
+    return axios.request(axiosRequestArgs)
+  }
 }

+ 87 - 80
distributor-node/src/services/networking/storage-node/generated/configuration.ts

@@ -12,90 +12,97 @@
  * Do not edit the class manually.
  */
 
-
 export interface ConfigurationParameters {
-    apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
-    username?: string;
-    password?: string;
-    accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);
-    basePath?: string;
-    baseOptions?: any;
-    formDataCtor?: new () => any;
+  apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>)
+  username?: string
+  password?: string
+  accessToken?:
+    | string
+    | Promise<string>
+    | ((name?: string, scopes?: string[]) => string)
+    | ((name?: string, scopes?: string[]) => Promise<string>)
+  basePath?: string
+  baseOptions?: any
+  formDataCtor?: new () => any
 }
 
 export class Configuration {
-    /**
-     * parameter for apiKey security
-     * @param name security name
-     * @memberof Configuration
-     */
-    apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>);
-    /**
-     * parameter for basic security
-     *
-     * @type {string}
-     * @memberof Configuration
-     */
-    username?: string;
-    /**
-     * parameter for basic security
-     *
-     * @type {string}
-     * @memberof Configuration
-     */
-    password?: string;
-    /**
-     * parameter for oauth2 security
-     * @param name security name
-     * @param scopes oauth2 scope
-     * @memberof Configuration
-     */
-    accessToken?: string | Promise<string> | ((name?: string, scopes?: string[]) => string) | ((name?: string, scopes?: string[]) => Promise<string>);
-    /**
-     * override base path
-     *
-     * @type {string}
-     * @memberof Configuration
-     */
-    basePath?: string;
-    /**
-     * base options for axios calls
-     *
-     * @type {any}
-     * @memberof Configuration
-     */
-    baseOptions?: any;
-    /**
-     * The FormData constructor that will be used to create multipart form data
-     * requests. You can inject this here so that execution environments that
-     * do not support the FormData class can still run the generated client.
-     *
-     * @type {new () => FormData}
-     */
-    formDataCtor?: new () => any;
+  /**
+   * parameter for apiKey security
+   * @param name security name
+   * @memberof Configuration
+   */
+  apiKey?: string | Promise<string> | ((name: string) => string) | ((name: string) => Promise<string>)
+  /**
+   * parameter for basic security
+   *
+   * @type {string}
+   * @memberof Configuration
+   */
+  username?: string
+  /**
+   * parameter for basic security
+   *
+   * @type {string}
+   * @memberof Configuration
+   */
+  password?: string
+  /**
+   * parameter for oauth2 security
+   * @param name security name
+   * @param scopes oauth2 scope
+   * @memberof Configuration
+   */
+  accessToken?:
+    | string
+    | Promise<string>
+    | ((name?: string, scopes?: string[]) => string)
+    | ((name?: string, scopes?: string[]) => Promise<string>)
+  /**
+   * override base path
+   *
+   * @type {string}
+   * @memberof Configuration
+   */
+  basePath?: string
+  /**
+   * base options for axios calls
+   *
+   * @type {any}
+   * @memberof Configuration
+   */
+  baseOptions?: any
+  /**
+   * The FormData constructor that will be used to create multipart form data
+   * requests. You can inject this here so that execution environments that
+   * do not support the FormData class can still run the generated client.
+   *
+   * @type {new () => FormData}
+   */
+  formDataCtor?: new () => any
 
-    constructor(param: ConfigurationParameters = {}) {
-        this.apiKey = param.apiKey;
-        this.username = param.username;
-        this.password = param.password;
-        this.accessToken = param.accessToken;
-        this.basePath = param.basePath;
-        this.baseOptions = param.baseOptions;
-        this.formDataCtor = param.formDataCtor;
-    }
+  constructor(param: ConfigurationParameters = {}) {
+    this.apiKey = param.apiKey
+    this.username = param.username
+    this.password = param.password
+    this.accessToken = param.accessToken
+    this.basePath = param.basePath
+    this.baseOptions = param.baseOptions
+    this.formDataCtor = param.formDataCtor
+  }
 
-    /**
-     * Check if the given MIME is a JSON MIME.
-     * JSON MIME examples:
-     *   application/json
-     *   application/json; charset=UTF8
-     *   APPLICATION/JSON
-     *   application/vnd.company+json
-     * @param mime - MIME (Multipurpose Internet Mail Extensions)
-     * @return True if the given MIME is JSON, false otherwise.
-     */
-    public isJsonMime(mime: string): boolean {
-        const jsonMime: RegExp = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
-        return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
-    }
+  /**
+   * Check if the given MIME is a JSON MIME.
+   * JSON MIME examples:
+   *   application/json
+   *   application/json; charset=UTF8
+   *   APPLICATION/JSON
+   *   application/vnd.company+json
+   * @param mime - MIME (Multipurpose Internet Mail Extensions)
+   * @return True if the given MIME is JSON, false otherwise.
+   */
+  public isJsonMime(mime: string): boolean {
+    const jsonMime: RegExp = new RegExp('^(application/json|[^;/ \t]+/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i')
+    return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json')
+  }
 }

+ 2 - 4
distributor-node/src/services/networking/storage-node/generated/index.ts

@@ -12,7 +12,5 @@
  * Do not edit the class manually.
  */
 
-
-export * from "./api";
-export * from "./configuration";
-
+export * from './api'
+export * from './configuration'

Algúns arquivos non se mostraron porque demasiados arquivos cambiaron neste cambio