UNPKG

@onfido/api

Version:

Node.js library for the Onfido API

50 lines (49 loc) 1.53 kB
"use strict"; /* tslint:disable */ /* eslint-disable */ /** * Onfido Public API v3.6 * The Onfido Public API (v3.6) * * The version of the OpenAPI document: v3.6 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.operationServerMap = exports.RequiredError = exports.BaseAPI = exports.COLLECTION_FORMATS = exports.BASE_PATH = void 0; const axios_1 = require("axios"); const file_transfer_1 = require("./file-transfer"); exports.BASE_PATH = "https://api.eu.onfido.com/v3.6".replace(/\/+$/, ""); const sdkAxios = axios_1.default.create(); exports.COLLECTION_FORMATS = { csv: ",", ssv: " ", tsv: "\t", pipes: "|", }; class BaseAPI { constructor(configuration, basePath = exports.BASE_PATH, axios = sdkAxios) { var _a; this.basePath = basePath; this.axios = axios; if (configuration) { this.configuration = configuration; this.basePath = (_a = configuration.basePath) !== null && _a !== void 0 ? _a : basePath; } (0, file_transfer_1.attachFileTransferInterceptor)(this.axios); } } exports.BaseAPI = BaseAPI; ; class RequiredError extends Error { constructor(field, msg) { super(msg); this.field = field; this.name = "RequiredError"; } } exports.RequiredError = RequiredError; exports.operationServerMap = {};