UNPKG

transbank-sdk

Version:
27 lines (26 loc) 1.14 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); /** * Class containing needed authenticaction and configuration to interact with the API. * Environment correspond to the environment to use, it can be Integration or Production, each has * a unique URL. */ var Options = /** @class */ (function () { /** * Create an instance of Options * @param commerceCode unique commerce identifier provided by Transbank * @param apiKey the secret used to authenticate against the API, it must be kept safe at all times. * @param environment Environment correspond to the environment to use, it can be Integration or * Production, each has a unique URL. * @param timeout Timeout for requests in milliseconds */ function Options(commerceCode, apiKey, environment, timeout) { var defaultTimeout = 1000 * 60 * 10; this.commerceCode = commerceCode; this.apiKey = apiKey; this.environment = environment; this.timeout = timeout !== null && timeout !== void 0 ? timeout : defaultTimeout; } return Options; }()); exports.default = Options;