@yoroi/exchange
Version:
The Exchange package of Yoroi SDK
29 lines (28 loc) • 744 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.banxaApiGetBaseUrl = exports.banxaApiConfig = void 0;
var _immer = require("immer");
const banxaApiGetBaseUrl = _ref => {
let {
isProduction,
partner
} = _ref;
return async () => {
const domain = banxaApiConfig[isProduction ? 'production' : 'sandbox'].getBaseUrl;
const baseUrl = `https://${partner}.${domain}`;
return Promise.resolve(baseUrl);
};
};
exports.banxaApiGetBaseUrl = banxaApiGetBaseUrl;
const banxaApiConfig = (0, _immer.freeze)({
production: {
getBaseUrl: 'banxa.com'
},
sandbox: {
getBaseUrl: 'banxa-sandbox.com'
}
}, true);
exports.banxaApiConfig = banxaApiConfig;
//# sourceMappingURL=api.js.map