@monerium/sdk 2.0.0 → 2.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +25 -0
- package/README.md +5 -12
- package/dist/index.d.ts +314 -0
- package/dist/index.es.js +73 -73
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +286 -286
- package/dist/index.umd.js.map +1 -1
- package/package.json +4 -4
package/dist/index.es.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.es.js","sources":["../src/config.ts","../__vite-browser-external","../node_modules/crypto-js/core.js","../node_modules/crypto-js/enc-base64url.js","../node_modules/crypto-js/sha256.js","../node_modules/crypto-js/lib-typedarrays.js","../src/client.ts","../src/types.ts"],"sourcesContent":["import type { Config } from \"./types\";\n\nconst MONERIUM_CONFIG: Config = {\n environments: {\n production: {\n api: \"https://api.monerium.app\",\n web: \"https://monerium.app\",\n },\n sandbox: {\n api: \"https://api.monerium.dev\",\n web: \"https://sandbox.monerium.dev\",\n },\n },\n};\n\nexport { MONERIUM_CONFIG };\n","export default {}",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory();\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\troot.CryptoJS = factory();\n\t}\n}(this, function () {\n\n\t/*globals window, global, require*/\n\n\t/**\n\t * CryptoJS core components.\n\t */\n\tvar CryptoJS = CryptoJS || (function (Math, undefined) {\n\n\t var crypto;\n\n\t // Native crypto from window (Browser)\n\t if (typeof window !== 'undefined' && window.crypto) {\n\t crypto = window.crypto;\n\t }\n\n\t // Native crypto in web worker (Browser)\n\t if (typeof self !== 'undefined' && self.crypto) {\n\t crypto = self.crypto;\n\t }\n\n\t // Native crypto from worker\n\t if (typeof globalThis !== 'undefined' && globalThis.crypto) {\n\t crypto = globalThis.crypto;\n\t }\n\n\t // Native (experimental IE 11) crypto from window (Browser)\n\t if (!crypto && typeof window !== 'undefined' && window.msCrypto) {\n\t crypto = window.msCrypto;\n\t }\n\n\t // Native crypto from global (NodeJS)\n\t if (!crypto && typeof global !== 'undefined' && global.crypto) {\n\t crypto = global.crypto;\n\t }\n\n\t // Native crypto import via require (NodeJS)\n\t if (!crypto && typeof require === 'function') {\n\t try {\n\t crypto = require('crypto');\n\t } catch (err) {}\n\t }\n\n\t /*\n\t * Cryptographically secure pseudorandom number generator\n\t *\n\t * As Math.random() is cryptographically not safe to use\n\t */\n\t var cryptoSecureRandomInt = function () {\n\t if (crypto) {\n\t // Use getRandomValues method (Browser)\n\t if (typeof crypto.getRandomValues === 'function') {\n\t try {\n\t return crypto.getRandomValues(new Uint32Array(1))[0];\n\t } catch (err) {}\n\t }\n\n\t // Use randomBytes method (NodeJS)\n\t if (typeof crypto.randomBytes === 'function') {\n\t try {\n\t return crypto.randomBytes(4).readInt32LE();\n\t } catch (err) {}\n\t }\n\t }\n\n\t throw new Error('Native crypto module could not be used to get secure random number.');\n\t };\n\n\t /*\n\t * Local polyfill of Object.create\n\n\t */\n\t var create = Object.create || (function () {\n\t function F() {}\n\n\t return function (obj) {\n\t var subtype;\n\n\t F.prototype = obj;\n\n\t subtype = new F();\n\n\t F.prototype = null;\n\n\t return subtype;\n\t };\n\t }());\n\n\t /**\n\t * CryptoJS namespace.\n\t */\n\t var C = {};\n\n\t /**\n\t * Library namespace.\n\t */\n\t var C_lib = C.lib = {};\n\n\t /**\n\t * Base object for prototypal inheritance.\n\t */\n\t var Base = C_lib.Base = (function () {\n\n\n\t return {\n\t /**\n\t * Creates a new object that inherits from this object.\n\t *\n\t * @param {Object} overrides Properties to copy into the new object.\n\t *\n\t * @return {Object} The new object.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var MyType = CryptoJS.lib.Base.extend({\n\t * field: 'value',\n\t *\n\t * method: function () {\n\t * }\n\t * });\n\t */\n\t extend: function (overrides) {\n\t // Spawn\n\t var subtype = create(this);\n\n\t // Augment\n\t if (overrides) {\n\t subtype.mixIn(overrides);\n\t }\n\n\t // Create default initializer\n\t if (!subtype.hasOwnProperty('init') || this.init === subtype.init) {\n\t subtype.init = function () {\n\t subtype.$super.init.apply(this, arguments);\n\t };\n\t }\n\n\t // Initializer's prototype is the subtype object\n\t subtype.init.prototype = subtype;\n\n\t // Reference supertype\n\t subtype.$super = this;\n\n\t return subtype;\n\t },\n\n\t /**\n\t * Extends this object and runs the init method.\n\t * Arguments to create() will be passed to init().\n\t *\n\t * @return {Object} The new object.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var instance = MyType.create();\n\t */\n\t create: function () {\n\t var instance = this.extend();\n\t instance.init.apply(instance, arguments);\n\n\t return instance;\n\t },\n\n\t /**\n\t * Initializes a newly created object.\n\t * Override this method to add some logic when your objects are created.\n\t *\n\t * @example\n\t *\n\t * var MyType = CryptoJS.lib.Base.extend({\n\t * init: function () {\n\t * // ...\n\t * }\n\t * });\n\t */\n\t init: function () {\n\t },\n\n\t /**\n\t * Copies properties into this object.\n\t *\n\t * @param {Object} properties The properties to mix in.\n\t *\n\t * @example\n\t *\n\t * MyType.mixIn({\n\t * field: 'value'\n\t * });\n\t */\n\t mixIn: function (properties) {\n\t for (var propertyName in properties) {\n\t if (properties.hasOwnProperty(propertyName)) {\n\t this[propertyName] = properties[propertyName];\n\t }\n\t }\n\n\t // IE won't copy toString using the loop above\n\t if (properties.hasOwnProperty('toString')) {\n\t this.toString = properties.toString;\n\t }\n\t },\n\n\t /**\n\t * Creates a copy of this object.\n\t *\n\t * @return {Object} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = instance.clone();\n\t */\n\t clone: function () {\n\t return this.init.prototype.extend(this);\n\t }\n\t };\n\t }());\n\n\t /**\n\t * An array of 32-bit words.\n\t *\n\t * @property {Array} words The array of 32-bit words.\n\t * @property {number} sigBytes The number of significant bytes in this word array.\n\t */\n\t var WordArray = C_lib.WordArray = Base.extend({\n\t /**\n\t * Initializes a newly created word array.\n\t *\n\t * @param {Array} words (Optional) An array of 32-bit words.\n\t * @param {number} sigBytes (Optional) The number of significant bytes in the words.\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.lib.WordArray.create();\n\t * var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607]);\n\t * var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607], 6);\n\t */\n\t init: function (words, sigBytes) {\n\t words = this.words = words || [];\n\n\t if (sigBytes != undefined) {\n\t this.sigBytes = sigBytes;\n\t } else {\n\t this.sigBytes = words.length * 4;\n\t }\n\t },\n\n\t /**\n\t * Converts this word array to a string.\n\t *\n\t * @param {Encoder} encoder (Optional) The encoding strategy to use. Default: CryptoJS.enc.Hex\n\t *\n\t * @return {string} The stringified word array.\n\t *\n\t * @example\n\t *\n\t * var string = wordArray + '';\n\t * var string = wordArray.toString();\n\t * var string = wordArray.toString(CryptoJS.enc.Utf8);\n\t */\n\t toString: function (encoder) {\n\t return (encoder || Hex).stringify(this);\n\t },\n\n\t /**\n\t * Concatenates a word array to this word array.\n\t *\n\t * @param {WordArray} wordArray The word array to append.\n\t *\n\t * @return {WordArray} This word array.\n\t *\n\t * @example\n\t *\n\t * wordArray1.concat(wordArray2);\n\t */\n\t concat: function (wordArray) {\n\t // Shortcuts\n\t var thisWords = this.words;\n\t var thatWords = wordArray.words;\n\t var thisSigBytes = this.sigBytes;\n\t var thatSigBytes = wordArray.sigBytes;\n\n\t // Clamp excess bits\n\t this.clamp();\n\n\t // Concat\n\t if (thisSigBytes % 4) {\n\t // Copy one byte at a time\n\t for (var i = 0; i < thatSigBytes; i++) {\n\t var thatByte = (thatWords[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t thisWords[(thisSigBytes + i) >>> 2] |= thatByte << (24 - ((thisSigBytes + i) % 4) * 8);\n\t }\n\t } else {\n\t // Copy one word at a time\n\t for (var j = 0; j < thatSigBytes; j += 4) {\n\t thisWords[(thisSigBytes + j) >>> 2] = thatWords[j >>> 2];\n\t }\n\t }\n\t this.sigBytes += thatSigBytes;\n\n\t // Chainable\n\t return this;\n\t },\n\n\t /**\n\t * Removes insignificant bits.\n\t *\n\t * @example\n\t *\n\t * wordArray.clamp();\n\t */\n\t clamp: function () {\n\t // Shortcuts\n\t var words = this.words;\n\t var sigBytes = this.sigBytes;\n\n\t // Clamp\n\t words[sigBytes >>> 2] &= 0xffffffff << (32 - (sigBytes % 4) * 8);\n\t words.length = Math.ceil(sigBytes / 4);\n\t },\n\n\t /**\n\t * Creates a copy of this word array.\n\t *\n\t * @return {WordArray} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = wordArray.clone();\n\t */\n\t clone: function () {\n\t var clone = Base.clone.call(this);\n\t clone.words = this.words.slice(0);\n\n\t return clone;\n\t },\n\n\t /**\n\t * Creates a word array filled with random bytes.\n\t *\n\t * @param {number} nBytes The number of random bytes to generate.\n\t *\n\t * @return {WordArray} The random word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.lib.WordArray.random(16);\n\t */\n\t random: function (nBytes) {\n\t var words = [];\n\n\t for (var i = 0; i < nBytes; i += 4) {\n\t words.push(cryptoSecureRandomInt());\n\t }\n\n\t return new WordArray.init(words, nBytes);\n\t }\n\t });\n\n\t /**\n\t * Encoder namespace.\n\t */\n\t var C_enc = C.enc = {};\n\n\t /**\n\t * Hex encoding strategy.\n\t */\n\t var Hex = C_enc.Hex = {\n\t /**\n\t * Converts a word array to a hex string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The hex string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hexString = CryptoJS.enc.Hex.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t // Shortcuts\n\t var words = wordArray.words;\n\t var sigBytes = wordArray.sigBytes;\n\n\t // Convert\n\t var hexChars = [];\n\t for (var i = 0; i < sigBytes; i++) {\n\t var bite = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t hexChars.push((bite >>> 4).toString(16));\n\t hexChars.push((bite & 0x0f).toString(16));\n\t }\n\n\t return hexChars.join('');\n\t },\n\n\t /**\n\t * Converts a hex string to a word array.\n\t *\n\t * @param {string} hexStr The hex string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Hex.parse(hexString);\n\t */\n\t parse: function (hexStr) {\n\t // Shortcut\n\t var hexStrLength = hexStr.length;\n\n\t // Convert\n\t var words = [];\n\t for (var i = 0; i < hexStrLength; i += 2) {\n\t words[i >>> 3] |= parseInt(hexStr.substr(i, 2), 16) << (24 - (i % 8) * 4);\n\t }\n\n\t return new WordArray.init(words, hexStrLength / 2);\n\t }\n\t };\n\n\t /**\n\t * Latin1 encoding strategy.\n\t */\n\t var Latin1 = C_enc.Latin1 = {\n\t /**\n\t * Converts a word array to a Latin1 string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The Latin1 string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var latin1String = CryptoJS.enc.Latin1.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t // Shortcuts\n\t var words = wordArray.words;\n\t var sigBytes = wordArray.sigBytes;\n\n\t // Convert\n\t var latin1Chars = [];\n\t for (var i = 0; i < sigBytes; i++) {\n\t var bite = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t latin1Chars.push(String.fromCharCode(bite));\n\t }\n\n\t return latin1Chars.join('');\n\t },\n\n\t /**\n\t * Converts a Latin1 string to a word array.\n\t *\n\t * @param {string} latin1Str The Latin1 string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Latin1.parse(latin1String);\n\t */\n\t parse: function (latin1Str) {\n\t // Shortcut\n\t var latin1StrLength = latin1Str.length;\n\n\t // Convert\n\t var words = [];\n\t for (var i = 0; i < latin1StrLength; i++) {\n\t words[i >>> 2] |= (latin1Str.charCodeAt(i) & 0xff) << (24 - (i % 4) * 8);\n\t }\n\n\t return new WordArray.init(words, latin1StrLength);\n\t }\n\t };\n\n\t /**\n\t * UTF-8 encoding strategy.\n\t */\n\t var Utf8 = C_enc.Utf8 = {\n\t /**\n\t * Converts a word array to a UTF-8 string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The UTF-8 string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var utf8String = CryptoJS.enc.Utf8.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t try {\n\t return decodeURIComponent(escape(Latin1.stringify(wordArray)));\n\t } catch (e) {\n\t throw new Error('Malformed UTF-8 data');\n\t }\n\t },\n\n\t /**\n\t * Converts a UTF-8 string to a word array.\n\t *\n\t * @param {string} utf8Str The UTF-8 string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Utf8.parse(utf8String);\n\t */\n\t parse: function (utf8Str) {\n\t return Latin1.parse(unescape(encodeURIComponent(utf8Str)));\n\t }\n\t };\n\n\t /**\n\t * Abstract buffered block algorithm template.\n\t *\n\t * The property blockSize must be implemented in a concrete subtype.\n\t *\n\t * @property {number} _minBufferSize The number of blocks that should be kept unprocessed in the buffer. Default: 0\n\t */\n\t var BufferedBlockAlgorithm = C_lib.BufferedBlockAlgorithm = Base.extend({\n\t /**\n\t * Resets this block algorithm's data buffer to its initial state.\n\t *\n\t * @example\n\t *\n\t * bufferedBlockAlgorithm.reset();\n\t */\n\t reset: function () {\n\t // Initial values\n\t this._data = new WordArray.init();\n\t this._nDataBytes = 0;\n\t },\n\n\t /**\n\t * Adds new data to this block algorithm's buffer.\n\t *\n\t * @param {WordArray|string} data The data to append. Strings are converted to a WordArray using UTF-8.\n\t *\n\t * @example\n\t *\n\t * bufferedBlockAlgorithm._append('data');\n\t * bufferedBlockAlgorithm._append(wordArray);\n\t */\n\t _append: function (data) {\n\t // Convert string to WordArray, else assume WordArray already\n\t if (typeof data == 'string') {\n\t data = Utf8.parse(data);\n\t }\n\n\t // Append\n\t this._data.concat(data);\n\t this._nDataBytes += data.sigBytes;\n\t },\n\n\t /**\n\t * Processes available data blocks.\n\t *\n\t * This method invokes _doProcessBlock(offset), which must be implemented by a concrete subtype.\n\t *\n\t * @param {boolean} doFlush Whether all blocks and partial blocks should be processed.\n\t *\n\t * @return {WordArray} The processed data.\n\t *\n\t * @example\n\t *\n\t * var processedData = bufferedBlockAlgorithm._process();\n\t * var processedData = bufferedBlockAlgorithm._process(!!'flush');\n\t */\n\t _process: function (doFlush) {\n\t var processedWords;\n\n\t // Shortcuts\n\t var data = this._data;\n\t var dataWords = data.words;\n\t var dataSigBytes = data.sigBytes;\n\t var blockSize = this.blockSize;\n\t var blockSizeBytes = blockSize * 4;\n\n\t // Count blocks ready\n\t var nBlocksReady = dataSigBytes / blockSizeBytes;\n\t if (doFlush) {\n\t // Round up to include partial blocks\n\t nBlocksReady = Math.ceil(nBlocksReady);\n\t } else {\n\t // Round down to include only full blocks,\n\t // less the number of blocks that must remain in the buffer\n\t nBlocksReady = Math.max((nBlocksReady | 0) - this._minBufferSize, 0);\n\t }\n\n\t // Count words ready\n\t var nWordsReady = nBlocksReady * blockSize;\n\n\t // Count bytes ready\n\t var nBytesReady = Math.min(nWordsReady * 4, dataSigBytes);\n\n\t // Process blocks\n\t if (nWordsReady) {\n\t for (var offset = 0; offset < nWordsReady; offset += blockSize) {\n\t // Perform concrete-algorithm logic\n\t this._doProcessBlock(dataWords, offset);\n\t }\n\n\t // Remove processed words\n\t processedWords = dataWords.splice(0, nWordsReady);\n\t data.sigBytes -= nBytesReady;\n\t }\n\n\t // Return processed words\n\t return new WordArray.init(processedWords, nBytesReady);\n\t },\n\n\t /**\n\t * Creates a copy of this object.\n\t *\n\t * @return {Object} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = bufferedBlockAlgorithm.clone();\n\t */\n\t clone: function () {\n\t var clone = Base.clone.call(this);\n\t clone._data = this._data.clone();\n\n\t return clone;\n\t },\n\n\t _minBufferSize: 0\n\t });\n\n\t /**\n\t * Abstract hasher template.\n\t *\n\t * @property {number} blockSize The number of 32-bit words this hasher operates on. Default: 16 (512 bits)\n\t */\n\t var Hasher = C_lib.Hasher = BufferedBlockAlgorithm.extend({\n\t /**\n\t * Configuration options.\n\t */\n\t cfg: Base.extend(),\n\n\t /**\n\t * Initializes a newly created hasher.\n\t *\n\t * @param {Object} cfg (Optional) The configuration options to use for this hash computation.\n\t *\n\t * @example\n\t *\n\t * var hasher = CryptoJS.algo.SHA256.create();\n\t */\n\t init: function (cfg) {\n\t // Apply config defaults\n\t this.cfg = this.cfg.extend(cfg);\n\n\t // Set initial values\n\t this.reset();\n\t },\n\n\t /**\n\t * Resets this hasher to its initial state.\n\t *\n\t * @example\n\t *\n\t * hasher.reset();\n\t */\n\t reset: function () {\n\t // Reset data buffer\n\t BufferedBlockAlgorithm.reset.call(this);\n\n\t // Perform concrete-hasher logic\n\t this._doReset();\n\t },\n\n\t /**\n\t * Updates this hasher with a message.\n\t *\n\t * @param {WordArray|string} messageUpdate The message to append.\n\t *\n\t * @return {Hasher} This hasher.\n\t *\n\t * @example\n\t *\n\t * hasher.update('message');\n\t * hasher.update(wordArray);\n\t */\n\t update: function (messageUpdate) {\n\t // Append\n\t this._append(messageUpdate);\n\n\t // Update the hash\n\t this._process();\n\n\t // Chainable\n\t return this;\n\t },\n\n\t /**\n\t * Finalizes the hash computation.\n\t * Note that the finalize operation is effectively a destructive, read-once operation.\n\t *\n\t * @param {WordArray|string} messageUpdate (Optional) A final message update.\n\t *\n\t * @return {WordArray} The hash.\n\t *\n\t * @example\n\t *\n\t * var hash = hasher.finalize();\n\t * var hash = hasher.finalize('message');\n\t * var hash = hasher.finalize(wordArray);\n\t */\n\t finalize: function (messageUpdate) {\n\t // Final message update\n\t if (messageUpdate) {\n\t this._append(messageUpdate);\n\t }\n\n\t // Perform concrete-hasher logic\n\t var hash = this._doFinalize();\n\n\t return hash;\n\t },\n\n\t blockSize: 512/32,\n\n\t /**\n\t * Creates a shortcut function to a hasher's object interface.\n\t *\n\t * @param {Hasher} hasher The hasher to create a helper for.\n\t *\n\t * @return {Function} The shortcut function.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var SHA256 = CryptoJS.lib.Hasher._createHelper(CryptoJS.algo.SHA256);\n\t */\n\t _createHelper: function (hasher) {\n\t return function (message, cfg) {\n\t return new hasher.init(cfg).finalize(message);\n\t };\n\t },\n\n\t /**\n\t * Creates a shortcut function to the HMAC's object interface.\n\t *\n\t * @param {Hasher} hasher The hasher to use in this HMAC helper.\n\t *\n\t * @return {Function} The shortcut function.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var HmacSHA256 = CryptoJS.lib.Hasher._createHmacHelper(CryptoJS.algo.SHA256);\n\t */\n\t _createHmacHelper: function (hasher) {\n\t return function (message, key) {\n\t return new C_algo.HMAC.init(hasher, key).finalize(message);\n\t };\n\t }\n\t });\n\n\t /**\n\t * Algorithm namespace.\n\t */\n\t var C_algo = C.algo = {};\n\n\t return C;\n\t}(Math));\n\n\n\treturn CryptoJS;\n\n}));",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory(require(\"./core\"));\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([\"./core\"], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\tfactory(root.CryptoJS);\n\t}\n}(this, function (CryptoJS) {\n\n\t(function () {\n\t // Shortcuts\n\t var C = CryptoJS;\n\t var C_lib = C.lib;\n\t var WordArray = C_lib.WordArray;\n\t var C_enc = C.enc;\n\n\t /**\n\t * Base64url encoding strategy.\n\t */\n\t var Base64url = C_enc.Base64url = {\n\t /**\n\t * Converts a word array to a Base64url string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @param {boolean} urlSafe Whether to use url safe\n\t *\n\t * @return {string} The Base64url string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var base64String = CryptoJS.enc.Base64url.stringify(wordArray);\n\t */\n\t stringify: function (wordArray, urlSafe=true) {\n\t // Shortcuts\n\t var words = wordArray.words;\n\t var sigBytes = wordArray.sigBytes;\n\t var map = urlSafe ? this._safe_map : this._map;\n\n\t // Clamp excess bits\n\t wordArray.clamp();\n\n\t // Convert\n\t var base64Chars = [];\n\t for (var i = 0; i < sigBytes; i += 3) {\n\t var byte1 = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t var byte2 = (words[(i + 1) >>> 2] >>> (24 - ((i + 1) % 4) * 8)) & 0xff;\n\t var byte3 = (words[(i + 2) >>> 2] >>> (24 - ((i + 2) % 4) * 8)) & 0xff;\n\n\t var triplet = (byte1 << 16) | (byte2 << 8) | byte3;\n\n\t for (var j = 0; (j < 4) && (i + j * 0.75 < sigBytes); j++) {\n\t base64Chars.push(map.charAt((triplet >>> (6 * (3 - j))) & 0x3f));\n\t }\n\t }\n\n\t // Add padding\n\t var paddingChar = map.charAt(64);\n\t if (paddingChar) {\n\t while (base64Chars.length % 4) {\n\t base64Chars.push(paddingChar);\n\t }\n\t }\n\n\t return base64Chars.join('');\n\t },\n\n\t /**\n\t * Converts a Base64url string to a word array.\n\t *\n\t * @param {string} base64Str The Base64url string.\n\t *\n\t * @param {boolean} urlSafe Whether to use url safe\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Base64url.parse(base64String);\n\t */\n\t parse: function (base64Str, urlSafe=true) {\n\t // Shortcuts\n\t var base64StrLength = base64Str.length;\n\t var map = urlSafe ? this._safe_map : this._map;\n\t var reverseMap = this._reverseMap;\n\n\t if (!reverseMap) {\n\t reverseMap = this._reverseMap = [];\n\t for (var j = 0; j < map.length; j++) {\n\t reverseMap[map.charCodeAt(j)] = j;\n\t }\n\t }\n\n\t // Ignore padding\n\t var paddingChar = map.charAt(64);\n\t if (paddingChar) {\n\t var paddingIndex = base64Str.indexOf(paddingChar);\n\t if (paddingIndex !== -1) {\n\t base64StrLength = paddingIndex;\n\t }\n\t }\n\n\t // Convert\n\t return parseLoop(base64Str, base64StrLength, reverseMap);\n\n\t },\n\n\t _map: 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=',\n\t _safe_map: 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_',\n\t };\n\n\t function parseLoop(base64Str, base64StrLength, reverseMap) {\n\t var words = [];\n\t var nBytes = 0;\n\t for (var i = 0; i < base64StrLength; i++) {\n\t if (i % 4) {\n\t var bits1 = reverseMap[base64Str.charCodeAt(i - 1)] << ((i % 4) * 2);\n\t var bits2 = reverseMap[base64Str.charCodeAt(i)] >>> (6 - (i % 4) * 2);\n\t var bitsCombined = bits1 | bits2;\n\t words[nBytes >>> 2] |= bitsCombined << (24 - (nBytes % 4) * 8);\n\t nBytes++;\n\t }\n\t }\n\t return WordArray.create(words, nBytes);\n\t }\n\t}());\n\n\treturn CryptoJS.enc.Base64url;\n\n}));",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory(require(\"./core\"));\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([\"./core\"], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\tfactory(root.CryptoJS);\n\t}\n}(this, function (CryptoJS) {\n\n\t(function (Math) {\n\t // Shortcuts\n\t var C = CryptoJS;\n\t var C_lib = C.lib;\n\t var WordArray = C_lib.WordArray;\n\t var Hasher = C_lib.Hasher;\n\t var C_algo = C.algo;\n\n\t // Initialization and round constants tables\n\t var H = [];\n\t var K = [];\n\n\t // Compute constants\n\t (function () {\n\t function isPrime(n) {\n\t var sqrtN = Math.sqrt(n);\n\t for (var factor = 2; factor <= sqrtN; factor++) {\n\t if (!(n % factor)) {\n\t return false;\n\t }\n\t }\n\n\t return true;\n\t }\n\n\t function getFractionalBits(n) {\n\t return ((n - (n | 0)) * 0x100000000) | 0;\n\t }\n\n\t var n = 2;\n\t var nPrime = 0;\n\t while (nPrime < 64) {\n\t if (isPrime(n)) {\n\t if (nPrime < 8) {\n\t H[nPrime] = getFractionalBits(Math.pow(n, 1 / 2));\n\t }\n\t K[nPrime] = getFractionalBits(Math.pow(n, 1 / 3));\n\n\t nPrime++;\n\t }\n\n\t n++;\n\t }\n\t }());\n\n\t // Reusable object\n\t var W = [];\n\n\t /**\n\t * SHA-256 hash algorithm.\n\t */\n\t var SHA256 = C_algo.SHA256 = Hasher.extend({\n\t _doReset: function () {\n\t this._hash = new WordArray.init(H.slice(0));\n\t },\n\n\t _doProcessBlock: function (M, offset) {\n\t // Shortcut\n\t var H = this._hash.words;\n\n\t // Working variables\n\t var a = H[0];\n\t var b = H[1];\n\t var c = H[2];\n\t var d = H[3];\n\t var e = H[4];\n\t var f = H[5];\n\t var g = H[6];\n\t var h = H[7];\n\n\t // Computation\n\t for (var i = 0; i < 64; i++) {\n\t if (i < 16) {\n\t W[i] = M[offset + i] | 0;\n\t } else {\n\t var gamma0x = W[i - 15];\n\t var gamma0 = ((gamma0x << 25) | (gamma0x >>> 7)) ^\n\t ((gamma0x << 14) | (gamma0x >>> 18)) ^\n\t (gamma0x >>> 3);\n\n\t var gamma1x = W[i - 2];\n\t var gamma1 = ((gamma1x << 15) | (gamma1x >>> 17)) ^\n\t ((gamma1x << 13) | (gamma1x >>> 19)) ^\n\t (gamma1x >>> 10);\n\n\t W[i] = gamma0 + W[i - 7] + gamma1 + W[i - 16];\n\t }\n\n\t var ch = (e & f) ^ (~e & g);\n\t var maj = (a & b) ^ (a & c) ^ (b & c);\n\n\t var sigma0 = ((a << 30) | (a >>> 2)) ^ ((a << 19) | (a >>> 13)) ^ ((a << 10) | (a >>> 22));\n\t var sigma1 = ((e << 26) | (e >>> 6)) ^ ((e << 21) | (e >>> 11)) ^ ((e << 7) | (e >>> 25));\n\n\t var t1 = h + sigma1 + ch + K[i] + W[i];\n\t var t2 = sigma0 + maj;\n\n\t h = g;\n\t g = f;\n\t f = e;\n\t e = (d + t1) | 0;\n\t d = c;\n\t c = b;\n\t b = a;\n\t a = (t1 + t2) | 0;\n\t }\n\n\t // Intermediate hash value\n\t H[0] = (H[0] + a) | 0;\n\t H[1] = (H[1] + b) | 0;\n\t H[2] = (H[2] + c) | 0;\n\t H[3] = (H[3] + d) | 0;\n\t H[4] = (H[4] + e) | 0;\n\t H[5] = (H[5] + f) | 0;\n\t H[6] = (H[6] + g) | 0;\n\t H[7] = (H[7] + h) | 0;\n\t },\n\n\t _doFinalize: function () {\n\t // Shortcuts\n\t var data = this._data;\n\t var dataWords = data.words;\n\n\t var nBitsTotal = this._nDataBytes * 8;\n\t var nBitsLeft = data.sigBytes * 8;\n\n\t // Add padding\n\t dataWords[nBitsLeft >>> 5] |= 0x80 << (24 - nBitsLeft % 32);\n\t dataWords[(((nBitsLeft + 64) >>> 9) << 4) + 14] = Math.floor(nBitsTotal / 0x100000000);\n\t dataWords[(((nBitsLeft + 64) >>> 9) << 4) + 15] = nBitsTotal;\n\t data.sigBytes = dataWords.length * 4;\n\n\t // Hash final blocks\n\t this._process();\n\n\t // Return final computed hash\n\t return this._hash;\n\t },\n\n\t clone: function () {\n\t var clone = Hasher.clone.call(this);\n\t clone._hash = this._hash.clone();\n\n\t return clone;\n\t }\n\t });\n\n\t /**\n\t * Shortcut function to the hasher's object interface.\n\t *\n\t * @param {WordArray|string} message The message to hash.\n\t *\n\t * @return {WordArray} The hash.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hash = CryptoJS.SHA256('message');\n\t * var hash = CryptoJS.SHA256(wordArray);\n\t */\n\t C.SHA256 = Hasher._createHelper(SHA256);\n\n\t /**\n\t * Shortcut function to the HMAC's object interface.\n\t *\n\t * @param {WordArray|string} message The message to hash.\n\t * @param {WordArray|string} key The secret key.\n\t *\n\t * @return {WordArray} The HMAC.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hmac = CryptoJS.HmacSHA256(message, key);\n\t */\n\t C.HmacSHA256 = Hasher._createHmacHelper(SHA256);\n\t}(Math));\n\n\n\treturn CryptoJS.SHA256;\n\n}));",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory(require(\"./core\"));\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([\"./core\"], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\tfactory(root.CryptoJS);\n\t}\n}(this, function (CryptoJS) {\n\n\t(function () {\n\t // Check if typed arrays are supported\n\t if (typeof ArrayBuffer != 'function') {\n\t return;\n\t }\n\n\t // Shortcuts\n\t var C = CryptoJS;\n\t var C_lib = C.lib;\n\t var WordArray = C_lib.WordArray;\n\n\t // Reference original init\n\t var superInit = WordArray.init;\n\n\t // Augment WordArray.init to handle typed arrays\n\t var subInit = WordArray.init = function (typedArray) {\n\t // Convert buffers to uint8\n\t if (typedArray instanceof ArrayBuffer) {\n\t typedArray = new Uint8Array(typedArray);\n\t }\n\n\t // Convert other array views to uint8\n\t if (\n\t typedArray instanceof Int8Array ||\n\t (typeof Uint8ClampedArray !== \"undefined\" && typedArray instanceof Uint8ClampedArray) ||\n\t typedArray instanceof Int16Array ||\n\t typedArray instanceof Uint16Array ||\n\t typedArray instanceof Int32Array ||\n\t typedArray instanceof Uint32Array ||\n\t typedArray instanceof Float32Array ||\n\t typedArray instanceof Float64Array\n\t ) {\n\t typedArray = new Uint8Array(typedArray.buffer, typedArray.byteOffset, typedArray.byteLength);\n\t }\n\n\t // Handle Uint8Array\n\t if (typedArray instanceof Uint8Array) {\n\t // Shortcut\n\t var typedArrayByteLength = typedArray.byteLength;\n\n\t // Extract bytes\n\t var words = [];\n\t for (var i = 0; i < typedArrayByteLength; i++) {\n\t words[i >>> 2] |= typedArray[i] << (24 - (i % 4) * 8);\n\t }\n\n\t // Initialize this word array\n\t superInit.call(this, words, typedArrayByteLength);\n\t } else {\n\t // Else call normal init\n\t superInit.apply(this, arguments);\n\t }\n\t };\n\n\t subInit.prototype = WordArray;\n\t}());\n\n\n\treturn CryptoJS.lib.WordArray;\n\n}));","import { MONERIUM_CONFIG } from \"./config\";\nimport encodeBase64Url from \"crypto-js/enc-base64url\";\nimport SHA256 from \"crypto-js/sha256\";\nimport wordArray from \"crypto-js/lib-typedarrays\";\nimport type {\n AuthArgs,\n AuthCode,\n AuthContext,\n Balances,\n BearerProfile,\n ClientCredentials,\n Environment,\n LinkAddress,\n NewOrder,\n Order,\n OrderFilter,\n PKCERequest,\n PKCERequestArgs,\n Profile,\n RefreshToken,\n SupportingDoc,\n Token,\n} from \"./types\";\n// import pjson from \"../package.json\";\n\nexport class MoneriumClient {\n #env: Environment;\n #authPayload?: string;\n\n codeVerifier?: string;\n bearerProfile?: BearerProfile;\n\n constructor(env: \"production\" | \"sandbox\" = \"sandbox\") {\n this.#env = MONERIUM_CONFIG.environments[env];\n }\n\n // -- Authentication\n\n async auth(args: AuthArgs) {\n let params: AuthCode | RefreshToken | ClientCredentials;\n\n if (this.#isAuthCode(args)) {\n params = { ...args, grant_type: \"authorization_code\" };\n } else if (this.#isRefreshToken(args)) {\n params = { ...args, grant_type: \"refresh_token\" };\n } else if (this.#isClientCredentials(args)) {\n params = { ...args, grant_type: \"client_credentials\" };\n } else {\n throw new Error(\"Authentication method could not be detected.\");\n }\n\n this.bearerProfile = (await this.#api(\n \"post\",\n `auth/token`,\n new URLSearchParams(params as unknown as Record<string, string>),\n true\n )) as BearerProfile;\n\n this.#authPayload = `Bearer ${this.bearerProfile.access_token}`;\n }\n\n pkceRequest(args: PKCERequestArgs): string {\n // this.codeVerifier = CryptoJS.lib.WordArray.random(64).toString();\n // const challenge = CryptoJS.enc.Base64url.stringify(\n // CryptoJS.SHA256(this.codeVerifier)\n // );\n this.codeVerifier = wordArray.random(64).toString();\n const challenge = encodeBase64Url.stringify(SHA256(this.codeVerifier));\n\n const params: PKCERequest = {\n ...args,\n code_challenge: challenge,\n code_challenge_method: \"S256\",\n response_type: \"code\",\n };\n\n return `${this.#env.api}/auth?${new URLSearchParams(params)}`;\n }\n\n // -- Read Methods\n\n getAuthContext(): Promise<AuthContext> {\n return this.#api(\"get\", `auth/context`) as Promise<AuthContext>;\n }\n\n getProfile(profileId: string): Promise<Profile> {\n return this.#api(\"get\", `profiles/${profileId}`) as Promise<Profile>;\n }\n\n getBalances(profileId?: string): Promise<Balances> | Promise<Balances[]> {\n if (profileId) {\n return this.#api(\n \"get\",\n `profiles/${profileId}/balances`\n ) as Promise<Balances>;\n } else {\n return this.#api(\"get\", `balances`) as Promise<Balances[]>;\n }\n }\n\n getOrders(filter?: OrderFilter): Promise<Order[]> {\n const searchParams = new URLSearchParams(\n filter as unknown as Record<string, string>\n );\n\n return this.#api(\"get\", `orders?${searchParams}`) as Promise<Order[]>;\n }\n\n getOrder(orderId: string): Promise<Order> {\n return this.#api(\"get\", `orders/${orderId}`) as Promise<Order>;\n }\n\n getTokens(): Promise<Token[]> {\n return this.#api(\"get\", \"tokens\") as Promise<Token[]>;\n }\n\n // -- Write Methods\n\n linkAddress(profileId: string, body: LinkAddress) {\n return this.#api(\n \"post\",\n `profiles/${profileId}/addresses`,\n JSON.stringify(body)\n );\n }\n\n placeOrder(order: NewOrder, profileId?: string): Promise<Order> {\n if (profileId) {\n return this.#api(\n \"post\",\n `profiles/${profileId}/orders`,\n JSON.stringify(order)\n ) as Promise<Order>;\n } else {\n return this.#api(\n \"post\",\n `orders`,\n JSON.stringify(order)\n ) as Promise<Order>;\n }\n }\n\n uploadSupportingDocument(document: File): Promise<SupportingDoc> {\n const searchParams = new URLSearchParams(\n document as unknown as Record<string, string>\n );\n\n return this.#api(\n \"post\",\n \"files/supporting-document\",\n searchParams,\n true\n ) as Promise<SupportingDoc>;\n }\n\n // -- Helper Methods\n\n async #api(\n method: string,\n resource: string,\n body?: BodyInit,\n isFormEncoded?: boolean\n ) {\n const res = await fetch(`${this.#env.api}/${resource}`, {\n method,\n headers: {\n \"Content-Type\": `application/${\n isFormEncoded ? \"x-www-form-urlencoded\" : \"json\"\n }`,\n Authorization: this.#authPayload || \"\",\n // \"User-Agent\": \"sdk/\" + pjson.version,\n },\n body,\n });\n\n const response = await res.json();\n\n if (res.ok) {\n return response;\n } else {\n throw response;\n }\n }\n\n #isAuthCode(args: AuthArgs): args is AuthCode {\n return (args as AuthCode).code != undefined;\n }\n\n #isRefreshToken(args: AuthArgs): args is RefreshToken {\n return (args as RefreshToken).refresh_token != undefined;\n }\n\n #isClientCredentials(args: AuthArgs): args is ClientCredentials {\n return (args as ClientCredentials).client_secret != undefined;\n }\n}\n","// --- Config --- //\n\nexport type Environment = { api: string; web: string };\n\nexport type Config = {\n environments: { production: Environment; sandbox: Environment };\n};\n\n// --- Client Variables --- //\n\nexport interface BearerProfile {\n access_token: string;\n token_type: string;\n expires_in: number;\n refresh_token: string;\n profile: string;\n userId: string;\n}\n\n// --- Client Methods --- //\n\nexport enum Currency {\n eur = \"eur\",\n usd = \"usd\",\n gbp = \"gbp\",\n isk = \"isk\",\n}\n\n// -- auth\n\nexport type AuthArgs =\n | Omit<AuthCode, \"grant_type\">\n | Omit<RefreshToken, \"grant_type\">\n | Omit<ClientCredentials, \"grant_type\">;\n\nexport interface AuthCode {\n grant_type: \"authorization_code\";\n client_id: string;\n code: string;\n code_verifier: string;\n redirect_uri: string;\n scope?: string;\n}\n\nexport interface RefreshToken {\n grant_type: \"refresh_token\";\n client_id: string;\n refresh_token: string;\n scope?: string;\n}\n\nexport interface ClientCredentials {\n grant_type: \"client_credentials\";\n client_id: string;\n client_secret: string;\n scope?: string;\n}\n\n// -- pkceRequest\n\nexport type PKCERequestArgs = Omit<\n PKCERequest,\n \"code_challenge\" | \"code_challenge_method\" | \"response_type\"\n>;\n\nexport type PKCERequest = {\n client_id: string;\n code_challenge: string;\n code_challenge_method: string;\n response_type: string;\n state: string;\n redirect_uri?: string;\n scope?: string;\n address?: string;\n};\n\n// -- authContext\n\nenum Method {\n password = \"password\",\n resource = \"resource\",\n jwt = \"jwt\",\n apiKey = \"apiKey\",\n}\n\nexport enum ProfileType {\n corporate = \"corporate\",\n personal = \"personal\",\n}\n\nexport enum Permission {\n read = \"read\",\n write = \"write\",\n}\n\nexport interface AuthProfile {\n id: string;\n type: ProfileType;\n name: string;\n perms: Permission[];\n}\n\nexport interface AuthContext {\n userId: string;\n email: string;\n name: string;\n roles: \"admin\"[];\n auth: { method: Method; subject: string; verified: boolean };\n defaultProfile: string;\n profiles: AuthProfile[];\n}\n\n// -- getProfile\n\nexport enum KYCState {\n absent = \"absent\",\n submitted = \"submitted\",\n pending = \"pending\",\n confirmed = \"confirmed\",\n}\n\nexport enum KYCOutcome {\n approved = \"approved\",\n rejected = \"rejected\",\n unknown = \"unknown\",\n}\n\nexport interface KYC {\n state: KYCState;\n outcome: KYCOutcome;\n}\n\nexport enum PaymentStandard {\n iban = \"iban\",\n scan = \"scan\",\n}\n\nexport interface Account {\n address: string;\n currency: Currency;\n standard: PaymentStandard;\n iban?: string;\n sortCode?: string;\n accountNumber?: string;\n network: Network;\n chain: Chain;\n id?: string;\n}\n\nexport interface Profile {\n id: string;\n name: string;\n kyc: KYC;\n accounts: Account[];\n}\n\n// -- getBalances\n\nexport enum Chain {\n polygon = \"polygon\",\n ethereum = \"ethereum\",\n gnosis = \"gnosis\",\n}\n\nexport enum Network {\n mainnet = \"mainnet\",\n chiado = \"chiado\",\n goerli = \"goerli\",\n mumbai = \"mumbai\",\n}\n\nexport interface Balance {\n currency: Currency;\n amount: string;\n}\n\nexport interface Balances {\n id: string;\n address: string;\n chain: Chain;\n network: Network;\n balances: Balance[];\n}\n\n// --getOrders\n\nexport enum OrderKind {\n redeem = \"redeem\",\n issue = \"issue\",\n}\n\nexport enum OrderState {\n placed = \"placed\",\n pending = \"pending\",\n processed = \"processed\",\n rejected = \"rejected\",\n}\n\nexport interface Fee {\n provider: \"satchel\";\n currency: Currency;\n amount: string;\n}\n\nexport interface IBAN {\n standard: PaymentStandard.iban;\n iban: string;\n}\n\nexport interface SCAN {\n standard: PaymentStandard.scan;\n sortCode: string;\n accountNumber: string;\n}\n\nexport interface Individual {\n firstName: string;\n lastName: string;\n country?: string;\n}\n\nexport interface Corporation {\n companyName: string;\n country: string;\n}\n\nexport interface Counterpart {\n identifier: IBAN | SCAN;\n details: Individual | Corporation;\n}\n\nexport interface OrderMetadata {\n approvedAt: string;\n processedAt: string;\n rejectedAt: string;\n state: OrderState;\n placedBy: string;\n placedAt: string;\n receivedAmount: string;\n sentAmount: string;\n}\n\nexport interface OrderFilter {\n address?: string;\n txHash?: string;\n profile?: string;\n memo?: string;\n accountId?: string;\n state?: OrderState;\n}\n\nexport interface Order {\n id: string;\n profile: string;\n accountId: string;\n address: string;\n kind: OrderKind;\n amount: string;\n currency: Currency;\n totalFee: string;\n fees: Fee[];\n counterpart: Counterpart;\n memo: string;\n rejectedReason: string;\n supportingDocumentId: string;\n meta: OrderMetadata;\n}\n\n// -- getTokens\n\nexport interface Token {\n currency: Currency;\n ticker: string;\n symbol: string;\n chain: Chain;\n network: Network;\n address: string;\n decimals: number;\n}\n\n// --placeOrder\n\nexport interface NewOrder {\n kind: OrderKind;\n amount: string;\n signature: string;\n accountId?: string;\n address: string;\n currency: Currency;\n counterpart: Counterpart;\n message: string;\n memo: string;\n supportingDocumentId?: string;\n chain: Chain;\n network: Network;\n}\n\n// -- uploadSupportingDocument\n\nexport interface SupportingDocMetadata {\n uploadedBy: string;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface SupportingDoc {\n id: string;\n name: string;\n type: string;\n size: number;\n hash: string;\n meta: SupportingDocMetadata;\n}\n\n// -- linkAddress\n\nexport interface CurrencyAccounts {\n network: Network;\n chain: Chain;\n currency: Currency;\n}\n\nexport interface LinkAddress {\n address: string;\n message: string;\n signature: string;\n accounts: CurrencyAccounts[];\n}\n"],"names":["MONERIUM_CONFIG","__viteBrowserExternal","root","factory","module","this","CryptoJS","Math","undefined","crypto","global","require","require$$0","cryptoSecureRandomInt","create","F","obj","subtype","C","C_lib","Base","overrides","instance","properties","propertyName","WordArray","words","sigBytes","encoder","Hex","wordArray","thisWords","thatWords","thisSigBytes","thatSigBytes","i","thatByte","j","clone","nBytes","C_enc","hexChars","bite","hexStr","hexStrLength","Latin1","latin1Chars","latin1Str","latin1StrLength","Utf8","utf8Str","BufferedBlockAlgorithm","data","doFlush","processedWords","dataWords","dataSigBytes","blockSize","blockSizeBytes","nBlocksReady","nWordsReady","nBytesReady","offset","cfg","messageUpdate","hash","hasher","message","key","C_algo","urlSafe","map","base64Chars","byte1","byte2","byte3","triplet","paddingChar","base64Str","base64StrLength","reverseMap","paddingIndex","parseLoop","bits1","bits2","bitsCombined","Hasher","H","K","isPrime","n","sqrtN","factor","getFractionalBits","nPrime","W","SHA256","M","a","b","c","d","e","f","h","gamma0x","gamma0","gamma1x","gamma1","ch","maj","sigma0","sigma1","t1","t2","nBitsTotal","nBitsLeft","superInit","subInit","typedArray","typedArrayByteLength","_env","_authPayload","_api","api_fn","_isAuthCode","isAuthCode_fn","_isRefreshToken","isRefreshToken_fn","_isClientCredentials","isClientCredentials_fn","MoneriumClient","env","__privateAdd","__publicField","__privateSet","args","params","__privateMethod","challenge","encodeBase64Url","__privateGet","profileId","filter","searchParams","orderId","body","order","document","method","resource","isFormEncoded","res","response","Currency","ProfileType","Permission","KYCState","KYCOutcome","PaymentStandard","Chain","Network","OrderKind","OrderState"],"mappings":";;;;;;;;;;;;AAEA,MAAMA,KAA0B;AAAA,EAC9B,cAAc;AAAA,IACZ,YAAY;AAAA,MACV,KAAK;AAAA,MACL,KAAK;AAAA,IACP;AAAA,IACA,SAAS;AAAA,MACP,KAAK;AAA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AAA,UAAU,WACVA,EAAA,SAAS,UACTA,EAAA,SAAS,UACTA,EAAA,SAAS,UAJCA,IAAAA,MAAA,CAAA,CAAA,GAsBAC,uBAAAA,OACVA,EAAA,SAAS,UACTA,EAAA,QAAQ,SAFEA,IAAAA,MAAA,CAAA,CAAA,GAKAC,uBAAAA,OACVA,EAAA,SAAS,UACTA,EAAA,UAAU,WACVA,EAAA,YAAY,aACZA,EAAA,WAAW,YAJDA,IAAAA,MAAA,CAAA,CAAA;"}
|
|
1
|
+
{"version":3,"file":"index.es.js","sources":["../__vite-browser-external","../node_modules/crypto-js/core.js","../node_modules/crypto-js/enc-base64url.js","../node_modules/crypto-js/lib-typedarrays.js","../node_modules/crypto-js/sha256.js","../src/config.ts","../src/client.ts","../src/types.ts"],"sourcesContent":["export default {}",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory();\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\troot.CryptoJS = factory();\n\t}\n}(this, function () {\n\n\t/*globals window, global, require*/\n\n\t/**\n\t * CryptoJS core components.\n\t */\n\tvar CryptoJS = CryptoJS || (function (Math, undefined) {\n\n\t var crypto;\n\n\t // Native crypto from window (Browser)\n\t if (typeof window !== 'undefined' && window.crypto) {\n\t crypto = window.crypto;\n\t }\n\n\t // Native crypto in web worker (Browser)\n\t if (typeof self !== 'undefined' && self.crypto) {\n\t crypto = self.crypto;\n\t }\n\n\t // Native crypto from worker\n\t if (typeof globalThis !== 'undefined' && globalThis.crypto) {\n\t crypto = globalThis.crypto;\n\t }\n\n\t // Native (experimental IE 11) crypto from window (Browser)\n\t if (!crypto && typeof window !== 'undefined' && window.msCrypto) {\n\t crypto = window.msCrypto;\n\t }\n\n\t // Native crypto from global (NodeJS)\n\t if (!crypto && typeof global !== 'undefined' && global.crypto) {\n\t crypto = global.crypto;\n\t }\n\n\t // Native crypto import via require (NodeJS)\n\t if (!crypto && typeof require === 'function') {\n\t try {\n\t crypto = require('crypto');\n\t } catch (err) {}\n\t }\n\n\t /*\n\t * Cryptographically secure pseudorandom number generator\n\t *\n\t * As Math.random() is cryptographically not safe to use\n\t */\n\t var cryptoSecureRandomInt = function () {\n\t if (crypto) {\n\t // Use getRandomValues method (Browser)\n\t if (typeof crypto.getRandomValues === 'function') {\n\t try {\n\t return crypto.getRandomValues(new Uint32Array(1))[0];\n\t } catch (err) {}\n\t }\n\n\t // Use randomBytes method (NodeJS)\n\t if (typeof crypto.randomBytes === 'function') {\n\t try {\n\t return crypto.randomBytes(4).readInt32LE();\n\t } catch (err) {}\n\t }\n\t }\n\n\t throw new Error('Native crypto module could not be used to get secure random number.');\n\t };\n\n\t /*\n\t * Local polyfill of Object.create\n\n\t */\n\t var create = Object.create || (function () {\n\t function F() {}\n\n\t return function (obj) {\n\t var subtype;\n\n\t F.prototype = obj;\n\n\t subtype = new F();\n\n\t F.prototype = null;\n\n\t return subtype;\n\t };\n\t }());\n\n\t /**\n\t * CryptoJS namespace.\n\t */\n\t var C = {};\n\n\t /**\n\t * Library namespace.\n\t */\n\t var C_lib = C.lib = {};\n\n\t /**\n\t * Base object for prototypal inheritance.\n\t */\n\t var Base = C_lib.Base = (function () {\n\n\n\t return {\n\t /**\n\t * Creates a new object that inherits from this object.\n\t *\n\t * @param {Object} overrides Properties to copy into the new object.\n\t *\n\t * @return {Object} The new object.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var MyType = CryptoJS.lib.Base.extend({\n\t * field: 'value',\n\t *\n\t * method: function () {\n\t * }\n\t * });\n\t */\n\t extend: function (overrides) {\n\t // Spawn\n\t var subtype = create(this);\n\n\t // Augment\n\t if (overrides) {\n\t subtype.mixIn(overrides);\n\t }\n\n\t // Create default initializer\n\t if (!subtype.hasOwnProperty('init') || this.init === subtype.init) {\n\t subtype.init = function () {\n\t subtype.$super.init.apply(this, arguments);\n\t };\n\t }\n\n\t // Initializer's prototype is the subtype object\n\t subtype.init.prototype = subtype;\n\n\t // Reference supertype\n\t subtype.$super = this;\n\n\t return subtype;\n\t },\n\n\t /**\n\t * Extends this object and runs the init method.\n\t * Arguments to create() will be passed to init().\n\t *\n\t * @return {Object} The new object.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var instance = MyType.create();\n\t */\n\t create: function () {\n\t var instance = this.extend();\n\t instance.init.apply(instance, arguments);\n\n\t return instance;\n\t },\n\n\t /**\n\t * Initializes a newly created object.\n\t * Override this method to add some logic when your objects are created.\n\t *\n\t * @example\n\t *\n\t * var MyType = CryptoJS.lib.Base.extend({\n\t * init: function () {\n\t * // ...\n\t * }\n\t * });\n\t */\n\t init: function () {\n\t },\n\n\t /**\n\t * Copies properties into this object.\n\t *\n\t * @param {Object} properties The properties to mix in.\n\t *\n\t * @example\n\t *\n\t * MyType.mixIn({\n\t * field: 'value'\n\t * });\n\t */\n\t mixIn: function (properties) {\n\t for (var propertyName in properties) {\n\t if (properties.hasOwnProperty(propertyName)) {\n\t this[propertyName] = properties[propertyName];\n\t }\n\t }\n\n\t // IE won't copy toString using the loop above\n\t if (properties.hasOwnProperty('toString')) {\n\t this.toString = properties.toString;\n\t }\n\t },\n\n\t /**\n\t * Creates a copy of this object.\n\t *\n\t * @return {Object} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = instance.clone();\n\t */\n\t clone: function () {\n\t return this.init.prototype.extend(this);\n\t }\n\t };\n\t }());\n\n\t /**\n\t * An array of 32-bit words.\n\t *\n\t * @property {Array} words The array of 32-bit words.\n\t * @property {number} sigBytes The number of significant bytes in this word array.\n\t */\n\t var WordArray = C_lib.WordArray = Base.extend({\n\t /**\n\t * Initializes a newly created word array.\n\t *\n\t * @param {Array} words (Optional) An array of 32-bit words.\n\t * @param {number} sigBytes (Optional) The number of significant bytes in the words.\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.lib.WordArray.create();\n\t * var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607]);\n\t * var wordArray = CryptoJS.lib.WordArray.create([0x00010203, 0x04050607], 6);\n\t */\n\t init: function (words, sigBytes) {\n\t words = this.words = words || [];\n\n\t if (sigBytes != undefined) {\n\t this.sigBytes = sigBytes;\n\t } else {\n\t this.sigBytes = words.length * 4;\n\t }\n\t },\n\n\t /**\n\t * Converts this word array to a string.\n\t *\n\t * @param {Encoder} encoder (Optional) The encoding strategy to use. Default: CryptoJS.enc.Hex\n\t *\n\t * @return {string} The stringified word array.\n\t *\n\t * @example\n\t *\n\t * var string = wordArray + '';\n\t * var string = wordArray.toString();\n\t * var string = wordArray.toString(CryptoJS.enc.Utf8);\n\t */\n\t toString: function (encoder) {\n\t return (encoder || Hex).stringify(this);\n\t },\n\n\t /**\n\t * Concatenates a word array to this word array.\n\t *\n\t * @param {WordArray} wordArray The word array to append.\n\t *\n\t * @return {WordArray} This word array.\n\t *\n\t * @example\n\t *\n\t * wordArray1.concat(wordArray2);\n\t */\n\t concat: function (wordArray) {\n\t // Shortcuts\n\t var thisWords = this.words;\n\t var thatWords = wordArray.words;\n\t var thisSigBytes = this.sigBytes;\n\t var thatSigBytes = wordArray.sigBytes;\n\n\t // Clamp excess bits\n\t this.clamp();\n\n\t // Concat\n\t if (thisSigBytes % 4) {\n\t // Copy one byte at a time\n\t for (var i = 0; i < thatSigBytes; i++) {\n\t var thatByte = (thatWords[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t thisWords[(thisSigBytes + i) >>> 2] |= thatByte << (24 - ((thisSigBytes + i) % 4) * 8);\n\t }\n\t } else {\n\t // Copy one word at a time\n\t for (var j = 0; j < thatSigBytes; j += 4) {\n\t thisWords[(thisSigBytes + j) >>> 2] = thatWords[j >>> 2];\n\t }\n\t }\n\t this.sigBytes += thatSigBytes;\n\n\t // Chainable\n\t return this;\n\t },\n\n\t /**\n\t * Removes insignificant bits.\n\t *\n\t * @example\n\t *\n\t * wordArray.clamp();\n\t */\n\t clamp: function () {\n\t // Shortcuts\n\t var words = this.words;\n\t var sigBytes = this.sigBytes;\n\n\t // Clamp\n\t words[sigBytes >>> 2] &= 0xffffffff << (32 - (sigBytes % 4) * 8);\n\t words.length = Math.ceil(sigBytes / 4);\n\t },\n\n\t /**\n\t * Creates a copy of this word array.\n\t *\n\t * @return {WordArray} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = wordArray.clone();\n\t */\n\t clone: function () {\n\t var clone = Base.clone.call(this);\n\t clone.words = this.words.slice(0);\n\n\t return clone;\n\t },\n\n\t /**\n\t * Creates a word array filled with random bytes.\n\t *\n\t * @param {number} nBytes The number of random bytes to generate.\n\t *\n\t * @return {WordArray} The random word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.lib.WordArray.random(16);\n\t */\n\t random: function (nBytes) {\n\t var words = [];\n\n\t for (var i = 0; i < nBytes; i += 4) {\n\t words.push(cryptoSecureRandomInt());\n\t }\n\n\t return new WordArray.init(words, nBytes);\n\t }\n\t });\n\n\t /**\n\t * Encoder namespace.\n\t */\n\t var C_enc = C.enc = {};\n\n\t /**\n\t * Hex encoding strategy.\n\t */\n\t var Hex = C_enc.Hex = {\n\t /**\n\t * Converts a word array to a hex string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The hex string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hexString = CryptoJS.enc.Hex.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t // Shortcuts\n\t var words = wordArray.words;\n\t var sigBytes = wordArray.sigBytes;\n\n\t // Convert\n\t var hexChars = [];\n\t for (var i = 0; i < sigBytes; i++) {\n\t var bite = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t hexChars.push((bite >>> 4).toString(16));\n\t hexChars.push((bite & 0x0f).toString(16));\n\t }\n\n\t return hexChars.join('');\n\t },\n\n\t /**\n\t * Converts a hex string to a word array.\n\t *\n\t * @param {string} hexStr The hex string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Hex.parse(hexString);\n\t */\n\t parse: function (hexStr) {\n\t // Shortcut\n\t var hexStrLength = hexStr.length;\n\n\t // Convert\n\t var words = [];\n\t for (var i = 0; i < hexStrLength; i += 2) {\n\t words[i >>> 3] |= parseInt(hexStr.substr(i, 2), 16) << (24 - (i % 8) * 4);\n\t }\n\n\t return new WordArray.init(words, hexStrLength / 2);\n\t }\n\t };\n\n\t /**\n\t * Latin1 encoding strategy.\n\t */\n\t var Latin1 = C_enc.Latin1 = {\n\t /**\n\t * Converts a word array to a Latin1 string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The Latin1 string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var latin1String = CryptoJS.enc.Latin1.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t // Shortcuts\n\t var words = wordArray.words;\n\t var sigBytes = wordArray.sigBytes;\n\n\t // Convert\n\t var latin1Chars = [];\n\t for (var i = 0; i < sigBytes; i++) {\n\t var bite = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t latin1Chars.push(String.fromCharCode(bite));\n\t }\n\n\t return latin1Chars.join('');\n\t },\n\n\t /**\n\t * Converts a Latin1 string to a word array.\n\t *\n\t * @param {string} latin1Str The Latin1 string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Latin1.parse(latin1String);\n\t */\n\t parse: function (latin1Str) {\n\t // Shortcut\n\t var latin1StrLength = latin1Str.length;\n\n\t // Convert\n\t var words = [];\n\t for (var i = 0; i < latin1StrLength; i++) {\n\t words[i >>> 2] |= (latin1Str.charCodeAt(i) & 0xff) << (24 - (i % 4) * 8);\n\t }\n\n\t return new WordArray.init(words, latin1StrLength);\n\t }\n\t };\n\n\t /**\n\t * UTF-8 encoding strategy.\n\t */\n\t var Utf8 = C_enc.Utf8 = {\n\t /**\n\t * Converts a word array to a UTF-8 string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @return {string} The UTF-8 string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var utf8String = CryptoJS.enc.Utf8.stringify(wordArray);\n\t */\n\t stringify: function (wordArray) {\n\t try {\n\t return decodeURIComponent(escape(Latin1.stringify(wordArray)));\n\t } catch (e) {\n\t throw new Error('Malformed UTF-8 data');\n\t }\n\t },\n\n\t /**\n\t * Converts a UTF-8 string to a word array.\n\t *\n\t * @param {string} utf8Str The UTF-8 string.\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Utf8.parse(utf8String);\n\t */\n\t parse: function (utf8Str) {\n\t return Latin1.parse(unescape(encodeURIComponent(utf8Str)));\n\t }\n\t };\n\n\t /**\n\t * Abstract buffered block algorithm template.\n\t *\n\t * The property blockSize must be implemented in a concrete subtype.\n\t *\n\t * @property {number} _minBufferSize The number of blocks that should be kept unprocessed in the buffer. Default: 0\n\t */\n\t var BufferedBlockAlgorithm = C_lib.BufferedBlockAlgorithm = Base.extend({\n\t /**\n\t * Resets this block algorithm's data buffer to its initial state.\n\t *\n\t * @example\n\t *\n\t * bufferedBlockAlgorithm.reset();\n\t */\n\t reset: function () {\n\t // Initial values\n\t this._data = new WordArray.init();\n\t this._nDataBytes = 0;\n\t },\n\n\t /**\n\t * Adds new data to this block algorithm's buffer.\n\t *\n\t * @param {WordArray|string} data The data to append. Strings are converted to a WordArray using UTF-8.\n\t *\n\t * @example\n\t *\n\t * bufferedBlockAlgorithm._append('data');\n\t * bufferedBlockAlgorithm._append(wordArray);\n\t */\n\t _append: function (data) {\n\t // Convert string to WordArray, else assume WordArray already\n\t if (typeof data == 'string') {\n\t data = Utf8.parse(data);\n\t }\n\n\t // Append\n\t this._data.concat(data);\n\t this._nDataBytes += data.sigBytes;\n\t },\n\n\t /**\n\t * Processes available data blocks.\n\t *\n\t * This method invokes _doProcessBlock(offset), which must be implemented by a concrete subtype.\n\t *\n\t * @param {boolean} doFlush Whether all blocks and partial blocks should be processed.\n\t *\n\t * @return {WordArray} The processed data.\n\t *\n\t * @example\n\t *\n\t * var processedData = bufferedBlockAlgorithm._process();\n\t * var processedData = bufferedBlockAlgorithm._process(!!'flush');\n\t */\n\t _process: function (doFlush) {\n\t var processedWords;\n\n\t // Shortcuts\n\t var data = this._data;\n\t var dataWords = data.words;\n\t var dataSigBytes = data.sigBytes;\n\t var blockSize = this.blockSize;\n\t var blockSizeBytes = blockSize * 4;\n\n\t // Count blocks ready\n\t var nBlocksReady = dataSigBytes / blockSizeBytes;\n\t if (doFlush) {\n\t // Round up to include partial blocks\n\t nBlocksReady = Math.ceil(nBlocksReady);\n\t } else {\n\t // Round down to include only full blocks,\n\t // less the number of blocks that must remain in the buffer\n\t nBlocksReady = Math.max((nBlocksReady | 0) - this._minBufferSize, 0);\n\t }\n\n\t // Count words ready\n\t var nWordsReady = nBlocksReady * blockSize;\n\n\t // Count bytes ready\n\t var nBytesReady = Math.min(nWordsReady * 4, dataSigBytes);\n\n\t // Process blocks\n\t if (nWordsReady) {\n\t for (var offset = 0; offset < nWordsReady; offset += blockSize) {\n\t // Perform concrete-algorithm logic\n\t this._doProcessBlock(dataWords, offset);\n\t }\n\n\t // Remove processed words\n\t processedWords = dataWords.splice(0, nWordsReady);\n\t data.sigBytes -= nBytesReady;\n\t }\n\n\t // Return processed words\n\t return new WordArray.init(processedWords, nBytesReady);\n\t },\n\n\t /**\n\t * Creates a copy of this object.\n\t *\n\t * @return {Object} The clone.\n\t *\n\t * @example\n\t *\n\t * var clone = bufferedBlockAlgorithm.clone();\n\t */\n\t clone: function () {\n\t var clone = Base.clone.call(this);\n\t clone._data = this._data.clone();\n\n\t return clone;\n\t },\n\n\t _minBufferSize: 0\n\t });\n\n\t /**\n\t * Abstract hasher template.\n\t *\n\t * @property {number} blockSize The number of 32-bit words this hasher operates on. Default: 16 (512 bits)\n\t */\n\t var Hasher = C_lib.Hasher = BufferedBlockAlgorithm.extend({\n\t /**\n\t * Configuration options.\n\t */\n\t cfg: Base.extend(),\n\n\t /**\n\t * Initializes a newly created hasher.\n\t *\n\t * @param {Object} cfg (Optional) The configuration options to use for this hash computation.\n\t *\n\t * @example\n\t *\n\t * var hasher = CryptoJS.algo.SHA256.create();\n\t */\n\t init: function (cfg) {\n\t // Apply config defaults\n\t this.cfg = this.cfg.extend(cfg);\n\n\t // Set initial values\n\t this.reset();\n\t },\n\n\t /**\n\t * Resets this hasher to its initial state.\n\t *\n\t * @example\n\t *\n\t * hasher.reset();\n\t */\n\t reset: function () {\n\t // Reset data buffer\n\t BufferedBlockAlgorithm.reset.call(this);\n\n\t // Perform concrete-hasher logic\n\t this._doReset();\n\t },\n\n\t /**\n\t * Updates this hasher with a message.\n\t *\n\t * @param {WordArray|string} messageUpdate The message to append.\n\t *\n\t * @return {Hasher} This hasher.\n\t *\n\t * @example\n\t *\n\t * hasher.update('message');\n\t * hasher.update(wordArray);\n\t */\n\t update: function (messageUpdate) {\n\t // Append\n\t this._append(messageUpdate);\n\n\t // Update the hash\n\t this._process();\n\n\t // Chainable\n\t return this;\n\t },\n\n\t /**\n\t * Finalizes the hash computation.\n\t * Note that the finalize operation is effectively a destructive, read-once operation.\n\t *\n\t * @param {WordArray|string} messageUpdate (Optional) A final message update.\n\t *\n\t * @return {WordArray} The hash.\n\t *\n\t * @example\n\t *\n\t * var hash = hasher.finalize();\n\t * var hash = hasher.finalize('message');\n\t * var hash = hasher.finalize(wordArray);\n\t */\n\t finalize: function (messageUpdate) {\n\t // Final message update\n\t if (messageUpdate) {\n\t this._append(messageUpdate);\n\t }\n\n\t // Perform concrete-hasher logic\n\t var hash = this._doFinalize();\n\n\t return hash;\n\t },\n\n\t blockSize: 512/32,\n\n\t /**\n\t * Creates a shortcut function to a hasher's object interface.\n\t *\n\t * @param {Hasher} hasher The hasher to create a helper for.\n\t *\n\t * @return {Function} The shortcut function.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var SHA256 = CryptoJS.lib.Hasher._createHelper(CryptoJS.algo.SHA256);\n\t */\n\t _createHelper: function (hasher) {\n\t return function (message, cfg) {\n\t return new hasher.init(cfg).finalize(message);\n\t };\n\t },\n\n\t /**\n\t * Creates a shortcut function to the HMAC's object interface.\n\t *\n\t * @param {Hasher} hasher The hasher to use in this HMAC helper.\n\t *\n\t * @return {Function} The shortcut function.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var HmacSHA256 = CryptoJS.lib.Hasher._createHmacHelper(CryptoJS.algo.SHA256);\n\t */\n\t _createHmacHelper: function (hasher) {\n\t return function (message, key) {\n\t return new C_algo.HMAC.init(hasher, key).finalize(message);\n\t };\n\t }\n\t });\n\n\t /**\n\t * Algorithm namespace.\n\t */\n\t var C_algo = C.algo = {};\n\n\t return C;\n\t}(Math));\n\n\n\treturn CryptoJS;\n\n}));",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory(require(\"./core\"));\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([\"./core\"], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\tfactory(root.CryptoJS);\n\t}\n}(this, function (CryptoJS) {\n\n\t(function () {\n\t // Shortcuts\n\t var C = CryptoJS;\n\t var C_lib = C.lib;\n\t var WordArray = C_lib.WordArray;\n\t var C_enc = C.enc;\n\n\t /**\n\t * Base64url encoding strategy.\n\t */\n\t var Base64url = C_enc.Base64url = {\n\t /**\n\t * Converts a word array to a Base64url string.\n\t *\n\t * @param {WordArray} wordArray The word array.\n\t *\n\t * @param {boolean} urlSafe Whether to use url safe\n\t *\n\t * @return {string} The Base64url string.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var base64String = CryptoJS.enc.Base64url.stringify(wordArray);\n\t */\n\t stringify: function (wordArray, urlSafe=true) {\n\t // Shortcuts\n\t var words = wordArray.words;\n\t var sigBytes = wordArray.sigBytes;\n\t var map = urlSafe ? this._safe_map : this._map;\n\n\t // Clamp excess bits\n\t wordArray.clamp();\n\n\t // Convert\n\t var base64Chars = [];\n\t for (var i = 0; i < sigBytes; i += 3) {\n\t var byte1 = (words[i >>> 2] >>> (24 - (i % 4) * 8)) & 0xff;\n\t var byte2 = (words[(i + 1) >>> 2] >>> (24 - ((i + 1) % 4) * 8)) & 0xff;\n\t var byte3 = (words[(i + 2) >>> 2] >>> (24 - ((i + 2) % 4) * 8)) & 0xff;\n\n\t var triplet = (byte1 << 16) | (byte2 << 8) | byte3;\n\n\t for (var j = 0; (j < 4) && (i + j * 0.75 < sigBytes); j++) {\n\t base64Chars.push(map.charAt((triplet >>> (6 * (3 - j))) & 0x3f));\n\t }\n\t }\n\n\t // Add padding\n\t var paddingChar = map.charAt(64);\n\t if (paddingChar) {\n\t while (base64Chars.length % 4) {\n\t base64Chars.push(paddingChar);\n\t }\n\t }\n\n\t return base64Chars.join('');\n\t },\n\n\t /**\n\t * Converts a Base64url string to a word array.\n\t *\n\t * @param {string} base64Str The Base64url string.\n\t *\n\t * @param {boolean} urlSafe Whether to use url safe\n\t *\n\t * @return {WordArray} The word array.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var wordArray = CryptoJS.enc.Base64url.parse(base64String);\n\t */\n\t parse: function (base64Str, urlSafe=true) {\n\t // Shortcuts\n\t var base64StrLength = base64Str.length;\n\t var map = urlSafe ? this._safe_map : this._map;\n\t var reverseMap = this._reverseMap;\n\n\t if (!reverseMap) {\n\t reverseMap = this._reverseMap = [];\n\t for (var j = 0; j < map.length; j++) {\n\t reverseMap[map.charCodeAt(j)] = j;\n\t }\n\t }\n\n\t // Ignore padding\n\t var paddingChar = map.charAt(64);\n\t if (paddingChar) {\n\t var paddingIndex = base64Str.indexOf(paddingChar);\n\t if (paddingIndex !== -1) {\n\t base64StrLength = paddingIndex;\n\t }\n\t }\n\n\t // Convert\n\t return parseLoop(base64Str, base64StrLength, reverseMap);\n\n\t },\n\n\t _map: 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=',\n\t _safe_map: 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_',\n\t };\n\n\t function parseLoop(base64Str, base64StrLength, reverseMap) {\n\t var words = [];\n\t var nBytes = 0;\n\t for (var i = 0; i < base64StrLength; i++) {\n\t if (i % 4) {\n\t var bits1 = reverseMap[base64Str.charCodeAt(i - 1)] << ((i % 4) * 2);\n\t var bits2 = reverseMap[base64Str.charCodeAt(i)] >>> (6 - (i % 4) * 2);\n\t var bitsCombined = bits1 | bits2;\n\t words[nBytes >>> 2] |= bitsCombined << (24 - (nBytes % 4) * 8);\n\t nBytes++;\n\t }\n\t }\n\t return WordArray.create(words, nBytes);\n\t }\n\t}());\n\n\treturn CryptoJS.enc.Base64url;\n\n}));",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory(require(\"./core\"));\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([\"./core\"], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\tfactory(root.CryptoJS);\n\t}\n}(this, function (CryptoJS) {\n\n\t(function () {\n\t // Check if typed arrays are supported\n\t if (typeof ArrayBuffer != 'function') {\n\t return;\n\t }\n\n\t // Shortcuts\n\t var C = CryptoJS;\n\t var C_lib = C.lib;\n\t var WordArray = C_lib.WordArray;\n\n\t // Reference original init\n\t var superInit = WordArray.init;\n\n\t // Augment WordArray.init to handle typed arrays\n\t var subInit = WordArray.init = function (typedArray) {\n\t // Convert buffers to uint8\n\t if (typedArray instanceof ArrayBuffer) {\n\t typedArray = new Uint8Array(typedArray);\n\t }\n\n\t // Convert other array views to uint8\n\t if (\n\t typedArray instanceof Int8Array ||\n\t (typeof Uint8ClampedArray !== \"undefined\" && typedArray instanceof Uint8ClampedArray) ||\n\t typedArray instanceof Int16Array ||\n\t typedArray instanceof Uint16Array ||\n\t typedArray instanceof Int32Array ||\n\t typedArray instanceof Uint32Array ||\n\t typedArray instanceof Float32Array ||\n\t typedArray instanceof Float64Array\n\t ) {\n\t typedArray = new Uint8Array(typedArray.buffer, typedArray.byteOffset, typedArray.byteLength);\n\t }\n\n\t // Handle Uint8Array\n\t if (typedArray instanceof Uint8Array) {\n\t // Shortcut\n\t var typedArrayByteLength = typedArray.byteLength;\n\n\t // Extract bytes\n\t var words = [];\n\t for (var i = 0; i < typedArrayByteLength; i++) {\n\t words[i >>> 2] |= typedArray[i] << (24 - (i % 4) * 8);\n\t }\n\n\t // Initialize this word array\n\t superInit.call(this, words, typedArrayByteLength);\n\t } else {\n\t // Else call normal init\n\t superInit.apply(this, arguments);\n\t }\n\t };\n\n\t subInit.prototype = WordArray;\n\t}());\n\n\n\treturn CryptoJS.lib.WordArray;\n\n}));",";(function (root, factory) {\n\tif (typeof exports === \"object\") {\n\t\t// CommonJS\n\t\tmodule.exports = exports = factory(require(\"./core\"));\n\t}\n\telse if (typeof define === \"function\" && define.amd) {\n\t\t// AMD\n\t\tdefine([\"./core\"], factory);\n\t}\n\telse {\n\t\t// Global (browser)\n\t\tfactory(root.CryptoJS);\n\t}\n}(this, function (CryptoJS) {\n\n\t(function (Math) {\n\t // Shortcuts\n\t var C = CryptoJS;\n\t var C_lib = C.lib;\n\t var WordArray = C_lib.WordArray;\n\t var Hasher = C_lib.Hasher;\n\t var C_algo = C.algo;\n\n\t // Initialization and round constants tables\n\t var H = [];\n\t var K = [];\n\n\t // Compute constants\n\t (function () {\n\t function isPrime(n) {\n\t var sqrtN = Math.sqrt(n);\n\t for (var factor = 2; factor <= sqrtN; factor++) {\n\t if (!(n % factor)) {\n\t return false;\n\t }\n\t }\n\n\t return true;\n\t }\n\n\t function getFractionalBits(n) {\n\t return ((n - (n | 0)) * 0x100000000) | 0;\n\t }\n\n\t var n = 2;\n\t var nPrime = 0;\n\t while (nPrime < 64) {\n\t if (isPrime(n)) {\n\t if (nPrime < 8) {\n\t H[nPrime] = getFractionalBits(Math.pow(n, 1 / 2));\n\t }\n\t K[nPrime] = getFractionalBits(Math.pow(n, 1 / 3));\n\n\t nPrime++;\n\t }\n\n\t n++;\n\t }\n\t }());\n\n\t // Reusable object\n\t var W = [];\n\n\t /**\n\t * SHA-256 hash algorithm.\n\t */\n\t var SHA256 = C_algo.SHA256 = Hasher.extend({\n\t _doReset: function () {\n\t this._hash = new WordArray.init(H.slice(0));\n\t },\n\n\t _doProcessBlock: function (M, offset) {\n\t // Shortcut\n\t var H = this._hash.words;\n\n\t // Working variables\n\t var a = H[0];\n\t var b = H[1];\n\t var c = H[2];\n\t var d = H[3];\n\t var e = H[4];\n\t var f = H[5];\n\t var g = H[6];\n\t var h = H[7];\n\n\t // Computation\n\t for (var i = 0; i < 64; i++) {\n\t if (i < 16) {\n\t W[i] = M[offset + i] | 0;\n\t } else {\n\t var gamma0x = W[i - 15];\n\t var gamma0 = ((gamma0x << 25) | (gamma0x >>> 7)) ^\n\t ((gamma0x << 14) | (gamma0x >>> 18)) ^\n\t (gamma0x >>> 3);\n\n\t var gamma1x = W[i - 2];\n\t var gamma1 = ((gamma1x << 15) | (gamma1x >>> 17)) ^\n\t ((gamma1x << 13) | (gamma1x >>> 19)) ^\n\t (gamma1x >>> 10);\n\n\t W[i] = gamma0 + W[i - 7] + gamma1 + W[i - 16];\n\t }\n\n\t var ch = (e & f) ^ (~e & g);\n\t var maj = (a & b) ^ (a & c) ^ (b & c);\n\n\t var sigma0 = ((a << 30) | (a >>> 2)) ^ ((a << 19) | (a >>> 13)) ^ ((a << 10) | (a >>> 22));\n\t var sigma1 = ((e << 26) | (e >>> 6)) ^ ((e << 21) | (e >>> 11)) ^ ((e << 7) | (e >>> 25));\n\n\t var t1 = h + sigma1 + ch + K[i] + W[i];\n\t var t2 = sigma0 + maj;\n\n\t h = g;\n\t g = f;\n\t f = e;\n\t e = (d + t1) | 0;\n\t d = c;\n\t c = b;\n\t b = a;\n\t a = (t1 + t2) | 0;\n\t }\n\n\t // Intermediate hash value\n\t H[0] = (H[0] + a) | 0;\n\t H[1] = (H[1] + b) | 0;\n\t H[2] = (H[2] + c) | 0;\n\t H[3] = (H[3] + d) | 0;\n\t H[4] = (H[4] + e) | 0;\n\t H[5] = (H[5] + f) | 0;\n\t H[6] = (H[6] + g) | 0;\n\t H[7] = (H[7] + h) | 0;\n\t },\n\n\t _doFinalize: function () {\n\t // Shortcuts\n\t var data = this._data;\n\t var dataWords = data.words;\n\n\t var nBitsTotal = this._nDataBytes * 8;\n\t var nBitsLeft = data.sigBytes * 8;\n\n\t // Add padding\n\t dataWords[nBitsLeft >>> 5] |= 0x80 << (24 - nBitsLeft % 32);\n\t dataWords[(((nBitsLeft + 64) >>> 9) << 4) + 14] = Math.floor(nBitsTotal / 0x100000000);\n\t dataWords[(((nBitsLeft + 64) >>> 9) << 4) + 15] = nBitsTotal;\n\t data.sigBytes = dataWords.length * 4;\n\n\t // Hash final blocks\n\t this._process();\n\n\t // Return final computed hash\n\t return this._hash;\n\t },\n\n\t clone: function () {\n\t var clone = Hasher.clone.call(this);\n\t clone._hash = this._hash.clone();\n\n\t return clone;\n\t }\n\t });\n\n\t /**\n\t * Shortcut function to the hasher's object interface.\n\t *\n\t * @param {WordArray|string} message The message to hash.\n\t *\n\t * @return {WordArray} The hash.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hash = CryptoJS.SHA256('message');\n\t * var hash = CryptoJS.SHA256(wordArray);\n\t */\n\t C.SHA256 = Hasher._createHelper(SHA256);\n\n\t /**\n\t * Shortcut function to the HMAC's object interface.\n\t *\n\t * @param {WordArray|string} message The message to hash.\n\t * @param {WordArray|string} key The secret key.\n\t *\n\t * @return {WordArray} The HMAC.\n\t *\n\t * @static\n\t *\n\t * @example\n\t *\n\t * var hmac = CryptoJS.HmacSHA256(message, key);\n\t */\n\t C.HmacSHA256 = Hasher._createHmacHelper(SHA256);\n\t}(Math));\n\n\n\treturn CryptoJS.SHA256;\n\n}));","import type { Config } from \"./types\";\n\nconst MONERIUM_CONFIG: Config = {\n environments: {\n production: {\n api: \"https://api.monerium.app\",\n web: \"https://monerium.app\",\n },\n sandbox: {\n api: \"https://api.monerium.dev\",\n web: \"https://sandbox.monerium.dev\",\n },\n },\n};\n\nexport { MONERIUM_CONFIG };\n","import encodeBase64Url from \"crypto-js/enc-base64url\";\nimport wordArray from \"crypto-js/lib-typedarrays\";\nimport SHA256 from \"crypto-js/sha256\";\nimport { MONERIUM_CONFIG } from \"./config\";\nimport type {\n AuthArgs,\n AuthCode,\n AuthContext,\n Balances,\n BearerProfile,\n ClientCredentials,\n Environment,\n LinkAddress,\n NewOrder,\n Order,\n OrderFilter,\n PKCERequest,\n PKCERequestArgs,\n Profile,\n RefreshToken,\n SupportingDoc,\n Token,\n} from \"./types\";\n// import pjson from \"../package.json\";\n/**\n * How to authenticate\n * ```ts\n *\n * import { MoneriumClient } from '@monerium/sdk'\n *\n * const client = new MoneriumClient();\n *\n * // Start by authenticating\n * await client.auth({\n * client_id:\n * client_secret:\n * })\n * ```\n * */\nexport class MoneriumClient {\n #env: Environment;\n\n #authPayload?: string;\n /** The PKCE code verifier */\n codeVerifier?: string;\n bearerProfile?: BearerProfile;\n\n constructor(env: \"production\" | \"sandbox\" = \"sandbox\") {\n this.#env = MONERIUM_CONFIG.environments[env];\n }\n\n // -- Authentication\n\n async auth(args: AuthArgs) {\n let params: AuthCode | RefreshToken | ClientCredentials;\n\n if (this.#isAuthCode(args)) {\n params = { ...args, grant_type: \"authorization_code\" };\n } else if (this.#isRefreshToken(args)) {\n params = { ...args, grant_type: \"refresh_token\" };\n } else if (this.#isClientCredentials(args)) {\n params = { ...args, grant_type: \"client_credentials\" };\n } else {\n throw new Error(\"Authentication method could not be detected.\");\n }\n\n this.bearerProfile = (await this.#api(\n \"post\",\n `auth/token`,\n new URLSearchParams(params as unknown as Record<string, string>),\n true\n )) as BearerProfile;\n\n this.#authPayload = `Bearer ${this.bearerProfile.access_token}`;\n }\n\n pkceRequest(args: PKCERequestArgs): string {\n // this.codeVerifier = CryptoJS.lib.WordArray.random(64).toString();\n // const challenge = CryptoJS.enc.Base64url.stringify(\n // CryptoJS.SHA256(this.codeVerifier)\n // );\n this.codeVerifier = wordArray.random(64).toString();\n const challenge = encodeBase64Url.stringify(SHA256(this.codeVerifier));\n\n const params: PKCERequest = {\n ...args,\n code_challenge: challenge,\n code_challenge_method: \"S256\",\n response_type: \"code\",\n };\n\n return `${this.#env.api}/auth?${new URLSearchParams(params)}`;\n }\n\n // -- Read Methods\n\n getAuthContext(): Promise<AuthContext> {\n return this.#api(\"get\", `auth/context`) as Promise<AuthContext>;\n }\n\n /**\n * @param {string} profileId - the id of the profile to fetch.\n */\n getProfile(profileId: string): Promise<Profile> {\n return this.#api(\"get\", `profiles/${profileId}`) as Promise<Profile>;\n }\n\n /**\n * @param {string=} profileId - the id of the profile to fetch balances.\n */\n getBalances(profileId?: string): Promise<Balances> | Promise<Balances[]> {\n if (profileId) {\n return this.#api(\n \"get\",\n `profiles/${profileId}/balances`\n ) as Promise<Balances>;\n } else {\n return this.#api(\"get\", `balances`) as Promise<Balances[]>;\n }\n }\n\n getOrders(filter?: OrderFilter): Promise<Order[]> {\n const searchParams = new URLSearchParams(\n filter as unknown as Record<string, string>\n );\n\n return this.#api(\"get\", `orders?${searchParams}`) as Promise<Order[]>;\n }\n\n getOrder(orderId: string): Promise<Order> {\n return this.#api(\"get\", `orders/${orderId}`) as Promise<Order>;\n }\n\n getTokens(): Promise<Token[]> {\n return this.#api(\"get\", \"tokens\") as Promise<Token[]>;\n }\n\n // -- Write Methods\n\n linkAddress(profileId: string, body: LinkAddress) {\n return this.#api(\n \"post\",\n `profiles/${profileId}/addresses`,\n JSON.stringify(body)\n );\n }\n\n placeOrder(order: NewOrder, profileId?: string): Promise<Order> {\n if (profileId) {\n return this.#api(\n \"post\",\n `profiles/${profileId}/orders`,\n JSON.stringify(order)\n ) as Promise<Order>;\n } else {\n return this.#api(\n \"post\",\n `orders`,\n JSON.stringify(order)\n ) as Promise<Order>;\n }\n }\n\n uploadSupportingDocument(document: File): Promise<SupportingDoc> {\n const searchParams = new URLSearchParams(\n document as unknown as Record<string, string>\n );\n\n return this.#api(\n \"post\",\n \"files/supporting-document\",\n searchParams,\n true\n ) as Promise<SupportingDoc>;\n }\n\n // -- Helper Methods\n\n async #api(\n method: string,\n resource: string,\n body?: BodyInit,\n isFormEncoded?: boolean\n ) {\n const res = await fetch(`${this.#env.api}/${resource}`, {\n method,\n headers: {\n \"Content-Type\": `application/${\n isFormEncoded ? \"x-www-form-urlencoded\" : \"json\"\n }`,\n Authorization: this.#authPayload || \"\",\n // \"User-Agent\": \"sdk/\" + pjson.version,\n },\n body,\n });\n\n const response = await res.json();\n\n if (res.ok) {\n return response;\n } else {\n throw response;\n }\n }\n\n #isAuthCode(args: AuthArgs): args is AuthCode {\n return (args as AuthCode).code != undefined;\n }\n\n #isRefreshToken(args: AuthArgs): args is RefreshToken {\n return (args as RefreshToken).refresh_token != undefined;\n }\n\n #isClientCredentials(args: AuthArgs): args is ClientCredentials {\n return (args as ClientCredentials).client_secret != undefined;\n }\n}\n","// --- Config --- //\n\nexport type Environment = { api: string; web: string };\n\nexport type Config = {\n environments: { production: Environment; sandbox: Environment };\n};\n\n// --- Client Variables --- //\n\nexport interface BearerProfile {\n access_token: string;\n token_type: string;\n expires_in: number;\n refresh_token: string;\n profile: string;\n userId: string;\n}\n\n// --- Client Methods --- //\n\nexport enum Currency {\n eur = \"eur\",\n usd = \"usd\",\n gbp = \"gbp\",\n isk = \"isk\",\n}\n\n// -- auth\n\nexport type AuthArgs =\n | Omit<AuthCode, \"grant_type\">\n | Omit<RefreshToken, \"grant_type\">\n | Omit<ClientCredentials, \"grant_type\">;\n\nexport interface AuthCode {\n grant_type: \"authorization_code\";\n client_id: string;\n code: string;\n code_verifier: string;\n redirect_uri: string;\n scope?: string;\n}\n\nexport interface RefreshToken {\n grant_type: \"refresh_token\";\n client_id: string;\n refresh_token: string;\n scope?: string;\n}\n\nexport interface ClientCredentials {\n grant_type: \"client_credentials\";\n client_id: string;\n client_secret: string;\n scope?: string;\n}\n\n// -- pkceRequest\n\nexport type PKCERequestArgs = Omit<\n PKCERequest,\n \"code_challenge\" | \"code_challenge_method\" | \"response_type\"\n>;\n\nexport type PKCERequest = {\n client_id: string;\n code_challenge: string;\n code_challenge_method: string;\n response_type: string;\n state: string;\n redirect_uri?: string;\n scope?: string;\n address?: string;\n};\n\n// -- authContext\n\nenum Method {\n password = \"password\",\n resource = \"resource\",\n jwt = \"jwt\",\n apiKey = \"apiKey\",\n}\n\nexport enum ProfileType {\n corporate = \"corporate\",\n personal = \"personal\",\n}\n\nexport enum Permission {\n read = \"read\",\n write = \"write\",\n}\n\nexport interface AuthProfile {\n id: string;\n type: ProfileType;\n name: string;\n perms: Permission[];\n}\n\nexport interface AuthContext {\n userId: string;\n email: string;\n name: string;\n roles: \"admin\"[];\n auth: { method: Method; subject: string; verified: boolean };\n defaultProfile: string;\n profiles: AuthProfile[];\n}\n\n// -- getProfile\n\nexport enum KYCState {\n absent = \"absent\",\n submitted = \"submitted\",\n pending = \"pending\",\n confirmed = \"confirmed\",\n}\n\nexport enum KYCOutcome {\n approved = \"approved\",\n rejected = \"rejected\",\n unknown = \"unknown\",\n}\n\nexport interface KYC {\n state: KYCState;\n outcome: KYCOutcome;\n}\n\nexport enum PaymentStandard {\n iban = \"iban\",\n scan = \"scan\",\n}\n\nexport interface Account {\n address: string;\n currency: Currency;\n standard: PaymentStandard;\n iban?: string;\n sortCode?: string;\n accountNumber?: string;\n network: Network;\n chain: Chain;\n id?: string;\n}\n\nexport interface Profile {\n id: string;\n name: string;\n kyc: KYC;\n accounts: Account[];\n}\n\n// -- getBalances\n\nexport enum Chain {\n polygon = \"polygon\",\n ethereum = \"ethereum\",\n gnosis = \"gnosis\",\n}\n\nexport enum Network {\n mainnet = \"mainnet\",\n chiado = \"chiado\",\n goerli = \"goerli\",\n mumbai = \"mumbai\",\n}\n\nexport interface Balance {\n currency: Currency;\n amount: string;\n}\n\nexport interface Balances {\n id: string;\n address: string;\n chain: Chain;\n network: Network;\n balances: Balance[];\n}\n\n// --getOrders\n\nexport enum OrderKind {\n redeem = \"redeem\",\n issue = \"issue\",\n}\n\nexport enum OrderState {\n placed = \"placed\",\n pending = \"pending\",\n processed = \"processed\",\n rejected = \"rejected\",\n}\n\nexport interface Fee {\n provider: \"satchel\";\n currency: Currency;\n amount: string;\n}\n\nexport interface IBAN {\n standard: PaymentStandard.iban;\n iban: string;\n}\n\nexport interface SCAN {\n standard: PaymentStandard.scan;\n sortCode: string;\n accountNumber: string;\n}\n\nexport interface Individual {\n firstName: string;\n lastName: string;\n country?: string;\n}\n\nexport interface Corporation {\n companyName: string;\n country: string;\n}\n\nexport interface Counterpart {\n identifier: IBAN | SCAN;\n details: Individual | Corporation;\n}\n\nexport interface OrderMetadata {\n approvedAt: string;\n processedAt: string;\n rejectedAt: string;\n state: OrderState;\n placedBy: string;\n placedAt: string;\n receivedAmount: string;\n sentAmount: string;\n}\n\nexport interface OrderFilter {\n address?: string;\n txHash?: string;\n profile?: string;\n memo?: string;\n accountId?: string;\n state?: OrderState;\n}\n\nexport interface Order {\n id: string;\n profile: string;\n accountId: string;\n address: string;\n kind: OrderKind;\n amount: string;\n currency: Currency;\n totalFee: string;\n fees: Fee[];\n counterpart: Counterpart;\n memo: string;\n rejectedReason: string;\n supportingDocumentId: string;\n meta: OrderMetadata;\n}\n\n// -- getTokens\n\nexport interface Token {\n currency: Currency;\n ticker: string;\n symbol: string;\n chain: Chain;\n network: Network;\n address: string;\n decimals: number;\n}\n\n// --placeOrder\n\nexport interface NewOrder {\n kind: OrderKind;\n amount: string;\n signature: string;\n accountId?: string;\n address: string;\n currency: Currency;\n counterpart: Counterpart;\n message: string;\n memo: string;\n supportingDocumentId?: string;\n chain: Chain;\n network: Network;\n}\n\n// -- uploadSupportingDocument\n\nexport interface SupportingDocMetadata {\n uploadedBy: string;\n createdAt: string;\n updatedAt: string;\n}\n\nexport interface SupportingDoc {\n id: string;\n name: string;\n type: string;\n size: number;\n hash: string;\n meta: SupportingDocMetadata;\n}\n\n// -- linkAddress\n\nexport interface CurrencyAccounts {\n network: Network;\n chain: Chain;\n currency: Currency;\n}\n\nexport interface LinkAddress {\n address: string;\n message: string;\n signature: string;\n accounts: CurrencyAccounts[];\n}\n"],"names":["__viteBrowserExternal","root","factory","module","this","CryptoJS","Math","undefined","crypto","global","require","require$$0","cryptoSecureRandomInt","create","F","obj","subtype","C","C_lib","Base","overrides","instance","properties","propertyName","WordArray","words","sigBytes","encoder","Hex","wordArray","thisWords","thatWords","thisSigBytes","thatSigBytes","i","thatByte","j","clone","nBytes","C_enc","hexChars","bite","hexStr","hexStrLength","Latin1","latin1Chars","latin1Str","latin1StrLength","Utf8","utf8Str","BufferedBlockAlgorithm","data","doFlush","processedWords","dataWords","dataSigBytes","blockSize","blockSizeBytes","nBlocksReady","nWordsReady","nBytesReady","offset","cfg","messageUpdate","hash","hasher","message","key","C_algo","urlSafe","map","base64Chars","byte1","byte2","byte3","triplet","paddingChar","base64Str","base64StrLength","reverseMap","paddingIndex","parseLoop","bits1","bits2","bitsCombined","superInit","subInit","typedArray","typedArrayByteLength","Hasher","H","K","isPrime","n","sqrtN","factor","getFractionalBits","nPrime","W","SHA256","M","a","b","c","d","e","f","h","gamma0x","gamma0","gamma1x","gamma1","ch","maj","sigma0","sigma1","t1","t2","nBitsTotal","nBitsLeft","MONERIUM_CONFIG","MoneriumClient","env","__privateAdd","_api","_isAuthCode","_isRefreshToken","_isClientCredentials","_env","_authPayload","__publicField","__privateSet","args","params","__privateMethod","isAuthCode_fn","isRefreshToken_fn","isClientCredentials_fn","api_fn","challenge","encodeBase64Url","__privateGet","profileId","filter","searchParams","orderId","body","order","document","method","resource","isFormEncoded","res","response","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