diff --git a/206.bundle.js b/206.bundle.js deleted file mode 100644 index 77299a116..000000000 --- a/206.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{var r,e,t,o,a,n,i={},p={};function c(r){var e=p[r];if(void 0!==e)return e.exports;var t=p[r]={exports:{}};return i[r](t,t.exports,c),t.exports}c.m=i,c.x=()=>{var r=c.O(void 0,[495,877,66],(()=>c(66)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,i)=>{var p;i&&((p=[]).d=-1);var c,s,f,l=new Set,u=a.exports,b=new Promise(((r,e)=>{f=e,s=r}));b[e]=u,b[r]=r=>(p&&r(p),l.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{i[e]=r,o(n)}),(r=>{i[t]=r,o(n)}));var i={};return i[r]=r=>r(n),i}}var p={};return p[r]=r=>{},p[e]=a,p})))(a);var i=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(i)).r=0;var t=r=>r!==p&&!l.has(r)&&(l.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:i()}),(r=>(r?f(b[t]=r):s(u),o(p)))),p&&p.d<0&&(p.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(f=0;f=o)&&Object.keys(c.O).every((r=>c.O[r](e[p])))?e.splice(p--,1):(i=!1,o0&&a[f-1][2]>o;f--)a[f]=a[f-1];a[f]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={206:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var i in a)c.o(a,i)&&(c.m[i]=a[i]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([495,877,66].map(c.e,c)).then(n);c.x()})(); -//# sourceMappingURL=206.bundle.js.map \ No newline at end of file diff --git a/206.bundle.js.map b/206.bundle.js.map deleted file mode 100644 index 50f81be47..000000000 --- a/206.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"206.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUI,EAAQA,EAAOD,QAASJ,GAG/CK,EAAOD,OACf,CAGAJ,EAAoBO,EAAID,EAGx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EAAQlC,OAAS,EAClBD,GAAK,KAAO6B,IAAc,aAAaQ,KAAKR,KAAaA,EAAYM,EAAQnC,KAAKkC,GAE3F,CAID,IAAKL,EAAW,MAAM,IAAIS,MAAM,yDAChCT,EAAYA,EAAUU,QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpFxF,EAAoByF,EAAIX,C,WClBxB9E,EAAoB0F,EAAIC,KAAKX,SAAW,GAIxC,IAAIY,EAAkB,CACrB,IAAK,GAgBN5F,EAAoB+D,EAAEd,EAAI,CAACe,EAASG,KAE/ByB,EAAgB5B,IAElBe,cAAc/E,EAAoByF,EAAIzF,EAAoBoE,EAAEJ,GAE9D,EAGD,IAAI6B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBnD,KAAKqD,KAAKF,GAC9DA,EAAmBnD,KAvBCsD,IACnB,IAAKnD,EAAUoD,EAAaC,GAAWF,EACvC,IAAI,IAAI/F,KAAYgG,EAChBjG,EAAoB2D,EAAEsC,EAAahG,KACrCD,EAAoBO,EAAEN,GAAYgG,EAAYhG,IAIhD,IADGiG,GAASA,EAAQlG,GACd6C,EAASK,QACd0C,EAAgB/C,EAASsD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BlG,EAAOE,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,IAAInC,IAAI9B,EAAoBkC,EAAGlC,IAAsBgC,KAAKlC,GSD7DE,EAAoBQ,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([495,877,66].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [495,877,66], () => (__webpack_require__(66)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t206: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/21.bundle.js b/21.bundle.js deleted file mode 100644 index e6800fd91..000000000 --- a/21.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{var r,e,t,o,a,n,i={},p={};function c(r){var e=p[r];if(void 0!==e)return e.exports;var t=p[r]={exports:{}};return i[r](t,t.exports,c),t.exports}c.m=i,c.x=()=>{var r=c.O(void 0,[933,383],(()=>c(5383)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,i)=>{var p;i&&((p=[]).d=-1);var c,s,f,l=new Set,u=a.exports,b=new Promise(((r,e)=>{f=e,s=r}));b[e]=u,b[r]=r=>(p&&r(p),l.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{i[e]=r,o(n)}),(r=>{i[t]=r,o(n)}));var i={};return i[r]=r=>r(n),i}}var p={};return p[r]=r=>{},p[e]=a,p})))(a);var i=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(i)).r=0;var t=r=>r!==p&&!l.has(r)&&(l.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:i()}),(r=>(r?f(b[t]=r):s(u),o(p)))),p&&p.d<0&&(p.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(f=0;f=o)&&Object.keys(c.O).every((r=>c.O[r](e[p])))?e.splice(p--,1):(i=!1,o0&&a[f-1][2]>o;f--)a[f]=a[f-1];a[f]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&!r;)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={21:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var i in a)c.o(a,i)&&(c.m[i]=a[i]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([c.e(933),c.e(383)]).then(n);c.x()})(); -//# sourceMappingURL=21.bundle.js.map \ No newline at end of file diff --git a/21.bundle.js.map b/21.bundle.js.map deleted file mode 100644 index 16255ccb7..000000000 --- a/21.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"21.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUI,EAAQA,EAAOD,QAASJ,GAG/CK,EAAOD,OACf,CAGAJ,EAAoBO,EAAID,EAGxBN,EAAoBQ,EAAI,KAGvB,IAAIC,EAAsBT,EAAoBU,OAAEP,EAAW,CAAC,IAAI,MAAM,IAAOH,EAAoB,QAEjG,OADAS,EAAsBT,EAAoBU,EAAED,EAClB,EHjCvBhB,EAAkC,mBAAXkB,OAAwBA,OAAO,kBAAoB,qBAC1EjB,EAAmC,mBAAXiB,OAAwBA,OAAO,mBAAqB,sBAC5EhB,EAAiC,mBAAXgB,OAAwBA,OAAO,iBAAmB,oBACxEf,EAAgBgB,IAChBA,GAASA,EAAMC,EAAI,IACrBD,EAAMC,EAAI,EACVD,EAAME,SAASC,GAAQA,EAAGC,MAC1BJ,EAAME,SAASC,GAAQA,EAAGC,IAAMD,EAAGC,IAAMD,MAC1C,EAyBDf,EAAoBiB,EAAI,CAACZ,EAAQa,EAAMC,KACtC,IAAIP,EACJO,KAAcP,EAAQ,IAAIC,GAAK,GAC/B,IAEIO,EACAC,EACAC,EAJAC,EAAY,IAAIC,IAChBpB,EAAUC,EAAOD,QAIjBqB,EAAU,IAAI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D,EAAoBO,EAAEN,GAAY+F,EAAY/F,IAIhD,IADGgG,GAASA,EAAQjG,GACd6C,EAASK,QACdyC,EAAgB9C,EAASqD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BjG,EAAOE,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChBkB,QAAQuC,IAAI,CAClBjE,EAAoBkC,EAAE,KACtBlC,EAAoBkC,EAAE,OACpBF,KAAKlC,GSJiBE,EAAoBQ,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(933),\n\t\t__webpack_require__.e(383)\n\t]).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [933,383], () => (__webpack_require__(5383)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && !scriptUrl) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t21: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/220.bundle.js b/220.bundle.js deleted file mode 100644 index c83388a63..000000000 --- a/220.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[220],{220:(t,e,n)=>{n.r(e),n.d(e,{getCLS:()=>d,getFCP:()=>m,getFID:()=>v,getLCP:()=>h,getTTFB:()=>S});var i,a,r=function(t){return{name:t,value:arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1,delta:0,entries:[],id:"".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),isFinal:!1}},o=function(t,e){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var n=new PerformanceObserver((function(t){return t.getEntries().map(e)}));return n.observe({type:t,buffered:!0}),n}}catch(t){}},s=!1,u=!1,c=function(t){s=!t.persisted},l=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];u||(addEventListener("pagehide",c),addEventListener("beforeunload",(function(){})),u=!0),addEventListener("visibilitychange",(function(e){var n=e.timeStamp;"hidden"===document.visibilityState&&t({timeStamp:n,isUnloading:s})}),{capture:!0,once:e})},p=function(t,e,n,i){var a;return function(){n&&e.isFinal&&n.disconnect(),e.value>=0&&(i||e.isFinal||"hidden"===document.visibilityState)&&(e.delta=e.value-(a||0),(e.delta||e.isFinal||void 0===a)&&(t(e),a=e.value))}},d=function(t){var e,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=r("CLS",0),a=function(t){t.hadRecentInput||(i.value+=t.value,i.entries.push(t),e())},s=o("layout-shift",a);s&&(e=p(t,i,s,n),l((function(t){var n=t.isUnloading;s.takeRecords().map(a),n&&(i.isFinal=!0),e()})))},f=function(){return void 0===i&&(i="hidden"===document.visibilityState?0:1/0,l((function(t){var e=t.timeStamp;return i=e}),!0)),{get timeStamp(){return i}}},m=function(t){var e,n=r("FCP"),i=f(),a=o("paint",(function(t){"first-contentful-paint"===t.name&&t.startTime1&&void 0!==arguments[1]&&arguments[1],i=r("LCP"),a=f(),s=function(t){var n=t.startTime;n1&&void 0!==arguments[1]?arguments[1]:-1;return{name:t,value:n,delta:0,entries:[],id:e(),isFinal:!1}},a=function(t,n){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var e=new PerformanceObserver((function(t){return t.getEntries().map(n)}));return e.observe({type:t,buffered:!0}),e}}catch(t){}},r=!1,o=!1,s=function(t){r=!t.persisted},u=function(){addEventListener(\"pagehide\",s),addEventListener(\"beforeunload\",(function(){}))},c=function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];o||(u(),o=!0),addEventListener(\"visibilitychange\",(function(n){var e=n.timeStamp;\"hidden\"===document.visibilityState&&t({timeStamp:e,isUnloading:r})}),{capture:!0,once:n})},l=function(t,n,e,i){var a;return function(){e&&n.isFinal&&e.disconnect(),n.value>=0&&(i||n.isFinal||\"hidden\"===document.visibilityState)&&(n.delta=n.value-(a||0),(n.delta||n.isFinal||void 0===a)&&(t(n),a=n.value))}},p=function(t){var n,e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=i(\"CLS\",0),o=function(t){t.hadRecentInput||(r.value+=t.value,r.entries.push(t),n())},s=a(\"layout-shift\",o);s&&(n=l(t,r,s,e),c((function(t){var e=t.isUnloading;s.takeRecords().map(o),e&&(r.isFinal=!0),n()})))},d=function(){return void 0===t&&(t=\"hidden\"===document.visibilityState?0:1/0,c((function(n){var e=n.timeStamp;return t=e}),!0)),{get timeStamp(){return t}}},v=function(t){var n,e=i(\"FCP\"),r=d(),o=a(\"paint\",(function(t){\"first-contentful-paint\"===t.name&&t.startTime1&&void 0!==arguments[1]&&arguments[1],r=i(\"LCP\"),o=d(),s=function(t){var e=t.startTime;e{var e,t,r,n,o,a,i={8229:(e,t,r)=>{r.a(e,(async(e,t)=>{try{r(5357);var n=r(9879),o=r(2857),a=r(9720),i=e([n,o]);[n,o]=i.then?(await i)():i,await(0,n.Fs)();const s="https://api.explorer.provable.com/v1",c=new o.A,u=new o.P(s,c,void 0);c.useCache(!0);let l="";async function p(e,t,r,a,i=!1){console.log("Web worker: Executing function locally...");const s=performance.now();let p;try{p=u.createProgramFromSource(e)}catch(e){throw new Error("Error creating program from source")}const f=p.id();if(!p.hasFunction(t))throw new Error(`Program ${f} does not contain function ${t}`);const g=`${f}:${t}`;let h;try{h=await u.networkClient.getProgramImports(e)}catch(e){throw new Error("Error getting program imports")}if(l!==e){const o=await u.synthesizeKeys(e,t,r,n.ZD.from_string(a));u.keyProvider.cacheKeys(g,o),l=e}const m=new o.a({cacheKey:g}),y=await u.run(e,t,r,i,h,m,void 0,void 0,n.ZD.from_string(a));console.log(`Web worker: Local execution completed in ${performance.now()-s} ms`);const d=y.getOutputs(),v=y.getExecution();let w,b="";try{w=c.getKeys(g)}catch(e){throw new Error("Could not get verifying key")}const E=w[1];return v?((0,n.Yc)(v,E,p,"hello"),b=v.toString(),console.log("Execution verified successfully: "+v)):b="",console.log(`Function execution response: ${d}`),{outputs:d,execution:b}}async function f(){return(new n.ZD).to_string()}const g={run:p,getPrivateKey:f};(0,a.p)(g),t()}catch(h){t(h)}}),1)},9720:(e,t,r)=>{r.d(t,{p:()=>l});const n=Symbol("Comlink.proxy"),o=Symbol("Comlink.endpoint"),a=Symbol("Comlink.releaseProxy"),i=Symbol("Comlink.finalizer"),s=Symbol("Comlink.thrown"),c=e=>"object"==typeof e&&null!==e||"function"==typeof e,u=new Map([["proxy",{canHandle:e=>c(e)&&e[n],serialize(e){const{port1:t,port2:r}=new MessageChannel;return l(e,t),[r,[r]]},deserialize(e){return e.start(),y(e,[],t);var t}}],["throw",{canHandle:e=>c(e)&&s in e,serialize({value:e}){let t;return t=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[t,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function l(e,t=globalThis,r=["*"]){t.addEventListener("message",(function o(a){if(!a||!a.data)return;if(!function(e,t){for(const r of e){if(t===r||"*"===r)return!0;if(r instanceof RegExp&&r.test(t))return!0}return!1}(r,a.origin))return void console.warn(`Invalid origin '${a.origin}' for comlink proxy`);const{id:c,type:u,path:f}=Object.assign({path:[]},a.data),g=(a.data.argumentList||[]).map(b);let h;try{const t=f.slice(0,-1).reduce(((e,t)=>e[t]),e),r=f.reduce(((e,t)=>e[t]),e);switch(u){case"GET":h=r;break;case"SET":t[f.slice(-1)[0]]=b(a.data.value),h=!0;break;case"APPLY":h=r.apply(t,g);break;case"CONSTRUCT":h=function(e){return Object.assign(e,{[n]:!0})}(new r(...g));break;case"ENDPOINT":{const{port1:t,port2:r}=new MessageChannel;l(e,r),h=function(e,t){return v.set(e,t),e}(t,[t])}break;case"RELEASE":h=void 0;break;default:return}}catch(e){h={value:e,[s]:0}}Promise.resolve(h).catch((e=>({value:e,[s]:0}))).then((r=>{const[n,a]=w(r);t.postMessage(Object.assign(Object.assign({},n),{id:c}),a),"RELEASE"===u&&(t.removeEventListener("message",o),p(t),i in e&&"function"==typeof e[i]&&e[i]())})).catch((e=>{const[r,n]=w({value:new TypeError("Unserializable return value"),[s]:0});t.postMessage(Object.assign(Object.assign({},r),{id:c}),n)}))})),t.start&&t.start()}function p(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function f(e){if(e)throw new Error("Proxy has been released and is not useable")}function g(e){return E(e,{type:"RELEASE"}).then((()=>{p(e)}))}const h=new WeakMap,m="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const t=(h.get(e)||0)-1;h.set(e,t),0===t&&g(e)}));function y(e,t=[],r=function(){}){let n=!1;const i=new Proxy(r,{get(r,o){if(f(n),o===a)return()=>{!function(e){m&&m.unregister(e)}(i),g(e),n=!0};if("then"===o){if(0===t.length)return{then:()=>i};const r=E(e,{type:"GET",path:t.map((e=>e.toString()))}).then(b);return r.then.bind(r)}return y(e,[...t,o])},set(r,o,a){f(n);const[i,s]=w(a);return E(e,{type:"SET",path:[...t,o].map((e=>e.toString())),value:i},s).then(b)},apply(r,a,i){f(n);const s=t[t.length-1];if(s===o)return E(e,{type:"ENDPOINT"}).then(b);if("bind"===s)return y(e,t.slice(0,-1));const[c,u]=d(i);return E(e,{type:"APPLY",path:t.map((e=>e.toString())),argumentList:c},u).then(b)},construct(r,o){f(n);const[a,i]=d(o);return E(e,{type:"CONSTRUCT",path:t.map((e=>e.toString())),argumentList:a},i).then(b)}});return function(e,t){const r=(h.get(t)||0)+1;h.set(t,r),m&&m.register(e,t,e)}(i,e),i}function d(e){const t=e.map(w);return[t.map((e=>e[0])),(r=t.map((e=>e[1])),Array.prototype.concat.apply([],r))];var r}const v=new WeakMap;function w(e){for(const[t,r]of u)if(r.canHandle(e)){const[n,o]=r.serialize(e);return[{type:"HANDLER",name:t,value:n},o]}return[{type:"RAW",value:e},v.get(e)||[]]}function b(e){switch(e.type){case"HANDLER":return u.get(e.name).deserialize(e.value);case"RAW":return e.value}}function E(e,t,r){return new Promise((n=>{const o=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-");e.addEventListener("message",(function t(r){r.data&&r.data.id&&r.data.id===o&&(e.removeEventListener("message",t),n(r.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:o},t),r)}))}}},s={};function c(e){var t=s[e];if(void 0!==t)return t.exports;var r=s[e]={exports:{}};return i[e].call(r.exports,r,r.exports,c),r.exports}c.m=i,c.x=()=>{var e=c.O(void 0,[357,857],(()=>c(8229)));return e=c.O(e)},e="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",t="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",r="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",n=e=>{e&&e.d<1&&(e.d=1,e.forEach((e=>e.r--)),e.forEach((e=>e.r--?e.r++:e())))},c.a=(o,a,i)=>{var s;i&&((s=[]).d=-1);var c,u,l,p=new Set,f=o.exports,g=new Promise(((e,t)=>{l=t,u=e}));g[t]=f,g[e]=e=>(s&&e(s),p.forEach(e),g.catch((e=>{}))),o.exports=g,a((o=>{var a;c=(o=>o.map((o=>{if(null!==o&&"object"==typeof o){if(o[e])return o;if(o.then){var a=[];a.d=0,o.then((e=>{i[t]=e,n(a)}),(e=>{i[r]=e,n(a)}));var i={};return i[e]=e=>e(a),i}}var s={};return s[e]=e=>{},s[t]=o,s})))(o);var i=()=>c.map((e=>{if(e[r])throw e[r];return e[t]})),u=new Promise((t=>{(a=()=>t(i)).r=0;var r=e=>e!==s&&!p.has(e)&&(p.add(e),e&&!e.d&&(a.r++,e.push(a)));c.map((t=>t[e](r)))}));return a.r?u:i()}),(e=>(e?l(g[r]=e):u(f),n(s)))),s&&s.d<0&&(s.d=0)},o=[],c.O=(e,t,r,n)=>{if(!t){var a=1/0;for(l=0;l=n)&&Object.keys(c.O).every((e=>c.O[e](t[s])))?t.splice(s--,1):(i=!1,n0&&o[l-1][2]>n;l--)o[l]=o[l-1];o[l]=[t,r,n]},c.d=(e,t)=>{for(var r in t)c.o(t,r)&&!c.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},c.f={},c.e=e=>Promise.all(Object.keys(c.f).reduce(((t,r)=>(c.f[r](e,t),t)),[])),c.u=e=>e+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e;c.g.importScripts&&(e=c.g.location+"");var t=c.g.document;if(!e&&t&&(t.currentScript&&"SCRIPT"===t.currentScript.tagName.toUpperCase()&&(e=t.currentScript.src),!e)){var r=t.getElementsByTagName("script");if(r.length)for(var n=r.length-1;n>-1&&(!e||!/^http(s?):/.test(e));)e=r[n--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=e})(),(()=>{c.b=self.location+"";var e={229:1};c.f.i=(t,r)=>{e[t]||importScripts(c.p+c.u(t))};var t=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],r=t.push.bind(t);t.push=t=>{var[n,o,a]=t;for(var i in o)c.o(o,i)&&(c.m[i]=o[i]);for(a&&a(c);n.length;)e[n.pop()]=1;r(t)}})(),a=c.x,c.x=()=>Promise.all([c.e(357),c.e(857)]).then(a);c.x()})(); +//# sourceMappingURL=229.bundle.js.map \ No newline at end of file diff --git a/427.bundle.js.LICENSE.txt b/229.bundle.js.LICENSE.txt similarity index 100% rename from 427.bundle.js.LICENSE.txt rename to 229.bundle.js.LICENSE.txt diff --git a/229.bundle.js.map b/229.bundle.js.map new file mode 100644 index 000000000..7c275ec4f --- /dev/null +++ b/229.bundle.js.map @@ -0,0 +1 @@ +{"version":3,"file":"229.bundle.js","mappings":";UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,kICKEC,EAAAA,EAAAA,MAEN,MAAMC,EAAc,uCACdC,EAAc,IAAIC,EAAAA,EAClBC,EAAiB,IAAIC,EAAAA,EACvBJ,EACAC,OACAI,GAGJJ,EAAYK,UAAS,GAErB,IAAIC,EAA2B,GAY/BC,eAAeC,EACXC,EACAC,EACAC,EACAC,EACAC,GAAiB,GAEjBC,QAAQC,IAAI,6CACZ,MAAMC,EAAYC,YAAYC,MAG9B,IAAIC,EAEJ,IACIA,EAAUjB,EAAekB,wBAAwBX,GACnD,MAAOY,GACL,MAAM,IAAIC,MAAM,sCAGpB,MAAMC,EAAaJ,EAAQK,KAC3B,IAAKL,EAAQM,YAAYf,GACrB,MAAM,IAAIY,MAAM,WAAWC,+BAAwCb,KAEvE,MAAMgB,EAAW,GAAGH,KAAcb,IAIlC,IAAIiB,EAEJ,IACIA,QAAgBzB,EAAe0B,cAAcC,kBACzCpB,GAEN,MAAOY,GACL,MAAM,IAAIC,MAAM,iCAIpB,GAAIhB,IAAqBG,EAAc,CACnC,MAAMqB,QAA8B5B,EAAe6B,eAC/CtB,EACAC,EACAC,EACAqB,EAAAA,GAAWC,YAAYrB,IAE3BV,EAAeF,YAAYkC,UAAUR,EAAUI,GAC/CxB,EAAmBG,EAIvB,MAAM0B,EAAY,I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B,GAE3F,CAID,IAAKP,EAAW,MAAM,IAAIjN,MAAM,yDAChCiN,EAAYA,EAAUU,QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpFvE,EAAoB3B,EAAIwF,YClBxB7D,EAAoBwE,EAAIC,KAAKV,SAAW,GAIxC,IAAIW,EAAkB,CACrB,IAAK,GAgBN1E,EAAoBmD,EAAEV,EAAI,CAACW,EAASE,KAE/BoB,EAAgBtB,IAElBU,cAAc9D,EAAoB3B,EAAI2B,EAAoBuD,EAAEH,GAE9D,EAGD,IAAIuB,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBzC,KAAK5D,KAAKqG,GAC9DA,EAAmBzC,KAvBCtH,IACnB,IAAKyH,EAAUwC,EAAaC,GAAWlK,EACvC,IAAI,IAAIqF,KAAY4E,EAChB7E,EAAoBgD,EAAE6B,EAAa5E,KACrCD,EAAoBO,EAAEN,GAAY4E,EAAY5E,IAIhD,IADG6E,GAASA,EAAQ9E,GACdqC,EAASlE,QACduG,EAAgBrC,EAAS0C,OAAS,EACnCH,EAA2BhK,EAAK,MVnB7BzF,EAAO6K,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChBpE,QAAQiH,IAAI,CAClBrD,EAAoBrJ,EAAE,KACtBqJ,EAAoBrJ,EAAE,OACpB4F,KAAKpH,GWJiB6K,EAAoBQ","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/../../src/worker.ts","webpack://aleo-website/../node_modules/comlink/dist/esm/comlink.mjs","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(357),\n\t\t__webpack_require__.e(857)\n\t]).then(next);\n};","import \"./polyfill/shared\";\nimport {initThreadPool, ProgramManager, PrivateKey, verifyFunctionExecution, FunctionKeyPair} from \"./browser\";\nimport { AleoKeyProvider, AleoKeyProviderParams} from \"./function-key-provider\";\nimport { expose } from \"comlink\";\n\nawait initThreadPool();\n\nconst defaultHost = \"https://api.explorer.provable.com/v1\";\nconst keyProvider = new AleoKeyProvider();\nconst programManager = new ProgramManager(\n defaultHost,\n keyProvider,\n undefined\n);\n\nkeyProvider.useCache(true);\n\nlet lastLocalProgram: string = \"\";\n\nexport interface WorkerAPI {\n run: (\n localProgram: string,\n aleoFunction: string,\n inputs: string[],\n privateKey: string\n ) => Promise<{ outputs: any; execution: string } | string>;\n\n getPrivateKey: () => Promise;\n}\nasync function run(\n localProgram: string,\n aleoFunction: string,\n inputs: string[],\n privateKey: string,\n proveExecution = false\n) {\n console.log(\"Web worker: Executing function locally...\");\n const startTime = performance.now();\n\n // Ensure the program is valid and that it contains the function specified\n let program;\n\n try {\n program = programManager.createProgramFromSource(localProgram);\n } catch (e) {\n throw new Error(\"Error creating program from source\");\n }\n\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw new Error(`Program ${program_id} does not contain function ${aleoFunction}`);\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n\n\n // Get the program imports\n let imports;\n\n try {\n imports = await programManager.networkClient.getProgramImports(\n localProgram\n );\n } catch (e) {\n throw new Error(\"Error getting program imports\");\n }\n\n // Get the proving and verifying keys for the function\n if (lastLocalProgram !== localProgram) {\n const keys = await programManager.synthesizeKeys(\n localProgram,\n aleoFunction,\n inputs,\n PrivateKey.from_string(privateKey)\n );\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n lastLocalProgram = localProgram;\n }\n\n // Pass the cache key to the execute function\n const keyParams = new AleoKeyProviderParams({\n cacheKey: cacheKey,\n });\n\n // Execute the function locally\n const response = await programManager.run(\n localProgram,\n aleoFunction,\n inputs,\n proveExecution,\n imports,\n keyParams,\n undefined,\n undefined,\n PrivateKey.from_string(privateKey),\n );\n\n // Return the outputs to the main thread\n console.log(\n `Web worker: Local execution completed in ${\n performance.now() - startTime\n } ms`\n );\n const outputs = response.getOutputs();\n const execution = response.getExecution();\n let executionString = \"\";\n\n let keys;\n\n try {\n keys = keyProvider.getKeys(cacheKey);\n } catch (e) {\n throw new Error(\"Could not get verifying key\");\n }\n\n const verifyingKey = keys[1];\n\n if (execution) {\n verifyFunctionExecution(\n execution,\n verifyingKey,\n program,\n \"hello\"\n );\n executionString = execution.toString();\n console.log(\"Execution verified successfully: \" + execution);\n } else {\n executionString = \"\";\n }\n\n console.log(`Function execution response: ${outputs}`);\n\n return { outputs: outputs, execution: executionString };\n}\n\nasync function getPrivateKey() {\n const privateKey = new PrivateKey();\n return privateKey.to_string();\n}\n\nconst workerAPI = { run, getPrivateKey };\nexpose(workerAPI);\n","/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nconst proxyMarker = Symbol(\"Comlink.proxy\");\nconst createEndpoint = Symbol(\"Comlink.endpoint\");\nconst releaseProxy = Symbol(\"Comlink.releaseProxy\");\nconst finalizer = Symbol(\"Comlink.finalizer\");\nconst throwMarker = Symbol(\"Comlink.thrown\");\nconst isObject = (val) => (typeof val === \"object\" && val !== null) || typeof val === \"function\";\n/**\n * Internal transfer handle to handle objects marked to proxy.\n */\nconst proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n};\n/**\n * Internal transfer handler to handle thrown exceptions.\n */\nconst throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n};\n/**\n * Allows customizing the serialization of certain values.\n */\nconst transferHandlers = new Map([\n [\"proxy\", proxyTransferHandler],\n [\"throw\", throwTransferHandler],\n]);\nfunction isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === \"*\") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n}\nfunction expose(obj, ep = globalThis, allowedOrigins = [\"*\"]) {\n ep.addEventListener(\"message\", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin '${ev.origin}' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case \"GET\" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case \"SET\" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case \"APPLY\" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case \"CONSTRUCT\" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case \"ENDPOINT\" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case \"RELEASE\" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === \"RELEASE\" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener(\"message\", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === \"function\") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError(\"Unserializable return value\"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n}\nfunction isMessagePort(endpoint) {\n return endpoint.constructor.name === \"MessagePort\";\n}\nfunction closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n}\nfunction wrap(ep, target) {\n return createProxy(ep, [], target);\n}\nfunction throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error(\"Proxy has been released and is not useable\");\n }\n}\nfunction releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: \"RELEASE\" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n}\nconst proxyCounter = new WeakMap();\nconst proxyFinalizers = \"FinalizationRegistry\" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\nfunction registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n}\nfunction unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n}\nfunction createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === \"then\") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: \"GET\" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: \"SET\" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: \"ENDPOINT\" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === \"bind\") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"APPLY\" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"CONSTRUCT\" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n}\nfunction myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n}\nfunction processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n}\nconst transferCache = new WeakMap();\nfunction transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n}\nfunction proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n}\nfunction windowEndpoint(w, context = globalThis, targetOrigin = \"*\") {\n return {\n postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\n addEventListener: context.addEventListener.bind(context),\n removeEventListener: context.removeEventListener.bind(context),\n };\n}\nfunction toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: \"HANDLER\" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: \"RAW\" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n}\nfunction fromWireValue(value) {\n switch (value.type) {\n case \"HANDLER\" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case \"RAW\" /* WireValueType.RAW */:\n return value.value;\n }\n}\nfunction requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener(\"message\", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener(\"message\", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n}\nfunction generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join(\"-\");\n}\n\nexport { createEndpoint, expose, finalizer, proxy, proxyMarker, releaseProxy, transfer, transferHandlers, windowEndpoint, wrap };\n//# sourceMappingURL=comlink.mjs.map\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,857], () => (__webpack_require__(8229)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t229: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","initThreadPool","defaultHost","keyProvider","AleoKeyProvider","programManager","ProgramManager","undefined","useCache","lastLocalProgram","async","run","localProgram","aleoFunction","inputs","privateKey","proveExecution","console","log","startTime","performance","now","program","createProgramFromSource","e","Error","program_id","id","hasFunction","cacheKey","imports","networkClient","getProgramImports","keys","synthesizeKeys","PrivateKey","from_string","cacheKeys","keyParams","AleoKeyProviderParams","response","outputs","getOutputs","execution","getExecution","executionString","getKeys","verifyingKey","verifyFunctionExecution","toString","getPrivateKey","to_string","workerAPI","expose","proxyMarker","Symbol","createEndpoint","releaseProxy","finalizer","throwMarker","isObject","val","transferHandlers","Map","canHandle","serialize","obj","port1","port2","MessageChannel","deserialize","port","start","createProxy","target","value","serialized","isError","message","name","stack","Object","assign","ep","globalThis","allowedOrigins","addEventListener","callback","ev","data","origin","allowedOrigin","RegExp","test","isAllowedOrigin","warn","type","path","argumentList","map","fromWireValue","returnValue","parent","slice","reduce","prop","rawValue","apply","proxy","transfers","transferCache","set","transfer","Promise","resolve","catch","then","wireValue","transferables","toWireValue","postMessage","removeEventListener","closeEndPoint","error","TypeError","endpoint","constructor","isMessagePort","close","throwIfProxyReleased","isReleased","releaseEndpoint","requestResponseMessage","proxyCounter","WeakMap","proxyFinalizers","FinalizationRegistry","newCount","get","isProxyReleased","Proxy","_target","unregister","unregisterProxy","length","r","p","bind","_thisArg","rawArgumentList","last","processArguments","construct","register","registerProxy","processed","v","arr","Array","prototype","concat","handler","serializedValue","msg","fill","Math","floor","random","Number","MAX_SAFE_INTEGER","join","l","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","queue","d","forEach","fn","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","rej","deps","dep","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","fulfilled","j","every","key","splice","definition","o","defineProperty","enumerable","f","chunkId","all","promises","u","g","this","Function","window","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","replace","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/258.bundle.js b/258.bundle.js deleted file mode 100644 index 96bc27ad0..000000000 --- a/258.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[258,877],{81:(_,t,e)=>{_.exports=e.p+"58342153fc9a001d7976.wasm"},977:(_,t,e)=>{_.exports=e.p+"2d6a4d794221941c07b8.js"},877:(_,t,e)=>{e.a(_,(async(_,r)=>{try{function i(_,t,e,r){return new Promise((n=>{const i=new Worker(_,{type:"module"});i.addEventListener("message",(_=>{setTimeout((()=>{n(i),i.unref&&i.unref()}),0)}),{capture:!0,once:!0}),i.postMessage({module:t,memory:e,address:r})}))}let o;e.d(t,{$7:()=>B_,Ao:()=>q_,BP:()=>M_,D0:()=>A_,Fs:()=>L_,KC:()=>U_,LW:()=>E_,OS:()=>O_,Yc:()=>J_,ZD:()=>C_,ZF:()=>I_,ZX:()=>$_,Zc:()=>R_,c7:()=>j_,hv:()=>D_,pF:()=>N_,pV:()=>T_,qp:()=>z_,to:()=>W_});const a=new Array(128).fill(void 0);function s(_){return a[_]}a.push(void 0,null,!0,!1);let c=a.length;function g(_){_<132||(a[_]=c,c=_)}function w(_){const t=s(_);return g(_),t}const d="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&d.decode();let b=null;function l(){return null!==b&&b.buffer===o.memory.buffer||(b=new Uint8Array(o.memory.buffer)),b}function u(_,t){return _>>>=0,d.decode(l().slice(_,_+t))}function f(_){c===a.length&&a.push(a.length+1);const t=c;return c=a[t],a[t]=_,t}let p=0;const y="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},m=function(_,t){const e=y.encode(_);return t.set(e),{read:_.length,written:e.length}};function h(_,t,e){if(void 0===e){const e=y.encode(_),r=t(e.length,1)>>>0;return l().subarray(r,r+e.length).set(e),p=e.length,r}let r=_.length,n=t(r,1)>>>0;const i=l();let o=0;for(;o127)break;i[n+o]=t}if(o!==r){0!==o&&(_=_.slice(o)),n=e(n,r,r=o+3*_.length,1)>>>0;const t=l().subarray(n+o,n+r);o+=m(_,t).written,n=e(n,r,o,1)>>>0}return p=o,n}function v(_){return null==_}let k=null;function P(){return null!==k&&k.buffer===o.memory.buffer||(k=new Int32Array(o.memory.buffer)),k}function S(_){const t=typeof _;if("number"==t||"boolean"==t||null==_)return`${_}`;if("string"==t)return`"${_}"`;if("symbol"==t){const t=_.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=_.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(_)){const t=_.length;let e="[";t>0&&(e+=S(_[0]));for(let r=1;r1))return toString.call(_);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(_)+")"}catch(_){return"Object"}return _ instanceof Error?`${_.name}: ${_.message}\n${_.stack}`:r}const x="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>{o.__wbindgen_export_3.get(_.dtor)(_.a,_.b)}));function V(_,t,e,r){const n={a:_,b:t,cnt:1,dtor:e},i=(..._)=>{n.cnt++;const t=n.a;n.a=0;try{return r(t,n.b,..._)}finally{0==--n.cnt?(o.__wbindgen_export_3.get(n.dtor)(t,n.b),x.unregister(n)):n.a=t}};return i.original=n,x.register(i,n,n),i}function F(_,t,e){o._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(_,t,f(e))}function T(_,t){if(!(_ instanceof t))throw new Error(`expected instance of ${t.name}`);return _.ptr}function R(_,t){const e=t(1*_.length,1)>>>0;return l().set(_,e/1),p=_.length,e}function z(_,t,e,r){try{const a=o.__wbindgen_add_to_stack_pointer(-16);T(_,q),T(t,p_),T(e,r_);const s=h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.verifyFunctionExecution(a,_.__wbg_ptr,t.__wbg_ptr,e.__wbg_ptr,s,c);var n=P()[a/4+0],i=P()[a/4+1];if(P()[a/4+2])throw w(i);return 0!==n}finally{o.__wbindgen_add_to_stack_pointer(16)}}let A=null;function O(){return null!==A&&A.buffer===o.memory.buffer||(A=new BigInt64Array(o.memory.buffer)),A}function j(_,t){return _>>>=0,l().subarray(_/1,_/1+t)}function K(_){o.runRayonThread(_)}function C(_,t){return w(o.initThreadPool(f(_),t))}function E(_,t){try{return _.apply(this,t)}catch(_){o.__wbindgen_exn_store(f(_))}}function M(_,t,e,r){o.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(_,t,f(e),f(r))}const B="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_address_free(_>>>0)));let U=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,B.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,B.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_address_free(_)}static from_private_key(t){T(t,G);const e=o.address_from_private_key(t.__wbg_ptr);return _.__wrap(e)}static from_view_key(t){T(t,m_);const e=o.address_from_view_key(t.__wbg_ptr);return _.__wrap(e)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.address_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.address_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}verify(_,t){const e=R(_,o.__wbindgen_malloc),r=p;T(t,b_);return 0!==o.address_verify(this.__wbg_ptr,e,r,t.__wbg_ptr)}};const I="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_execution_free(_>>>0)));let q=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,I.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,I.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_execution_free(_)}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.execution_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.execution_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const W="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_executionresponse_free(_>>>0)));let $=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,W.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,W.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_executionresponse_free(_)}getOutputs(){return w(o.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const _=o.executionresponse_getExecution(this.__wbg_ptr);return 0===_?void 0:q.__wrap(_)}getKeys(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.executionresponse_getKeys(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return L.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const _=o.executionresponse_getProvingKey(this.__wbg_ptr);return 0===_?void 0:a_.__wrap(_)}getVerifyingKey(){const _=o.executionresponse_getVerifyingKey(this.__wbg_ptr);return p_.__wrap(_)}getFunctionId(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.executionresponse_getFunctionId(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}getProgram(){const _=o.executionresponse_getProgram(this.__wbg_ptr);return r_.__wrap(_)}};const D="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_field_free(_>>>0)));let N=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,D.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,D.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_field_free(_)}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.field_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.field_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const J="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_keypair_free(_>>>0)));class L{static __wrap(_){_>>>=0;const t=Object.create(L.prototype);return t.__wbg_ptr=_,J.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,J.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_keypair_free(_)}constructor(_,t){T(_,a_);var e=_.__destroy_into_raw();T(t,p_);var r=t.__destroy_into_raw();const n=o.keypair_new(e,r);return this.__wbg_ptr=n>>>0,this}provingKey(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.keypair_provingKey(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return a_.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.keypair_verifyingKey(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return p_.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}}const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_metadata_free(_>>>0)));let Z=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,H.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_metadata_free(_)}get name(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_name(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set name(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_name(this.__wbg_ptr,t,e)}get locator(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_locator(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set locator(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_locator(this.__wbg_ptr,t,e)}get prover(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_prover(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set prover(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_prover(this.__wbg_ptr,t,e)}get verifier(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_verifier(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set verifier(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_verifier(this.__wbg_ptr,t,e)}get verifyingKey(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_verifyingKey(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set verifyingKey(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,t,e)}static baseUrl(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.metadata_baseUrl(n);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static bond_public(){const t=o.metadata_bond_public();return _.__wrap(t)}static bond_validator(){const t=o.metadata_bond_validator();return _.__wrap(t)}static claim_unbond_public(){const t=o.metadata_claim_unbond_public();return _.__wrap(t)}static fee_private(){const t=o.metadata_fee_private();return _.__wrap(t)}static fee_public(){const t=o.metadata_fee_public();return _.__wrap(t)}static inclusion(){const t=o.metadata_inclusion();return _.__wrap(t)}static join(){const t=o.metadata_join();return _.__wrap(t)}static set_validator_state(){const t=o.metadata_set_validator_state();return _.__wrap(t)}static split(){const t=o.metadata_split();return _.__wrap(t)}static transfer_private(){const t=o.metadata_transfer_private();return _.__wrap(t)}static transfer_private_to_public(){const t=o.metadata_transfer_private_to_public();return _.__wrap(t)}static transfer_public(){const t=o.metadata_transfer_public();return _.__wrap(t)}static transfer_public_as_signer(){const t=o.metadata_transfer_public_as_signer();return _.__wrap(t)}static transfer_public_to_private(){const t=o.metadata_transfer_public_to_private();return _.__wrap(t)}static unbond_public(){const t=o.metadata_unbond_public();return _.__wrap(t)}};const Q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_offlinequery_free(_>>>0)));let X=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,Q.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Q.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_offlinequery_free(_)}constructor(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.offlinequery_new(r,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return this.__wbg_ptr=t>>>0,this}finally{o.__wbindgen_add_to_stack_pointer(16)}}addStatePath(_,t){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p,a=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.offlinequery_addStatePath(r,this.__wbg_ptr,n,i,a,s);var e=P()[r/4+0];if(P()[r/4+1])throw w(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.offlinequery_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.offlinequery_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const Y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_privatekey_free(_>>>0)));let G=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,Y.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Y.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_privatekey_free(_)}constructor(){const _=o.privatekey_new();return this.__wbg_ptr=_>>>0,this}static from_seed_unchecked(t){const e=R(t,o.__wbindgen_malloc),r=p,n=o.privatekey_from_seed_unchecked(e,r);return _.__wrap(n)}static from_string(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.privatekey_from_string(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.privatekey_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}to_view_key(){const _=o.privatekey_to_view_key(this.__wbg_ptr);return m_.__wrap(_)}to_address(){const _=o.privatekey_to_address(this.__wbg_ptr);return U.__wrap(_)}sign(_){const t=R(_,o.__wbindgen_malloc),e=p,r=o.privatekey_sign(this.__wbg_ptr,t,e);return b_.__wrap(r)}static newEncrypted(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekey_newEncrypted(r,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return t_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekey_toCiphertext(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return t_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,e){try{const i=o.__wbindgen_add_to_stack_pointer(-16);T(t,t_);const a=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.privatekey_fromPrivateKeyCiphertext(i,t.__wbg_ptr,a,s);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw w(n);return _.__wrap(r)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const __="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_privatekeyciphertext_free(_>>>0)));let t_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,__.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,__.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_privatekeyciphertext_free(_)}static encryptPrivateKey(t,e){try{const i=o.__wbindgen_add_to_stack_pointer(-16);T(t,G);const a=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.privatekey_toCiphertext(i,t.__wbg_ptr,a,s);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw w(n);return _.__wrap(r)}finally{o.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekeyciphertext_decryptToPrivateKey(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return G.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.privatekeyciphertext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.privatekeyciphertext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const e_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_program_free(_>>>0)));let r_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,e_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,e_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_program_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.program_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.program_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}hasFunction(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;return 0!==o.program_hasFunction(this.__wbg_ptr,t,e)}getFunctions(){return w(o.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getFunctionInputs(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.program_getMappings(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return w(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getRecordMembers(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getStructMembers(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=o.program_getCreditsProgram();return _.__wrap(t)}id(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.program_id(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}address(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.program_address(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return U.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){T(t,_);return 0!==o.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return w(o.program_getImports(this.__wbg_ptr))}};const n_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_programmanager_free(_>>>0)));let i_=class{__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,n_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_programmanager_free(_)}static buildDeploymentTransaction(_,t,e,r,n,i,a,s,c){T(_,G);const g=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),d=p;let b=0;v(r)||(T(r,w_),b=r.__destroy_into_raw());var l=v(n)?0:h(n,o.__wbindgen_malloc,o.__wbindgen_realloc),u=p;let y=0;v(a)||(T(a,a_),y=a.__destroy_into_raw());let m=0;v(s)||(T(s,p_),m=s.__destroy_into_raw());let k=0;v(c)||(T(c,X),k=c.__destroy_into_raw());return w(o.programmanager_buildDeploymentTransaction(_.__wbg_ptr,g,d,e,b,l,u,v(i)?0:f(i),y,m,k))}static estimateDeploymentFee(_,t){const e=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;return w(o.programmanager_estimateDeploymentFee(e,r,v(t)?0:f(t)))}static estimateProgramNameCost(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.programmanager_estimateProgramNameCost(r,n,i);var t=O()[r/8+0],e=P()[r/4+2];if(P()[r/4+3])throw w(e);return BigInt.asUintN(64,t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(_,t,e,r,n,i,a,s,c,g,d){T(_,G);const b=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),l=p,u=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(s)||(T(s,a_),m=s.__destroy_into_raw());let k=0;v(c)||(T(c,p_),k=c.__destroy_into_raw());var P=v(g)?0:h(g,o.__wbindgen_malloc,o.__wbindgen_realloc),S=p;let x=0;v(d)||(T(d,X),x=d.__destroy_into_raw());return w(o.programmanager_executeFunctionOffline(_.__wbg_ptr,b,l,u,y,f(r),n,i,v(a)?0:f(a),m,k,P,S,x))}static buildExecutionTransaction(_,t,e,r,n,i,a,s,c,g,d,b,l){T(_,G);const u=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p,m=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),k=p;let P=0;v(i)||(T(i,w_),P=i.__destroy_into_raw());var S=v(a)?0:h(a,o.__wbindgen_malloc,o.__wbindgen_realloc),x=p;let V=0;v(c)||(T(c,a_),V=c.__destroy_into_raw());let F=0;v(g)||(T(g,p_),F=g.__destroy_into_raw());let R=0;v(d)||(T(d,a_),R=d.__destroy_into_raw());let z=0;v(b)||(T(b,p_),z=b.__destroy_into_raw());let A=0;v(l)||(T(l,X),A=l.__destroy_into_raw());return w(o.programmanager_buildExecutionTransaction(_.__wbg_ptr,u,y,m,k,f(r),n,P,S,x,v(s)?0:f(s),V,F,R,z,A))}static estimateExecutionFee(_,t,e,r,n,i,a,s,c){T(_,G);const g=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),d=p,b=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),l=p;var u=v(n)?0:h(n,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(a)||(T(a,a_),m=a.__destroy_into_raw());let k=0;v(s)||(T(s,p_),k=s.__destroy_into_raw());let P=0;v(c)||(T(c,X),P=c.__destroy_into_raw());return w(o.programmanager_estimateExecutionFee(_.__wbg_ptr,g,d,b,l,f(r),u,y,v(i)?0:f(i),m,k,P))}static estimateFinalizeFee(_,t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.programmanager_estimateFinalizeFee(n,i,a,s,c);var e=O()[n/8+0],r=P()[n/4+2];if(P()[n/4+3])throw w(r);return BigInt.asUintN(64,e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(_,t,e,r,n,i,a,s,c,g,d){T(_,G),T(t,w_);var b=t.__destroy_into_raw();T(e,w_);var l=e.__destroy_into_raw();let u=0;v(n)||(T(n,w_),u=n.__destroy_into_raw());var f=v(i)?0:h(i,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(a)||(T(a,a_),m=a.__destroy_into_raw());let k=0;v(s)||(T(s,p_),k=s.__destroy_into_raw());let P=0;v(c)||(T(c,a_),P=c.__destroy_into_raw());let S=0;v(g)||(T(g,p_),S=g.__destroy_into_raw());let x=0;v(d)||(T(d,X),x=d.__destroy_into_raw());return w(o.programmanager_buildJoinTransaction(_.__wbg_ptr,b,l,r,u,f,y,m,k,P,S,x))}static buildSplitTransaction(_,t,e,r,n,i,a){T(_,G),T(e,w_);var s=e.__destroy_into_raw(),c=v(r)?0:h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),g=p;let d=0;v(n)||(T(n,a_),d=n.__destroy_into_raw());let b=0;v(i)||(T(i,p_),b=i.__destroy_into_raw());let l=0;v(a)||(T(a,X),l=a.__destroy_into_raw());return w(o.programmanager_buildSplitTransaction(_.__wbg_ptr,t,s,c,g,d,b,l))}static buildTransferTransaction(_,t,e,r,n,i,a,s,c,g,d,b,l){T(_,G);const u=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),f=p,y=h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),m=p;let k=0;v(n)||(T(n,w_),k=n.__destroy_into_raw());let P=0;v(a)||(T(a,w_),P=a.__destroy_into_raw());var S=v(s)?0:h(s,o.__wbindgen_malloc,o.__wbindgen_realloc),x=p;let V=0;v(c)||(T(c,a_),V=c.__destroy_into_raw());let F=0;v(g)||(T(g,p_),F=g.__destroy_into_raw());let R=0;v(d)||(T(d,a_),R=d.__destroy_into_raw());let z=0;v(b)||(T(b,p_),z=b.__destroy_into_raw());let A=0;v(l)||(T(l,X),A=l.__destroy_into_raw());return w(o.programmanager_buildTransferTransaction(_.__wbg_ptr,t,u,f,y,m,k,i,P,S,x,V,F,R,z,A))}static synthesizeKeyPair(_,t,e,r,n){T(_,G);const i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;return w(o.programmanager_synthesizeKeyPair(_.__wbg_ptr,i,a,s,c,f(r),v(n)?0:f(n)))}};const o_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_provingkey_free(_>>>0)));let a_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,o_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,o_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_provingkey_free(_)}isBondPublicProver(){return 0!==o.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==o.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==o.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==o.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==o.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==o.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==o.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==o.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==o.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==o.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==o.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==o.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==o.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==o.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==o.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_checksum(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}copy(){const t=o.provingkey_copy(this.__wbg_ptr);return _.__wrap(t)}static fromBytes(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=R(t,o.__wbindgen_malloc),a=p;o.provingkey_fromBytes(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.provingkey_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_toBytes(n,this.__wbg_ptr);var _=P()[n/4+0],t=P()[n/4+1],e=P()[n/4+2];if(P()[n/4+3])throw w(e);var r=j(_,t).slice();return o.__wbindgen_free(_,1*t,1),r}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const s_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_recordciphertext_free(_>>>0)));let c_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,s_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,s_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_recordciphertext_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.recordciphertext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordciphertext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}decrypt(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16);T(_,m_),o.recordciphertext_decrypt(r,this.__wbg_ptr,_.__wbg_ptr);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}isOwner(_){T(_,m_);return 0!==o.recordciphertext_isOwner(this.__wbg_ptr,_.__wbg_ptr)}};const g_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_recordplaintext_free(_>>>0)));let w_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,g_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,g_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_recordplaintext_free(_)}commitment(_,t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.recordplaintext_commitment(n,this.__wbg_ptr,i,a,s,c);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return N.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.recordplaintext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordplaintext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}microcredits(){const _=o.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,_)}nonce(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordplaintext_nonce(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}serialNumberString(_,t,e){let r,n;try{const b=o.__wbindgen_add_to_stack_pointer(-16);T(_,G);const l=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),f=p,y=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),m=p;o.recordplaintext_serialNumberString(b,this.__wbg_ptr,_.__wbg_ptr,l,f,y,m);var i=P()[b/4+0],a=P()[b/4+1],s=P()[b/4+2],c=P()[b/4+3],g=i,d=a;if(c)throw g=0,d=0,w(s);return r=g,n=d,u(g,d)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(r,n,1)}}};const d_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_signature_free(_>>>0)));let b_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,d_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,d_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_signature_free(_)}static sign(t,e){T(t,G);const r=R(e,o.__wbindgen_malloc),n=p,i=o.privatekey_sign(t.__wbg_ptr,r,n);return _.__wrap(i)}verify(_,t){T(_,U);const e=R(t,o.__wbindgen_malloc),r=p;return 0!==o.signature_verify(this.__wbg_ptr,_.__wbg_ptr,e,r)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.signature_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.signature_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const l_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_transaction_free(_>>>0)));let u_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,l_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,l_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_transaction_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.transaction_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}transactionId(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_transactionId(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}transactionType(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_transactionType(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const f_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_verifyingkey_free(_>>>0)));let p_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,f_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,f_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_verifyingkey_free(_)}static bondPublicVerifier(){const t=o.verifyingkey_bondPublicVerifier();return _.__wrap(t)}static bondValidatorVerifier(){const t=o.verifyingkey_bondValidatorVerifier();return _.__wrap(t)}static claimUnbondPublicVerifier(){const t=o.verifyingkey_claimUnbondPublicVerifier();return _.__wrap(t)}static feePrivateVerifier(){const t=o.verifyingkey_feePrivateVerifier();return _.__wrap(t)}static feePublicVerifier(){const t=o.verifyingkey_feePublicVerifier();return _.__wrap(t)}static inclusionVerifier(){const t=o.verifyingkey_inclusionVerifier();return _.__wrap(t)}static joinVerifier(){const t=o.verifyingkey_joinVerifier();return _.__wrap(t)}static setValidatorStateVerifier(){const t=o.verifyingkey_setValidatorStateVerifier();return _.__wrap(t)}static splitVerifier(){const t=o.verifyingkey_splitVerifier();return _.__wrap(t)}static transferPrivateVerifier(){const t=o.verifyingkey_transferPrivateVerifier();return _.__wrap(t)}static transferPrivateToPublicVerifier(){const t=o.verifyingkey_transferPrivateToPublicVerifier();return _.__wrap(t)}static transferPublicVerifier(){const t=o.verifyingkey_transferPublicVerifier();return _.__wrap(t)}static transferPublicAsSignerVerifier(){const t=o.verifyingkey_transferPublicAsSignerVerifier();return _.__wrap(t)}static transferPublicToPrivateVerifier(){const t=o.verifyingkey_transferPublicToPrivateVerifier();return _.__wrap(t)}static unbondPublicVerifier(){const t=o.verifyingkey_unbondPublicVerifier();return _.__wrap(t)}isBondPublicVerifier(){return 0!==o.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==o.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==o.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==o.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==o.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==o.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==o.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==o.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==o.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==o.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==o.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==o.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==o.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==o.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==o.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_checksum(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}copy(){const t=o.verifyingkey_copy(this.__wbg_ptr);return _.__wrap(t)}static fromBytes(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=R(t,o.__wbindgen_malloc),a=p;o.verifyingkey_fromBytes(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.verifyingkey_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_toBytes(n,this.__wbg_ptr);var _=P()[n/4+0],t=P()[n/4+1],e=P()[n/4+2];if(P()[n/4+3])throw w(e);var r=j(_,t).slice();return o.__wbindgen_free(_,1*t,1),r}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const y_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_viewkey_free(_>>>0)));let m_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,y_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,y_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_viewkey_free(_)}static from_private_key(t){T(t,G);const e=o.privatekey_to_view_key(t.__wbg_ptr);return _.__wrap(e)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.viewkey_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.viewkey_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}to_address(){const _=o.address_from_view_key(this.__wbg_ptr);return U.__wrap(_)}decrypt(_){let t,e;try{const g=o.__wbindgen_add_to_stack_pointer(-16),d=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),b=p;o.viewkey_decrypt(g,this.__wbg_ptr,d,b);var r=P()[g/4+0],n=P()[g/4+1],i=P()[g/4+2],a=P()[g/4+3],s=r,c=n;if(a)throw s=0,c=0,w(i);return t=s,e=c,u(s,c)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(t,e,1)}}};async function h_(_,t){if("function"==typeof Response&&_ instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(_,t)}catch(t){if("application/wasm"==_.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await _.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(_,t);return e instanceof WebAssembly.Instance?{instance:e,module:_}:e}}function v_(){const _={wbg:{}};return _.wbg.__wbindgen_object_drop_ref=function(_){w(_)},_.wbg.__wbg_new_71801a555ad9f2aa=function(){return E((function(){return f(new XMLHttpRequest)}),arguments)},_.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return E((function(_,t,e){s(_).overrideMimeType(u(t,e))}),arguments)},_.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return E((function(_,t,e,r,n,i){s(_).open(u(t,e),u(r,n),0!==i)}),arguments)},_.wbg.__wbg_send_80d29985093c1ec5=function(){return E((function(_){s(_).send()}),arguments)},_.wbg.__wbg_response_7c2e2759084f7279=function(){return E((function(_){return f(s(_).response)}),arguments)},_.wbg.__wbg_status_d485fb5a478426fb=function(){return E((function(_){return s(_).status}),arguments)},_.wbg.__wbg_new_72fb9a18b5ae2624=function(){return f(new Object)},_.wbg.__wbindgen_string_new=function(_,t){return f(u(_,t))},_.wbg.__wbg_set_1f9b04f170055d33=function(){return E((function(_,t,e){return Reflect.set(s(_),s(t),s(e))}),arguments)},_.wbg.__wbg_new_ab6fd82b10560829=function(){return E((function(){return f(new Headers)}),arguments)},_.wbg.__wbindgen_object_clone_ref=function(_){return f(s(_))},_.wbg.__wbg_new_0d76b0581eca6298=function(){return E((function(){return f(new AbortController)}),arguments)},_.wbg.__wbg_signal_a61f78a3478fd9bc=function(_){return f(s(_).signal)},_.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return E((function(_,t,e,r,n){s(_).append(u(t,e),u(r,n))}),arguments)},_.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(_){let t;try{t=s(_)instanceof Response}catch(_){t=!1}return t},_.wbg.__wbg_status_61a01141acd3cf74=function(_){return s(_).status},_.wbg.__wbg_url_5f6dc4009ac5f99d=function(_,t){const e=h(s(t).url,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbg_headers_9620bfada380764a=function(_){return f(s(_).headers)},_.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return f(Symbol.iterator)},_.wbg.__wbg_get_e3c254076557e348=function(){return E((function(_,t){return f(Reflect.get(s(_),s(t)))}),arguments)},_.wbg.__wbindgen_is_function=function(_){return"function"==typeof s(_)},_.wbg.__wbg_call_27c0f87801dedf93=function(){return E((function(_,t){return f(s(_).call(s(t)))}),arguments)},_.wbg.__wbindgen_is_object=function(_){const t=s(_);return"object"==typeof t&&null!==t},_.wbg.__wbg_next_40fc327bfc8770e6=function(_){return f(s(_).next)},_.wbg.__wbg_next_196c84450b364254=function(){return E((function(_){return f(s(_).next())}),arguments)},_.wbg.__wbg_done_298b57d23c0fc80c=function(_){return s(_).done},_.wbg.__wbg_value_d93c65011f51a456=function(_){return f(s(_).value)},_.wbg.__wbg_abort_2aa7521d5690750e=function(_){s(_).abort()},_.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return E((function(_){return f(JSON.stringify(s(_)))}),arguments)},_.wbg.__wbindgen_string_get=function(_,t){const e=s(t),r="string"==typeof e?e:void 0;var n=v(r)?0:h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;P()[_/4+1]=i,P()[_/4+0]=n},_.wbg.__wbg_log_0159ca40cddf5b15=function(_,t){console.log(u(_,t))},_.wbg.__wbindgen_bigint_from_u64=function(_){return f(BigInt.asUintN(64,_))},_.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return E((function(_,t,e){return f(s(_).call(s(t),s(e)))}),arguments)},_.wbg.__wbg_transaction_new=function(_){return f(u_.__wrap(_))},_.wbg.__wbg_keypair_new=function(_){return f(L.__wrap(_))},_.wbg.__wbindgen_module=function(){return f(x_.__wbindgen_wasm_module)},_.wbg.__wbindgen_memory=function(){return f(o.memory)},_.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a=function(_,t,e,r){return f(i(s(_),s(t),s(e),r>>>0))},_.wbg.__wbg_executionresponse_new=function(_){return f($.__wrap(_))},_.wbg.__wbg_newwithlength_66ae46612e7f0234=function(_){return f(new Array(_>>>0))},_.wbg.__wbg_set_d4638f722068f043=function(_,t,e){s(_)[t>>>0]=w(e)},_.wbg.__wbindgen_cb_drop=function(_){const t=w(_).original;if(1==t.cnt--)return t.a=0,!0;return!1},_.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return f(new Array)},_.wbg.__wbg_push_a5b05aedc7234f9f=function(_,t){return s(_).push(s(t))},_.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return E((function(_){return f(s(_).arrayBuffer())}),arguments)},_.wbg.__wbg_new_63b92bc8671ed464=function(_){return f(new Uint8Array(s(_)))},_.wbg.__wbg_length_c20a40f15020d68a=function(_){return s(_).length},_.wbg.__wbg_new_81740750da40724f=function(_,t){try{var e={a:_,b:t};const r=new Promise(((_,t)=>{const r=e.a;e.a=0;try{return M(r,e.b,_,t)}finally{e.a=r}}));return f(r)}finally{e.a=e.b=0}},_.wbg.__wbindgen_number_new=function(_){return f(_)},_.wbg.__wbg_new_abda76e883ba8a5f=function(){return f(new Error)},_.wbg.__wbg_stack_658279fe44541cf6=function(_,t){const e=h(s(t).stack,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbg_error_f851667af71bcfc6=function(_,t){let e,r;try{e=_,r=t,console.error(u(_,t))}finally{o.__wbindgen_free(e,r,1)}},_.wbg.__wbg_buffer_12d079cc21e14bdb=function(_){return f(s(_).buffer)},_.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(_,t,e){return f(new Uint8Array(s(_),t>>>0,e>>>0))},_.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return E((function(_,t){s(_).randomFillSync(w(t))}),arguments)},_.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(_,t,e){return f(s(_).subarray(t>>>0,e>>>0))},_.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return E((function(_,t){s(_).getRandomValues(s(t))}),arguments)},_.wbg.__wbg_set_a47bac70306a19a7=function(_,t,e){s(_).set(s(t),e>>>0)},_.wbg.__wbg_crypto_1d1f22824a6a080c=function(_){return f(s(_).crypto)},_.wbg.__wbg_process_4a72847cc503995b=function(_){return f(s(_).process)},_.wbg.__wbg_versions_f686565e586dd935=function(_){return f(s(_).versions)},_.wbg.__wbg_node_104a2ff8d6ea03a2=function(_){return f(s(_).node)},_.wbg.__wbindgen_is_string=function(_){return"string"==typeof s(_)},_.wbg.__wbg_require_cca90b1a94a0255b=function(){return E((function(){return f(module.require)}),arguments)},_.wbg.__wbg_msCrypto_eb05e62b530a1508=function(_){return f(s(_).msCrypto)},_.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(_){return f(new Uint8Array(_>>>0))},_.wbg.__wbg_length_cd7af8117672b8b8=function(_){return s(_).length},_.wbg.__wbg_get_bd8e338fbd5f5cc8=function(_,t){return f(s(_)[t>>>0])},_.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return E((function(){return f(self.self)}),arguments)},_.wbg.__wbg_window_c6fb939a7f436783=function(){return E((function(){return f(window.window)}),arguments)},_.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return E((function(){return f(globalThis.globalThis)}),arguments)},_.wbg.__wbg_global_207b558942527489=function(){return E((function(){return f(global.global)}),arguments)},_.wbg.__wbindgen_is_undefined=function(_){return void 0===s(_)},_.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(_,t){return f(new Function(u(_,t)))},_.wbg.__wbg_has_0af94d20077affa2=function(){return E((function(_,t){return Reflect.has(s(_),s(t))}),arguments)},_.wbg.__wbg_fetch_bc7c8e27076a5c84=function(_){return f(fetch(s(_)))},_.wbg.__wbg_fetch_921fad6ef9e883dd=function(_,t){return f(s(_).fetch(s(t)))},_.wbg.__wbindgen_debug_string=function(_,t){const e=h(S(s(t)),o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbindgen_throw=function(_,t){throw new Error(u(_,t))},_.wbg.__wbindgen_rethrow=function(_){throw w(_)},_.wbg.__wbg_then_a73caa9a87991566=function(_,t,e){return f(s(_).then(s(t),s(e)))},_.wbg.__wbg_then_0c86a60e8fcfe9f6=function(_,t){return f(s(_).then(s(t)))},_.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(_){queueMicrotask(s(_))},_.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(_){return f(s(_).queueMicrotask)},_.wbg.__wbg_resolve_b0083a7967828ec8=function(_){return f(Promise.resolve(s(_)))},_.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return f(Atomics.waitAsync)},_.wbg.__wbg_new_8cccba86b0f574cb=function(_){return f(new Int32Array(s(_)))},_.wbg.__wbg_waitAsync_46d5c36955b71a79=function(_,t,e){return f(Atomics.waitAsync(s(_),t,e))},_.wbg.__wbg_async_19c0400d97cc72fe=function(_){return s(_).async},_.wbg.__wbg_value_571d60108110e917=function(_){return f(s(_).value)},_.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(_){const t=h("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;P()[_/4+1]=e,P()[_/4+0]=t},_.wbg.__wbg_new_d1187ae36d662ef9=function(){return E((function(_,t){return f(new Worker(u(_,t)))}),arguments)},_.wbg.__wbg_setonmessage_503809e5bb51bd33=function(_,t){s(_).onmessage=s(t)},_.wbg.__wbg_of_6a70eed8d41f469c=function(_,t,e){return f(Array.of(s(_),s(t),s(e)))},_.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return E((function(_,t){s(_).postMessage(s(t))}),arguments)},_.wbg.__wbg_data_3ce7c145ca4fbcdc=function(_){return f(s(_).data)},_.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return E((function(_,t,e){return f(new Request(u(_,t),s(e)))}),arguments)},_.wbg.__wbg_responseText_c67ed2d48db10769=function(){return E((function(_,t){const e=s(t).responseText;var r=v(e)?0:h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),n=p;P()[_/4+1]=n,P()[_/4+0]=r}),arguments)},_.wbg.__wbindgen_closure_wrapper5837=function(_,t,e){return f(V(_,t,538,F))},_.wbg.__wbindgen_closure_wrapper5862=function(_,t,e){return f(V(_,t,538,F))},_}function k_(_,t){_.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function P_(_,t){return o=_.exports,x_.__wbindgen_wasm_module=t,A=null,k=null,b=null,o.__wbindgen_start(),o}function S_(_,t){if(void 0!==o)return o;const e=v_();k_(e,t),_ instanceof WebAssembly.Module||(_=new WebAssembly.Module(_));return P_(new WebAssembly.Instance(_,e),_)}async function x_(_,t){if(void 0!==o)return o;const e=v_();("string"==typeof _||"function"==typeof Request&&_ instanceof Request||"function"==typeof URL&&_ instanceof URL)&&(_=fetch(_)),k_(e,t);const{instance:r,module:n}=await h_(await _,e);return P_(r,n)}var n=Object.freeze({__proto__:null,Address:U,Execution:q,ExecutionResponse:$,Field:N,KeyPair:L,Metadata:Z,OfflineQuery:X,PrivateKey:G,PrivateKeyCiphertext:t_,Program:r_,ProgramManager:i_,ProvingKey:a_,RecordCiphertext:c_,RecordPlaintext:w_,Signature:b_,Transaction:u_,VerifyingKey:p_,ViewKey:m_,default:x_,initSync:S_,initThreadPool:C,runRayonThread:K,verifyFunctionExecution:z});const V_="assets/aleo_wasm.wasm";const{initThreadPool:F_,Address:T_,Execution:R_,ExecutionResponse:z_,Field:A_,Metadata:O_,OfflineQuery:j_,Private:K_,PrivateKey:C_,PrivateKeyCiphertext:E_,Program:M_,ProvingKey:B_,RecordCiphertext:U_,RecordPlaintext:I_,ProgramManager:q_,Signature:W_,Transaction:$_,ViewKey:D_,VerifyingKey:N_,verifyFunctionExecution:J_}=await(async(_={})=>{let{importHook:t,serverPath:e,initializeHook:r}=_,i=V_;return null!=e&&(i=e+/[^\/\\]*$/.exec(i)[0]),null!=t&&(i=t(i)),null!=r?await r(x_,i):await x_(i),n})({importHook:()=>new URL(e(81),e.b)});async function L_(_){null==_&&(_=navigator.hardwareConcurrency),console.info(`Spawning ${_} threads`),await F_(new URL(e(977),e.b),_)}r()}catch(H_){r(H_)}}),1)}}]); -//# sourceMappingURL=258.bundle.js.map \ No newline at end of file diff --git a/258.bundle.js.map b/258.bundle.js.map deleted file mode 100644 index a362a5cd4..000000000 --- a/258.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"258.bundle.js","mappings":"wOAAA,SAASA,EAAYC,EAAKC,EAAQC,EAAQC,GAClC,OAAO,IAAIC,SAASC,IAChB,MAAMC,EAAS,IAAIC,OAAOP,EAAK,CAC3BQ,KAAM,WAGVF,EAAOG,iBAAiB,WAAYC,IAGhCC,YAAW,KACPN,EAAQC,GAIJA,EAAOM,OACPN,EAAOM,OAC/B,GACmB,EAAE,GACN,CACCC,SAAS,EACTC,MAAM,IAGVR,EAAOS,YAAY,CACfd,SACAC,SACAC,WACF,GAEd,CAEA,IAAIa,E,uMAEJ,MAAMC,EAAO,IAAIC,MAAM,KAAKC,UAAKC,GAIjC,SAASC,EAAUC,GAAO,OAAOL,EAAKK,EAAK,CAF3CL,EAAKM,UAAKH,EAAW,MAAM,GAAM,GAIjC,IAAII,EAAYP,EAAKQ,OAErB,SAASC,EAAWJ,GACZA,EAAM,MACVL,EAAKK,GAAOE,EACZA,EAAYF,EAChB,CAEA,SAASK,EAAWL,GAChB,MAAMM,EAAMP,EAAUC,GAEtB,OADAI,EAAWJ,GACJM,CACX,CAEA,MAAMC,EAA4C,oBAAhBC,YAA8B,IAAIA,YAAY,QAAS,CAAEC,WAAW,EAAMC,OAAO,IAAU,CAAEC,OAAQA,KAAQ,MAAMC,MAAM,4BAA4B,GAE5J,oBAAhBJ,aAA+BD,EAAkBI,SAC5D,IAAIE,EAAqB,KAEzB,SA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AAI,aAIvBtL,eAAe9a,GAAeqnB,GACX,MAAXA,IACAA,EAAUC,UAAUC,qBAGxBnM,QAAQoM,KAAK,YAAYH,mBAEnBR,GAAmB,IAAIT,IAAI,YAA+BiB,EACpE,C","sources":["webpack://aleo-website/wasm.js","webpack://aleo-website/../js/index.js"],"sourcesContent":["function spawnWorker(url, module, memory, address) {\n return new Promise((resolve) => {\n const worker = new Worker(url, {\n type: \"module\",\n });\n\n worker.addEventListener(\"message\", (event) => {\n // This is needed in Node to wait one extra tick, so that way\n // the Worker can fully initialize before we return.\n setTimeout(() => {\n resolve(worker);\n\n // When running in Node, this allows the process to exit\n // even though the Worker is still running.\n if (worker.unref) {\n worker.unref();\n }\n }, 0);\n }, {\n capture: true,\n once: true,\n });\n\n worker.postMessage({\n module,\n memory,\n address,\n });\n });\n }\n\nlet wasm;\n\nconst heap = new Array(128).fill(undefined);\n\nheap.push(undefined, null, true, false);\n\nfunction getObject(idx) { return heap[idx]; }\n\nlet heap_next = heap.length;\n\nfunction dropObject(idx) {\n if (idx < 132) return;\n heap[idx] = heap_next;\n heap_next = idx;\n}\n\nfunction takeObject(idx) {\n const ret = getObject(idx);\n dropObject(idx);\n return ret;\n}\n\nconst cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );\n\nif (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); }\nlet cachedUint8Memory0 = null;\n\nfunction getUint8Memory0() {\n if (cachedUint8Memory0 === null || cachedUint8Memory0.buffer !== wasm.memory.buffer) {\n cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);\n }\n return cachedUint8Memory0;\n}\n\nfunction getStringFromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return cachedTextDecoder.decode(getUint8Memory0().slice(ptr, ptr + len));\n}\n\nfunction addHeapObject(obj) {\n if (heap_next === heap.length) heap.push(heap.length + 1);\n const idx = heap_next;\n heap_next = heap[idx];\n\n heap[idx] = obj;\n return idx;\n}\n\nlet WASM_VECTOR_LEN = 0;\n\nconst cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );\n\nconst encodeString = function (arg, view) {\n const buf = cachedTextEncoder.encode(arg);\n view.set(buf);\n return {\n read: arg.length,\n written: buf.length\n };\n};\n\nfunction passStringToWasm0(arg, malloc, realloc) {\n\n if (realloc === undefined) {\n const buf = cachedTextEncoder.encode(arg);\n const ptr = malloc(buf.length, 1) >>> 0;\n getUint8Memory0().subarray(ptr, ptr + buf.length).set(buf);\n WASM_VECTOR_LEN = buf.length;\n return ptr;\n }\n\n let len = arg.length;\n let ptr = malloc(len, 1) >>> 0;\n\n const mem = getUint8Memory0();\n\n let offset = 0;\n\n for (; offset < len; offset++) {\n const code = arg.charCodeAt(offset);\n if (code > 0x7F) break;\n mem[ptr + offset] = code;\n }\n\n if (offset !== len) {\n if (offset !== 0) {\n arg = arg.slice(offset);\n }\n ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;\n const view = getUint8Memory0().subarray(ptr + offset, ptr + len);\n const ret = encodeString(arg, view);\n\n offset += ret.written;\n ptr = realloc(ptr, len, offset, 1) >>> 0;\n }\n\n WASM_VECTOR_LEN = offset;\n return ptr;\n}\n\nfunction isLikeNone(x) {\n return x === undefined || x === null;\n}\n\nlet cachedInt32Memory0 = null;\n\nfunction getInt32Memory0() {\n if (cachedInt32Memory0 === null || cachedInt32Memory0.buffer !== wasm.memory.buffer) {\n cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);\n }\n return cachedInt32Memory0;\n}\n\nfunction debugString(val) {\n // primitive types\n const type = typeof val;\n if (type == 'number' || type == 'boolean' || val == null) {\n return `${val}`;\n }\n if (type == 'string') {\n return `\"${val}\"`;\n }\n if (type == 'symbol') {\n const description = val.description;\n if (description == null) {\n return 'Symbol';\n } else {\n return `Symbol(${description})`;\n }\n }\n if (type == 'function') {\n const name = val.name;\n if (typeof name == 'string' && name.length > 0) {\n return `Function(${name})`;\n } else {\n return 'Function';\n }\n }\n // objects\n if (Array.isArray(val)) {\n const length = val.length;\n let debug = '[';\n if (length > 0) {\n debug += debugString(val[0]);\n }\n for(let i = 1; i < length; i++) {\n debug += ', ' + debugString(val[i]);\n }\n debug += ']';\n return debug;\n }\n // Test for built-in\n const builtInMatches = /\\[object ([^\\]]+)\\]/.exec(toString.call(val));\n let className;\n if (builtInMatches.length > 1) {\n className = builtInMatches[1];\n } else {\n // Failed to match the standard '[object ClassName]'\n return toString.call(val);\n }\n if (className == 'Object') {\n // we're a user defined class or Object\n // JSON.stringify avoids problems with cycles, and is generally much\n // easier than looping through ownProperties of `val`.\n try {\n return 'Object(' + JSON.stringify(val) + ')';\n } catch (_) {\n return 'Object';\n }\n }\n // errors\n if (val instanceof Error) {\n return `${val.name}: ${val.message}\\n${val.stack}`;\n }\n // TODO we could test for more things here, like `Set`s and `Map`s.\n return className;\n}\n\nconst CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(state => {\n wasm.__wbindgen_export_3.get(state.dtor)(state.a, state.b);\n});\n\nfunction makeMutClosure(arg0, arg1, dtor, f) {\n const state = { a: arg0, b: arg1, cnt: 1, dtor };\n const real = (...args) => {\n // First up with a closure we increment the internal reference\n // count. This ensures that the Rust closure environment won't\n // be deallocated while we're invoking it.\n state.cnt++;\n const a = state.a;\n state.a = 0;\n try {\n return f(a, state.b, ...args);\n } finally {\n if (--state.cnt === 0) {\n wasm.__wbindgen_export_3.get(state.dtor)(a, state.b);\n CLOSURE_DTORS.unregister(state);\n } else {\n state.a = a;\n }\n }\n };\n real.original = state;\n CLOSURE_DTORS.register(real, state, state);\n return real;\n}\nfunction __wbg_adapter_34(arg0, arg1, arg2) {\n wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(arg0, arg1, addHeapObject(arg2));\n}\n\nfunction _assertClass(instance, klass) {\n if (!(instance instanceof klass)) {\n throw new Error(`expected instance of ${klass.name}`);\n }\n return instance.ptr;\n}\n\nfunction passArray8ToWasm0(arg, malloc) {\n const ptr = malloc(arg.length * 1, 1) >>> 0;\n getUint8Memory0().set(arg, ptr / 1);\n WASM_VECTOR_LEN = arg.length;\n return ptr;\n}\n/**\n* Verify an execution with a single function and a single transition. Executions with multiple\n* transitions or functions will fail to verify. Also, this does not verify that the state root of\n* the execution is included in the Aleo Network ledger.\n*\n* @param {Execution} execution The function execution to verify\n* @param {VerifyingKey} verifying_key The verifying key for the function\n* @param {Program} program The program that the function execution belongs to\n* @param {String} function_id The name of the function that was executed\n* @returns {boolean} True if the execution is valid, false otherwise\n* @param {Execution} execution\n* @param {VerifyingKey} verifying_key\n* @param {Program} program\n* @param {string} function_id\n* @returns {boolean}\n*/\nfunction verifyFunctionExecution(execution, verifying_key, program, function_id) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(execution, Execution);\n _assertClass(verifying_key, VerifyingKey);\n _assertClass(program, Program);\n const ptr0 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyFunctionExecution(retptr, execution.__wbg_ptr, verifying_key.__wbg_ptr, program.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return r0 !== 0;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n}\n\nlet cachedBigInt64Memory0 = null;\n\nfunction getBigInt64Memory0() {\n if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.buffer !== wasm.memory.buffer) {\n cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);\n }\n return cachedBigInt64Memory0;\n}\n\nfunction getArrayU8FromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);\n}\n/**\n* @param {number} receiver\n*/\nfunction runRayonThread(receiver) {\n wasm.runRayonThread(receiver);\n}\n\n/**\n* @param {URL} url\n* @param {number} num_threads\n* @returns {Promise}\n*/\nfunction initThreadPool(url, num_threads) {\n const ret = wasm.initThreadPool(addHeapObject(url), num_threads);\n return takeObject(ret);\n}\n\nfunction handleError(f, args) {\n try {\n return f.apply(this, args);\n } catch (e) {\n wasm.__wbindgen_exn_store(addHeapObject(e));\n }\n}\nfunction __wbg_adapter_281(arg0, arg1, arg2, arg3) {\n wasm.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));\n}\n\nconst AddressFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_address_free(ptr >>> 0));\n/**\n* Public address of an Aleo account\n*/\nclass Address {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Address.prototype);\n obj.__wbg_ptr = ptr;\n AddressFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n AddressFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_address_free(ptr);\n }\n /**\n * Derive an Aleo address from a private key\n *\n * @param {PrivateKey} private_key The private key to derive the address from\n * @returns {Address} Address corresponding to the private key\n * @param {PrivateKey} private_key\n * @returns {Address}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.address_from_private_key(private_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Derive an Aleo address from a view key\n *\n * @param {ViewKey} view_key The view key to derive the address from\n * @returns {Address} Address corresponding to the view key\n * @param {ViewKey} view_key\n * @returns {Address}\n */\n static from_view_key(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.address_from_view_key(view_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Create an aleo address object from a string representation of an address\n *\n * @param {string} address String representation of an addressm\n * @returns {Address} Address\n * @param {string} address\n * @returns {Address}\n */\n static from_string(address) {\n const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.address_from_string(ptr0, len0);\n return Address.__wrap(ret);\n }\n /**\n * Get a string representation of an Aleo address object\n *\n * @param {Address} Address\n * @returns {string} String representation of the address\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.address_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Verify a signature for a message signed by the address\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {boolean} Boolean representing whether or not the signature is valid\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n */\n verify(message, signature) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n _assertClass(signature, Signature);\n const ret = wasm.address_verify(this.__wbg_ptr, ptr0, len0, signature.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst ExecutionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_execution_free(ptr >>> 0));\n/**\n* Execution of an Aleo program.\n*/\nclass Execution {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Execution.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_execution_free(ptr);\n }\n /**\n * Returns the string representation of the execution.\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.execution_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates an execution object from a string representation of an execution.\n * @param {string} execution\n * @returns {Execution}\n */\n static fromString(execution) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(execution, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.execution_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Execution.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ExecutionResponseFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_executionresponse_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo function execution response\n*\n* This object is returned by the execution of an Aleo function off-chain. It provides methods for\n* retrieving the outputs of the function execution.\n*/\nclass ExecutionResponse {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ExecutionResponse.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionResponseFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionResponseFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_executionresponse_free(ptr);\n }\n /**\n * Get the outputs of the executed function\n *\n * @returns {Array} Array of strings representing the outputs of the function\n * @returns {Array}\n */\n getOutputs() {\n const ret = wasm.executionresponse_getOutputs(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Returns the execution object if present, null if otherwise.\n *\n * @returns {Execution | undefined} The execution object if present, null if otherwise\n * @returns {Execution | undefined}\n */\n getExecution() {\n const ret = wasm.executionresponse_getExecution(this.__wbg_ptr);\n return ret === 0 ? undefined : Execution.__wrap(ret);\n }\n /**\n * Returns the program keys if present\n * @returns {KeyPair}\n */\n getKeys() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getKeys(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return KeyPair.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the proving_key if the proving key was cached in the Execution response.\n * Note the proving key is removed from the response object after the first call to this\n * function. Subsequent calls will return null.\n *\n * @returns {ProvingKey | undefined} The proving key\n * @returns {ProvingKey | undefined}\n */\n getProvingKey() {\n const ret = wasm.executionresponse_getProvingKey(this.__wbg_ptr);\n return ret === 0 ? undefined : ProvingKey.__wrap(ret);\n }\n /**\n * Returns the verifying_key associated with the program\n *\n * @returns {VerifyingKey} The verifying key\n * @returns {VerifyingKey}\n */\n getVerifyingKey() {\n const ret = wasm.executionresponse_getVerifyingKey(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the function identifier\n * @returns {string}\n */\n getFunctionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getFunctionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the program\n * @returns {Program}\n */\n getProgram() {\n const ret = wasm.executionresponse_getProgram(this.__wbg_ptr);\n return Program.__wrap(ret);\n }\n}\n\nconst FieldFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_field_free(ptr >>> 0));\n/**\n*/\nclass Field {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Field.prototype);\n obj.__wbg_ptr = ptr;\n FieldFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n FieldFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_field_free(ptr);\n }\n /**\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.field_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} field\n * @returns {Field}\n */\n static fromString(field) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(field, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.field_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst KeyPairFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_keypair_free(ptr >>> 0));\n/**\n* Key pair object containing both the function proving and verifying keys\n*/\nclass KeyPair {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(KeyPair.prototype);\n obj.__wbg_ptr = ptr;\n KeyPairFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n KeyPairFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_keypair_free(ptr);\n }\n /**\n * Create new key pair from proving and verifying keys\n *\n * @param {ProvingKey} proving_key Proving key corresponding to a function in an Aleo program\n * @param {VerifyingKey} verifying_key Verifying key corresponding to a function in an Aleo program\n * @returns {KeyPair} Key pair object containing both the function proving and verifying keys\n * @param {ProvingKey} proving_key\n * @param {VerifyingKey} verifying_key\n */\n constructor(proving_key, verifying_key) {\n _assertClass(proving_key, ProvingKey);\n var ptr0 = proving_key.__destroy_into_raw();\n _assertClass(verifying_key, VerifyingKey);\n var ptr1 = verifying_key.__destroy_into_raw();\n const ret = wasm.keypair_new(ptr0, ptr1);\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get the proving key. This method will remove the proving key from the key pair\n *\n * @returns {ProvingKey | Error}\n * @returns {ProvingKey}\n */\n provingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_provingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the verifying key. This method will remove the verifying key from the key pair\n *\n * @returns {VerifyingKey | Error}\n * @returns {VerifyingKey}\n */\n verifyingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst MetadataFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_metadata_free(ptr >>> 0));\n/**\n*/\nclass Metadata {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Metadata.prototype);\n obj.__wbg_ptr = ptr;\n MetadataFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n MetadataFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_metadata_free(ptr);\n }\n /**\n * @returns {string}\n */\n get name() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_name(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set name(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_name(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get locator() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_locator(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set locator(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_locator(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get prover() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_prover(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set prover(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_prover(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifier() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifier(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifier(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifier(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifyingKey() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifyingKey(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifyingKey(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n static baseUrl() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.metadata_baseUrl(retptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @returns {Metadata}\n */\n static bond_public() {\n const ret = wasm.metadata_bond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static bond_validator() {\n const ret = wasm.metadata_bond_validator();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static claim_unbond_public() {\n const ret = wasm.metadata_claim_unbond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_private() {\n const ret = wasm.metadata_fee_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_public() {\n const ret = wasm.metadata_fee_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static inclusion() {\n const ret = wasm.metadata_inclusion();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static join() {\n const ret = wasm.metadata_join();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static set_validator_state() {\n const ret = wasm.metadata_set_validator_state();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static split() {\n const ret = wasm.metadata_split();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private() {\n const ret = wasm.metadata_transfer_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private_to_public() {\n const ret = wasm.metadata_transfer_private_to_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public() {\n const ret = wasm.metadata_transfer_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_as_signer() {\n const ret = wasm.metadata_transfer_public_as_signer();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_to_private() {\n const ret = wasm.metadata_transfer_public_to_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static unbond_public() {\n const ret = wasm.metadata_unbond_public();\n return Metadata.__wrap(ret);\n }\n}\n\nconst OfflineQueryFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_offlinequery_free(ptr >>> 0));\n/**\n* An offline query object used to insert the global state root and state paths needed to create\n* a valid inclusion proof offline.\n*/\nclass OfflineQuery {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(OfflineQuery.prototype);\n obj.__wbg_ptr = ptr;\n OfflineQueryFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n OfflineQueryFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_offlinequery_free(ptr);\n }\n /**\n * Creates a new offline query object. The state root is required to be passed in as a string\n * @param {string} state_root\n */\n constructor(state_root) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(state_root, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_new(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n this.__wbg_ptr = r0 >>> 0;\n return this;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Add a new state path to the offline query object.\n *\n * @param {string} commitment: The commitment corresponding to a record inpout\n * @param {string} state_path: The state path corresponding to the commitment\n * @param {string} commitment\n * @param {string} state_path\n */\n addStatePath(commitment, state_path) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(commitment, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(state_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.offlinequery_addStatePath(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n if (r1) {\n throw takeObject(r0);\n }\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a json string representation of the offline query object\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.offlinequery_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create an offline query object from a json string representation\n * @param {string} s\n * @returns {OfflineQuery}\n */\n static fromString(s) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(s, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return OfflineQuery.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekey_free(ptr >>> 0));\n/**\n* Private key of an Aleo account\n*/\nclass PrivateKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKey.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekey_free(ptr);\n }\n /**\n * Generate a new private key using a cryptographically secure random number generator\n *\n * @returns {PrivateKey}\n */\n constructor() {\n const ret = wasm.privatekey_new();\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get a private key from a series of unchecked bytes\n *\n * @param {Uint8Array} seed Unchecked 32 byte long Uint8Array acting as the seed for the private key\n * @returns {PrivateKey}\n * @param {Uint8Array} seed\n * @returns {PrivateKey}\n */\n static from_seed_unchecked(seed) {\n const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_from_seed_unchecked(ptr0, len0);\n return PrivateKey.__wrap(ret);\n }\n /**\n * Get a private key from a string representation of a private key\n *\n * @param {string} seed String representation of a private key\n * @returns {PrivateKey}\n * @param {string} private_key\n * @returns {PrivateKey}\n */\n static from_string(private_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(private_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_from_string(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the private key. This function should be used very carefully\n * as it exposes the private key plaintext\n *\n * @returns {string} String representation of a private key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the view key corresponding to the private key\n *\n * @returns {ViewKey}\n * @returns {ViewKey}\n */\n to_view_key() {\n const ret = wasm.privatekey_to_view_key(this.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get the address corresponding to the private key\n *\n * @returns {Address}\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.privatekey_to_address(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Sign a message with the private key\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {Signature} Signature generated by signing the message with the address\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n sign(message) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(this.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a new randomly generated private key ciphertext using a secret. The secret is sensitive\n * and will be needed to decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext | Error} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static newEncrypted(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_newEncrypted(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Encrypt an existing private key with a secret. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext | Error} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n toCiphertext(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get private key from a private key ciphertext and secret originally used to encrypt it\n *\n * @param {PrivateKeyCiphertext} ciphertext Ciphertext representation of the private key\n * @param {string} secret Secret originally used to encrypt the private key\n * @returns {PrivateKey | Error} Private key\n * @param {PrivateKeyCiphertext} ciphertext\n * @param {string} secret\n * @returns {PrivateKey}\n */\n static fromPrivateKeyCiphertext(ciphertext, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(ciphertext, PrivateKeyCiphertext);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_fromPrivateKeyCiphertext(retptr, ciphertext.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekeyciphertext_free(ptr >>> 0));\n/**\n* Private Key in ciphertext form\n*/\nclass PrivateKeyCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKeyCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekeyciphertext_free(ptr);\n }\n /**\n * Encrypt a private key using a secret string. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {PrivateKey} private_key Private key to encrypt\n * @param {string} secret Secret to encrypt the private key with\n * @returns {PrivateKeyCiphertext | Error} Private key ciphertext\n * @param {PrivateKey} private_key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static encryptPrivateKey(private_key, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, private_key.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Decrypts a private ciphertext using a secret string. This must be the same secret used to\n * encrypt the private key\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKey | Error} Private key\n * @param {string} secret\n * @returns {PrivateKey}\n */\n decryptToPrivateKey(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_decryptToPrivateKey(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the ciphertext string\n *\n * @returns {string} Ciphertext string\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekeyciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates a PrivateKeyCiphertext from a string\n *\n * @param {string} ciphertext Ciphertext string\n * @returns {PrivateKeyCiphertext | Error} Private key ciphertext\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n */\n static fromString(ciphertext) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ProgramFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_program_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo program\n*/\nclass Program {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Program.prototype);\n obj.__wbg_ptr = ptr;\n ProgramFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_program_free(ptr);\n }\n /**\n * Create a program from a program string\n *\n * @param {string} program Aleo program source code\n * @returns {Program | Error} Program object\n * @param {string} program\n * @returns {Program}\n */\n static fromString(program) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Program.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the program\n *\n * @returns {string} String containing the program source code\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Determine if a function is present in the program\n *\n * @param {string} functionName Name of the function to check for\n * @returns {boolean} True if the program is valid, false otherwise\n * @param {string} function_name\n * @returns {boolean}\n */\n hasFunction(function_name) {\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.program_hasFunction(this.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get javascript array of functions names in the program\n *\n * @returns {Array} Array of all function names present in the program\n *\n * @example\n * const expected_functions = [\n * \"mint\",\n * \"transfer_private\",\n * \"transfer_private_to_public\",\n * \"transfer_public\",\n * \"transfer_public_to_private\",\n * \"join\",\n * \"split\",\n * \"fee\"\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_functions = credits_program.getFunctions();\n * console.log(credits_functions === expected_functions); // Output should be \"true\"\n * @returns {Array}\n */\n getFunctions() {\n const ret = wasm.program_getFunctions(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Get a javascript object representation of the function inputs and types. This can be used\n * to generate a web form to capture user inputs for an execution of a function.\n *\n * @param {string} function_name Name of the function to get inputs for\n * @returns {Array | Error} Array of function inputs\n *\n * @example\n * const expected_inputs = [\n * {\n * type:\"record\",\n * visibility:\"private\",\n * record:\"credits\",\n * members:[\n * {\n * name:\"microcredits\",\n * type:\"u64\",\n * visibility:\"private\"\n * }\n * ],\n * register:\"r0\"\n * },\n * {\n * type:\"address\",\n * visibility:\"private\",\n * register:\"r1\"\n * },\n * {\n * type:\"u64\",\n * visibility:\"private\",\n * register:\"r2\"\n * }\n * ];\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const transfer_function_inputs = credits_program.getFunctionInputs(\"transfer_private\");\n * console.log(transfer_function_inputs === expected_inputs); // Output should be \"true\"\n * @param {string} function_name\n * @returns {Array}\n */\n getFunctionInputs(function_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getFunctionInputs(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a the list of a program's mappings and the names/types of their keys and values.\n *\n * @returns {Array | Error} - An array of objects representing the mappings in the program\n * @example\n * const expected_mappings = [\n * {\n * name: \"account\",\n * key_name: \"owner\",\n * key_type: \"address\",\n * value_name: \"microcredits\",\n * value_type: \"u64\"\n * }\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_mappings = credits_program.getMappings();\n * console.log(credits_mappings === expected_mappings); // Output should be \"true\"\n * @returns {Array}\n */\n getMappings() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_getMappings(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program record and its types\n *\n * @param {string} record_name Name of the record to get members for\n * @returns {Object | Error} Object containing the record name, type, and members\n *\n * @example\n *\n * const expected_record = {\n * type: \"record\",\n * record: \"Credits\",\n * members: [\n * {\n * name: \"owner\",\n * type: \"address\",\n * visibility: \"private\"\n * },\n * {\n * name: \"microcredits\",\n * type: \"u64\",\n * visibility: \"private\"\n * }\n * ];\n * };\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_record = credits_program.getRecordMembers(\"Credits\");\n * console.log(credits_record === expected_record); // Output should be \"true\"\n * @param {string} record_name\n * @returns {object}\n */\n getRecordMembers(record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getRecordMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program struct and its types\n *\n * @param {string} struct_name Name of the struct to get members for\n * @returns {Array | Error} Array containing the struct members\n *\n * @example\n *\n * const STRUCT_PROGRAM = \"program token_issue.aleo;\n *\n * struct token_metadata:\n * network as u32;\n * version as u32;\n *\n * struct token:\n * token_id as u32;\n * metadata as token_metadata;\n *\n * function no_op:\n * input r0 as u64;\n * output r0 as u64;\"\n *\n * const expected_struct_members = [\n * {\n * name: \"token_id\",\n * type: \"u32\",\n * },\n * {\n * name: \"metadata\",\n * type: \"struct\",\n * struct_id: \"token_metadata\",\n * members: [\n * {\n * name: \"network\",\n * type: \"u32\",\n * }\n * {\n * name: \"version\",\n * type: \"u32\",\n * }\n * ]\n * }\n * ];\n *\n * const program = aleo_wasm.Program.fromString(STRUCT_PROGRAM);\n * const struct_members = program.getStructMembers(\"token\");\n * console.log(struct_members === expected_struct_members); // Output should be \"true\"\n * @param {string} struct_name\n * @returns {Array}\n */\n getStructMembers(struct_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(struct_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getStructMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the credits.aleo program\n *\n * @returns {Program} The credits.aleo program\n * @returns {Program}\n */\n static getCreditsProgram() {\n const ret = wasm.program_getCreditsProgram();\n return Program.__wrap(ret);\n }\n /**\n * Get the id of the program\n *\n * @returns {string} The id of the program\n * @returns {string}\n */\n id() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_id(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get a unique address of the program\n *\n * @returns {Address} The address of the program\n * @returns {Address}\n */\n address() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_address(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Address.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determine equality with another program\n *\n * @param {Program} other The other program to compare\n * @returns {boolean} True if the programs are equal, false otherwise\n * @param {Program} other\n * @returns {boolean}\n */\n isEqual(other) {\n _assertClass(other, Program);\n const ret = wasm.program_isEqual(this.__wbg_ptr, other.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get program_imports\n *\n * @returns {Array} The program imports\n *\n * @example\n *\n * const DOUBLE_TEST = \"import multiply_test.aleo;\n *\n * program double_test.aleo;\n *\n * function double_it:\n * input r0 as u32.private;\n * call multiply_test.aleo/multiply 2u32 r0 into r1;\n * output r1 as u32.private;\";\n *\n * const expected_imports = [\n * \"multiply_test.aleo\"\n * ];\n *\n * const program = aleo_wasm.Program.fromString(DOUBLE_TEST_PROGRAM);\n * const imports = program.getImports();\n * console.log(imports === expected_imports); // Output should be \"true\"\n * @returns {Array}\n */\n getImports() {\n const ret = wasm.program_getImports(this.__wbg_ptr);\n return takeObject(ret);\n }\n}\n\nconst ProgramManagerFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_programmanager_free(ptr >>> 0));\n/**\n*/\nclass ProgramManager {\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramManagerFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_programmanager_free(ptr);\n }\n /**\n * Deploy an Aleo program\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being deployed\n * @param imports A javascript object holding the source code of any imported programs in the\n * form \\{\"program_name1\": \"program_source_code\", \"program_name2\": \"program_source_code\", ..\\}.\n * Note that all imported programs must be deployed on chain before the main program in order\n * for the deployment to succeed\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the program deployment in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildDeploymentTransaction(private_key, program, fee_credits, fee_record, url, imports, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n let ptr1 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr1 = fee_record.__destroy_into_raw();\n }\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr3 = fee_proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr4 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildDeploymentTransaction(private_key.__wbg_ptr, ptr0, len0, fee_credits, ptr1, ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the fee for a program deployment\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The source code of the program being deployed\n * @param imports (optional) Provide a list of imports to use for the deployment fee estimation\n * in the form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @returns {u64 | Error}\n * @param {string} program\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static estimateDeploymentFee(program, imports) {\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_estimateDeploymentFee(ptr0, len0, isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n /**\n * Estimate the component of the deployment cost which comes from the fee for the program name.\n * Note that this cost does not represent the entire cost of deployment. It is additional to\n * the cost of the size (in bytes) of the deployment.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param name The name of the program to be deployed\n * @returns {u64 | Error}\n * @param {string} name\n * @returns {bigint}\n */\n static estimateProgramNameCost(name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateProgramNameCost(retptr, ptr0, len0);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Execute an arbitrary function locally\n *\n * @param {PrivateKey} private_key The private key of the sender\n * @param {string} program The source code of the program being executed\n * @param {string} function The name of the function to execute\n * @param {Array} inputs A javascript array of inputs to the function\n * @param {boolean} prove_execution If true, the execution will be proven and an execution object\n * containing the proof and the encrypted inputs and outputs needed to verify the proof offline\n * will be returned.\n * @param {boolean} cache Cache the proving and verifying keys in the Execution response.\n * If this is set to 'true' the keys synthesized will be stored in the Execution Response\n * and the `ProvingKey` and `VerifyingKey` can be retrieved from the response via the `.getKeys()`\n * method.\n * @param {Object | undefined} imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param {ProvingKey | undefined} proving_key (optional) Provide a verifying key to use for the function execution\n * @param {VerifyingKey | undefined} verifying_key (optional) Provide a verifying key to use for the function execution\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {boolean} prove_execution\n * @param {boolean} cache\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {string | undefined} [url]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static executeFunctionOffline(private_key, program, _function, inputs, prove_execution, cache, imports, proving_key, verifying_key, url, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr2 = proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr3 = verifying_key.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_executeFunctionOffline(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), prove_execution, cache, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr2, ptr3, ptr4, len4, ptr5);\n return takeObject(ret);\n }\n /**\n * Execute Aleo function and create an Aleo execution transaction\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being executed\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * If this is set to 'true' the keys synthesized (or passed in as optional parameters via the\n * `proving_key` and `verifying_key` arguments) will be stored in the ProgramManager's memory\n * and used for subsequent transactions. If this is set to 'false' the proving and verifying\n * keys will be deallocated from memory after the transaction is executed.\n * @param imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the function execution\n * @param verifying_key (optional) Provide a verifying key to use for the function execution\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildExecutionTransaction(private_key, program, _function, inputs, fee_credits, fee_record, url, imports, proving_key, verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr4 = proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr5 = verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildExecutionTransaction(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), fee_credits, ptr2, ptr3, len3, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Estimate Fee for Aleo function execution. Note if \"cache\" is set to true, the proving and\n * verifying keys will be stored in the ProgramManager's memory and used for subsequent\n * program executions.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program to estimate the execution fee for\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the fee estimation in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the fee estimation\n * @param verifying_key (optional) Provide a verifying key to use for the fee estimation\n * @returns {u64 | Error} Fee in microcredits\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static estimateExecutionFee(private_key, program, _function, inputs, url, imports, proving_key, verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr3 = proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr4 = verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_estimateExecutionFee(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the finalize fee component for executing a function. This fee is additional to the\n * size of the execution of the program in bytes. If the function does not have a finalize\n * step, then the finalize fee is 0.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The program containing the function to estimate the finalize fee for\n * @param function The function to estimate the finalize fee for\n * @returns {u64 | Error} Fee in microcredits\n * @param {string} program\n * @param {string} _function\n * @returns {bigint}\n */\n static estimateFinalizeFee(program, _function) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateFinalizeFee(retptr, ptr0, len0, ptr1, len1);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Join two records together to create a new record with an amount of credits equal to the sum\n * of the credits of the two original records\n *\n * @param private_key The private key of the sender\n * @param record_1 The first record to combine\n * @param record_2 The second record to combine\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param join_proving_key (optional) Provide a proving key to use for the join function\n * @param join_verifying_key (optional) Provide a verifying key to use for the join function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error} Transaction object\n * @param {PrivateKey} private_key\n * @param {RecordPlaintext} record_1\n * @param {RecordPlaintext} record_2\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [join_proving_key]\n * @param {VerifyingKey | undefined} [join_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildJoinTransaction(private_key, record_1, record_2, fee_credits, fee_record, url, join_proving_key, join_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(record_1, RecordPlaintext);\n var ptr0 = record_1.__destroy_into_raw();\n _assertClass(record_2, RecordPlaintext);\n var ptr1 = record_2.__destroy_into_raw();\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(join_proving_key)) {\n _assertClass(join_proving_key, ProvingKey);\n ptr4 = join_proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(join_verifying_key)) {\n _assertClass(join_verifying_key, VerifyingKey);\n ptr5 = join_verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildJoinTransaction(private_key.__wbg_ptr, ptr0, ptr1, fee_credits, ptr2, ptr3, len3, ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Split an Aleo credits record into two separate records. This function does not require a fee.\n *\n * @param private_key The private key of the sender\n * @param split_amount The amount of the credit split. This amount will be subtracted from the\n * value of the record and two new records will be created with the split amount and the remainder\n * @param amount_record The record to split\n * @param url The url of the Aleo network node to send the transaction to\n * @param split_proving_key (optional) Provide a proving key to use for the split function\n * @param split_verifying_key (optional) Provide a verifying key to use for the split function\n * @returns {Transaction | Error} Transaction object\n * @param {PrivateKey} private_key\n * @param {number} split_amount\n * @param {RecordPlaintext} amount_record\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [split_proving_key]\n * @param {VerifyingKey | undefined} [split_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildSplitTransaction(private_key, split_amount, amount_record, url, split_proving_key, split_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(amount_record, RecordPlaintext);\n var ptr0 = amount_record.__destroy_into_raw();\n var ptr1 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(split_proving_key)) {\n _assertClass(split_proving_key, ProvingKey);\n ptr2 = split_proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(split_verifying_key)) {\n _assertClass(split_verifying_key, VerifyingKey);\n ptr3 = split_verifying_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr4 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildSplitTransaction(private_key.__wbg_ptr, split_amount, ptr0, ptr1, len1, ptr2, ptr3, ptr4);\n return takeObject(ret);\n }\n /**\n * Send credits from one Aleo account to another\n *\n * @param private_key The private key of the sender\n * @param amount_credits The amount of credits to send\n * @param recipient The recipient of the transaction\n * @param transfer_type The type of the transfer (options: \"private\", \"public\", \"private_to_public\", \"public_to_private\")\n * @param amount_record The record to fund the amount from\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param transfer_verifying_key (optional) Provide a verifying key to use for the transfer\n * function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {number} amount_credits\n * @param {string} recipient\n * @param {string} transfer_type\n * @param {RecordPlaintext | undefined} amount_record\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [transfer_proving_key]\n * @param {VerifyingKey | undefined} [transfer_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildTransferTransaction(private_key, amount_credits, recipient, transfer_type, amount_record, fee_credits, fee_record, url, transfer_proving_key, transfer_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(recipient, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(transfer_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(amount_record)) {\n _assertClass(amount_record, RecordPlaintext);\n ptr2 = amount_record.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr3 = fee_record.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(transfer_proving_key)) {\n _assertClass(transfer_proving_key, ProvingKey);\n ptr5 = transfer_proving_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(transfer_verifying_key)) {\n _assertClass(transfer_verifying_key, VerifyingKey);\n ptr6 = transfer_verifying_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr7 = fee_proving_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr8 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr9 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr9 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildTransferTransaction(private_key.__wbg_ptr, amount_credits, ptr0, len0, ptr1, len1, ptr2, fee_credits, ptr3, ptr4, len4, ptr5, ptr6, ptr7, ptr8, ptr9);\n return takeObject(ret);\n }\n /**\n * Synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code of the program to synthesize keys for\n * @param function_id {string} The function to synthesize keys for\n * @param inputs {Array} The inputs to the function\n * @param imports {Object | undefined} The imports for the program\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} function_id\n * @param {Array} inputs\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static synthesizeKeyPair(private_key, program, function_id, inputs, imports) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_synthesizeKeyPair(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n}\n\nconst ProvingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_provingkey_free(ptr >>> 0));\n/**\n* Proving key for a function within an Aleo program\n*/\nclass ProvingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ProvingKey.prototype);\n obj.__wbg_ptr = ptr;\n ProvingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProvingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_provingkey_free(ptr);\n }\n /**\n * Verify if the proving key is for the bond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_public_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_public function, false if otherwise\n * @returns {boolean}\n */\n isBondPublicProver() {\n const ret = wasm.provingkey_isBondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the bond_validator function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_validator_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_validator function, false if otherwise\n * @returns {boolean}\n */\n isBondValidatorProver() {\n const ret = wasm.provingkey_isBondValidatorProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the claim_unbond function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"claim_unbond_proving_key.bin\");\n * provingKey.isClaimUnbondProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the claim_unbond function, false if otherwise\n * @returns {boolean}\n */\n isClaimUnbondPublicProver() {\n const ret = wasm.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_private_proving_key.bin\");\n * provingKey.isFeePrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_private function, false if otherwise\n * @returns {boolean}\n */\n isFeePrivateProver() {\n const ret = wasm.provingkey_isFeePrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_public_proving_key.bin\");\n * provingKey.isFeePublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_public function, false if otherwise\n * @returns {boolean}\n */\n isFeePublicProver() {\n const ret = wasm.provingkey_isFeePublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the inclusion function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"inclusion_proving_key.bin\");\n * provingKey.isInclusionProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the inclusion function, false if otherwise\n * @returns {boolean}\n */\n isInclusionProver() {\n const ret = wasm.provingkey_isInclusionProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the join function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"join_proving_key.bin\");\n * provingKey.isJoinProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the join function, false if otherwise\n * @returns {boolean}\n */\n isJoinProver() {\n const ret = wasm.provingkey_isJoinProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the set_validator_state function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"set_validator_set_proving_key.bin\");\n * provingKey.isSetValidatorStateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the set_validator_state function, false if otherwise\n * @returns {boolean}\n */\n isSetValidatorStateProver() {\n const ret = wasm.provingkey_isSetValidatorStateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the split function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"split_proving_key.bin\");\n * provingKey.isSplitProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the split function, false if otherwise\n * @returns {boolean}\n */\n isSplitProver() {\n const ret = wasm.provingkey_isSplitProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_proving_key.bin\");\n * provingKey.isTransferPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateProver() {\n const ret = wasm.provingkey_isTransferPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private_to_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_to_public_proving_key.bin\");\n * provingKey.isTransferPrivateToPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private_to_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateToPublicProver() {\n const ret = wasm.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_proving_key.bin\");\n * provingKey.isTransferPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicProver() {\n const ret = wasm.provingkey_isTransferPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_as_signer function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_as_signer_proving_key.bin\");\n * provingKey.isTransferPublicAsSignerProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicAsSignerProver() {\n const ret = wasm.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_to_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_to_private_proving_key.bin\");\n * provingKey.isTransferPublicToPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public_to_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicToPrivateProver() {\n const ret = wasm.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the unbond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"unbond_public.bin\");\n * provingKey.isUnbondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the unbond_public_prover function, false if otherwise\n * @returns {boolean}\n */\n isUnbondPublicProver() {\n const ret = wasm.provingkey_isUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Return the checksum of the proving key\n *\n * @returns {string} Checksum of the proving key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the proving key\n *\n * @returns {ProvingKey} A copy of the proving key\n * @returns {ProvingKey}\n */\n copy() {\n const ret = wasm.provingkey_copy(this.__wbg_ptr);\n return ProvingKey.__wrap(ret);\n }\n /**\n * Construct a new proving key from a byte array\n *\n * @param {Uint8Array} bytes Byte array representation of a proving key\n * @returns {ProvingKey | Error}\n * @param {Uint8Array} bytes\n * @returns {ProvingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a proving key from string\n *\n * @param {string | Error} String representation of the proving key\n * @param {string} string\n * @returns {ProvingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the byte representation of a proving key\n *\n * @returns {Uint8Array | Error} Byte array representation of a proving key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the proving key\n *\n * @returns {string} String representation of the proving key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst RecordCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordciphertext_free(ptr >>> 0));\n/**\n* Encrypted Aleo record\n*/\nclass RecordCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n RecordCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordciphertext_free(ptr);\n }\n /**\n * Create a record ciphertext from a string\n *\n * @param {string} record String representation of a record ciphertext\n * @returns {RecordCiphertext | Error} Record ciphertext\n * @param {string} record\n * @returns {RecordCiphertext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the string reprensentation of the record ciphertext\n *\n * @returns {string} String representation of the record ciphertext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Decrypt the record ciphertext into plaintext using the view key. The record will only\n * decrypt if the record was encrypted by the account corresponding to the view key\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {RecordPlaintext | Error} Record plaintext object\n * @param {ViewKey} view_key\n * @returns {RecordPlaintext}\n */\n decrypt(view_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(view_key, ViewKey);\n wasm.recordciphertext_decrypt(retptr, this.__wbg_ptr, view_key.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determines if the account corresponding to the view key is the owner of the record\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {boolean}\n * @param {ViewKey} view_key\n * @returns {boolean}\n */\n isOwner(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.recordciphertext_isOwner(this.__wbg_ptr, view_key.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst RecordPlaintextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordplaintext_free(ptr >>> 0));\n/**\n* Plaintext representation of an Aleo record\n*/\nclass RecordPlaintext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordPlaintext.prototype);\n obj.__wbg_ptr = ptr;\n RecordPlaintextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordPlaintextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordplaintext_free(ptr);\n }\n /**\n * @param {string} program_id\n * @param {string} record_name\n * @returns {Field}\n */\n commitment(program_id, record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_commitment(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return a record plaintext from a string.\n *\n * @param {string} record String representation of a plaintext representation of an Aleo record\n * @returns {RecordPlaintext | Error} Record plaintext\n * @param {string} record\n * @returns {RecordPlaintext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordplaintext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the record plaintext string\n *\n * @returns {string} String representation of the record plaintext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the amount of microcredits in the record\n *\n * @returns {u64} Amount of microcredits in the record\n * @returns {bigint}\n */\n microcredits() {\n const ret = wasm.recordplaintext_microcredits(this.__wbg_ptr);\n return BigInt.asUintN(64, ret);\n }\n /**\n * Returns the nonce of the record. This can be used to uniquely identify a record.\n *\n * @returns {string} Nonce of the record\n * @returns {string}\n */\n nonce() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_nonce(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Attempt to get the serial number of a record to determine whether or not is has been spent\n *\n * @param {PrivateKey} private_key Private key of the account that owns the record\n * @param {string} program_id Program ID of the program that the record is associated with\n * @param {string} record_name Name of the record\n * @returns {string | Error} Serial number of the record\n * @param {PrivateKey} private_key\n * @param {string} program_id\n * @param {string} record_name\n * @returns {string}\n */\n serialNumberString(private_key, program_id, record_name) {\n let deferred4_0;\n let deferred4_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_serialNumberString(retptr, this.__wbg_ptr, private_key.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr3 = r0;\n var len3 = r1;\n if (r3) {\n ptr3 = 0; len3 = 0;\n throw takeObject(r2);\n }\n deferred4_0 = ptr3;\n deferred4_1 = len3;\n return getStringFromWasm0(ptr3, len3);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred4_0, deferred4_1, 1);\n }\n }\n}\n\nconst SignatureFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_signature_free(ptr >>> 0));\n/**\n* Cryptographic signature of a message signed by an Aleo account\n*/\nclass Signature {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Signature.prototype);\n obj.__wbg_ptr = ptr;\n SignatureFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n SignatureFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_signature_free(ptr);\n }\n /**\n * Sign a message with a private key\n *\n * @param {PrivateKey} private_key The private key to sign the message with\n * @param {Uint8Array} message Byte representation of the message to sign\n * @returns {Signature} Signature of the message\n * @param {PrivateKey} private_key\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n static sign(private_key, message) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(private_key.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Verify a signature of a message with an address\n *\n * @param {Address} address The address to verify the signature with\n * @param {Uint8Array} message Byte representation of the message to verify\n * @returns {boolean} True if the signature is valid, false otherwise\n * @param {Address} address\n * @param {Uint8Array} message\n * @returns {boolean}\n */\n verify(address, message) {\n _assertClass(address, Address);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_verify(this.__wbg_ptr, address.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get a signature from a string representation of a signature\n *\n * @param {string} signature String representation of a signature\n * @returns {Signature} Signature\n * @param {string} signature\n * @returns {Signature}\n */\n static from_string(signature) {\n const ptr0 = passStringToWasm0(signature, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_from_string(ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a string representation of a signature\n *\n * @returns {string} String representation of a signature\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.signature_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst TransactionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_transaction_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo transaction\n*\n* This object is created when generating an on-chain function deployment or execution and is the\n* object that should be submitted to the Aleo Network in order to deploy or execute a function.\n*/\nclass Transaction {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Transaction.prototype);\n obj.__wbg_ptr = ptr;\n TransactionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n TransactionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_transaction_free(ptr);\n }\n /**\n * Create a transaction from a string\n *\n * @param {string} transaction String representation of a transaction\n * @returns {Transaction | Error}\n * @param {string} transaction\n * @returns {Transaction}\n */\n static fromString(transaction) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(transaction, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.transaction_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Transaction.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the transaction as a string. If you want to submit this transaction to the Aleo Network\n * this function will create the string that should be submitted in the `POST` data.\n *\n * @returns {string} String representation of the transaction\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the id of the transaction. This is the merkle root of the transaction's inclusion proof.\n *\n * This value can be used to query the status of the transaction on the Aleo Network to see\n * if it was successful. If successful, the transaction will be included in a block and this\n * value can be used to lookup the transaction data on-chain.\n *\n * @returns {string} Transaction id\n * @returns {string}\n */\n transactionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the type of the transaction (will return \"deploy\" or \"execute\")\n *\n * @returns {string} Transaction type\n * @returns {string}\n */\n transactionType() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionType(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst VerifyingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_verifyingkey_free(ptr >>> 0));\n/**\n* Verifying key for a function within an Aleo program\n*/\nclass VerifyingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(VerifyingKey.prototype);\n obj.__wbg_ptr = ptr;\n VerifyingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n VerifyingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_verifyingkey_free(ptr);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {VerifyingKey}\n */\n static bondPublicVerifier() {\n const ret = wasm.verifyingkey_bondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {VerifyingKey}\n */\n static bondValidatorVerifier() {\n const ret = wasm.verifyingkey_bondValidatorVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the claim_delegator function\n *\n * @returns {VerifyingKey} Verifying key for the claim_unbond_public function\n * @returns {VerifyingKey}\n */\n static claimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_claimUnbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_private function\n *\n * @returns {VerifyingKey} Verifying key for the fee_private function\n * @returns {VerifyingKey}\n */\n static feePrivateVerifier() {\n const ret = wasm.verifyingkey_feePrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_public function\n *\n * @returns {VerifyingKey} Verifying key for the fee_public function\n * @returns {VerifyingKey}\n */\n static feePublicVerifier() {\n const ret = wasm.verifyingkey_feePublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the inclusion function\n *\n * @returns {VerifyingKey} Verifying key for the inclusion function\n * @returns {VerifyingKey}\n */\n static inclusionVerifier() {\n const ret = wasm.verifyingkey_inclusionVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the join function\n *\n * @returns {VerifyingKey} Verifying key for the join function\n * @returns {VerifyingKey}\n */\n static joinVerifier() {\n const ret = wasm.verifyingkey_joinVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the set_validator_state function\n *\n * @returns {VerifyingKey} Verifying key for the set_validator_state function\n * @returns {VerifyingKey}\n */\n static setValidatorStateVerifier() {\n const ret = wasm.verifyingkey_setValidatorStateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the split function\n *\n * @returns {VerifyingKey} Verifying key for the split function\n * @returns {VerifyingKey}\n */\n static splitVerifier() {\n const ret = wasm.verifyingkey_splitVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private function\n * @returns {VerifyingKey}\n */\n static transferPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private_to_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private_to_public function\n * @returns {VerifyingKey}\n */\n static transferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_transferPrivateToPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public function\n * @returns {VerifyingKey}\n */\n static transferPublicVerifier() {\n const ret = wasm.verifyingkey_transferPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_as_signer function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_as_signer function\n * @returns {VerifyingKey}\n */\n static transferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_transferPublicAsSignerVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_to_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_to_private function\n * @returns {VerifyingKey}\n */\n static transferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPublicToPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the unbond_public function\n *\n * @returns {VerifyingKey} Verifying key for the unbond_public function\n * @returns {VerifyingKey}\n */\n static unbondPublicVerifier() {\n const ret = wasm.verifyingkey_unbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {boolean}\n */\n isBondPublicVerifier() {\n const ret = wasm.verifyingkey_isBondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {boolean}\n */\n isBondValidatorVerifier() {\n const ret = wasm.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the claim_delegator function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isClaimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePrivateVerifier() {\n const ret = wasm.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePublicVerifier() {\n const ret = wasm.verifyingkey_isFeePublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the inclusion function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isInclusionVerifier() {\n const ret = wasm.verifyingkey_isInclusionVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the join function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isJoinVerifier() {\n const ret = wasm.verifyingkey_isJoinVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the set_validator_state function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSetValidatorStateVerifier() {\n const ret = wasm.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the split function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSplitVerifier() {\n const ret = wasm.verifyingkey_isSplitVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private_to_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_as_signer function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_to_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the unbond_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get the checksum of the verifying key\n *\n * @returns {string} Checksum of the verifying key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the verifying key\n *\n * @returns {VerifyingKey} A copy of the verifying key\n * @returns {VerifyingKey}\n */\n copy() {\n const ret = wasm.verifyingkey_copy(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Construct a new verifying key from a byte array\n *\n * @param {Uint8Array} bytes Byte representation of a verifying key\n * @returns {VerifyingKey | Error}\n * @param {Uint8Array} bytes\n * @returns {VerifyingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a verifying key from string\n *\n * @param {String} string String representation of a verifying key\n * @returns {VerifyingKey | Error}\n * @param {string} string\n * @returns {VerifyingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a byte array from a verifying key\n *\n * @returns {Uint8Array | Error} Byte representation of a verifying key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the verifying key\n *\n * @returns {String} String representation of the verifying key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst ViewKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_viewkey_free(ptr >>> 0));\n/**\n*/\nclass ViewKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ViewKey.prototype);\n obj.__wbg_ptr = ptr;\n ViewKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ViewKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_viewkey_free(ptr);\n }\n /**\n * Create a new view key from a private key\n *\n * @param {PrivateKey} private_key Private key\n * @returns {ViewKey} View key\n * @param {PrivateKey} private_key\n * @returns {ViewKey}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.privatekey_to_view_key(private_key.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Create a new view key from a string representation of a view key\n *\n * @param {string} view_key String representation of a view key\n * @returns {ViewKey} View key\n * @param {string} view_key\n * @returns {ViewKey}\n */\n static from_string(view_key) {\n const ptr0 = passStringToWasm0(view_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.viewkey_from_string(ptr0, len0);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get a string representation of a view key\n *\n * @returns {string} String representation of a view key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.viewkey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the address corresponding to a view key\n *\n * @returns {Address} Address\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.address_from_view_key(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Decrypt a record ciphertext with a view key\n *\n * @param {string} ciphertext String representation of a record ciphertext\n * @returns {string} String representation of a record plaintext\n * @param {string} ciphertext\n * @returns {string}\n */\n decrypt(ciphertext) {\n let deferred3_0;\n let deferred3_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.viewkey_decrypt(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr2 = r0;\n var len2 = r1;\n if (r3) {\n ptr2 = 0; len2 = 0;\n throw takeObject(r2);\n }\n deferred3_0 = ptr2;\n deferred3_1 = len2;\n return getStringFromWasm0(ptr2, len2);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);\n }\n }\n}\n\nasync function __wbg_load(module, imports) {\n if (typeof Response === 'function' && module instanceof Response) {\n if (typeof WebAssembly.instantiateStreaming === 'function') {\n try {\n return await WebAssembly.instantiateStreaming(module, imports);\n\n } catch (e) {\n if (module.headers.get('Content-Type') != 'application/wasm') {\n console.warn(\"`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n\", e);\n\n } else {\n throw e;\n }\n }\n }\n\n const bytes = await module.arrayBuffer();\n return await WebAssembly.instantiate(bytes, imports);\n\n } else {\n const instance = await WebAssembly.instantiate(module, imports);\n\n if (instance instanceof WebAssembly.Instance) {\n return { instance, module };\n\n } else {\n return instance;\n }\n }\n}\n\nfunction __wbg_get_imports() {\n const imports = {};\n imports.wbg = {};\n imports.wbg.__wbindgen_object_drop_ref = function(arg0) {\n takeObject(arg0);\n };\n imports.wbg.__wbg_new_71801a555ad9f2aa = function() { return handleError(function () {\n const ret = new XMLHttpRequest();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_overrideMimeType_ee9c51919ceb418b = function() { return handleError(function (arg0, arg1, arg2) {\n getObject(arg0).overrideMimeType(getStringFromWasm0(arg1, arg2));\n }, arguments) };\n imports.wbg.__wbg_open_c9eb0cf2c9d95679 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {\n getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), arg5 !== 0);\n }, arguments) };\n imports.wbg.__wbg_send_80d29985093c1ec5 = function() { return handleError(function (arg0) {\n getObject(arg0).send();\n }, arguments) };\n imports.wbg.__wbg_response_7c2e2759084f7279 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).response;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_status_d485fb5a478426fb = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).status;\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_72fb9a18b5ae2624 = function() {\n const ret = new Object();\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_string_new = function(arg0, arg1) {\n const ret = getStringFromWasm0(arg0, arg1);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_1f9b04f170055d33 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_ab6fd82b10560829 = function() { return handleError(function () {\n const ret = new Headers();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_object_clone_ref = function(arg0) {\n const ret = getObject(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_0d76b0581eca6298 = function() { return handleError(function () {\n const ret = new AbortController();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_signal_a61f78a3478fd9bc = function(arg0) {\n const ret = getObject(arg0).signal;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_append_7bfcb4937d1d5e29 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {\n getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));\n }, arguments) };\n imports.wbg.__wbg_instanceof_Response_849eb93e75734b6e = function(arg0) {\n let result;\n try {\n result = getObject(arg0) instanceof Response;\n } catch (_) {\n result = false;\n }\n const ret = result;\n return ret;\n };\n imports.wbg.__wbg_status_61a01141acd3cf74 = function(arg0) {\n const ret = getObject(arg0).status;\n return ret;\n };\n imports.wbg.__wbg_url_5f6dc4009ac5f99d = function(arg0, arg1) {\n const ret = getObject(arg1).url;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_headers_9620bfada380764a = function(arg0) {\n const ret = getObject(arg0).headers;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_iterator_2cee6dadfd956dfa = function() {\n const ret = Symbol.iterator;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_get_e3c254076557e348 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.get(getObject(arg0), getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_function = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'function';\n return ret;\n };\n imports.wbg.__wbg_call_27c0f87801dedf93 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg0).call(getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_object = function(arg0) {\n const val = getObject(arg0);\n const ret = typeof(val) === 'object' && val !== null;\n return ret;\n };\n imports.wbg.__wbg_next_40fc327bfc8770e6 = function(arg0) {\n const ret = getObject(arg0).next;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_next_196c84450b364254 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).next();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_done_298b57d23c0fc80c = function(arg0) {\n const ret = getObject(arg0).done;\n return ret;\n };\n imports.wbg.__wbg_value_d93c65011f51a456 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_abort_2aa7521d5690750e = function(arg0) {\n getObject(arg0).abort();\n };\n imports.wbg.__wbg_stringify_8887fe74e1c50d81 = function() { return handleError(function (arg0) {\n const ret = JSON.stringify(getObject(arg0));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_string_get = function(arg0, arg1) {\n const obj = getObject(arg1);\n const ret = typeof(obj) === 'string' ? obj : undefined;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_log_0159ca40cddf5b15 = function(arg0, arg1) {\n console.log(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {\n const ret = BigInt.asUintN(64, arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_call_b3ca7c6051f9bec1 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_transaction_new = function(arg0) {\n const ret = Transaction.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_keypair_new = function(arg0) {\n const ret = KeyPair.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_module = function() {\n const ret = __wbg_init.__wbindgen_wasm_module;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_memory = function() {\n const ret = wasm.memory;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a = function(arg0, arg1, arg2, arg3) {\n const ret = spawnWorker(getObject(arg0), getObject(arg1), getObject(arg2), arg3 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_executionresponse_new = function(arg0) {\n const ret = ExecutionResponse.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_66ae46612e7f0234 = function(arg0) {\n const ret = new Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_d4638f722068f043 = function(arg0, arg1, arg2) {\n getObject(arg0)[arg1 >>> 0] = takeObject(arg2);\n };\n imports.wbg.__wbindgen_cb_drop = function(arg0) {\n const obj = takeObject(arg0).original;\n if (obj.cnt-- == 1) {\n obj.a = 0;\n return true;\n }\n const ret = false;\n return ret;\n };\n imports.wbg.__wbg_new_16b304a2cfa7ff4a = function() {\n const ret = new Array();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_push_a5b05aedc7234f9f = function(arg0, arg1) {\n const ret = getObject(arg0).push(getObject(arg1));\n return ret;\n };\n imports.wbg.__wbg_arrayBuffer_29931d52c7206b02 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).arrayBuffer();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_new_63b92bc8671ed464 = function(arg0) {\n const ret = new Uint8Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_c20a40f15020d68a = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_new_81740750da40724f = function(arg0, arg1) {\n try {\n var state0 = {a: arg0, b: arg1};\n var cb0 = (arg0, arg1) => {\n const a = state0.a;\n state0.a = 0;\n try {\n return __wbg_adapter_281(a, state0.b, arg0, arg1);\n } finally {\n state0.a = a;\n }\n };\n const ret = new Promise(cb0);\n return addHeapObject(ret);\n } finally {\n state0.a = state0.b = 0;\n }\n };\n imports.wbg.__wbindgen_number_new = function(arg0) {\n const ret = arg0;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_abda76e883ba8a5f = function() {\n const ret = new Error();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_stack_658279fe44541cf6 = function(arg0, arg1) {\n const ret = getObject(arg1).stack;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {\n let deferred0_0;\n let deferred0_1;\n try {\n deferred0_0 = arg0;\n deferred0_1 = arg1;\n console.error(getStringFromWasm0(arg0, arg1));\n } finally {\n wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);\n }\n };\n imports.wbg.__wbg_buffer_12d079cc21e14bdb = function(arg0) {\n const ret = getObject(arg0).buffer;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb = function(arg0, arg1, arg2) {\n const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_randomFillSync_5c9c955aa56b6049 = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).randomFillSync(takeObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_subarray_a1f73cd4b5b42fe1 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_getRandomValues_3aa56aa6edec874c = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).getRandomValues(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_set_a47bac70306a19a7 = function(arg0, arg1, arg2) {\n getObject(arg0).set(getObject(arg1), arg2 >>> 0);\n };\n imports.wbg.__wbg_crypto_1d1f22824a6a080c = function(arg0) {\n const ret = getObject(arg0).crypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_process_4a72847cc503995b = function(arg0) {\n const ret = getObject(arg0).process;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_versions_f686565e586dd935 = function(arg0) {\n const ret = getObject(arg0).versions;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_node_104a2ff8d6ea03a2 = function(arg0) {\n const ret = getObject(arg0).node;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_is_string = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'string';\n return ret;\n };\n imports.wbg.__wbg_require_cca90b1a94a0255b = function() { return handleError(function () {\n const ret = module.require;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_msCrypto_eb05e62b530a1508 = function(arg0) {\n const ret = getObject(arg0).msCrypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_e9b4878cebadb3d3 = function(arg0) {\n const ret = new Uint8Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_cd7af8117672b8b8 = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_get_bd8e338fbd5f5cc8 = function(arg0, arg1) {\n const ret = getObject(arg0)[arg1 >>> 0];\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_self_ce0dbfc45cf2f5be = function() { return handleError(function () {\n const ret = self.self;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_window_c6fb939a7f436783 = function() { return handleError(function () {\n const ret = window.window;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_globalThis_d1e6af4856ba331b = function() { return handleError(function () {\n const ret = globalThis.globalThis;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_global_207b558942527489 = function() { return handleError(function () {\n const ret = global.global;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_undefined = function(arg0) {\n const ret = getObject(arg0) === undefined;\n return ret;\n };\n imports.wbg.__wbg_newnoargs_e258087cd0daa0ea = function(arg0, arg1) {\n const ret = new Function(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_has_0af94d20077affa2 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.has(getObject(arg0), getObject(arg1));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_fetch_bc7c8e27076a5c84 = function(arg0) {\n const ret = fetch(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_fetch_921fad6ef9e883dd = function(arg0, arg1) {\n const ret = getObject(arg0).fetch(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {\n const ret = debugString(getObject(arg1));\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbindgen_throw = function(arg0, arg1) {\n throw new Error(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_rethrow = function(arg0) {\n throw takeObject(arg0);\n };\n imports.wbg.__wbg_then_a73caa9a87991566 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_then_0c86a60e8fcfe9f6 = function(arg0, arg1) {\n const ret = getObject(arg0).then(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_queueMicrotask_481971b0d87f3dd4 = function(arg0) {\n queueMicrotask(getObject(arg0));\n };\n imports.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6 = function(arg0) {\n const ret = getObject(arg0).queueMicrotask;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_resolve_b0083a7967828ec8 = function(arg0) {\n const ret = Promise.resolve(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_5d743fc9058ba01a = function() {\n const ret = Atomics.waitAsync;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_8cccba86b0f574cb = function(arg0) {\n const ret = new Int32Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_46d5c36955b71a79 = function(arg0, arg1, arg2) {\n const ret = Atomics.waitAsync(getObject(arg0), arg1, arg2);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_async_19c0400d97cc72fe = function(arg0) {\n const ret = getObject(arg0).async;\n return ret;\n };\n imports.wbg.__wbg_value_571d60108110e917 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_link_fc1eedd35dc7e0a6 = function(arg0) {\n const ret = \"data:application/javascript,\" + encodeURIComponent(`onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n `);\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_new_d1187ae36d662ef9 = function() { return handleError(function (arg0, arg1) {\n const ret = new Worker(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_setonmessage_503809e5bb51bd33 = function(arg0, arg1) {\n getObject(arg0).onmessage = getObject(arg1);\n };\n imports.wbg.__wbg_of_6a70eed8d41f469c = function(arg0, arg1, arg2) {\n const ret = Array.of(getObject(arg0), getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_postMessage_7380d10e8b8269df = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).postMessage(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_data_3ce7c145ca4fbcdc = function(arg0) {\n const ret = getObject(arg0).data;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_responseText_c67ed2d48db10769 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg1).responseText;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n }, arguments) };\n imports.wbg.__wbindgen_closure_wrapper5837 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 538, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_closure_wrapper5862 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 538, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n\n return imports;\n}\n\nfunction __wbg_init_memory(imports, maybe_memory) {\n imports.wbg.memory = maybe_memory || new WebAssembly.Memory({initial:25,maximum:65536,shared:true});\n}\n\nfunction __wbg_finalize_init(instance, module) {\n wasm = instance.exports;\n __wbg_init.__wbindgen_wasm_module = module;\n cachedBigInt64Memory0 = null;\n cachedInt32Memory0 = null;\n cachedUint8Memory0 = null;\n\n wasm.__wbindgen_start();\n return wasm;\n}\n\nfunction initSync(module, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n const imports = __wbg_get_imports();\n\n __wbg_init_memory(imports, maybe_memory);\n\n if (!(module instanceof WebAssembly.Module)) {\n module = new WebAssembly.Module(module);\n }\n\n const instance = new WebAssembly.Instance(module, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nasync function __wbg_init(input, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n\n const imports = __wbg_get_imports();\n\n if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {\n input = fetch(input);\n }\n\n __wbg_init_memory(imports, maybe_memory);\n\n const { instance, module } = await __wbg_load(await input, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nvar exports = /*#__PURE__*/Object.freeze({\n __proto__: null,\n Address: Address,\n Execution: Execution,\n ExecutionResponse: ExecutionResponse,\n Field: Field,\n KeyPair: KeyPair,\n Metadata: Metadata,\n OfflineQuery: OfflineQuery,\n PrivateKey: PrivateKey,\n PrivateKeyCiphertext: PrivateKeyCiphertext,\n Program: Program,\n ProgramManager: ProgramManager,\n ProvingKey: ProvingKey,\n RecordCiphertext: RecordCiphertext,\n RecordPlaintext: RecordPlaintext,\n Signature: Signature,\n Transaction: Transaction,\n VerifyingKey: VerifyingKey,\n ViewKey: ViewKey,\n default: __wbg_init,\n initSync: initSync,\n initThreadPool: initThreadPool,\n runRayonThread: runRayonThread,\n verifyFunctionExecution: verifyFunctionExecution\n});\n\nconst wasm_path = \"assets/aleo_wasm.wasm\";\n\n \n var Cargo = async (opt = {}) => {\n let {importHook, serverPath, initializeHook} = opt;\n\n let final_path = wasm_path;\n\n if (serverPath != null) {\n final_path = serverPath + /[^\\/\\\\]*$/.exec(final_path)[0];\n }\n\n if (importHook != null) {\n final_path = importHook(final_path);\n }\n\n if (initializeHook != null) {\n await initializeHook(__wbg_init, final_path);\n\n } else {\n await __wbg_init(final_path);\n }\n\n return exports;\n };\n\nexport { Cargo as default };\n//# sourceMappingURL=wasm.js.map\n","import wasm from \"../dist/wasm.js\";\n\nconst {\n initThreadPool: wasmInitThreadPool,\n Address,\n Execution,\n ExecutionResponse,\n Field,\n Metadata,\n OfflineQuery,\n Private,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n ProgramManager,\n Signature,\n Transaction,\n ViewKey,\n VerifyingKey,\n verifyFunctionExecution,\n} = await wasm({\n importHook: () => {\n return new URL(\"assets/aleo_wasm.wasm\", import.meta.url);\n },\n});\n\nasync function initThreadPool(threads) {\n if (threads == null) {\n threads = navigator.hardwareConcurrency;\n }\n\n console.info(`Spawning ${threads} threads`);\n\n await wasmInitThreadPool(new URL(\"worker.js\", import.meta.url), threads);\n}\n\nexport {\n initThreadPool,\n Address,\n Execution,\n ExecutionResponse,\n Field,\n Metadata,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n ProgramManager,\n Signature,\n Transaction,\n ViewKey,\n VerifyingKey,\n verifyFunctionExecution,\n};\n"],"names":["spawnWorker","url","module","memory","address","Promise","resolve","worker","Worker","type","addEventListener","event","setTimeout","unref","capture","once","postMessage","wasm","heap","Array","fill","undefined","getObject","idx","push","heap_next","length","dropObject","takeObject","ret","cachedTextDecoder","TextDecoder","ignoreBOM","fatal","decode","Error","cachedUint8Memory0","getUint8Memory0","buffer","Uint8Array","getStringFromWasm0","ptr","len","slice","addHeapObject","obj","WASM_VECTOR_LEN","cachedTextEncoder","TextEncoder","encode","encodeString","arg","view","buf","set","read","written","passStringToWasm0","malloc","realloc","subarray","mem","offset","code","charCodeAt","isLikeNone","x","cachedInt32Memory0","getInt32Memory0","Int32Array","debugString","val","description","name","isArray","debug","i","builtInMatches","exec","toString","call","className","JSON","stringify","_","message","stack","CLOSURE_DTORS","FinalizationRegistry","register","unregister","state","__wbindgen_export_3","get","dtor","a","b","makeMutClosure","arg0","arg1","f","cnt","real","args","original","__wbg_adapter_34","arg2","_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3","_assertClass","instance","klass","passArray8ToWasm0","verifyFunctionExecution$1","execution","verifying_key","program","function_id","retptr","__wbindgen_add_to_stack_pointer","Execution$1","VerifyingKey$1","Program$1","ptr0","__wbindgen_malloc","__wbindgen_realloc","len0","verifyFunctionExecution","__wbg_ptr","r0","r1","cachedBigInt64Memory0","getBigInt64Memory0","BigInt64Array","getArrayU8FromWasm0","runRayonThread","receiver","initThreadPool$1","num_threads","initThreadPool","handleError","apply","this","e","__wbindgen_exn_store","__wbg_adapter_281","arg3","wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7","AddressFinalization","__wbg_address_free","Address","__wrap","Object","create","prototype","__destroy_into_raw","free","from_private_key","private_key","PrivateKey$1","address_from_private_key","from_view_key","view_key","ViewKey$1","address_from_view_key","from_string","address_from_string","to_string","deferred1_0","deferred1_1","address_to_string","__wbindgen_free","verify","signature","Signature$1","address_verify","ExecutionFinalization","__wbg_execution_free","Execution","execution_toString","fromString","execution_fromString","ExecutionResponseFinalization","__wbg_executionresponse_free","ExecutionResponse","getOutputs","executionresponse_getOutputs","getExecution","executionresponse_getExecution","getKeys","executionresponse_getKeys","KeyPair","getProvingKey","executionresponse_getProvingKey","ProvingKey$1","getVerifyingKey","executionresponse_getVerifyingKey","getFunctionId","executionresponse_getFunctionId","getProgram","executionresponse_getProgram","FieldFinalization","__wbg_field_free","Field","field_toString","field","field_fromString","KeyPairFinalization","__wbg_keypair_free","constructor","proving_key","ptr1","keypair_new","provingKey","keypair_provingKey","verifyingKey","keypair_verifyingKey","MetadataFinalization","__wbg_metadata_free","Metadata","__wbg_get_metadata_name","__wbg_set_metadata_name","locator","__wbg_get_metadata_locator","__wbg_set_metadata_locator","prover","__wbg_get_metadata_prover","__wbg_set_metadata_prover","verifier","__wbg_get_metadata_verifier","__wbg_set_metadata_verifier","__wbg_get_metadata_verifyingKey","__wbg_set_metadata_verifyingKey","baseUrl","metadata_baseUrl","bond_public","metadata_bond_public","bond_validator","metadata_bond_validator","claim_unbond_public","metadata_claim_unbond_public","fee_private","metadata_fee_private","fee_public","metadata_fee_public","inclusion","metadata_inclusion","join","metadata_join","set_validator_state","metadata_set_validator_state","split","metadata_split","transfer_private","metadata_transfer_private","transfer_private_to_public","metadata_transfer_private_to_public","transfer_public","metadata_transfer_public","transfer_public_as_signer","metadata_transfer_public_as_signer","transfer_public_to_private","metadata_transfer_public_to_private","unbond_public","metadata_unbond_public","OfflineQueryFinalization","__wbg_offlinequery_free","OfflineQuery","state_root","offlinequery_new","addStatePath","commitment","state_path","len1","offlinequery_addStatePath","offlinequery_toString","s","offlinequery_fromString","PrivateKeyFinalization","__wbg_privatekey_free","PrivateKey","privatekey_new","from_seed_unchecked","seed","privatekey_from_seed_unchecked","privatekey_from_string","privatekey_to_string","to_view_key","privatekey_to_view_key","to_address","privatekey_to_address","Address$1","sign","privatekey_sign","newEncrypted","secret","privatekey_newEncrypted","PrivateKeyCiphertext$1","toCiphertext","privatekey_toCiphertext","fromPrivateKeyCiphertext","ciphertext","privatekey_fromPrivateKeyCiphertext","PrivateKeyCiphertextFinalization","__wbg_privatekeyciphertext_free","PrivateKeyCiphertext","encryptPrivateKey","decryptToPrivateKey","privatekeyciphertext_decryptToPrivateKey","privatekeyciphertext_toString","privatekeyciphertext_fromString","ProgramFinalization","__wbg_program_free","Program","program_fromString","program_toString","hasFunction","function_name","program_hasFunction","getFunctions","program_getFunctions","getFunctionInputs","program_getFunctionInputs","getMappings","program_getMappings","getRecordMembers","record_name","program_getRecordMembers","getStructMembers","struct_name","program_getStructMembers","getCreditsProgram","program_getCreditsProgram","id","program_id","program_address","isEqual","other","program_isEqual","getImports","program_getImports","ProgramManagerFinalization","__wbg_programmanager_free","buildDeploymentTransaction","fee_credits","fee_record","imports","fee_proving_key","fee_verifying_key","offline_query","RecordPlaintext$1","ptr2","len2","ptr3","ptr4","ptr5","OfflineQuery$1","programmanager_buildDeploymentTransaction","estimateDeploymentFee","programmanager_estimateDeploymentFee","estimateProgramNameCost","programmanager_estimateProgramNameCost","r2","BigInt","asUintN","executeFunctionOffline","_function","inputs","prove_execution","cache","len4","programmanager_executeFunctionOffline","buildExecutionTransaction","len3","ptr6","ptr7","ptr8","programmanager_buildExecutionTransaction","estimateExecutionFee","programmanager_estimateExecutionFee","estimateFinalizeFee","programmanager_estimateFinalizeFee","buildJoinTransaction","record_1","record_2","join_proving_key","join_verifying_key","programmanager_buildJoinTransaction","buildSplitTransaction","split_amount","amount_record","split_proving_key","split_verifying_key","programmanager_buildSplitTransaction","buildTransferTransaction","amount_credits","recipient","transfer_type","transfer_proving_key","transfer_verifying_key","ptr9","programmanager_buildTransferTransaction","synthesizeKeyPair","programmanager_synthesizeKeyPair","ProvingKeyFinalization","__wbg_provingkey_free","ProvingKey","isBondPublicProver","provingkey_isBondPublicProver","isBondValidatorProver","provingkey_isBondValidatorProver","isClaimUnbondPublicProver","provingkey_isClaimUnbondPublicProver","isFeePrivateProver","provingkey_isFeePrivateProver","isFeePublicProver","provingkey_isFeePublicProver","isInclusionProver","provingkey_isInclusionProver","isJoinProver","provingkey_isJoinProver","isSetValidatorStateProver","provingkey_isSetValidatorStateProver","isSplitProver","provingkey_isSplitProver","isTransferPrivateProver","provingkey_isTransferPrivateProver","isTransferPrivateToPublicProver","provingkey_isTransferPrivateToPublicProver","isTransferPublicProver","provingkey_isTransferPublicProver","isTransferPublicAsSignerProver","provingkey_isTransferPublicAsSignerProver","isTransferPublicToPrivateProver","provingkey_isTransferPublicToPrivateProver","isUnbondPublicProver","provingkey_isUnbondPublicProver","checksum","provingkey_checksum","copy","provingkey_copy","fromBytes","bytes","provingkey_fromBytes","string","provingkey_fromString","toBytes","provingkey_toBytes","v1","provingkey_toString","RecordCiphertextFinalization","__wbg_recordciphertext_free","RecordCiphertext","record","recordciphertext_fromString","recordciphertext_toString","decrypt","recordciphertext_decrypt","isOwner","recordciphertext_isOwner","RecordPlaintextFinalization","__wbg_recordplaintext_free","RecordPlaintext","recordplaintext_commitment","Field$1","recordplaintext_fromString","recordplaintext_toString","microcredits","recordplaintext_microcredits","nonce","recordplaintext_nonce","serialNumberString","deferred4_0","deferred4_1","recordplaintext_serialNumberString","r3","SignatureFinalization","__wbg_signature_free","Signature","signature_verify","signature_from_string","signature_to_string","TransactionFinalization","__wbg_transaction_free","Transaction","transaction","transaction_fromString","transaction_toString","transactionId","transaction_transactionId","transactionType","transaction_transactionType","VerifyingKeyFinalization","__wbg_verifyingkey_free","VerifyingKey","bondPublicVerifier","verifyingkey_bondPublicVerifier","bondValidatorVerifier","verifyingkey_bondValidatorVerifier","claimUnbondPublicVerifier","verifyingkey_claimUnbondPublicVerifier","feePrivateVerifier","verifyingkey_feePrivateVerifier","feePublicVerifier","verifyingkey_feePublicVerifier","inclusionVerifier","verifyingkey_inclusionVerifier","joinVerifier","verifyingkey_joinVerifier","setValidatorStateVerifier","verifyingkey_setValidatorStateVerifier","splitVerifier","verifyingkey_splitVerifier","transferPrivateVerifier","verifyingkey_transferPrivateVerifier","transferPrivateToPublicVerifier","verifyingkey_transferPrivateToPublicVerifier","transferPublicVerifier","verifyingkey_transferPublicVerifier","transferPublicAsSignerVerifier","verifyingkey_transferPublicAsSignerVerifier","transferPublicToPrivateVerifier","verifyingkey_transferPublicToPrivateVerifier","unbondPublicVerifier","verifyingkey_unbondPublicVerifier","isBondPublicVerifier","verifyingkey_isBondPublicVerifier","isBondValidatorVerifier","verifyingkey_isBondValidatorVerifier","isClaimUnbondPublicVerifier","verifyingkey_isClaimUnbondPublicVerifier","isFeePrivateVerifier","verifyingkey_isFeePrivateVerifier","isFeePublicVerifier","verifyingkey_isFeePublicVerifier","isInclusionVerifier","verifyingkey_isInclusionVerifier","isJoinVerifier","verifyingkey_isJoinVerifier","isSetValidatorStateVerifier","verifyingkey_isSetValidatorStateVerifier","isSplitVerifier","verifyingkey_isSplitVerifier","isTransferPrivateVerifier","verifyingkey_isTransferPrivateVerifier","isTransferPrivateToPublicVerifier","verifyingkey_isTransferPrivateToPublicVerifier","isTransferPublicVerifier","verifyingkey_isTransferPublicVerifier","isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicAsSignerVerifier","isTransferPublicToPrivateVerifier","verifyingkey_isTransferPublicToPrivateVerifier","isUnbondPublicVerifier","verifyingkey_isUnbondPublicVerifier","verifyingkey_checksum","verifyingkey_copy","verifyingkey_fromBytes","verifyingkey_fromString","verifyingkey_toBytes","verifyingkey_toString","ViewKeyFinalization","__wbg_viewkey_free","ViewKey","viewkey_from_string","viewkey_to_string","deferred3_0","deferred3_1","viewkey_decrypt","async","__wbg_load","Response","WebAssembly","instantiateStreaming","headers","console","warn","arrayBuffer","instantiate","Instance","__wbg_get_imports","wbg","__wbindgen_object_drop_ref","__wbg_new_71801a555ad9f2aa","XMLHttpRequest","arguments","__wbg_overrideMimeType_ee9c51919ceb418b","overrideMimeType","__wbg_open_c9eb0cf2c9d95679","arg4","arg5","open","__wbg_send_80d29985093c1ec5","send","__wbg_response_7c2e2759084f7279","response","__wbg_status_d485fb5a478426fb","status","__wbg_new_72fb9a18b5ae2624","__wbindgen_string_new","__wbg_set_1f9b04f170055d33","Reflect","__wbg_new_ab6fd82b10560829","Headers","__wbindgen_object_clone_ref","__wbg_new_0d76b0581eca6298","AbortController","__wbg_signal_a61f78a3478fd9bc","signal","__wbg_append_7bfcb4937d1d5e29","append","__wbg_instanceof_Response_849eb93e75734b6e","result","__wbg_status_61a01141acd3cf74","__wbg_url_5f6dc4009ac5f99d","__wbg_headers_9620bfada380764a","__wbg_iterator_2cee6dadfd956dfa","Symbol","iterator","__wbg_get_e3c254076557e348","__wbindgen_is_function","__wbg_call_27c0f87801dedf93","__wbindgen_is_object","__wbg_next_40fc327bfc8770e6","next","__wbg_next_196c84450b364254","__wbg_done_298b57d23c0fc80c","done","__wbg_value_d93c65011f51a456","value","__wbg_abort_2aa7521d5690750e","abort","__wbg_stringify_8887fe74e1c50d81","__wbindgen_string_get","__wbg_log_0159ca40cddf5b15","log","__wbindgen_bigint_from_u64","__wbg_call_b3ca7c6051f9bec1","__wbg_transaction_new","Transaction$1","__wbg_keypair_new","__wbindgen_module","__wbg_init","__wbindgen_wasm_module","__wbindgen_memory","__wbg_spawnWorker_f6acaddb2e29dc4a","__wbg_executionresponse_new","ExecutionResponse$1","__wbg_newwithlength_66ae46612e7f0234","__wbg_set_d4638f722068f043","__wbindgen_cb_drop","__wbg_new_16b304a2cfa7ff4a","__wbg_push_a5b05aedc7234f9f","__wbg_arrayBuffer_29931d52c7206b02","__wbg_new_63b92bc8671ed464","__wbg_length_c20a40f15020d68a","__wbg_new_81740750da40724f","state0","cb0","__wbindgen_number_new","__wbg_new_abda76e883ba8a5f","__wbg_stack_658279fe44541cf6","__wbg_error_f851667af71bcfc6","deferred0_0","deferred0_1","error","__wbg_buffer_12d079cc21e14bdb","__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb","__wbg_randomFillSync_5c9c955aa56b6049","randomFillSync","__wbg_subarray_a1f73cd4b5b42fe1","__wbg_getRandomValues_3aa56aa6edec874c","getRandomValues","__wbg_set_a47bac70306a19a7","__wbg_crypto_1d1f22824a6a080c","crypto","__wbg_process_4a72847cc503995b","process","__wbg_versions_f686565e586dd935","versions","__wbg_node_104a2ff8d6ea03a2","node","__wbindgen_is_string","__wbg_require_cca90b1a94a0255b","require","__wbg_msCrypto_eb05e62b530a1508","msCrypto","__wbg_newwithlength_e9b4878cebadb3d3","__wbg_length_cd7af8117672b8b8","__wbg_get_bd8e338fbd5f5cc8","__wbg_self_ce0dbfc45cf2f5be","self","__wbg_window_c6fb939a7f436783","window","__wbg_globalThis_d1e6af4856ba331b","globalThis","__wbg_global_207b558942527489","global","__wbindgen_is_undefined","__wbg_newnoargs_e258087cd0daa0ea","Function","__wbg_has_0af94d20077affa2","has","__wbg_fetch_bc7c8e27076a5c84","fetch","__wbg_fetch_921fad6ef9e883dd","__wbindgen_debug_string","__wbindgen_throw","__wbindgen_rethrow","__wbg_then_a73caa9a87991566","then","__wbg_then_0c86a60e8fcfe9f6","__wbg_queueMicrotask_481971b0d87f3dd4","queueMicrotask","__wbg_queueMicrotask_3cbae2ec6b6cd3d6","__wbg_resolve_b0083a7967828ec8","__wbg_waitAsync_5d743fc9058ba01a","Atomics","waitAsync","__wbg_new_8cccba86b0f574cb","__wbg_waitAsync_46d5c36955b71a79","__wbg_async_19c0400d97cc72fe","__wbg_value_571d60108110e917","__wbindgen_link_fc1eedd35dc7e0a6","encodeURIComponent","__wbg_new_d1187ae36d662ef9","__wbg_setonmessage_503809e5bb51bd33","onmessage","__wbg_of_6a70eed8d41f469c","of","__wbg_postMessage_7380d10e8b8269df","__wbg_data_3ce7c145ca4fbcdc","data","__wbg_newwithstrandinit_3fd6fba4083ff2d0","Request","__wbg_responseText_c67ed2d48db10769","responseText","__wbindgen_closure_wrapper5837","__wbindgen_closure_wrapper5862","__wbg_init_memory","maybe_memory","Memory","initial","maximum","shared","__wbg_finalize_init","exports","__wbindgen_start","initSync","Module","input","URL","freeze","__proto__","Metadata$1","ProgramManager","ProgramManager$1","RecordCiphertext$1","default","wasm_path","wasmInitThreadPool","Private","opt","importHook","serverPath","initializeHook","final_path","Cargo","threads","navigator","hardwareConcurrency","info"],"sourceRoot":""} \ No newline at end of file diff --git a/268.bundle.js b/268.bundle.js deleted file mode 100644 index 4e5a2f246..000000000 --- a/268.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{var r,e,t,o,a,n,i={},p={};function c(r){var e=p[r];if(void 0!==e)return e.exports;var t=p[r]={exports:{}};return i[r](t,t.exports,c),t.exports}c.m=i,c.x=()=>{var r=c.O(void 0,[933,383],(()=>c(5383)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,i)=>{var p;i&&((p=[]).d=-1);var c,s,f,l=new Set,u=a.exports,b=new Promise(((r,e)=>{f=e,s=r}));b[e]=u,b[r]=r=>(p&&r(p),l.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{i[e]=r,o(n)}),(r=>{i[t]=r,o(n)}));var i={};return i[r]=r=>r(n),i}}var p={};return p[r]=r=>{},p[e]=a,p})))(a);var i=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(i)).r=0;var t=r=>r!==p&&!l.has(r)&&(l.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:i()}),(r=>(r?f(b[t]=r):s(u),o(p)))),p&&p.d<0&&(p.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(f=0;f=o)&&Object.keys(c.O).every((r=>c.O[r](e[p])))?e.splice(p--,1):(i=!1,o0&&a[f-1][2]>o;f--)a[f]=a[f-1];a[f]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&!r;)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={268:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var i in a)c.o(a,i)&&(c.m[i]=a[i]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([c.e(933),c.e(383)]).then(n);c.x()})(); -//# sourceMappingURL=268.bundle.js.map \ No newline at end of file diff --git a/268.bundle.js.map b/268.bundle.js.map deleted file mode 100644 index 1c8da87c8..000000000 --- a/268.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"268.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUI,EAAQA,EAAOD,QAASJ,GAG/CK,EAAOD,OACf,CAGAJ,EAAoBO,EAAID,EAGxBN,EAAoBQ,EAAI,KAGvB,IAAIC,EAAsBT,EAAoBU,OAAEP,EAAW,CAAC,IAAI,MAAM,IAAOH,EAAoB,QAEjG,OADAS,EAAsBT,EAAoBU,EAAED,EAClB,EHjCvBhB,EAAkC,mBAAXkB,OAAwBA,OAAO,kBAAoB,qBAC1EjB,EAAmC,mBAAXiB,OAAwBA,OAAO,mBAAqB,sBAC5EhB,EAAiC,mBAAXgB,OAAwBA,OAAO,iBAAmB,oBACxEf,EAAgBgB,IAChBA,GAASA,EAAMC,EAAI,IACrBD,EAAMC,EAAI,EACVD,EAAME,SAASC,GAAQA,EAAGC,MAC1BJ,EAAME,SAASC,GAAQA,EAAGC,IAAMD,EAAGC,IAAMD,MAC1C,EAyBDf,EAAoBiB,EAAI,CAACZ,EAAQa,EAAMC,KACtC,IAAIP,EACJO,KAAcP,EAAQ,IAAIC,GAAK,GAC/B,IAEIO,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GAAWF,EACvC,IAAI,IAAI9F,KAAY+F,EAChBhG,EAAoB2D,EAAEqC,EAAa/F,KACrCD,EAAoBO,EAAEN,GAAY+F,EAAY/F,IAIhD,IADGgG,GAASA,EAAQjG,GACd6C,EAASK,QACdyC,EAAgB9C,EAASqD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BjG,EAAOE,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChBkB,QAAQuC,IAAI,CAClBjE,EAAoBkC,EAAE,KACtBlC,EAAoBkC,EAAE,OACpBF,KAAKlC,GSJiBE,EAAoBQ,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(933),\n\t\t__webpack_require__.e(383)\n\t]).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [933,383], () => (__webpack_require__(5383)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && !scriptUrl) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t268: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/286.bundle.js b/286.bundle.js deleted file mode 100644 index 93e36ecd6..000000000 --- a/286.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[286],{286:(e,n,t)=>{t.r(n),t.d(n,{CLSThresholds:()=>P,FCPThresholds:()=>w,FIDThresholds:()=>ne,INPThresholds:()=>j,LCPThresholds:()=>G,TTFBThresholds:()=>Q,onCLS:()=>A,onFCP:()=>I,onFID:()=>te,onINP:()=>z,onLCP:()=>K,onTTFB:()=>V});var r,i,o,a,c,u=-1,s=function(e){addEventListener("pageshow",(function(n){n.persisted&&(u=n.timeStamp,e(n))}),!0)},f=function(){var e=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart=0?r="back-forward-cache":t&&(document.prerendering||d()>0?r="prerender":document.wasDiscarded?r="restore":t.type&&(r=t.type.replace(/_/g,"-"))),{name:e,value:void 0===n?-1:n,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},p=function(e,n,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){n(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},t||{})),r}}catch(e){}},v=function(e,n,t,r){var i,o;return function(a){n.value>=0&&(a||r)&&((o=n.value-(i||0))||void 0===i)&&(i=n.value,n.delta=o,n.rating=function(e,n){return e>n[1]?"poor":e>n[0]?"needs-improvement":"good"}(n.value,t),e(n))}},m=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},h=function(e){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&e()}))},g=function(e){var n=!1;return function(){n||(e(),n=!0)}},T=-1,y=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},E=function(e){"hidden"===document.visibilityState&&T>-1&&(T="visibilitychange"===e.type?e.timeStamp:0,b())},C=function(){addEventListener("visibilitychange",E,!0),addEventListener("prerenderingchange",E,!0)},b=function(){removeEventListener("visibilitychange",E,!0),removeEventListener("prerenderingchange",E,!0)},L=function(){return T<0&&(T=y(),C(),s((function(){setTimeout((function(){T=y(),C()}),0)}))),{get firstHiddenTime(){return T}}},S=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},w=[1800,3e3],I=function(e,n){n=n||{},S((function(){var t,r=L(),i=l("FCP"),o=p("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(o.disconnect(),e.startTimer.value&&(r.value=i,r.entries=o,t())},c=p("layout-shift",a);c&&(t=v(e,r,P,n.reportAllChanges),h((function(){a(c.takeRecords()),t(!0)})),s((function(){i=0,r=l("CLS",0),t=v(e,r,P,n.reportAllChanges),m((function(){return t()}))})),setTimeout(t,0))})))},F=0,k=1/0,M=0,D=function(e){e.forEach((function(e){e.interactionId&&(k=Math.min(k,e.interactionId),M=Math.max(M,e.interactionId),F=M?(M-k)/7+1:0)}))},B=function(){return r?F:performance.interactionCount||0},R=function(){"interactionCount"in performance||r||(r=p("event",D,{type:"event",buffered:!0,durationThreshold:0}))},x=[],H=new Map,N=0,q=[],O=function(e){if(q.forEach((function(n){return n(e)})),e.interactionId||"first-input"===e.entryType){var n=x[x.length-1],t=H.get(e.interactionId);if(t||x.length<10||e.duration>n.latency){if(t)e.duration>t.latency?(t.entries=[e],t.latency=e.duration):e.duration===t.latency&&e.startTime===t.entries[0].startTime&&t.entries.push(e);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};H.set(r.id,r),x.push(r)}x.sort((function(e,n){return n.latency-e.latency})),x.length>10&&x.splice(10).forEach((function(e){return H.delete(e.id)}))}}},_=function(e){var n=self.requestIdleCallback||self.setTimeout,t=-1;return e=g(e),"hidden"===document.visibilityState?e():(t=n(e),h(e)),t},j=[200,500],z=function(e,n){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(n=n||{},S((function(){var t;R();var r,i=l("INP"),o=function(e){_((function(){e.forEach(O);var n=function(){var e=Math.min(x.length-1,Math.floor((B()-N)/50));return x[e]}();n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())}))},a=p("event",o,{durationThreshold:null!==(t=n.durationThreshold)&&void 0!==t?t:40});r=v(e,i,j,n.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),h((function(){o(a.takeRecords()),r(!0)})),s((function(){N=B(),x.length=0,H.clear(),i=l("INP"),r=v(e,i,j,n.reportAllChanges)})))})))},G=[2500,4e3],J={},K=function(e,n){n=n||{},S((function(){var t,r=L(),i=l("LCP"),o=function(e){n.reportAllChanges||(e=e.slice(-1)),e.forEach((function(e){e.startTime=0&&o1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,n){var t=function(){Y(e,n),i()},r=function(){i()},i=function(){removeEventListener("pointerup",t,W),removeEventListener("pointercancel",r,W)};addEventListener("pointerup",t,W),addEventListener("pointercancel",r,W)}(n,e):Y(n,e)}},ee=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(n){return e(n,$,W)}))},ne=[100,300],te=function(e,n){n=n||{},S((function(){var t,r=L(),a=l("FID"),u=function(e){e.startTime0&&e.responseStart=0?r=\"back-forward-cache\":t&&(document.prerendering||u()>0?r=\"prerender\":document.wasDiscarded?r=\"restore\":t.type&&(r=t.type.replace(/_/g,\"-\")));return{name:e,value:void 0===n?-1:n,rating:\"good\",delta:0,entries:[],id:\"v4-\".concat(Date.now(),\"-\").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},s=function(e,n,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){n(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},t||{})),r}}catch(e){}},d=function(e,n,t,r){var i,o;return function(a){n.value>=0&&(a||r)&&((o=n.value-(i||0))||void 0===i)&&(i=n.value,n.delta=o,n.rating=function(e,n){return e>n[1]?\"poor\":e>n[0]?\"needs-improvement\":\"good\"}(n.value,t),e(n))}},l=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},p=function(e){document.addEventListener(\"visibilitychange\",(function(){\"hidden\"===document.visibilityState&&e()}))},v=function(e){var n=!1;return function(){n||(e(),n=!0)}},m=-1,h=function(){return\"hidden\"!==document.visibilityState||document.prerendering?1/0:0},g=function(e){\"hidden\"===document.visibilityState&&m>-1&&(m=\"visibilitychange\"===e.type?e.timeStamp:0,T())},y=function(){addEventListener(\"visibilitychange\",g,!0),addEventListener(\"prerenderingchange\",g,!0)},T=function(){removeEventListener(\"visibilitychange\",g,!0),removeEventListener(\"prerenderingchange\",g,!0)},E=function(){return m<0&&(m=h(),y(),a((function(){setTimeout((function(){m=h(),y()}),0)}))),{get firstHiddenTime(){return m}}},C=function(e){document.prerendering?addEventListener(\"prerenderingchange\",(function(){return e()}),!0):e()},b=[1800,3e3],S=function(e,n){n=n||{},C((function(){var t,r=E(),i=f(\"FCP\"),o=s(\"paint\",(function(e){e.forEach((function(e){\"first-contentful-paint\"===e.name&&(o.disconnect(),e.startTimer.value&&(r.value=i,r.entries=o,t())},u=s(\"layout-shift\",c);u&&(t=d(e,r,L,n.reportAllChanges),p((function(){c(u.takeRecords()),t(!0)})),a((function(){i=0,r=f(\"CLS\",0),t=d(e,r,L,n.reportAllChanges),l((function(){return t()}))})),setTimeout(t,0))})))},A=0,I=1/0,P=0,M=function(e){e.forEach((function(e){e.interactionId&&(I=Math.min(I,e.interactionId),P=Math.max(P,e.interactionId),A=P?(P-I)/7+1:0)}))},k=function(){return e?A:performance.interactionCount||0},F=function(){\"interactionCount\"in performance||e||(e=s(\"event\",M,{type:\"event\",buffered:!0,durationThreshold:0}))},D=[],x=new Map,R=0,B=function(){var e=Math.min(D.length-1,Math.floor((k()-R)/50));return D[e]},H=[],q=function(e){if(H.forEach((function(n){return n(e)})),e.interactionId||\"first-input\"===e.entryType){var n=D[D.length-1],t=x.get(e.interactionId);if(t||D.length<10||e.duration>n.latency){if(t)e.duration>t.latency?(t.entries=[e],t.latency=e.duration):e.duration===t.latency&&e.startTime===t.entries[0].startTime&&t.entries.push(e);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};x.set(r.id,r),D.push(r)}D.sort((function(e,n){return n.latency-e.latency})),D.length>10&&D.splice(10).forEach((function(e){return x.delete(e.id)}))}}},O=function(e){var n=self.requestIdleCallback||self.setTimeout,t=-1;return e=v(e),\"hidden\"===document.visibilityState?e():(t=n(e),p(e)),t},N=[200,500],j=function(e,n){\"PerformanceEventTiming\"in self&&\"interactionId\"in PerformanceEventTiming.prototype&&(n=n||{},C((function(){var t;F();var r,i=f(\"INP\"),o=function(e){O((function(){e.forEach(q);var n=B();n&&n.latency!==i.value&&(i.value=n.latency,i.entries=n.entries,r())}))},c=s(\"event\",o,{durationThreshold:null!==(t=n.durationThreshold)&&void 0!==t?t:40});r=d(e,i,N,n.reportAllChanges),c&&(c.observe({type:\"first-input\",buffered:!0}),p((function(){o(c.takeRecords()),r(!0)})),a((function(){R=k(),D.length=0,x.clear(),i=f(\"INP\"),r=d(e,i,N,n.reportAllChanges)})))})))},_=[2500,4e3],z={},G=function(e,n){n=n||{},C((function(){var t,r=E(),i=f(\"LCP\"),o=function(e){n.reportAllChanges||(e=e.slice(-1)),e.forEach((function(e){e.startTime=0&&t1e12?new Date:performance.now())-e.timeStamp;\"pointerdown\"==e.type?function(e,n){var t=function(){W(e,n),i()},r=function(){i()},i=function(){removeEventListener(\"pointerup\",t,U),removeEventListener(\"pointercancel\",r,U)};addEventListener(\"pointerup\",t,U),addEventListener(\"pointercancel\",r,U)}(n,e):W(n,e)}},Z=function(e){[\"mousedown\",\"keydown\",\"touchstart\",\"pointerdown\"].forEach((function(n){return e(n,Y,U)}))},$=[100,300],ee=function(e,r){r=r||{},C((function(){var o,c=E(),u=f(\"FID\"),l=function(e){e.startTime{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&i.decode();let o=null;function a(){return null!==o&&o.buffer===_.memory.buffer||(o=new Uint8Array(_.memory.buffer)),o}function s(_,t){return _>>>=0,i.decode(a().slice(_,_+t))}function c(_){r===t.length&&t.push(t.length+1);const e=r;return r=t[e],t[e]=_,e}let g=0;const w="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},d=function(_,t){const e=w.encode(_);return t.set(e),{read:_.length,written:e.length}};function b(_,t,e){if(void 0===e){const e=w.encode(_),r=t(e.length,1)>>>0;return a().subarray(r,r+e.length).set(e),g=e.length,r}let r=_.length,n=t(r,1)>>>0;const i=a();let o=0;for(;o127)break;i[n+o]=t}if(o!==r){0!==o&&(_=_.slice(o)),n=e(n,r,r=o+3*_.length,1)>>>0;const t=a().subarray(n+o,n+r);o+=d(_,t).written,n=e(n,r,o,1)>>>0}return g=o,n}function l(_){return null==_}let u=null;function f(){return null!==u&&u.buffer===_.memory.buffer||(u=new Int32Array(_.memory.buffer)),u}function p(_){const t=typeof _;if("number"==t||"boolean"==t||null==_)return`${_}`;if("string"==t)return`"${_}"`;if("symbol"==t){const t=_.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=_.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(_)){const t=_.length;let e="[";t>0&&(e+=p(_[0]));for(let r=1;r1))return toString.call(_);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(_)+")"}catch(_){return"Object"}return _ instanceof Error?`${_.name}: ${_.message}\n${_.stack}`:r}const y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>{_.__wbindgen_export_3.get(t.dtor)(t.a,t.b)}));function m(t,e,r,n){const i={a:t,b:e,cnt:1,dtor:r},o=(...t)=>{i.cnt++;const e=i.a;i.a=0;try{return n(e,i.b,...t)}finally{0==--i.cnt?(_.__wbindgen_export_3.get(i.dtor)(e,i.b),y.unregister(i)):i.a=e}};return o.original=i,y.register(o,i,i),o}function h(t,e,r){_._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(t,e,c(r))}function v(_,t){if(!(_ instanceof t))throw new Error(`expected instance of ${t.name}`);return _.ptr}function k(_,t){const e=t(1*_.length,1)>>>0;return a().set(_,e/1),g=_.length,e}let P=null;function S(){return null!==P&&P.buffer===_.memory.buffer||(P=new BigInt64Array(_.memory.buffer)),P}function V(_,t){return _>>>=0,a().subarray(_/1,_/1+t)}function x(t,e){try{return t.apply(this,e)}catch(t){_.__wbindgen_exn_store(c(t))}}const F="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_address_free(t>>>0)));class T{static __wrap(_){_>>>=0;const t=Object.create(T.prototype);return t.__wbg_ptr=_,F.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,F.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_address_free(t)}static from_private_key(t){v(t,W);const e=_.address_from_private_key(t.__wbg_ptr);return T.__wrap(e)}static from_view_key(t){v(t,a_);const e=_.address_from_view_key(t.__wbg_ptr);return T.__wrap(e)}static from_string(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.address_from_string(e,r);return T.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.address_to_string(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}verify(t,e){const r=k(t,_.__wbindgen_malloc),n=g;v(e,t_);return 0!==_.address_verify(this.__wbg_ptr,r,n,e.__wbg_ptr)}}const R="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_execution_free(t>>>0)));class z{static __wrap(_){_>>>=0;const t=Object.create(z.prototype);return t.__wbg_ptr=_,R.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,R.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_execution_free(t)}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.execution_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.execution_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return z.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const A="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_executionresponse_free(t>>>0)));class O{static __wrap(_){_>>>=0;const t=Object.create(O.prototype);return t.__wbg_ptr=_,A.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,A.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_executionresponse_free(t)}getOutputs(){return n(_.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const t=_.executionresponse_getExecution(this.__wbg_ptr);return 0===t?void 0:z.__wrap(t)}getKeys(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.executionresponse_getKeys(r,this.__wbg_ptr);var t=f()[r/4+0],e=f()[r/4+1];if(f()[r/4+2])throw n(e);return E.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const t=_.executionresponse_getProvingKey(this.__wbg_ptr);return 0===t?void 0:Q.__wrap(t)}getVerifyingKey(){const t=_.executionresponse_getVerifyingKey(this.__wbg_ptr);return i_.__wrap(t)}getFunctionId(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.executionresponse_getFunctionId(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}getProgram(){const t=_.executionresponse_getProgram(this.__wbg_ptr);return J.__wrap(t)}}const j="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_field_free(t>>>0)));class K{static __wrap(_){_>>>=0;const t=Object.create(K.prototype);return t.__wbg_ptr=_,j.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,j.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_field_free(t)}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.field_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.field_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return K.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const M="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_keypair_free(t>>>0)));class E{static __wrap(_){_>>>=0;const t=Object.create(E.prototype);return t.__wbg_ptr=_,M.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,M.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_keypair_free(t)}constructor(t,e){v(t,Q);var r=t.__destroy_into_raw();v(e,i_);var n=e.__destroy_into_raw();const i=_.keypair_new(r,n);return this.__wbg_ptr=i>>>0,this}provingKey(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.keypair_provingKey(r,this.__wbg_ptr);var t=f()[r/4+0],e=f()[r/4+1];if(f()[r/4+2])throw n(e);return Q.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.keypair_verifyingKey(r,this.__wbg_ptr);var t=f()[r/4+0],e=f()[r/4+1];if(f()[r/4+2])throw n(e);return i_.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const B="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_metadata_free(t>>>0)));class I{static __wrap(_){_>>>=0;const t=Object.create(I.prototype);return t.__wbg_ptr=_,B.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,B.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_metadata_free(t)}get name(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_name(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set name(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_name(this.__wbg_ptr,e,r)}get locator(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_locator(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set locator(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_locator(this.__wbg_ptr,e,r)}get prover(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_prover(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set prover(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_prover(this.__wbg_ptr,e,r)}get verifier(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_verifier(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set verifier(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_verifier(this.__wbg_ptr,e,r)}get verifyingKey(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_verifyingKey(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set verifyingKey(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,e,r)}static baseUrl(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.metadata_baseUrl(i);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static bond_public(){const t=_.metadata_bond_public();return I.__wrap(t)}static bond_validator(){const t=_.metadata_bond_validator();return I.__wrap(t)}static claim_unbond_public(){const t=_.metadata_claim_unbond_public();return I.__wrap(t)}static fee_private(){const t=_.metadata_fee_private();return I.__wrap(t)}static fee_public(){const t=_.metadata_fee_public();return I.__wrap(t)}static inclusion(){const t=_.metadata_inclusion();return I.__wrap(t)}static join(){const t=_.metadata_join();return I.__wrap(t)}static set_validator_state(){const t=_.metadata_set_validator_state();return I.__wrap(t)}static split(){const t=_.metadata_split();return I.__wrap(t)}static transfer_private(){const t=_.metadata_transfer_private();return I.__wrap(t)}static transfer_private_to_public(){const t=_.metadata_transfer_private_to_public();return I.__wrap(t)}static transfer_public(){const t=_.metadata_transfer_public();return I.__wrap(t)}static transfer_public_as_signer(){const t=_.metadata_transfer_public_as_signer();return I.__wrap(t)}static transfer_public_to_private(){const t=_.metadata_transfer_public_to_private();return I.__wrap(t)}static unbond_public(){const t=_.metadata_unbond_public();return I.__wrap(t)}}const U="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_offlinequery_free(t>>>0)));class C{static __wrap(_){_>>>=0;const t=Object.create(C.prototype);return t.__wbg_ptr=_,U.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,U.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_offlinequery_free(t)}constructor(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.offlinequery_new(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return this.__wbg_ptr=e>>>0,this}finally{_.__wbindgen_add_to_stack_pointer(16)}}addStatePath(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g,s=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),c=g;_.offlinequery_addStatePath(i,this.__wbg_ptr,o,a,s,c);var r=f()[i/4+0];if(f()[i/4+1])throw n(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.offlinequery_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.offlinequery_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return C.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_privatekey_free(t>>>0)));class W{static __wrap(_){_>>>=0;const t=Object.create(W.prototype);return t.__wbg_ptr=_,q.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,q.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_privatekey_free(t)}constructor(){const t=_.privatekey_new();return this.__wbg_ptr=t>>>0,this}static from_seed_unchecked(t){const e=k(t,_.__wbindgen_malloc),r=g,n=_.privatekey_from_seed_unchecked(e,r);return W.__wrap(n)}static from_string(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_from_string(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return W.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.privatekey_to_string(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}to_view_key(){const t=_.privatekey_to_view_key(this.__wbg_ptr);return a_.__wrap(t)}to_address(){const t=_.privatekey_to_address(this.__wbg_ptr);return T.__wrap(t)}sign(t){const e=k(t,_.__wbindgen_malloc),r=g,n=_.privatekey_sign(this.__wbg_ptr,e,r);return t_.__wrap(n)}static newEncrypted(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_newEncrypted(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return $.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_toCiphertext(i,this.__wbg_ptr,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return $.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16);v(t,$);const a=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g;_.privatekey_fromPrivateKeyCiphertext(o,t.__wbg_ptr,a,s);var r=f()[o/4+0],i=f()[o/4+1];if(f()[o/4+2])throw n(i);return W.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const N="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_privatekeyciphertext_free(t>>>0)));class ${static __wrap(_){_>>>=0;const t=Object.create($.prototype);return t.__wbg_ptr=_,N.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,N.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_privatekeyciphertext_free(t)}static encryptPrivateKey(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16);v(t,W);const a=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g;_.privatekey_toCiphertext(o,t.__wbg_ptr,a,s);var r=f()[o/4+0],i=f()[o/4+1];if(f()[o/4+2])throw n(i);return $.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekeyciphertext_decryptToPrivateKey(i,this.__wbg_ptr,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return W.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.privatekeyciphertext_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekeyciphertext_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return $.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const D="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_program_free(t>>>0)));class J{static __wrap(_){_>>>=0;const t=Object.create(J.prototype);return t.__wbg_ptr=_,D.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,D.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_program_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return J.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.program_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}hasFunction(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;return 0!==_.program_hasFunction(this.__wbg_ptr,e,r)}getFunctions(){return n(_.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getFunctionInputs(i,this.__wbg_ptr,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.program_getMappings(r,this.__wbg_ptr);var t=f()[r/4+0],e=f()[r/4+1];if(f()[r/4+2])throw n(e);return n(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getRecordMembers(i,this.__wbg_ptr,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getStructMembers(i,this.__wbg_ptr,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=_.program_getCreditsProgram();return J.__wrap(t)}id(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.program_id(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}address(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.program_address(r,this.__wbg_ptr);var t=f()[r/4+0],e=f()[r/4+1];if(f()[r/4+2])throw n(e);return T.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){v(t,J);return 0!==_.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return n(_.program_getImports(this.__wbg_ptr))}}const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_programmanager_free(t>>>0)));const L="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_provingkey_free(t>>>0)));class Q{static __wrap(_){_>>>=0;const t=Object.create(Q.prototype);return t.__wbg_ptr=_,L.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,L.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_provingkey_free(t)}isBondPublicProver(){return 0!==_.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==_.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==_.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==_.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==_.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==_.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==_.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==_.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==_.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==_.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==_.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==_.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==_.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==_.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==_.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_checksum(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}copy(){const t=_.provingkey_copy(this.__wbg_ptr);return Q.__wrap(t)}static fromBytes(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=k(t,_.__wbindgen_malloc),a=g;_.provingkey_fromBytes(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return Q.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.provingkey_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return Q.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const o=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_toBytes(o,this.__wbg_ptr);var t=f()[o/4+0],e=f()[o/4+1],r=f()[o/4+2];if(f()[o/4+3])throw n(r);var i=V(t,e).slice();return _.__wbindgen_free(t,1*e,1),i}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const X="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_recordciphertext_free(t>>>0)));class G{static __wrap(_){_>>>=0;const t=Object.create(G.prototype);return t.__wbg_ptr=_,X.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,X.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_recordciphertext_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.recordciphertext_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return G.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordciphertext_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}decrypt(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16);v(t,a_),_.recordciphertext_decrypt(i,this.__wbg_ptr,t.__wbg_ptr);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return Z.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}isOwner(t){v(t,a_);return 0!==_.recordciphertext_isOwner(this.__wbg_ptr,t.__wbg_ptr)}}const Y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_recordplaintext_free(t>>>0)));class Z{static __wrap(_){_>>>=0;const t=Object.create(Z.prototype);return t.__wbg_ptr=_,Y.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Y.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_recordplaintext_free(t)}commitment(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16),a=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,c=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.recordplaintext_commitment(o,this.__wbg_ptr,a,s,c,w);var r=f()[o/4+0],i=f()[o/4+1];if(f()[o/4+2])throw n(i);return K.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.recordplaintext_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return Z.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordplaintext_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}microcredits(){const t=_.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,t)}nonce(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordplaintext_nonce(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}serialNumberString(t,e,r){let i,o;try{const p=_.__wbindgen_add_to_stack_pointer(-16);v(t,W);const y=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g,h=b(r,_.__wbindgen_malloc,_.__wbindgen_realloc),k=g;_.recordplaintext_serialNumberString(p,this.__wbg_ptr,t.__wbg_ptr,y,m,h,k);var a=f()[p/4+0],c=f()[p/4+1],w=f()[p/4+2],d=f()[p/4+3],l=a,u=c;if(d)throw l=0,u=0,n(w);return i=l,o=u,s(l,u)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(i,o,1)}}}const __="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_signature_free(t>>>0)));class t_{static __wrap(_){_>>>=0;const t=Object.create(t_.prototype);return t.__wbg_ptr=_,__.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,__.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_signature_free(t)}static sign(t,e){v(t,W);const r=k(e,_.__wbindgen_malloc),n=g,i=_.privatekey_sign(t.__wbg_ptr,r,n);return t_.__wrap(i)}verify(t,e){v(t,T);const r=k(e,_.__wbindgen_malloc),n=g;return 0!==_.signature_verify(this.__wbg_ptr,t.__wbg_ptr,r,n)}static from_string(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.signature_from_string(e,r);return t_.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.signature_to_string(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const e_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_transaction_free(t>>>0)));class r_{static __wrap(_){_>>>=0;const t=Object.create(r_.prototype);return t.__wbg_ptr=_,e_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,e_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_transaction_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.transaction_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return r_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}transactionId(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_transactionId(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}transactionType(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_transactionType(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const n_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_verifyingkey_free(t>>>0)));class i_{static __wrap(_){_>>>=0;const t=Object.create(i_.prototype);return t.__wbg_ptr=_,n_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,n_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_verifyingkey_free(t)}static bondPublicVerifier(){const t=_.verifyingkey_bondPublicVerifier();return i_.__wrap(t)}static bondValidatorVerifier(){const t=_.verifyingkey_bondValidatorVerifier();return i_.__wrap(t)}static claimUnbondPublicVerifier(){const t=_.verifyingkey_claimUnbondPublicVerifier();return i_.__wrap(t)}static feePrivateVerifier(){const t=_.verifyingkey_feePrivateVerifier();return i_.__wrap(t)}static feePublicVerifier(){const t=_.verifyingkey_feePublicVerifier();return i_.__wrap(t)}static inclusionVerifier(){const t=_.verifyingkey_inclusionVerifier();return i_.__wrap(t)}static joinVerifier(){const t=_.verifyingkey_joinVerifier();return i_.__wrap(t)}static setValidatorStateVerifier(){const t=_.verifyingkey_setValidatorStateVerifier();return i_.__wrap(t)}static splitVerifier(){const t=_.verifyingkey_splitVerifier();return i_.__wrap(t)}static transferPrivateVerifier(){const t=_.verifyingkey_transferPrivateVerifier();return i_.__wrap(t)}static transferPrivateToPublicVerifier(){const t=_.verifyingkey_transferPrivateToPublicVerifier();return i_.__wrap(t)}static transferPublicVerifier(){const t=_.verifyingkey_transferPublicVerifier();return i_.__wrap(t)}static transferPublicAsSignerVerifier(){const t=_.verifyingkey_transferPublicAsSignerVerifier();return i_.__wrap(t)}static transferPublicToPrivateVerifier(){const t=_.verifyingkey_transferPublicToPrivateVerifier();return i_.__wrap(t)}static unbondPublicVerifier(){const t=_.verifyingkey_unbondPublicVerifier();return i_.__wrap(t)}isBondPublicVerifier(){return 0!==_.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==_.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==_.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==_.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==_.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==_.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==_.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==_.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==_.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==_.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==_.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==_.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==_.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==_.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==_.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_checksum(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}copy(){const t=_.verifyingkey_copy(this.__wbg_ptr);return i_.__wrap(t)}static fromBytes(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=k(t,_.__wbindgen_malloc),a=g;_.verifyingkey_fromBytes(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return i_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.verifyingkey_fromString(i,o,a);var e=f()[i/4+0],r=f()[i/4+1];if(f()[i/4+2])throw n(r);return i_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const o=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_toBytes(o,this.__wbg_ptr);var t=f()[o/4+0],e=f()[o/4+1],r=f()[o/4+2];if(f()[o/4+3])throw n(r);var i=V(t,e).slice();return _.__wbindgen_free(t,1*e,1),i}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_toString(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const o_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_viewkey_free(t>>>0)));class a_{static __wrap(_){_>>>=0;const t=Object.create(a_.prototype);return t.__wbg_ptr=_,o_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,o_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_viewkey_free(t)}static from_private_key(t){v(t,W);const e=_.privatekey_to_view_key(t.__wbg_ptr);return a_.__wrap(e)}static from_string(t){const e=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.viewkey_from_string(e,r);return a_.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.viewkey_to_string(i,this.__wbg_ptr);var r=f()[i/4+0],n=f()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}to_address(){const t=_.address_from_view_key(this.__wbg_ptr);return T.__wrap(t)}decrypt(t){let e,r;try{const l=_.__wbindgen_add_to_stack_pointer(-16),u=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),p=g;_.viewkey_decrypt(l,this.__wbg_ptr,u,p);var i=f()[l/4+0],o=f()[l/4+1],a=f()[l/4+2],c=f()[l/4+3],w=i,d=o;if(c)throw w=0,d=0,n(a);return e=w,r=d,s(w,d)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(e,r,1)}}}function s_(){const t={wbg:{}};return t.wbg.__wbindgen_object_drop_ref=function(_){n(_)},t.wbg.__wbg_new_71801a555ad9f2aa=function(){return x((function(){return c(new XMLHttpRequest)}),arguments)},t.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return x((function(_,t,r){e(_).overrideMimeType(s(t,r))}),arguments)},t.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return x((function(_,t,r,n,i,o){e(_).open(s(t,r),s(n,i),0!==o)}),arguments)},t.wbg.__wbg_send_80d29985093c1ec5=function(){return x((function(_){e(_).send()}),arguments)},t.wbg.__wbg_response_7c2e2759084f7279=function(){return x((function(_){return c(e(_).response)}),arguments)},t.wbg.__wbg_status_d485fb5a478426fb=function(){return x((function(_){return e(_).status}),arguments)},t.wbg.__wbg_new_72fb9a18b5ae2624=function(){return c(new Object)},t.wbg.__wbindgen_string_new=function(_,t){return c(s(_,t))},t.wbg.__wbg_set_1f9b04f170055d33=function(){return x((function(_,t,r){return Reflect.set(e(_),e(t),e(r))}),arguments)},t.wbg.__wbg_new_ab6fd82b10560829=function(){return x((function(){return c(new Headers)}),arguments)},t.wbg.__wbindgen_object_clone_ref=function(_){return c(e(_))},t.wbg.__wbg_new_0d76b0581eca6298=function(){return x((function(){return c(new AbortController)}),arguments)},t.wbg.__wbg_signal_a61f78a3478fd9bc=function(_){return c(e(_).signal)},t.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return x((function(_,t,r,n,i){e(_).append(s(t,r),s(n,i))}),arguments)},t.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(_){let t;try{t=e(_)instanceof Response}catch(_){t=!1}return t},t.wbg.__wbg_status_61a01141acd3cf74=function(_){return e(_).status},t.wbg.__wbg_url_5f6dc4009ac5f99d=function(t,r){const n=b(e(r).url,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;f()[t/4+1]=i,f()[t/4+0]=n},t.wbg.__wbg_headers_9620bfada380764a=function(_){return c(e(_).headers)},t.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return c(Symbol.iterator)},t.wbg.__wbg_get_e3c254076557e348=function(){return x((function(_,t){return c(Reflect.get(e(_),e(t)))}),arguments)},t.wbg.__wbindgen_is_function=function(_){return"function"==typeof e(_)},t.wbg.__wbg_call_27c0f87801dedf93=function(){return x((function(_,t){return c(e(_).call(e(t)))}),arguments)},t.wbg.__wbindgen_is_object=function(_){const t=e(_);return"object"==typeof t&&null!==t},t.wbg.__wbg_next_40fc327bfc8770e6=function(_){return c(e(_).next)},t.wbg.__wbg_next_196c84450b364254=function(){return x((function(_){return c(e(_).next())}),arguments)},t.wbg.__wbg_done_298b57d23c0fc80c=function(_){return e(_).done},t.wbg.__wbg_value_d93c65011f51a456=function(_){return c(e(_).value)},t.wbg.__wbg_abort_2aa7521d5690750e=function(_){e(_).abort()},t.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return x((function(_){return c(JSON.stringify(e(_)))}),arguments)},t.wbg.__wbindgen_string_get=function(t,r){const n=e(r),i="string"==typeof n?n:void 0;var o=l(i)?0:b(i,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;f()[t/4+1]=a,f()[t/4+0]=o},t.wbg.__wbg_log_0159ca40cddf5b15=function(_,t){console.log(s(_,t))},t.wbg.__wbindgen_bigint_from_u64=function(_){return c(BigInt.asUintN(64,_))},t.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return x((function(_,t,r){return c(e(_).call(e(t),e(r)))}),arguments)},t.wbg.__wbg_transaction_new=function(_){return c(r_.__wrap(_))},t.wbg.__wbg_keypair_new=function(_){return c(E.__wrap(_))},t.wbg.__wbindgen_module=function(){return c(w_.__wbindgen_wasm_module)},t.wbg.__wbindgen_memory=function(){return c(_.memory)},t.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a=function(_,t,r,n){return c(function(_,t,e,r){return new Promise((n=>{const i=new Worker(_,{type:"module"});i.addEventListener("message",(_=>{setTimeout((()=>{n(i),i.unref&&i.unref()}),0)}),{capture:!0,once:!0}),i.postMessage({module:t,memory:e,address:r})}))}(e(_),e(t),e(r),n>>>0))},t.wbg.__wbg_executionresponse_new=function(_){return c(O.__wrap(_))},t.wbg.__wbg_newwithlength_66ae46612e7f0234=function(_){return c(new Array(_>>>0))},t.wbg.__wbg_set_d4638f722068f043=function(_,t,r){e(_)[t>>>0]=n(r)},t.wbg.__wbindgen_cb_drop=function(_){const t=n(_).original;if(1==t.cnt--)return t.a=0,!0;return!1},t.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return c(new Array)},t.wbg.__wbg_push_a5b05aedc7234f9f=function(_,t){return e(_).push(e(t))},t.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return x((function(_){return c(e(_).arrayBuffer())}),arguments)},t.wbg.__wbg_new_63b92bc8671ed464=function(_){return c(new Uint8Array(e(_)))},t.wbg.__wbg_length_c20a40f15020d68a=function(_){return e(_).length},t.wbg.__wbg_new_81740750da40724f=function(t,e){try{var r={a:t,b:e};const n=new Promise(((t,e)=>{const n=r.a;r.a=0;try{return function(t,e,r,n){_.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(t,e,c(r),c(n))}(n,r.b,t,e)}finally{r.a=n}}));return c(n)}finally{r.a=r.b=0}},t.wbg.__wbindgen_number_new=function(_){return c(_)},t.wbg.__wbg_new_abda76e883ba8a5f=function(){return c(new Error)},t.wbg.__wbg_stack_658279fe44541cf6=function(t,r){const n=b(e(r).stack,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;f()[t/4+1]=i,f()[t/4+0]=n},t.wbg.__wbg_error_f851667af71bcfc6=function(t,e){let r,n;try{r=t,n=e,console.error(s(t,e))}finally{_.__wbindgen_free(r,n,1)}},t.wbg.__wbg_buffer_12d079cc21e14bdb=function(_){return c(e(_).buffer)},t.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(_,t,r){return c(new Uint8Array(e(_),t>>>0,r>>>0))},t.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return x((function(_,t){e(_).randomFillSync(n(t))}),arguments)},t.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(_,t,r){return c(e(_).subarray(t>>>0,r>>>0))},t.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return x((function(_,t){e(_).getRandomValues(e(t))}),arguments)},t.wbg.__wbg_set_a47bac70306a19a7=function(_,t,r){e(_).set(e(t),r>>>0)},t.wbg.__wbg_crypto_1d1f22824a6a080c=function(_){return c(e(_).crypto)},t.wbg.__wbg_process_4a72847cc503995b=function(_){return c(e(_).process)},t.wbg.__wbg_versions_f686565e586dd935=function(_){return c(e(_).versions)},t.wbg.__wbg_node_104a2ff8d6ea03a2=function(_){return c(e(_).node)},t.wbg.__wbindgen_is_string=function(_){return"string"==typeof e(_)},t.wbg.__wbg_require_cca90b1a94a0255b=function(){return x((function(){return c(module.require)}),arguments)},t.wbg.__wbg_msCrypto_eb05e62b530a1508=function(_){return c(e(_).msCrypto)},t.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(_){return c(new Uint8Array(_>>>0))},t.wbg.__wbg_length_cd7af8117672b8b8=function(_){return e(_).length},t.wbg.__wbg_get_bd8e338fbd5f5cc8=function(_,t){return c(e(_)[t>>>0])},t.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return x((function(){return c(self.self)}),arguments)},t.wbg.__wbg_window_c6fb939a7f436783=function(){return x((function(){return c(window.window)}),arguments)},t.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return x((function(){return c(globalThis.globalThis)}),arguments)},t.wbg.__wbg_global_207b558942527489=function(){return x((function(){return c(global.global)}),arguments)},t.wbg.__wbindgen_is_undefined=function(_){return void 0===e(_)},t.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(_,t){return c(new Function(s(_,t)))},t.wbg.__wbg_has_0af94d20077affa2=function(){return x((function(_,t){return Reflect.has(e(_),e(t))}),arguments)},t.wbg.__wbg_fetch_bc7c8e27076a5c84=function(_){return c(fetch(e(_)))},t.wbg.__wbg_fetch_921fad6ef9e883dd=function(_,t){return c(e(_).fetch(e(t)))},t.wbg.__wbindgen_debug_string=function(t,r){const n=b(p(e(r)),_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;f()[t/4+1]=i,f()[t/4+0]=n},t.wbg.__wbindgen_throw=function(_,t){throw new Error(s(_,t))},t.wbg.__wbindgen_rethrow=function(_){throw n(_)},t.wbg.__wbg_then_a73caa9a87991566=function(_,t,r){return c(e(_).then(e(t),e(r)))},t.wbg.__wbg_then_0c86a60e8fcfe9f6=function(_,t){return c(e(_).then(e(t)))},t.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(_){queueMicrotask(e(_))},t.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(_){return c(e(_).queueMicrotask)},t.wbg.__wbg_resolve_b0083a7967828ec8=function(_){return c(Promise.resolve(e(_)))},t.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return c(Atomics.waitAsync)},t.wbg.__wbg_new_8cccba86b0f574cb=function(_){return c(new Int32Array(e(_)))},t.wbg.__wbg_waitAsync_46d5c36955b71a79=function(_,t,r){return c(Atomics.waitAsync(e(_),t,r))},t.wbg.__wbg_async_19c0400d97cc72fe=function(_){return e(_).async},t.wbg.__wbg_value_571d60108110e917=function(_){return c(e(_).value)},t.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(t){const e=b("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;f()[t/4+1]=r,f()[t/4+0]=e},t.wbg.__wbg_new_d1187ae36d662ef9=function(){return x((function(_,t){return c(new Worker(s(_,t)))}),arguments)},t.wbg.__wbg_setonmessage_503809e5bb51bd33=function(_,t){e(_).onmessage=e(t)},t.wbg.__wbg_of_6a70eed8d41f469c=function(_,t,r){return c(Array.of(e(_),e(t),e(r)))},t.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return x((function(_,t){e(_).postMessage(e(t))}),arguments)},t.wbg.__wbg_data_3ce7c145ca4fbcdc=function(_){return c(e(_).data)},t.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return x((function(_,t,r){return c(new Request(s(_,t),e(r)))}),arguments)},t.wbg.__wbg_responseText_c67ed2d48db10769=function(){return x((function(t,r){const n=e(r).responseText;var i=l(n)?0:b(n,_.__wbindgen_malloc,_.__wbindgen_realloc),o=g;f()[t/4+1]=o,f()[t/4+0]=i}),arguments)},t.wbg.__wbindgen_closure_wrapper5837=function(_,t,e){return c(m(_,t,538,h))},t.wbg.__wbindgen_closure_wrapper5862=function(_,t,e){return c(m(_,t,538,h))},t}function c_(_,t){_.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function g_(t,e){return _=t.exports,w_.__wbindgen_wasm_module=e,P=null,u=null,o=null,_.__wbindgen_start(),_}async function w_(t,e){if(void 0!==_)return _;const r=s_();("string"==typeof t||"function"==typeof Request&&t instanceof Request||"function"==typeof URL&&t instanceof URL)&&(t=fetch(t)),c_(r,e);const{instance:n,module:i}=await async function(_,t){if("function"==typeof Response&&_ instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(_,t)}catch(t){if("application/wasm"==_.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await _.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(_,t);return e instanceof WebAssembly.Instance?{instance:e,module:_}:e}}(await t,r);return g_(n,i)}var d_=Object.freeze({__proto__:null,Address:T,Execution:z,ExecutionResponse:O,Field:K,KeyPair:E,Metadata:I,OfflineQuery:C,PrivateKey:W,PrivateKeyCiphertext:$,Program:J,ProgramManager:class{__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_programmanager_free(t)}static buildDeploymentTransaction(t,e,r,i,o,a,s,w,d){v(t,W);const u=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),f=g;let p=0;l(i)||(v(i,Z),p=i.__destroy_into_raw());var y=l(o)?0:b(o,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g;let h=0;l(s)||(v(s,Q),h=s.__destroy_into_raw());let k=0;l(w)||(v(w,i_),k=w.__destroy_into_raw());let P=0;l(d)||(v(d,C),P=d.__destroy_into_raw());return n(_.programmanager_buildDeploymentTransaction(t.__wbg_ptr,u,f,r,p,y,m,l(a)?0:c(a),h,k,P))}static estimateDeploymentFee(t,e){const r=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;return n(_.programmanager_estimateDeploymentFee(r,i,l(e)?0:c(e)))}static estimateProgramNameCost(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.programmanager_estimateProgramNameCost(i,o,a);var e=S()[i/8+0],r=f()[i/4+2];if(f()[i/4+3])throw n(r);return BigInt.asUintN(64,e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(t,e,r,i,o,a,s,w,d,u,f){v(t,W);const p=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),y=g,m=b(r,_.__wbindgen_malloc,_.__wbindgen_realloc),h=g;let k=0;l(w)||(v(w,Q),k=w.__destroy_into_raw());let P=0;l(d)||(v(d,i_),P=d.__destroy_into_raw());var S=l(u)?0:b(u,_.__wbindgen_malloc,_.__wbindgen_realloc),V=g;let x=0;l(f)||(v(f,C),x=f.__destroy_into_raw());return n(_.programmanager_executeFunctionOffline(t.__wbg_ptr,p,y,m,h,c(i),o,a,l(s)?0:c(s),k,P,S,V,x))}static buildExecutionTransaction(t,e,r,i,o,a,s,w,d,u,f,p,y){v(t,W);const m=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),h=g,k=b(r,_.__wbindgen_malloc,_.__wbindgen_realloc),P=g;let S=0;l(a)||(v(a,Z),S=a.__destroy_into_raw());var V=l(s)?0:b(s,_.__wbindgen_malloc,_.__wbindgen_realloc),x=g;let F=0;l(d)||(v(d,Q),F=d.__destroy_into_raw());let T=0;l(u)||(v(u,i_),T=u.__destroy_into_raw());let R=0;l(f)||(v(f,Q),R=f.__destroy_into_raw());let z=0;l(p)||(v(p,i_),z=p.__destroy_into_raw());let A=0;l(y)||(v(y,C),A=y.__destroy_into_raw());return n(_.programmanager_buildExecutionTransaction(t.__wbg_ptr,m,h,k,P,c(i),o,S,V,x,l(w)?0:c(w),F,T,R,z,A))}static estimateExecutionFee(t,e,r,i,o,a,s,w,d){v(t,W);const u=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),f=g,p=b(r,_.__wbindgen_malloc,_.__wbindgen_realloc),y=g;var m=l(o)?0:b(o,_.__wbindgen_malloc,_.__wbindgen_realloc),h=g;let k=0;l(s)||(v(s,Q),k=s.__destroy_into_raw());let P=0;l(w)||(v(w,i_),P=w.__destroy_into_raw());let S=0;l(d)||(v(d,C),S=d.__destroy_into_raw());return n(_.programmanager_estimateExecutionFee(t.__wbg_ptr,u,f,p,y,c(i),m,h,l(a)?0:c(a),k,P,S))}static estimateFinalizeFee(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16),a=b(t,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,c=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.programmanager_estimateFinalizeFee(o,a,s,c,w);var r=S()[o/8+0],i=f()[o/4+2];if(f()[o/4+3])throw n(i);return BigInt.asUintN(64,r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(t,e,r,i,o,a,s,c,w,d,u){v(t,W),v(e,Z);var f=e.__destroy_into_raw();v(r,Z);var p=r.__destroy_into_raw();let y=0;l(o)||(v(o,Z),y=o.__destroy_into_raw());var m=l(a)?0:b(a,_.__wbindgen_malloc,_.__wbindgen_realloc),h=g;let k=0;l(s)||(v(s,Q),k=s.__destroy_into_raw());let P=0;l(c)||(v(c,i_),P=c.__destroy_into_raw());let S=0;l(w)||(v(w,Q),S=w.__destroy_into_raw());let V=0;l(d)||(v(d,i_),V=d.__destroy_into_raw());let x=0;l(u)||(v(u,C),x=u.__destroy_into_raw());return n(_.programmanager_buildJoinTransaction(t.__wbg_ptr,f,p,i,y,m,h,k,P,S,V,x))}static buildSplitTransaction(t,e,r,i,o,a,s){v(t,W),v(r,Z);var c=r.__destroy_into_raw(),w=l(i)?0:b(i,_.__wbindgen_malloc,_.__wbindgen_realloc),d=g;let u=0;l(o)||(v(o,Q),u=o.__destroy_into_raw());let f=0;l(a)||(v(a,i_),f=a.__destroy_into_raw());let p=0;l(s)||(v(s,C),p=s.__destroy_into_raw());return n(_.programmanager_buildSplitTransaction(t.__wbg_ptr,e,c,w,d,u,f,p))}static buildTransferTransaction(t,e,r,i,o,a,s,c,w,d,u,f,p){v(t,W);const y=b(r,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g,h=b(i,_.__wbindgen_malloc,_.__wbindgen_realloc),k=g;let P=0;l(o)||(v(o,Z),P=o.__destroy_into_raw());let S=0;l(s)||(v(s,Z),S=s.__destroy_into_raw());var V=l(c)?0:b(c,_.__wbindgen_malloc,_.__wbindgen_realloc),x=g;let F=0;l(w)||(v(w,Q),F=w.__destroy_into_raw());let T=0;l(d)||(v(d,i_),T=d.__destroy_into_raw());let R=0;l(u)||(v(u,Q),R=u.__destroy_into_raw());let z=0;l(f)||(v(f,i_),z=f.__destroy_into_raw());let A=0;l(p)||(v(p,C),A=p.__destroy_into_raw());return n(_.programmanager_buildTransferTransaction(t.__wbg_ptr,e,y,m,h,k,P,a,S,V,x,F,T,R,z,A))}static synthesizeKeyPair(t,e,r,i,o){v(t,W);const a=b(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,w=b(r,_.__wbindgen_malloc,_.__wbindgen_realloc),d=g;return n(_.programmanager_synthesizeKeyPair(t.__wbg_ptr,a,s,w,d,c(i),l(o)?0:c(o)))}},ProvingKey:Q,RecordCiphertext:G,RecordPlaintext:Z,Signature:t_,Transaction:r_,VerifyingKey:i_,ViewKey:a_,default:w_,initSync:function(t,e){if(void 0!==_)return _;const r=s_();return c_(r,e),t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t)),g_(new WebAssembly.Instance(t,r),t)},initThreadPool:function(t,e){return n(_.initThreadPool(c(t),e))},runRayonThread:function(t){_.runRayonThread(t)},verifyFunctionExecution:function(t,e,r,i){try{const s=_.__wbindgen_add_to_stack_pointer(-16);v(t,z),v(e,i_),v(r,J);const c=b(i,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.verifyFunctionExecution(s,t.__wbg_ptr,e.__wbg_ptr,r.__wbg_ptr,c,w);var o=f()[s/4+0],a=f()[s/4+1];if(f()[s/4+2])throw n(a);return 0!==o}finally{_.__wbindgen_add_to_stack_pointer(16)}}});await async function(_){const[t,{module:e,memory:r,address:n}]=await Promise.all([_,new Promise((_=>{addEventListener("message",(t=>{_(t.data)}),{capture:!0,once:!0})}))]),i=await t({initializeHook:(_,t)=>_(e,r)});postMessage(null),i.runRayonThread(n),close()}((async(_={})=>{let{importHook:t,serverPath:e,initializeHook:r}=_,n="assets/aleo_wasm.wasm";return null!=e&&(n=e+/[^\/\\]*$/.exec(n)[0]),null!=t&&(n=t(n)),null!=r?await r(w_,n):await w_(n),d_})); \ No newline at end of file diff --git a/301.bundle.js b/301.bundle.js index 88ebc5cc9..08304748e 100644 --- a/301.bundle.js +++ b/301.bundle.js @@ -1,2 +1,2 @@ -(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,879,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={301:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,879,312].map(c.e,c)).then(n);c.x()})(); +(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,857,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={301:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,857,312].map(c.e,c)).then(n);c.x()})(); //# sourceMappingURL=301.bundle.js.map \ No newline at end of file diff --git a/301.bundle.js.map b/301.bundle.js.map index 19a70a13c..3e5da7614 100644 --- a/301.bundle.js.map +++ b/301.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"301.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAGpEK,EAAOD,OACf,CAGAJ,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAI,KAGvB,IAAIC,EAAsBV,EAAoBW,OAAER,EAAW,CAAC,IAAI,IAAI,MAAM,IAAOH,EAAoB,QAErG,OADAU,EAAsBV,EAAoBW,EAAED,EAClB,EHjCvBjB,EAAkC,mBAAXmB,OAAwBA,OAAO,kBAAoB,qBAC1ElB,EA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QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpF1F,EAAoB2F,EAAIb,C,WClBxB9E,EAAoB4F,EAAIC,KAAKb,SAAW,GAIxC,IAAIc,EAAkB,CACrB,IAAK,GAgBN9F,EAAoBgE,EAAEd,EAAI,CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,879,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,879,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t301: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"301.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAGpEK,EAAOD,OACf,CAGAJ,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAI,KAGvB,IAAIC,EAAsBV,EAAoBW,OAAER,EAAW,CAAC,IAAI,IAAI,MAAM,IAAOH,EAAoB,QAErG,OADAU,EAAsBV,EAAoBW,EAAED,EAClB,EHjCvBjB,EAAkC,mBAAXmB,OAAwBA,OAAO,kBAAoB,qBAC1ElB,EAAmC,mBAAXkB,OAAwBA,OAAO,mBAAqB,sBAC5EjB,EAAiC,mBAAXiB,OAAwBA,OAAO,iBAAmB,oBACxEhB,EAAgBiB,IAChBA,GAASA,EAAMC,EAAI,IACrBD,EAAMC,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B,IAAK,GAgBN9F,EAAoBgE,EAAEd,EAAI,CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,857,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,857,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t301: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/312.bundle.js b/312.bundle.js index b8e83a8c4..2268ad2c6 100644 --- a/312.bundle.js +++ b/312.bundle.js @@ -1,3 +1,3 @@ /*! For license information please see 312.bundle.js.LICENSE.txt */ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[312],{9523:(e,t,r)=>{r.a(e,(async(e,n)=>{try{r.d(t,{AleoKeyProvider:()=>f,AleoKeyProviderParams:()=>l,PrivateKey:()=>o.ZD,ProgramManager:()=>h,ProgramManagerBase:()=>o.Ao,initThreadPool:()=>o.Fs,verifyFunctionExecution:()=>o.Yc});r(5357);var o=r(9879),i=e([o]);o=(i.then?(await i)():i)[0];function a(e){return JSON.parse(e,(function(e,t,r){return Number.isInteger(t)?BigInt(r.source):t}))}async function s(e,t){const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not get URL "+e);return r}async function c(e,t){t.method="POST";const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not post URL "+e);return r}class u{host;headers;account;constructor(e,t){this.host=e+"/testnet",t&&t.headers?this.headers=t.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const t=await s(this.host+e,{headers:this.headers});return a(await t.text())}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,t,r,n,i,a){if(a=a||[],e<0)throw new Error("Start height must be greater than or equal to 0");const s=new Array;let c,u,l,f,h=0,p=BigInt(0);if(void 0===r){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");l=this.account._privateKey}else try{l=r instanceof o.ZD?r:o.ZD.from_string(r)}catch(e){throw new Error("Error parsing private key provided.")}const y=l.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");f=e}catch(e){throw new Error("Error fetching latest block height.")}if(u="number"==typeof t&&t<=f?t:f,e>u)throw new Error("Start height must be less than or equal to end height.");for(;u>e;){c=u-50,c=BigInt(i))))return s;if(void 0!==n&&n.length>0){let e=0;if(t.microcredits()>n[e]){if(e+=1,s.push(t),"number"==typeof i&&(p+=t.microcredits(),p>=BigInt(i)))return s;if(s.length>=n.length)return s}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+c.toString()+"-"+u.toString()),console.warn("Error: ",e),h+=1,h>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),s}}return s}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,t){try{return await this.fetchData("/blocks?start="+e+"&end="+t)}catch(r){throw new Error(`Error fetching blocks between ${e} and ${t}.`)}}async getDeploymentTransactionIDForProgram(e){e instanceof o.BP&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const t=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(t)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return Number(await this.fetchData("/latest/height"))}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return o.BP.fromString(e)}catch(t){try{return o.BP.fromString(await this.getProgram(e))}catch(t){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const t={},r=(e instanceof o.BP?e:await this.getProgramObject(e)).getImports();for(let e=0;e0&&!d)try{d=await this.networkClient.getProgramImports(t)}catch(e){K(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await o.Ao.buildExecutionTransaction(v,y,r,a,n,f,this.host,d,h,p,m,w,l)}async execute(e){const t=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(t)}async run(e,t,r,n,i,a,s,c,u,l){let f=u;if(void 0===u&&void 0!==this.account&&(f=this.account.privateKey()),void 0===f)throw"No private key provided and no private key set in the ProgramManager";if(!s||!c)try{[s,c]=await this.keyProvider.functionKeys(a)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",s),console.log("Verifying key: ",c),o.Ao.executeFunctionOffline(f,e,t,r,n,!1,i,s,c,this.host,l)}async join(e,t,r,n,i,a,s,c){let u,l,f=s;if(void 0===s&&void 0!==this.account&&(f=this.account.privateKey()),void 0===f)throw"No private key provided and no private key set in the ProgramManager";try{u=n?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),l=await this.keyProvider.joinKeys()}catch(e){K(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[h,p]=u,[y,d]=l;try{a=n?await this.getCreditsRecord(r,[],a,i):void 0}catch(e){K(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof o.ZF?e:o.ZF.fromString(e),t=t instanceof o.ZF?t:o.ZF.fromString(t)}catch(e){K("Records provided are not valid. Please ensure they are valid plaintext records.")}const g=await o.Ao.buildJoinTransaction(f,e,t,r,a,this.host,y,d,h,p,c);return await this.networkClient.submitTransaction(g)}async split(e,t,r,n){let i,a=r;if(void 0===a&&void 0!==this.account&&(a=this.account.privateKey()),void 0===a)throw"No private key provided and no private key set in the ProgramManager";try{i=await this.keyProvider.splitKeys()}catch(e){K(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[s,c]=i;try{t=t instanceof o.ZF?t:o.ZF.fromString(t)}catch(e){K("Record provided is not valid. Please ensure it is a valid plaintext record.")}const u=await o.Ao.buildSplitTransaction(a,e,t,this.host,s,c,n);return await this.networkClient.submitTransaction(u)}async synthesizeKeys(e,t,r,n){let i,a=n;void 0===a&&(a=void 0!==this.account?this.account.privateKey():new o.ZD);try{i=await this.networkClient.getProgramImports(e);const n=await o.Ao.synthesizeKeyPair(a,e,t,r,i);return[n.provingKey(),n.verifyingKey()]}catch(e){K(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,t,r,n,i,a,s,c,u,l){r=y(r);let f,h,d=u;if(void 0===d&&void 0!==this.account&&(d=this.account.privateKey()),void 0===d)throw"No private key provided and no private key set in the ProgramManager";try{f=i?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),h=await this.keyProvider.transferKeys(r)}catch(e){K(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[g,v]=f,[m,w]=h;try{const e=[];p(r)?(s=await this.getCreditsRecord(n,[],s,a),e.push(s.nonce())):s=void 0,c=i?await this.getCreditsRecord(n,e,c,a):void 0}catch(e){K(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await o.Ao.buildTransferTransaction(d,e,t,r,s,n,c,this.host,m,w,g,v,l)}async buildTransferPublicTransaction(e,t,r,n,o){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,o)}async buildTransferPublicAsSignerTransaction(e,t,r,n,o){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,o)}async transfer(e,t,r,n,o,i,a,s,c,u){const l=await this.buildTransferTransaction(e,t,r,n,o,i,a,s,c,u);return await this.networkClient.submitTransaction(l)}async buildBondPublicTransaction(e,t,r,n,o={}){const i=Math.trunc(1e6*n),{programName:a="credits.aleo",functionName:s="bond_public",fee:c=o.fee||.86,privateFee:u=!1,inputs:f=[e,t,r,`${i.toString()}u64`],keySearchParams:h=new l({proverUri:v.bond_public.prover,verifierUri:v.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:p=this.creditsProgram(),...y}=o,d={programName:a,functionName:s,fee:c,privateFee:u,inputs:f,keySearchParams:h,...y};return await this.buildExecutionTransaction(d)}async bondPublic(e,t,r,n,o={}){const i=await this.buildBondPublicTransaction(e,t,r,n,o);return await this.networkClient.submitTransaction(i)}async buildBondValidatorTransaction(e,t,r,n,o={}){const i=Math.trunc(1e6*r),a=Math.trunc(n),{programName:s="credits.aleo",functionName:c="bond_validator",fee:u=o.fee||.86,privateFee:f=!1,inputs:h=[e,t,`${i.toString()}u64`,`${a.toString()}u8`],keySearchParams:p=new l({proverUri:v.bond_validator.prover,verifierUri:v.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:y=this.creditsProgram(),...d}=o,g={programName:s,functionName:c,fee:u,privateFee:f,inputs:h,keySearchParams:p,...d};return await this.buildExecutionTransaction(g)}async bondValidator(e,t,r,n,o={}){const i=await this.buildBondValidatorTransaction(e,t,r,n,o);return await this.networkClient.submitTransaction(i)}async buildUnbondPublicTransaction(e,t,r={}){const n=Math.trunc(1e6*t),{programName:o="credits.aleo",functionName:i="unbond_public",fee:a=r.fee||1.3,privateFee:s=!1,inputs:c=[e,`${n.toString()}u64`],keySearchParams:u=new l({proverUri:v.unbond_public.prover,verifierUri:v.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:f=this.creditsProgram(),...h}=r,p={programName:o,functionName:i,fee:a,privateFee:s,inputs:c,keySearchParams:u,...h};return this.buildExecutionTransaction(p)}async unbondPublic(e,t,r={}){const n=await this.buildUnbondPublicTransaction(e,t,r);return await this.networkClient.submitTransaction(n)}async buildClaimUnbondPublicTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="claim_unbond_public",fee:o=t.fee||2,privateFee:i=!1,inputs:a=[e],keySearchParams:s=new l({proverUri:v.claim_unbond_public.prover,verifierUri:v.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:c=this.creditsProgram(),...u}=t,f={programName:r,functionName:n,fee:o,privateFee:i,inputs:a,keySearchParams:s,...u};return await this.buildExecutionTransaction(f)}async claimUnbondPublic(e,t={}){const r=await this.buildClaimUnbondPublicTransaction(e,t);return await this.networkClient.submitTransaction(r)}async buildSetValidatorStateTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="set_validator_state",fee:o=1,privateFee:i=!1,inputs:a=[e.toString()],keySearchParams:s=new l({proverUri:v.set_validator_state.prover,verifierUri:v.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...c}=t,u={programName:r,functionName:n,fee:o,privateFee:i,inputs:a,keySearchParams:s,...c};return await this.execute(u)}async setValidatorState(e,t={}){const r=await this.buildSetValidatorStateTransaction(e,t);return this.networkClient.submitTransaction(r)}verifyExecution(e){try{const t=e.getExecution(),r=e.getFunctionId(),n=e.getProgram(),i=e.getVerifyingKey();return(0,o.Yc)(t,i,n,r)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return o.BP.fromString(e)}creditsProgram(){return o.BP.getCreditsProgram()}verifyProgram(e){try{return o.BP.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,t,r,n){try{return r instanceof o.ZF?r:o.ZF.fromString(r)}catch(r){try{const r=this.recordProvider;return await r.findCreditsRecord(e,!0,t,n)}catch(e){K(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function p(e){return m.has(e)}function y(e){return w.has(e)?e:K(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const d=o.OS.baseUrl();function g(e){const t=o.pF[e.verifyingKey];if(!t)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:t}}const v={bond_public:g(o.OS.bond_public()),bond_validator:g(o.OS.bond_validator()),claim_unbond_public:g(o.OS.claim_unbond_public()),fee_private:g(o.OS.fee_private()),fee_public:g(o.OS.fee_public()),inclusion:g(o.OS.inclusion()),join:g(o.OS.join()),set_validator_state:g(o.OS.set_validator_state()),split:g(o.OS.split()),transfer_private:g(o.OS.transfer_private()),transfer_private_to_public:g(o.OS.transfer_private_to_public()),transfer_public:g(o.OS.transfer_public()),transfer_public_as_signer:g(o.OS.transfer_public_as_signer()),transfer_public_to_private:g(o.OS.transfer_public_to_private()),unbond_public:g(o.OS.unbond_public()),getKey:function(e){if(this.hasOwnProperty(e))return this[e];throw new Error(`Key "${e}" not found.`)}},m=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),w=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),b=new Set(["private","transfer_private","transferPrivate"]),_=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),P=new Set(["public","transfer_public","transferPublic"]),E=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),k=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function K(e){throw console.error(e),new Error(e)}n()}catch(T){n(T)}}))},4312:(e,t,r)=>{r.a(e,(async(e,t)=>{try{var n=r(9523),o=e([n]);function u(e){return u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u(e)}function l(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function f(e,t){if(e){if("string"==typeof e)return h(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?h(e,t):void 0}}function h(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r=0;--i){var a=this.tryEntries[i],s=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var c=n.call(a,"catchLoc"),u=n.call(a,"finallyLoc");if(c&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),N(r),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:R(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),m}},t}function g(e,t,r,n,o,i,a){try{var s=e[i](a),c=s.value}catch(e){return void r(e)}s.done?t(c):Promise.resolve(c).then(n,o)}function v(e){return function(){var t=this,r=arguments;return new Promise((function(n,o){var i=e.apply(t,r);function a(e){g(i,n,o,a,s,"next",e)}function s(e){g(i,n,o,a,s,"throw",e)}a(void 0)}))}}n=(o.then?(await o)():o)[0],await n.initThreadPool();var i="https://api.explorer.provable.com/v1",a=new n.AleoKeyProvider,s=new n.ProgramManager(i,a,void 0);a.useCache(!0),self.postMessage({type:"ALEO_WORKER_READY"});var c=null;self.addEventListener("message",(function(e){if("ALEO_EXECUTE_PROGRAM_LOCAL"===e.data.type){var t=e.data,r=t.localProgram,o=t.aleoFunction,u=t.inputs,h=t.privateKey;console.log("Web worker: Executing function locally...");var g=performance.now();v(d().mark((function e(){var t,i,l,f,p,y,v,m,w,b;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(e.prev=0,t=n.PrivateKey.from_string(h),i=s.createProgramFromSource(r),l=i.id(),i.hasFunction(o)){e.next=6;break}throw new Error("Program ".concat(l," does not contain function ").concat(o));case 6:if(f="".concat(l,":").concat(o),p=s.networkClient.getProgramImports(r),c===r){e.next=14;break}return e.next=11,s.synthesizeKeys(r,o,u,t);case 11:y=e.sent,s.keyProvider.cacheKeys(f,y),c=r;case 14:return v=new n.AleoKeyProviderParams({cacheKey:f}),e.next=17,s.run(r,o,u,!1,p,v,void 0,void 0,t,void 0);case 17:m=e.sent,console.log("Web worker: Local execution completed in ".concat(performance.now()-g," ms")),w=m.getOutputs(),(b=m.getExecution())?(n.verifyFunctionExecution(b,a.getKeys(f)[1],i,"hello"),b=b.toString(),console.log("Execution verified successfully: "+b)):b="",console.log("Function execution response: ".concat(w)),self.postMessage({type:"OFFLINE_EXECUTION_COMPLETED",outputs:{outputs:w,execution:b}}),e.next=30;break;case 26:e.prev=26,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 30:case"end":return e.stop()}}),e,null,[[0,26]])})))()}else if("ALEO_EXECUTE_PROGRAM_ON_CHAIN"===e.data.type){var m=e.data,w=m.remoteProgram,b=m.aleoFunction,_=m.inputs,P=m.privateKey,E=m.fee,k=m.privateFee,K=m.feeRecord,T=m.url;console.log("Web worker: Creating execution...");var x=performance.now();v(d().mark((function e(){var t,r,o,a,c,u,l;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=n.PrivateKey.from_string(P),e.next=4,s.networkClient.getProgramObject(w);case 4:if(r=e.sent,o=r.id(),r.hasFunction(b)){e.next=8;break}throw new Error("Program ".concat(o," does not contain function ").concat(b));case 8:if(a="".concat(o,":").concat(b),s.keyProvider.containsKeys(a)){e.next=15;break}return console.log("Web worker: Synthesizing proving & verifying keys for: '".concat(o,":").concat(b,"'")),e.next=13,s.synthesizeKeys(w,b,_,t);case 13:c=e.sent,s.keyProvider.cacheKeys(a,c);case 15:return u=new n.AleoKeyProviderParams({cacheKey:a}),"string"==typeof T&&s.setHost(T),e.next=19,s.execute({programName:o,functionName:b,fee:E,privateFee:k,inputs:_,keySearchParams:u,feeRecord:K,privateKey:t});case 19:l=e.sent,console.log("Web worker: On-chain execution transaction created in ".concat(performance.now()-x," ms")),self.postMessage({type:"EXECUTION_TRANSACTION_COMPLETED",executeTransaction:l}),e.next=28;break;case 24:e.prev=24,e.t0=e.catch(0),console.error("Error creating execution transaction: ".concat(e.t0)),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 28:return e.prev=28,s.setHost(i),e.finish(28);case 31:case"end":return e.stop()}}),e,null,[[0,24,28,31]])})))()}else if("ALEO_ESTIMATE_EXECUTION_FEE"===e.data.type){var S=e.data,O=S.remoteProgram,C=S.privateKey,N=S.aleoFunction,A=S.inputs,R=S.url;console.log("Web worker: Estimating execution fee...");var F=performance.now();v(d().mark((function e(){var t,r,o,i,a,c,u,h,g,v,m;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=n.PrivateKey.from_string(C),e.next=4,s.networkClient.getProgramObject(O);case 4:if(r=e.sent,o=r.id(),r.getFunctions().includes(N)){e.next=8;break}throw new Error("Program ".concat(o," does not contain function ").concat(N));case 8:return i="".concat(o,":").concat(N),e.next=11,s.networkClient.getProgramImports(O);case 11:if(a=e.sent,s.keyProvider.containsKeys(i)){e.next=18;break}return console.log("Web worker: Synthesizing proving & verifying keys for: '".concat(o,":").concat(N,"'")),e.next=16,s.synthesizeKeys(r.toString(),N,A,t);case 16:c=e.sent,s.keyProvider.cacheKeys(i,c);case 18:return u=s.keyProvider.getKeys(i),w=2,h=y(d=u)||p(d,w)||f(d,w)||l(),g=h[0],v=h[1],e.next=21,n.ProgramManagerBase.estimateExecutionFee(t,O,N,A,R,a,g,v,void 0);case 21:m=e.sent,console.log("Web worker: Execution fee estimated in ".concat(performance.now()-F," ms")),console.log("Execution Fee Estimation: ".concat(m," microcredits")),self.postMessage({type:"EXECUTION_FEE_ESTIMATION_COMPLETED",executionFee:Number(m)/1e6+.01}),e.next=31;break;case 27:e.prev=27,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 31:case"end":return e.stop()}var d,w}),e,null,[[0,27]])})))()}else if("ALEO_ESTIMATE_DEPLOYMENT_FEE"===e.data.type){var L=e.data,M=L.program;L.url;console.log("Web worker: Estimating deployment fee...");var I=performance.now();v(d().mark((function e(){var t,r;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,s.networkClient.getProgramImports(M);case 3:return t=e.sent,console.log("Estimating deployment fee.."),e.next=7,n.ProgramManagerBase.estimateDeploymentFee(M,t);case 7:r=e.sent,console.log("Web worker: Deployment fee estimation completed in ".concat(performance.now()-I," ms")),console.log("Deployment Fee Estimation: ".concat(r," microcredits")),self.postMessage({type:"DEPLOYMENT_FEE_ESTIMATION_COMPLETED",deploymentFee:Number(r)/1e6+.01}),e.next=17;break;case 13:e.prev=13,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 17:case"end":return e.stop()}}),e,null,[[0,13]])})))()}else if("ALEO_TRANSFER"===e.data.type){var B=e.data,$=B.privateKey,D=B.amountCredits,U=B.recipient,j=B.transfer_type,W=B.amountRecord,H=B.fee,V=B.privateFee,Z=B.feeRecord,z=B.url;console.log("Web worker: Creating transfer of type ".concat(j,"..."));var G=performance.now();v(d().mark((function e(){var t;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof z&&s.setHost(z),e.next=4,s.transfer(D,U,j,H,V,void 0,W,Z,n.PrivateKey.from_string($),void 0);case 4:t=e.sent,console.log("Web worker: Transfer transaction ".concat(t," created in ").concat(performance.now()-G," ms")),self.postMessage({type:"TRANSFER_TRANSACTION_COMPLETED",transferTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,s.setHost(i),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}else if("ALEO_DEPLOY"===e.data.type){var Y=e.data,X=Y.program,J=Y.privateKey,q=Y.fee,Q=Y.privateFee,ee=Y.feeRecord,te=Y.url;console.log("Web worker: Creating deployment...");var re=performance.now();v(d().mark((function e(){var t,r,o;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof te&&s.setHost(te),t=s.createProgramFromSource(X),r=!1,e.prev=4,e.next=7,s.networkClient.getProgram(t.id());case 7:r=!0,e.next=13;break;case 10:e.prev=10,e.t0=e.catch(4),console.log("Program not found on the Aleo Network - proceeding with deployment...");case 13:if(!r){e.next=15;break}throw new Error("Program ".concat(t.id()," already exists on the network"));case 15:return console.log("fee is: ",q),e.next=18,s.deploy(X,q,Q,void 0,ee,n.PrivateKey.from_string(J));case 18:o=e.sent,console.log("Web worker: Deployment transaction ".concat(o," created in ").concat(performance.now()-re," ms")),self.postMessage({type:"DEPLOY_TRANSACTION_COMPLETED",deployTransaction:o}),e.next=27;break;case 23:e.prev=23,e.t1=e.catch(0),console.log(e.t1),self.postMessage({type:"ERROR",errorMessage:e.t1.toString()});case 27:return e.prev=27,s.setHost(i),e.finish(27);case 30:case"end":return e.stop()}}),e,null,[[0,23,27,30],[4,10]])})))()}else if("ALEO_SPLIT"===e.data.type){var ne=e.data,oe=ne.splitAmount,ie=ne.record,ae=ne.privateKey,se=ne.url;console.log("Web worker: Creating split...");var ce=performance.now();v(d().mark((function e(){var t;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof se&&s.setHost(se),e.next=4,s.split(oe,ie,n.PrivateKey.from_string(ae),void 0);case 4:t=e.sent,console.log("Web worker: Split transaction ".concat(t," created in ").concat(performance.now()-ce," ms")),self.postMessage({type:"SPLIT_TRANSACTION_COMPLETED",splitTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,s.setHost(i),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}else if("ALEO_JOIN"===e.data.type){var ue=e.data,le=ue.recordOne,fe=ue.recordTwo,he=ue.fee,pe=ue.privateFee,ye=ue.feeRecord,de=ue.privateKey,ge=ue.url;console.log("Web worker: Creating join...");var ve=performance.now();v(d().mark((function e(){var t;return d().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof ge&&s.setHost(ge),e.next=4,s.join(le,fe,he,pe,void 0,ye,n.PrivateKey.from_string(de),void 0);case 4:t=e.sent,console.log("Web worker: Join transaction ".concat(t," created in ").concat(performance.now()-ve," ms")),self.postMessage({type:"JOIN_TRANSACTION_COMPLETED",joinTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,s.setHost(i),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}})),t()}catch(m){t(m)}}),1)}}]); +(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[312],{9523:(e,t,r)=>{r.a(e,(async(e,n)=>{try{r.d(t,{AleoKeyProvider:()=>a.A,AleoKeyProviderParams:()=>a.a,PrivateKey:()=>o.ZD,ProgramManager:()=>a.P,ProgramManagerBase:()=>o.Ao,initThreadPool:()=>o.Fs,verifyFunctionExecution:()=>o.Yc});r(5357);var o=r(9879),a=r(2857),i=e([o,a]);[o,a]=i.then?(await i)():i;n()}catch(e){n(e)}}))},4312:(e,t,r)=>{r.a(e,(async(e,t)=>{try{var n=r(9523),o=e([n]);function l(e){return l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l(e)}function u(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function f(e,t){if(e){if("string"==typeof e)return p(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?p(e,t):void 0}}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r=0;--a){var i=this.tryEntries[a],c=i.completion;if("root"===i.tryLoc)return o("end");if(i.tryLoc<=this.prev){var s=n.call(i,"catchLoc"),l=n.call(i,"finallyLoc");if(s&&l){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),R(r),d}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;R(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:N(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),d}},t}function g(e,t,r,n,o,a,i){try{var c=e[a](i),s=c.value}catch(e){return void r(e)}c.done?t(s):Promise.resolve(s).then(n,o)}function m(e){return function(){var t=this,r=arguments;return new Promise((function(n,o){var a=e.apply(t,r);function i(e){g(a,n,o,i,c,"next",e)}function c(e){g(a,n,o,i,c,"throw",e)}i(void 0)}))}}n=(o.then?(await o)():o)[0],await n.initThreadPool();var a="https://api.explorer.provable.com/v1",i=new n.AleoKeyProvider,c=new n.ProgramManager(a,i,void 0);i.useCache(!0),self.postMessage({type:"ALEO_WORKER_READY"});var s=null;self.addEventListener("message",(function(e){if("ALEO_EXECUTE_PROGRAM_LOCAL"===e.data.type){var t=e.data,r=t.localProgram,o=t.aleoFunction,l=t.inputs,p=t.privateKey;console.log("Web worker: Executing function locally...");var g=performance.now();m(v().mark((function e(){var t,a,u,f,y,h,m,d,w,E;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(e.prev=0,t=n.PrivateKey.from_string(p),a=c.createProgramFromSource(r),u=a.id(),a.hasFunction(o)){e.next=6;break}throw new Error("Program ".concat(u," does not contain function ").concat(o));case 6:if(f="".concat(u,":").concat(o),y=c.networkClient.getProgramImports(r),s===r){e.next=14;break}return e.next=11,c.synthesizeKeys(r,o,l,t);case 11:h=e.sent,c.keyProvider.cacheKeys(f,h),s=r;case 14:return m=new n.AleoKeyProviderParams({cacheKey:f}),e.next=17,c.run(r,o,l,!1,y,m,void 0,void 0,t,void 0);case 17:d=e.sent,console.log("Web worker: Local execution completed in ".concat(performance.now()-g," ms")),w=d.getOutputs(),(E=d.getExecution())?(n.verifyFunctionExecution(E,i.getKeys(f)[1],a,"hello"),E=E.toString(),console.log("Execution verified successfully: "+E)):E="",console.log("Function execution response: ".concat(w)),self.postMessage({type:"OFFLINE_EXECUTION_COMPLETED",outputs:{outputs:w,execution:E}}),e.next=30;break;case 26:e.prev=26,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 30:case"end":return e.stop()}}),e,null,[[0,26]])})))()}else if("ALEO_EXECUTE_PROGRAM_ON_CHAIN"===e.data.type){var d=e.data,w=d.remoteProgram,E=d.aleoFunction,b=d.inputs,x=d.privateKey,P=d.fee,k=d.privateFee,O=d.feeRecord,_=d.url;console.log("Web worker: Creating execution...");var L=performance.now();m(v().mark((function e(){var t,r,o,i,s,l,u;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=n.PrivateKey.from_string(x),e.next=4,c.networkClient.getProgramObject(w);case 4:if(r=e.sent,o=r.id(),r.hasFunction(E)){e.next=8;break}throw new Error("Program ".concat(o," does not contain function ").concat(E));case 8:if(i="".concat(o,":").concat(E),c.keyProvider.containsKeys(i)){e.next=15;break}return console.log("Web worker: Synthesizing proving & verifying keys for: '".concat(o,":").concat(E,"'")),e.next=13,c.synthesizeKeys(w,E,b,t);case 13:s=e.sent,c.keyProvider.cacheKeys(i,s);case 15:return l=new n.AleoKeyProviderParams({cacheKey:i}),"string"==typeof _&&c.setHost(_),e.next=19,c.execute({programName:o,functionName:E,fee:P,privateFee:k,inputs:b,keySearchParams:l,feeRecord:O,privateKey:t});case 19:u=e.sent,console.log("Web worker: On-chain execution transaction created in ".concat(performance.now()-L," ms")),self.postMessage({type:"EXECUTION_TRANSACTION_COMPLETED",executeTransaction:u}),e.next=28;break;case 24:e.prev=24,e.t0=e.catch(0),console.error("Error creating execution transaction: ".concat(e.t0)),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 28:return e.prev=28,c.setHost(a),e.finish(28);case 31:case"end":return e.stop()}}),e,null,[[0,24,28,31]])})))()}else if("ALEO_ESTIMATE_EXECUTION_FEE"===e.data.type){var T=e.data,A=T.remoteProgram,M=T.privateKey,R=T.aleoFunction,S=T.inputs,N=T.url;console.log("Web worker: Estimating execution fee...");var C=performance.now();m(v().mark((function e(){var t,r,o,a,i,s,l,p,g,m,d;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=n.PrivateKey.from_string(M),e.next=4,c.networkClient.getProgramObject(A);case 4:if(r=e.sent,o=r.id(),r.getFunctions().includes(R)){e.next=8;break}throw new Error("Program ".concat(o," does not contain function ").concat(R));case 8:return a="".concat(o,":").concat(R),e.next=11,c.networkClient.getProgramImports(A);case 11:if(i=e.sent,c.keyProvider.containsKeys(a)){e.next=18;break}return console.log("Web worker: Synthesizing proving & verifying keys for: '".concat(o,":").concat(R,"'")),e.next=16,c.synthesizeKeys(r.toString(),R,S,t);case 16:s=e.sent,c.keyProvider.cacheKeys(a,s);case 18:return l=c.keyProvider.getKeys(a),w=2,p=h(v=l)||y(v,w)||f(v,w)||u(),g=p[0],m=p[1],e.next=21,n.ProgramManagerBase.estimateExecutionFee(t,A,R,S,N,i,g,m,void 0);case 21:d=e.sent,console.log("Web worker: Execution fee estimated in ".concat(performance.now()-C," ms")),console.log("Execution Fee Estimation: ".concat(d," microcredits")),self.postMessage({type:"EXECUTION_FEE_ESTIMATION_COMPLETED",executionFee:Number(d)/1e6+.01}),e.next=31;break;case 27:e.prev=27,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 31:case"end":return e.stop()}var v,w}),e,null,[[0,27]])})))()}else if("ALEO_ESTIMATE_DEPLOYMENT_FEE"===e.data.type){var F=e.data,K=F.program;F.url;console.log("Web worker: Estimating deployment fee...");var I=performance.now();m(v().mark((function e(){var t,r;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,c.networkClient.getProgramImports(K);case 3:return t=e.sent,console.log("Estimating deployment fee.."),e.next=7,n.ProgramManagerBase.estimateDeploymentFee(K,t);case 7:r=e.sent,console.log("Web worker: Deployment fee estimation completed in ".concat(performance.now()-I," ms")),console.log("Deployment Fee Estimation: ".concat(r," microcredits")),self.postMessage({type:"DEPLOYMENT_FEE_ESTIMATION_COMPLETED",deploymentFee:Number(r)/1e6+.01}),e.next=17;break;case 13:e.prev=13,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 17:case"end":return e.stop()}}),e,null,[[0,13]])})))()}else if("ALEO_TRANSFER"===e.data.type){var j=e.data,W=j.privateKey,D=j.amountCredits,H=j.recipient,G=j.transfer_type,Y=j.amountRecord,U=j.fee,X=j.privateFee,z=j.feeRecord,B=j.url;console.log("Web worker: Creating transfer of type ".concat(G,"..."));var J=performance.now();m(v().mark((function e(){var t;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof B&&c.setHost(B),e.next=4,c.transfer(D,H,G,U,X,void 0,Y,z,n.PrivateKey.from_string(W),void 0);case 4:t=e.sent,console.log("Web worker: Transfer transaction ".concat(t," created in ").concat(performance.now()-J," ms")),self.postMessage({type:"TRANSFER_TRANSACTION_COMPLETED",transferTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,c.setHost(a),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}else if("ALEO_DEPLOY"===e.data.type){var Z=e.data,$=Z.program,q=Z.privateKey,Q=Z.fee,V=Z.privateFee,ee=Z.feeRecord,te=Z.url;console.log("Web worker: Creating deployment...");var re=performance.now();m(v().mark((function e(){var t,r,o;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof te&&c.setHost(te),t=c.createProgramFromSource($),r=!1,e.prev=4,e.next=7,c.networkClient.getProgram(t.id());case 7:r=!0,e.next=13;break;case 10:e.prev=10,e.t0=e.catch(4),console.log("Program not found on the Aleo Network - proceeding with deployment...");case 13:if(!r){e.next=15;break}throw new Error("Program ".concat(t.id()," already exists on the network"));case 15:return console.log("fee is: ",Q),e.next=18,c.deploy($,Q,V,void 0,ee,n.PrivateKey.from_string(q));case 18:o=e.sent,console.log("Web worker: Deployment transaction ".concat(o," created in ").concat(performance.now()-re," ms")),self.postMessage({type:"DEPLOY_TRANSACTION_COMPLETED",deployTransaction:o}),e.next=27;break;case 23:e.prev=23,e.t1=e.catch(0),console.log(e.t1),self.postMessage({type:"ERROR",errorMessage:e.t1.toString()});case 27:return e.prev=27,c.setHost(a),e.finish(27);case 30:case"end":return e.stop()}}),e,null,[[0,23,27,30],[4,10]])})))()}else if("ALEO_SPLIT"===e.data.type){var ne=e.data,oe=ne.splitAmount,ae=ne.record,ie=ne.privateKey,ce=ne.url;console.log("Web worker: Creating split...");var se=performance.now();m(v().mark((function e(){var t;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof ce&&c.setHost(ce),e.next=4,c.split(oe,ae,n.PrivateKey.from_string(ie),void 0);case 4:t=e.sent,console.log("Web worker: Split transaction ".concat(t," created in ").concat(performance.now()-se," ms")),self.postMessage({type:"SPLIT_TRANSACTION_COMPLETED",splitTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,c.setHost(a),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}else if("ALEO_JOIN"===e.data.type){var le=e.data,ue=le.recordOne,fe=le.recordTwo,pe=le.fee,ye=le.privateFee,he=le.feeRecord,ve=le.privateKey,ge=le.url;console.log("Web worker: Creating join...");var me=performance.now();m(v().mark((function e(){var t;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof ge&&c.setHost(ge),e.next=4,c.join(ue,fe,pe,ye,void 0,he,n.PrivateKey.from_string(ve),void 0);case 4:t=e.sent,console.log("Web worker: Join transaction ".concat(t," created in ").concat(performance.now()-me," ms")),self.postMessage({type:"JOIN_TRANSACTION_COMPLETED",joinTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,c.setHost(a),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}})),t()}catch(d){t(d)}}),1)}}]); //# sourceMappingURL=312.bundle.js.map \ No newline at end of file diff --git a/312.bundle.js.map b/312.bundle.js.map index ddf3d6668..add453dad 100644 --- a/312.bundle.js.map +++ b/312.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"312.bundle.js","mappings":";0WAAM,S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,QAAQjB,IAEtDmc,EAAAjG,KAAA,EAC0BsC,EAAe9M,KACrCgD,GACAC,GACA5B,GACAC,QACAQ,EACAN,GACAoL,EAAAA,WAAgBhW,YAAYd,SAC5BgM,GACH,OATKrK,EAAWgZ,EAAAvG,KAYjBlR,QAAQ0I,IAAI,gCAADsM,OAAiCvW,EAAW,gBAAAuW,OAAeR,YAAYC,MAAQF,GAAS,QACnGR,KAAKC,YAAY,CACbxV,KAAM,6BACNkZ,gBAAiBjZ,IAClBgZ,EAAAjG,KAAA,gBAAAiG,EAAA5E,KAAA,EAAA4E,EAAAvC,GAAAuC,EAAA,SAEHzX,QAAQ0I,IAAG+O,EAAAvC,IACXnB,KAAKC,YAAY,CACbxV,KAAM,QACN2W,aAAcsC,EAAAvC,GAAMhV,aACrB,QAEiC,OAFjCuX,EAAA5E,KAAA,GAEHiB,EAAevX,QAAQsX,GAAa4D,EAAArE,OAAA,6BAAAqE,EAAAzE,OAAA,GAAAwE,EAAA,uBA/B5CjE,EAkCJ,CACJ","sources":["webpack://aleo-website/../../src/utils.ts","webpack://aleo-website/../../src/network-client.ts","webpack://aleo-website/../../src/function-key-provider.ts","webpack://aleo-website/../../src/program-manager.ts","webpack://aleo-website/../../src/browser.ts","webpack://aleo-website/./src/workers/worker.js"],"sourcesContent":["export function parseJSON(json: string): any {\n function revive(key: string, value: any, context: any) {\n if (Number.isInteger(value)) {\n return BigInt(context.source);\n\n } else {\n return value;\n }\n }\n\n return JSON.parse(json, revive as any);\n}\n\n\nexport async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post, parseJSON } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./browser\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/%%NETWORK%%\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/%%NETWORK%%\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = `Error fetching blocks between ${start} and ${end}.`;\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return Number(await this.fetchData(\"/latest/height\"));\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error: any) {\n logAndThrow(\"Error fetching program imports: \" + error.message);\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error: any) {\n throw new Error(\"Error fetching program imports with error: \" + error.message);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error: any) {\n throw new Error(`Error posting transaction. Aleo network response: ${error.message}`);\n }\n } catch (error: any) {\n throw new Error(`Error posting transaction: No response received: ${error.message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./browser\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error: any) {\n throw new Error(\"Error fetching data.\" + error.message);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n throw new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n return this.fetchCreditsKeys(key);\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw new Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error: any) {\n throw new Error(`Error: fetching credits.aleo keys: ${error.message}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner: any) {\n throw new Error(\"Invalid verifying key. Error: \" + inner.message);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionExecution,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./browser\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.provable.com/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n\n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e: any) {\n logAndThrow(`Error validating program: ${e.message}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e: any) {\n logAndThrow(`Error finding ${programName}. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e: any) {\n logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e: any) {\n logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e: any) {\n logAndThrow(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program} The program object\n */\n createProgramFromSource(program: string): Program {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import \"./polyfill/shared\";\nimport {VerifyingKey, Metadata} from \"@provablehq/wasm/%%NETWORK%%.js\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n throw new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): never {\n console.error(message);\n throw new Error(message);\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm/%%NETWORK%%.js\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n","import * as aleo from \"@provablehq/sdk\";\n\nawait aleo.initThreadPool();\n\nconst defaultHost = \"https://api.explorer.provable.com/v1\";\nconst keyProvider = new aleo.AleoKeyProvider();\nconst programManager = new aleo.ProgramManager(defaultHost, keyProvider, undefined);\nkeyProvider.useCache(true);\n\nself.postMessage({\n type: \"ALEO_WORKER_READY\",\n});\n\nlet lastLocalProgram = null;\nself.addEventListener(\"message\", (ev) => {\n if (ev.data.type === \"ALEO_EXECUTE_PROGRAM_LOCAL\") {\n const { localProgram, aleoFunction, inputs, privateKey } = ev.data;\n\n console.log(\"Web worker: Executing function locally...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey);\n // Ensure the program is valid and that it contains the function specified\n const program = programManager.createProgramFromSource(localProgram);\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw new Error(`Program ${program_id} does not contain function ${aleoFunction}`);\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n\n // Get the program imports\n const imports = programManager.networkClient.getProgramImports(localProgram);\n\n // Get the proving and verifying keys for the function\n if (lastLocalProgram !== localProgram) {\n const keys = await programManager.synthesizeKeys(localProgram, aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n lastLocalProgram = localProgram;\n }\n\n // Pass the cache key to the execute function\n const keyParams = new aleo.AleoKeyProviderParams({\"cacheKey\": cacheKey});\n\n // Execute the function locally\n let response = await programManager.run(\n localProgram,\n aleoFunction,\n inputs,\n false,\n imports,\n keyParams,\n undefined,\n undefined,\n privateKeyObject,\n undefined\n );\n\n // Return the outputs to the main thread\n console.log(`Web worker: Local execution completed in ${performance.now() - startTime} ms`);\n const outputs = response.getOutputs();\n let execution = response.getExecution();\n if (execution) {\n aleo.verifyFunctionExecution(execution, keyProvider.getKeys(cacheKey)[1], program, \"hello\");\n execution = execution.toString();\n console.log(\"Execution verified successfully: \" + execution);\n } else {\n execution = \"\";\n }\n\n console.log(`Function execution response: ${outputs}`);\n self.postMessage({\n type: \"OFFLINE_EXECUTION_COMPLETED\",\n outputs: {outputs: outputs, execution: execution}\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_EXECUTE_PROGRAM_ON_CHAIN\") {\n const {\n remoteProgram,\n aleoFunction,\n inputs,\n privateKey,\n fee,\n privateFee,\n feeRecord,\n url,\n } = ev.data;\n\n console.log(\"Web worker: Creating execution...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey)\n // Ensure the program is valid and that it contains the function specified\n const program = await programManager.networkClient.getProgramObject(remoteProgram);\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw new Error(`Program ${program_id} does not contain function ${aleoFunction}`);\n }\n\n // Get the proving and verifying keys for the function\n const cacheKey = `${program_id}:${aleoFunction}`;\n if (!programManager.keyProvider.containsKeys(cacheKey)) {\n console.log(`Web worker: Synthesizing proving & verifying keys for: '${program_id}:${aleoFunction}'`);\n const keys = await programManager.synthesizeKeys(remoteProgram, aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n }\n\n // Pass the cache key to the execute function\n const keyParams = new aleo.AleoKeyProviderParams({\"cacheKey\": cacheKey})\n\n // Set the host to the provided URL if provided\n if (typeof url === \"string\") { programManager.setHost(url); }\n const transaction = await programManager.execute({\n programName: program_id,\n functionName: aleoFunction,\n fee: fee,\n privateFee: privateFee,\n inputs: inputs,\n keySearchParams: keyParams,\n feeRecord: feeRecord,\n privateKey: privateKeyObject\n });\n\n // Return the transaction id to the main thread\n console.log(`Web worker: On-chain execution transaction created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"EXECUTION_TRANSACTION_COMPLETED\",\n executeTransaction: transaction,\n });\n } catch (error) {\n console.error(`Error creating execution transaction: ${error}`);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_ESTIMATE_EXECUTION_FEE\") {\n const { remoteProgram, privateKey, aleoFunction, inputs, url } =\n ev.data;\n\n console.log(\"Web worker: Estimating execution fee...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey);\n // Ensure the program is valid and that it contains the function specified\n const program = await programManager.networkClient.getProgramObject(remoteProgram);\n const program_id = program.id();\n if (!program.getFunctions().includes(aleoFunction)) {\n throw new Error(`Program ${program_id} does not contain function ${aleoFunction}`);\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n const imports = await programManager.networkClient.getProgramImports(remoteProgram);\n\n // Get the proving and verifying keys for the function\n if (!programManager.keyProvider.containsKeys(cacheKey)) {\n console.log(`Web worker: Synthesizing proving & verifying keys for: '${program_id}:${aleoFunction}'`);\n const keys = await programManager.synthesizeKeys(program.toString(), aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n }\n\n // Estimate the execution fee\n const [provingKey, verifyingKey] = programManager.keyProvider.getKeys(cacheKey);\n let executeFee = await aleo.ProgramManagerBase.estimateExecutionFee(\n privateKeyObject,\n remoteProgram,\n aleoFunction,\n inputs,\n url,\n imports,\n provingKey,\n verifyingKey,\n undefined\n );\n\n // Return the execution fee estimate to the main thread\n console.log(`Web worker: Execution fee estimated in ${performance.now() - startTime} ms`);\n console.log(`Execution Fee Estimation: ${executeFee} microcredits`);\n self.postMessage({\n type: \"EXECUTION_FEE_ESTIMATION_COMPLETED\",\n executionFee: Number(executeFee) / 1000000 + 0.01,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_ESTIMATE_DEPLOYMENT_FEE\") {\n const { program, url } = ev.data;\n\n console.log(\"Web worker: Estimating deployment fee...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n const imports = await programManager.networkClient.getProgramImports(program);\n console.log(\"Estimating deployment fee..\");\n let deploymentFee =\n await aleo.ProgramManagerBase.estimateDeploymentFee(\n program,\n imports,\n );\n\n // Return the deployment fee estimate to the main thread\n console.log(`Web worker: Deployment fee estimation completed in ${performance.now() - startTime} ms`);\n console.log(`Deployment Fee Estimation: ${deploymentFee} microcredits`);\n self.postMessage({\n type: \"DEPLOYMENT_FEE_ESTIMATION_COMPLETED\",\n deploymentFee: Number(deploymentFee) / 1000000 + 0.01,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_TRANSFER\") {\n const {\n privateKey,\n amountCredits,\n recipient,\n transfer_type,\n amountRecord,\n fee,\n privateFee,\n feeRecord,\n url,\n } = ev.data;\n\n console.log(\n `Web worker: Creating transfer of type ${transfer_type}...`,\n );\n let startTime = performance.now();\n\n (async function () {\n try {\n // Set the host to the provided URL if provided\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the transfer transaction and submit it to the network\n const transaction = await programManager.transfer(\n amountCredits,\n recipient,\n transfer_type,\n fee,\n privateFee,\n undefined,\n amountRecord,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Transfer transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"TRANSFER_TRANSACTION_COMPLETED\",\n transferTransaction: transaction,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_DEPLOY\") {\n const { program, privateKey, fee, privateFee, feeRecord, url } = ev.data;\n\n console.log(\"Web worker: Creating deployment...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Check if the program is valid\n const programObject = programManager.createProgramFromSource(program);\n\n // Check if the program already exists on the network. If so, throw an error\n let programExists = false;\n try {\n await programManager.networkClient.getProgram(programObject.id());\n programExists = true;\n } catch (e) {\n console.log(\n `Program not found on the Aleo Network - proceeding with deployment...`,\n );\n }\n\n if (programExists) {\n throw new Error(`Program ${programObject.id()} already exists on the network`);\n }\n\n console.log(\"fee is: \", fee);\n // Create the deployment transaction and submit it to the network\n let transaction = await programManager.deploy(\n program,\n fee,\n privateFee,\n undefined,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n )\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Deployment transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"DEPLOY_TRANSACTION_COMPLETED\",\n deployTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_SPLIT\") {\n const { splitAmount, record, privateKey, url } = ev.data;\n\n console.log(\"Web worker: Creating split...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the split transaction and submit to the network\n const transaction = await programManager.split(\n splitAmount,\n record,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Split transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"SPLIT_TRANSACTION_COMPLETED\",\n splitTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_JOIN\") {\n const { recordOne, recordTwo, fee, privateFee, feeRecord, privateKey, url } =\n ev.data;\n\n console.log(\"Web worker: Creating join...\");\n\n let startTime = performance.now();\n (async function () {\n\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the join transaction and submit it to the network\n const transaction = await programManager.join(\n recordOne,\n recordTwo,\n fee,\n privateFee,\n undefined,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Join transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"JOIN_TRANSACTION_COMPLETED\",\n joinTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n }\n});\n"],"names":["parseJSON","json","JSON","parse","key","value","context","Number","isInteger","BigInt","source","async","get","url","options","response","fetch","ok","Error","status","post","method","AleoNetworkClient","host","headers","account","constructor","this","setAccount","getAccount","setHost","fetchData","text","error","findUnspentRecords","startHeight","endHeight","privateKey","amounts","maxMicrocredits","nonces","records","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","_privateKey","PrivateKey","from_string","viewKey","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","length","transactions","j","confirmedTransaction","type","transaction","execution","transitions","k","transition","program","outputs","l","output","record","RecordCiphertext","fromString","isOwner","recordPlaintext","decrypt","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","console","warn","toString","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","logAndThrow","message","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","AleoKeyProviderParams","name","proverUri","verifierUri","cacheKey","params","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","KEY_STORE","Map","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","set","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","join","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","e","inner","unBondPublicKeys","ProgramManager","keyProvider","networkClient","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","undefined","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","findCreditsRecord","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set","_regeneratorRuntime","t","r","prototype","n","o","defineProperty","Symbol","a","iterator","c","asyncIterator","u","toStringTag","define","enumerable","configurable","writable","wrap","Generator","create","Context","makeInvokeMethod","tryCatch","arg","call","h","f","s","y","GeneratorFunction","GeneratorFunctionPrototype","p","d","getPrototypeOf","v","values","g","defineIteratorMethods","forEach","_invoke","AsyncIterator","invoke","_typeof","resolve","__await","then","callInvokeWithMethodAndArg","done","delegate","maybeInvokeDelegate","sent","_sent","dispatchException","abrupt","TypeError","resultName","next","nextLoc","pushTryEntry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","resetTryEntry","completion","reset","isNaN","displayName","isGeneratorFunction","mark","setPrototypeOf","__proto__","awrap","Promise","reverse","pop","prev","charAt","slice","stop","rval","handle","complete","finish","delegateYield","asyncGeneratorStep","_asyncToGenerator","arguments","apply","_next","_throw","aleo","defaultHost","programManager","self","postMessage","lastLocalProgram","addEventListener","ev","_ev$data","localProgram","aleoFunction","startTime","performance","now","_callee","privateKeyObject","program_id","keyParams","_context","hasFunction","concat","getOutputs","t0","errorMessage","_ev$data2","remoteProgram","_callee2","_context2","executeTransaction","_ev$data3","_callee3","_programManager$keyPr","_programManager$keyPr2","executeFee","_context3","getFunctions","estimateExecutionFee","executionFee","_ev$data4","_callee4","deploymentFee","_context4","estimateDeploymentFee","_ev$data5","amountCredits","transfer_type","_callee5","_context5","transferTransaction","_ev$data6","_callee6","programExists","_context6","deployTransaction","t1","_ev$data7","_callee7","_context7","splitTransaction","_ev$data8","_call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,KAAA,gBAAA4J,EAAAjI,KAAA,EAAAiI,EAAAnE,GAAAmE,EAAA,SAEHjG,QAAQC,IAAGgG,EAAAnE,IACXzC,KAAKC,YAAY,CACbtF,KAAM,QACNgI,aAAciE,EAAAnE,GAAMD,aACrB,QAEiC,OAFjCoE,EAAAjI,KAAA,GAEHkB,EAAe0D,QAAQ5D,GAAaiH,EAAA1H,OAAA,6BAAA0H,EAAA9H,OAAA,GAAA6H,EAAA,uBA/B5CtH,EAkCJ,CACJ","sources":["webpack://aleo-website/./src/workers/worker.js"],"sourcesContent":["import * as aleo from \"@provablehq/sdk\";\n\nawait aleo.initThreadPool();\n\nconst defaultHost = \"https://api.explorer.provable.com/v1\";\nconst keyProvider = new aleo.AleoKeyProvider();\nconst programManager = new aleo.ProgramManager(defaultHost, keyProvider, undefined);\nkeyProvider.useCache(true);\n\nself.postMessage({\n type: \"ALEO_WORKER_READY\",\n});\n\nlet lastLocalProgram = null;\nself.addEventListener(\"message\", (ev) => {\n if (ev.data.type === \"ALEO_EXECUTE_PROGRAM_LOCAL\") {\n const { localProgram, aleoFunction, inputs, privateKey } = ev.data;\n\n console.log(\"Web worker: Executing function locally...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey);\n // Ensure the program is valid and that it contains the function specified\n const program = programManager.createProgramFromSource(localProgram);\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw new Error(`Program ${program_id} does not contain function ${aleoFunction}`);\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n\n // Get the program imports\n const imports = programManager.networkClient.getProgramImports(localProgram);\n\n // Get the proving and verifying keys for the function\n if (lastLocalProgram !== localProgram) {\n const keys = await programManager.synthesizeKeys(localProgram, aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n lastLocalProgram = localProgram;\n }\n\n // Pass the cache key to the execute function\n const keyParams = new aleo.AleoKeyProviderParams({\"cacheKey\": cacheKey});\n\n // Execute the function locally\n let response = await programManager.run(\n localProgram,\n aleoFunction,\n inputs,\n false,\n imports,\n keyParams,\n undefined,\n undefined,\n privateKeyObject,\n undefined\n );\n\n // Return the outputs to the main thread\n console.log(`Web worker: Local execution completed in ${performance.now() - startTime} ms`);\n const outputs = response.getOutputs();\n let execution = response.getExecution();\n if (execution) {\n aleo.verifyFunctionExecution(execution, keyProvider.getKeys(cacheKey)[1], program, \"hello\");\n execution = execution.toString();\n console.log(\"Execution verified successfully: \" + execution);\n } else {\n execution = \"\";\n }\n\n console.log(`Function execution response: ${outputs}`);\n self.postMessage({\n type: \"OFFLINE_EXECUTION_COMPLETED\",\n outputs: {outputs: outputs, execution: execution}\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_EXECUTE_PROGRAM_ON_CHAIN\") {\n const {\n remoteProgram,\n aleoFunction,\n inputs,\n privateKey,\n fee,\n privateFee,\n feeRecord,\n url,\n } = ev.data;\n\n console.log(\"Web worker: Creating execution...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey)\n // Ensure the program is valid and that it contains the function specified\n const program = await programManager.networkClient.getProgramObject(remoteProgram);\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw new Error(`Program ${program_id} does not contain function ${aleoFunction}`);\n }\n\n // Get the proving and verifying keys for the function\n const cacheKey = `${program_id}:${aleoFunction}`;\n if (!programManager.keyProvider.containsKeys(cacheKey)) {\n console.log(`Web worker: Synthesizing proving & verifying keys for: '${program_id}:${aleoFunction}'`);\n const keys = await programManager.synthesizeKeys(remoteProgram, aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n }\n\n // Pass the cache key to the execute function\n const keyParams = new aleo.AleoKeyProviderParams({\"cacheKey\": cacheKey})\n\n // Set the host to the provided URL if provided\n if (typeof url === \"string\") { programManager.setHost(url); }\n const transaction = await programManager.execute({\n programName: program_id,\n functionName: aleoFunction,\n fee: fee,\n privateFee: privateFee,\n inputs: inputs,\n keySearchParams: keyParams,\n feeRecord: feeRecord,\n privateKey: privateKeyObject\n });\n\n // Return the transaction id to the main thread\n console.log(`Web worker: On-chain execution transaction created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"EXECUTION_TRANSACTION_COMPLETED\",\n executeTransaction: transaction,\n });\n } catch (error) {\n console.error(`Error creating execution transaction: ${error}`);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_ESTIMATE_EXECUTION_FEE\") {\n const { remoteProgram, privateKey, aleoFunction, inputs, url } =\n ev.data;\n\n console.log(\"Web worker: Estimating execution fee...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey);\n // Ensure the program is valid and that it contains the function specified\n const program = await programManager.networkClient.getProgramObject(remoteProgram);\n const program_id = program.id();\n if (!program.getFunctions().includes(aleoFunction)) {\n throw new Error(`Program ${program_id} does not contain function ${aleoFunction}`);\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n const imports = await programManager.networkClient.getProgramImports(remoteProgram);\n\n // Get the proving and verifying keys for the function\n if (!programManager.keyProvider.containsKeys(cacheKey)) {\n console.log(`Web worker: Synthesizing proving & verifying keys for: '${program_id}:${aleoFunction}'`);\n const keys = await programManager.synthesizeKeys(program.toString(), aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n }\n\n // Estimate the execution fee\n const [provingKey, verifyingKey] = programManager.keyProvider.getKeys(cacheKey);\n let executeFee = await aleo.ProgramManagerBase.estimateExecutionFee(\n privateKeyObject,\n remoteProgram,\n aleoFunction,\n inputs,\n url,\n imports,\n provingKey,\n verifyingKey,\n undefined\n );\n\n // Return the execution fee estimate to the main thread\n console.log(`Web worker: Execution fee estimated in ${performance.now() - startTime} ms`);\n console.log(`Execution Fee Estimation: ${executeFee} microcredits`);\n self.postMessage({\n type: \"EXECUTION_FEE_ESTIMATION_COMPLETED\",\n executionFee: Number(executeFee) / 1000000 + 0.01,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_ESTIMATE_DEPLOYMENT_FEE\") {\n const { program, url } = ev.data;\n\n console.log(\"Web worker: Estimating deployment fee...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n const imports = await programManager.networkClient.getProgramImports(program);\n console.log(\"Estimating deployment fee..\");\n let deploymentFee =\n await aleo.ProgramManagerBase.estimateDeploymentFee(\n program,\n imports,\n );\n\n // Return the deployment fee estimate to the main thread\n console.log(`Web worker: Deployment fee estimation completed in ${performance.now() - startTime} ms`);\n console.log(`Deployment Fee Estimation: ${deploymentFee} microcredits`);\n self.postMessage({\n type: \"DEPLOYMENT_FEE_ESTIMATION_COMPLETED\",\n deploymentFee: Number(deploymentFee) / 1000000 + 0.01,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_TRANSFER\") {\n const {\n privateKey,\n amountCredits,\n recipient,\n transfer_type,\n amountRecord,\n fee,\n privateFee,\n feeRecord,\n url,\n } = ev.data;\n\n console.log(\n `Web worker: Creating transfer of type ${transfer_type}...`,\n );\n let startTime = performance.now();\n\n (async function () {\n try {\n // Set the host to the provided URL if provided\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the transfer transaction and submit it to the network\n const transaction = await programManager.transfer(\n amountCredits,\n recipient,\n transfer_type,\n fee,\n privateFee,\n undefined,\n amountRecord,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Transfer transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"TRANSFER_TRANSACTION_COMPLETED\",\n transferTransaction: transaction,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_DEPLOY\") {\n const { program, privateKey, fee, privateFee, feeRecord, url } = ev.data;\n\n console.log(\"Web worker: Creating deployment...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Check if the program is valid\n const programObject = programManager.createProgramFromSource(program);\n\n // Check if the program already exists on the network. If so, throw an error\n let programExists = false;\n try {\n await programManager.networkClient.getProgram(programObject.id());\n programExists = true;\n } catch (e) {\n console.log(\n `Program not found on the Aleo Network - proceeding with deployment...`,\n );\n }\n\n if (programExists) {\n throw new Error(`Program ${programObject.id()} already exists on the network`);\n }\n\n console.log(\"fee is: \", fee);\n // Create the deployment transaction and submit it to the network\n let transaction = await programManager.deploy(\n program,\n fee,\n privateFee,\n undefined,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n )\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Deployment transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"DEPLOY_TRANSACTION_COMPLETED\",\n deployTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_SPLIT\") {\n const { splitAmount, record, privateKey, url } = ev.data;\n\n console.log(\"Web worker: Creating split...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the split transaction and submit to the network\n const transaction = await programManager.split(\n splitAmount,\n record,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Split transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"SPLIT_TRANSACTION_COMPLETED\",\n splitTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_JOIN\") {\n const { recordOne, recordTwo, fee, privateFee, feeRecord, privateKey, url } =\n ev.data;\n\n console.log(\"Web worker: Creating join...\");\n\n let startTime = performance.now();\n (async function () {\n\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the join transaction and submit it to the network\n const transaction = await programManager.join(\n recordOne,\n recordTwo,\n fee,\n privateFee,\n undefined,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Join transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"JOIN_TRANSACTION_COMPLETED\",\n joinTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n }\n});\n"],"names":["_regeneratorRuntime","e","t","r","Object","prototype","n","hasOwnProperty","o","defineProperty","value","i","Symbol","a","iterator","c","asyncIterator","u","toStringTag","define","enumerable","configurable","writable","wrap","Generator","create","Context","makeInvokeMethod","tryCatch","type","arg","call","h","l","f","s","y","GeneratorFunction","GeneratorFunctionPrototype","p","d","getPrototypeOf","v","values","g","defineIteratorMethods","forEach","_invoke","AsyncIterator","invoke","_typeof","resolve","__await","then","callInvokeWithMethodAndArg","Error","done","method","delegate","maybeInvokeDelegate","sent","_sent","dispatchException","abrupt","TypeError","resultName","next","nextLoc","pushTryEntry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","push","resetTryEntry","completion","reset","isNaN","length","displayName","isGeneratorFunction","constructor","name","mark","setPrototypeOf","__proto__","awrap","async","Promise","keys","reverse","pop","prev","charAt","slice","stop","rval","handle","complete","finish","delegateYield","asyncGeneratorStep","_asyncToGenerator","arguments","apply","_next","_throw","aleo","defaultHost","keyProvider","programManager","undefined","useCache","self","postMessage","lastLocalProgram","addEventListener","ev","data","_ev$data","localProgram","aleoFunction","inputs","privateKey","console","log","startTime","performance","now","_callee","privateKeyObject","program","program_id","cacheKey","imports","keyParams","response","outputs","execution","_context","from_string","createProgramFromSource","id","hasFunction","concat","networkClient","getProgramImports","synthesizeKeys","cacheKeys","run","getOutputs","getExecution","getKeys","toString","t0","error","errorMessage","_ev$data2","remoteProgram","fee","privateFee","feeRecord","url","_callee2","transaction","_context2","getProgramObject","containsKeys","setHost","execute","programName","functionName","keySearchParams","executeTransaction","_ev$data3","_callee3","_programManager$keyPr","_programManager$keyPr2","provingKey","verifyingKey","executeFee","_context3","getFunctions","includes","estimateExecutionFee","executionFee","Number","_ev$data4","_callee4","deploymentFee","_context4","estimateDeploymentFee","_ev$data5","amountCredits","recipient","transfer_type","amountRecord","_callee5","_context5","transfer","transferTransaction","_ev$data6","_callee6","programObject","programExists","_context6","getProgram","deploy","deployTransaction","t1","_ev$data7","splitAmount","record","_callee7","_context7","split","splitTransaction","_ev$data8","recordOne","recordTwo","_callee8","_context8","join","joinTransaction"],"sourceRoot":""} \ No newline at end of file diff --git a/358.bundle.js b/358.bundle.js deleted file mode 100644 index 71c125cb8..000000000 --- a/358.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{var r,e,t,o,a,n,i={},p={};function c(r){var e=p[r];if(void 0!==e)return e.exports;var t=p[r]={exports:{}};return i[r](t,t.exports,c),t.exports}c.m=i,c.x=()=>{var r=c.O(void 0,[933,383],(()=>c(5383)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,i)=>{var p;i&&((p=[]).d=-1);var c,s,f,l=new Set,u=a.exports,b=new Promise(((r,e)=>{f=e,s=r}));b[e]=u,b[r]=r=>(p&&r(p),l.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{i[e]=r,o(n)}),(r=>{i[t]=r,o(n)}));var i={};return i[r]=r=>r(n),i}}var p={};return p[r]=r=>{},p[e]=a,p})))(a);var i=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(i)).r=0;var t=r=>r!==p&&!l.has(r)&&(l.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:i()}),(r=>(r?f(b[t]=r):s(u),o(p)))),p&&p.d<0&&(p.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(f=0;f=o)&&Object.keys(c.O).every((r=>c.O[r](e[p])))?e.splice(p--,1):(i=!1,o0&&a[f-1][2]>o;f--)a[f]=a[f-1];a[f]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&!r;)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={358:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var i in a)c.o(a,i)&&(c.m[i]=a[i]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([c.e(933),c.e(383)]).then(n);c.x()})(); -//# sourceMappingURL=358.bundle.js.map \ No newline at end of file diff --git a/358.bundle.js.map b/358.bundle.js.map deleted file mode 100644 index c493f1046..000000000 --- a/358.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"358.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUI,EAAQA,EAAOD,QAASJ,GAG/CK,EAAOD,OACf,CAGAJ,EAAoBO,EAAID,EAGxBN,EAAoBQ,EAAI,KAGvB,IAAIC,EAAsBT,EAAoBU,OAAEP,EAAW,CAAC,IAAI,MAAM,IAAOH,EAAoB,QAEjG,OADAS,EAAsBT,EAAoBU,EAAED,EAClB,EHjCvBhB,EAAkC,mBAAXkB,OAAwBA,OAAO,kBAAoB,qBAC1EjB,EAAmC,mBAAXiB,OAAwBA,OAAO,mBAAqB,sBAC5EhB,EAAiC,mBAAXgB,OAAwBA,OAAO,iBAAmB,oBACxEf,EAAgBgB,IAChBA,GAASA,EAAMC,EAAI,IACrBD,EAAMC,EAAI,EACVD,EAAME,SAASC,GAAQA,EAAGC,MAC1BJ,EAAME,SAASC,GAAQA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AI4B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBlD,KAAKoD,KAAKF,GAC9DA,EAAmBlD,KAvBCqD,IACnB,IAAKlD,EAAUmD,EAAaC,GAAWF,EACvC,IAAI,IAAI9F,KAAY+F,EAChBhG,EAAoB2D,EAAEqC,EAAa/F,KACrCD,EAAoBO,EAAEN,GAAY+F,EAAY/F,IAIhD,IADGgG,GAASA,EAAQjG,GACd6C,EAASK,QACdyC,EAAgB9C,EAASqD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BjG,EAAOE,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChBkB,QAAQuC,IAAI,CAClBjE,EAAoBkC,EAAE,KACtBlC,EAAoBkC,EAAE,OACpBF,KAAKlC,GSJiBE,EAAoBQ,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(933),\n\t\t__webpack_require__.e(383)\n\t]).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [933,383], () => (__webpack_require__(5383)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && !scriptUrl) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t358: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/383.bundle.js b/383.bundle.js deleted file mode 100644 index 61e9b3aaa..000000000 --- a/383.bundle.js +++ /dev/null @@ -1,3 +0,0 @@ -/*! For license information please see 383.bundle.js.LICENSE.txt */ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[383],{5052:(e,t,r)=>{r.a(e,(async(e,n)=>{try{r.d(t,{AleoKeyProvider:()=>p,AleoKeyProviderParams:()=>y,PrivateKey:()=>o._q,ProgramManager:()=>d,ProgramManagerBase:()=>o.L,initThreadPool:()=>o.CK,verifyFunctionExecution:()=>o.hz});var o=r(9933),i=e([o]);o=(i.then?(await i)():i)[0];async function a(e,t){const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not get URL "+e);return r}async function s(e,t){t.method="POST";const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not post URL "+e);return r}class f{host;headers;account;constructor(e,t){this.host=e+"/testnet",t&&t.headers?this.headers=t.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const t=await a(this.host+e,{headers:this.headers});return await t.json()}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,t,r,n,i,a){if(a=a||[],e<0)throw new Error("Start height must be greater than or equal to 0");const s=new Array;let c,u,l,h,f=0,y=BigInt(0);if(void 0===r){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");l=this.account._privateKey}else try{l=r instanceof o._q?r:o._q.from_string(r)}catch(e){throw new Error("Error parsing private key provided.")}const p=l.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");h=e}catch(e){throw new Error("Error fetching latest block height.")}if(u="number"==typeof t&&t<=h?t:h,e>u)throw new Error("Start height must be less than or equal to end height.");for(;u>e;){c=u-50,c=BigInt(i))))return s;if(void 0!==n&&n.length>0){let e=0;if(t.microcredits()>n[e]){if(e+=1,s.push(t),"number"==typeof i&&(y+=t.microcredits(),y>=BigInt(i)))return s;if(s.length>=n.length)return s}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+c.toString()+"-"+u.toString()),console.warn("Error: ",e),f+=1,f>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),s}}return s}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,t){try{return await this.fetchData("/blocks?start="+e+"&end="+t)}catch(r){throw new Error("Error fetching blocks between "+e+" and "+t+".")}}async getDeploymentTransactionIDForProgram(e){e instanceof o.$r&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const t=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(t)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return await this.fetchData("/latest/height")}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return o.$r.fromString(e)}catch(t){try{return o.$r.fromString(await this.getProgram(e))}catch(t){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const t={},r=(e instanceof o.$r?e:await this.getProgramObject(e)).getImports();for(let e=0;e0&&!g)try{g=await this.networkClient.getProgramImports(t)}catch(e){throw h(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await o.L.buildExecutionTransaction(w,d,r,a,n,f,this.host,g,y,p,m,b,l)}async execute(e){const t=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(t)}async run(e,t,r,n,i,a,s,c,u,l){let h=u;if(void 0===u&&void 0!==this.account&&(h=this.account.privateKey()),void 0===h)throw"No private key provided and no private key set in the ProgramManager";if(!s||!c)try{[s,c]=await this.keyProvider.functionKeys(a)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",s),console.log("Verifying key: ",c),o.L.executeFunctionOffline(h,e,t,r,n,!1,i,s,c,this.host,l)}async join(e,t,r,n,i,a,s,c){let u,l,f=s;if(void 0===s&&void 0!==this.account&&(f=this.account.privateKey()),void 0===f)throw"No private key provided and no private key set in the ProgramManager";try{u=n?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),l=await this.keyProvider.joinKeys()}catch(e){throw h(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[y,p]=u,[d,g]=l;try{a=n?await this.getCreditsRecord(r,[],a,i):void 0}catch(e){throw h(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof o.PD?e:o.PD.fromString(e),t=t instanceof o.PD?t:o.PD.fromString(t)}catch(e){throw h("Records provided are not valid. Please ensure they are valid plaintext records.")}const v=await o.L.buildJoinTransaction(f,e,t,r,a,this.host,d,g,y,p,c);return await this.networkClient.submitTransaction(v)}async split(e,t,r,n){let i,a=r;if(void 0===a&&void 0!==this.account&&(a=this.account.privateKey()),void 0===a)throw"No private key provided and no private key set in the ProgramManager";try{i=await this.keyProvider.splitKeys()}catch(e){throw h(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[s,c]=i;try{t=t instanceof o.PD?t:o.PD.fromString(t)}catch(e){throw h("Record provided is not valid. Please ensure it is a valid plaintext record.")}const u=await o.L.buildSplitTransaction(a,e,t,this.host,s,c,n);return await this.networkClient.submitTransaction(u)}async synthesizeKeys(e,t,r,n){let i,a=n;void 0===a&&(a=void 0!==this.account?this.account.privateKey():new o._q);try{i=await this.networkClient.getProgramImports(e);const n=await o.L.synthesizeKeyPair(a,e,t,r,i);return[n.provingKey(),n.verifyingKey()]}catch(e){throw h(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,t,r,n,i,a,s,l,f,y){r=u(r);let p,d,g=f;if(void 0===g&&void 0!==this.account&&(g=this.account.privateKey()),void 0===g)throw"No private key provided and no private key set in the ProgramManager";try{p=i?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),d=await this.keyProvider.transferKeys(r)}catch(e){throw h(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[v,w]=p,[m,b]=d;try{const e=[];c(r)?(s=await this.getCreditsRecord(n,[],s,a),e.push(s.nonce())):s=void 0,l=i?await this.getCreditsRecord(n,e,l,a):void 0}catch(e){throw h(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await o.L.buildTransferTransaction(g,e,t,r,s,n,l,this.host,m,b,v,w,y)}async buildTransferPublicTransaction(e,t,r,n,o){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,o)}async buildTransferPublicAsSignerTransaction(e,t,r,n,o){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,o)}async transfer(e,t,r,n,o,i,a,s,c,u){const l=await this.buildTransferTransaction(e,t,r,n,o,i,a,s,c,u);return await this.networkClient.submitTransaction(l)}async buildBondPublicTransaction(e,t,r,n,o={}){const i=Math.trunc(1e6*n),{programName:a="credits.aleo",functionName:s="bond_public",fee:c=o.fee||.86,privateFee:u=!1,inputs:l=[e,t,r,`${i.toString()}u64`],keySearchParams:h=new y({proverUri:v.bond_public.prover,verifierUri:v.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:f=this.creditsProgram(),...p}=o,d={programName:a,functionName:s,fee:c,privateFee:u,inputs:l,keySearchParams:h,...p};return await this.buildExecutionTransaction(d)}async bondPublic(e,t,r,n,o={}){const i=await this.buildBondPublicTransaction(e,t,r,n,o);return await this.networkClient.submitTransaction(i)}async buildBondValidatorTransaction(e,t,r,n,o={}){const i=Math.trunc(1e6*r),a=Math.trunc(n),{programName:s="credits.aleo",functionName:c="bond_validator",fee:u=o.fee||.86,privateFee:l=!1,inputs:h=[e,t,`${i.toString()}u64`,`${a.toString()}u8`],keySearchParams:f=new y({proverUri:v.bond_validator.prover,verifierUri:v.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:p=this.creditsProgram(),...d}=o,g={programName:s,functionName:c,fee:u,privateFee:l,inputs:h,keySearchParams:f,...d};return await this.buildExecutionTransaction(g)}async bondValidator(e,t,r,n,o={}){const i=await this.buildBondValidatorTransaction(e,t,r,n,o);return await this.networkClient.submitTransaction(i)}async buildUnbondPublicTransaction(e,t,r={}){const n=Math.trunc(1e6*t),{programName:o="credits.aleo",functionName:i="unbond_public",fee:a=r.fee||1.3,privateFee:s=!1,inputs:c=[e,`${n.toString()}u64`],keySearchParams:u=new y({proverUri:v.unbond_public.prover,verifierUri:v.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:l=this.creditsProgram(),...h}=r,f={programName:o,functionName:i,fee:a,privateFee:s,inputs:c,keySearchParams:u,...h};return this.buildExecutionTransaction(f)}async unbondPublic(e,t,r={}){const n=await this.buildUnbondPublicTransaction(e,t,r);return await this.networkClient.submitTransaction(n)}async buildClaimUnbondPublicTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="claim_unbond_public",fee:o=t.fee||2,privateFee:i=!1,inputs:a=[e],keySearchParams:s=new y({proverUri:v.claim_unbond_public.prover,verifierUri:v.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:c=this.creditsProgram(),...u}=t,l={programName:r,functionName:n,fee:o,privateFee:i,inputs:a,keySearchParams:s,...u};return await this.buildExecutionTransaction(l)}async claimUnbondPublic(e,t={}){const r=await this.buildClaimUnbondPublicTransaction(e,t);return await this.networkClient.submitTransaction(r)}async buildSetValidatorStateTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="set_validator_state",fee:o=1,privateFee:i=!1,inputs:a=[e.toString()],keySearchParams:s=new y({proverUri:v.set_validator_state.prover,verifierUri:v.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...c}=t,u={programName:r,functionName:n,fee:o,privateFee:i,inputs:a,keySearchParams:s,...c};return await this.execute(u)}async setValidatorState(e,t={}){const r=await this.buildSetValidatorStateTransaction(e,t);return this.networkClient.submitTransaction(r)}verifyExecution(e){try{const t=e.getExecution(),r=e.getFunctionId(),n=e.getProgram(),i=e.getVerifyingKey();return(0,o.hz)(t,i,n,r)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return o.$r.fromString(e)}creditsProgram(){return o.$r.getCreditsProgram()}verifyProgram(e){try{return o.$r.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,t,r,n){try{return r instanceof o.PD?r:o.PD.fromString(r)}catch(r){try{const r=this.recordProvider;return await r.findCreditsRecord(e,!0,t,n)}catch(e){throw h(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function c(e){return w.has(e)}function u(e){return m.has(e)?e:h(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const g=o.SF.baseUrl();function l(e){const t=o.XV[e.verifyingKey];if(!t)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:t}}const v={bond_public:l(o.SF.bond_public()),bond_validator:l(o.SF.bond_validator()),claim_unbond_public:l(o.SF.claim_unbond_public()),fee_private:l(o.SF.fee_private()),fee_public:l(o.SF.fee_public()),inclusion:l(o.SF.inclusion()),join:l(o.SF.join()),set_validator_state:l(o.SF.set_validator_state()),split:l(o.SF.split()),transfer_private:l(o.SF.transfer_private()),transfer_private_to_public:l(o.SF.transfer_private_to_public()),transfer_public:l(o.SF.transfer_public()),transfer_public_as_signer:l(o.SF.transfer_public_as_signer()),transfer_public_to_private:l(o.SF.transfer_public_to_private()),unbond_public:l(o.SF.unbond_public()),getKey:function(e){return this.hasOwnProperty(e)?this[e]:new Error(`Key "${e}" not found.`)}},w=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),m=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),b=new Set(["private","transfer_private","transferPrivate"]),_=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),P=new Set(["public","transfer_public","transferPublic"]),E=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),k=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function h(e){throw console.error(e),e}n()}catch(K){n(K)}}))},5383:(e,t,r)=>{r.a(e,(async(e,t)=>{try{var n=r(5052),o=e([n]);function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function a(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function s(e,t){if(e){if("string"==typeof e)return c(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?c(e,t):void 0}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=0;--i){var a=this.tryEntries[i],s=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var c=n.call(a,"catchLoc"),u=n.call(a,"finallyLoc");if(c&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),N(r),w}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;N(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:F(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),w}},t}function f(e,t,r,n,o,i,a){try{var s=e[i](a),c=s.value}catch(e){return void r(e)}s.done?t(c):Promise.resolve(c).then(n,o)}function y(e){return function(){var t=this,r=arguments;return new Promise((function(n,o){var i=e.apply(t,r);function a(e){f(i,n,o,a,s,"next",e)}function s(e){f(i,n,o,a,s,"throw",e)}a(void 0)}))}}n=(o.then?(await o)():o)[0],await n.initThreadPool();var p="https://api.explorer.aleo.org/v1",d=new n.AleoKeyProvider,g=new n.ProgramManager(p,d,void 0);d.useCache(!0),self.postMessage({type:"ALEO_WORKER_READY"});var v=null;self.addEventListener("message",(function(e){if("ALEO_EXECUTE_PROGRAM_LOCAL"===e.data.type){var t=e.data,r=t.localProgram,o=t.aleoFunction,i=t.inputs,c=t.privateKey;console.log("Web worker: Executing function locally...");var f=performance.now();y(h().mark((function e(){var t,a,s,u,l,y,p,w,m,b;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(e.prev=0,t=n.PrivateKey.from_string(c),a=g.createProgramFromSource(r),s=a.id(),a.hasFunction(o)){e.next=6;break}throw"Program ".concat(s," does not contain function ").concat(o);case 6:if(u="".concat(s,":").concat(o),l=g.networkClient.getProgramImports(r),v===r){e.next=14;break}return e.next=11,g.synthesizeKeys(r,o,i,t);case 11:y=e.sent,g.keyProvider.cacheKeys(u,y),v=r;case 14:return p=new n.AleoKeyProviderParams({cacheKey:u}),e.next=17,g.run(r,o,i,!1,l,p,void 0,void 0,t,void 0);case 17:w=e.sent,console.log("Web worker: Local execution completed in ".concat(performance.now()-f," ms")),m=w.getOutputs(),(b=w.getExecution())?(n.verifyFunctionExecution(b,d.getKeys(u)[1],a,"hello"),b=b.toString(),console.log("Execution verified successfully: "+b)):b="",console.log("Function execution response: ".concat(m)),self.postMessage({type:"OFFLINE_EXECUTION_COMPLETED",outputs:{outputs:m,execution:b}}),e.next=30;break;case 26:e.prev=26,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 30:case"end":return e.stop()}}),e,null,[[0,26]])})))()}else if("ALEO_EXECUTE_PROGRAM_ON_CHAIN"===e.data.type){var w=e.data,m=w.remoteProgram,b=w.aleoFunction,_=w.inputs,P=w.privateKey,E=w.fee,k=w.privateFee,K=w.feeRecord,T=w.url;console.log("Web worker: Creating execution...");var S=performance.now();y(h().mark((function e(){var t,r,o,i,a,s,c;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=n.PrivateKey.from_string(P),e.next=4,g.networkClient.getProgramObject(m);case 4:if(r=e.sent,o=r.id(),r.hasFunction(b)){e.next=8;break}throw"Program ".concat(o," does not contain function ").concat(b);case 8:if(i="".concat(o,":").concat(b),g.keyProvider.containsKeys(i)){e.next=15;break}return console.log("Web worker: Synthesizing proving & verifying keys for: '".concat(o,":").concat(b,"'")),e.next=13,g.synthesizeKeys(m,b,_,t);case 13:a=e.sent,g.keyProvider.cacheKeys(i,a);case 15:return s=new n.AleoKeyProviderParams({cacheKey:i}),"string"==typeof T&&g.setHost(T),e.next=19,g.execute({programName:o,functionName:b,fee:E,privateFee:k,inputs:_,keySearchParams:s,feeRecord:K,privateKey:t});case 19:c=e.sent,console.log("Web worker: On-chain execution transaction created in ".concat(performance.now()-S," ms")),self.postMessage({type:"EXECUTION_TRANSACTION_COMPLETED",executeTransaction:c}),e.next=28;break;case 24:e.prev=24,e.t0=e.catch(0),console.error("Error creating execution transaction: ".concat(e.t0)),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 28:return e.prev=28,g.setHost(p),e.finish(28);case 31:case"end":return e.stop()}}),e,null,[[0,24,28,31]])})))()}else if("ALEO_ESTIMATE_EXECUTION_FEE"===e.data.type){var x=e.data,O=x.remoteProgram,C=x.privateKey,N=x.aleoFunction,R=x.inputs,F=x.url;console.log("Web worker: Estimating execution fee...");var L=performance.now();y(h().mark((function e(){var t,r,o,i,c,f,y,p,d,v,w;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=n.PrivateKey.from_string(C),e.next=4,g.networkClient.getProgramObject(O);case 4:if(r=e.sent,o=r.id(),r.getFunctions().includes(N)){e.next=8;break}throw"Program ".concat(o," does not contain function ").concat(N);case 8:return i="".concat(o,":").concat(N),e.next=11,g.networkClient.getProgramImports(O);case 11:if(c=e.sent,g.keyProvider.containsKeys(i)){e.next=18;break}return console.log("Web worker: Synthesizing proving & verifying keys for: '".concat(o,":").concat(N,"'")),e.next=16,g.synthesizeKeys(r.toString(),N,R,t);case 16:f=e.sent,g.keyProvider.cacheKeys(i,f);case 18:return y=g.keyProvider.getKeys(i),m=2,p=l(h=y)||u(h,m)||s(h,m)||a(),d=p[0],v=p[1],e.next=21,n.ProgramManagerBase.estimateExecutionFee(t,O,N,R,F,c,d,v,void 0);case 21:w=e.sent,console.log("Web worker: Execution fee estimated in ".concat(performance.now()-L," ms")),console.log("Execution Fee Estimation: ".concat(w," microcredits")),self.postMessage({type:"EXECUTION_FEE_ESTIMATION_COMPLETED",executionFee:Number(w)/1e6+.01}),e.next=31;break;case 27:e.prev=27,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 31:case"end":return e.stop()}var h,m}),e,null,[[0,27]])})))()}else if("ALEO_ESTIMATE_DEPLOYMENT_FEE"===e.data.type){var A=e.data,M=A.program;A.url;console.log("Web worker: Estimating deployment fee...");var I=performance.now();y(h().mark((function e(){var t,r;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,g.networkClient.getProgramImports(M);case 3:return t=e.sent,console.log("Estimating deployment fee.."),e.next=7,n.ProgramManagerBase.estimateDeploymentFee(M,t);case 7:r=e.sent,console.log("Web worker: Deployment fee estimation completed in ".concat(performance.now()-I," ms")),console.log("Deployment Fee Estimation: ".concat(r," microcredits")),self.postMessage({type:"DEPLOYMENT_FEE_ESTIMATION_COMPLETED",deploymentFee:Number(r)/1e6+.01}),e.next=17;break;case 13:e.prev=13,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 17:case"end":return e.stop()}}),e,null,[[0,13]])})))()}else if("ALEO_TRANSFER"===e.data.type){var D=e.data,$=D.privateKey,U=D.amountCredits,B=D.recipient,j=D.transfer_type,W=D.amountRecord,V=D.fee,z=D.privateFee,H=D.feeRecord,X=D.url;console.log("Web worker: Creating transfer of type ".concat(j,"..."));var G=performance.now();y(h().mark((function e(){var t;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof X&&g.setHost(X),e.next=4,g.transfer(U,B,j,V,z,void 0,W,H,n.PrivateKey.from_string($),void 0);case 4:t=e.sent,console.log("Web worker: Transfer transaction ".concat(t," created in ").concat(performance.now()-G," ms")),self.postMessage({type:"TRANSFER_TRANSACTION_COMPLETED",transferTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,g.setHost(p),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}else if("ALEO_DEPLOY"===e.data.type){var Y=e.data,q=Y.program,J=Y.privateKey,Q=Y.fee,Z=Y.privateFee,ee=Y.feeRecord,te=Y.url;console.log("Web worker: Creating deployment...");var re=performance.now();y(h().mark((function e(){var t,r,o;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof te&&g.setHost(te),t=g.createProgramFromSource(q),r=!1,e.prev=4,e.next=7,g.networkClient.getProgram(t.id());case 7:r=!0,e.next=13;break;case 10:e.prev=10,e.t0=e.catch(4),console.log("Program not found on the Aleo Network - proceeding with deployment...");case 13:if(!r){e.next=15;break}throw"Program ".concat(t.id()," already exists on the network");case 15:return console.log("fee is: ",Q),e.next=18,g.deploy(q,Q,Z,void 0,ee,n.PrivateKey.from_string(J));case 18:o=e.sent,console.log("Web worker: Deployment transaction ".concat(o," created in ").concat(performance.now()-re," ms")),self.postMessage({type:"DEPLOY_TRANSACTION_COMPLETED",deployTransaction:o}),e.next=27;break;case 23:e.prev=23,e.t1=e.catch(0),console.log(e.t1),self.postMessage({type:"ERROR",errorMessage:e.t1.toString()});case 27:return e.prev=27,g.setHost(p),e.finish(27);case 30:case"end":return e.stop()}}),e,null,[[0,23,27,30],[4,10]])})))()}else if("ALEO_SPLIT"===e.data.type){var ne=e.data,oe=ne.splitAmount,ie=ne.record,ae=ne.privateKey,se=ne.url;console.log("Web worker: Creating split...");var ce=performance.now();y(h().mark((function e(){var t;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof se&&g.setHost(se),e.next=4,g.split(oe,ie,n.PrivateKey.from_string(ae),void 0);case 4:t=e.sent,console.log("Web worker: Split transaction ".concat(t," created in ").concat(performance.now()-ce," ms")),self.postMessage({type:"SPLIT_TRANSACTION_COMPLETED",splitTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,g.setHost(p),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}else if("ALEO_JOIN"===e.data.type){var ue=e.data,le=ue.recordOne,he=ue.recordTwo,fe=ue.fee,ye=ue.privateFee,pe=ue.feeRecord,de=ue.privateKey,ge=ue.url;console.log("Web worker: Creating join...");var ve=performance.now();y(h().mark((function e(){var t;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof ge&&g.setHost(ge),e.next=4,g.join(le,he,fe,ye,void 0,pe,n.PrivateKey.from_string(de),void 0);case 4:t=e.sent,console.log("Web worker: Join transaction ".concat(t," created in ").concat(performance.now()-ve," ms")),self.postMessage({type:"JOIN_TRANSACTION_COMPLETED",joinTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,g.setHost(p),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}})),t()}catch(w){t(w)}}),1)}}]); -//# sourceMappingURL=383.bundle.js.map \ No newline at end of file diff --git a/383.bundle.js.LICENSE.txt b/383.bundle.js.LICENSE.txt deleted file mode 100644 index ae386fb79..000000000 --- a/383.bundle.js.LICENSE.txt +++ /dev/null @@ -1 +0,0 @@ -/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ diff --git a/383.bundle.js.map b/383.bundle.js.map deleted file mode 100644 index 2c92204db..000000000 --- a/383.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"383.bundle.js","mappings":";iWAAOA,eAAeC,EAAIC,EAAmBC,GACzC,MAAMC,QAAiBC,MAAMH,EAAKC,GAElC,IAAKC,EAASE,GACV,MAAM,IAAIC,MAAMH,EAASI,OAAS,sBAAwBN,GAG9D,OAAOE,CACX,CAGOJ,eAAeS,EAAKP,EAAmBC,GAC1CA,EAAQO,OAAS,OAEjB,MAAMN,QAAiBC,MAAMH,EAAKC,GAElC,IAAKC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6BAAA4E,EAAAhF,OAAA,GAAA+E,EAAA,uBA/B5CnE,EAkCJ,CACJ","sources":["webpack://aleo-website/../src/utils.ts","webpack://aleo-website/../src/network-client.ts","webpack://aleo-website/../src/function-key-provider.ts","webpack://aleo-website/../src/program-manager.ts","webpack://aleo-website/../src/index.ts","webpack://aleo-website/./src/workers/worker.js"],"sourcesContent":["export async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./index\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/testnet\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/testnet\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n return await response.json();\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise | Error> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n if (!(blocks instanceof Error)) {\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = \"Error fetching blocks between \" + start + \" and \" + end + \".\"\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return await this.fetchData(\"/latest/height\");\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error) {\n throw logAndThrow(\"Error fetching program imports: \" + error)\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error) {\n throw new Error(\"Error fetching program imports with error: \" + error);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise | Error> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise | Error> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string | Error} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n return await response.json();\n\n } catch (error) {\n throw new Error(`Error posting transaction. Aleo network response: ${(error as Error).message}`);\n }\n } catch (error) {\n throw new Error(`Error posting transaction: No response received: ${(error as Error).message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./index\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error) {\n throw new Error(\"Error fetching data.\" + error);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair | Error} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair | Error {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n return new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n if (!(key instanceof Error)) {\n return this.fetchCreditsKeys(key);\n }\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error) {\n throw new Error(`Error: fetching credits.aleo keys: ${error}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner) {\n return new Error(\"Invalid verifying key. Error: \" + inner);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./index\";\nimport {Execution} from \"@provablehq/wasm/dist/crates/aleo_wasm\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.aleo.org/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n \n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string | Error} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e) {\n throw logAndThrow(`Error validating program: ${e}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e) {\n throw logAndThrow(`Error finding ${programName}. Network response: '${e}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e) {\n throw logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e) {\n throw logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e) {\n throw logAndThrow(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program | Error} The program object\n */\n createProgramFromSource(program: string): Program | Error {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string | Error {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import {VerifyingKey, Metadata} from \"@provablehq/wasm\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key | Error {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n return new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): Error {\n console.error(message);\n throw message;\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n","import * as aleo from \"@provablehq/sdk\";\n\nawait aleo.initThreadPool();\n\nconst defaultHost = \"https://api.explorer.aleo.org/v1\";\nconst keyProvider = new aleo.AleoKeyProvider();\nconst programManager = new aleo.ProgramManager(defaultHost, keyProvider, undefined);\nkeyProvider.useCache(true);\n\nself.postMessage({\n type: \"ALEO_WORKER_READY\",\n});\n\nlet lastLocalProgram = null;\nself.addEventListener(\"message\", (ev) => {\n if (ev.data.type === \"ALEO_EXECUTE_PROGRAM_LOCAL\") {\n const { localProgram, aleoFunction, inputs, privateKey } = ev.data;\n\n console.log(\"Web worker: Executing function locally...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey);\n // Ensure the program is valid and that it contains the function specified\n const program = programManager.createProgramFromSource(localProgram);\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw `Program ${program_id} does not contain function ${aleoFunction}`;\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n\n // Get the program imports\n const imports = programManager.networkClient.getProgramImports(localProgram);\n\n // Get the proving and verifying keys for the function\n if (lastLocalProgram !== localProgram) {\n const keys = await programManager.synthesizeKeys(localProgram, aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n lastLocalProgram = localProgram;\n }\n\n // Pass the cache key to the execute function\n const keyParams = new aleo.AleoKeyProviderParams({\"cacheKey\": cacheKey});\n\n // Execute the function locally\n let response = await programManager.run(\n localProgram,\n aleoFunction,\n inputs,\n false,\n imports,\n keyParams,\n undefined,\n undefined,\n privateKeyObject,\n undefined\n );\n\n // Return the outputs to the main thread\n console.log(`Web worker: Local execution completed in ${performance.now() - startTime} ms`);\n const outputs = response.getOutputs();\n let execution = response.getExecution();\n if (execution) {\n aleo.verifyFunctionExecution(execution, keyProvider.getKeys(cacheKey)[1], program, \"hello\");\n execution = execution.toString();\n console.log(\"Execution verified successfully: \" + execution);\n } else {\n execution = \"\";\n }\n\n console.log(`Function execution response: ${outputs}`);\n self.postMessage({\n type: \"OFFLINE_EXECUTION_COMPLETED\",\n outputs: {outputs: outputs, execution: execution}\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_EXECUTE_PROGRAM_ON_CHAIN\") {\n const {\n remoteProgram,\n aleoFunction,\n inputs,\n privateKey,\n fee,\n privateFee,\n feeRecord,\n url,\n } = ev.data;\n\n console.log(\"Web worker: Creating execution...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey)\n // Ensure the program is valid and that it contains the function specified\n const program = await programManager.networkClient.getProgramObject(remoteProgram);\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw `Program ${program_id} does not contain function ${aleoFunction}`;\n }\n\n // Get the proving and verifying keys for the function\n const cacheKey = `${program_id}:${aleoFunction}`;\n if (!programManager.keyProvider.containsKeys(cacheKey)) {\n console.log(`Web worker: Synthesizing proving & verifying keys for: '${program_id}:${aleoFunction}'`);\n const keys = await programManager.synthesizeKeys(remoteProgram, aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n }\n\n // Pass the cache key to the execute function\n const keyParams = new aleo.AleoKeyProviderParams({\"cacheKey\": cacheKey})\n\n // Set the host to the provided URL if provided\n if (typeof url === \"string\") { programManager.setHost(url); }\n const transaction = await programManager.execute({\n programName: program_id,\n functionName: aleoFunction,\n fee: fee,\n privateFee: privateFee,\n inputs: inputs,\n keySearchParams: keyParams,\n feeRecord: feeRecord,\n privateKey: privateKeyObject\n });\n\n // Return the transaction id to the main thread\n console.log(`Web worker: On-chain execution transaction created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"EXECUTION_TRANSACTION_COMPLETED\",\n executeTransaction: transaction,\n });\n } catch (error) {\n console.error(`Error creating execution transaction: ${error}`);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_ESTIMATE_EXECUTION_FEE\") {\n const { remoteProgram, privateKey, aleoFunction, inputs, url } =\n ev.data;\n\n console.log(\"Web worker: Estimating execution fee...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey);\n // Ensure the program is valid and that it contains the function specified\n const program = await programManager.networkClient.getProgramObject(remoteProgram);\n const program_id = program.id();\n if (!program.getFunctions().includes(aleoFunction)) {\n throw `Program ${program_id} does not contain function ${aleoFunction}`;\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n const imports = await programManager.networkClient.getProgramImports(remoteProgram);\n\n // Get the proving and verifying keys for the function\n if (!programManager.keyProvider.containsKeys(cacheKey)) {\n console.log(`Web worker: Synthesizing proving & verifying keys for: '${program_id}:${aleoFunction}'`);\n const keys = await programManager.synthesizeKeys(program.toString(), aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n }\n\n // Estimate the execution fee\n const [provingKey, verifyingKey] = programManager.keyProvider.getKeys(cacheKey);\n let executeFee = await aleo.ProgramManagerBase.estimateExecutionFee(\n privateKeyObject,\n remoteProgram,\n aleoFunction,\n inputs,\n url,\n imports,\n provingKey,\n verifyingKey,\n undefined\n );\n\n // Return the execution fee estimate to the main thread\n console.log(`Web worker: Execution fee estimated in ${performance.now() - startTime} ms`);\n console.log(`Execution Fee Estimation: ${executeFee} microcredits`);\n self.postMessage({\n type: \"EXECUTION_FEE_ESTIMATION_COMPLETED\",\n executionFee: Number(executeFee) / 1000000 + 0.01,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_ESTIMATE_DEPLOYMENT_FEE\") {\n const { program, url } = ev.data;\n\n console.log(\"Web worker: Estimating deployment fee...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n const imports = await programManager.networkClient.getProgramImports(program);\n console.log(\"Estimating deployment fee..\");\n let deploymentFee =\n await aleo.ProgramManagerBase.estimateDeploymentFee(\n program,\n imports,\n );\n\n // Return the deployment fee estimate to the main thread\n console.log(`Web worker: Deployment fee estimation completed in ${performance.now() - startTime} ms`);\n console.log(`Deployment Fee Estimation: ${deploymentFee} microcredits`);\n self.postMessage({\n type: \"DEPLOYMENT_FEE_ESTIMATION_COMPLETED\",\n deploymentFee: Number(deploymentFee) / 1000000 + 0.01,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_TRANSFER\") {\n const {\n privateKey,\n amountCredits,\n recipient,\n transfer_type,\n amountRecord,\n fee,\n privateFee,\n feeRecord,\n url,\n } = ev.data;\n\n console.log(\n `Web worker: Creating transfer of type ${transfer_type}...`,\n );\n let startTime = performance.now();\n\n (async function () {\n try {\n // Set the host to the provided URL if provided\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the transfer transaction and submit it to the network\n const transaction = await programManager.transfer(\n amountCredits,\n recipient,\n transfer_type,\n fee,\n privateFee,\n undefined,\n amountRecord,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Transfer transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"TRANSFER_TRANSACTION_COMPLETED\",\n transferTransaction: transaction,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_DEPLOY\") {\n const { program, privateKey, fee, privateFee, feeRecord, url } = ev.data;\n\n console.log(\"Web worker: Creating deployment...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Check if the program is valid\n const programObject = programManager.createProgramFromSource(program);\n\n // Check if the program already exists on the network. If so, throw an error\n let programExists = false;\n try {\n await programManager.networkClient.getProgram(programObject.id());\n programExists = true;\n } catch (e) {\n console.log(\n `Program not found on the Aleo Network - proceeding with deployment...`,\n );\n }\n\n if (programExists) {\n throw `Program ${programObject.id()} already exists on the network`;\n }\n\n console.log(\"fee is: \", fee);\n // Create the deployment transaction and submit it to the network\n let transaction = await programManager.deploy(\n program,\n fee,\n privateFee,\n undefined,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n )\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Deployment transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"DEPLOY_TRANSACTION_COMPLETED\",\n deployTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_SPLIT\") {\n const { splitAmount, record, privateKey, url } = ev.data;\n\n console.log(\"Web worker: Creating split...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the split transaction and submit to the network\n const transaction = await programManager.split(\n splitAmount,\n record,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Split transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"SPLIT_TRANSACTION_COMPLETED\",\n splitTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_JOIN\") {\n const { recordOne, recordTwo, fee, privateFee, feeRecord, privateKey, url } =\n ev.data;\n\n console.log(\"Web worker: Creating join...\");\n\n let startTime = performance.now();\n (async function () {\n\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the join transaction and submit it to the network\n const transaction = await programManager.join(\n recordOne,\n recordTwo,\n fee,\n privateFee,\n undefined,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Join transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"JOIN_TRANSACTION_COMPLETED\",\n joinTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n }\n});\n"],"names":["async","get","url","options","response","fetch","ok","Error","status","post","method","AleoNetworkClient","host","headers","account","constructor","this","setAccount","getAccount","setHost","fetchData","json","error","findUnspentRecords","startHeight","endHeight","privateKey","amounts","maxMicrocredits","nonces","records","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","BigInt","_privateKey","PrivateKey","from_string","viewKey","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","length","transactions","j","confirmedTransaction","type","transaction","execution","transitions","k","transition","program","outputs","l","output","record","RecordCiphertext","fromString","value","isOwner","recordPlaintext","decrypt","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","console","warn","toString","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","key","logAndThrow","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","message","AleoKeyProviderParams","name","proverUri","verifierUri","cacheKey","params","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","KEY_STORE","Map","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","set","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","join","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","text","e","inner","unBondPublicKeys","ProgramManager","keyProvider","networkClient","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","undefined","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","findCreditsRecord","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set","_regeneratorRuntime","t","r","prototype","n","o","defineProperty","Symbol","a","iterator","c","asyncIterator","u","toStringTag","define","enumerable","configurable","writable","wrap","Generator","create","Context","makeInvokeMethod","tryCatch","arg","call","h","f","s","y","GeneratorFunction","GeneratorFunctionPrototype","p","d","getPrototypeOf","v","values","g","defineIteratorMethods","forEach","_invoke","AsyncIterator","invoke","_typeof","resolve","__await","then","callInvokeWithMethodAndArg","done","delegate","maybeInvokeDelegate","sent","_sent","dispatchException","abrupt","TypeError","resultName","next","nextLoc","pushTryEntry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","resetTryEntry","completion","reset","isNaN","displayName","isGeneratorFunction","mark","setPrototypeOf","__proto__","awrap","Promise","reverse","pop","prev","charAt","slice","stop","rval","handle","complete","finish","delegateYield","asyncGeneratorStep","gen","reject","_next","_throw","info","_asyncToGenerator","fn","self","args","arguments","apply","err","aleo","defaultHost","programManager","postMessage","lastLocalProgram","addEventListener","ev","_ev$data","localProgram","aleoFunction","startTime","performance","now","_callee","privateKeyObject","program_id","keyParams","_context","hasFunction","concat","getOutputs","t0","errorMessage","_ev$data2","remoteProgram","_callee2","_context2","executeTransaction","_ev$data3","_callee3","_programManager$keyPr","_programManager$keyPr2","executeFee","_context3","getFunctions","estimateExecutionFee","executionFee","Number","_ev$data4","_callee4","deploymentFee","_context4","estimateDeploymentFee","_ev$data5","amountCredits","transfer_type","_callee5","_context5","transferTransaction","_ev$data6","_callee6","programExists","_context6","deployTransaction","t1","_ev$data7","_callee7","_context7","splitTransaction","_ev$data8","_callee8","_context8","joinTransaction"],"sourceRoot":""} \ No newline at end of file diff --git a/427.bundle.js b/427.bundle.js deleted file mode 100644 index 1ce04a768..000000000 --- a/427.bundle.js +++ /dev/null @@ -1,3 +0,0 @@ -/*! For license information please see 427.bundle.js.LICENSE.txt */ -(()=>{var e,r,t,i,n,a,o={9523:(e,r,t)=>{t.a(e,(async(e,i)=>{try{t.d(r,{AleoKeyProvider:()=>l,AleoKeyProviderParams:()=>h,ProgramManager:()=>f});t(5357);var n=t(9879),a=e([n]);n=(a.then?(await a)():a)[0];function o(e){return JSON.parse(e,(function(e,r,t){return Number.isInteger(r)?BigInt(t.source):r}))}async function s(e,r){const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not get URL "+e);return t}async function c(e,r){r.method="POST";const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not post URL "+e);return t}class u{host;headers;account;constructor(e,r){this.host=e+"/testnet",r&&r.headers?this.headers=r.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const r=await s(this.host+e,{headers:this.headers});return o(await r.text())}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,r,t,i,a,o){if(o=o||[],e<0)throw new Error("Start height must be greater than or equal to 0");const s=new Array;let c,u,h,l,f=0,d=BigInt(0);if(void 0===t){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");h=this.account._privateKey}else try{h=t instanceof n.ZD?t:n.ZD.from_string(t)}catch(e){throw new Error("Error parsing private key provided.")}const y=h.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");l=e}catch(e){throw new Error("Error fetching latest block height.")}if(u="number"==typeof r&&r<=l?r:l,e>u)throw new Error("Start height must be less than or equal to end height.");for(;u>e;){c=u-50,c=BigInt(a))))return s;if(void 0!==i&&i.length>0){let e=0;if(r.microcredits()>i[e]){if(e+=1,s.push(r),"number"==typeof a&&(d+=r.microcredits(),d>=BigInt(a)))return s;if(s.length>=i.length)return s}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+c.toString()+"-"+u.toString()),console.warn("Error: ",e),f+=1,f>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),s}}return s}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,r){try{return await this.fetchData("/blocks?start="+e+"&end="+r)}catch(t){throw new Error(`Error fetching blocks between ${e} and ${r}.`)}}async getDeploymentTransactionIDForProgram(e){e instanceof n.BP&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const r=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(r)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return Number(await this.fetchData("/latest/height"))}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return n.BP.fromString(e)}catch(r){try{return n.BP.fromString(await this.getProgram(e))}catch(r){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const r={},t=(e instanceof n.BP?e:await this.getProgramObject(e)).getImports();for(let e=0;e0&&!p)try{p=await this.networkClient.getProgramImports(r)}catch(e){K(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await n.Ao.buildExecutionTransaction(v,y,t,o,i,l,this.host,p,f,d,m,w,h)}async execute(e){const r=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(r)}async run(e,r,t,i,a,o,s,c,u,h){let l=u;if(void 0===u&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";if(!s||!c)try{[s,c]=await this.keyProvider.functionKeys(o)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",s),console.log("Verifying key: ",c),n.Ao.executeFunctionOffline(l,e,r,t,i,!1,a,s,c,this.host,h)}async join(e,r,t,i,a,o,s,c){let u,h,l=s;if(void 0===s&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";try{u=i?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),h=await this.keyProvider.joinKeys()}catch(e){K(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[f,d]=u,[y,p]=h;try{o=i?await this.getCreditsRecord(t,[],o,a):void 0}catch(e){K(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof n.ZF?e:n.ZF.fromString(e),r=r instanceof n.ZF?r:n.ZF.fromString(r)}catch(e){K("Records provided are not valid. Please ensure they are valid plaintext records.")}const g=await n.Ao.buildJoinTransaction(l,e,r,t,o,this.host,y,p,f,d,c);return await this.networkClient.submitTransaction(g)}async split(e,r,t,i){let a,o=t;if(void 0===o&&void 0!==this.account&&(o=this.account.privateKey()),void 0===o)throw"No private key provided and no private key set in the ProgramManager";try{a=await this.keyProvider.splitKeys()}catch(e){K(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[s,c]=a;try{r=r instanceof n.ZF?r:n.ZF.fromString(r)}catch(e){K("Record provided is not valid. Please ensure it is a valid plaintext record.")}const u=await n.Ao.buildSplitTransaction(o,e,r,this.host,s,c,i);return await this.networkClient.submitTransaction(u)}async synthesizeKeys(e,r,t,i){let a,o=i;void 0===o&&(o=void 0!==this.account?this.account.privateKey():new n.ZD);try{a=await this.networkClient.getProgramImports(e);const i=await n.Ao.synthesizeKeyPair(o,e,r,t,a);return[i.provingKey(),i.verifyingKey()]}catch(e){K(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,r,t,i,a,o,s,c,u,h){t=y(t);let l,f,p=u;if(void 0===p&&void 0!==this.account&&(p=this.account.privateKey()),void 0===p)throw"No private key provided and no private key set in the ProgramManager";try{l=a?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),f=await this.keyProvider.transferKeys(t)}catch(e){K(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[g,v]=l,[m,w]=f;try{const e=[];d(t)?(s=await this.getCreditsRecord(i,[],s,o),e.push(s.nonce())):s=void 0,c=a?await this.getCreditsRecord(i,e,c,o):void 0}catch(e){K(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await n.Ao.buildTransferTransaction(p,e,r,t,s,i,c,this.host,m,w,g,v,h)}async buildTransferPublicTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async buildTransferPublicAsSignerTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async transfer(e,r,t,i,n,a,o,s,c,u){const h=await this.buildTransferTransaction(e,r,t,i,n,a,o,s,c,u);return await this.networkClient.submitTransaction(h)}async buildBondPublicTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*i),{programName:o="credits.aleo",functionName:s="bond_public",fee:c=n.fee||.86,privateFee:u=!1,inputs:l=[e,r,t,`${a.toString()}u64`],keySearchParams:f=new h({proverUri:v.bond_public.prover,verifierUri:v.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:d=this.creditsProgram(),...y}=n,p={programName:o,functionName:s,fee:c,privateFee:u,inputs:l,keySearchParams:f,...y};return await this.buildExecutionTransaction(p)}async bondPublic(e,r,t,i,n={}){const a=await this.buildBondPublicTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildBondValidatorTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*t),o=Math.trunc(i),{programName:s="credits.aleo",functionName:c="bond_validator",fee:u=n.fee||.86,privateFee:l=!1,inputs:f=[e,r,`${a.toString()}u64`,`${o.toString()}u8`],keySearchParams:d=new h({proverUri:v.bond_validator.prover,verifierUri:v.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:y=this.creditsProgram(),...p}=n,g={programName:s,functionName:c,fee:u,privateFee:l,inputs:f,keySearchParams:d,...p};return await this.buildExecutionTransaction(g)}async bondValidator(e,r,t,i,n={}){const a=await this.buildBondValidatorTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildUnbondPublicTransaction(e,r,t={}){const i=Math.trunc(1e6*r),{programName:n="credits.aleo",functionName:a="unbond_public",fee:o=t.fee||1.3,privateFee:s=!1,inputs:c=[e,`${i.toString()}u64`],keySearchParams:u=new h({proverUri:v.unbond_public.prover,verifierUri:v.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:l=this.creditsProgram(),...f}=t,d={programName:n,functionName:a,fee:o,privateFee:s,inputs:c,keySearchParams:u,...f};return this.buildExecutionTransaction(d)}async unbondPublic(e,r,t={}){const i=await this.buildUnbondPublicTransaction(e,r,t);return await this.networkClient.submitTransaction(i)}async buildClaimUnbondPublicTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="claim_unbond_public",fee:n=r.fee||2,privateFee:a=!1,inputs:o=[e],keySearchParams:s=new h({proverUri:v.claim_unbond_public.prover,verifierUri:v.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:c=this.creditsProgram(),...u}=r,l={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...u};return await this.buildExecutionTransaction(l)}async claimUnbondPublic(e,r={}){const t=await this.buildClaimUnbondPublicTransaction(e,r);return await this.networkClient.submitTransaction(t)}async buildSetValidatorStateTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="set_validator_state",fee:n=1,privateFee:a=!1,inputs:o=[e.toString()],keySearchParams:s=new h({proverUri:v.set_validator_state.prover,verifierUri:v.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...c}=r,u={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...c};return await this.execute(u)}async setValidatorState(e,r={}){const t=await this.buildSetValidatorStateTransaction(e,r);return this.networkClient.submitTransaction(t)}verifyExecution(e){try{const r=e.getExecution(),t=e.getFunctionId(),i=e.getProgram(),a=e.getVerifyingKey();return(0,n.Yc)(r,a,i,t)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return n.BP.fromString(e)}creditsProgram(){return n.BP.getCreditsProgram()}verifyProgram(e){try{return n.BP.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,r,t,i){try{return t instanceof n.ZF?t:n.ZF.fromString(t)}catch(t){try{const t=this.recordProvider;return await t.findCreditsRecord(e,!0,r,i)}catch(e){K(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function d(e){return m.has(e)}function y(e){return w.has(e)?e:K(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const p=n.OS.baseUrl();function g(e){const r=n.pF[e.verifyingKey];if(!r)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:r}}const v={bond_public:g(n.OS.bond_public()),bond_validator:g(n.OS.bond_validator()),claim_unbond_public:g(n.OS.claim_unbond_public()),fee_private:g(n.OS.fee_private()),fee_public:g(n.OS.fee_public()),inclusion:g(n.OS.inclusion()),join:g(n.OS.join()),set_validator_state:g(n.OS.set_validator_state()),split:g(n.OS.split()),transfer_private:g(n.OS.transfer_private()),transfer_private_to_public:g(n.OS.transfer_private_to_public()),transfer_public:g(n.OS.transfer_public()),transfer_public_as_signer:g(n.OS.transfer_public_as_signer()),transfer_public_to_private:g(n.OS.transfer_public_to_private()),unbond_public:g(n.OS.unbond_public()),getKey:function(e){if(this.hasOwnProperty(e))return this[e];throw new Error(`Key "${e}" not found.`)}},m=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),w=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),b=new Set(["private","transfer_private","transferPrivate"]),P=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),_=new Set(["public","transfer_public","transferPublic"]),k=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),E=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function K(e){throw console.error(e),new Error(e)}i()}catch(S){i(S)}}))},8229:(e,r,t)=>{t.a(e,(async(e,r)=>{try{t(5357);var i=t(9523),n=t(9720),a=t(9879),o=e([i,a]);[i,a]=o.then?(await o)():o,await(0,a.Fs)();const s="https://api.explorer.provable.com/v1",c=new i.AleoKeyProvider,u=new i.ProgramManager(s,c,void 0);c.useCache(!0);let h="";async function l(e,r,t,n,o=!1){console.log("Web worker: Executing function locally...");const s=performance.now();let l;try{l=u.createProgramFromSource(e)}catch(e){throw new Error("Error creating program from source")}const f=l.id();if(!l.hasFunction(r))throw new Error(`Program ${f} does not contain function ${r}`);const d=`${f}:${r}`;let y;try{y=await u.networkClient.getProgramImports(e)}catch(e){throw new Error("Error getting program imports")}if(h!==e){const i=await u.synthesizeKeys(e,r,t,a.ZD.from_string(n));u.keyProvider.cacheKeys(d,i),h=e}const p=new i.AleoKeyProviderParams({cacheKey:d}),g=await u.run(e,r,t,o,y,p,void 0,void 0,a.ZD.from_string(n));console.log(`Web worker: Local execution completed in ${performance.now()-s} ms`);const v=g.getOutputs(),m=g.getExecution();let w,b="";try{w=c.getKeys(d)}catch(e){throw new Error("Could not get verifying key")}const P=w[1];return m?((0,a.Yc)(m,P,l,"hello"),b=m.toString(),console.log("Execution verified successfully: "+m)):b="",console.log(`Function execution response: ${v}`),{outputs:v,execution:b}}async function f(){return(new a.ZD).to_string()}const d={run:l,getPrivateKey:f};(0,n.p)(d),r()}catch(y){r(y)}}),1)},9720:(e,r,t)=>{t.d(r,{p:()=>h});const i=Symbol("Comlink.proxy"),n=Symbol("Comlink.endpoint"),a=Symbol("Comlink.releaseProxy"),o=Symbol("Comlink.finalizer"),s=Symbol("Comlink.thrown"),c=e=>"object"==typeof e&&null!==e||"function"==typeof e,u=new Map([["proxy",{canHandle:e=>c(e)&&e[i],serialize(e){const{port1:r,port2:t}=new MessageChannel;return h(e,r),[t,[t]]},deserialize(e){return e.start(),g(e,[],r);var r}}],["throw",{canHandle:e=>c(e)&&s in e,serialize({value:e}){let r;return r=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[r,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function h(e,r=globalThis,t=["*"]){r.addEventListener("message",(function n(a){if(!a||!a.data)return;if(!function(e,r){for(const t of e){if(r===t||"*"===t)return!0;if(t instanceof RegExp&&t.test(r))return!0}return!1}(t,a.origin))return void console.warn(`Invalid origin '${a.origin}' for comlink proxy`);const{id:c,type:u,path:f}=Object.assign({path:[]},a.data),d=(a.data.argumentList||[]).map(b);let y;try{const r=f.slice(0,-1).reduce(((e,r)=>e[r]),e),t=f.reduce(((e,r)=>e[r]),e);switch(u){case"GET":y=t;break;case"SET":r[f.slice(-1)[0]]=b(a.data.value),y=!0;break;case"APPLY":y=t.apply(r,d);break;case"CONSTRUCT":y=function(e){return Object.assign(e,{[i]:!0})}(new t(...d));break;case"ENDPOINT":{const{port1:r,port2:t}=new MessageChannel;h(e,t),y=function(e,r){return m.set(e,r),e}(r,[r])}break;case"RELEASE":y=void 0;break;default:return}}catch(e){y={value:e,[s]:0}}Promise.resolve(y).catch((e=>({value:e,[s]:0}))).then((t=>{const[i,a]=w(t);r.postMessage(Object.assign(Object.assign({},i),{id:c}),a),"RELEASE"===u&&(r.removeEventListener("message",n),l(r),o in e&&"function"==typeof e[o]&&e[o]())})).catch((e=>{const[t,i]=w({value:new TypeError("Unserializable return value"),[s]:0});r.postMessage(Object.assign(Object.assign({},t),{id:c}),i)}))})),r.start&&r.start()}function l(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function f(e){if(e)throw new Error("Proxy has been released and is not useable")}function d(e){return P(e,{type:"RELEASE"}).then((()=>{l(e)}))}const y=new WeakMap,p="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const r=(y.get(e)||0)-1;y.set(e,r),0===r&&d(e)}));function g(e,r=[],t=function(){}){let i=!1;const o=new Proxy(t,{get(t,n){if(f(i),n===a)return()=>{!function(e){p&&p.unregister(e)}(o),d(e),i=!0};if("then"===n){if(0===r.length)return{then:()=>o};const t=P(e,{type:"GET",path:r.map((e=>e.toString()))}).then(b);return t.then.bind(t)}return g(e,[...r,n])},set(t,n,a){f(i);const[o,s]=w(a);return P(e,{type:"SET",path:[...r,n].map((e=>e.toString())),value:o},s).then(b)},apply(t,a,o){f(i);const s=r[r.length-1];if(s===n)return P(e,{type:"ENDPOINT"}).then(b);if("bind"===s)return g(e,r.slice(0,-1));const[c,u]=v(o);return P(e,{type:"APPLY",path:r.map((e=>e.toString())),argumentList:c},u).then(b)},construct(t,n){f(i);const[a,o]=v(n);return P(e,{type:"CONSTRUCT",path:r.map((e=>e.toString())),argumentList:a},o).then(b)}});return function(e,r){const t=(y.get(r)||0)+1;y.set(r,t),p&&p.register(e,r,e)}(o,e),o}function v(e){const r=e.map(w);return[r.map((e=>e[0])),(t=r.map((e=>e[1])),Array.prototype.concat.apply([],t))];var t}const m=new WeakMap;function w(e){for(const[r,t]of u)if(t.canHandle(e)){const[i,n]=t.serialize(e);return[{type:"HANDLER",name:r,value:i},n]}return[{type:"RAW",value:e},m.get(e)||[]]}function b(e){switch(e.type){case"HANDLER":return u.get(e.name).deserialize(e.value);case"RAW":return e.value}}function P(e,r,t){return new Promise((i=>{const n=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-");e.addEventListener("message",(function r(t){t.data&&t.data.id&&t.data.id===n&&(e.removeEventListener("message",r),i(t.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:n},r),t)}))}}},s={};function c(e){var r=s[e];if(void 0!==r)return r.exports;var t=s[e]={exports:{}};return o[e].call(t.exports,t,t.exports,c),t.exports}c.m=o,c.x=()=>{var e=c.O(void 0,[357,879],(()=>c(8229)));return e=c.O(e)},e="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",r="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",i=e=>{e&&e.d<1&&(e.d=1,e.forEach((e=>e.r--)),e.forEach((e=>e.r--?e.r++:e())))},c.a=(n,a,o)=>{var s;o&&((s=[]).d=-1);var c,u,h,l=new Set,f=n.exports,d=new Promise(((e,r)=>{h=r,u=e}));d[r]=f,d[e]=e=>(s&&e(s),l.forEach(e),d.catch((e=>{}))),n.exports=d,a((n=>{var a;c=(n=>n.map((n=>{if(null!==n&&"object"==typeof n){if(n[e])return n;if(n.then){var a=[];a.d=0,n.then((e=>{o[r]=e,i(a)}),(e=>{o[t]=e,i(a)}));var o={};return o[e]=e=>e(a),o}}var s={};return s[e]=e=>{},s[r]=n,s})))(n);var o=()=>c.map((e=>{if(e[t])throw e[t];return e[r]})),u=new Promise((r=>{(a=()=>r(o)).r=0;var t=e=>e!==s&&!l.has(e)&&(l.add(e),e&&!e.d&&(a.r++,e.push(a)));c.map((r=>r[e](t)))}));return a.r?u:o()}),(e=>(e?h(d[t]=e):u(f),i(s)))),s&&s.d<0&&(s.d=0)},n=[],c.O=(e,r,t,i)=>{if(!r){var a=1/0;for(h=0;h=i)&&Object.keys(c.O).every((e=>c.O[e](r[s])))?r.splice(s--,1):(o=!1,i0&&n[h-1][2]>i;h--)n[h]=n[h-1];n[h]=[r,t,i]},c.d=(e,r)=>{for(var t in r)c.o(r,t)&&!c.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},c.f={},c.e=e=>Promise.all(Object.keys(c.f).reduce(((r,t)=>(c.f[t](e,r),r)),[])),c.u=e=>e+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),(()=>{var e;c.g.importScripts&&(e=c.g.location+"");var r=c.g.document;if(!e&&r&&(r.currentScript&&"SCRIPT"===r.currentScript.tagName.toUpperCase()&&(e=r.currentScript.src),!e)){var t=r.getElementsByTagName("script");if(t.length)for(var i=t.length-1;i>-1&&(!e||!/^http(s?):/.test(e));)e=t[i--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=e})(),(()=>{c.b=self.location+"";var e={427:1};c.f.i=(r,t)=>{e[r]||importScripts(c.p+c.u(r))};var r=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=r.push.bind(r);r.push=r=>{var[i,n,a]=r;for(var o in n)c.o(n,o)&&(c.m[o]=n[o]);for(a&&a(c);i.length;)e[i.pop()]=1;t(r)}})(),a=c.x,c.x=()=>Promise.all([c.e(357),c.e(879)]).then(a);c.x()})(); -//# sourceMappingURL=427.bundle.js.map \ No newline at end of file diff --git a/427.bundle.js.map b/427.bundle.js.map deleted file mode 100644 index 4788e3410..000000000 --- a/427.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"427.bundle.js","mappings":";UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,uLCAE,SAAUC,EAAUC,GAUtB,OAAOC,KAAKC,MAAMF,GATlB,SAAgBG,EAAaC,EAAYC,GACrC,OAAIC,OAAOC,UAAUH,GACVI,OAAOH,EAAQI,QAGfL,IAKnB,CAGOM,eAAeC,EAAIC,EAAmBC,GACzC,MAAMC,QAAiBC,MAAMH,EAAKC,GAElC,IAAKC,EAASE,GACV,MAAM,IAAIC,MAAMH,EAASI,OAAS,sBAAwBN,GAG9D,OAAOE,CACX,CAGOJ,eAAeS,EAAKP,EAAmBC,GAC1CA,EAAQO,OAAS,OAEjB,MAAMN,QAAiBC,MAAMH,EAAKC,GAElC,IAAKC,EAASE,GACV,MAAM,IAAIC,MAAMH,EAASI,OAAS,uBAAyBN,GAG/D,OAAOE,CACX,CCJA,MAAMO,EACJC,KACAC,QACAC,QAEAC,WAAAA,CAAYH,EAAcT,GACxBa,KAAKJ,KAAOA,EAAO,WAEfT,GAAWA,EAAQU,QACrBG,KAAKH,QAAUV,EAAQU,QAGvBG,KAAKH,QAAU,CAEb,qBAAsB,UAa5BI,UAAAA,CAAWH,GACTE,KAAKF,Q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,cAAcG,MAC/BP,GAAW,CACf,IAAIQ,EAAUL,EAASM,qBAAqB,UAC5C,GAAGD,EAAQ3a,OAEV,IADA,IAAID,EAAI4a,EAAQ3a,OAAS,EAClBD,GAAK,KAAOoa,IAAc,aAAavH,KAAKuH,KAAaA,EAAYQ,EAAQ5a,KAAK2a,GAE3F,CAID,IAAKP,EAAW,MAAM,IAAI5c,MAAM,yDAChC4c,EAAYA,EAAUhY,QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpF4U,EAAoBtB,EAAI0E,YClBxBpD,EAAoB8D,EAAIC,KAAKT,SAAW,GAIxC,IAAIU,EAAkB,CACrB,IAAK,GAgBNhE,EAAoB4C,EAAE5Z,EAAI,CAAC6Z,EAASE,KAE/BiB,EAAgBnB,IAElBQ,cAAcrD,EAAoBtB,EAAIsB,EAAoBgD,EAAEH,GAE9D,EAGD,IAAIoB,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBvZ,KAAKiU,KAAKsF,GAC9DA,EAAmBvZ,KAvBCwD,IACnB,IAAK+T,EAAUkC,EAAaC,GAAWlW,EACvC,IAAI,IAAI+R,KAAYkE,EAChBnE,EAAoByC,EAAE0B,EAAalE,KACrCD,EAAoBO,EAAEN,GAAYkE,EAAYlE,IAIhD,IADGmE,GAASA,EAAQpE,GACdiC,EAAShZ,QACd+a,EAAgB/B,EAASoC,OAAS,EACnCH,EAA2BhW,EAAK,MfnB7B7I,EAAO2a,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChB3D,QAAQiG,IAAI,CAClB9C,EAAoBxN,EAAE,KACtBwN,EAAoBxN,EAAE,OACpBwK,KAAK3X,GgBJiB2a,EAAoBQ","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/../../src/utils.ts","webpack://aleo-website/../../src/network-client.ts","webpack://aleo-website/../../src/function-key-provider.ts","webpack://aleo-website/../../src/program-manager.ts","webpack://aleo-website/../../src/browser.ts","webpack://aleo-website/../../src/worker.ts","webpack://aleo-website/../node_modules/comlink/dist/esm/comlink.mjs","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(357),\n\t\t__webpack_require__.e(879)\n\t]).then(next);\n};","export function parseJSON(json: string): any {\n function revive(key: string, value: any, context: any) {\n if (Number.isInteger(value)) {\n return BigInt(context.source);\n\n } else {\n return value;\n }\n }\n\n return JSON.parse(json, revive as any);\n}\n\n\nexport async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post, parseJSON } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./browser\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/%%NETWORK%%\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/%%NETWORK%%\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = `Error fetching blocks between ${start} and ${end}.`;\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return Number(await this.fetchData(\"/latest/height\"));\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error: any) {\n logAndThrow(\"Error fetching program imports: \" + error.message);\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error: any) {\n throw new Error(\"Error fetching program imports with error: \" + error.message);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error: any) {\n throw new Error(`Error posting transaction. Aleo network response: ${error.message}`);\n }\n } catch (error: any) {\n throw new Error(`Error posting transaction: No response received: ${error.message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./browser\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error: any) {\n throw new Error(\"Error fetching data.\" + error.message);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n throw new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n return this.fetchCreditsKeys(key);\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw new Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error: any) {\n throw new Error(`Error: fetching credits.aleo keys: ${error.message}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner: any) {\n throw new Error(\"Invalid verifying key. Error: \" + inner.message);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionExecution,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./browser\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.provable.com/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n\n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e: any) {\n logAndThrow(`Error validating program: ${e.message}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e: any) {\n logAndThrow(`Error finding ${programName}. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e: any) {\n logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e: any) {\n logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e: any) {\n logAndThrow(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program} The program object\n */\n createProgramFromSource(program: string): Program {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import \"./polyfill/shared\";\nimport {VerifyingKey, Metadata} from \"@provablehq/wasm/%%NETWORK%%.js\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n throw new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): never {\n console.error(message);\n throw new Error(message);\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm/%%NETWORK%%.js\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n","import \"./polyfill/shared\";\nimport {initThreadPool, ProgramManager, PrivateKey, verifyFunctionExecution, FunctionKeyPair} from \"./browser\";\nimport { AleoKeyProvider, AleoKeyProviderParams} from \"./function-key-provider\";\nimport { expose } from \"comlink\";\n\nawait initThreadPool();\n\nconst defaultHost = \"https://api.explorer.provable.com/v1\";\nconst keyProvider = new AleoKeyProvider();\nconst programManager = new ProgramManager(\n defaultHost,\n keyProvider,\n undefined\n);\n\nkeyProvider.useCache(true);\n\nlet lastLocalProgram: string = \"\";\n\nexport interface WorkerAPI {\n run: (\n localProgram: string,\n aleoFunction: string,\n inputs: string[],\n privateKey: string\n ) => Promise<{ outputs: any; execution: string } | string>;\n\n getPrivateKey: () => Promise;\n}\nasync function run(\n localProgram: string,\n aleoFunction: string,\n inputs: string[],\n privateKey: string,\n proveExecution = false\n) {\n console.log(\"Web worker: Executing function locally...\");\n const startTime = performance.now();\n\n // Ensure the program is valid and that it contains the function specified\n let program;\n\n try {\n program = programManager.createProgramFromSource(localProgram);\n } catch (e) {\n throw new Error(\"Error creating program from source\");\n }\n\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw new Error(`Program ${program_id} does not contain function ${aleoFunction}`);\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n\n\n // Get the program imports\n let imports;\n\n try {\n imports = await programManager.networkClient.getProgramImports(\n localProgram\n );\n } catch (e) {\n throw new Error(\"Error getting program imports\");\n }\n\n // Get the proving and verifying keys for the function\n if (lastLocalProgram !== localProgram) {\n const keys = await programManager.synthesizeKeys(\n localProgram,\n aleoFunction,\n inputs,\n PrivateKey.from_string(privateKey)\n );\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n lastLocalProgram = localProgram;\n }\n\n // Pass the cache key to the execute function\n const keyParams = new AleoKeyProviderParams({\n cacheKey: cacheKey,\n });\n\n // Execute the function locally\n const response = await programManager.run(\n localProgram,\n aleoFunction,\n inputs,\n proveExecution,\n imports,\n keyParams,\n undefined,\n undefined,\n PrivateKey.from_string(privateKey),\n );\n\n // Return the outputs to the main thread\n console.log(\n `Web worker: Local execution completed in ${\n performance.now() - startTime\n } ms`\n );\n const outputs = response.getOutputs();\n const execution = response.getExecution();\n let executionString = \"\";\n\n let keys;\n\n try {\n keys = keyProvider.getKeys(cacheKey);\n } catch (e) {\n throw new Error(\"Could not get verifying key\");\n }\n\n const verifyingKey = keys[1];\n\n if (execution) {\n verifyFunctionExecution(\n execution,\n verifyingKey,\n program,\n \"hello\"\n );\n executionString = execution.toString();\n console.log(\"Execution verified successfully: \" + execution);\n } else {\n executionString = \"\";\n }\n\n console.log(`Function execution response: ${outputs}`);\n\n return { outputs: outputs, execution: executionString };\n}\n\nasync function getPrivateKey() {\n const privateKey = new PrivateKey();\n return privateKey.to_string();\n}\n\nconst workerAPI = { run, getPrivateKey };\nexpose(workerAPI);\n","/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nconst proxyMarker = Symbol(\"Comlink.proxy\");\nconst createEndpoint = Symbol(\"Comlink.endpoint\");\nconst releaseProxy = Symbol(\"Comlink.releaseProxy\");\nconst finalizer = Symbol(\"Comlink.finalizer\");\nconst throwMarker = Symbol(\"Comlink.thrown\");\nconst isObject = (val) => (typeof val === \"object\" && val !== null) || typeof val === \"function\";\n/**\n * Internal transfer handle to handle objects marked to proxy.\n */\nconst proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n};\n/**\n * Internal transfer handler to handle thrown exceptions.\n */\nconst throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n};\n/**\n * Allows customizing the serialization of certain values.\n */\nconst transferHandlers = new Map([\n [\"proxy\", proxyTransferHandler],\n [\"throw\", throwTransferHandler],\n]);\nfunction isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === \"*\") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n}\nfunction expose(obj, ep = globalThis, allowedOrigins = [\"*\"]) {\n ep.addEventListener(\"message\", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin '${ev.origin}' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case \"GET\" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case \"SET\" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case \"APPLY\" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case \"CONSTRUCT\" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case \"ENDPOINT\" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case \"RELEASE\" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === \"RELEASE\" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener(\"message\", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === \"function\") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError(\"Unserializable return value\"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n}\nfunction isMessagePort(endpoint) {\n return endpoint.constructor.name === \"MessagePort\";\n}\nfunction closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n}\nfunction wrap(ep, target) {\n return createProxy(ep, [], target);\n}\nfunction throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error(\"Proxy has been released and is not useable\");\n }\n}\nfunction releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: \"RELEASE\" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n}\nconst proxyCounter = new WeakMap();\nconst proxyFinalizers = \"FinalizationRegistry\" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\nfunction registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n}\nfunction unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n}\nfunction createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === \"then\") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: \"GET\" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: \"SET\" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: \"ENDPOINT\" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === \"bind\") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"APPLY\" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"CONSTRUCT\" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n}\nfunction myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n}\nfunction processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n}\nconst transferCache = new WeakMap();\nfunction transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n}\nfunction proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n}\nfunction windowEndpoint(w, context = globalThis, targetOrigin = \"*\") {\n return {\n postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\n addEventListener: context.addEventListener.bind(context),\n removeEventListener: context.removeEventListener.bind(context),\n };\n}\nfunction toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: \"HANDLER\" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: \"RAW\" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n}\nfunction fromWireValue(value) {\n switch (value.type) {\n case \"HANDLER\" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case \"RAW\" /* WireValueType.RAW */:\n return value.value;\n }\n}\nfunction requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener(\"message\", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener(\"message\", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n}\nfunction generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join(\"-\");\n}\n\nexport { createEndpoint, expose, finalizer, proxy, proxyMarker, releaseProxy, transfer, transferHandlers, windowEndpoint, wrap };\n//# sourceMappingURL=comlink.mjs.map\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,879], () => (__webpack_require__(8229)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t427: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","parseJSON","json","JSON","parse","key","value","context","Number","isInteger","BigInt","source","async","get","url","options","response","fetch","ok","Error","status","post","method","AleoNetworkClient","host","headers","account","constructor","this","setAccount","getAccount","setHost","fetchData","text","error","findUnspentRecords","startHeight","endHeight","privateKey","amounts","maxMicrocredits","nonces","records","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","_privateKey","PrivateKey","from_string","viewKey","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","length","transactions","j","confirmedTransaction","type","transaction","execution","transitions","k","transition","program","outputs","l","output","record","RecordCiphertext","fromString","isOwner","recordPlaintext","decrypt","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","console","warn","toString","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","logAndThrow","message","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","AleoKeyProviderParams","name","proverUri","verifierUri","cacheKey","params","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","KEY_STORE","Map","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","set","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","join","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","e","inner","unBondPublicKeys","ProgramManager","keyProvider","networkClient","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","undefined","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","findCreditsRecord","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set","initThreadPool","defaultHost","programManager","lastLocalProgram","localProgram","aleoFunction","startTime","performance","now","program_id","hasFunction","keyParams","getOutputs","executionString","getPrivateKey","to_string","workerAPI","expose","proxyMarker","Symbol","createEndpoint","releaseProxy","finalizer","throwMarker","isObject","val","transferHandlers","canHandle","serialize","obj","port1","port2","MessageChannel","deserialize","port","createProxy","target","serialized","isError","stack","ep","globalThis","allowedOrigins","addEventListener","callback","ev","origin","allowedOrigin","RegExp","test","isAllowedOrigin","path","argumentList","map","fromWireValue","returnValue","parent","slice","reduce","prop","rawValue","apply","proxy","transfers","transferCache","Promise","resolve","catch","then","wireValue","transferables","toWireValue","postMessage","removeEventListener","closeEndPoint","TypeError","endpoint","isMessagePort","close","throwIfProxyReleased","isReleased","releaseEndpoint","requestResponseMessage","proxyCounter","WeakMap","proxyFinalizers","FinalizationRegistry","newCount","isProxyReleased","Proxy","_target","unregister","unregisterProxy","r","p","bind","_thisArg","rawArgumentList","last","processArguments","construct","register","registerProxy","processed","v","arr","prototype","concat","handler","serializedValue","msg","fill","floor","random","MAX_SAFE_INTEGER","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","queue","d","forEach","fn","a","hasAwait","currentDeps","outerResolve","reject","depQueues","promise","rej","deps","dep","ret","wrapDeps","getResult","fnQueue","q","add","err","result","chunkIds","priority","notFulfilled","Infinity","fulfilled","every","splice","definition","o","defineProperty","enumerable","f","chunkId","all","promises","u","g","Function","window","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/444.bundle.js b/444.bundle.js index b43ba266a..2a18452f2 100644 --- a/444.bundle.js +++ b/444.bundle.js @@ -1,2 +1,2 @@ -(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,879,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={444:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,879,312].map(c.e,c)).then(n);c.x()})(); +(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,857,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={444:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,857,312].map(c.e,c)).then(n);c.x()})(); //# sourceMappingURL=444.bundle.js.map \ No newline at end of file diff --git a/444.bundle.js.map b/444.bundle.js.map index ff816ad12..7ec7359af 100644 --- a/444.bundle.js.map +++ b/444.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"444.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAA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AAYG,EAASC,cAAcG,MAC/BP,GAAW,CACf,IAAIQ,EAAUL,EAASM,qBAAqB,UAC5C,GAAGD,EAAQnC,OAEV,IADA,IAAID,EAAIoC,EAAQnC,OAAS,EAClBD,GAAK,KAAO4B,IAAc,aAAaU,KAAKV,KAAaA,EAAYQ,EAAQpC,KAAKmC,GAE3F,CAID,IAAKP,EAAW,MAAM,IAAIW,MAAM,yDAChCX,EAAYA,EAAUY,QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpF1F,EAAoB2F,EAAIb,C,WClBxB9E,EAAoB4F,EAAIC,KAAKb,SAAW,GAIxC,IAAIc,EAAkB,CACrB,IAAK,GAgBN9F,EAAoBgE,EAAEd,EAAI,CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,879,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,879,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t444: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"444.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAGpEK,EAAOD,OACf,CAGAJ,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAI,KAGvB,IAAIC,EAAsBV,EAAoBW,OAAER,EAAW,CAAC,IAAI,IAAI,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O4B,IAAc,aAAaU,KAAKV,KAAaA,EAAYQ,EAAQpC,KAAKmC,GAE3F,CAID,IAAKP,EAAW,MAAM,IAAIW,MAAM,yDAChCX,EAAYA,EAAUY,QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpF1F,EAAoB2F,EAAIb,C,WClBxB9E,EAAoB4F,EAAIC,KAAKb,SAAW,GAIxC,IAAIc,EAAkB,CACrB,IAAK,GAgBN9F,EAAoBgE,EAAEd,EAAI,CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,857,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,857,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t444: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/473.bundle.js b/473.bundle.js deleted file mode 100644 index 4ce8ed5a1..000000000 --- a/473.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{var r,e,t,o,a,n,i={},p={};function c(r){var e=p[r];if(void 0!==e)return e.exports;var t=p[r]={exports:{}};return i[r](t,t.exports,c),t.exports}c.m=i,c.x=()=>{var r=c.O(void 0,[933,383],(()=>c(5383)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,i)=>{var p;i&&((p=[]).d=-1);var c,s,f,l=new Set,u=a.exports,b=new Promise(((r,e)=>{f=e,s=r}));b[e]=u,b[r]=r=>(p&&r(p),l.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{i[e]=r,o(n)}),(r=>{i[t]=r,o(n)}));var i={};return i[r]=r=>r(n),i}}var p={};return p[r]=r=>{},p[e]=a,p})))(a);var i=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(i)).r=0;var t=r=>r!==p&&!l.has(r)&&(l.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:i()}),(r=>(r?f(b[t]=r):s(u),o(p)))),p&&p.d<0&&(p.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(f=0;f=o)&&Object.keys(c.O).every((r=>c.O[r](e[p])))?e.splice(p--,1):(i=!1,o0&&a[f-1][2]>o;f--)a[f]=a[f-1];a[f]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&!r;)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={473:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var i in a)c.o(a,i)&&(c.m[i]=a[i]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([c.e(933),c.e(383)]).then(n);c.x()})(); -//# sourceMappingURL=473.bundle.js.map \ No newline at end of file diff --git a/473.bundle.js.map b/473.bundle.js.map deleted file mode 100644 index 086876c7b..000000000 --- a/473.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"473.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUI,EAAQA,EAAOD,QAASJ,GAG/CK,EAAOD,OACf,CAGAJ,EAAoBO,EAAID,EAGxBN,EAAoBQ,EAAI,KAGvB,IAAIC,EAAsBT,EAAoBU,OAAEP,EAAW,CAAC,IAAI,MAAM,IAAOH,EAAoB,QAEjG,OADAS,EAAsBT,EAAoBU,EAAED,EAClB,EHjCvBhB,EAAkC,mBAAXkB,OAAwBA,OAAO,kBAAoB,qBAC1EjB,EAAmC,mBAAXiB,OAAwBA,OAAO,mBAAqB,sBAC5EhB,EAAiC,mBAAXgB,OAAwBA,OAAO,iBAAmB,oBACxEf,EAAgBgB,IAChBA,GAASA,EAAMC,EAAI,IACrBD,EAAMC,EAAI,EACVD,EAAME,SAASC,GAAQA,EAAGC,MAC1BJ,EAAME,SAASC,GAAQA,EAAGC,IAAMD,EAAGC,IAAMD,MAC1C,EAyBDf,EAAoBiB,EAAI,CAACZ,EAAQa,EAAMC,KACtC,IAAIP,EACJO,KAAcP,EAAQ,IAAIC,GAAK,GAC/B,IAEIO,EACAC,EACAC,EAJAC,EAAY,IAAIC,IAChBpB,EAAU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AAoB2D,EAAEqC,EAAa/F,KACrCD,EAAoBO,EAAEN,GAAY+F,EAAY/F,IAIhD,IADGgG,GAASA,EAAQjG,GACd6C,EAASK,QACdyC,EAAgB9C,EAASqD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BjG,EAAOE,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChBkB,QAAQuC,IAAI,CAClBjE,EAAoBkC,EAAE,KACtBlC,EAAoBkC,EAAE,OACpBF,KAAKlC,GSJiBE,EAAoBQ,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(933),\n\t\t__webpack_require__.e(383)\n\t]).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [933,383], () => (__webpack_require__(5383)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && !scriptUrl) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t473: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/495.bundle.js b/495.bundle.js deleted file mode 100644 index cca9c4d14..000000000 --- a/495.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[495],{495:(e,r,t)=>{t.a(e,(async(e,i)=>{try{t.d(r,{AleoKeyProvider:()=>u,AleoKeyProviderParams:()=>h,PrivateKey:()=>n.ZD,ProgramManager:()=>f,ProgramManagerBase:()=>n.Ao,initThreadPool:()=>n.Fs,verifyFunctionExecution:()=>n.Yc});var n=t(877),a=e([n]);n=(a.then?(await a)():a)[0];async function o(e,r){const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not get URL "+e);return t}async function s(e,r){r.method="POST";const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not post URL "+e);return t}class c{host;headers;account;constructor(e,r){this.host=e+"/testnet",r&&r.headers?this.headers=r.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const r=await o(this.host+e,{headers:this.headers});return await r.json()}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,r,t,i,a,o){if(o=o||[],e<0)throw new Error("Start height must be greater than or equal to 0");const s=new Array;let c,h,u,f,d=0,l=BigInt(0);if(void 0===t){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");u=this.account._privateKey}else try{u=t instanceof n.ZD?t:n.ZD.from_string(t)}catch(e){throw new Error("Error parsing private key provided.")}const y=u.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");f=e}catch(e){throw new Error("Error fetching latest block height.")}if(h="number"==typeof r&&r<=f?r:f,e>h)throw new Error("Start height must be less than or equal to end height.");for(;h>e;){c=h-50,c=BigInt(a))))return s;if(void 0!==i&&i.length>0){let e=0;if(r.microcredits()>i[e]){if(e+=1,s.push(r),"number"==typeof a&&(l+=r.microcredits(),l>=BigInt(a)))return s;if(s.length>=i.length)return s}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+c.toString()+"-"+h.toString()),console.warn("Error: ",e),d+=1,d>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),s}}return s}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,r){try{return await this.fetchData("/blocks?start="+e+"&end="+r)}catch(t){throw new Error("Error fetching blocks between "+e+" and "+r+".")}}async getDeploymentTransactionIDForProgram(e){e instanceof n.BP&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const r=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(r)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return await this.fetchData("/latest/height")}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return n.BP.fromString(e)}catch(r){try{return n.BP.fromString(await this.getProgram(e))}catch(r){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const r={},t=(e instanceof n.BP?e:await this.getProgramObject(e)).getImports();for(let e=0;e0&&!p)try{p=await this.networkClient.getProgramImports(r)}catch(e){throw K(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await n.Ao.buildExecutionTransaction(v,y,t,o,i,f,this.host,p,d,l,w,b,u)}async execute(e){const r=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(r)}async run(e,r,t,i,a,o,s,c,h,u){let f=h;if(void 0===h&&void 0!==this.account&&(f=this.account.privateKey()),void 0===f)throw"No private key provided and no private key set in the ProgramManager";if(!s||!c)try{[s,c]=await this.keyProvider.functionKeys(o)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",s),console.log("Verifying key: ",c),n.Ao.executeFunctionOffline(f,e,r,t,i,!1,a,s,c,this.host,u)}async join(e,r,t,i,a,o,s,c){let h,u,f=s;if(void 0===s&&void 0!==this.account&&(f=this.account.privateKey()),void 0===f)throw"No private key provided and no private key set in the ProgramManager";try{h=i?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),u=await this.keyProvider.joinKeys()}catch(e){throw K(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[d,l]=h,[y,p]=u;try{o=i?await this.getCreditsRecord(t,[],o,a):void 0}catch(e){throw K(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof n.ZF?e:n.ZF.fromString(e),r=r instanceof n.ZF?r:n.ZF.fromString(r)}catch(e){throw K("Records provided are not valid. Please ensure they are valid plaintext records.")}const g=await n.Ao.buildJoinTransaction(f,e,r,t,o,this.host,y,p,d,l,c);return await this.networkClient.submitTransaction(g)}async split(e,r,t,i){let a,o=t;if(void 0===o&&void 0!==this.account&&(o=this.account.privateKey()),void 0===o)throw"No private key provided and no private key set in the ProgramManager";try{a=await this.keyProvider.splitKeys()}catch(e){throw K(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[s,c]=a;try{r=r instanceof n.ZF?r:n.ZF.fromString(r)}catch(e){throw K("Record provided is not valid. Please ensure it is a valid plaintext record.")}const h=await n.Ao.buildSplitTransaction(o,e,r,this.host,s,c,i);return await this.networkClient.submitTransaction(h)}async synthesizeKeys(e,r,t,i){let a,o=i;void 0===o&&(o=void 0!==this.account?this.account.privateKey():new n.ZD);try{a=await this.networkClient.getProgramImports(e);const i=await n.Ao.synthesizeKeyPair(o,e,r,t,a);return[i.provingKey(),i.verifyingKey()]}catch(e){throw K(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,r,t,i,a,o,s,c,h,u){t=l(t);let f,y,p=h;if(void 0===p&&void 0!==this.account&&(p=this.account.privateKey()),void 0===p)throw"No private key provided and no private key set in the ProgramManager";try{f=a?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),y=await this.keyProvider.transferKeys(t)}catch(e){throw K(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[g,v]=f,[w,b]=y;try{const e=[];d(t)?(s=await this.getCreditsRecord(i,[],s,o),e.push(s.nonce())):s=void 0,c=a?await this.getCreditsRecord(i,e,c,o):void 0}catch(e){throw K(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await n.Ao.buildTransferTransaction(p,e,r,t,s,i,c,this.host,w,b,g,v,u)}async buildTransferPublicTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async buildTransferPublicAsSignerTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async transfer(e,r,t,i,n,a,o,s,c,h){const u=await this.buildTransferTransaction(e,r,t,i,n,a,o,s,c,h);return await this.networkClient.submitTransaction(u)}async buildBondPublicTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*i),{programName:o="credits.aleo",functionName:s="bond_public",fee:c=n.fee||.86,privateFee:u=!1,inputs:f=[e,r,t,`${a.toString()}u64`],keySearchParams:d=new h({proverUri:g.bond_public.prover,verifierUri:g.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:l=this.creditsProgram(),...y}=n,p={programName:o,functionName:s,fee:c,privateFee:u,inputs:f,keySearchParams:d,...y};return await this.buildExecutionTransaction(p)}async bondPublic(e,r,t,i,n={}){const a=await this.buildBondPublicTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildBondValidatorTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*t),o=Math.trunc(i),{programName:s="credits.aleo",functionName:c="bond_validator",fee:u=n.fee||.86,privateFee:f=!1,inputs:d=[e,r,`${a.toString()}u64`,`${o.toString()}u8`],keySearchParams:l=new h({proverUri:g.bond_validator.prover,verifierUri:g.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:y=this.creditsProgram(),...p}=n,v={programName:s,functionName:c,fee:u,privateFee:f,inputs:d,keySearchParams:l,...p};return await this.buildExecutionTransaction(v)}async bondValidator(e,r,t,i,n={}){const a=await this.buildBondValidatorTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildUnbondPublicTransaction(e,r,t={}){const i=Math.trunc(1e6*r),{programName:n="credits.aleo",functionName:a="unbond_public",fee:o=t.fee||1.3,privateFee:s=!1,inputs:c=[e,`${i.toString()}u64`],keySearchParams:u=new h({proverUri:g.unbond_public.prover,verifierUri:g.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:f=this.creditsProgram(),...d}=t,l={programName:n,functionName:a,fee:o,privateFee:s,inputs:c,keySearchParams:u,...d};return this.buildExecutionTransaction(l)}async unbondPublic(e,r,t={}){const i=await this.buildUnbondPublicTransaction(e,r,t);return await this.networkClient.submitTransaction(i)}async buildClaimUnbondPublicTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="claim_unbond_public",fee:n=r.fee||2,privateFee:a=!1,inputs:o=[e],keySearchParams:s=new h({proverUri:g.claim_unbond_public.prover,verifierUri:g.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:c=this.creditsProgram(),...u}=r,f={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...u};return await this.buildExecutionTransaction(f)}async claimUnbondPublic(e,r={}){const t=await this.buildClaimUnbondPublicTransaction(e,r);return await this.networkClient.submitTransaction(t)}async buildSetValidatorStateTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="set_validator_state",fee:n=1,privateFee:a=!1,inputs:o=[e.toString()],keySearchParams:s=new h({proverUri:g.set_validator_state.prover,verifierUri:g.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...c}=r,u={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...c};return await this.execute(u)}async setValidatorState(e,r={}){const t=await this.buildSetValidatorStateTransaction(e,r);return this.networkClient.submitTransaction(t)}verifyExecution(e){try{const r=e.getExecution(),t=e.getFunctionId(),i=e.getProgram(),a=e.getVerifyingKey();return(0,n.Yc)(r,a,i,t)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return n.BP.fromString(e)}creditsProgram(){return n.BP.getCreditsProgram()}verifyProgram(e){try{return n.BP.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,r,t,i){try{return t instanceof n.ZF?t:n.ZF.fromString(t)}catch(t){try{const t=this.recordProvider;return await t.findCreditsRecord(e,!0,r,i)}catch(e){throw K(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function d(e){return v.has(e)}function l(e){return w.has(e)?e:K(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const y=n.OS.baseUrl();function p(e){const r=n.pF[e.verifyingKey];if(!r)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:r}}const g={bond_public:p(n.OS.bond_public()),bond_validator:p(n.OS.bond_validator()),claim_unbond_public:p(n.OS.claim_unbond_public()),fee_private:p(n.OS.fee_private()),fee_public:p(n.OS.fee_public()),inclusion:p(n.OS.inclusion()),join:p(n.OS.join()),set_validator_state:p(n.OS.set_validator_state()),split:p(n.OS.split()),transfer_private:p(n.OS.transfer_private()),transfer_private_to_public:p(n.OS.transfer_private_to_public()),transfer_public:p(n.OS.transfer_public()),transfer_public_as_signer:p(n.OS.transfer_public_as_signer()),transfer_public_to_private:p(n.OS.transfer_public_to_private()),unbond_public:p(n.OS.unbond_public()),getKey:function(e){return this.hasOwnProperty(e)?this[e]:new Error(`Key "${e}" not found.`)}},v=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),w=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),b=new Set(["private","transfer_private","transferPrivate"]),m=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),_=new Set(["public","transfer_public","transferPublic"]),P=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),k=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function K(e){throw console.error(e),e}i()}catch(E){i(E)}}))}}]); -//# sourceMappingURL=495.bundle.js.map \ No newline at end of file diff --git a/495.bundle.js.map b/495.bundle.js.map deleted file mode 100644 index 0b207f63e..000000000 --- a/495.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"495.bundle.js","mappings":"gWAAOA,eAAeC,EAAIC,EAAmBC,GACzC,MAAMC,QAAiBC,MAAMH,EAAKC,GAElC,IAAKC,EAASE,GACV,MAAM,IAAIC,MAAMH,EAASI,OAAS,sBAAwBN,GAG9D,OAAOE,CACX,CAGOJ,eAAeS,EAAKP,EAAmBC,GAC1CA,EAAQO,OAAS,OAEjB,MAAMN,QAAiBC,MAAMH,EAAKC,GAElC,IAAKC,EAASE,GACV,MAAM,IAAIC,MAAMH,EAASI,OAAS,uBAAyBN,GAG/D,OAAOE,CACX,CCUA,MAAMO,EACJC,KACAC,QACAC,QAEAC,WAAAA,CAAYH,EAAcT,GACxBa,KAAKJ,KAAOA,EAAO,WAEfT,GAAWA,EAAQU,QACrBG,KAAKH,QAAUV,EAAQU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,SAAStM,EAAYgB,GAEjB,MADA1C,QAAQxD,MAAMkG,GACRA,CACV,C","sources":["webpack://aleo-website/../src/utils.ts","webpack://aleo-website/../src/network-client.ts","webpack://aleo-website/../src/function-key-provider.ts","webpack://aleo-website/../src/program-manager.ts","webpack://aleo-website/../src/index.ts"],"sourcesContent":["export async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./index\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/testnet\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/testnet\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n return await response.json();\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise | Error> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n if (!(blocks instanceof Error)) {\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = \"Error fetching blocks between \" + start + \" and \" + end + \".\"\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return await this.fetchData(\"/latest/height\");\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error) {\n throw logAndThrow(\"Error fetching program imports: \" + error)\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error) {\n throw new Error(\"Error fetching program imports with error: \" + error);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise | Error> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise | Error> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string | Error} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n return await response.json();\n\n } catch (error) {\n throw new Error(`Error posting transaction. Aleo network response: ${(error as Error).message}`);\n }\n } catch (error) {\n throw new Error(`Error posting transaction: No response received: ${(error as Error).message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./index\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error) {\n throw new Error(\"Error fetching data.\" + error);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair | Error} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair | Error {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n return new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n if (!(key instanceof Error)) {\n return this.fetchCreditsKeys(key);\n }\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error) {\n throw new Error(`Error: fetching credits.aleo keys: ${error}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner) {\n return new Error(\"Invalid verifying key. Error: \" + inner);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./index\";\nimport {Execution} from \"@provablehq/wasm/dist/crates/aleo_wasm\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.aleo.org/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n \n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string | Error} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e) {\n throw logAndThrow(`Error validating program: ${e}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e) {\n throw logAndThrow(`Error finding ${programName}. Network response: '${e}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e) {\n throw logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e) {\n throw logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e) {\n throw logAndThrow(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program | Error} The program object\n */\n createProgramFromSource(program: string): Program | Error {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string | Error {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import {VerifyingKey, Metadata} from \"@provablehq/wasm\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key | Error {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n return new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): Error {\n console.error(message);\n throw message;\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n"],"names":["async","get","url","options","response","fetch","ok","Error","status","post","method","AleoNetworkClient","host","headers","account","constructor","this","setAccount","getAccount","setHost","fetchData","json","error","findUnspentRecords","startHeight","endHeight","privateKey","amounts","maxMicrocredits","nonces","records","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","BigInt","_privateKey","PrivateKey","from_string","viewKey","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","length","transactions","j","confirmedTransaction","type","transaction","execution","transitions","k","transition","program","outputs","l","output","record","RecordCiphertext","fromString","value","isOwner","recordPlaintext","decrypt","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","console","warn","toString","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","key","logAndThrow","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","message","AleoKeyProviderParams","name","proverUri","verifierUri","cacheKey","params","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","KEY_STORE","Map","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","set","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","join","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","text","e","inner","unBondPublicKeys","ProgramManager","keyProvider","networkClient","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","undefined","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","findCreditsRecord","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set"],"sourceRoot":""} \ No newline at end of file diff --git a/210d0782d748f9305082.wasm b/49a4de3dabc57be5a0e7.wasm similarity index 57% rename from 210d0782d748f9305082.wasm rename to 49a4de3dabc57be5a0e7.wasm index 7dd626b3f..0ce642c4e 100644 Binary files a/210d0782d748f9305082.wasm and b/49a4de3dabc57be5a0e7.wasm differ diff --git a/52.bundle.js b/52.bundle.js deleted file mode 100644 index 852a3716f..000000000 --- a/52.bundle.js +++ /dev/null @@ -1,3 +0,0 @@ -/*! For license information please see 52.bundle.js.LICENSE.txt */ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[52,933],{2583:(e,t,r)=>{e.exports=r.p+"2d6a4d794221941c07b8.js"},5934:(e,t,r)=>{e.exports=r.p+"58342153fc9a001d7976.wasm"},5052:(e,t,r)=>{r.a(e,(async(e,n)=>{try{r.r(t),r.d(t,{Account:()=>f,Address:()=>i.kL,AleoKeyProvider:()=>p,AleoKeyProviderParams:()=>b,AleoNetworkClient:()=>w,BlockHeightSearch:()=>m,CREDITS_PROGRAM_KEYS:()=>T,ExecutionResponse:()=>i._U,Field:()=>i.gN,FunctionExecution:()=>i.o,KEY_STORE:()=>S,NetworkRecordProvider:()=>v,OfflineKeyProvider:()=>h,OfflineQuery:()=>i.Gd,OfflineSearchParams:()=>y,PRIVATE_TO_PUBLIC_TRANSFER:()=>F,PRIVATE_TRANSFER:()=>R,PRIVATE_TRANSFER_TYPES:()=>E,PUBLIC_TO_PRIVATE_TRANSFER:()=>A,PUBLIC_TRANSFER:()=>x,PUBLIC_TRANSFER_AS_SIGNER:()=>C,PrivateKey:()=>i._q,PrivateKeyCiphertext:()=>i.uq,Program:()=>i.$r,ProgramManager:()=>K,ProgramManagerBase:()=>i.L,ProvingKey:()=>i.zW,RecordCiphertext:()=>i.fW,RecordPlaintext:()=>i.PD,Signature:()=>i.Pc,Transaction:()=>i.YW,VALID_TRANSFER_TYPES:()=>V,VerifyingKey:()=>i.XV,ViewKey:()=>i.IO,createAleoWorker:()=>k,initThreadPool:()=>i.CK,initializeWasm:()=>u,logAndThrow:()=>l,verifyFunctionExecution:()=>i.hz});var i=r(9933),_=r(6891),a=e([i]);i=(a.then?(await a)():a)[0];class f{_privateKey;_viewKey;_address;constructor(e={}){try{this._privateKey=this.privateKeyFromParams(e)}catch(e){throw console.error("Wrong parameter",e),new Error("Wrong Parameter")}this._viewKey=i.IO.from_private_key(this._privateKey),this._address=i.kL.from_private_key(this._privateKey)}static fromCiphertext(e,t){try{e="string"==typeof e?i.uq.fromString(e):e;const r=i._q.fromPrivateKeyCiphertext(e,t);return new f({privateKey:r.to_string()})}catch(e){throw new Error("Wrong password or invalid ciphertext")}}privateKeyFromParams(e){return e.seed?i._q.from_seed_unchecked(e.seed):e.privateKey?i._q.from_string(e.privateKey):new i._q}privateKey(){return this._privateKey}viewKey(){return this._viewKey}address(){return this._address}toString(){return this.address().to_string()}encryptAccount(e){return this._privateKey.toCiphertext(e)}decryptRecord(e){return this._viewKey.decrypt(e)}decryptRecords(e){return e.map((e=>this._viewKey.decrypt(e)))}ownsRecordCiphertext(e){if("string"!=typeof e)return e.isOwner(this._viewKey);try{return i.fW.fromString(e).isOwner(this._viewKey)}catch(e){return!1}}sign(e){return this._privateKey.sign(e)}verify(e,t){return this._address.verify(e,t)}}async function o(e,t){const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not get URL "+e);return r}async function s(e,t){t.method="POST";const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not post URL "+e);return r}class w{host;headers;account;constructor(e,t){this.host=e+"/testnet",t&&t.headers?this.headers=t.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const t=await o(this.host+e,{headers:this.headers});return await t.json()}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,t,r,n,_,a){if(a=a||[],e<0)throw new Error("Start height must be greater than or equal to 0");const o=new Array;let s,c,d,g,l=0,u=BigInt(0);if(void 0===r){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");d=this.account._privateKey}else try{d=r instanceof i._q?r:i._q.from_string(r)}catch(e){throw new Error("Error parsing private key provided.")}const f=d.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");g=e}catch(e){throw new Error("Error fetching latest block height.")}if(c="number"==typeof t&&t<=g?t:g,e>c)throw new Error("Start height must be less than or equal to end height.");for(;c>e;){s=c-50,s=BigInt(_))))return o;if(void 0!==n&&n.length>0){let e=0;if(t.microcredits()>n[e]){if(e+=1,o.push(t),"number"==typeof _&&(u+=t.microcredits(),u>=BigInt(_)))return o;if(o.length>=n.length)return o}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+s.toString()+"-"+c.toString()),console.warn("Error: ",e),l+=1,l>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),o}}return o}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,t){try{return await this.fetchData("/blocks?start="+e+"&end="+t)}catch(r){throw new Error("Error fetching blocks between "+e+" and "+t+".")}}async getDeploymentTransactionIDForProgram(e){e instanceof i.$r&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const t=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(t)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return await this.fetchData("/latest/height")}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return i.$r.fromString(e)}catch(t){try{return i.$r.fromString(await this.getProgram(e))}catch(t){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const t={},r=(e instanceof i.$r?e:await this.getProgramObject(e)).getImports();for(let e=0;e{if(void 0===e)r(new Error("No search parameters provided, cannot retrieve keys"));else{const n=e.cacheKey,_=e.verifyCreditsKeys;if(this.cache.has(n)){const[e,a]=this.cache.get(n),o=i.zW.fromBytes(e),s=i.XV.fromBytes(a);if(_){this.verifyCreditsKeys(n,o,s)||r(new Error(`Cached keys do not match expected keys for ${n}`))}t([o,s])}else r(new Error("Keys not found in cache for "+n))}}))}verifyCreditsKeys(e,t,r){switch(e){case T.bond_public.locator:return t.isBondPublicProver()&&r.isBondPublicVerifier();case T.claim_unbond_public.locator:return t.isClaimUnbondPublicProver()&&r.isClaimUnbondPublicVerifier();case T.fee_private.locator:return t.isFeePrivateProver()&&r.isFeePrivateVerifier();case T.fee_public.locator:return t.isFeePublicProver()&&r.isFeePublicVerifier();case T.inclusion.locator:return t.isInclusionProver()&&r.isInclusionVerifier();case T.join.locator:return t.isJoinProver()&&r.isJoinVerifier();case T.set_validator_state.locator:return t.isSetValidatorStateProver()&&r.isSetValidatorStateVerifier();case T.split.locator:return t.isSplitProver()&&r.isSplitVerifier();case T.transfer_private.locator:return t.isTransferPrivateProver()&&r.isTransferPrivateVerifier();case T.transfer_private_to_public.locator:return t.isTransferPrivateToPublicProver()&&r.isTransferPrivateToPublicVerifier();case T.transfer_public.locator:return t.isTransferPublicProver()&&r.isTransferPublicVerifier();case T.transfer_public_to_private.locator:return t.isTransferPublicToPrivateProver()&&r.isTransferPublicToPrivateVerifier();case T.unbond_public.locator:return t.isUnbondPublicProver()&&r.isUnbondPublicVerifier();default:return!1}}feePrivateKeys(){return this.functionKeys(y.feePrivateKeyParams())}feePublicKeys(){return this.functionKeys(y.feePublicKeyParams())}joinKeys(){return this.functionKeys(y.joinKeyParams())}splitKeys(){return this.functionKeys(y.splitKeyParams())}transferKeys(e){if(R.has(e))return this.functionKeys(y.transferPrivateKeyParams());if(F.has(e))return this.functionKeys(y.transferPrivateToPublicKeyParams());if(x.has(e))return this.functionKeys(y.transferPublicKeyParams());if(C.has(e))return this.functionKeys(y.transferPublicAsSignerKeyParams());if(A.has(e))return this.functionKeys(y.transferPublicToPrivateKeyParams());throw new Error("Invalid visibility type")}async unBondPublicKeys(){return this.functionKeys(y.unbondPublicKeyParams())}insertBondPublicKeys(e){if(!e.isBondPublicProver())throw new Error("Attempted to insert invalid proving keys for bond_public");this.cache.set(T.bond_public.locator,[e.toBytes(),i.XV.bondPublicVerifier().toBytes()])}insertClaimUnbondPublicKeys(e){if(!e.isClaimUnbondPublicProver())throw new Error("Attempted to insert invalid proving keys for claim_unbond_public");this.cache.set(T.claim_unbond_public.locator,[e.toBytes(),i.XV.claimUnbondPublicVerifier().toBytes()])}insertFeePrivateKeys(e){if(!e.isFeePrivateProver())throw new Error("Attempted to insert invalid proving keys for fee_private");this.cache.set(T.fee_private.locator,[e.toBytes(),i.XV.feePrivateVerifier().toBytes()])}insertFeePublicKeys(e){if(!e.isFeePublicProver())throw new Error("Attempted to insert invalid proving keys for fee_public");this.cache.set(T.fee_public.locator,[e.toBytes(),i.XV.feePublicVerifier().toBytes()])}insertJoinKeys(e){if(!e.isJoinProver())throw new Error("Attempted to insert invalid proving keys for join");this.cache.set(T.join.locator,[e.toBytes(),i.XV.joinVerifier().toBytes()])}insertSetValidatorStateKeys(e){if(!e.isSetValidatorStateProver())throw new Error("Attempted to insert invalid proving keys for set_validator_state");this.cache.set(T.set_validator_state.locator,[e.toBytes(),i.XV.setValidatorStateVerifier().toBytes()])}insertSplitKeys(e){if(!e.isSplitProver())throw new Error("Attempted to insert invalid proving keys for split");this.cache.set(T.split.locator,[e.toBytes(),i.XV.splitVerifier().toBytes()])}insertTransferPrivateKeys(e){if(!e.isTransferPrivateProver())throw new Error("Attempted to insert invalid proving keys for transfer_private");this.cache.set(T.transfer_private.locator,[e.toBytes(),i.XV.transferPrivateVerifier().toBytes()])}insertTransferPrivateToPublicKeys(e){if(!e.isTransferPrivateToPublicProver())throw new Error("Attempted to insert invalid proving keys for transfer_private_to_public");this.cache.set(T.transfer_private_to_public.locator,[e.toBytes(),i.XV.transferPrivateToPublicVerifier().toBytes()])}insertTransferPublicKeys(e){if(!e.isTransferPublicProver())throw new Error("Attempted to insert invalid proving keys for transfer_public");this.cache.set(T.transfer_public.locator,[e.toBytes(),i.XV.transferPublicVerifier().toBytes()])}insertTransferPublicToPrivateKeys(e){if(!e.isTransferPublicToPrivateProver())throw new Error("Attempted to insert invalid proving keys for transfer_public_to_private");this.cache.set(T.transfer_public_to_private.locator,[e.toBytes(),i.XV.transferPublicToPrivateVerifier().toBytes()])}insertUnbondPublicKeys(e){if(!e.isUnbondPublicProver())throw new Error("Attempted to insert invalid proving keys for unbond_public");this.cache.set(T.unbond_public.locator,[e.toBytes(),i.XV.unbondPublicVerifier().toBytes()])}}class v{account;networkClient;constructor(e,t){this.account=e,this.networkClient=t}setAccount(e){this.account=e}async findCreditsRecords(e,t,r,n){let i=0,_=0;if(n&&("startHeight"in n&&"number"==typeof n.endHeight&&(i=n.startHeight),"endHeight"in n&&"number"==typeof n.endHeight&&(_=n.endHeight)),0==_){const e=await this.networkClient.getLatestHeight();if(e instanceof Error)throw l("Unable to get current block height from the network");_=e}if(i>=_)throw l("Start height must be less than end height");return await this.networkClient.findUnspentRecords(i,_,this.account.privateKey(),e,void 0,r)}async findCreditsRecord(e,t,r,n){const i=await this.findCreditsRecords([e],t,r,n);return!(i instanceof Error)&&i.length>0?i[0]:(console.error("Record not found with error:",i),new Error("Record not found"))}async findRecord(e,t,r){throw new Error("Method not implemented.")}async findRecords(e,t,r){throw new Error("Method not implemented.")}}class m{startHeight;endHeight;constructor(e,t){this.startHeight=e,this.endHeight=t}}let P=null;const k=()=>{if(!P){const e=new Worker(new URL(r.p+r.u(530),r.b),{type:void 0});P=(0,_.Ud)(e)}return P};class K{account;keyProvider;host;networkClient;recordProvider;constructor(e,t,r){this.host=e||"https://api.explorer.aleo.org/v1",this.networkClient=new w(this.host),this.keyProvider=t||new p,this.recordProvider=r}setAccount(e){this.account=e}setKeyProvider(e){this.keyProvider=e}setHost(e){this.host=e,this.networkClient.setHost(e)}setRecordProvider(e){this.recordProvider=e}async deploy(e,t,r,n,_,a){try{const t=i.$r.fromString(e);let r;try{r=await this.networkClient.getProgram(t.id())}catch(e){console.log(`Program ${t.id()} does not exist on the network, deploying...`)}if("string"==typeof r)throw`Program ${t.id()} already exists on the network, please rename your program`}catch(e){throw l(`Error validating program: ${e}`)}let o,s=a;if(void 0===a&&void 0!==this.account&&(s=this.account.privateKey()),void 0===s)throw"No private key provided and no private key set in the ProgramManager";try{_=r?await this.getCreditsRecord(t,[],_,n):void 0}catch(e){throw l(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{o=r?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys()}catch(e){throw l(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[c,d]=o;let g;try{g=await this.networkClient.getProgramImports(e)}catch(e){throw l(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}const u=await i.L.buildDeploymentTransaction(s,e,t,_,this.host,g,c,d);return await this.networkClient.submitTransaction(u)}async buildExecutionTransaction(e){const{programName:t,functionName:r,fee:n,privateFee:_,inputs:a,recordSearchParams:o,keySearchParams:s,privateKey:c,offlineQuery:d}=e;let g=e.feeRecord,u=e.provingKey,f=e.verifyingKey,w=e.program,b=e.imports;if(void 0===w)try{w=await this.networkClient.getProgram(t)}catch(e){throw l(`Error finding ${t}. Network response: '${e}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`)}else w instanceof i.$r&&(w=w.toString());let p,y=c;if(void 0===c&&void 0!==this.account&&(y=this.account.privateKey()),void 0===y)throw"No private key provided and no private key set in the ProgramManager";try{g=_?await this.getCreditsRecord(n,[],g,o):void 0}catch(e){throw l(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{p=_?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys()}catch(e){throw l(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[h,v]=p;if(!u||!f)try{[u,f]=await this.keyProvider.functionKeys(s)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}if(i.$r.fromString(w).getImports().length>0&&!b)try{b=await this.networkClient.getProgramImports(t)}catch(e){throw l(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await i.L.buildExecutionTransaction(y,w,r,a,n,g,this.host,b,u,f,h,v,d)}async execute(e){const t=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(t)}async run(e,t,r,n,_,a,o,s,c,d){let g=c;if(void 0===c&&void 0!==this.account&&(g=this.account.privateKey()),void 0===g)throw"No private key provided and no private key set in the ProgramManager";if(!o||!s)try{[o,s]=await this.keyProvider.functionKeys(a)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",o),console.log("Verifying key: ",s),i.L.executeFunctionOffline(g,e,t,r,n,!1,_,o,s,this.host,d)}async join(e,t,r,n,_,a,o,s){let c,d,g=o;if(void 0===o&&void 0!==this.account&&(g=this.account.privateKey()),void 0===g)throw"No private key provided and no private key set in the ProgramManager";try{c=n?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),d=await this.keyProvider.joinKeys()}catch(e){throw l(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[u,f]=c,[w,b]=d;try{a=n?await this.getCreditsRecord(r,[],a,_):void 0}catch(e){throw l(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof i.PD?e:i.PD.fromString(e),t=t instanceof i.PD?t:i.PD.fromString(t)}catch(e){throw l("Records provided are not valid. Please ensure they are valid plaintext records.")}const p=await i.L.buildJoinTransaction(g,e,t,r,a,this.host,w,b,u,f,s);return await this.networkClient.submitTransaction(p)}async split(e,t,r,n){let _,a=r;if(void 0===a&&void 0!==this.account&&(a=this.account.privateKey()),void 0===a)throw"No private key provided and no private key set in the ProgramManager";try{_=await this.keyProvider.splitKeys()}catch(e){throw l(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[o,s]=_;try{t=t instanceof i.PD?t:i.PD.fromString(t)}catch(e){throw l("Record provided is not valid. Please ensure it is a valid plaintext record.")}const c=await i.L.buildSplitTransaction(a,e,t,this.host,o,s,n);return await this.networkClient.submitTransaction(c)}async synthesizeKeys(e,t,r,n){let _,a=n;void 0===a&&(a=void 0!==this.account?this.account.privateKey():new i._q);try{_=await this.networkClient.getProgramImports(e);const n=await i.L.synthesizeKeyPair(a,e,t,r,_);return[n.provingKey(),n.verifyingKey()]}catch(e){throw l(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,t,r,n,_,a,o,s,g,u){r=d(r);let f,w,b=g;if(void 0===b&&void 0!==this.account&&(b=this.account.privateKey()),void 0===b)throw"No private key provided and no private key set in the ProgramManager";try{f=_?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),w=await this.keyProvider.transferKeys(r)}catch(e){throw l(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[p,y]=f,[h,v]=w;try{const e=[];c(r)?(o=await this.getCreditsRecord(n,[],o,a),e.push(o.nonce())):o=void 0,s=_?await this.getCreditsRecord(n,e,s,a):void 0}catch(e){throw l(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await i.L.buildTransferTransaction(b,e,t,r,o,n,s,this.host,h,v,p,y,u)}async buildTransferPublicTransaction(e,t,r,n,i){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,i)}async buildTransferPublicAsSignerTransaction(e,t,r,n,i){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,i)}async transfer(e,t,r,n,i,_,a,o,s,c){const d=await this.buildTransferTransaction(e,t,r,n,i,_,a,o,s,c);return await this.networkClient.submitTransaction(d)}async buildBondPublicTransaction(e,t,r,n,i={}){const _=Math.trunc(1e6*n),{programName:a="credits.aleo",functionName:o="bond_public",fee:s=i.fee||.86,privateFee:c=!1,inputs:d=[e,t,r,`${_.toString()}u64`],keySearchParams:g=new b({proverUri:T.bond_public.prover,verifierUri:T.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:l=this.creditsProgram(),...u}=i,f={programName:a,functionName:o,fee:s,privateFee:c,inputs:d,keySearchParams:g,...u};return await this.buildExecutionTransaction(f)}async bondPublic(e,t,r,n,i={}){const _=await this.buildBondPublicTransaction(e,t,r,n,i);return await this.networkClient.submitTransaction(_)}async buildBondValidatorTransaction(e,t,r,n,i={}){const _=Math.trunc(1e6*r),a=Math.trunc(n),{programName:o="credits.aleo",functionName:s="bond_validator",fee:c=i.fee||.86,privateFee:d=!1,inputs:g=[e,t,`${_.toString()}u64`,`${a.toString()}u8`],keySearchParams:l=new b({proverUri:T.bond_validator.prover,verifierUri:T.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:u=this.creditsProgram(),...f}=i,w={programName:o,functionName:s,fee:c,privateFee:d,inputs:g,keySearchParams:l,...f};return await this.buildExecutionTransaction(w)}async bondValidator(e,t,r,n,i={}){const _=await this.buildBondValidatorTransaction(e,t,r,n,i);return await this.networkClient.submitTransaction(_)}async buildUnbondPublicTransaction(e,t,r={}){const n=Math.trunc(1e6*t),{programName:i="credits.aleo",functionName:_="unbond_public",fee:a=r.fee||1.3,privateFee:o=!1,inputs:s=[e,`${n.toString()}u64`],keySearchParams:c=new b({proverUri:T.unbond_public.prover,verifierUri:T.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:d=this.creditsProgram(),...g}=r,l={programName:i,functionName:_,fee:a,privateFee:o,inputs:s,keySearchParams:c,...g};return this.buildExecutionTransaction(l)}async unbondPublic(e,t,r={}){const n=await this.buildUnbondPublicTransaction(e,t,r);return await this.networkClient.submitTransaction(n)}async buildClaimUnbondPublicTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="claim_unbond_public",fee:i=t.fee||2,privateFee:_=!1,inputs:a=[e],keySearchParams:o=new b({proverUri:T.claim_unbond_public.prover,verifierUri:T.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:s=this.creditsProgram(),...c}=t,d={programName:r,functionName:n,fee:i,privateFee:_,inputs:a,keySearchParams:o,...c};return await this.buildExecutionTransaction(d)}async claimUnbondPublic(e,t={}){const r=await this.buildClaimUnbondPublicTransaction(e,t);return await this.networkClient.submitTransaction(r)}async buildSetValidatorStateTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="set_validator_state",fee:i=1,privateFee:_=!1,inputs:a=[e.toString()],keySearchParams:o=new b({proverUri:T.set_validator_state.prover,verifierUri:T.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...s}=t,c={programName:r,functionName:n,fee:i,privateFee:_,inputs:a,keySearchParams:o,...s};return await this.execute(c)}async setValidatorState(e,t={}){const r=await this.buildSetValidatorStateTransaction(e,t);return this.networkClient.submitTransaction(r)}verifyExecution(e){try{const t=e.getExecution(),r=e.getFunctionId(),n=e.getProgram(),_=e.getVerifyingKey();return(0,i.hz)(t,_,n,r)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return i.$r.fromString(e)}creditsProgram(){return i.$r.getCreditsProgram()}verifyProgram(e){try{return i.$r.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,t,r,n){try{return r instanceof i.PD?r:i.PD.fromString(r)}catch(r){try{const r=this.recordProvider;return await r.findCreditsRecord(e,!0,t,n)}catch(e){throw l(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function c(e){return E.has(e)}function d(e){return V.has(e)?e:l(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const S=i.SF.baseUrl();function g(e){const t=i.XV[e.verifyingKey];if(!t)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:t}}const T={bond_public:g(i.SF.bond_public()),bond_validator:g(i.SF.bond_validator()),claim_unbond_public:g(i.SF.claim_unbond_public()),fee_private:g(i.SF.fee_private()),fee_public:g(i.SF.fee_public()),inclusion:g(i.SF.inclusion()),join:g(i.SF.join()),set_validator_state:g(i.SF.set_validator_state()),split:g(i.SF.split()),transfer_private:g(i.SF.transfer_private()),transfer_private_to_public:g(i.SF.transfer_private_to_public()),transfer_public:g(i.SF.transfer_public()),transfer_public_as_signer:g(i.SF.transfer_public_as_signer()),transfer_public_to_private:g(i.SF.transfer_public_to_private()),unbond_public:g(i.SF.unbond_public()),getKey:function(e){return this.hasOwnProperty(e)?this[e]:new Error(`Key "${e}" not found.`)}},E=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),V=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),R=new Set(["private","transfer_private","transferPrivate"]),F=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),x=new Set(["public","transfer_public","transferPublic"]),C=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),A=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function l(e){throw console.error(e),e}async function u(){console.warn("initializeWasm is deprecated, you no longer need to use it")}n()}catch(B){n(B)}}))},9933:(e,t,r)=>{r.a(e,(async(e,n)=>{try{function i(e,t,r,n){return new Promise((i=>{const _=new Worker(e,{type:"module"});_.addEventListener("message",(e=>{setTimeout((()=>{i(_),_.unref&&_.unref()}),0)}),{capture:!0,once:!0}),_.postMessage({module:t,memory:r,address:n})}))}let B;r.d(t,{$r:()=>Ie,CK:()=>A,Gd:()=>Be,IO:()=>We,L:()=>Me,PD:()=>$e,Pc:()=>De,SF:()=>Ae,XV:()=>qe,YW:()=>Le,_U:()=>xe,_q:()=>Oe,fW:()=>je,gN:()=>Ce,hz:()=>He,kL:()=>Re,o:()=>Fe,uq:()=>ze,zW:()=>Ne});const U=new Array(128).fill(void 0);function _(e){return U[e]}U.push(void 0,null,!0,!1);let O=U.length;function a(e){e<132||(U[e]=O,O=e)}function o(e){const t=_(e);return a(e),t}const z="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&z.decode();let I=null;function s(){return null!==I&&I.buffer===B.memory.buffer||(I=new Uint8Array(B.memory.buffer)),I}function c(e,t){return e>>>=0,z.decode(s().slice(e,e+t))}function d(e){O===U.length&&U.push(U.length+1);const t=O;return O=U[t],U[t]=e,t}let N=0;const j="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},$=function(e,t){const r=j.encode(e);return t.set(r),{read:e.length,written:r.length}};function g(e,t,r){if(void 0===r){const r=j.encode(e),n=t(r.length,1)>>>0;return s().subarray(n,n+r.length).set(r),N=r.length,n}let n=e.length,i=t(n,1)>>>0;const _=s();let a=0;for(;a127)break;_[i+a]=t}if(a!==n){0!==a&&(e=e.slice(a)),i=r(i,n,n=a+3*e.length,1)>>>0;const t=s().subarray(i+a,i+n);a+=$(e,t).written,i=r(i,n,a,1)>>>0}return N=a,i}function l(e){return null==e}let M=null;function u(){return null!==M&&M.buffer===B.memory.buffer||(M=new Int32Array(B.memory.buffer)),M}function f(e){const t=typeof e;if("number"==t||"boolean"==t||null==e)return`${e}`;if("string"==t)return`"${e}"`;if("symbol"==t){const t=e.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=e.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(e)){const t=e.length;let r="[";t>0&&(r+=f(e[0]));for(let n=1;n1))return toString.call(e);if(n=r[1],"Object"==n)try{return"Object("+JSON.stringify(e)+")"}catch(e){return"Object"}return e instanceof Error?`${e.name}: ${e.message}\n${e.stack}`:n}const D="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>{B.__wbindgen_export_3.get(e.dtor)(e.a,e.b)}));function w(e,t,r,n){const i={a:e,b:t,cnt:1,dtor:r},_=(...e)=>{i.cnt++;const t=i.a;i.a=0;try{return n(t,i.b,...e)}finally{0==--i.cnt?(B.__wbindgen_export_3.get(i.dtor)(t,i.b),D.unregister(i)):i.a=t}};return _.original=i,D.register(_,i,i),_}function b(e,t,r){B._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(e,t,d(r))}function p(e,t){if(!(e instanceof t))throw new Error(`expected instance of ${t.name}`);return e.ptr}function y(e,t){const r=t(1*e.length,1)>>>0;return s().set(e,r/1),N=e.length,r}function h(e,t,r,n){try{const a=B.__wbindgen_add_to_stack_pointer(-16);p(e,X),p(t,Ke),p(r,de);const s=g(n,B.__wbindgen_malloc,B.__wbindgen_realloc),c=N;B.verifyFunctionExecution(a,e.__wbg_ptr,t.__wbg_ptr,r.__wbg_ptr,s,c);var i=u()[a/4+0],_=u()[a/4+1];if(u()[a/4+2])throw o(_);return 0!==i}finally{B.__wbindgen_add_to_stack_pointer(16)}}let L=null;function v(){return null!==L&&L.buffer===B.memory.buffer||(L=new BigInt64Array(B.memory.buffer)),L}function m(e,t){return e>>>=0,s().subarray(e/1,e/1+t)}function P(e){B.runRayonThread(e)}function k(e,t){return o(B.initThreadPool(d(e),t))}function K(e,t){try{return e.apply(this,t)}catch(e){B.__wbindgen_exn_store(d(e))}}function S(e,t,r,n){B.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(e,t,d(r),d(n))}const W="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_address_free(e>>>0)));let q=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,W.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,W.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_address_free(e)}static from_private_key(t){p(t,ae);const r=B.address_from_private_key(t.__wbg_ptr);return e.__wrap(r)}static from_view_key(t){p(t,Te);const r=B.address_from_view_key(t.__wbg_ptr);return e.__wrap(r)}static from_string(t){const r=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),n=N,i=B.address_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.address_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}verify(e,t){const r=y(e,B.__wbindgen_malloc),n=N;p(t,ve);return 0!==B.address_verify(this.__wbg_ptr,r,n,t.__wbg_ptr)}};const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_execution_free(e>>>0)));let X=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,H.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_execution_free(e)}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.execution_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.execution_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}};const J="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_executionresponse_free(e>>>0)));let Y=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,J.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,J.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_executionresponse_free(e)}getOutputs(){return o(B.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const e=B.executionresponse_getExecution(this.__wbg_ptr);return 0===e?void 0:X.__wrap(e)}getKeys(){try{const r=B.__wbindgen_add_to_stack_pointer(-16);B.executionresponse_getKeys(r,this.__wbg_ptr);var e=u()[r/4+0],t=u()[r/4+1];if(u()[r/4+2])throw o(t);return ee.__wrap(e)}finally{B.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const e=B.executionresponse_getProvingKey(this.__wbg_ptr);return 0===e?void 0:fe.__wrap(e)}getVerifyingKey(){const e=B.executionresponse_getVerifyingKey(this.__wbg_ptr);return Ke.__wrap(e)}getFunctionId(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.executionresponse_getFunctionId(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}getProgram(){const e=B.executionresponse_getProgram(this.__wbg_ptr);return de.__wrap(e)}};const G="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_field_free(e>>>0)));let Q=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,G.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,G.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_field_free(e)}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.field_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.field_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}};const Z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_keypair_free(e>>>0)));class ee{static __wrap(e){e>>>=0;const t=Object.create(ee.prototype);return t.__wbg_ptr=e,Z.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_keypair_free(e)}constructor(e,t){p(e,fe);var r=e.__destroy_into_raw();p(t,Ke);var n=t.__destroy_into_raw();const i=B.keypair_new(r,n);return this.__wbg_ptr=i>>>0,this}provingKey(){try{const r=B.__wbindgen_add_to_stack_pointer(-16);B.keypair_provingKey(r,this.__wbg_ptr);var e=u()[r/4+0],t=u()[r/4+1];if(u()[r/4+2])throw o(t);return fe.__wrap(e)}finally{B.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const r=B.__wbindgen_add_to_stack_pointer(-16);B.keypair_verifyingKey(r,this.__wbg_ptr);var e=u()[r/4+0],t=u()[r/4+1];if(u()[r/4+2])throw o(t);return Ke.__wrap(e)}finally{B.__wbindgen_add_to_stack_pointer(16)}}}const te="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_metadata_free(e>>>0)));let re=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,te.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,te.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_metadata_free(e)}get name(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.__wbg_get_metadata_name(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}set name(e){const t=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),r=N;B.__wbg_set_metadata_name(this.__wbg_ptr,t,r)}get locator(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.__wbg_get_metadata_locator(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}set locator(e){const t=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),r=N;B.__wbg_set_metadata_locator(this.__wbg_ptr,t,r)}get prover(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.__wbg_get_metadata_prover(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}set prover(e){const t=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),r=N;B.__wbg_set_metadata_prover(this.__wbg_ptr,t,r)}get verifier(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.__wbg_get_metadata_verifier(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}set verifier(e){const t=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),r=N;B.__wbg_set_metadata_verifier(this.__wbg_ptr,t,r)}get verifyingKey(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.__wbg_get_metadata_verifyingKey(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}set verifyingKey(e){const t=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),r=N;B.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,t,r)}static baseUrl(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.metadata_baseUrl(i);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}static bond_public(){const t=B.metadata_bond_public();return e.__wrap(t)}static bond_validator(){const t=B.metadata_bond_validator();return e.__wrap(t)}static claim_unbond_public(){const t=B.metadata_claim_unbond_public();return e.__wrap(t)}static fee_private(){const t=B.metadata_fee_private();return e.__wrap(t)}static fee_public(){const t=B.metadata_fee_public();return e.__wrap(t)}static inclusion(){const t=B.metadata_inclusion();return e.__wrap(t)}static join(){const t=B.metadata_join();return e.__wrap(t)}static set_validator_state(){const t=B.metadata_set_validator_state();return e.__wrap(t)}static split(){const t=B.metadata_split();return e.__wrap(t)}static transfer_private(){const t=B.metadata_transfer_private();return e.__wrap(t)}static transfer_private_to_public(){const t=B.metadata_transfer_private_to_public();return e.__wrap(t)}static transfer_public(){const t=B.metadata_transfer_public();return e.__wrap(t)}static transfer_public_as_signer(){const t=B.metadata_transfer_public_as_signer();return e.__wrap(t)}static transfer_public_to_private(){const t=B.metadata_transfer_public_to_private();return e.__wrap(t)}static unbond_public(){const t=B.metadata_unbond_public();return e.__wrap(t)}};const ne="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_offlinequery_free(e>>>0)));let ie=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ne.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ne.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_offlinequery_free(e)}constructor(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N;B.offlinequery_new(n,i,_);var t=u()[n/4+0],r=u()[n/4+1];if(u()[n/4+2])throw o(r);return this.__wbg_ptr=t>>>0,this}finally{B.__wbindgen_add_to_stack_pointer(16)}}addStatePath(e,t){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N,a=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),s=N;B.offlinequery_addStatePath(n,this.__wbg_ptr,i,_,a,s);var r=u()[n/4+0];if(u()[n/4+1])throw o(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.offlinequery_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.offlinequery_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}};const _e="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_privatekey_free(e>>>0)));let ae=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,_e.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,_e.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_privatekey_free(e)}constructor(){const e=B.privatekey_new();return this.__wbg_ptr=e>>>0,this}static from_seed_unchecked(t){const r=y(t,B.__wbindgen_malloc),n=N,i=B.privatekey_from_seed_unchecked(r,n);return e.__wrap(i)}static from_string(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.privatekey_from_string(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}to_string(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.privatekey_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}to_view_key(){const e=B.privatekey_to_view_key(this.__wbg_ptr);return Te.__wrap(e)}to_address(){const e=B.privatekey_to_address(this.__wbg_ptr);return q.__wrap(e)}sign(e){const t=y(e,B.__wbindgen_malloc),r=N,n=B.privatekey_sign(this.__wbg_ptr,t,r);return ve.__wrap(n)}static newEncrypted(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N;B.privatekey_newEncrypted(n,i,_);var t=u()[n/4+0],r=u()[n/4+1];if(u()[n/4+2])throw o(r);return se.__wrap(t)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N;B.privatekey_toCiphertext(n,this.__wbg_ptr,i,_);var t=u()[n/4+0],r=u()[n/4+1];if(u()[n/4+2])throw o(r);return se.__wrap(t)}finally{B.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,r){try{const _=B.__wbindgen_add_to_stack_pointer(-16);p(t,se);const a=g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),s=N;B.privatekey_fromPrivateKeyCiphertext(_,t.__wbg_ptr,a,s);var n=u()[_/4+0],i=u()[_/4+1];if(u()[_/4+2])throw o(i);return e.__wrap(n)}finally{B.__wbindgen_add_to_stack_pointer(16)}}};const oe="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_privatekeyciphertext_free(e>>>0)));let se=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,oe.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,oe.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_privatekeyciphertext_free(e)}static encryptPrivateKey(t,r){try{const _=B.__wbindgen_add_to_stack_pointer(-16);p(t,ae);const a=g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),s=N;B.privatekey_toCiphertext(_,t.__wbg_ptr,a,s);var n=u()[_/4+0],i=u()[_/4+1];if(u()[_/4+2])throw o(i);return e.__wrap(n)}finally{B.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N;B.privatekeyciphertext_decryptToPrivateKey(n,this.__wbg_ptr,i,_);var t=u()[n/4+0],r=u()[n/4+1];if(u()[n/4+2])throw o(r);return ae.__wrap(t)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.privatekeyciphertext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.privatekeyciphertext_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}};const ce="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_program_free(e>>>0)));let de=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ce.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ce.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_program_free(e)}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.program_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.program_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}hasFunction(e){const t=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),r=N;return 0!==B.program_hasFunction(this.__wbg_ptr,t,r)}getFunctions(){return o(B.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N;B.program_getFunctionInputs(n,this.__wbg_ptr,i,_);var t=u()[n/4+0],r=u()[n/4+1];if(u()[n/4+2])throw o(r);return o(t)}finally{B.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const r=B.__wbindgen_add_to_stack_pointer(-16);B.program_getMappings(r,this.__wbg_ptr);var e=u()[r/4+0],t=u()[r/4+1];if(u()[r/4+2])throw o(t);return o(e)}finally{B.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N;B.program_getRecordMembers(n,this.__wbg_ptr,i,_);var t=u()[n/4+0],r=u()[n/4+1];if(u()[n/4+2])throw o(r);return o(t)}finally{B.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N;B.program_getStructMembers(n,this.__wbg_ptr,i,_);var t=u()[n/4+0],r=u()[n/4+1];if(u()[n/4+2])throw o(r);return o(t)}finally{B.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=B.program_getCreditsProgram();return e.__wrap(t)}id(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.program_id(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}address(){try{const r=B.__wbindgen_add_to_stack_pointer(-16);B.program_address(r,this.__wbg_ptr);var e=u()[r/4+0],t=u()[r/4+1];if(u()[r/4+2])throw o(t);return q.__wrap(e)}finally{B.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){p(t,e);return 0!==B.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return o(B.program_getImports(this.__wbg_ptr))}};const ge="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_programmanager_free(e>>>0)));let le=class{__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ge.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_programmanager_free(e)}static buildDeploymentTransaction(e,t,r,n,i,_,a,s,c){p(e,ae);const u=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),f=N;let w=0;l(n)||(p(n,ye),w=n.__destroy_into_raw());var b=l(i)?0:g(i,B.__wbindgen_malloc,B.__wbindgen_realloc),y=N;let h=0;l(a)||(p(a,fe),h=a.__destroy_into_raw());let v=0;l(s)||(p(s,Ke),v=s.__destroy_into_raw());let m=0;l(c)||(p(c,ie),m=c.__destroy_into_raw());return o(B.programmanager_buildDeploymentTransaction(e.__wbg_ptr,u,f,r,w,b,y,l(_)?0:d(_),h,v,m))}static estimateDeploymentFee(e,t){const r=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),n=N;return o(B.programmanager_estimateDeploymentFee(r,n,l(t)?0:d(t)))}static estimateProgramNameCost(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16),i=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),_=N;B.programmanager_estimateProgramNameCost(n,i,_);var t=v()[n/8+0],r=u()[n/4+2];if(u()[n/4+3])throw o(r);return BigInt.asUintN(64,t)}finally{B.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(e,t,r,n,i,_,a,s,c,u,f){p(e,ae);const w=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),b=N,y=g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),h=N;let v=0;l(s)||(p(s,fe),v=s.__destroy_into_raw());let m=0;l(c)||(p(c,Ke),m=c.__destroy_into_raw());var P=l(u)?0:g(u,B.__wbindgen_malloc,B.__wbindgen_realloc),k=N;let K=0;l(f)||(p(f,ie),K=f.__destroy_into_raw());return o(B.programmanager_executeFunctionOffline(e.__wbg_ptr,w,b,y,h,d(n),i,_,l(a)?0:d(a),v,m,P,k,K))}static buildExecutionTransaction(e,t,r,n,i,_,a,s,c,u,f,w,b){p(e,ae);const y=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),h=N,v=g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),m=N;let P=0;l(_)||(p(_,ye),P=_.__destroy_into_raw());var k=l(a)?0:g(a,B.__wbindgen_malloc,B.__wbindgen_realloc),K=N;let S=0;l(c)||(p(c,fe),S=c.__destroy_into_raw());let T=0;l(u)||(p(u,Ke),T=u.__destroy_into_raw());let E=0;l(f)||(p(f,fe),E=f.__destroy_into_raw());let V=0;l(w)||(p(w,Ke),V=w.__destroy_into_raw());let R=0;l(b)||(p(b,ie),R=b.__destroy_into_raw());return o(B.programmanager_buildExecutionTransaction(e.__wbg_ptr,y,h,v,m,d(n),i,P,k,K,l(s)?0:d(s),S,T,E,V,R))}static estimateExecutionFee(e,t,r,n,i,_,a,s,c){p(e,ae);const u=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),f=N,w=g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),b=N;var y=l(i)?0:g(i,B.__wbindgen_malloc,B.__wbindgen_realloc),h=N;let v=0;l(a)||(p(a,fe),v=a.__destroy_into_raw());let m=0;l(s)||(p(s,Ke),m=s.__destroy_into_raw());let P=0;l(c)||(p(c,ie),P=c.__destroy_into_raw());return o(B.programmanager_estimateExecutionFee(e.__wbg_ptr,u,f,w,b,d(n),y,h,l(_)?0:d(_),v,m,P))}static estimateFinalizeFee(e,t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N,s=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),c=N;B.programmanager_estimateFinalizeFee(i,_,a,s,c);var r=v()[i/8+0],n=u()[i/4+2];if(u()[i/4+3])throw o(n);return BigInt.asUintN(64,r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(e,t,r,n,i,_,a,s,c,d,u){p(e,ae),p(t,ye);var f=t.__destroy_into_raw();p(r,ye);var w=r.__destroy_into_raw();let b=0;l(i)||(p(i,ye),b=i.__destroy_into_raw());var y=l(_)?0:g(_,B.__wbindgen_malloc,B.__wbindgen_realloc),h=N;let v=0;l(a)||(p(a,fe),v=a.__destroy_into_raw());let m=0;l(s)||(p(s,Ke),m=s.__destroy_into_raw());let P=0;l(c)||(p(c,fe),P=c.__destroy_into_raw());let k=0;l(d)||(p(d,Ke),k=d.__destroy_into_raw());let K=0;l(u)||(p(u,ie),K=u.__destroy_into_raw());return o(B.programmanager_buildJoinTransaction(e.__wbg_ptr,f,w,n,b,y,h,v,m,P,k,K))}static buildSplitTransaction(e,t,r,n,i,_,a){p(e,ae),p(r,ye);var s=r.__destroy_into_raw(),c=l(n)?0:g(n,B.__wbindgen_malloc,B.__wbindgen_realloc),d=N;let u=0;l(i)||(p(i,fe),u=i.__destroy_into_raw());let f=0;l(_)||(p(_,Ke),f=_.__destroy_into_raw());let w=0;l(a)||(p(a,ie),w=a.__destroy_into_raw());return o(B.programmanager_buildSplitTransaction(e.__wbg_ptr,t,s,c,d,u,f,w))}static buildTransferTransaction(e,t,r,n,i,_,a,s,c,d,u,f,w){p(e,ae);const b=g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),y=N,h=g(n,B.__wbindgen_malloc,B.__wbindgen_realloc),v=N;let m=0;l(i)||(p(i,ye),m=i.__destroy_into_raw());let P=0;l(a)||(p(a,ye),P=a.__destroy_into_raw());var k=l(s)?0:g(s,B.__wbindgen_malloc,B.__wbindgen_realloc),K=N;let S=0;l(c)||(p(c,fe),S=c.__destroy_into_raw());let T=0;l(d)||(p(d,Ke),T=d.__destroy_into_raw());let E=0;l(u)||(p(u,fe),E=u.__destroy_into_raw());let V=0;l(f)||(p(f,Ke),V=f.__destroy_into_raw());let R=0;l(w)||(p(w,ie),R=w.__destroy_into_raw());return o(B.programmanager_buildTransferTransaction(e.__wbg_ptr,t,b,y,h,v,m,_,P,k,K,S,T,E,V,R))}static synthesizeKeyPair(e,t,r,n,i){p(e,ae);const _=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N,s=g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),c=N;return o(B.programmanager_synthesizeKeyPair(e.__wbg_ptr,_,a,s,c,d(n),l(i)?0:d(i)))}};const ue="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_provingkey_free(e>>>0)));let fe=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ue.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ue.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_provingkey_free(e)}isBondPublicProver(){return 0!==B.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==B.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==B.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==B.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==B.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==B.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==B.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==B.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==B.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==B.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==B.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==B.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==B.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==B.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==B.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.provingkey_checksum(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}copy(){const t=B.provingkey_copy(this.__wbg_ptr);return e.__wrap(t)}static fromBytes(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=y(t,B.__wbindgen_malloc),a=N;B.provingkey_fromBytes(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.provingkey_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.provingkey_toBytes(i,this.__wbg_ptr);var e=u()[i/4+0],t=u()[i/4+1],r=u()[i/4+2];if(u()[i/4+3])throw o(r);var n=m(e,t).slice();return B.__wbindgen_free(e,1*t,1),n}finally{B.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.provingkey_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}};const we="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_recordciphertext_free(e>>>0)));let be=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,we.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,we.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_recordciphertext_free(e)}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.recordciphertext_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.recordciphertext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}decrypt(e){try{const n=B.__wbindgen_add_to_stack_pointer(-16);p(e,Te),B.recordciphertext_decrypt(n,this.__wbg_ptr,e.__wbg_ptr);var t=u()[n/4+0],r=u()[n/4+1];if(u()[n/4+2])throw o(r);return ye.__wrap(t)}finally{B.__wbindgen_add_to_stack_pointer(16)}}isOwner(e){p(e,Te);return 0!==B.recordciphertext_isOwner(this.__wbg_ptr,e.__wbg_ptr)}};const pe="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_recordplaintext_free(e>>>0)));let ye=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,pe.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,pe.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_recordplaintext_free(e)}commitment(e,t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N,s=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),c=N;B.recordplaintext_commitment(i,this.__wbg_ptr,_,a,s,c);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return Q.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.recordplaintext_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.recordplaintext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}microcredits(){const e=B.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,e)}nonce(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.recordplaintext_nonce(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}serialNumberString(e,t,r){let n,i;try{const w=B.__wbindgen_add_to_stack_pointer(-16);p(e,ae);const b=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),y=N,h=g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),v=N;B.recordplaintext_serialNumberString(w,this.__wbg_ptr,e.__wbg_ptr,b,y,h,v);var _=u()[w/4+0],a=u()[w/4+1],s=u()[w/4+2],d=u()[w/4+3],l=_,f=a;if(d)throw l=0,f=0,o(s);return n=l,i=f,c(l,f)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(n,i,1)}}};const he="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_signature_free(e>>>0)));let ve=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,he.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,he.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_signature_free(e)}static sign(t,r){p(t,ae);const n=y(r,B.__wbindgen_malloc),i=N,_=B.privatekey_sign(t.__wbg_ptr,n,i);return e.__wrap(_)}verify(e,t){p(e,q);const r=y(t,B.__wbindgen_malloc),n=N;return 0!==B.signature_verify(this.__wbg_ptr,e.__wbg_ptr,r,n)}static from_string(t){const r=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),n=N,i=B.signature_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.signature_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}};const me="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_transaction_free(e>>>0)));let Pe=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,me.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,me.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_transaction_free(e)}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.transaction_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.transaction_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}transactionId(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.transaction_transactionId(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}transactionType(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.transaction_transactionType(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}};const ke="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_verifyingkey_free(e>>>0)));let Ke=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ke.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ke.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_verifyingkey_free(e)}static bondPublicVerifier(){const t=B.verifyingkey_bondPublicVerifier();return e.__wrap(t)}static bondValidatorVerifier(){const t=B.verifyingkey_bondValidatorVerifier();return e.__wrap(t)}static claimUnbondPublicVerifier(){const t=B.verifyingkey_claimUnbondPublicVerifier();return e.__wrap(t)}static feePrivateVerifier(){const t=B.verifyingkey_feePrivateVerifier();return e.__wrap(t)}static feePublicVerifier(){const t=B.verifyingkey_feePublicVerifier();return e.__wrap(t)}static inclusionVerifier(){const t=B.verifyingkey_inclusionVerifier();return e.__wrap(t)}static joinVerifier(){const t=B.verifyingkey_joinVerifier();return e.__wrap(t)}static setValidatorStateVerifier(){const t=B.verifyingkey_setValidatorStateVerifier();return e.__wrap(t)}static splitVerifier(){const t=B.verifyingkey_splitVerifier();return e.__wrap(t)}static transferPrivateVerifier(){const t=B.verifyingkey_transferPrivateVerifier();return e.__wrap(t)}static transferPrivateToPublicVerifier(){const t=B.verifyingkey_transferPrivateToPublicVerifier();return e.__wrap(t)}static transferPublicVerifier(){const t=B.verifyingkey_transferPublicVerifier();return e.__wrap(t)}static transferPublicAsSignerVerifier(){const t=B.verifyingkey_transferPublicAsSignerVerifier();return e.__wrap(t)}static transferPublicToPrivateVerifier(){const t=B.verifyingkey_transferPublicToPrivateVerifier();return e.__wrap(t)}static unbondPublicVerifier(){const t=B.verifyingkey_unbondPublicVerifier();return e.__wrap(t)}isBondPublicVerifier(){return 0!==B.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==B.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==B.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==B.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==B.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==B.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==B.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==B.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==B.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==B.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==B.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==B.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==B.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==B.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==B.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.verifyingkey_checksum(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}copy(){const t=B.verifyingkey_copy(this.__wbg_ptr);return e.__wrap(t)}static fromBytes(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=y(t,B.__wbindgen_malloc),a=N;B.verifyingkey_fromBytes(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=B.__wbindgen_add_to_stack_pointer(-16),_=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;B.verifyingkey_fromString(i,_,a);var r=u()[i/4+0],n=u()[i/4+1];if(u()[i/4+2])throw o(n);return e.__wrap(r)}finally{B.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.verifyingkey_toBytes(i,this.__wbg_ptr);var e=u()[i/4+0],t=u()[i/4+1],r=u()[i/4+2];if(u()[i/4+3])throw o(r);var n=m(e,t).slice();return B.__wbindgen_free(e,1*t,1),n}finally{B.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.verifyingkey_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}};const Se="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>B.__wbg_viewkey_free(e>>>0)));let Te=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,Se.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,Se.unregister(this),e}free(){const e=this.__destroy_into_raw();B.__wbg_viewkey_free(e)}static from_private_key(t){p(t,ae);const r=B.privatekey_to_view_key(t.__wbg_ptr);return e.__wrap(r)}static from_string(t){const r=g(t,B.__wbindgen_malloc,B.__wbindgen_realloc),n=N,i=B.viewkey_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=B.__wbindgen_add_to_stack_pointer(-16);B.viewkey_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return e=r,t=n,c(r,n)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(e,t,1)}}to_address(){const e=B.address_from_view_key(this.__wbg_ptr);return q.__wrap(e)}decrypt(e){let t,r;try{const l=B.__wbindgen_add_to_stack_pointer(-16),f=g(e,B.__wbindgen_malloc,B.__wbindgen_realloc),w=N;B.viewkey_decrypt(l,this.__wbg_ptr,f,w);var n=u()[l/4+0],i=u()[l/4+1],_=u()[l/4+2],a=u()[l/4+3],s=n,d=i;if(a)throw s=0,d=0,o(_);return t=s,r=d,c(s,d)}finally{B.__wbindgen_add_to_stack_pointer(16),B.__wbindgen_free(t,r,1)}}};async function T(e,t){if("function"==typeof Response&&e instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(e,t)}catch(t){if("application/wasm"==e.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const r=await e.arrayBuffer();return await WebAssembly.instantiate(r,t)}{const r=await WebAssembly.instantiate(e,t);return r instanceof WebAssembly.Instance?{instance:r,module:e}:r}}function E(){const e={wbg:{}};return e.wbg.__wbindgen_object_drop_ref=function(e){o(e)},e.wbg.__wbg_new_71801a555ad9f2aa=function(){return K((function(){return d(new XMLHttpRequest)}),arguments)},e.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return K((function(e,t,r){_(e).overrideMimeType(c(t,r))}),arguments)},e.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return K((function(e,t,r,n,i,a){_(e).open(c(t,r),c(n,i),0!==a)}),arguments)},e.wbg.__wbg_send_80d29985093c1ec5=function(){return K((function(e){_(e).send()}),arguments)},e.wbg.__wbg_response_7c2e2759084f7279=function(){return K((function(e){return d(_(e).response)}),arguments)},e.wbg.__wbg_status_d485fb5a478426fb=function(){return K((function(e){return _(e).status}),arguments)},e.wbg.__wbg_new_72fb9a18b5ae2624=function(){return d(new Object)},e.wbg.__wbindgen_string_new=function(e,t){return d(c(e,t))},e.wbg.__wbg_set_1f9b04f170055d33=function(){return K((function(e,t,r){return Reflect.set(_(e),_(t),_(r))}),arguments)},e.wbg.__wbg_new_ab6fd82b10560829=function(){return K((function(){return d(new Headers)}),arguments)},e.wbg.__wbindgen_object_clone_ref=function(e){return d(_(e))},e.wbg.__wbg_new_0d76b0581eca6298=function(){return K((function(){return d(new AbortController)}),arguments)},e.wbg.__wbg_signal_a61f78a3478fd9bc=function(e){return d(_(e).signal)},e.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return K((function(e,t,r,n,i){_(e).append(c(t,r),c(n,i))}),arguments)},e.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(e){let t;try{t=_(e)instanceof Response}catch(e){t=!1}return t},e.wbg.__wbg_status_61a01141acd3cf74=function(e){return _(e).status},e.wbg.__wbg_url_5f6dc4009ac5f99d=function(e,t){const r=g(_(t).url,B.__wbindgen_malloc,B.__wbindgen_realloc),n=N;u()[e/4+1]=n,u()[e/4+0]=r},e.wbg.__wbg_headers_9620bfada380764a=function(e){return d(_(e).headers)},e.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return d(Symbol.iterator)},e.wbg.__wbg_get_e3c254076557e348=function(){return K((function(e,t){return d(Reflect.get(_(e),_(t)))}),arguments)},e.wbg.__wbindgen_is_function=function(e){return"function"==typeof _(e)},e.wbg.__wbg_call_27c0f87801dedf93=function(){return K((function(e,t){return d(_(e).call(_(t)))}),arguments)},e.wbg.__wbindgen_is_object=function(e){const t=_(e);return"object"==typeof t&&null!==t},e.wbg.__wbg_next_40fc327bfc8770e6=function(e){return d(_(e).next)},e.wbg.__wbg_next_196c84450b364254=function(){return K((function(e){return d(_(e).next())}),arguments)},e.wbg.__wbg_done_298b57d23c0fc80c=function(e){return _(e).done},e.wbg.__wbg_value_d93c65011f51a456=function(e){return d(_(e).value)},e.wbg.__wbg_abort_2aa7521d5690750e=function(e){_(e).abort()},e.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return K((function(e){return d(JSON.stringify(_(e)))}),arguments)},e.wbg.__wbindgen_string_get=function(e,t){const r=_(t),n="string"==typeof r?r:void 0;var i=l(n)?0:g(n,B.__wbindgen_malloc,B.__wbindgen_realloc),a=N;u()[e/4+1]=a,u()[e/4+0]=i},e.wbg.__wbg_log_0159ca40cddf5b15=function(e,t){console.log(c(e,t))},e.wbg.__wbindgen_bigint_from_u64=function(e){return d(BigInt.asUintN(64,e))},e.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return K((function(e,t,r){return d(_(e).call(_(t),_(r)))}),arguments)},e.wbg.__wbg_transaction_new=function(e){return d(Pe.__wrap(e))},e.wbg.__wbg_keypair_new=function(e){return d(ee.__wrap(e))},e.wbg.__wbindgen_module=function(){return d(x.__wbindgen_wasm_module)},e.wbg.__wbindgen_memory=function(){return d(B.memory)},e.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a=function(e,t,r,n){return d(i(_(e),_(t),_(r),n>>>0))},e.wbg.__wbg_executionresponse_new=function(e){return d(Y.__wrap(e))},e.wbg.__wbg_newwithlength_66ae46612e7f0234=function(e){return d(new Array(e>>>0))},e.wbg.__wbg_set_d4638f722068f043=function(e,t,r){_(e)[t>>>0]=o(r)},e.wbg.__wbindgen_cb_drop=function(e){const t=o(e).original;if(1==t.cnt--)return t.a=0,!0;return!1},e.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return d(new Array)},e.wbg.__wbg_push_a5b05aedc7234f9f=function(e,t){return _(e).push(_(t))},e.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return K((function(e){return d(_(e).arrayBuffer())}),arguments)},e.wbg.__wbg_new_63b92bc8671ed464=function(e){return d(new Uint8Array(_(e)))},e.wbg.__wbg_length_c20a40f15020d68a=function(e){return _(e).length},e.wbg.__wbg_new_81740750da40724f=function(e,t){try{var r={a:e,b:t};const n=new Promise(((e,t)=>{const n=r.a;r.a=0;try{return S(n,r.b,e,t)}finally{r.a=n}}));return d(n)}finally{r.a=r.b=0}},e.wbg.__wbindgen_number_new=function(e){return d(e)},e.wbg.__wbg_new_abda76e883ba8a5f=function(){return d(new Error)},e.wbg.__wbg_stack_658279fe44541cf6=function(e,t){const r=g(_(t).stack,B.__wbindgen_malloc,B.__wbindgen_realloc),n=N;u()[e/4+1]=n,u()[e/4+0]=r},e.wbg.__wbg_error_f851667af71bcfc6=function(e,t){let r,n;try{r=e,n=t,console.error(c(e,t))}finally{B.__wbindgen_free(r,n,1)}},e.wbg.__wbg_buffer_12d079cc21e14bdb=function(e){return d(_(e).buffer)},e.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(e,t,r){return d(new Uint8Array(_(e),t>>>0,r>>>0))},e.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return K((function(e,t){_(e).randomFillSync(o(t))}),arguments)},e.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(e,t,r){return d(_(e).subarray(t>>>0,r>>>0))},e.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return K((function(e,t){_(e).getRandomValues(_(t))}),arguments)},e.wbg.__wbg_set_a47bac70306a19a7=function(e,t,r){_(e).set(_(t),r>>>0)},e.wbg.__wbg_crypto_1d1f22824a6a080c=function(e){return d(_(e).crypto)},e.wbg.__wbg_process_4a72847cc503995b=function(e){return d(_(e).process)},e.wbg.__wbg_versions_f686565e586dd935=function(e){return d(_(e).versions)},e.wbg.__wbg_node_104a2ff8d6ea03a2=function(e){return d(_(e).node)},e.wbg.__wbindgen_is_string=function(e){return"string"==typeof _(e)},e.wbg.__wbg_require_cca90b1a94a0255b=function(){return K((function(){return d(module.require)}),arguments)},e.wbg.__wbg_msCrypto_eb05e62b530a1508=function(e){return d(_(e).msCrypto)},e.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(e){return d(new Uint8Array(e>>>0))},e.wbg.__wbg_length_cd7af8117672b8b8=function(e){return _(e).length},e.wbg.__wbg_get_bd8e338fbd5f5cc8=function(e,t){return d(_(e)[t>>>0])},e.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return K((function(){return d(self.self)}),arguments)},e.wbg.__wbg_window_c6fb939a7f436783=function(){return K((function(){return d(window.window)}),arguments)},e.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return K((function(){return d(globalThis.globalThis)}),arguments)},e.wbg.__wbg_global_207b558942527489=function(){return K((function(){return d(global.global)}),arguments)},e.wbg.__wbindgen_is_undefined=function(e){return void 0===_(e)},e.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(e,t){return d(new Function(c(e,t)))},e.wbg.__wbg_has_0af94d20077affa2=function(){return K((function(e,t){return Reflect.has(_(e),_(t))}),arguments)},e.wbg.__wbg_fetch_bc7c8e27076a5c84=function(e){return d(fetch(_(e)))},e.wbg.__wbg_fetch_921fad6ef9e883dd=function(e,t){return d(_(e).fetch(_(t)))},e.wbg.__wbindgen_debug_string=function(e,t){const r=g(f(_(t)),B.__wbindgen_malloc,B.__wbindgen_realloc),n=N;u()[e/4+1]=n,u()[e/4+0]=r},e.wbg.__wbindgen_throw=function(e,t){throw new Error(c(e,t))},e.wbg.__wbindgen_rethrow=function(e){throw o(e)},e.wbg.__wbg_then_a73caa9a87991566=function(e,t,r){return d(_(e).then(_(t),_(r)))},e.wbg.__wbg_then_0c86a60e8fcfe9f6=function(e,t){return d(_(e).then(_(t)))},e.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(e){queueMicrotask(_(e))},e.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(e){return d(_(e).queueMicrotask)},e.wbg.__wbg_resolve_b0083a7967828ec8=function(e){return d(Promise.resolve(_(e)))},e.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return d(Atomics.waitAsync)},e.wbg.__wbg_new_8cccba86b0f574cb=function(e){return d(new Int32Array(_(e)))},e.wbg.__wbg_waitAsync_46d5c36955b71a79=function(e,t,r){return d(Atomics.waitAsync(_(e),t,r))},e.wbg.__wbg_async_19c0400d97cc72fe=function(e){return _(e).async},e.wbg.__wbg_value_571d60108110e917=function(e){return d(_(e).value)},e.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(e){const t=g("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),B.__wbindgen_malloc,B.__wbindgen_realloc),r=N;u()[e/4+1]=r,u()[e/4+0]=t},e.wbg.__wbg_new_d1187ae36d662ef9=function(){return K((function(e,t){return d(new Worker(c(e,t)))}),arguments)},e.wbg.__wbg_setonmessage_503809e5bb51bd33=function(e,t){_(e).onmessage=_(t)},e.wbg.__wbg_of_6a70eed8d41f469c=function(e,t,r){return d(Array.of(_(e),_(t),_(r)))},e.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return K((function(e,t){_(e).postMessage(_(t))}),arguments)},e.wbg.__wbg_data_3ce7c145ca4fbcdc=function(e){return d(_(e).data)},e.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return K((function(e,t,r){return d(new Request(c(e,t),_(r)))}),arguments)},e.wbg.__wbg_responseText_c67ed2d48db10769=function(){return K((function(e,t){const r=_(t).responseText;var n=l(r)?0:g(r,B.__wbindgen_malloc,B.__wbindgen_realloc),i=N;u()[e/4+1]=i,u()[e/4+0]=n}),arguments)},e.wbg.__wbindgen_closure_wrapper5837=function(e,t,r){return d(w(e,t,538,b))},e.wbg.__wbindgen_closure_wrapper5862=function(e,t,r){return d(w(e,t,538,b))},e}function V(e,t){e.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function R(e,t){return B=e.exports,x.__wbindgen_wasm_module=t,L=null,M=null,I=null,B.__wbindgen_start(),B}function F(e,t){if(void 0!==B)return B;const r=E();V(r,t),e instanceof WebAssembly.Module||(e=new WebAssembly.Module(e));return R(new WebAssembly.Instance(e,r),e)}async function x(e,t){if(void 0!==B)return B;const r=E();("string"==typeof e||"function"==typeof Request&&e instanceof Request||"function"==typeof URL&&e instanceof URL)&&(e=fetch(e)),V(r,t);const{instance:n,module:i}=await T(await e,r);return R(n,i)}var C=Object.freeze({__proto__:null,Address:q,Execution:X,ExecutionResponse:Y,Field:Q,KeyPair:ee,Metadata:re,OfflineQuery:ie,PrivateKey:ae,PrivateKeyCiphertext:se,Program:de,ProgramManager:le,ProvingKey:fe,RecordCiphertext:be,RecordPlaintext:ye,Signature:ve,Transaction:Pe,VerifyingKey:Ke,ViewKey:Te,default:x,initSync:F,initThreadPool:k,runRayonThread:P,verifyFunctionExecution:h});const Ee="assets/aleo_wasm.wasm";const{initThreadPool:Ve,Address:Re,Execution:Fe,ExecutionResponse:xe,Field:Ce,Metadata:Ae,OfflineQuery:Be,Private:Ue,PrivateKey:Oe,PrivateKeyCiphertext:ze,Program:Ie,ProvingKey:Ne,RecordCiphertext:je,RecordPlaintext:$e,ProgramManager:Me,Signature:De,Transaction:Le,ViewKey:We,VerifyingKey:qe,verifyFunctionExecution:He}=await(async(e={})=>{let{importHook:t,serverPath:r,initializeHook:n}=e,i=Ee;return null!=r&&(i=r+/[^\/\\]*$/.exec(i)[0]),null!=t&&(i=t(i)),null!=n?await n(x,i):await x(i),C})({importHook:()=>new URL(r(5934),r.b)});async function A(e){null==e&&(e=navigator.hardwareConcurrency),console.info(`Spawning ${e} threads`),await Ve(new URL(r(2583),r.b),e)}n()}catch(Xe){n(Xe)}}),1)},6891:(e,t,r)=>{r.d(t,{Ud:()=>l});const n=Symbol("Comlink.proxy"),i=Symbol("Comlink.endpoint"),_=Symbol("Comlink.releaseProxy"),a=Symbol("Comlink.finalizer"),o=Symbol("Comlink.thrown"),s=e=>"object"==typeof e&&null!==e||"function"==typeof e,c=new Map([["proxy",{canHandle:e=>s(e)&&e[n],serialize(e){const{port1:t,port2:r}=new MessageChannel;return d(e,t),[r,[r]]},deserialize:e=>(e.start(),l(e))}],["throw",{canHandle:e=>s(e)&&o in e,serialize({value:e}){let t;return t=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[t,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function d(e,t=globalThis,r=["*"]){t.addEventListener("message",(function i(_){if(!_||!_.data)return;if(!function(e,t){for(const r of e){if(t===r||"*"===r)return!0;if(r instanceof RegExp&&r.test(t))return!0}return!1}(r,_.origin))return void console.warn(`Invalid origin '${_.origin}' for comlink proxy`);const{id:s,type:c,path:l}=Object.assign({path:[]},_.data),u=(_.data.argumentList||[]).map(m);let f;try{const t=l.slice(0,-1).reduce(((e,t)=>e[t]),e),r=l.reduce(((e,t)=>e[t]),e);switch(c){case"GET":f=r;break;case"SET":t[l.slice(-1)[0]]=m(_.data.value),f=!0;break;case"APPLY":f=r.apply(t,u);break;case"CONSTRUCT":f=function(e){return Object.assign(e,{[n]:!0})}(new r(...u));break;case"ENDPOINT":{const{port1:t,port2:r}=new MessageChannel;d(e,r),f=function(e,t){return h.set(e,t),e}(t,[t])}break;case"RELEASE":f=void 0;break;default:return}}catch(e){f={value:e,[o]:0}}Promise.resolve(f).catch((e=>({value:e,[o]:0}))).then((r=>{const[n,_]=v(r);t.postMessage(Object.assign(Object.assign({},n),{id:s}),_),"RELEASE"===c&&(t.removeEventListener("message",i),g(t),a in e&&"function"==typeof e[a]&&e[a]())})).catch((e=>{const[r,n]=v({value:new TypeError("Unserializable return value"),[o]:0});t.postMessage(Object.assign(Object.assign({},r),{id:s}),n)}))})),t.start&&t.start()}function g(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function l(e,t){return p(e,[],t)}function u(e){if(e)throw new Error("Proxy has been released and is not useable")}function f(e){return P(e,{type:"RELEASE"}).then((()=>{g(e)}))}const w=new WeakMap,b="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const t=(w.get(e)||0)-1;w.set(e,t),0===t&&f(e)}));function p(e,t=[],r=function(){}){let n=!1;const a=new Proxy(r,{get(r,i){if(u(n),i===_)return()=>{!function(e){b&&b.unregister(e)}(a),f(e),n=!0};if("then"===i){if(0===t.length)return{then:()=>a};const r=P(e,{type:"GET",path:t.map((e=>e.toString()))}).then(m);return r.then.bind(r)}return p(e,[...t,i])},set(r,i,_){u(n);const[a,o]=v(_);return P(e,{type:"SET",path:[...t,i].map((e=>e.toString())),value:a},o).then(m)},apply(r,_,a){u(n);const o=t[t.length-1];if(o===i)return P(e,{type:"ENDPOINT"}).then(m);if("bind"===o)return p(e,t.slice(0,-1));const[s,c]=y(a);return P(e,{type:"APPLY",path:t.map((e=>e.toString())),argumentList:s},c).then(m)},construct(r,i){u(n);const[_,a]=y(i);return P(e,{type:"CONSTRUCT",path:t.map((e=>e.toString())),argumentList:_},a).then(m)}});return function(e,t){const r=(w.get(t)||0)+1;w.set(t,r),b&&b.register(e,t,e)}(a,e),a}function y(e){const t=e.map(v);return[t.map((e=>e[0])),(r=t.map((e=>e[1])),Array.prototype.concat.apply([],r))];var r}const h=new WeakMap;function v(e){for(const[t,r]of c)if(r.canHandle(e)){const[n,i]=r.serialize(e);return[{type:"HANDLER",name:t,value:n},i]}return[{type:"RAW",value:e},h.get(e)||[]]}function m(e){switch(e.type){case"HANDLER":return c.get(e.name).deserialize(e.value);case"RAW":return e.value}}function P(e,t,r){return new Promise((n=>{const i=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-");e.addEventListener("message",(function t(r){r.data&&r.data.id&&r.data.id===i&&(e.removeEventListener("message",t),n(r.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:i},t),r)}))}}}]); -//# sourceMappingURL=52.bundle.js.map \ No newline at end of file diff --git a/52.bundle.js.LICENSE.txt b/52.bundle.js.LICENSE.txt deleted file mode 100644 index 479a8e58b..000000000 --- a/52.bundle.js.LICENSE.txt +++ /dev/null @@ -1,5 +0,0 @@ -/** - * @license - * Copyright 2019 Google LLC - * SPDX-License-Identifier: Apache-2.0 - */ diff --git a/52.bundle.js.map b/52.bundle.js.map deleted file mode 100644 index 03a99f3c7..000000000 --- a/52.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"52.bundle.js","mappings":";0tCA2CaA,EACXC,YACAC,SACAC,SAEAC,WAAAA,CAAYC,EAAuB,CAAC,GAClC,IACEC,KAAKL,YAAcK,KAAKC,qBAAqBF,GAC7C,MAAOG,GAEP,MADAC,QAAQC,MAAM,kBAAmBF,GAC3B,IAAIG,MAAM,mBAElBL,KAAKJ,SAAWU,EAAAA,GAAQC,iBAAiBP,KAAKL,aAC9CK,KAAKH,SAAWW,EAAAA,GAAQD,iBAAiBP,KAAKL,aAazC,qBAAOc,CAAeC,EAA2CC,GACtE,IACED,EAAoC,iBAAfA,EAA2BE,EAAAA,GAAqBC,WAAWH,GAAcA,EAC9F,MAAMf,EAAcmB,EAAAA,GAAWC,yBAAyBL,EAAYC,GACpE,OAAO,IAAIjB,EAAQ,CAAEsB,WAAYrB,EAAYsB,cAC7C,MAAMf,GACN,MAAM,IAAIG,MAAM,yCAIZJ,oBAAAA,CAAqBF,GAC3B,OAAIA,EAAOm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C,EAAQlE,UAAUv6B,GAC3D,MAAO,CACH,CACIX,KAAM,UACN8D,OACAnD,MAAO0+B,GAEXpC,EAER,CAEJ,MAAO,CACH,CACIj9B,KAAM,MACNW,SAEJm8B,EAAcz/B,IAAIsD,IAAU,GAEpC,CACA,SAAS27B,EAAc37B,GACnB,OAAQA,EAAMX,MACV,IAAK,UACD,OAAOg7B,EAAiB39B,IAAIsD,EAAMmD,MAAMy3B,YAAY56B,EAAMA,OAC9D,IAAK,MACD,OAAOA,EAAMA,MAEzB,CACA,SAASm9B,EAAuBnC,EAAI2D,EAAKzC,GACrC,OAAO,IAAI3yB,SAASC,IAChB,MAAMhH,EAeH,IAAIrE,MAAM,GACZoW,KAAK,GACLtY,KAAI,IAAMyV,KAAKktB,MAAMltB,KAAKmtB,SAAWC,OAAOC,kBAAkBrjC,SAAS,MACvE6L,KAAK,KAjBNyzB,EAAGlnB,iBAAiB,WAAW,SAASjU,EAAEs7B,GACjCA,EAAGv3B,MAASu3B,EAAGv3B,KAAKpB,IAAM24B,EAAGv3B,KAAKpB,KAAOA,IAG9Cw4B,EAAGwB,oBAAoB,UAAW38B,GAClC2J,EAAQ2xB,EAAGv3B,MACf,IACIo3B,EAAG58B,OACH48B,EAAG58B,QAEP48B,EAAG5mB,YAAYpR,OAAOC,OAAO,CAAET,MAAMm8B,GAAMzC,EAAU,GAE7D","sources":["webpack://aleo-website/../src/account.ts","webpack://aleo-website/../src/utils.ts","webpack://aleo-website/../src/network-client.ts","webpack://aleo-website/../src/function-key-provider.ts","webpack://aleo-website/../src/offline-key-provider.ts","webpack://aleo-website/../src/record-provider.ts","webpack://aleo-website/../src/managed-worker.ts","webpack://aleo-website/../src/program-manager.ts","webpack://aleo-website/../src/index.ts","webpack://aleo-website/wasm.js","webpack://aleo-website/../js/index.js","webpack://aleo-website/../node_modules/comlink/dist/esm/comlink.mjs"],"sourcesContent":["import {\n Address,\n PrivateKey,\n Signature,\n ViewKey,\n PrivateKeyCiphertext,\n RecordCiphertext,\n} from \"./index\";\n\ninterface AccountParam {\n privateKey?: string;\n seed?: Uint8Array;\n}\n\n/**\n * Key Management class. Enables the creation of a new Aleo Account, importation of an existing account from\n * an existing private key or seed, and message signing and verification functionality.\n *\n * An Aleo Account is generated from a randomly generated seed (number) from which an account private key, view key,\n * and a public account address are derived. The private key lies at the root of an Aleo account. It is a highly\n * sensitive secret and should be protected as it allows for creation of Aleo Program executions and arbitrary value\n * transfers. The View Key allows for decryption of a user's activity on the blockchain. The Address is the public\n * address to which other users of Aleo can send Aleo credits and other records to. This class should only be used\n * environments where the safety of the underlying key material can be assured.\n *\n * @example\n * // Create a new account\n * const myRandomAccount = new Account();\n *\n * // Create an account from a randomly generated seed\n * const seed = new Uint8Array([94, 91, 52, 251, 240, 230, 226, 35, 117, 253, 224, 210, 175, 13, 205, 120, 155, 214, 7, 169, 66, 62, 206, 50, 188, 40, 29, 122, 40, 250, 54, 18]);\n * const mySeededAccount = new Account({seed: seed});\n *\n * // Create an account from an existing private key\n * const myExistingAccount = new Account({privateKey: 'myExistingPrivateKey'})\n *\n * // Sign a message\n * const hello_world = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * const signature = myRandomAccount.sign(hello_world)\n *\n * // Verify a signature\n * myRandomAccount.verify(hello_world, signature)\n */\nexport class Account {\n _privateKey: PrivateKey;\n _viewKey: ViewKey;\n _address: Address;\n\n constructor(params: AccountParam = {}) {\n try {\n this._privateKey = this.privateKeyFromParams(params);\n } catch (e) {\n console.error(\"Wrong parameter\", e);\n throw new Error(\"Wrong Parameter\");\n }\n this._viewKey = ViewKey.from_private_key(this._privateKey);\n this._address = Address.from_private_key(this._privateKey);\n }\n\n /**\n * Attempts to create an account from a private key ciphertext\n * @param {PrivateKeyCiphertext | string} ciphertext\n * @param {string} password\n * @returns {PrivateKey | Error}\n *\n * @example\n * const ciphertext = PrivateKey.newEncrypted(\"password\");\n * const account = Account.fromCiphertext(ciphertext, \"password\");\n */\n public static fromCiphertext(ciphertext: PrivateKeyCiphertext | string, password: string) {\n try {\n ciphertext = (typeof ciphertext === \"string\") ? PrivateKeyCiphertext.fromString(ciphertext) : ciphertext;\n const _privateKey = PrivateKey.fromPrivateKeyCiphertext(ciphertext, password);\n return new Account({ privateKey: _privateKey.to_string() });\n } catch(e) {\n throw new Error(\"Wrong password or invalid ciphertext\");\n }\n }\n\n private privateKeyFromParams(params: AccountParam) {\n if (params.seed) {\n return PrivateKey.from_seed_unchecked(params.seed);\n }\n if (params.privateKey) {\n return PrivateKey.from_string(params.privateKey);\n }\n return new PrivateKey();\n }\n\n privateKey() {\n return this._privateKey;\n }\n\n viewKey() {\n return this._viewKey;\n }\n\n address() {\n return this._address;\n }\n\n toString() {\n return this.address().to_string()\n }\n\n /**\n * Encrypt the account's private key with a password\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n *\n * @example\n * const account = new Account();\n * const ciphertext = account.encryptAccount(\"password\");\n */\n encryptAccount(password: string) {\n return this._privateKey.toCiphertext(password);\n }\n\n /**\n * Decrypts a Record in ciphertext form into plaintext\n * @param {string} ciphertext\n * @returns {Record}\n *\n * @example\n * const account = new Account();\n * const record = account.decryptRecord(\"record1ciphertext\");\n */\n decryptRecord(ciphertext: string) {\n return this._viewKey.decrypt(ciphertext);\n }\n\n /**\n * Decrypts an array of Records in ciphertext form into plaintext\n * @param {string[]} ciphertexts\n * @returns {Record[]}\n *\n * @example\n * const account = new Account();\n * const record = account.decryptRecords([\"record1ciphertext\", \"record2ciphertext\"]);\n */\n decryptRecords(ciphertexts: string[]) {\n return ciphertexts.map((ciphertext) => this._viewKey.decrypt(ciphertext));\n }\n\n /**\n * Determines whether the account owns a ciphertext record\n * @param {RecordCipherText | string} ciphertext\n * @returns {boolean}\n *\n * @example\n * // Create a connection to the Aleo network and an account\n * const connection = new NodeConnection(\"vm.aleo.org/api\");\n * const account = Account.fromCiphertext(\"ciphertext\", \"password\");\n *\n * // Get a record from the network\n * const record = connection.getBlock(1234);\n * const recordCipherText = record.transactions[0].execution.transitions[0].id;\n *\n * // Check if the account owns the record\n * if account.ownsRecord(recordCipherText) {\n * // Then one can do something like:\n * // Decrypt the record and check if it's spent\n * // Store the record in a local database\n * // Etc.\n * }\n */\n ownsRecordCiphertext(ciphertext: RecordCiphertext | string) {\n if (typeof ciphertext === 'string') {\n try {\n const ciphertextObject = RecordCiphertext.fromString(ciphertext);\n return ciphertextObject.isOwner(this._viewKey);\n }\n catch (e) {\n return false;\n }\n }\n else {\n return ciphertext.isOwner(this._viewKey);\n }\n }\n\n /**\n * Signs a message with the account's private key.\n * Returns a Signature.\n *\n * @param {Uint8Array} message\n * @returns {Signature}\n *\n * @example\n * const account = new Account();\n * const message = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * account.sign(message);\n */\n sign(message: Uint8Array) {\n return this._privateKey.sign(message);\n }\n\n /**\n * Verifies the Signature on a message.\n *\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n *\n * @example\n * const account = new Account();\n * const message = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * const signature = account.sign(message);\n * account.verify(message, signature);\n */\n verify(message: Uint8Array, signature: Signature) {\n return this._address.verify(message, signature);\n }\n\n}\n","export async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./index\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/testnet\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/testnet\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n return await response.json();\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise | Error> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n if (!(blocks instanceof Error)) {\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = \"Error fetching blocks between \" + start + \" and \" + end + \".\"\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return await this.fetchData(\"/latest/height\");\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error) {\n throw logAndThrow(\"Error fetching program imports: \" + error)\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error) {\n throw new Error(\"Error fetching program imports with error: \" + error);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise | Error> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise | Error> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string | Error} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n return await response.json();\n\n } catch (error) {\n throw new Error(`Error posting transaction. Aleo network response: ${(error as Error).message}`);\n }\n } catch (error) {\n throw new Error(`Error posting transaction: No response received: ${(error as Error).message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./index\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error) {\n throw new Error(\"Error fetching data.\" + error);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair | Error} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair | Error {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n return new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n if (!(key instanceof Error)) {\n return this.fetchCreditsKeys(key);\n }\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error) {\n throw new Error(`Error: fetching credits.aleo keys: ${error}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner) {\n return new Error(\"Invalid verifying key. Error: \" + inner);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n FunctionKeyProvider,\n KeySearchParams,\n FunctionKeyPair,\n CachedKeyPair,\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./index\";\n\n/**\n * Search parameters for the offline key provider. This class implements the KeySearchParams interface and includes\n * a convenience method for creating a new instance of this class for each function of the credits.aleo program.\n *\n * @example\n * // If storing a key for a custom program function\n * offlineSearchParams = new OfflineSearchParams(\"myprogram.aleo/myfunction\");\n *\n * // If storing a key for a credits.aleo program function\n * bondPublicKeyParams = OfflineSearchParams.bondPublicKeyParams();\n */\nclass OfflineSearchParams implements KeySearchParams {\n cacheKey: string | undefined;\n verifyCreditsKeys: boolean | undefined;\n\n /**\n * Create a new OfflineSearchParams instance.\n *\n * @param {string} cacheKey - Key used to store the local function proving & verifying keys. This should be stored\n * under the naming convention \"programName/functionName\" (i.e. \"myprogram.aleo/myfunction\")\n * @param {boolean} verifyCreditsKeys - Whether to verify the keys against the credits.aleo program,\n * defaults to false, but should be set to true if using keys from the credits.aleo program\n */\n constructor(cacheKey: string, verifyCreditsKeys = false) {\n this.cacheKey = cacheKey;\n this.verifyCreditsKeys = verifyCreditsKeys;\n }\n\n /**\n * Create a new OfflineSearchParams instance for the bond_public function of the credits.aleo program.\n */\n static bondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.bond_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the bond_validator function of the credits.aleo program.\n */\n static bondValidatorKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.bond_validator.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the claim_unbond_public function of the\n */\n static claimUnbondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.claim_unbond_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the fee_private function of the credits.aleo program.\n */\n static feePrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.fee_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the fee_public function of the credits.aleo program.\n */\n static feePublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.fee_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the inclusion prover function.\n */\n static inclusionKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.inclusion.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the join function of the credits.aleo program.\n */\n static joinKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.join.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the set_validator_state function of the credits.aleo program.\n */\n static setValidatorStateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.set_validator_state.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the split function of the credits.aleo program.\n */\n static splitKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.split.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_private function of the credits.aleo program.\n */\n static transferPrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_private_to_public function of the credits.aleo program.\n */\n static transferPrivateToPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public function of the credits.aleo program.\n */\n static transferPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public_as_signer function of the credits.aleo program.\n */\n static transferPublicAsSignerKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public_as_signer.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public_to_private function of the credits.aleo program.\n */\n static transferPublicToPrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the unbond_public function of the credits.aleo program.\n */\n static unbondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.unbond_public.locator, true);\n }\n}\n\n/**\n * A key provider meant for building transactions offline on devices such as hardware wallets. This key provider is not\n * able to contact the internet for key material and instead relies on the user to insert Aleo function proving &\n * verifying keys from local storage prior to usage.\n *\n * @example\n * // Create an offline program manager\n * const programManager = new ProgramManager();\n *\n * // Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * // Create the proving keys from the key bytes on the offline machine\n * console.log(\"Creating proving keys from local key files\");\n * const program = \"program hello_hello.aleo; function hello: input r0 as u32.public; input r1 as u32.private; add r0 r1 into r2; output r2 as u32.private;\";\n * const myFunctionProver = await getLocalKey(\"/path/to/my/function/hello_hello.prover\");\n * const myFunctionVerifier = await getLocalKey(\"/path/to/my/function/hello_hello.verifier\");\n * const feePublicProvingKeyBytes = await getLocalKey(\"/path/to/credits.aleo/feePublic.prover\");\n *\n * myFunctionProvingKey = ProvingKey.fromBytes(myFunctionProver);\n * myFunctionVerifyingKey = VerifyingKey.fromBytes(myFunctionVerifier);\n * const feePublicProvingKey = ProvingKey.fromBytes(feePublicKeyBytes);\n *\n * // Create an offline key provider\n * console.log(\"Creating offline key provider\");\n * const offlineKeyProvider = new OfflineKeyProvider();\n *\n * // Cache the keys\n * // Cache the proving and verifying keys for the custom hello function\n * OfflineKeyProvider.cacheKeys(\"hello_hello.aleo/hello\", myFunctionProvingKey, myFunctionVerifyingKey);\n *\n * // Cache the proving key for the fee_public function (the verifying key is automatically cached)\n * OfflineKeyProvider.insertFeePublicKey(feePublicProvingKey);\n *\n * // Create an offline query using the latest state root in order to create the inclusion proof\n * const offlineQuery = new OfflineQuery(\"latestStateRoot\");\n *\n * // Insert the key provider into the program manager\n * programManager.setKeyProvider(offlineKeyProvider);\n *\n * // Create the offline search params\n * const offlineSearchParams = new OfflineSearchParams(\"hello_hello.aleo/hello\");\n *\n * // Create the offline transaction\n * const offlineExecuteTx = await this.buildExecutionTransaction(\"hello_hello.aleo\", \"hello\", 1, false, [\"5u32\", \"5u32\"], undefined, offlineSearchParams, undefined, undefined, undefined, undefined, offlineQuery, program);\n *\n * // Broadcast the transaction later on a machine with internet access\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const txId = await networkClient.broadcastTransaction(offlineExecuteTx);\n */\nclass OfflineKeyProvider implements FunctionKeyProvider {\n cache: Map;\n\n constructor() {\n this.cache = new Map();\n }\n\n /**\n * Get bond_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.bondPublicKeyParams());\n };\n\n /**\n * Get bond_validator function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondValidatorKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.bondValidatorKeyParams());\n };\n\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n };\n\n /**\n * Get unbond_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.claimUnbondPublicKeyParams());\n };\n\n /**\n * Get arbitrary function key from the offline key provider cache.\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * /// First cache the keys from local offline resources\n * const offlineKeyProvider = new OfflineKeyProvider();\n * const myFunctionVerifyingKey = VerifyingKey.fromString(\"verifier...\");\n * const myFunctionProvingKeyBytes = await readBinaryFile('./resources/myfunction.prover');\n * const myFunctionProvingKey = ProvingKey.fromBytes(myFunctionProvingKeyBytes);\n *\n * /// Cache the keys for future use with a memorable locator\n * offlineKeyProvider.cacheKeys(\"myprogram.aleo/myfunction\", [myFunctionProvingKey, myFunctionVerifyingKey]);\n *\n * /// When they're needed, retrieve the keys from the cache\n *\n * /// First create a search parameter object with the same locator used to cache the keys\n * const keyParams = new OfflineSearchParams(\"myprogram.aleo/myfunction\");\n *\n * /// Then retrieve the keys\n * const [myFunctionProver, myFunctionVerifier] = await offlineKeyProvider.functionKeys(keyParams);\n */\n functionKeys(params?: KeySearchParams): Promise {\n return new Promise((resolve, reject) => {\n if (params === undefined) {\n reject(new Error(\"No search parameters provided, cannot retrieve keys\"));\n } else {\n const keyId = params.cacheKey;\n const verifyCreditsKeys = params.verifyCreditsKeys;\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId) as CachedKeyPair;\n const provingKey = ProvingKey.fromBytes(provingKeyBytes);\n const verifyingKey = VerifyingKey.fromBytes(verifyingKeyBytes);\n if (verifyCreditsKeys) {\n const keysMatchExpected = this.verifyCreditsKeys(keyId, provingKey, verifyingKey)\n if (!keysMatchExpected) {\n reject (new Error(`Cached keys do not match expected keys for ${keyId}`));\n }\n }\n resolve([provingKey, verifyingKey]);\n } else {\n reject(new Error(\"Keys not found in cache for \" + keyId));\n }\n }\n });\n };\n\n /**\n * Determines if the keys for a given credits function match the expected keys.\n *\n * @returns {boolean} Whether the keys match the expected keys\n */\n verifyCreditsKeys(locator: string, provingKey: ProvingKey, verifyingKey: VerifyingKey): boolean {\n switch (locator) {\n case CREDITS_PROGRAM_KEYS.bond_public.locator:\n return provingKey.isBondPublicProver() && verifyingKey.isBondPublicVerifier();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.locator:\n return provingKey.isClaimUnbondPublicProver() && verifyingKey.isClaimUnbondPublicVerifier();\n case CREDITS_PROGRAM_KEYS.fee_private.locator:\n return provingKey.isFeePrivateProver() && verifyingKey.isFeePrivateVerifier();\n case CREDITS_PROGRAM_KEYS.fee_public.locator:\n return provingKey.isFeePublicProver() && verifyingKey.isFeePublicVerifier();\n case CREDITS_PROGRAM_KEYS.inclusion.locator:\n return provingKey.isInclusionProver() && verifyingKey.isInclusionVerifier();\n case CREDITS_PROGRAM_KEYS.join.locator:\n return provingKey.isJoinProver() && verifyingKey.isJoinVerifier();\n case CREDITS_PROGRAM_KEYS.set_validator_state.locator:\n return provingKey.isSetValidatorStateProver() && verifyingKey.isSetValidatorStateVerifier();\n case CREDITS_PROGRAM_KEYS.split.locator:\n return provingKey.isSplitProver() && verifyingKey.isSplitVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_private.locator:\n return provingKey.isTransferPrivateProver() && verifyingKey.isTransferPrivateVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator:\n return provingKey.isTransferPrivateToPublicProver() && verifyingKey.isTransferPrivateToPublicVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_public.locator:\n return provingKey.isTransferPublicProver() && verifyingKey.isTransferPublicVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator:\n return provingKey.isTransferPublicToPrivateProver() && verifyingKey.isTransferPublicToPrivateVerifier();\n case CREDITS_PROGRAM_KEYS.unbond_public.locator:\n return provingKey.isUnbondPublicProver() && verifyingKey.isUnbondPublicVerifier();\n default:\n return false;\n }\n }\n\n /**\n * Get fee_private function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.feePrivateKeyParams());\n };\n\n /**\n * Get fee_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.feePublicKeyParams());\n };\n\n /**\n * Get join function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.joinKeyParams());\n };\n\n /**\n * Get split function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.splitKeyParams());\n };\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program.\n *\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new OfflineKeyProvider\n * const offlineKeyProvider = new OfflineKeyProvider();\n *\n * // Cache the keys for future use with the official locator\n * const transferPublicProvingKeyBytes = await readBinaryFile('./resources/transfer_public.prover.a74565e');\n * const transferPublicProvingKey = ProvingKey.fromBytes(transferPublicProvingKeyBytes);\n *\n * // Cache the transfer_public keys for future use with the OfflinKeyProvider's convenience method for\n * // transfer_public (the verifying key will be cached automatically)\n * offlineKeyProvider.insertTransferPublicKeys(transferPublicProvingKey);\n *\n * /// When they're needed, retrieve the keys from the cache\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPrivateKeyParams());\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPrivateToPublicKeyParams());\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicKeyParams());\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicAsSignerKeyParams());\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicToPrivateKeyParams());\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n };\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async unBondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.unbondPublicKeyParams());\n };\n\n /**\n * Insert the proving and verifying keys for the bond_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for bond_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertBondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isBondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [provingKey.toBytes(), VerifyingKey.bondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for bond_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the claim_unbond_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for claim_unbond_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertClaimUnbondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isClaimUnbondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.claim_unbond_public.locator, [provingKey.toBytes(), VerifyingKey.claimUnbondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for claim_unbond_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the fee_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for fee_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertFeePrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isFeePrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.fee_private.locator, [provingKey.toBytes(), VerifyingKey.feePrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for fee_private\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the fee_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for fee_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertFeePublicKeys(provingKey: ProvingKey) {\n if (provingKey.isFeePublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.fee_public.locator, [provingKey.toBytes(), VerifyingKey.feePublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for fee_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the join function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for join before inserting them into the cache.\n *\n * @param provingKey\n */\n insertJoinKeys(provingKey: ProvingKey) {\n if (provingKey.isJoinProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.join.locator, [provingKey.toBytes(), VerifyingKey.joinVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for join\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the set_validator_state function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for set_validator_state before inserting them into the cache.\n *\n * @param provingKey\n */\n insertSetValidatorStateKeys(provingKey: ProvingKey) {\n if (provingKey.isSetValidatorStateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.set_validator_state.locator, [provingKey.toBytes(), VerifyingKey.setValidatorStateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for set_validator_state\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the split function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for split before inserting them into the cache.\n *\n * @param provingKey\n */\n insertSplitKeys(provingKey: ProvingKey) {\n if (provingKey.isSplitProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.split.locator, [provingKey.toBytes(), VerifyingKey.splitVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for split\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_private.locator, [provingKey.toBytes(), VerifyingKey.transferPrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_private\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_private_to_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_private_to_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPrivateToPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPrivateToPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator, [provingKey.toBytes(), VerifyingKey.transferPrivateToPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_private_to_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_public.locator, [provingKey.toBytes(), VerifyingKey.transferPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_public_to_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_public_to_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPublicToPrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPublicToPrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator, [provingKey.toBytes(), VerifyingKey.transferPublicToPrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_public_to_private\");\n }\n }\n\n insertUnbondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isUnbondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.unbond_public.locator, [provingKey.toBytes(), VerifyingKey.unbondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for unbond_public\");\n }\n }\n}\n\n\nexport {OfflineKeyProvider, OfflineSearchParams}\n","import { logAndThrow, RecordPlaintext } from \"./index\";\nimport { Account } from \"./account\";\nimport { AleoNetworkClient } from \"./network-client\";\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface RecordSearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * Interface for a record provider. A record provider is used to find records for use in deployment and execution\n * transactions on the Aleo Network. A default implementation is provided by the NetworkRecordProvider class. However,\n * a custom implementation can be provided (say if records are synced locally to a database from the network) by\n * implementing this interface.\n */\ninterface RecordProvider {\n account: Account\n\n /**\n * Find a credits.aleo record with a given number of microcredits from the chosen provider\n *\n * @param {number} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // A class implementing record provider can be used to find a record with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, its nonce should be added to the nonces array so that it is not\n * // found again if a subsequent search is performed\n * const record2 = await recordProvider.findCreditsRecord(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n findCreditsRecord(microcredits: number, unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find a list of credit.aleo records with a given number of microcredits from the chosen provider\n *\n * @param {number} microcreditAmounts A list of separate microcredit amounts to search for (e.g. [5000, 100000])\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} A list of records with a value greater or equal to the amounts specified if such records exist, otherwise an error\n *\n * @example\n * // A class implementing record provider can be used to find a record with a given number of microcredits\n * const records = await recordProvider.findCreditsRecords([5000, 5000], true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces array so that it is not\n * // found again if a subsequent search is performed\n * const nonces = [];\n * records.forEach(record => { nonces.push(record.nonce()) });\n * const records2 = await recordProvider.findCreditsRecord(5000, true, nonces);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n findCreditsRecords(microcreditAmounts: number[], unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find an arbitrary record\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // The RecordSearchParams interface can be used to create parameters for custom record searches which can then\n * // be passed to the record provider. An example of how this would be done for the credits.aleo program is shown\n * // below.\n *\n * class CustomRecordSearch implements RecordSearchParams {\n * startHeight: number;\n * endHeight: number;\n * amount: number;\n * program: string;\n * recordName: string;\n * constructor(startHeight: number, endHeight: number, credits: number, maxRecords: number, programName: string, recordName: string) {\n * this.startHeight = startHeight;\n * this.endHeight = endHeight;\n * this.amount = amount;\n * this.program = programName;\n * this.recordName = recordName;\n * }\n * }\n *\n * const params = new CustomRecordSearch(0, 100, 5000, \"credits.aleo\", \"credits\");\n *\n * const record = await recordProvider.findRecord(true, [], params);\n */\n findRecord(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find multiple records from arbitrary programs\n *\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * // The RecordSearchParams interface can be used to create parameters for custom record searches which can then\n * // be passed to the record provider. An example of how this would be done for the credits.aleo program is shown\n * // below.\n *\n * class CustomRecordSearch implements RecordSearchParams {\n * startHeight: number;\n * endHeight: number;\n * amount: number;\n * maxRecords: number;\n * programName: string;\n * recordName: string;\n * constructor(startHeight: number, endHeight: number, credits: number, maxRecords: number, programName: string, recordName: string) {\n * this.startHeight = startHeight;\n * this.endHeight = endHeight;\n * this.amount = amount;\n * this.maxRecords = maxRecords;\n * this.programName = programName;\n * this.recordName = recordName;\n * }\n * }\n *\n * const params = new CustomRecordSearch(0, 100, 5000, 2, \"credits.aleo\", \"credits\");\n * const records = await recordProvider.findRecord(true, [], params);\n */\n findRecords(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n}\n\n/**\n * A record provider implementation that uses the official Aleo API to find records for usage in program execution and\n * deployment, wallet functionality, and other use cases.\n */\nclass NetworkRecordProvider implements RecordProvider {\n account: Account;\n networkClient: AleoNetworkClient;\n constructor(account: Account, networkClient: AleoNetworkClient) {\n this.account = account;\n this.networkClient = networkClient;\n }\n\n /**\n * Set the account used to search for records\n *\n * @param {Account} account The account to use for searching for records\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Find a list of credit records with a given number of microcredits by via the official Aleo API\n *\n * @param {number[]} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces parameter so that it is not\n * // found again if a subsequent search is performed\n * const records = await recordProvider.findCreditsRecords(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * */\n async findCreditsRecords(microcredits: number[], unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n let startHeight = 0;\n let endHeight = 0;\n\n if (searchParameters) {\n if (\"startHeight\" in searchParameters && typeof searchParameters[\"endHeight\"] == \"number\") {\n startHeight = searchParameters[\"startHeight\"];\n }\n\n if (\"endHeight\" in searchParameters && typeof searchParameters[\"endHeight\"] == \"number\") {\n endHeight = searchParameters[\"endHeight\"];\n }\n }\n\n // If the end height is not specified, use the current block height\n if (endHeight == 0) {\n const end = await this.networkClient.getLatestHeight();\n if (end instanceof Error) {\n throw logAndThrow(\"Unable to get current block height from the network\")\n }\n endHeight = end;\n }\n\n // If the start height is greater than the end height, throw an error\n if (startHeight >= endHeight) {\n throw logAndThrow(\"Start height must be less than end height\");\n }\n\n return await this.networkClient.findUnspentRecords(startHeight, endHeight, this.account.privateKey(), microcredits, undefined, nonces);\n }\n\n /**\n * Find a credit record with a given number of microcredits by via the official Aleo API\n *\n * @param {number} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces parameter so that it is not\n * // found again if a subsequent search is performed\n * const records = await recordProvider.findCreditsRecords(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n async findCreditsRecord(microcredits: number, unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n const records = await this.findCreditsRecords([microcredits], unspent, nonces, searchParameters);\n if (!(records instanceof Error) && records.length > 0) {\n return records[0];\n }\n console.error(\"Record not found with error:\", records);\n return new Error(\"Record not found\");\n }\n\n /**\n * Find an arbitrary record. WARNING: This function is not implemented yet and will throw an error.\n */\n async findRecord(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n throw new Error(\"Method not implemented.\");\n }\n\n /**\n * Find multiple arbitrary records. WARNING: This function is not implemented yet and will throw an error.\n */\n async findRecords(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n throw new Error(\"Method not implemented.\");\n }\n\n}\n\n/**\n * BlockHeightSearch is a RecordSearchParams implementation that allows for searching for records within a given\n * block height range.\n *\n * @example\n * // Create a new BlockHeightSearch\n * const params = new BlockHeightSearch(89995, 99995);\n *\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits and the block height search\n * // can be used to find records within a given block height range\n * const record = await recordProvider.findCreditsRecord(5000, true, [], params);\n *\n */\nclass BlockHeightSearch implements RecordSearchParams {\n startHeight: number;\n endHeight: number;\n constructor(startHeight: number, endHeight: number) {\n this.startHeight = startHeight;\n this.endHeight = endHeight;\n }\n}\n\nexport { BlockHeightSearch, NetworkRecordProvider, RecordProvider, RecordSearchParams};\n","// Experimental example where SDK manages worker\n\nimport { wrap } from \"comlink\";\nimport { WorkerAPI } from './worker';\n\nlet singletonWorker: WorkerAPI | null = null;\n\nconst createAleoWorker = (): WorkerAPI => {\n if (!singletonWorker) {\n const worker = new Worker(new URL(\"worker.js\", import.meta.url), {\n type: \"module\",\n });\n singletonWorker = wrap(worker);\n }\n return singletonWorker;\n};\n\nexport { createAleoWorker };","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./index\";\nimport {Execution} from \"@provablehq/wasm/dist/crates/aleo_wasm\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.aleo.org/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n \n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string | Error} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e) {\n throw logAndThrow(`Error validating program: ${e}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e) {\n throw logAndThrow(`Error finding ${programName}. Network response: '${e}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e) {\n throw logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e) {\n throw logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e) {\n throw logAndThrow(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program | Error} The program object\n */\n createProgramFromSource(program: string): Program | Error {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string | Error {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import {VerifyingKey, Metadata} from \"@provablehq/wasm\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key | Error {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n return new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): Error {\n console.error(message);\n throw message;\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n","function spawnWorker(url, module, memory, address) {\n return new Promise((resolve) => {\n const worker = new Worker(url, {\n type: \"module\",\n });\n\n worker.addEventListener(\"message\", (event) => {\n // This is needed in Node to wait one extra tick, so that way\n // the Worker can fully initialize before we return.\n setTimeout(() => {\n resolve(worker);\n\n // When running in Node, this allows the process to exit\n // even though the Worker is still running.\n if (worker.unref) {\n worker.unref();\n }\n }, 0);\n }, {\n capture: true,\n once: true,\n });\n\n worker.postMessage({\n module,\n memory,\n address,\n });\n });\n }\n\nlet wasm;\n\nconst heap = new Array(128).fill(undefined);\n\nheap.push(undefined, null, true, false);\n\nfunction getObject(idx) { return heap[idx]; }\n\nlet heap_next = heap.length;\n\nfunction dropObject(idx) {\n if (idx < 132) return;\n heap[idx] = heap_next;\n heap_next = idx;\n}\n\nfunction takeObject(idx) {\n const ret = getObject(idx);\n dropObject(idx);\n return ret;\n}\n\nconst cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );\n\nif (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); }\nlet cachedUint8Memory0 = null;\n\nfunction getUint8Memory0() {\n if (cachedUint8Memory0 === null || cachedUint8Memory0.buffer !== wasm.memory.buffer) {\n cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);\n }\n return cachedUint8Memory0;\n}\n\nfunction getStringFromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return cachedTextDecoder.decode(getUint8Memory0().slice(ptr, ptr + len));\n}\n\nfunction addHeapObject(obj) {\n if (heap_next === heap.length) heap.push(heap.length + 1);\n const idx = heap_next;\n heap_next = heap[idx];\n\n heap[idx] = obj;\n return idx;\n}\n\nlet WASM_VECTOR_LEN = 0;\n\nconst cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );\n\nconst encodeString = function (arg, view) {\n const buf = cachedTextEncoder.encode(arg);\n view.set(buf);\n return {\n read: arg.length,\n written: buf.length\n };\n};\n\nfunction passStringToWasm0(arg, malloc, realloc) {\n\n if (realloc === undefined) {\n const buf = cachedTextEncoder.encode(arg);\n const ptr = malloc(buf.length, 1) >>> 0;\n getUint8Memory0().subarray(ptr, ptr + buf.length).set(buf);\n WASM_VECTOR_LEN = buf.length;\n return ptr;\n }\n\n let len = arg.length;\n let ptr = malloc(len, 1) >>> 0;\n\n const mem = getUint8Memory0();\n\n let offset = 0;\n\n for (; offset < len; offset++) {\n const code = arg.charCodeAt(offset);\n if (code > 0x7F) break;\n mem[ptr + offset] = code;\n }\n\n if (offset !== len) {\n if (offset !== 0) {\n arg = arg.slice(offset);\n }\n ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;\n const view = getUint8Memory0().subarray(ptr + offset, ptr + len);\n const ret = encodeString(arg, view);\n\n offset += ret.written;\n ptr = realloc(ptr, len, offset, 1) >>> 0;\n }\n\n WASM_VECTOR_LEN = offset;\n return ptr;\n}\n\nfunction isLikeNone(x) {\n return x === undefined || x === null;\n}\n\nlet cachedInt32Memory0 = null;\n\nfunction getInt32Memory0() {\n if (cachedInt32Memory0 === null || cachedInt32Memory0.buffer !== wasm.memory.buffer) {\n cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);\n }\n return cachedInt32Memory0;\n}\n\nfunction debugString(val) {\n // primitive types\n const type = typeof val;\n if (type == 'number' || type == 'boolean' || val == null) {\n return `${val}`;\n }\n if (type == 'string') {\n return `\"${val}\"`;\n }\n if (type == 'symbol') {\n const description = val.description;\n if (description == null) {\n return 'Symbol';\n } else {\n return `Symbol(${description})`;\n }\n }\n if (type == 'function') {\n const name = val.name;\n if (typeof name == 'string' && name.length > 0) {\n return `Function(${name})`;\n } else {\n return 'Function';\n }\n }\n // objects\n if (Array.isArray(val)) {\n const length = val.length;\n let debug = '[';\n if (length > 0) {\n debug += debugString(val[0]);\n }\n for(let i = 1; i < length; i++) {\n debug += ', ' + debugString(val[i]);\n }\n debug += ']';\n return debug;\n }\n // Test for built-in\n const builtInMatches = /\\[object ([^\\]]+)\\]/.exec(toString.call(val));\n let className;\n if (builtInMatches.length > 1) {\n className = builtInMatches[1];\n } else {\n // Failed to match the standard '[object ClassName]'\n return toString.call(val);\n }\n if (className == 'Object') {\n // we're a user defined class or Object\n // JSON.stringify avoids problems with cycles, and is generally much\n // easier than looping through ownProperties of `val`.\n try {\n return 'Object(' + JSON.stringify(val) + ')';\n } catch (_) {\n return 'Object';\n }\n }\n // errors\n if (val instanceof Error) {\n return `${val.name}: ${val.message}\\n${val.stack}`;\n }\n // TODO we could test for more things here, like `Set`s and `Map`s.\n return className;\n}\n\nconst CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(state => {\n wasm.__wbindgen_export_3.get(state.dtor)(state.a, state.b);\n});\n\nfunction makeMutClosure(arg0, arg1, dtor, f) {\n const state = { a: arg0, b: arg1, cnt: 1, dtor };\n const real = (...args) => {\n // First up with a closure we increment the internal reference\n // count. This ensures that the Rust closure environment won't\n // be deallocated while we're invoking it.\n state.cnt++;\n const a = state.a;\n state.a = 0;\n try {\n return f(a, state.b, ...args);\n } finally {\n if (--state.cnt === 0) {\n wasm.__wbindgen_export_3.get(state.dtor)(a, state.b);\n CLOSURE_DTORS.unregister(state);\n } else {\n state.a = a;\n }\n }\n };\n real.original = state;\n CLOSURE_DTORS.register(real, state, state);\n return real;\n}\nfunction __wbg_adapter_34(arg0, arg1, arg2) {\n wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(arg0, arg1, addHeapObject(arg2));\n}\n\nfunction _assertClass(instance, klass) {\n if (!(instance instanceof klass)) {\n throw new Error(`expected instance of ${klass.name}`);\n }\n return instance.ptr;\n}\n\nfunction passArray8ToWasm0(arg, malloc) {\n const ptr = malloc(arg.length * 1, 1) >>> 0;\n getUint8Memory0().set(arg, ptr / 1);\n WASM_VECTOR_LEN = arg.length;\n return ptr;\n}\n/**\n* Verify an execution with a single function and a single transition. Executions with multiple\n* transitions or functions will fail to verify. Also, this does not verify that the state root of\n* the execution is included in the Aleo Network ledger.\n*\n* @param {Execution} execution The function execution to verify\n* @param {VerifyingKey} verifying_key The verifying key for the function\n* @param {Program} program The program that the function execution belongs to\n* @param {String} function_id The name of the function that was executed\n* @returns {boolean} True if the execution is valid, false otherwise\n* @param {Execution} execution\n* @param {VerifyingKey} verifying_key\n* @param {Program} program\n* @param {string} function_id\n* @returns {boolean}\n*/\nfunction verifyFunctionExecution(execution, verifying_key, program, function_id) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(execution, Execution);\n _assertClass(verifying_key, VerifyingKey);\n _assertClass(program, Program);\n const ptr0 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyFunctionExecution(retptr, execution.__wbg_ptr, verifying_key.__wbg_ptr, program.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return r0 !== 0;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n}\n\nlet cachedBigInt64Memory0 = null;\n\nfunction getBigInt64Memory0() {\n if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.buffer !== wasm.memory.buffer) {\n cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);\n }\n return cachedBigInt64Memory0;\n}\n\nfunction getArrayU8FromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);\n}\n/**\n* @param {number} receiver\n*/\nfunction runRayonThread(receiver) {\n wasm.runRayonThread(receiver);\n}\n\n/**\n* @param {URL} url\n* @param {number} num_threads\n* @returns {Promise}\n*/\nfunction initThreadPool(url, num_threads) {\n const ret = wasm.initThreadPool(addHeapObject(url), num_threads);\n return takeObject(ret);\n}\n\nfunction handleError(f, args) {\n try {\n return f.apply(this, args);\n } catch (e) {\n wasm.__wbindgen_exn_store(addHeapObject(e));\n }\n}\nfunction __wbg_adapter_281(arg0, arg1, arg2, arg3) {\n wasm.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));\n}\n\nconst AddressFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_address_free(ptr >>> 0));\n/**\n* Public address of an Aleo account\n*/\nclass Address {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Address.prototype);\n obj.__wbg_ptr = ptr;\n AddressFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n AddressFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_address_free(ptr);\n }\n /**\n * Derive an Aleo address from a private key\n *\n * @param {PrivateKey} private_key The private key to derive the address from\n * @returns {Address} Address corresponding to the private key\n * @param {PrivateKey} private_key\n * @returns {Address}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.address_from_private_key(private_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Derive an Aleo address from a view key\n *\n * @param {ViewKey} view_key The view key to derive the address from\n * @returns {Address} Address corresponding to the view key\n * @param {ViewKey} view_key\n * @returns {Address}\n */\n static from_view_key(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.address_from_view_key(view_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Create an aleo address object from a string representation of an address\n *\n * @param {string} address String representation of an addressm\n * @returns {Address} Address\n * @param {string} address\n * @returns {Address}\n */\n static from_string(address) {\n const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.address_from_string(ptr0, len0);\n return Address.__wrap(ret);\n }\n /**\n * Get a string representation of an Aleo address object\n *\n * @param {Address} Address\n * @returns {string} String representation of the address\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.address_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Verify a signature for a message signed by the address\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {boolean} Boolean representing whether or not the signature is valid\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n */\n verify(message, signature) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n _assertClass(signature, Signature);\n const ret = wasm.address_verify(this.__wbg_ptr, ptr0, len0, signature.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst ExecutionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_execution_free(ptr >>> 0));\n/**\n* Execution of an Aleo program.\n*/\nclass Execution {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Execution.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_execution_free(ptr);\n }\n /**\n * Returns the string representation of the execution.\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.execution_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates an execution object from a string representation of an execution.\n * @param {string} execution\n * @returns {Execution}\n */\n static fromString(execution) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(execution, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.execution_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Execution.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ExecutionResponseFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_executionresponse_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo function execution response\n*\n* This object is returned by the execution of an Aleo function off-chain. It provides methods for\n* retrieving the outputs of the function execution.\n*/\nclass ExecutionResponse {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ExecutionResponse.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionResponseFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionResponseFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_executionresponse_free(ptr);\n }\n /**\n * Get the outputs of the executed function\n *\n * @returns {Array} Array of strings representing the outputs of the function\n * @returns {Array}\n */\n getOutputs() {\n const ret = wasm.executionresponse_getOutputs(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Returns the execution object if present, null if otherwise.\n *\n * @returns {Execution | undefined} The execution object if present, null if otherwise\n * @returns {Execution | undefined}\n */\n getExecution() {\n const ret = wasm.executionresponse_getExecution(this.__wbg_ptr);\n return ret === 0 ? undefined : Execution.__wrap(ret);\n }\n /**\n * Returns the program keys if present\n * @returns {KeyPair}\n */\n getKeys() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getKeys(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return KeyPair.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the proving_key if the proving key was cached in the Execution response.\n * Note the proving key is removed from the response object after the first call to this\n * function. Subsequent calls will return null.\n *\n * @returns {ProvingKey | undefined} The proving key\n * @returns {ProvingKey | undefined}\n */\n getProvingKey() {\n const ret = wasm.executionresponse_getProvingKey(this.__wbg_ptr);\n return ret === 0 ? undefined : ProvingKey.__wrap(ret);\n }\n /**\n * Returns the verifying_key associated with the program\n *\n * @returns {VerifyingKey} The verifying key\n * @returns {VerifyingKey}\n */\n getVerifyingKey() {\n const ret = wasm.executionresponse_getVerifyingKey(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the function identifier\n * @returns {string}\n */\n getFunctionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getFunctionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the program\n * @returns {Program}\n */\n getProgram() {\n const ret = wasm.executionresponse_getProgram(this.__wbg_ptr);\n return Program.__wrap(ret);\n }\n}\n\nconst FieldFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_field_free(ptr >>> 0));\n/**\n*/\nclass Field {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Field.prototype);\n obj.__wbg_ptr = ptr;\n FieldFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n FieldFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_field_free(ptr);\n }\n /**\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.field_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} field\n * @returns {Field}\n */\n static fromString(field) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(field, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.field_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst KeyPairFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_keypair_free(ptr >>> 0));\n/**\n* Key pair object containing both the function proving and verifying keys\n*/\nclass KeyPair {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(KeyPair.prototype);\n obj.__wbg_ptr = ptr;\n KeyPairFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n KeyPairFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_keypair_free(ptr);\n }\n /**\n * Create new key pair from proving and verifying keys\n *\n * @param {ProvingKey} proving_key Proving key corresponding to a function in an Aleo program\n * @param {VerifyingKey} verifying_key Verifying key corresponding to a function in an Aleo program\n * @returns {KeyPair} Key pair object containing both the function proving and verifying keys\n * @param {ProvingKey} proving_key\n * @param {VerifyingKey} verifying_key\n */\n constructor(proving_key, verifying_key) {\n _assertClass(proving_key, ProvingKey);\n var ptr0 = proving_key.__destroy_into_raw();\n _assertClass(verifying_key, VerifyingKey);\n var ptr1 = verifying_key.__destroy_into_raw();\n const ret = wasm.keypair_new(ptr0, ptr1);\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get the proving key. This method will remove the proving key from the key pair\n *\n * @returns {ProvingKey | Error}\n * @returns {ProvingKey}\n */\n provingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_provingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the verifying key. This method will remove the verifying key from the key pair\n *\n * @returns {VerifyingKey | Error}\n * @returns {VerifyingKey}\n */\n verifyingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst MetadataFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_metadata_free(ptr >>> 0));\n/**\n*/\nclass Metadata {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Metadata.prototype);\n obj.__wbg_ptr = ptr;\n MetadataFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n MetadataFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_metadata_free(ptr);\n }\n /**\n * @returns {string}\n */\n get name() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_name(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set name(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_name(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get locator() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_locator(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set locator(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_locator(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get prover() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_prover(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set prover(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_prover(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifier() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifier(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifier(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifier(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifyingKey() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifyingKey(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifyingKey(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n static baseUrl() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.metadata_baseUrl(retptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @returns {Metadata}\n */\n static bond_public() {\n const ret = wasm.metadata_bond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static bond_validator() {\n const ret = wasm.metadata_bond_validator();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static claim_unbond_public() {\n const ret = wasm.metadata_claim_unbond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_private() {\n const ret = wasm.metadata_fee_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_public() {\n const ret = wasm.metadata_fee_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static inclusion() {\n const ret = wasm.metadata_inclusion();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static join() {\n const ret = wasm.metadata_join();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static set_validator_state() {\n const ret = wasm.metadata_set_validator_state();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static split() {\n const ret = wasm.metadata_split();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private() {\n const ret = wasm.metadata_transfer_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private_to_public() {\n const ret = wasm.metadata_transfer_private_to_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public() {\n const ret = wasm.metadata_transfer_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_as_signer() {\n const ret = wasm.metadata_transfer_public_as_signer();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_to_private() {\n const ret = wasm.metadata_transfer_public_to_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static unbond_public() {\n const ret = wasm.metadata_unbond_public();\n return Metadata.__wrap(ret);\n }\n}\n\nconst OfflineQueryFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_offlinequery_free(ptr >>> 0));\n/**\n* An offline query object used to insert the global state root and state paths needed to create\n* a valid inclusion proof offline.\n*/\nclass OfflineQuery {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(OfflineQuery.prototype);\n obj.__wbg_ptr = ptr;\n OfflineQueryFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n OfflineQueryFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_offlinequery_free(ptr);\n }\n /**\n * Creates a new offline query object. The state root is required to be passed in as a string\n * @param {string} state_root\n */\n constructor(state_root) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(state_root, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_new(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n this.__wbg_ptr = r0 >>> 0;\n return this;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Add a new state path to the offline query object.\n *\n * @param {string} commitment: The commitment corresponding to a record inpout\n * @param {string} state_path: The state path corresponding to the commitment\n * @param {string} commitment\n * @param {string} state_path\n */\n addStatePath(commitment, state_path) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(commitment, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(state_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.offlinequery_addStatePath(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n if (r1) {\n throw takeObject(r0);\n }\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a json string representation of the offline query object\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.offlinequery_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create an offline query object from a json string representation\n * @param {string} s\n * @returns {OfflineQuery}\n */\n static fromString(s) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(s, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return OfflineQuery.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekey_free(ptr >>> 0));\n/**\n* Private key of an Aleo account\n*/\nclass PrivateKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKey.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekey_free(ptr);\n }\n /**\n * Generate a new private key using a cryptographically secure random number generator\n *\n * @returns {PrivateKey}\n */\n constructor() {\n const ret = wasm.privatekey_new();\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get a private key from a series of unchecked bytes\n *\n * @param {Uint8Array} seed Unchecked 32 byte long Uint8Array acting as the seed for the private key\n * @returns {PrivateKey}\n * @param {Uint8Array} seed\n * @returns {PrivateKey}\n */\n static from_seed_unchecked(seed) {\n const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_from_seed_unchecked(ptr0, len0);\n return PrivateKey.__wrap(ret);\n }\n /**\n * Get a private key from a string representation of a private key\n *\n * @param {string} seed String representation of a private key\n * @returns {PrivateKey}\n * @param {string} private_key\n * @returns {PrivateKey}\n */\n static from_string(private_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(private_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_from_string(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the private key. This function should be used very carefully\n * as it exposes the private key plaintext\n *\n * @returns {string} String representation of a private key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the view key corresponding to the private key\n *\n * @returns {ViewKey}\n * @returns {ViewKey}\n */\n to_view_key() {\n const ret = wasm.privatekey_to_view_key(this.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get the address corresponding to the private key\n *\n * @returns {Address}\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.privatekey_to_address(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Sign a message with the private key\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {Signature} Signature generated by signing the message with the address\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n sign(message) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(this.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a new randomly generated private key ciphertext using a secret. The secret is sensitive\n * and will be needed to decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext | Error} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static newEncrypted(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_newEncrypted(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Encrypt an existing private key with a secret. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext | Error} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n toCiphertext(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get private key from a private key ciphertext and secret originally used to encrypt it\n *\n * @param {PrivateKeyCiphertext} ciphertext Ciphertext representation of the private key\n * @param {string} secret Secret originally used to encrypt the private key\n * @returns {PrivateKey | Error} Private key\n * @param {PrivateKeyCiphertext} ciphertext\n * @param {string} secret\n * @returns {PrivateKey}\n */\n static fromPrivateKeyCiphertext(ciphertext, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(ciphertext, PrivateKeyCiphertext);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_fromPrivateKeyCiphertext(retptr, ciphertext.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekeyciphertext_free(ptr >>> 0));\n/**\n* Private Key in ciphertext form\n*/\nclass PrivateKeyCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKeyCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekeyciphertext_free(ptr);\n }\n /**\n * Encrypt a private key using a secret string. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {PrivateKey} private_key Private key to encrypt\n * @param {string} secret Secret to encrypt the private key with\n * @returns {PrivateKeyCiphertext | Error} Private key ciphertext\n * @param {PrivateKey} private_key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static encryptPrivateKey(private_key, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, private_key.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Decrypts a private ciphertext using a secret string. This must be the same secret used to\n * encrypt the private key\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKey | Error} Private key\n * @param {string} secret\n * @returns {PrivateKey}\n */\n decryptToPrivateKey(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_decryptToPrivateKey(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the ciphertext string\n *\n * @returns {string} Ciphertext string\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekeyciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates a PrivateKeyCiphertext from a string\n *\n * @param {string} ciphertext Ciphertext string\n * @returns {PrivateKeyCiphertext | Error} Private key ciphertext\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n */\n static fromString(ciphertext) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ProgramFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_program_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo program\n*/\nclass Program {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Program.prototype);\n obj.__wbg_ptr = ptr;\n ProgramFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_program_free(ptr);\n }\n /**\n * Create a program from a program string\n *\n * @param {string} program Aleo program source code\n * @returns {Program | Error} Program object\n * @param {string} program\n * @returns {Program}\n */\n static fromString(program) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Program.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the program\n *\n * @returns {string} String containing the program source code\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Determine if a function is present in the program\n *\n * @param {string} functionName Name of the function to check for\n * @returns {boolean} True if the program is valid, false otherwise\n * @param {string} function_name\n * @returns {boolean}\n */\n hasFunction(function_name) {\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.program_hasFunction(this.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get javascript array of functions names in the program\n *\n * @returns {Array} Array of all function names present in the program\n *\n * @example\n * const expected_functions = [\n * \"mint\",\n * \"transfer_private\",\n * \"transfer_private_to_public\",\n * \"transfer_public\",\n * \"transfer_public_to_private\",\n * \"join\",\n * \"split\",\n * \"fee\"\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_functions = credits_program.getFunctions();\n * console.log(credits_functions === expected_functions); // Output should be \"true\"\n * @returns {Array}\n */\n getFunctions() {\n const ret = wasm.program_getFunctions(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Get a javascript object representation of the function inputs and types. This can be used\n * to generate a web form to capture user inputs for an execution of a function.\n *\n * @param {string} function_name Name of the function to get inputs for\n * @returns {Array | Error} Array of function inputs\n *\n * @example\n * const expected_inputs = [\n * {\n * type:\"record\",\n * visibility:\"private\",\n * record:\"credits\",\n * members:[\n * {\n * name:\"microcredits\",\n * type:\"u64\",\n * visibility:\"private\"\n * }\n * ],\n * register:\"r0\"\n * },\n * {\n * type:\"address\",\n * visibility:\"private\",\n * register:\"r1\"\n * },\n * {\n * type:\"u64\",\n * visibility:\"private\",\n * register:\"r2\"\n * }\n * ];\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const transfer_function_inputs = credits_program.getFunctionInputs(\"transfer_private\");\n * console.log(transfer_function_inputs === expected_inputs); // Output should be \"true\"\n * @param {string} function_name\n * @returns {Array}\n */\n getFunctionInputs(function_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getFunctionInputs(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a the list of a program's mappings and the names/types of their keys and values.\n *\n * @returns {Array | Error} - An array of objects representing the mappings in the program\n * @example\n * const expected_mappings = [\n * {\n * name: \"account\",\n * key_name: \"owner\",\n * key_type: \"address\",\n * value_name: \"microcredits\",\n * value_type: \"u64\"\n * }\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_mappings = credits_program.getMappings();\n * console.log(credits_mappings === expected_mappings); // Output should be \"true\"\n * @returns {Array}\n */\n getMappings() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_getMappings(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program record and its types\n *\n * @param {string} record_name Name of the record to get members for\n * @returns {Object | Error} Object containing the record name, type, and members\n *\n * @example\n *\n * const expected_record = {\n * type: \"record\",\n * record: \"Credits\",\n * members: [\n * {\n * name: \"owner\",\n * type: \"address\",\n * visibility: \"private\"\n * },\n * {\n * name: \"microcredits\",\n * type: \"u64\",\n * visibility: \"private\"\n * }\n * ];\n * };\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_record = credits_program.getRecordMembers(\"Credits\");\n * console.log(credits_record === expected_record); // Output should be \"true\"\n * @param {string} record_name\n * @returns {object}\n */\n getRecordMembers(record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getRecordMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program struct and its types\n *\n * @param {string} struct_name Name of the struct to get members for\n * @returns {Array | Error} Array containing the struct members\n *\n * @example\n *\n * const STRUCT_PROGRAM = \"program token_issue.aleo;\n *\n * struct token_metadata:\n * network as u32;\n * version as u32;\n *\n * struct token:\n * token_id as u32;\n * metadata as token_metadata;\n *\n * function no_op:\n * input r0 as u64;\n * output r0 as u64;\"\n *\n * const expected_struct_members = [\n * {\n * name: \"token_id\",\n * type: \"u32\",\n * },\n * {\n * name: \"metadata\",\n * type: \"struct\",\n * struct_id: \"token_metadata\",\n * members: [\n * {\n * name: \"network\",\n * type: \"u32\",\n * }\n * {\n * name: \"version\",\n * type: \"u32\",\n * }\n * ]\n * }\n * ];\n *\n * const program = aleo_wasm.Program.fromString(STRUCT_PROGRAM);\n * const struct_members = program.getStructMembers(\"token\");\n * console.log(struct_members === expected_struct_members); // Output should be \"true\"\n * @param {string} struct_name\n * @returns {Array}\n */\n getStructMembers(struct_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(struct_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getStructMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the credits.aleo program\n *\n * @returns {Program} The credits.aleo program\n * @returns {Program}\n */\n static getCreditsProgram() {\n const ret = wasm.program_getCreditsProgram();\n return Program.__wrap(ret);\n }\n /**\n * Get the id of the program\n *\n * @returns {string} The id of the program\n * @returns {string}\n */\n id() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_id(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get a unique address of the program\n *\n * @returns {Address} The address of the program\n * @returns {Address}\n */\n address() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_address(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Address.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determine equality with another program\n *\n * @param {Program} other The other program to compare\n * @returns {boolean} True if the programs are equal, false otherwise\n * @param {Program} other\n * @returns {boolean}\n */\n isEqual(other) {\n _assertClass(other, Program);\n const ret = wasm.program_isEqual(this.__wbg_ptr, other.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get program_imports\n *\n * @returns {Array} The program imports\n *\n * @example\n *\n * const DOUBLE_TEST = \"import multiply_test.aleo;\n *\n * program double_test.aleo;\n *\n * function double_it:\n * input r0 as u32.private;\n * call multiply_test.aleo/multiply 2u32 r0 into r1;\n * output r1 as u32.private;\";\n *\n * const expected_imports = [\n * \"multiply_test.aleo\"\n * ];\n *\n * const program = aleo_wasm.Program.fromString(DOUBLE_TEST_PROGRAM);\n * const imports = program.getImports();\n * console.log(imports === expected_imports); // Output should be \"true\"\n * @returns {Array}\n */\n getImports() {\n const ret = wasm.program_getImports(this.__wbg_ptr);\n return takeObject(ret);\n }\n}\n\nconst ProgramManagerFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_programmanager_free(ptr >>> 0));\n/**\n*/\nclass ProgramManager {\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramManagerFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_programmanager_free(ptr);\n }\n /**\n * Deploy an Aleo program\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being deployed\n * @param imports A javascript object holding the source code of any imported programs in the\n * form \\{\"program_name1\": \"program_source_code\", \"program_name2\": \"program_source_code\", ..\\}.\n * Note that all imported programs must be deployed on chain before the main program in order\n * for the deployment to succeed\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the program deployment in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildDeploymentTransaction(private_key, program, fee_credits, fee_record, url, imports, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n let ptr1 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr1 = fee_record.__destroy_into_raw();\n }\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr3 = fee_proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr4 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildDeploymentTransaction(private_key.__wbg_ptr, ptr0, len0, fee_credits, ptr1, ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the fee for a program deployment\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The source code of the program being deployed\n * @param imports (optional) Provide a list of imports to use for the deployment fee estimation\n * in the form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @returns {u64 | Error}\n * @param {string} program\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static estimateDeploymentFee(program, imports) {\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_estimateDeploymentFee(ptr0, len0, isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n /**\n * Estimate the component of the deployment cost which comes from the fee for the program name.\n * Note that this cost does not represent the entire cost of deployment. It is additional to\n * the cost of the size (in bytes) of the deployment.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param name The name of the program to be deployed\n * @returns {u64 | Error}\n * @param {string} name\n * @returns {bigint}\n */\n static estimateProgramNameCost(name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateProgramNameCost(retptr, ptr0, len0);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Execute an arbitrary function locally\n *\n * @param {PrivateKey} private_key The private key of the sender\n * @param {string} program The source code of the program being executed\n * @param {string} function The name of the function to execute\n * @param {Array} inputs A javascript array of inputs to the function\n * @param {boolean} prove_execution If true, the execution will be proven and an execution object\n * containing the proof and the encrypted inputs and outputs needed to verify the proof offline\n * will be returned.\n * @param {boolean} cache Cache the proving and verifying keys in the Execution response.\n * If this is set to 'true' the keys synthesized will be stored in the Execution Response\n * and the `ProvingKey` and `VerifyingKey` can be retrieved from the response via the `.getKeys()`\n * method.\n * @param {Object | undefined} imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param {ProvingKey | undefined} proving_key (optional) Provide a verifying key to use for the function execution\n * @param {VerifyingKey | undefined} verifying_key (optional) Provide a verifying key to use for the function execution\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {boolean} prove_execution\n * @param {boolean} cache\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {string | undefined} [url]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static executeFunctionOffline(private_key, program, _function, inputs, prove_execution, cache, imports, proving_key, verifying_key, url, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr2 = proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr3 = verifying_key.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_executeFunctionOffline(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), prove_execution, cache, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr2, ptr3, ptr4, len4, ptr5);\n return takeObject(ret);\n }\n /**\n * Execute Aleo function and create an Aleo execution transaction\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being executed\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * If this is set to 'true' the keys synthesized (or passed in as optional parameters via the\n * `proving_key` and `verifying_key` arguments) will be stored in the ProgramManager's memory\n * and used for subsequent transactions. If this is set to 'false' the proving and verifying\n * keys will be deallocated from memory after the transaction is executed.\n * @param imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the function execution\n * @param verifying_key (optional) Provide a verifying key to use for the function execution\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildExecutionTransaction(private_key, program, _function, inputs, fee_credits, fee_record, url, imports, proving_key, verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr4 = proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr5 = verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildExecutionTransaction(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), fee_credits, ptr2, ptr3, len3, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Estimate Fee for Aleo function execution. Note if \"cache\" is set to true, the proving and\n * verifying keys will be stored in the ProgramManager's memory and used for subsequent\n * program executions.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program to estimate the execution fee for\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the fee estimation in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the fee estimation\n * @param verifying_key (optional) Provide a verifying key to use for the fee estimation\n * @returns {u64 | Error} Fee in microcredits\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static estimateExecutionFee(private_key, program, _function, inputs, url, imports, proving_key, verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr3 = proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr4 = verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_estimateExecutionFee(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the finalize fee component for executing a function. This fee is additional to the\n * size of the execution of the program in bytes. If the function does not have a finalize\n * step, then the finalize fee is 0.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The program containing the function to estimate the finalize fee for\n * @param function The function to estimate the finalize fee for\n * @returns {u64 | Error} Fee in microcredits\n * @param {string} program\n * @param {string} _function\n * @returns {bigint}\n */\n static estimateFinalizeFee(program, _function) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateFinalizeFee(retptr, ptr0, len0, ptr1, len1);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Join two records together to create a new record with an amount of credits equal to the sum\n * of the credits of the two original records\n *\n * @param private_key The private key of the sender\n * @param record_1 The first record to combine\n * @param record_2 The second record to combine\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param join_proving_key (optional) Provide a proving key to use for the join function\n * @param join_verifying_key (optional) Provide a verifying key to use for the join function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error} Transaction object\n * @param {PrivateKey} private_key\n * @param {RecordPlaintext} record_1\n * @param {RecordPlaintext} record_2\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [join_proving_key]\n * @param {VerifyingKey | undefined} [join_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildJoinTransaction(private_key, record_1, record_2, fee_credits, fee_record, url, join_proving_key, join_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(record_1, RecordPlaintext);\n var ptr0 = record_1.__destroy_into_raw();\n _assertClass(record_2, RecordPlaintext);\n var ptr1 = record_2.__destroy_into_raw();\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(join_proving_key)) {\n _assertClass(join_proving_key, ProvingKey);\n ptr4 = join_proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(join_verifying_key)) {\n _assertClass(join_verifying_key, VerifyingKey);\n ptr5 = join_verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildJoinTransaction(private_key.__wbg_ptr, ptr0, ptr1, fee_credits, ptr2, ptr3, len3, ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Split an Aleo credits record into two separate records. This function does not require a fee.\n *\n * @param private_key The private key of the sender\n * @param split_amount The amount of the credit split. This amount will be subtracted from the\n * value of the record and two new records will be created with the split amount and the remainder\n * @param amount_record The record to split\n * @param url The url of the Aleo network node to send the transaction to\n * @param split_proving_key (optional) Provide a proving key to use for the split function\n * @param split_verifying_key (optional) Provide a verifying key to use for the split function\n * @returns {Transaction | Error} Transaction object\n * @param {PrivateKey} private_key\n * @param {number} split_amount\n * @param {RecordPlaintext} amount_record\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [split_proving_key]\n * @param {VerifyingKey | undefined} [split_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildSplitTransaction(private_key, split_amount, amount_record, url, split_proving_key, split_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(amount_record, RecordPlaintext);\n var ptr0 = amount_record.__destroy_into_raw();\n var ptr1 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(split_proving_key)) {\n _assertClass(split_proving_key, ProvingKey);\n ptr2 = split_proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(split_verifying_key)) {\n _assertClass(split_verifying_key, VerifyingKey);\n ptr3 = split_verifying_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr4 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildSplitTransaction(private_key.__wbg_ptr, split_amount, ptr0, ptr1, len1, ptr2, ptr3, ptr4);\n return takeObject(ret);\n }\n /**\n * Send credits from one Aleo account to another\n *\n * @param private_key The private key of the sender\n * @param amount_credits The amount of credits to send\n * @param recipient The recipient of the transaction\n * @param transfer_type The type of the transfer (options: \"private\", \"public\", \"private_to_public\", \"public_to_private\")\n * @param amount_record The record to fund the amount from\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param transfer_verifying_key (optional) Provide a verifying key to use for the transfer\n * function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {number} amount_credits\n * @param {string} recipient\n * @param {string} transfer_type\n * @param {RecordPlaintext | undefined} amount_record\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [transfer_proving_key]\n * @param {VerifyingKey | undefined} [transfer_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildTransferTransaction(private_key, amount_credits, recipient, transfer_type, amount_record, fee_credits, fee_record, url, transfer_proving_key, transfer_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(recipient, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(transfer_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(amount_record)) {\n _assertClass(amount_record, RecordPlaintext);\n ptr2 = amount_record.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr3 = fee_record.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(transfer_proving_key)) {\n _assertClass(transfer_proving_key, ProvingKey);\n ptr5 = transfer_proving_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(transfer_verifying_key)) {\n _assertClass(transfer_verifying_key, VerifyingKey);\n ptr6 = transfer_verifying_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr7 = fee_proving_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr8 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr9 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr9 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildTransferTransaction(private_key.__wbg_ptr, amount_credits, ptr0, len0, ptr1, len1, ptr2, fee_credits, ptr3, ptr4, len4, ptr5, ptr6, ptr7, ptr8, ptr9);\n return takeObject(ret);\n }\n /**\n * Synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code of the program to synthesize keys for\n * @param function_id {string} The function to synthesize keys for\n * @param inputs {Array} The inputs to the function\n * @param imports {Object | undefined} The imports for the program\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} function_id\n * @param {Array} inputs\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static synthesizeKeyPair(private_key, program, function_id, inputs, imports) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_synthesizeKeyPair(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n}\n\nconst ProvingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_provingkey_free(ptr >>> 0));\n/**\n* Proving key for a function within an Aleo program\n*/\nclass ProvingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ProvingKey.prototype);\n obj.__wbg_ptr = ptr;\n ProvingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProvingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_provingkey_free(ptr);\n }\n /**\n * Verify if the proving key is for the bond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_public_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_public function, false if otherwise\n * @returns {boolean}\n */\n isBondPublicProver() {\n const ret = wasm.provingkey_isBondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the bond_validator function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_validator_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_validator function, false if otherwise\n * @returns {boolean}\n */\n isBondValidatorProver() {\n const ret = wasm.provingkey_isBondValidatorProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the claim_unbond function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"claim_unbond_proving_key.bin\");\n * provingKey.isClaimUnbondProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the claim_unbond function, false if otherwise\n * @returns {boolean}\n */\n isClaimUnbondPublicProver() {\n const ret = wasm.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_private_proving_key.bin\");\n * provingKey.isFeePrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_private function, false if otherwise\n * @returns {boolean}\n */\n isFeePrivateProver() {\n const ret = wasm.provingkey_isFeePrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_public_proving_key.bin\");\n * provingKey.isFeePublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_public function, false if otherwise\n * @returns {boolean}\n */\n isFeePublicProver() {\n const ret = wasm.provingkey_isFeePublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the inclusion function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"inclusion_proving_key.bin\");\n * provingKey.isInclusionProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the inclusion function, false if otherwise\n * @returns {boolean}\n */\n isInclusionProver() {\n const ret = wasm.provingkey_isInclusionProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the join function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"join_proving_key.bin\");\n * provingKey.isJoinProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the join function, false if otherwise\n * @returns {boolean}\n */\n isJoinProver() {\n const ret = wasm.provingkey_isJoinProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the set_validator_state function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"set_validator_set_proving_key.bin\");\n * provingKey.isSetValidatorStateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the set_validator_state function, false if otherwise\n * @returns {boolean}\n */\n isSetValidatorStateProver() {\n const ret = wasm.provingkey_isSetValidatorStateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the split function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"split_proving_key.bin\");\n * provingKey.isSplitProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the split function, false if otherwise\n * @returns {boolean}\n */\n isSplitProver() {\n const ret = wasm.provingkey_isSplitProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_proving_key.bin\");\n * provingKey.isTransferPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateProver() {\n const ret = wasm.provingkey_isTransferPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private_to_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_to_public_proving_key.bin\");\n * provingKey.isTransferPrivateToPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private_to_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateToPublicProver() {\n const ret = wasm.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_proving_key.bin\");\n * provingKey.isTransferPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicProver() {\n const ret = wasm.provingkey_isTransferPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_as_signer function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_as_signer_proving_key.bin\");\n * provingKey.isTransferPublicAsSignerProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicAsSignerProver() {\n const ret = wasm.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_to_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_to_private_proving_key.bin\");\n * provingKey.isTransferPublicToPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public_to_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicToPrivateProver() {\n const ret = wasm.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the unbond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"unbond_public.bin\");\n * provingKey.isUnbondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the unbond_public_prover function, false if otherwise\n * @returns {boolean}\n */\n isUnbondPublicProver() {\n const ret = wasm.provingkey_isUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Return the checksum of the proving key\n *\n * @returns {string} Checksum of the proving key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the proving key\n *\n * @returns {ProvingKey} A copy of the proving key\n * @returns {ProvingKey}\n */\n copy() {\n const ret = wasm.provingkey_copy(this.__wbg_ptr);\n return ProvingKey.__wrap(ret);\n }\n /**\n * Construct a new proving key from a byte array\n *\n * @param {Uint8Array} bytes Byte array representation of a proving key\n * @returns {ProvingKey | Error}\n * @param {Uint8Array} bytes\n * @returns {ProvingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a proving key from string\n *\n * @param {string | Error} String representation of the proving key\n * @param {string} string\n * @returns {ProvingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the byte representation of a proving key\n *\n * @returns {Uint8Array | Error} Byte array representation of a proving key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the proving key\n *\n * @returns {string} String representation of the proving key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst RecordCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordciphertext_free(ptr >>> 0));\n/**\n* Encrypted Aleo record\n*/\nclass RecordCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n RecordCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordciphertext_free(ptr);\n }\n /**\n * Create a record ciphertext from a string\n *\n * @param {string} record String representation of a record ciphertext\n * @returns {RecordCiphertext | Error} Record ciphertext\n * @param {string} record\n * @returns {RecordCiphertext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the string reprensentation of the record ciphertext\n *\n * @returns {string} String representation of the record ciphertext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Decrypt the record ciphertext into plaintext using the view key. The record will only\n * decrypt if the record was encrypted by the account corresponding to the view key\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {RecordPlaintext | Error} Record plaintext object\n * @param {ViewKey} view_key\n * @returns {RecordPlaintext}\n */\n decrypt(view_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(view_key, ViewKey);\n wasm.recordciphertext_decrypt(retptr, this.__wbg_ptr, view_key.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determines if the account corresponding to the view key is the owner of the record\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {boolean}\n * @param {ViewKey} view_key\n * @returns {boolean}\n */\n isOwner(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.recordciphertext_isOwner(this.__wbg_ptr, view_key.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst RecordPlaintextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordplaintext_free(ptr >>> 0));\n/**\n* Plaintext representation of an Aleo record\n*/\nclass RecordPlaintext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordPlaintext.prototype);\n obj.__wbg_ptr = ptr;\n RecordPlaintextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordPlaintextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordplaintext_free(ptr);\n }\n /**\n * @param {string} program_id\n * @param {string} record_name\n * @returns {Field}\n */\n commitment(program_id, record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_commitment(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return a record plaintext from a string.\n *\n * @param {string} record String representation of a plaintext representation of an Aleo record\n * @returns {RecordPlaintext | Error} Record plaintext\n * @param {string} record\n * @returns {RecordPlaintext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordplaintext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the record plaintext string\n *\n * @returns {string} String representation of the record plaintext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the amount of microcredits in the record\n *\n * @returns {u64} Amount of microcredits in the record\n * @returns {bigint}\n */\n microcredits() {\n const ret = wasm.recordplaintext_microcredits(this.__wbg_ptr);\n return BigInt.asUintN(64, ret);\n }\n /**\n * Returns the nonce of the record. This can be used to uniquely identify a record.\n *\n * @returns {string} Nonce of the record\n * @returns {string}\n */\n nonce() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_nonce(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Attempt to get the serial number of a record to determine whether or not is has been spent\n *\n * @param {PrivateKey} private_key Private key of the account that owns the record\n * @param {string} program_id Program ID of the program that the record is associated with\n * @param {string} record_name Name of the record\n * @returns {string | Error} Serial number of the record\n * @param {PrivateKey} private_key\n * @param {string} program_id\n * @param {string} record_name\n * @returns {string}\n */\n serialNumberString(private_key, program_id, record_name) {\n let deferred4_0;\n let deferred4_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_serialNumberString(retptr, this.__wbg_ptr, private_key.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr3 = r0;\n var len3 = r1;\n if (r3) {\n ptr3 = 0; len3 = 0;\n throw takeObject(r2);\n }\n deferred4_0 = ptr3;\n deferred4_1 = len3;\n return getStringFromWasm0(ptr3, len3);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred4_0, deferred4_1, 1);\n }\n }\n}\n\nconst SignatureFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_signature_free(ptr >>> 0));\n/**\n* Cryptographic signature of a message signed by an Aleo account\n*/\nclass Signature {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Signature.prototype);\n obj.__wbg_ptr = ptr;\n SignatureFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n SignatureFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_signature_free(ptr);\n }\n /**\n * Sign a message with a private key\n *\n * @param {PrivateKey} private_key The private key to sign the message with\n * @param {Uint8Array} message Byte representation of the message to sign\n * @returns {Signature} Signature of the message\n * @param {PrivateKey} private_key\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n static sign(private_key, message) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(private_key.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Verify a signature of a message with an address\n *\n * @param {Address} address The address to verify the signature with\n * @param {Uint8Array} message Byte representation of the message to verify\n * @returns {boolean} True if the signature is valid, false otherwise\n * @param {Address} address\n * @param {Uint8Array} message\n * @returns {boolean}\n */\n verify(address, message) {\n _assertClass(address, Address);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_verify(this.__wbg_ptr, address.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get a signature from a string representation of a signature\n *\n * @param {string} signature String representation of a signature\n * @returns {Signature} Signature\n * @param {string} signature\n * @returns {Signature}\n */\n static from_string(signature) {\n const ptr0 = passStringToWasm0(signature, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_from_string(ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a string representation of a signature\n *\n * @returns {string} String representation of a signature\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.signature_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst TransactionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_transaction_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo transaction\n*\n* This object is created when generating an on-chain function deployment or execution and is the\n* object that should be submitted to the Aleo Network in order to deploy or execute a function.\n*/\nclass Transaction {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Transaction.prototype);\n obj.__wbg_ptr = ptr;\n TransactionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n TransactionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_transaction_free(ptr);\n }\n /**\n * Create a transaction from a string\n *\n * @param {string} transaction String representation of a transaction\n * @returns {Transaction | Error}\n * @param {string} transaction\n * @returns {Transaction}\n */\n static fromString(transaction) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(transaction, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.transaction_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Transaction.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the transaction as a string. If you want to submit this transaction to the Aleo Network\n * this function will create the string that should be submitted in the `POST` data.\n *\n * @returns {string} String representation of the transaction\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the id of the transaction. This is the merkle root of the transaction's inclusion proof.\n *\n * This value can be used to query the status of the transaction on the Aleo Network to see\n * if it was successful. If successful, the transaction will be included in a block and this\n * value can be used to lookup the transaction data on-chain.\n *\n * @returns {string} Transaction id\n * @returns {string}\n */\n transactionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the type of the transaction (will return \"deploy\" or \"execute\")\n *\n * @returns {string} Transaction type\n * @returns {string}\n */\n transactionType() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionType(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst VerifyingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_verifyingkey_free(ptr >>> 0));\n/**\n* Verifying key for a function within an Aleo program\n*/\nclass VerifyingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(VerifyingKey.prototype);\n obj.__wbg_ptr = ptr;\n VerifyingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n VerifyingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_verifyingkey_free(ptr);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {VerifyingKey}\n */\n static bondPublicVerifier() {\n const ret = wasm.verifyingkey_bondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {VerifyingKey}\n */\n static bondValidatorVerifier() {\n const ret = wasm.verifyingkey_bondValidatorVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the claim_delegator function\n *\n * @returns {VerifyingKey} Verifying key for the claim_unbond_public function\n * @returns {VerifyingKey}\n */\n static claimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_claimUnbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_private function\n *\n * @returns {VerifyingKey} Verifying key for the fee_private function\n * @returns {VerifyingKey}\n */\n static feePrivateVerifier() {\n const ret = wasm.verifyingkey_feePrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_public function\n *\n * @returns {VerifyingKey} Verifying key for the fee_public function\n * @returns {VerifyingKey}\n */\n static feePublicVerifier() {\n const ret = wasm.verifyingkey_feePublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the inclusion function\n *\n * @returns {VerifyingKey} Verifying key for the inclusion function\n * @returns {VerifyingKey}\n */\n static inclusionVerifier() {\n const ret = wasm.verifyingkey_inclusionVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the join function\n *\n * @returns {VerifyingKey} Verifying key for the join function\n * @returns {VerifyingKey}\n */\n static joinVerifier() {\n const ret = wasm.verifyingkey_joinVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the set_validator_state function\n *\n * @returns {VerifyingKey} Verifying key for the set_validator_state function\n * @returns {VerifyingKey}\n */\n static setValidatorStateVerifier() {\n const ret = wasm.verifyingkey_setValidatorStateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the split function\n *\n * @returns {VerifyingKey} Verifying key for the split function\n * @returns {VerifyingKey}\n */\n static splitVerifier() {\n const ret = wasm.verifyingkey_splitVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private function\n * @returns {VerifyingKey}\n */\n static transferPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private_to_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private_to_public function\n * @returns {VerifyingKey}\n */\n static transferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_transferPrivateToPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public function\n * @returns {VerifyingKey}\n */\n static transferPublicVerifier() {\n const ret = wasm.verifyingkey_transferPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_as_signer function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_as_signer function\n * @returns {VerifyingKey}\n */\n static transferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_transferPublicAsSignerVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_to_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_to_private function\n * @returns {VerifyingKey}\n */\n static transferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPublicToPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the unbond_public function\n *\n * @returns {VerifyingKey} Verifying key for the unbond_public function\n * @returns {VerifyingKey}\n */\n static unbondPublicVerifier() {\n const ret = wasm.verifyingkey_unbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {boolean}\n */\n isBondPublicVerifier() {\n const ret = wasm.verifyingkey_isBondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {boolean}\n */\n isBondValidatorVerifier() {\n const ret = wasm.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the claim_delegator function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isClaimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePrivateVerifier() {\n const ret = wasm.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePublicVerifier() {\n const ret = wasm.verifyingkey_isFeePublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the inclusion function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isInclusionVerifier() {\n const ret = wasm.verifyingkey_isInclusionVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the join function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isJoinVerifier() {\n const ret = wasm.verifyingkey_isJoinVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the set_validator_state function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSetValidatorStateVerifier() {\n const ret = wasm.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the split function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSplitVerifier() {\n const ret = wasm.verifyingkey_isSplitVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private_to_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_as_signer function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_to_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the unbond_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get the checksum of the verifying key\n *\n * @returns {string} Checksum of the verifying key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the verifying key\n *\n * @returns {VerifyingKey} A copy of the verifying key\n * @returns {VerifyingKey}\n */\n copy() {\n const ret = wasm.verifyingkey_copy(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Construct a new verifying key from a byte array\n *\n * @param {Uint8Array} bytes Byte representation of a verifying key\n * @returns {VerifyingKey | Error}\n * @param {Uint8Array} bytes\n * @returns {VerifyingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a verifying key from string\n *\n * @param {String} string String representation of a verifying key\n * @returns {VerifyingKey | Error}\n * @param {string} string\n * @returns {VerifyingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a byte array from a verifying key\n *\n * @returns {Uint8Array | Error} Byte representation of a verifying key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the verifying key\n *\n * @returns {String} String representation of the verifying key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst ViewKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_viewkey_free(ptr >>> 0));\n/**\n*/\nclass ViewKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ViewKey.prototype);\n obj.__wbg_ptr = ptr;\n ViewKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ViewKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_viewkey_free(ptr);\n }\n /**\n * Create a new view key from a private key\n *\n * @param {PrivateKey} private_key Private key\n * @returns {ViewKey} View key\n * @param {PrivateKey} private_key\n * @returns {ViewKey}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.privatekey_to_view_key(private_key.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Create a new view key from a string representation of a view key\n *\n * @param {string} view_key String representation of a view key\n * @returns {ViewKey} View key\n * @param {string} view_key\n * @returns {ViewKey}\n */\n static from_string(view_key) {\n const ptr0 = passStringToWasm0(view_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.viewkey_from_string(ptr0, len0);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get a string representation of a view key\n *\n * @returns {string} String representation of a view key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.viewkey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the address corresponding to a view key\n *\n * @returns {Address} Address\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.address_from_view_key(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Decrypt a record ciphertext with a view key\n *\n * @param {string} ciphertext String representation of a record ciphertext\n * @returns {string} String representation of a record plaintext\n * @param {string} ciphertext\n * @returns {string}\n */\n decrypt(ciphertext) {\n let deferred3_0;\n let deferred3_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.viewkey_decrypt(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr2 = r0;\n var len2 = r1;\n if (r3) {\n ptr2 = 0; len2 = 0;\n throw takeObject(r2);\n }\n deferred3_0 = ptr2;\n deferred3_1 = len2;\n return getStringFromWasm0(ptr2, len2);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);\n }\n }\n}\n\nasync function __wbg_load(module, imports) {\n if (typeof Response === 'function' && module instanceof Response) {\n if (typeof WebAssembly.instantiateStreaming === 'function') {\n try {\n return await WebAssembly.instantiateStreaming(module, imports);\n\n } catch (e) {\n if (module.headers.get('Content-Type') != 'application/wasm') {\n console.warn(\"`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n\", e);\n\n } else {\n throw e;\n }\n }\n }\n\n const bytes = await module.arrayBuffer();\n return await WebAssembly.instantiate(bytes, imports);\n\n } else {\n const instance = await WebAssembly.instantiate(module, imports);\n\n if (instance instanceof WebAssembly.Instance) {\n return { instance, module };\n\n } else {\n return instance;\n }\n }\n}\n\nfunction __wbg_get_imports() {\n const imports = {};\n imports.wbg = {};\n imports.wbg.__wbindgen_object_drop_ref = function(arg0) {\n takeObject(arg0);\n };\n imports.wbg.__wbg_new_71801a555ad9f2aa = function() { return handleError(function () {\n const ret = new XMLHttpRequest();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_overrideMimeType_ee9c51919ceb418b = function() { return handleError(function (arg0, arg1, arg2) {\n getObject(arg0).overrideMimeType(getStringFromWasm0(arg1, arg2));\n }, arguments) };\n imports.wbg.__wbg_open_c9eb0cf2c9d95679 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {\n getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), arg5 !== 0);\n }, arguments) };\n imports.wbg.__wbg_send_80d29985093c1ec5 = function() { return handleError(function (arg0) {\n getObject(arg0).send();\n }, arguments) };\n imports.wbg.__wbg_response_7c2e2759084f7279 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).response;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_status_d485fb5a478426fb = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).status;\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_72fb9a18b5ae2624 = function() {\n const ret = new Object();\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_string_new = function(arg0, arg1) {\n const ret = getStringFromWasm0(arg0, arg1);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_1f9b04f170055d33 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_ab6fd82b10560829 = function() { return handleError(function () {\n const ret = new Headers();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_object_clone_ref = function(arg0) {\n const ret = getObject(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_0d76b0581eca6298 = function() { return handleError(function () {\n const ret = new AbortController();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_signal_a61f78a3478fd9bc = function(arg0) {\n const ret = getObject(arg0).signal;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_append_7bfcb4937d1d5e29 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {\n getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));\n }, arguments) };\n imports.wbg.__wbg_instanceof_Response_849eb93e75734b6e = function(arg0) {\n let result;\n try {\n result = getObject(arg0) instanceof Response;\n } catch (_) {\n result = false;\n }\n const ret = result;\n return ret;\n };\n imports.wbg.__wbg_status_61a01141acd3cf74 = function(arg0) {\n const ret = getObject(arg0).status;\n return ret;\n };\n imports.wbg.__wbg_url_5f6dc4009ac5f99d = function(arg0, arg1) {\n const ret = getObject(arg1).url;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_headers_9620bfada380764a = function(arg0) {\n const ret = getObject(arg0).headers;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_iterator_2cee6dadfd956dfa = function() {\n const ret = Symbol.iterator;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_get_e3c254076557e348 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.get(getObject(arg0), getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_function = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'function';\n return ret;\n };\n imports.wbg.__wbg_call_27c0f87801dedf93 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg0).call(getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_object = function(arg0) {\n const val = getObject(arg0);\n const ret = typeof(val) === 'object' && val !== null;\n return ret;\n };\n imports.wbg.__wbg_next_40fc327bfc8770e6 = function(arg0) {\n const ret = getObject(arg0).next;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_next_196c84450b364254 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).next();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_done_298b57d23c0fc80c = function(arg0) {\n const ret = getObject(arg0).done;\n return ret;\n };\n imports.wbg.__wbg_value_d93c65011f51a456 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_abort_2aa7521d5690750e = function(arg0) {\n getObject(arg0).abort();\n };\n imports.wbg.__wbg_stringify_8887fe74e1c50d81 = function() { return handleError(function (arg0) {\n const ret = JSON.stringify(getObject(arg0));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_string_get = function(arg0, arg1) {\n const obj = getObject(arg1);\n const ret = typeof(obj) === 'string' ? obj : undefined;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_log_0159ca40cddf5b15 = function(arg0, arg1) {\n console.log(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {\n const ret = BigInt.asUintN(64, arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_call_b3ca7c6051f9bec1 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_transaction_new = function(arg0) {\n const ret = Transaction.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_keypair_new = function(arg0) {\n const ret = KeyPair.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_module = function() {\n const ret = __wbg_init.__wbindgen_wasm_module;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_memory = function() {\n const ret = wasm.memory;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a = function(arg0, arg1, arg2, arg3) {\n const ret = spawnWorker(getObject(arg0), getObject(arg1), getObject(arg2), arg3 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_executionresponse_new = function(arg0) {\n const ret = ExecutionResponse.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_66ae46612e7f0234 = function(arg0) {\n const ret = new Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_d4638f722068f043 = function(arg0, arg1, arg2) {\n getObject(arg0)[arg1 >>> 0] = takeObject(arg2);\n };\n imports.wbg.__wbindgen_cb_drop = function(arg0) {\n const obj = takeObject(arg0).original;\n if (obj.cnt-- == 1) {\n obj.a = 0;\n return true;\n }\n const ret = false;\n return ret;\n };\n imports.wbg.__wbg_new_16b304a2cfa7ff4a = function() {\n const ret = new Array();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_push_a5b05aedc7234f9f = function(arg0, arg1) {\n const ret = getObject(arg0).push(getObject(arg1));\n return ret;\n };\n imports.wbg.__wbg_arrayBuffer_29931d52c7206b02 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).arrayBuffer();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_new_63b92bc8671ed464 = function(arg0) {\n const ret = new Uint8Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_c20a40f15020d68a = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_new_81740750da40724f = function(arg0, arg1) {\n try {\n var state0 = {a: arg0, b: arg1};\n var cb0 = (arg0, arg1) => {\n const a = state0.a;\n state0.a = 0;\n try {\n return __wbg_adapter_281(a, state0.b, arg0, arg1);\n } finally {\n state0.a = a;\n }\n };\n const ret = new Promise(cb0);\n return addHeapObject(ret);\n } finally {\n state0.a = state0.b = 0;\n }\n };\n imports.wbg.__wbindgen_number_new = function(arg0) {\n const ret = arg0;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_abda76e883ba8a5f = function() {\n const ret = new Error();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_stack_658279fe44541cf6 = function(arg0, arg1) {\n const ret = getObject(arg1).stack;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {\n let deferred0_0;\n let deferred0_1;\n try {\n deferred0_0 = arg0;\n deferred0_1 = arg1;\n console.error(getStringFromWasm0(arg0, arg1));\n } finally {\n wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);\n }\n };\n imports.wbg.__wbg_buffer_12d079cc21e14bdb = function(arg0) {\n const ret = getObject(arg0).buffer;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb = function(arg0, arg1, arg2) {\n const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_randomFillSync_5c9c955aa56b6049 = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).randomFillSync(takeObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_subarray_a1f73cd4b5b42fe1 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_getRandomValues_3aa56aa6edec874c = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).getRandomValues(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_set_a47bac70306a19a7 = function(arg0, arg1, arg2) {\n getObject(arg0).set(getObject(arg1), arg2 >>> 0);\n };\n imports.wbg.__wbg_crypto_1d1f22824a6a080c = function(arg0) {\n const ret = getObject(arg0).crypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_process_4a72847cc503995b = function(arg0) {\n const ret = getObject(arg0).process;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_versions_f686565e586dd935 = function(arg0) {\n const ret = getObject(arg0).versions;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_node_104a2ff8d6ea03a2 = function(arg0) {\n const ret = getObject(arg0).node;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_is_string = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'string';\n return ret;\n };\n imports.wbg.__wbg_require_cca90b1a94a0255b = function() { return handleError(function () {\n const ret = module.require;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_msCrypto_eb05e62b530a1508 = function(arg0) {\n const ret = getObject(arg0).msCrypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_e9b4878cebadb3d3 = function(arg0) {\n const ret = new Uint8Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_cd7af8117672b8b8 = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_get_bd8e338fbd5f5cc8 = function(arg0, arg1) {\n const ret = getObject(arg0)[arg1 >>> 0];\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_self_ce0dbfc45cf2f5be = function() { return handleError(function () {\n const ret = self.self;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_window_c6fb939a7f436783 = function() { return handleError(function () {\n const ret = window.window;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_globalThis_d1e6af4856ba331b = function() { return handleError(function () {\n const ret = globalThis.globalThis;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_global_207b558942527489 = function() { return handleError(function () {\n const ret = global.global;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_undefined = function(arg0) {\n const ret = getObject(arg0) === undefined;\n return ret;\n };\n imports.wbg.__wbg_newnoargs_e258087cd0daa0ea = function(arg0, arg1) {\n const ret = new Function(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_has_0af94d20077affa2 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.has(getObject(arg0), getObject(arg1));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_fetch_bc7c8e27076a5c84 = function(arg0) {\n const ret = fetch(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_fetch_921fad6ef9e883dd = function(arg0, arg1) {\n const ret = getObject(arg0).fetch(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {\n const ret = debugString(getObject(arg1));\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbindgen_throw = function(arg0, arg1) {\n throw new Error(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_rethrow = function(arg0) {\n throw takeObject(arg0);\n };\n imports.wbg.__wbg_then_a73caa9a87991566 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_then_0c86a60e8fcfe9f6 = function(arg0, arg1) {\n const ret = getObject(arg0).then(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_queueMicrotask_481971b0d87f3dd4 = function(arg0) {\n queueMicrotask(getObject(arg0));\n };\n imports.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6 = function(arg0) {\n const ret = getObject(arg0).queueMicrotask;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_resolve_b0083a7967828ec8 = function(arg0) {\n const ret = Promise.resolve(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_5d743fc9058ba01a = function() {\n const ret = Atomics.waitAsync;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_8cccba86b0f574cb = function(arg0) {\n const ret = new Int32Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_46d5c36955b71a79 = function(arg0, arg1, arg2) {\n const ret = Atomics.waitAsync(getObject(arg0), arg1, arg2);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_async_19c0400d97cc72fe = function(arg0) {\n const ret = getObject(arg0).async;\n return ret;\n };\n imports.wbg.__wbg_value_571d60108110e917 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_link_fc1eedd35dc7e0a6 = function(arg0) {\n const ret = \"data:application/javascript,\" + encodeURIComponent(`onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n `);\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_new_d1187ae36d662ef9 = function() { return handleError(function (arg0, arg1) {\n const ret = new Worker(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_setonmessage_503809e5bb51bd33 = function(arg0, arg1) {\n getObject(arg0).onmessage = getObject(arg1);\n };\n imports.wbg.__wbg_of_6a70eed8d41f469c = function(arg0, arg1, arg2) {\n const ret = Array.of(getObject(arg0), getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_postMessage_7380d10e8b8269df = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).postMessage(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_data_3ce7c145ca4fbcdc = function(arg0) {\n const ret = getObject(arg0).data;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_responseText_c67ed2d48db10769 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg1).responseText;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n }, arguments) };\n imports.wbg.__wbindgen_closure_wrapper5837 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 538, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_closure_wrapper5862 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 538, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n\n return imports;\n}\n\nfunction __wbg_init_memory(imports, maybe_memory) {\n imports.wbg.memory = maybe_memory || new WebAssembly.Memory({initial:25,maximum:65536,shared:true});\n}\n\nfunction __wbg_finalize_init(instance, module) {\n wasm = instance.exports;\n __wbg_init.__wbindgen_wasm_module = module;\n cachedBigInt64Memory0 = null;\n cachedInt32Memory0 = null;\n cachedUint8Memory0 = null;\n\n wasm.__wbindgen_start();\n return wasm;\n}\n\nfunction initSync(module, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n const imports = __wbg_get_imports();\n\n __wbg_init_memory(imports, maybe_memory);\n\n if (!(module instanceof WebAssembly.Module)) {\n module = new WebAssembly.Module(module);\n }\n\n const instance = new WebAssembly.Instance(module, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nasync function __wbg_init(input, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n\n const imports = __wbg_get_imports();\n\n if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {\n input = fetch(input);\n }\n\n __wbg_init_memory(imports, maybe_memory);\n\n const { instance, module } = await __wbg_load(await input, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nvar exports = /*#__PURE__*/Object.freeze({\n __proto__: null,\n Address: Address,\n Execution: Execution,\n ExecutionResponse: ExecutionResponse,\n Field: Field,\n KeyPair: KeyPair,\n Metadata: Metadata,\n OfflineQuery: OfflineQuery,\n PrivateKey: PrivateKey,\n PrivateKeyCiphertext: PrivateKeyCiphertext,\n Program: Program,\n ProgramManager: ProgramManager,\n ProvingKey: ProvingKey,\n RecordCiphertext: RecordCiphertext,\n RecordPlaintext: RecordPlaintext,\n Signature: Signature,\n Transaction: Transaction,\n VerifyingKey: VerifyingKey,\n ViewKey: ViewKey,\n default: __wbg_init,\n initSync: initSync,\n initThreadPool: initThreadPool,\n runRayonThread: runRayonThread,\n verifyFunctionExecution: verifyFunctionExecution\n});\n\nconst wasm_path = \"assets/aleo_wasm.wasm\";\n\n \n var Cargo = async (opt = {}) => {\n let {importHook, serverPath, initializeHook} = opt;\n\n let final_path = wasm_path;\n\n if (serverPath != null) {\n final_path = serverPath + /[^\\/\\\\]*$/.exec(final_path)[0];\n }\n\n if (importHook != null) {\n final_path = importHook(final_path);\n }\n\n if (initializeHook != null) {\n await initializeHook(__wbg_init, final_path);\n\n } else {\n await __wbg_init(final_path);\n }\n\n return exports;\n };\n\nexport { Cargo as default };\n//# sourceMappingURL=wasm.js.map\n","import wasm from \"../dist/wasm.js\";\n\nconst {\n initThreadPool: wasmInitThreadPool,\n Address,\n Execution,\n ExecutionResponse,\n Field,\n Metadata,\n OfflineQuery,\n Private,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n ProgramManager,\n Signature,\n Transaction,\n ViewKey,\n VerifyingKey,\n verifyFunctionExecution,\n} = await wasm({\n importHook: () => {\n return new URL(\"assets/aleo_wasm.wasm\", import.meta.url);\n },\n});\n\nasync function initThreadPool(threads) {\n if (threads == null) {\n threads = navigator.hardwareConcurrency;\n }\n\n console.info(`Spawning ${threads} threads`);\n\n await wasmInitThreadPool(new URL(\"worker.js\", import.meta.url), threads);\n}\n\nexport {\n initThreadPool,\n Address,\n Execution,\n ExecutionResponse,\n Field,\n Metadata,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n ProgramManager,\n Signature,\n Transaction,\n ViewKey,\n VerifyingKey,\n verifyFunctionExecution,\n};\n","/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nconst proxyMarker = Symbol(\"Comlink.proxy\");\nconst createEndpoint = Symbol(\"Comlink.endpoint\");\nconst releaseProxy = Symbol(\"Comlink.releaseProxy\");\nconst finalizer = Symbol(\"Comlink.finalizer\");\nconst throwMarker = Symbol(\"Comlink.thrown\");\nconst isObject = (val) => (typeof val === \"object\" && val !== null) || typeof val === \"function\";\n/**\n * Internal transfer handle to handle objects marked to proxy.\n */\nconst proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n};\n/**\n * Internal transfer handler to handle thrown exceptions.\n */\nconst throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n};\n/**\n * Allows customizing the serialization of certain values.\n */\nconst transferHandlers = new Map([\n [\"proxy\", proxyTransferHandler],\n [\"throw\", throwTransferHandler],\n]);\nfunction isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === \"*\") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n}\nfunction expose(obj, ep = globalThis, allowedOrigins = [\"*\"]) {\n ep.addEventListener(\"message\", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin '${ev.origin}' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case \"GET\" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case \"SET\" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case \"APPLY\" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case \"CONSTRUCT\" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case \"ENDPOINT\" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case \"RELEASE\" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === \"RELEASE\" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener(\"message\", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === \"function\") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError(\"Unserializable return value\"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n}\nfunction isMessagePort(endpoint) {\n return endpoint.constructor.name === \"MessagePort\";\n}\nfunction closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n}\nfunction wrap(ep, target) {\n return createProxy(ep, [], target);\n}\nfunction throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error(\"Proxy has been released and is not useable\");\n }\n}\nfunction releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: \"RELEASE\" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n}\nconst proxyCounter = new WeakMap();\nconst proxyFinalizers = \"FinalizationRegistry\" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\nfunction registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n}\nfunction unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n}\nfunction createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === \"then\") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: \"GET\" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: \"SET\" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: \"ENDPOINT\" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === \"bind\") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"APPLY\" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"CONSTRUCT\" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n}\nfunction myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n}\nfunction processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n}\nconst transferCache = new WeakMap();\nfunction transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n}\nfunction proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n}\nfunction windowEndpoint(w, context = globalThis, targetOrigin = \"*\") {\n return {\n postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\n addEventListener: context.addEventListener.bind(context),\n removeEventListener: context.removeEventListener.bind(context),\n };\n}\nfunction toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: \"HANDLER\" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: \"RAW\" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n}\nfunction fromWireValue(value) {\n switch (value.type) {\n case \"HANDLER\" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case \"RAW\" /* WireValueType.RAW */:\n return value.value;\n }\n}\nfunction requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener(\"message\", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener(\"message\", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n}\nfunction generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join(\"-\");\n}\n\nexport { createEndpoint, expose, finalizer, proxy, proxyMarker, releaseProxy, transfer, transferHandlers, windowEndpoint, wrap };\n//# sourceMappingURL=comlink.mjs.map\n"],"names":["Account","_privateKey","_viewKey","_address","constructor","params","this","privateKeyFromParams","e","console","error","Error","ViewKey","from_private_key","Address","fromCiphertext","ciphertext","password","PrivateKeyCiphertext","fromString","PrivateKey","fromPrivateKeyCiphertext","privateKey","to_string","seed","from_seed_unchecked","from_string","viewKey","address","toString","encryptAccount","toCiphertext","decryptRecord","decrypt","decryptRecords","ciphertexts","map","ownsRecordCiphertext","isOwner","RecordCiphertext","sign","message","verify","signature","async","get","url","options","response","fetch","ok","status","post","method","AleoNetworkClient","host","headers","account","setAccount","getAccount","setHost","fetchData","json","findUnspentRecords","startHeight","endHeight","amounts","maxMicrocredits","nonces","records","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","BigInt","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","length","transactions","j","confirmedTransaction","type","transaction","execution","transitions","k","transition","program","outputs","l","output","record","value","recordPlaintext","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","warn","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","key","logAndThrow","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","AleoKeyProviderParams","name","proverUri","verifierUri","cacheKey","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","KEY_STORE","Map","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","set","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","join","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","text","inner","unBondPublicKeys","OfflineSearchParams","verifyCreditsKeys","bondPublicKeyParams","bondValidatorKeyParams","claimUnbondPublicKeyParams","feePrivateKeyParams","feePublicKeyParams","inclusionKeyParams","joinKeyParams","setValidatorStateKeyParams","splitKeyParams","transferPrivateKeyParams","transferPrivateToPublicKeyParams","transferPublicKeyParams","transferPublicAsSignerKeyParams","transferPublicToPrivateKeyParams","unbondPublicKeyParams","OfflineKeyProvider","Promise","resolve","reject","undefined","isBondPublicProver","isBondPublicVerifier","isClaimUnbondPublicProver","isClaimUnbondPublicVerifier","isFeePrivateProver","isFeePrivateVerifier","isFeePublicProver","isFeePublicVerifier","isInclusionProver","isInclusionVerifier","isJoinProver","isJoinVerifier","isSetValidatorStateProver","isSetValidatorStateVerifier","isSplitProver","isSplitVerifier","isTransferPrivateProver","isTransferPrivateVerifier","isTransferPrivateToPublicProver","isTransferPrivateToPublicVerifier","isTransferPublicProver","isTransferPublicVerifier","isTransferPublicToPrivateProver","isTransferPublicToPrivateVerifier","isUnbondPublicProver","isUnbondPublicVerifier","insertBondPublicKeys","bondPublicVerifier","insertClaimUnbondPublicKeys","claimUnbondPublicVerifier","insertFeePrivateKeys","feePrivateVerifier","insertFeePublicKeys","feePublicVerifier","insertJoinKeys","joinVerifier","insertSetValidatorStateKeys","setValidatorStateVerifier","insertSplitKeys","splitVerifier","insertTransferPrivateKeys","transferPrivateVerifier","insertTransferPrivateToPublicKeys","transferPrivateToPublicVerifier","insertTransferPublicKeys","transferPublicVerifier","insertTransferPublicToPrivateKeys","transferPublicToPrivateVerifier","insertUnbondPublicKeys","unbondPublicVerifier","NetworkRecordProvider","networkClient","findCreditsRecords","unspent","searchParameters","findCreditsRecord","findRecord","findRecords","BlockHeightSearch","singletonWorker","createAleoWorker","worker","Worker","URL","wrap","ProgramManager","keyProvider","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set","initializeWasm","spawnWorker","module","memory","addEventListener","event","setTimeout","unref","capture","once","postMessage","wasm","heap","fill","getObject","idx","heap_next","dropObject","takeObject","ret","cachedTextDecoder","TextDecoder","ignoreBOM","fatal","decode","cachedUint8Memory0","getUint8Memory0","buffer","getStringFromWasm0","ptr","len","slice","addHeapObject","obj","WASM_VECTOR_LEN","cachedTextEncoder","TextEncoder","encode","encodeString","arg","view","buf","read","written","passStringToWasm0","malloc","realloc","subarray","mem","offset","code","charCodeAt","isLikeNone","x","cachedInt32Memory0","getInt32Memory0","Int32Array","debugString","val","description","isArray","builtInMatches","exec","call","className","JSON","stringify","_","stack","CLOSURE_DTORS","FinalizationRegistry","register","unregister","state","__wbindgen_export_3","dtor","a","b","makeMutClosure","arg0","arg1","f","cnt","real","args","original","__wbg_adapter_34","arg2","_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3","_assertClass","instance","klass","passArray8ToWasm0","verifyFunctionExecution$1","retptr","__wbindgen_add_to_stack_pointer","Execution$1","VerifyingKey$1","Program$1","ptr0","__wbindgen_malloc","__wbindgen_realloc","len0","__wbg_ptr","r0","r1","cachedBigInt64Memory0","getBigInt64Memory0","BigInt64Array","getArrayU8FromWasm0","runRayonThread","receiver","initThreadPool$1","num_threads","initThreadPool","handleError","apply","__wbindgen_exn_store","__wbg_adapter_281","arg3","wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7","AddressFinalization","__wbg_address_free","__wrap","create","prototype","__destroy_into_raw","free","private_key","PrivateKey$1","address_from_private_key","from_view_key","view_key","ViewKey$1","address_from_view_key","address_from_string","deferred1_0","deferred1_1","address_to_string","__wbindgen_free","Signature$1","address_verify","ExecutionFinalization","__wbg_execution_free","Execution","execution_toString","execution_fromString","ExecutionResponseFinalization","__wbg_executionresponse_free","ExecutionResponse","getOutputs","executionresponse_getOutputs","executionresponse_getExecution","executionresponse_getKeys","KeyPair","getProvingKey","executionresponse_getProvingKey","ProvingKey$1","executionresponse_getVerifyingKey","executionresponse_getFunctionId","executionresponse_getProgram","FieldFinalization","__wbg_field_free","Field","field_toString","field","field_fromString","KeyPairFinalization","__wbg_keypair_free","ptr1","keypair_new","keypair_provingKey","keypair_verifyingKey","MetadataFinalization","__wbg_metadata_free","__wbg_get_metadata_name","__wbg_set_metadata_name","__wbg_get_metadata_locator","__wbg_set_metadata_locator","__wbg_get_metadata_prover","__wbg_set_metadata_prover","__wbg_get_metadata_verifier","__wbg_set_metadata_verifier","__wbg_get_metadata_verifyingKey","__wbg_set_metadata_verifyingKey","metadata_baseUrl","metadata_bond_public","metadata_bond_validator","metadata_claim_unbond_public","metadata_fee_private","metadata_fee_public","metadata_inclusion","metadata_join","metadata_set_validator_state","metadata_split","metadata_transfer_private","metadata_transfer_private_to_public","metadata_transfer_public","metadata_transfer_public_as_signer","metadata_transfer_public_to_private","metadata_unbond_public","OfflineQueryFinalization","__wbg_offlinequery_free","OfflineQuery","state_root","offlinequery_new","addStatePath","commitment","state_path","len1","offlinequery_addStatePath","offlinequery_toString","s","offlinequery_fromString","PrivateKeyFinalization","__wbg_privatekey_free","privatekey_new","privatekey_from_seed_unchecked","privatekey_from_string","privatekey_to_string","privatekey_to_view_key","to_address","privatekey_to_address","Address$1","privatekey_sign","newEncrypted","secret","privatekey_newEncrypted","PrivateKeyCiphertext$1","privatekey_toCiphertext","privatekey_fromPrivateKeyCiphertext","PrivateKeyCiphertextFinalization","__wbg_privatekeyciphertext_free","encryptPrivateKey","decryptToPrivateKey","privatekeyciphertext_decryptToPrivateKey","privatekeyciphertext_toString","privatekeyciphertext_fromString","ProgramFinalization","__wbg_program_free","program_fromString","program_toString","hasFunction","program_hasFunction","getFunctions","program_getFunctions","getFunctionInputs","program_getFunctionInputs","getMappings","program_getMappings","getRecordMembers","record_name","program_getRecordMembers","getStructMembers","struct_name","program_getStructMembers","program_getCreditsProgram","program_id","program_address","isEqual","other","program_isEqual","program_getImports","ProgramManagerFinalization","__wbg_programmanager_free","fee_credits","fee_record","fee_proving_key","fee_verifying_key","offline_query","RecordPlaintext$1","ptr2","len2","ptr3","ptr4","ptr5","OfflineQuery$1","programmanager_buildDeploymentTransaction","estimateDeploymentFee","programmanager_estimateDeploymentFee","estimateProgramNameCost","programmanager_estimateProgramNameCost","r2","asUintN","_function","prove_execution","len4","programmanager_executeFunctionOffline","len3","ptr6","ptr7","ptr8","programmanager_buildExecutionTransaction","estimateExecutionFee","programmanager_estimateExecutionFee","estimateFinalizeFee","programmanager_estimateFinalizeFee","record_1","record_2","join_proving_key","join_verifying_key","programmanager_buildJoinTransaction","split_amount","amount_record","split_proving_key","split_verifying_key","programmanager_buildSplitTransaction","amount_credits","transfer_type","transfer_proving_key","transfer_verifying_key","ptr9","programmanager_buildTransferTransaction","programmanager_synthesizeKeyPair","ProvingKeyFinalization","__wbg_provingkey_free","provingkey_isBondPublicProver","isBondValidatorProver","provingkey_isBondValidatorProver","provingkey_isClaimUnbondPublicProver","provingkey_isFeePrivateProver","provingkey_isFeePublicProver","provingkey_isInclusionProver","provingkey_isJoinProver","provingkey_isSetValidatorStateProver","provingkey_isSplitProver","provingkey_isTransferPrivateProver","provingkey_isTransferPrivateToPublicProver","provingkey_isTransferPublicProver","isTransferPublicAsSignerProver","provingkey_isTransferPublicAsSignerProver","provingkey_isTransferPublicToPrivateProver","provingkey_isUnbondPublicProver","checksum","provingkey_checksum","copy","provingkey_copy","bytes","provingkey_fromBytes","string","provingkey_fromString","provingkey_toBytes","v1","provingkey_toString","RecordCiphertextFinalization","__wbg_recordciphertext_free","recordciphertext_fromString","recordciphertext_toString","recordciphertext_decrypt","recordciphertext_isOwner","RecordPlaintextFinalization","__wbg_recordplaintext_free","recordplaintext_commitment","Field$1","recordplaintext_fromString","recordplaintext_toString","recordplaintext_microcredits","recordplaintext_nonce","deferred4_0","deferred4_1","recordplaintext_serialNumberString","r3","SignatureFinalization","__wbg_signature_free","Signature","signature_verify","signature_from_string","signature_to_string","TransactionFinalization","__wbg_transaction_free","transaction_fromString","transaction_toString","transactionId","transaction_transactionId","transactionType","transaction_transactionType","VerifyingKeyFinalization","__wbg_verifyingkey_free","verifyingkey_bondPublicVerifier","bondValidatorVerifier","verifyingkey_bondValidatorVerifier","verifyingkey_claimUnbondPublicVerifier","verifyingkey_feePrivateVerifier","verifyingkey_feePublicVerifier","inclusionVerifier","verifyingkey_inclusionVerifier","verifyingkey_joinVerifier","verifyingkey_setValidatorStateVerifier","verifyingkey_splitVerifier","verifyingkey_transferPrivateVerifier","verifyingkey_transferPrivateToPublicVerifier","verifyingkey_transferPublicVerifier","transferPublicAsSignerVerifier","verifyingkey_transferPublicAsSignerVerifier","verifyingkey_transferPublicToPrivateVerifier","verifyingkey_unbondPublicVerifier","verifyingkey_isBondPublicVerifier","isBondValidatorVerifier","verifyingkey_isBondValidatorVerifier","verifyingkey_isClaimUnbondPublicVerifier","verifyingkey_isFeePrivateVerifier","verifyingkey_isFeePublicVerifier","verifyingkey_isInclusionVerifier","verifyingkey_isJoinVerifier","verifyingkey_isSetValidatorStateVerifier","verifyingkey_isSplitVerifier","verifyingkey_isTransferPrivateVerifier","verifyingkey_isTransferPrivateToPublicVerifier","verifyingkey_isTransferPublicVerifier","isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicToPrivateVerifier","verifyingkey_isUnbondPublicVerifier","verifyingkey_checksum","verifyingkey_copy","verifyingkey_fromBytes","verifyingkey_fromString","verifyingkey_toBytes","verifyingkey_toString","ViewKeyFinalization","__wbg_viewkey_free","viewkey_from_string","viewkey_to_string","deferred3_0","deferred3_1","viewkey_decrypt","__wbg_load","Response","WebAssembly","instantiateStreaming","instantiate","Instance","__wbg_get_imports","wbg","__wbindgen_object_drop_ref","__wbg_new_71801a555ad9f2aa","XMLHttpRequest","arguments","__wbg_overrideMimeType_ee9c51919ceb418b","overrideMimeType","__wbg_open_c9eb0cf2c9d95679","arg4","arg5","open","__wbg_send_80d29985093c1ec5","send","__wbg_response_7c2e2759084f7279","__wbg_status_d485fb5a478426fb","__wbg_new_72fb9a18b5ae2624","__wbindgen_string_new","__wbg_set_1f9b04f170055d33","Reflect","__wbg_new_ab6fd82b10560829","Headers","__wbindgen_object_clone_ref","__wbg_new_0d76b0581eca6298","AbortController","__wbg_signal_a61f78a3478fd9bc","signal","__wbg_append_7bfcb4937d1d5e29","append","__wbg_instanceof_Response_849eb93e75734b6e","result","__wbg_status_61a01141acd3cf74","__wbg_url_5f6dc4009ac5f99d","__wbg_headers_9620bfada380764a","__wbg_iterator_2cee6dadfd956dfa","Symbol","iterator","__wbg_get_e3c254076557e348","__wbindgen_is_function","__wbg_call_27c0f87801dedf93","__wbindgen_is_object","__wbg_next_40fc327bfc8770e6","next","__wbg_next_196c84450b364254","__wbg_done_298b57d23c0fc80c","done","__wbg_value_d93c65011f51a456","__wbg_abort_2aa7521d5690750e","abort","__wbg_stringify_8887fe74e1c50d81","__wbindgen_string_get","__wbg_log_0159ca40cddf5b15","__wbindgen_bigint_from_u64","__wbg_call_b3ca7c6051f9bec1","__wbg_transaction_new","Transaction$1","__wbg_keypair_new","__wbindgen_module","__wbg_init","__wbindgen_wasm_module","__wbindgen_memory","__wbg_spawnWorker_f6acaddb2e29dc4a","__wbg_executionresponse_new","ExecutionResponse$1","__wbg_newwithlength_66ae46612e7f0234","__wbg_set_d4638f722068f043","__wbindgen_cb_drop","__wbg_new_16b304a2cfa7ff4a","__wbg_push_a5b05aedc7234f9f","__wbg_arrayBuffer_29931d52c7206b02","__wbg_new_63b92bc8671ed464","__wbg_length_c20a40f15020d68a","__wbg_new_81740750da40724f","state0","cb0","__wbindgen_number_new","__wbg_new_abda76e883ba8a5f","__wbg_stack_658279fe44541cf6","__wbg_error_f851667af71bcfc6","deferred0_0","deferred0_1","__wbg_buffer_12d079cc21e14bdb","__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb","__wbg_randomFillSync_5c9c955aa56b6049","randomFillSync","__wbg_subarray_a1f73cd4b5b42fe1","__wbg_getRandomValues_3aa56aa6edec874c","getRandomValues","__wbg_set_a47bac70306a19a7","__wbg_crypto_1d1f22824a6a080c","crypto","__wbg_process_4a72847cc503995b","process","__wbg_versions_f686565e586dd935","versions","__wbg_node_104a2ff8d6ea03a2","node","__wbindgen_is_string","__wbg_require_cca90b1a94a0255b","require","__wbg_msCrypto_eb05e62b530a1508","msCrypto","__wbg_newwithlength_e9b4878cebadb3d3","__wbg_length_cd7af8117672b8b8","__wbg_get_bd8e338fbd5f5cc8","__wbg_self_ce0dbfc45cf2f5be","self","__wbg_window_c6fb939a7f436783","window","__wbg_globalThis_d1e6af4856ba331b","globalThis","__wbg_global_207b558942527489","global","__wbindgen_is_undefined","__wbg_newnoargs_e258087cd0daa0ea","Function","__wbg_has_0af94d20077affa2","__wbg_fetch_bc7c8e27076a5c84","__wbg_fetch_921fad6ef9e883dd","__wbindgen_debug_string","__wbindgen_throw","__wbindgen_rethrow","__wbg_then_a73caa9a87991566","then","__wbg_then_0c86a60e8fcfe9f6","__wbg_queueMicrotask_481971b0d87f3dd4","queueMicrotask","__wbg_queueMicrotask_3cbae2ec6b6cd3d6","__wbg_resolve_b0083a7967828ec8","__wbg_waitAsync_5d743fc9058ba01a","Atomics","waitAsync","__wbg_new_8cccba86b0f574cb","__wbg_waitAsync_46d5c36955b71a79","__wbg_async_19c0400d97cc72fe","__wbg_value_571d60108110e917","__wbindgen_link_fc1eedd35dc7e0a6","encodeURIComponent","__wbg_new_d1187ae36d662ef9","__wbg_setonmessage_503809e5bb51bd33","onmessage","__wbg_of_6a70eed8d41f469c","of","__wbg_postMessage_7380d10e8b8269df","__wbg_data_3ce7c145ca4fbcdc","__wbg_newwithstrandinit_3fd6fba4083ff2d0","Request","__wbg_responseText_c67ed2d48db10769","responseText","__wbindgen_closure_wrapper5837","__wbindgen_closure_wrapper5862","__wbg_init_memory","maybe_memory","Memory","initial","maximum","shared","__wbg_finalize_init","exports","__wbindgen_start","initSync","Module","input","freeze","__proto__","Metadata$1","RecordCiphertext$1","default","wasm_path","wasmInitThreadPool","Private","opt","importHook","serverPath","initializeHook","final_path","Cargo","threads","navigator","hardwareConcurrency","info","proxyMarker","createEndpoint","releaseProxy","finalizer","throwMarker","isObject","transferHandlers","canHandle","serialize","port1","port2","MessageChannel","expose","deserialize","port","serialized","isError","ep","allowedOrigins","callback","ev","origin","allowedOrigin","RegExp","test","isAllowedOrigin","path","argumentList","fromWireValue","returnValue","parent","reduce","prop","rawValue","proxy","transfers","transferCache","catch","wireValue","transferables","toWireValue","removeEventListener","closeEndPoint","TypeError","endpoint","isMessagePort","close","target","createProxy","throwIfProxyReleased","isReleased","releaseEndpoint","requestResponseMessage","proxyCounter","WeakMap","proxyFinalizers","newCount","isProxyReleased","Proxy","_target","unregisterProxy","r","p","bind","_thisArg","rawArgumentList","last","processArguments","construct","registerProxy","processed","v","arr","concat","handler","serializedValue","msg","floor","random","Number","MAX_SAFE_INTEGER"],"sourceRoot":""} \ No newline at end of file diff --git a/520.bundle.js b/520.bundle.js deleted file mode 100644 index 5b5f60e95..000000000 --- a/520.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{var r,e,t,o,a,n,i={},p={};function c(r){var e=p[r];if(void 0!==e)return e.exports;var t=p[r]={exports:{}};return i[r](t,t.exports,c),t.exports}c.m=i,c.x=()=>{var r=c.O(void 0,[933,383],(()=>c(5383)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,i)=>{var p;i&&((p=[]).d=-1);var c,s,f,l=new Set,u=a.exports,b=new Promise(((r,e)=>{f=e,s=r}));b[e]=u,b[r]=r=>(p&&r(p),l.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{i[e]=r,o(n)}),(r=>{i[t]=r,o(n)}));var i={};return i[r]=r=>r(n),i}}var p={};return p[r]=r=>{},p[e]=a,p})))(a);var i=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(i)).r=0;var t=r=>r!==p&&!l.has(r)&&(l.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:i()}),(r=>(r?f(b[t]=r):s(u),o(p)))),p&&p.d<0&&(p.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(f=0;f=o)&&Object.keys(c.O).every((r=>c.O[r](e[p])))?e.splice(p--,1):(i=!1,o0&&a[f-1][2]>o;f--)a[f]=a[f-1];a[f]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&!r;)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={520:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var i in a)c.o(a,i)&&(c.m[i]=a[i]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([c.e(933),c.e(383)]).then(n);c.x()})(); -//# sourceMappingURL=520.bundle.js.map \ No newline at end of file diff --git a/520.bundle.js.map b/520.bundle.js.map deleted file mode 100644 index 8752d4ed8..000000000 --- a/520.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"520.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC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AeD,EAAY9E,EAAoBqE,EAAEW,SAAW,IACtF,IAAIC,EAAWjF,EAAoBqE,EAAEY,SACrC,IAAKH,GAAaG,IACbA,EAASC,gBACZJ,EAAYG,EAASC,cAAcC,MAC/BL,GAAW,CACf,IAAIM,EAAUH,EAASI,qBAAqB,UAC5C,GAAGD,EAAQlC,OAEV,IADA,IAAID,EAAImC,EAAQlC,OAAS,EAClBD,GAAK,IAAM6B,GAAWA,EAAYM,EAAQnC,KAAKkC,GAExD,CAID,IAAKL,EAAW,MAAM,IAAIQ,MAAM,yDAChCR,EAAYA,EAAUS,QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpFvF,EAAoBwF,EAAIV,C,WClBxB9E,EAAoByF,EAAIC,KAAKV,SAAW,GAIxC,IAAIW,EAAkB,CACrB,IAAK,GAgBN3F,EAAoB+D,EAAEd,EAAI,CAACe,EAASG,KAE/BwB,EAAgB3B,IAElBe,cAAc/E,EAAoBwF,EAAIxF,EAAoBoE,EAAEJ,GAE9D,EAGD,IAAI4B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBlD,KAAKoD,KAAKF,GAC9DA,EAAmBlD,KAvBCqD,IACnB,IAAKlD,EAAUmD,EAAaC,GAAWF,EACvC,IAAI,IAAI9F,KAAY+F,EAChBhG,EAAoB2D,EAAEqC,EAAa/F,KACrCD,EAAoBO,EAAEN,GAAY+F,EAAY/F,IAIhD,IADGgG,GAASA,EAAQjG,GACd6C,EAASK,QACdyC,EAAgB9C,EAASqD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BjG,EAAOE,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChBkB,QAAQuC,IAAI,CAClBjE,EAAoBkC,EAAE,KACtBlC,EAAoBkC,EAAE,OACpBF,KAAKlC,GSJiBE,EAAoBQ,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(933),\n\t\t__webpack_require__.e(383)\n\t]).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [933,383], () => (__webpack_require__(5383)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && !scriptUrl) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t520: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/523.bundle.js b/523.bundle.js index d8169b024..7d84f2738 100644 --- a/523.bundle.js +++ b/523.bundle.js @@ -1,3 +1,3 @@ /*! For license information please see 523.bundle.js.LICENSE.txt */ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[523,879],{2851:(e,t,r)=>{e.exports=r.p+"ed5d9d6957e80846ebe2.js"},6545:(e,t,r)=>{e.exports=r.p+"210d0782d748f9305082.wasm"},9523:(e,t,r)=>{r.a(e,(async(e,n)=>{try{r.r(t),r.d(t,{Account:()=>o,Address:()=>i.pV,AleoKeyProvider:()=>u,AleoKeyProviderParams:()=>l,AleoNetworkClient:()=>g,BlockHeightSearch:()=>p,CREDITS_PROGRAM_KEYS:()=>S,ExecutionResponse:()=>i.qp,Field:()=>i.D0,FunctionExecution:()=>i.Zc,KEY_STORE:()=>k,NetworkRecordProvider:()=>b,OfflineKeyProvider:()=>w,OfflineQuery:()=>i.c7,OfflineSearchParams:()=>f,PRIVATE_TO_PUBLIC_TRANSFER:()=>R,PRIVATE_TRANSFER:()=>F,PRIVATE_TRANSFER_TYPES:()=>T,PUBLIC_TO_PRIVATE_TRANSFER:()=>A,PUBLIC_TRANSFER:()=>V,PUBLIC_TRANSFER_AS_SIGNER:()=>x,PrivateKey:()=>i.ZD,PrivateKeyCiphertext:()=>i.LW,Program:()=>i.BP,ProgramManager:()=>v,ProgramManagerBase:()=>i.Ao,ProvingKey:()=>i.$7,RecordCiphertext:()=>i.KC,RecordPlaintext:()=>i.ZF,Signature:()=>i.to,Transaction:()=>i.ZX,VALID_TRANSFER_TYPES:()=>E,VerifyingKey:()=>i.pF,ViewKey:()=>i.hv,createAleoWorker:()=>h,initThreadPool:()=>i.Fs,initializeWasm:()=>B,logAndThrow:()=>C,verifyFunctionExecution:()=>i.Yc});r(5357);var i=r(9879),_=r(9720),a=e([i]);i=(a.then?(await a)():a)[0];class o{_privateKey;_viewKey;_address;constructor(e={}){try{this._privateKey=this.privateKeyFromParams(e)}catch(e){throw console.error("Wrong parameter",e),new Error("Wrong Parameter")}this._viewKey=i.hv.from_private_key(this._privateKey),this._address=i.pV.from_private_key(this._privateKey)}static fromCiphertext(e,t){try{e="string"==typeof e?i.LW.fromString(e):e;const r=i.ZD.fromPrivateKeyCiphertext(e,t);return new o({privateKey:r.to_string()})}catch(e){throw new Error("Wrong password or invalid ciphertext")}}privateKeyFromParams(e){return e.seed?i.ZD.from_seed_unchecked(e.seed):e.privateKey?i.ZD.from_string(e.privateKey):new i.ZD}privateKey(){return this._privateKey}viewKey(){return this._viewKey}address(){return this._address}toString(){return this.address().to_string()}encryptAccount(e){return this._privateKey.toCiphertext(e)}decryptRecord(e){return this._viewKey.decrypt(e)}decryptRecords(e){return e.map((e=>this._viewKey.decrypt(e)))}ownsRecordCiphertext(e){if("string"!=typeof e)return e.isOwner(this._viewKey);try{return i.KC.fromString(e).isOwner(this._viewKey)}catch(e){return!1}}sign(e){return this._privateKey.sign(e)}verify(e,t){return this._address.verify(e,t)}}function s(e){return JSON.parse(e,(function(e,t,r){return Number.isInteger(t)?BigInt(r.source):t}))}async function c(e,t){const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not get URL "+e);return r}async function d(e,t){t.method="POST";const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not post URL "+e);return r}class g{host;headers;account;constructor(e,t){this.host=e+"/testnet",t&&t.headers?this.headers=t.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const t=await c(this.host+e,{headers:this.headers});return s(await t.text())}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,t,r,n,_,a){if(a=a||[],e<0)throw new Error("Start height must be greater than or equal to 0");const o=new Array;let s,c,d,g,l=0,u=BigInt(0);if(void 0===r){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");d=this.account._privateKey}else try{d=r instanceof i.ZD?r:i.ZD.from_string(r)}catch(e){throw new Error("Error parsing private key provided.")}const f=d.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");g=e}catch(e){throw new Error("Error fetching latest block height.")}if(c="number"==typeof t&&t<=g?t:g,e>c)throw new Error("Start height must be less than or equal to end height.");for(;c>e;){s=c-50,s=BigInt(_))))return o;if(void 0!==n&&n.length>0){let e=0;if(t.microcredits()>n[e]){if(e+=1,o.push(t),"number"==typeof _&&(u+=t.microcredits(),u>=BigInt(_)))return o;if(o.length>=n.length)return o}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+s.toString()+"-"+c.toString()),console.warn("Error: ",e),l+=1,l>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),o}}return o}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,t){try{return await this.fetchData("/blocks?start="+e+"&end="+t)}catch(r){throw new Error(`Error fetching blocks between ${e} and ${t}.`)}}async getDeploymentTransactionIDForProgram(e){e instanceof i.BP&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const t=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(t)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return Number(await this.fetchData("/latest/height"))}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return i.BP.fromString(e)}catch(t){try{return i.BP.fromString(await this.getProgram(e))}catch(t){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const t={},r=(e instanceof i.BP?e:await this.getProgramObject(e)).getImports();for(let e=0;e{if(void 0===e)r(new Error("No search parameters provided, cannot retrieve keys"));else{const n=e.cacheKey,_=e.verifyCreditsKeys;if(this.cache.has(n)){const[e,a]=this.cache.get(n),o=i.$7.fromBytes(e),s=i.pF.fromBytes(a);if(_){this.verifyCreditsKeys(n,o,s)||r(new Error(`Cached keys do not match expected keys for ${n}`))}t([o,s])}else r(new Error("Keys not found in cache for "+n))}}))}verifyCreditsKeys(e,t,r){switch(e){case S.bond_public.locator:return t.isBondPublicProver()&&r.isBondPublicVerifier();case S.claim_unbond_public.locator:return t.isClaimUnbondPublicProver()&&r.isClaimUnbondPublicVerifier();case S.fee_private.locator:return t.isFeePrivateProver()&&r.isFeePrivateVerifier();case S.fee_public.locator:return t.isFeePublicProver()&&r.isFeePublicVerifier();case S.inclusion.locator:return t.isInclusionProver()&&r.isInclusionVerifier();case S.join.locator:return t.isJoinProver()&&r.isJoinVerifier();case S.set_validator_state.locator:return t.isSetValidatorStateProver()&&r.isSetValidatorStateVerifier();case S.split.locator:return t.isSplitProver()&&r.isSplitVerifier();case S.transfer_private.locator:return t.isTransferPrivateProver()&&r.isTransferPrivateVerifier();case S.transfer_private_to_public.locator:return t.isTransferPrivateToPublicProver()&&r.isTransferPrivateToPublicVerifier();case S.transfer_public.locator:return t.isTransferPublicProver()&&r.isTransferPublicVerifier();case S.transfer_public_to_private.locator:return t.isTransferPublicToPrivateProver()&&r.isTransferPublicToPrivateVerifier();case S.unbond_public.locator:return t.isUnbondPublicProver()&&r.isUnbondPublicVerifier();default:return!1}}feePrivateKeys(){return this.functionKeys(f.feePrivateKeyParams())}feePublicKeys(){return this.functionKeys(f.feePublicKeyParams())}joinKeys(){return this.functionKeys(f.joinKeyParams())}splitKeys(){return this.functionKeys(f.splitKeyParams())}transferKeys(e){if(F.has(e))return this.functionKeys(f.transferPrivateKeyParams());if(R.has(e))return this.functionKeys(f.transferPrivateToPublicKeyParams());if(V.has(e))return this.functionKeys(f.transferPublicKeyParams());if(x.has(e))return this.functionKeys(f.transferPublicAsSignerKeyParams());if(A.has(e))return this.functionKeys(f.transferPublicToPrivateKeyParams());throw new Error("Invalid visibility type")}async unBondPublicKeys(){return this.functionKeys(f.unbondPublicKeyParams())}insertBondPublicKeys(e){if(!e.isBondPublicProver())throw new Error("Attempted to insert invalid proving keys for bond_public");this.cache.set(S.bond_public.locator,[e.toBytes(),i.pF.bondPublicVerifier().toBytes()])}insertClaimUnbondPublicKeys(e){if(!e.isClaimUnbondPublicProver())throw new Error("Attempted to insert invalid proving keys for claim_unbond_public");this.cache.set(S.claim_unbond_public.locator,[e.toBytes(),i.pF.claimUnbondPublicVerifier().toBytes()])}insertFeePrivateKeys(e){if(!e.isFeePrivateProver())throw new Error("Attempted to insert invalid proving keys for fee_private");this.cache.set(S.fee_private.locator,[e.toBytes(),i.pF.feePrivateVerifier().toBytes()])}insertFeePublicKeys(e){if(!e.isFeePublicProver())throw new Error("Attempted to insert invalid proving keys for fee_public");this.cache.set(S.fee_public.locator,[e.toBytes(),i.pF.feePublicVerifier().toBytes()])}insertJoinKeys(e){if(!e.isJoinProver())throw new Error("Attempted to insert invalid proving keys for join");this.cache.set(S.join.locator,[e.toBytes(),i.pF.joinVerifier().toBytes()])}insertSetValidatorStateKeys(e){if(!e.isSetValidatorStateProver())throw new Error("Attempted to insert invalid proving keys for set_validator_state");this.cache.set(S.set_validator_state.locator,[e.toBytes(),i.pF.setValidatorStateVerifier().toBytes()])}insertSplitKeys(e){if(!e.isSplitProver())throw new Error("Attempted to insert invalid proving keys for split");this.cache.set(S.split.locator,[e.toBytes(),i.pF.splitVerifier().toBytes()])}insertTransferPrivateKeys(e){if(!e.isTransferPrivateProver())throw new Error("Attempted to insert invalid proving keys for transfer_private");this.cache.set(S.transfer_private.locator,[e.toBytes(),i.pF.transferPrivateVerifier().toBytes()])}insertTransferPrivateToPublicKeys(e){if(!e.isTransferPrivateToPublicProver())throw new Error("Attempted to insert invalid proving keys for transfer_private_to_public");this.cache.set(S.transfer_private_to_public.locator,[e.toBytes(),i.pF.transferPrivateToPublicVerifier().toBytes()])}insertTransferPublicKeys(e){if(!e.isTransferPublicProver())throw new Error("Attempted to insert invalid proving keys for transfer_public");this.cache.set(S.transfer_public.locator,[e.toBytes(),i.pF.transferPublicVerifier().toBytes()])}insertTransferPublicToPrivateKeys(e){if(!e.isTransferPublicToPrivateProver())throw new Error("Attempted to insert invalid proving keys for transfer_public_to_private");this.cache.set(S.transfer_public_to_private.locator,[e.toBytes(),i.pF.transferPublicToPrivateVerifier().toBytes()])}insertUnbondPublicKeys(e){if(!e.isUnbondPublicProver())throw new Error("Attempted to insert invalid proving keys for unbond_public");this.cache.set(S.unbond_public.locator,[e.toBytes(),i.pF.unbondPublicVerifier().toBytes()])}}class b{account;networkClient;constructor(e,t){this.account=e,this.networkClient=t}setAccount(e){this.account=e}async findCreditsRecords(e,t,r,n){let i=0,_=0;if(n&&("startHeight"in n&&"number"==typeof n.endHeight&&(i=n.startHeight),"endHeight"in n&&"number"==typeof n.endHeight&&(_=n.endHeight)),0==_){_=await this.networkClient.getLatestHeight()}return i>=_&&C("Start height must be less than end height"),await this.networkClient.findUnspentRecords(i,_,this.account.privateKey(),e,void 0,r)}async findCreditsRecord(e,t,r,n){let i=null;try{i=await this.findCreditsRecords([e],t,r,n)}catch(e){}if(i&&i.length>0)return i[0];throw console.error("Record not found with error:",i),new Error("Record not found")}async findRecord(e,t,r){throw new Error("Method not implemented.")}async findRecords(e,t,r){throw new Error("Method not implemented.")}}class p{startHeight;endHeight;constructor(e,t){this.startHeight=e,this.endHeight=t}}let y=null;const h=()=>{if(!y){const e=new Worker(new URL(r.p+r.u(427),r.b),{type:void 0});y=(0,_.LV)(e)}return y};class v{account;keyProvider;host;networkClient;recordProvider;constructor(e,t,r){this.host=e||"https://api.explorer.provable.com/v1",this.networkClient=new g(this.host),this.keyProvider=t||new u,this.recordProvider=r}setAccount(e){this.account=e}setKeyProvider(e){this.keyProvider=e}setHost(e){this.host=e,this.networkClient.setHost(e)}setRecordProvider(e){this.recordProvider=e}async deploy(e,t,r,n,_,a){try{const t=i.BP.fromString(e);let r;try{r=await this.networkClient.getProgram(t.id())}catch(e){console.log(`Program ${t.id()} does not exist on the network, deploying...`)}if("string"==typeof r)throw`Program ${t.id()} already exists on the network, please rename your program`}catch(e){C(`Error validating program: ${e.message}`)}let o,s=a;if(void 0===a&&void 0!==this.account&&(s=this.account.privateKey()),void 0===s)throw"No private key provided and no private key set in the ProgramManager";try{_=r?await this.getCreditsRecord(t,[],_,n):void 0}catch(e){C(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{o=r?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys()}catch(e){C(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[c,d]=o;let g;try{g=await this.networkClient.getProgramImports(e)}catch(e){C(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}const l=await i.Ao.buildDeploymentTransaction(s,e,t,_,this.host,g,c,d);return await this.networkClient.submitTransaction(l)}async buildExecutionTransaction(e){const{programName:t,functionName:r,fee:n,privateFee:_,inputs:a,recordSearchParams:o,keySearchParams:s,privateKey:c,offlineQuery:d}=e;let g=e.feeRecord,l=e.provingKey,u=e.verifyingKey,f=e.program,w=e.imports;if(void 0===f)try{f=await this.networkClient.getProgram(t)}catch(e){C(`Error finding ${t}. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`)}else f instanceof i.BP&&(f=f.toString());let b,p=c;if(void 0===c&&void 0!==this.account&&(p=this.account.privateKey()),void 0===p)throw"No private key provided and no private key set in the ProgramManager";try{g=_?await this.getCreditsRecord(n,[],g,o):void 0}catch(e){C(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{b=_?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys()}catch(e){C(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[y,h]=b;if(!l||!u)try{[l,u]=await this.keyProvider.functionKeys(s)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}if(i.BP.fromString(f).getImports().length>0&&!w)try{w=await this.networkClient.getProgramImports(t)}catch(e){C(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await i.Ao.buildExecutionTransaction(p,f,r,a,n,g,this.host,w,l,u,y,h,d)}async execute(e){const t=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(t)}async run(e,t,r,n,_,a,o,s,c,d){let g=c;if(void 0===c&&void 0!==this.account&&(g=this.account.privateKey()),void 0===g)throw"No private key provided and no private key set in the ProgramManager";if(!o||!s)try{[o,s]=await this.keyProvider.functionKeys(a)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",o),console.log("Verifying key: ",s),i.Ao.executeFunctionOffline(g,e,t,r,n,!1,_,o,s,this.host,d)}async join(e,t,r,n,_,a,o,s){let c,d,g=o;if(void 0===o&&void 0!==this.account&&(g=this.account.privateKey()),void 0===g)throw"No private key provided and no private key set in the ProgramManager";try{c=n?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),d=await this.keyProvider.joinKeys()}catch(e){C(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[l,u]=c,[f,w]=d;try{a=n?await this.getCreditsRecord(r,[],a,_):void 0}catch(e){C(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof i.ZF?e:i.ZF.fromString(e),t=t instanceof i.ZF?t:i.ZF.fromString(t)}catch(e){C("Records provided are not valid. Please ensure they are valid plaintext records.")}const b=await i.Ao.buildJoinTransaction(g,e,t,r,a,this.host,f,w,l,u,s);return await this.networkClient.submitTransaction(b)}async split(e,t,r,n){let _,a=r;if(void 0===a&&void 0!==this.account&&(a=this.account.privateKey()),void 0===a)throw"No private key provided and no private key set in the ProgramManager";try{_=await this.keyProvider.splitKeys()}catch(e){C(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[o,s]=_;try{t=t instanceof i.ZF?t:i.ZF.fromString(t)}catch(e){C("Record provided is not valid. Please ensure it is a valid plaintext record.")}const c=await i.Ao.buildSplitTransaction(a,e,t,this.host,o,s,n);return await this.networkClient.submitTransaction(c)}async synthesizeKeys(e,t,r,n){let _,a=n;void 0===a&&(a=void 0!==this.account?this.account.privateKey():new i.ZD);try{_=await this.networkClient.getProgramImports(e);const n=await i.Ao.synthesizeKeyPair(a,e,t,r,_);return[n.provingKey(),n.verifyingKey()]}catch(e){C(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,t,r,n,_,a,o,s,c,d){r=P(r);let g,l,u=c;if(void 0===u&&void 0!==this.account&&(u=this.account.privateKey()),void 0===u)throw"No private key provided and no private key set in the ProgramManager";try{g=_?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),l=await this.keyProvider.transferKeys(r)}catch(e){C(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[f,w]=g,[b,p]=l;try{const e=[];m(r)?(o=await this.getCreditsRecord(n,[],o,a),e.push(o.nonce())):o=void 0,s=_?await this.getCreditsRecord(n,e,s,a):void 0}catch(e){C(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await i.Ao.buildTransferTransaction(u,e,t,r,o,n,s,this.host,b,p,f,w,d)}async buildTransferPublicTransaction(e,t,r,n,i){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,i)}async buildTransferPublicAsSignerTransaction(e,t,r,n,i){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,i)}async transfer(e,t,r,n,i,_,a,o,s,c){const d=await this.buildTransferTransaction(e,t,r,n,i,_,a,o,s,c);return await this.networkClient.submitTransaction(d)}async buildBondPublicTransaction(e,t,r,n,i={}){const _=Math.trunc(1e6*n),{programName:a="credits.aleo",functionName:o="bond_public",fee:s=i.fee||.86,privateFee:c=!1,inputs:d=[e,t,r,`${_.toString()}u64`],keySearchParams:g=new l({proverUri:S.bond_public.prover,verifierUri:S.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:u=this.creditsProgram(),...f}=i,w={programName:a,functionName:o,fee:s,privateFee:c,inputs:d,keySearchParams:g,...f};return await this.buildExecutionTransaction(w)}async bondPublic(e,t,r,n,i={}){const _=await this.buildBondPublicTransaction(e,t,r,n,i);return await this.networkClient.submitTransaction(_)}async buildBondValidatorTransaction(e,t,r,n,i={}){const _=Math.trunc(1e6*r),a=Math.trunc(n),{programName:o="credits.aleo",functionName:s="bond_validator",fee:c=i.fee||.86,privateFee:d=!1,inputs:g=[e,t,`${_.toString()}u64`,`${a.toString()}u8`],keySearchParams:u=new l({proverUri:S.bond_validator.prover,verifierUri:S.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:f=this.creditsProgram(),...w}=i,b={programName:o,functionName:s,fee:c,privateFee:d,inputs:g,keySearchParams:u,...w};return await this.buildExecutionTransaction(b)}async bondValidator(e,t,r,n,i={}){const _=await this.buildBondValidatorTransaction(e,t,r,n,i);return await this.networkClient.submitTransaction(_)}async buildUnbondPublicTransaction(e,t,r={}){const n=Math.trunc(1e6*t),{programName:i="credits.aleo",functionName:_="unbond_public",fee:a=r.fee||1.3,privateFee:o=!1,inputs:s=[e,`${n.toString()}u64`],keySearchParams:c=new l({proverUri:S.unbond_public.prover,verifierUri:S.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:d=this.creditsProgram(),...g}=r,u={programName:i,functionName:_,fee:a,privateFee:o,inputs:s,keySearchParams:c,...g};return this.buildExecutionTransaction(u)}async unbondPublic(e,t,r={}){const n=await this.buildUnbondPublicTransaction(e,t,r);return await this.networkClient.submitTransaction(n)}async buildClaimUnbondPublicTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="claim_unbond_public",fee:i=t.fee||2,privateFee:_=!1,inputs:a=[e],keySearchParams:o=new l({proverUri:S.claim_unbond_public.prover,verifierUri:S.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:s=this.creditsProgram(),...c}=t,d={programName:r,functionName:n,fee:i,privateFee:_,inputs:a,keySearchParams:o,...c};return await this.buildExecutionTransaction(d)}async claimUnbondPublic(e,t={}){const r=await this.buildClaimUnbondPublicTransaction(e,t);return await this.networkClient.submitTransaction(r)}async buildSetValidatorStateTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="set_validator_state",fee:i=1,privateFee:_=!1,inputs:a=[e.toString()],keySearchParams:o=new l({proverUri:S.set_validator_state.prover,verifierUri:S.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...s}=t,c={programName:r,functionName:n,fee:i,privateFee:_,inputs:a,keySearchParams:o,...s};return await this.execute(c)}async setValidatorState(e,t={}){const r=await this.buildSetValidatorStateTransaction(e,t);return this.networkClient.submitTransaction(r)}verifyExecution(e){try{const t=e.getExecution(),r=e.getFunctionId(),n=e.getProgram(),_=e.getVerifyingKey();return(0,i.Yc)(t,_,n,r)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return i.BP.fromString(e)}creditsProgram(){return i.BP.getCreditsProgram()}verifyProgram(e){try{return i.BP.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,t,r,n){try{return r instanceof i.ZF?r:i.ZF.fromString(r)}catch(r){try{const r=this.recordProvider;return await r.findCreditsRecord(e,!0,t,n)}catch(e){C(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function m(e){return T.has(e)}function P(e){return E.has(e)?e:C(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const k=i.OS.baseUrl();function K(e){const t=i.pF[e.verifyingKey];if(!t)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:t}}const S={bond_public:K(i.OS.bond_public()),bond_validator:K(i.OS.bond_validator()),claim_unbond_public:K(i.OS.claim_unbond_public()),fee_private:K(i.OS.fee_private()),fee_public:K(i.OS.fee_public()),inclusion:K(i.OS.inclusion()),join:K(i.OS.join()),set_validator_state:K(i.OS.set_validator_state()),split:K(i.OS.split()),transfer_private:K(i.OS.transfer_private()),transfer_private_to_public:K(i.OS.transfer_private_to_public()),transfer_public:K(i.OS.transfer_public()),transfer_public_as_signer:K(i.OS.transfer_public_as_signer()),transfer_public_to_private:K(i.OS.transfer_public_to_private()),unbond_public:K(i.OS.unbond_public()),getKey:function(e){if(this.hasOwnProperty(e))return this[e];throw new Error(`Key "${e}" not found.`)}},T=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),E=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),F=new Set(["private","transfer_private","transferPrivate"]),R=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),V=new Set(["public","transfer_public","transferPublic"]),x=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),A=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function C(e){throw console.error(e),new Error(e)}async function B(){console.warn("initializeWasm is deprecated, you no longer need to use it")}n()}catch(O){n(O)}}))},9879:(e,t,r)=>{r.a(e,(async(e,n)=>{try{function _(e,t,r,n){return new Promise((i=>{const _=new Worker(e,{type:"module"});_.addEventListener("message",(e=>{setTimeout((()=>{i(_),_.unref&&_.unref()}),0)}),{capture:!0,once:!0}),_.postMessage({module:t,memory:r,address:n})}))}let a;r.d(t,{$7:()=>Ne,Ao:()=>$e,BP:()=>Ie,D0:()=>xe,Fs:()=>Ze,KC:()=>je,LW:()=>Ue,OS:()=>Ae,Yc:()=>He,ZD:()=>Oe,ZF:()=>ze,ZX:()=>De,Zc:()=>Re,c7:()=>Ce,hv:()=>Le,pF:()=>We,pV:()=>Fe,qp:()=>Ve,to:()=>Me});const o=new Array(128).fill(void 0);function s(e){return o[e]}o.push(void 0,null,!0,!1);let c=o.length;function d(e){e<132||(o[e]=c,c=e)}function g(e){const t=s(e);return d(e),t}const l="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&l.decode();let u=null;function f(){return null!==u&&u.buffer===a.memory.buffer||(u=new Uint8Array(a.memory.buffer)),u}function w(e,t){return e>>>=0,l.decode(f().slice(e,e+t))}function b(e){c===o.length&&o.push(o.length+1);const t=c;return c=o[t],o[t]=e,t}let p=0;const y="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},h=function(e,t){const r=y.encode(e);return t.set(r),{read:e.length,written:r.length}};function v(e,t,r){if(void 0===r){const r=y.encode(e),n=t(r.length,1)>>>0;return f().subarray(n,n+r.length).set(r),p=r.length,n}let n=e.length,i=t(n,1)>>>0;const _=f();let a=0;for(;a127)break;_[i+a]=t}if(a!==n){0!==a&&(e=e.slice(a)),i=r(i,n,n=a+3*e.length,1)>>>0;const t=f().subarray(i+a,i+n);a+=h(e,t).written,i=r(i,n,a,1)>>>0}return p=a,i}function m(e){return null==e}let P=null;function k(){return null!==P&&P.buffer===a.memory.buffer||(P=new Int32Array(a.memory.buffer)),P}function K(e){const t=typeof e;if("number"==t||"boolean"==t||null==e)return`${e}`;if("string"==t)return`"${e}"`;if("symbol"==t){const t=e.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=e.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(e)){const t=e.length;let r="[";t>0&&(r+=K(e[0]));for(let n=1;n1))return toString.call(e);if(n=r[1],"Object"==n)try{return"Object("+JSON.stringify(e)+")"}catch(e){return"Object"}return e instanceof Error?`${e.name}: ${e.message}\n${e.stack}`:n}const S="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>{a.__wbindgen_export_3.get(e.dtor)(e.a,e.b)}));function T(e,t,r,n){const i={a:e,b:t,cnt:1,dtor:r},_=(...e)=>{i.cnt++;const t=i.a;i.a=0;try{return n(t,i.b,...e)}finally{0==--i.cnt?(a.__wbindgen_export_3.get(i.dtor)(t,i.b),S.unregister(i)):i.a=t}};return _.original=i,S.register(_,i,i),_}function E(e,t,r){a._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha51b8a0cd6570266(e,t,b(r))}function F(e,t){if(!(e instanceof t))throw new Error(`expected instance of ${t.name}`);return e.ptr}function R(e,t){const r=t(1*e.length,1)>>>0;return f().set(e,r/1),p=e.length,r}function V(e,t,r,n){try{const o=a.__wbindgen_add_to_stack_pointer(-16);F(e,$),F(t,pe),F(r,ne);const s=v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.verifyFunctionExecution(o,e.__wbg_ptr,t.__wbg_ptr,r.__wbg_ptr,s,c);var i=k()[o/4+0],_=k()[o/4+1];if(k()[o/4+2])throw g(_);return 0!==i}finally{a.__wbindgen_add_to_stack_pointer(16)}}let x=null;function A(){return null!==x&&x.buffer===a.memory.buffer||(x=new BigInt64Array(a.memory.buffer)),x}function C(e,t){return e>>>=0,f().subarray(e/1,e/1+t)}function B(e){a.runRayonThread(e)}function O(e,t){return g(a.initThreadPool(b(e),t))}function U(e,t){try{return e.apply(this,t)}catch(e){a.__wbindgen_exn_store(b(e))}}function I(e,t,r,n){a.wasm_bindgen__convert__closures__invoke2_mut__h823ad1ce2c4b384e(e,t,b(r),b(n))}const N="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_address_free(e>>>0)));let j=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,N.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,N.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_address_free(e)}static from_private_key(t){F(t,Q);const r=a.address_from_private_key(t.__wbg_ptr);return e.__wrap(r)}static from_view_key(t){F(t,he);const r=a.address_from_view_key(t.__wbg_ptr);return e.__wrap(r)}static from_string(t){const r=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.address_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.address_to_string(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}verify(e,t){const r=R(e,a.__wbindgen_malloc),n=p;F(t,ue);return 0!==a.address_verify(this.__wbg_ptr,r,n,t.__wbg_ptr)}};const z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_execution_free(e>>>0)));let $=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,z.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,z.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_execution_free(e)}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.execution_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.execution_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const M="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_executionresponse_free(e>>>0)));let D=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,M.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,M.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_executionresponse_free(e)}getOutputs(){return g(a.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const e=a.executionresponse_getExecution(this.__wbg_ptr);return 0===e?void 0:$.__wrap(e)}getKeys(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.executionresponse_getKeys(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return Z.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const e=a.executionresponse_getProvingKey(this.__wbg_ptr);return 0===e?void 0:oe.__wrap(e)}getVerifyingKey(){const e=a.executionresponse_getVerifyingKey(this.__wbg_ptr);return pe.__wrap(e)}getFunctionId(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.executionresponse_getFunctionId(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}getProgram(){const e=a.executionresponse_getProgram(this.__wbg_ptr);return ne.__wrap(e)}};const L="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_field_free(e>>>0)));let W=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,L.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,L.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_field_free(e)}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.field_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.field_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_keypair_free(e>>>0)));class Z{static __wrap(e){e>>>=0;const t=Object.create(Z.prototype);return t.__wbg_ptr=e,H.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_keypair_free(e)}constructor(e,t){F(e,oe);var r=e.__destroy_into_raw();F(t,pe);var n=t.__destroy_into_raw();const i=a.keypair_new(r,n);return this.__wbg_ptr=i>>>0,this}provingKey(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.keypair_provingKey(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return oe.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.keypair_verifyingKey(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return pe.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}}const q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_metadata_free(e>>>0)));let J=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,q.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,q.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_metadata_free(e)}get name(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_name(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set name(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_name(this.__wbg_ptr,t,r)}get locator(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_locator(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set locator(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_locator(this.__wbg_ptr,t,r)}get prover(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_prover(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set prover(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_prover(this.__wbg_ptr,t,r)}get verifier(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_verifier(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set verifier(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_verifier(this.__wbg_ptr,t,r)}get verifyingKey(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_verifyingKey(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set verifyingKey(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,t,r)}static baseUrl(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.metadata_baseUrl(i);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static bond_public(){const t=a.metadata_bond_public();return e.__wrap(t)}static bond_validator(){const t=a.metadata_bond_validator();return e.__wrap(t)}static claim_unbond_public(){const t=a.metadata_claim_unbond_public();return e.__wrap(t)}static fee_private(){const t=a.metadata_fee_private();return e.__wrap(t)}static fee_public(){const t=a.metadata_fee_public();return e.__wrap(t)}static inclusion(){const t=a.metadata_inclusion();return e.__wrap(t)}static join(){const t=a.metadata_join();return e.__wrap(t)}static set_validator_state(){const t=a.metadata_set_validator_state();return e.__wrap(t)}static split(){const t=a.metadata_split();return e.__wrap(t)}static transfer_private(){const t=a.metadata_transfer_private();return e.__wrap(t)}static transfer_private_to_public(){const t=a.metadata_transfer_private_to_public();return e.__wrap(t)}static transfer_public(){const t=a.metadata_transfer_public();return e.__wrap(t)}static transfer_public_as_signer(){const t=a.metadata_transfer_public_as_signer();return e.__wrap(t)}static transfer_public_to_private(){const t=a.metadata_transfer_public_to_private();return e.__wrap(t)}static unbond_public(){const t=a.metadata_unbond_public();return e.__wrap(t)}};const Y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_offlinequery_free(e>>>0)));let X=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,Y.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,Y.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_offlinequery_free(e)}constructor(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.offlinequery_new(n,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return this.__wbg_ptr=t>>>0,this}finally{a.__wbindgen_add_to_stack_pointer(16)}}addStatePath(e,t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p,o=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.offlinequery_addStatePath(n,this.__wbg_ptr,i,_,o,s);var r=k()[n/4+0];if(k()[n/4+1])throw g(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.offlinequery_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.offlinequery_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const G="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_privatekey_free(e>>>0)));let Q=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,G.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,G.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_privatekey_free(e)}constructor(){const e=a.privatekey_new();return this.__wbg_ptr=e>>>0,this}static from_seed_unchecked(t){const r=R(t,a.__wbindgen_malloc),n=p,i=a.privatekey_from_seed_unchecked(r,n);return e.__wrap(i)}static from_string(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.privatekey_from_string(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}to_string(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.privatekey_to_string(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}to_view_key(){const e=a.privatekey_to_view_key(this.__wbg_ptr);return he.__wrap(e)}to_address(){const e=a.privatekey_to_address(this.__wbg_ptr);return j.__wrap(e)}sign(e){const t=R(e,a.__wbindgen_malloc),r=p,n=a.privatekey_sign(this.__wbg_ptr,t,r);return ue.__wrap(n)}static newEncrypted(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekey_newEncrypted(n,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return te.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekey_toCiphertext(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return te.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,r){try{const _=a.__wbindgen_add_to_stack_pointer(-16);F(t,te);const o=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.privatekey_fromPrivateKeyCiphertext(_,t.__wbg_ptr,o,s);var n=k()[_/4+0],i=k()[_/4+1];if(k()[_/4+2])throw g(i);return e.__wrap(n)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const ee="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_privatekeyciphertext_free(e>>>0)));let te=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ee.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ee.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_privatekeyciphertext_free(e)}static encryptPrivateKey(t,r){try{const _=a.__wbindgen_add_to_stack_pointer(-16);F(t,Q);const o=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.privatekey_toCiphertext(_,t.__wbg_ptr,o,s);var n=k()[_/4+0],i=k()[_/4+1];if(k()[_/4+2])throw g(i);return e.__wrap(n)}finally{a.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekeyciphertext_decryptToPrivateKey(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return Q.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.privatekeyciphertext_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.privatekeyciphertext_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const re="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_program_free(e>>>0)));let ne=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,re.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,re.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_program_free(e)}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.program_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.program_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}hasFunction(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;return 0!==a.program_hasFunction(this.__wbg_ptr,t,r)}getFunctions(){return g(a.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getFunctionInputs(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return g(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.program_getMappings(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return g(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getRecordMembers(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return g(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getStructMembers(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return g(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=a.program_getCreditsProgram();return e.__wrap(t)}id(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.program_id(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}address(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.program_address(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return j.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){F(t,e);return 0!==a.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return g(a.program_getImports(this.__wbg_ptr))}};const ie="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_programmanager_free(e>>>0)));let _e=class{__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ie.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_programmanager_free(e)}static buildDeploymentTransaction(e,t,r,n,i,_,o,s,c){F(e,Q);const d=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),l=p;let u=0;m(n)||(F(n,ge),u=n.__destroy_into_raw());var f=m(i)?0:v(i,a.__wbindgen_malloc,a.__wbindgen_realloc),w=p;let y=0;m(o)||(F(o,oe),y=o.__destroy_into_raw());let h=0;m(s)||(F(s,pe),h=s.__destroy_into_raw());let P=0;m(c)||(F(c,X),P=c.__destroy_into_raw());return g(a.programmanager_buildDeploymentTransaction(e.__wbg_ptr,d,l,r,u,f,w,m(_)?0:b(_),y,h,P))}static estimateDeploymentFee(e,t){const r=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;return g(a.programmanager_estimateDeploymentFee(r,n,m(t)?0:b(t)))}static estimateProgramNameCost(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.programmanager_estimateProgramNameCost(n,i,_);var t=A()[n/8+0],r=k()[n/4+2];if(k()[n/4+3])throw g(r);return BigInt.asUintN(64,t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(e,t,r,n,i,_,o,s,c,d,l){F(e,Q);const u=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),f=p,w=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(s)||(F(s,oe),h=s.__destroy_into_raw());let P=0;m(c)||(F(c,pe),P=c.__destroy_into_raw());var k=m(d)?0:v(d,a.__wbindgen_malloc,a.__wbindgen_realloc),K=p;let S=0;m(l)||(F(l,X),S=l.__destroy_into_raw());return g(a.programmanager_executeFunctionOffline(e.__wbg_ptr,u,f,w,y,b(n),i,_,m(o)?0:b(o),h,P,k,K,S))}static buildExecutionTransaction(e,t,r,n,i,_,o,s,c,d,l,u,f){F(e,Q);const w=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p,h=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),P=p;let k=0;m(_)||(F(_,ge),k=_.__destroy_into_raw());var K=m(o)?0:v(o,a.__wbindgen_malloc,a.__wbindgen_realloc),S=p;let T=0;m(c)||(F(c,oe),T=c.__destroy_into_raw());let E=0;m(d)||(F(d,pe),E=d.__destroy_into_raw());let R=0;m(l)||(F(l,oe),R=l.__destroy_into_raw());let V=0;m(u)||(F(u,pe),V=u.__destroy_into_raw());let x=0;m(f)||(F(f,X),x=f.__destroy_into_raw());return g(a.programmanager_buildExecutionTransaction(e.__wbg_ptr,w,y,h,P,b(n),i,k,K,S,m(s)?0:b(s),T,E,R,V,x))}static estimateExecutionFee(e,t,r,n,i,_,o,s,c){F(e,Q);const d=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),l=p,u=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),f=p;var w=m(i)?0:v(i,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(o)||(F(o,oe),h=o.__destroy_into_raw());let P=0;m(s)||(F(s,pe),P=s.__destroy_into_raw());let k=0;m(c)||(F(c,X),k=c.__destroy_into_raw());return g(a.programmanager_estimateExecutionFee(e.__wbg_ptr,d,l,u,f,b(n),w,y,m(_)?0:b(_),h,P,k))}static estimateFinalizeFee(e,t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.programmanager_estimateFinalizeFee(i,_,o,s,c);var r=A()[i/8+0],n=k()[i/4+2];if(k()[i/4+3])throw g(n);return BigInt.asUintN(64,r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(e,t,r,n,i,_,o,s,c,d,l){F(e,Q),F(t,ge);var u=t.__destroy_into_raw();F(r,ge);var f=r.__destroy_into_raw();let w=0;m(i)||(F(i,ge),w=i.__destroy_into_raw());var b=m(_)?0:v(_,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(o)||(F(o,oe),h=o.__destroy_into_raw());let P=0;m(s)||(F(s,pe),P=s.__destroy_into_raw());let k=0;m(c)||(F(c,oe),k=c.__destroy_into_raw());let K=0;m(d)||(F(d,pe),K=d.__destroy_into_raw());let S=0;m(l)||(F(l,X),S=l.__destroy_into_raw());return g(a.programmanager_buildJoinTransaction(e.__wbg_ptr,u,f,n,w,b,y,h,P,k,K,S))}static buildSplitTransaction(e,t,r,n,i,_,o){F(e,Q),F(r,ge);var s=r.__destroy_into_raw(),c=m(n)?0:v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),d=p;let l=0;m(i)||(F(i,oe),l=i.__destroy_into_raw());let u=0;m(_)||(F(_,pe),u=_.__destroy_into_raw());let f=0;m(o)||(F(o,X),f=o.__destroy_into_raw());return g(a.programmanager_buildSplitTransaction(e.__wbg_ptr,t,s,c,d,l,u,f))}static buildTransferTransaction(e,t,r,n,i,_,o,s,c,d,l,u,f){F(e,Q);const w=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),b=p,y=v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),h=p;let P=0;m(i)||(F(i,ge),P=i.__destroy_into_raw());let k=0;m(o)||(F(o,ge),k=o.__destroy_into_raw());var K=m(s)?0:v(s,a.__wbindgen_malloc,a.__wbindgen_realloc),S=p;let T=0;m(c)||(F(c,oe),T=c.__destroy_into_raw());let E=0;m(d)||(F(d,pe),E=d.__destroy_into_raw());let R=0;m(l)||(F(l,oe),R=l.__destroy_into_raw());let V=0;m(u)||(F(u,pe),V=u.__destroy_into_raw());let x=0;m(f)||(F(f,X),x=f.__destroy_into_raw());return g(a.programmanager_buildTransferTransaction(e.__wbg_ptr,t,w,b,y,h,P,_,k,K,S,T,E,R,V,x))}static synthesizeKeyPair(e,t,r,n,i){F(e,Q);const _=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;return g(a.programmanager_synthesizeKeyPair(e.__wbg_ptr,_,o,s,c,b(n),m(i)?0:b(i)))}};const ae="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_provingkey_free(e>>>0)));let oe=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ae.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ae.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_provingkey_free(e)}isBondPublicProver(){return 0!==a.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==a.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==a.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==a.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==a.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==a.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==a.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==a.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==a.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==a.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==a.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==a.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==a.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==a.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==a.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_checksum(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}copy(){const t=a.provingkey_copy(this.__wbg_ptr);return e.__wrap(t)}static fromBytes(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=R(t,a.__wbindgen_malloc),o=p;a.provingkey_fromBytes(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.provingkey_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_toBytes(i,this.__wbg_ptr);var e=k()[i/4+0],t=k()[i/4+1],r=k()[i/4+2];if(k()[i/4+3])throw g(r);var n=C(e,t).slice();return a.__wbindgen_free(e,1*t,1),n}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}};const se="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_recordciphertext_free(e>>>0)));let ce=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,se.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,se.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_recordciphertext_free(e)}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.recordciphertext_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordciphertext_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}decrypt(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16);F(e,he),a.recordciphertext_decrypt(n,this.__wbg_ptr,e.__wbg_ptr);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return ge.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}isOwner(e){F(e,he);return 0!==a.recordciphertext_isOwner(this.__wbg_ptr,e.__wbg_ptr)}};const de="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_recordplaintext_free(e>>>0)));let ge=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,de.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,de.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_recordplaintext_free(e)}commitment(e,t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.recordplaintext_commitment(i,this.__wbg_ptr,_,o,s,c);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return W.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.recordplaintext_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordplaintext_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}microcredits(){const e=a.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,e)}nonce(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordplaintext_nonce(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}serialNumberString(e,t,r){let n,i;try{const u=a.__wbindgen_add_to_stack_pointer(-16);F(e,Q);const f=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),b=p,y=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),h=p;a.recordplaintext_serialNumberString(u,this.__wbg_ptr,e.__wbg_ptr,f,b,y,h);var _=k()[u/4+0],o=k()[u/4+1],s=k()[u/4+2],c=k()[u/4+3],d=_,l=o;if(c)throw d=0,l=0,g(s);return n=d,i=l,w(d,l)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(n,i,1)}}};const le="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_signature_free(e>>>0)));let ue=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,le.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,le.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_signature_free(e)}static sign(t,r){F(t,Q);const n=R(r,a.__wbindgen_malloc),i=p,_=a.privatekey_sign(t.__wbg_ptr,n,i);return e.__wrap(_)}verify(e,t){F(e,j);const r=R(t,a.__wbindgen_malloc),n=p;return 0!==a.signature_verify(this.__wbg_ptr,e.__wbg_ptr,r,n)}static from_string(t){const r=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.signature_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.signature_to_string(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}};const fe="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_transaction_free(e>>>0)));let we=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,fe.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,fe.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_transaction_free(e)}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.transaction_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}transactionId(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_transactionId(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}transactionType(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_transactionType(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}};const be="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_verifyingkey_free(e>>>0)));let pe=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,be.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,be.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_verifyingkey_free(e)}static bondPublicVerifier(){const t=a.verifyingkey_bondPublicVerifier();return e.__wrap(t)}static bondValidatorVerifier(){const t=a.verifyingkey_bondValidatorVerifier();return e.__wrap(t)}static claimUnbondPublicVerifier(){const t=a.verifyingkey_claimUnbondPublicVerifier();return e.__wrap(t)}static feePrivateVerifier(){const t=a.verifyingkey_feePrivateVerifier();return e.__wrap(t)}static feePublicVerifier(){const t=a.verifyingkey_feePublicVerifier();return e.__wrap(t)}static inclusionVerifier(){const t=a.verifyingkey_inclusionVerifier();return e.__wrap(t)}static joinVerifier(){const t=a.verifyingkey_joinVerifier();return e.__wrap(t)}static setValidatorStateVerifier(){const t=a.verifyingkey_setValidatorStateVerifier();return e.__wrap(t)}static splitVerifier(){const t=a.verifyingkey_splitVerifier();return e.__wrap(t)}static transferPrivateVerifier(){const t=a.verifyingkey_transferPrivateVerifier();return e.__wrap(t)}static transferPrivateToPublicVerifier(){const t=a.verifyingkey_transferPrivateToPublicVerifier();return e.__wrap(t)}static transferPublicVerifier(){const t=a.verifyingkey_transferPublicVerifier();return e.__wrap(t)}static transferPublicAsSignerVerifier(){const t=a.verifyingkey_transferPublicAsSignerVerifier();return e.__wrap(t)}static transferPublicToPrivateVerifier(){const t=a.verifyingkey_transferPublicToPrivateVerifier();return e.__wrap(t)}static unbondPublicVerifier(){const t=a.verifyingkey_unbondPublicVerifier();return e.__wrap(t)}isBondPublicVerifier(){return 0!==a.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==a.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==a.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==a.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==a.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==a.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==a.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==a.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==a.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==a.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==a.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==a.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==a.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==a.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==a.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_checksum(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}copy(){const t=a.verifyingkey_copy(this.__wbg_ptr);return e.__wrap(t)}static fromBytes(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=R(t,a.__wbindgen_malloc),o=p;a.verifyingkey_fromBytes(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.verifyingkey_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_toBytes(i,this.__wbg_ptr);var e=k()[i/4+0],t=k()[i/4+1],r=k()[i/4+2];if(k()[i/4+3])throw g(r);var n=C(e,t).slice();return a.__wbindgen_free(e,1*t,1),n}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}};const ye="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_viewkey_free(e>>>0)));let he=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ye.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ye.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_viewkey_free(e)}static from_private_key(t){F(t,Q);const r=a.privatekey_to_view_key(t.__wbg_ptr);return e.__wrap(r)}static from_string(t){const r=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.viewkey_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.viewkey_to_string(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}to_address(){const e=a.address_from_view_key(this.__wbg_ptr);return j.__wrap(e)}decrypt(e){let t,r;try{const d=a.__wbindgen_add_to_stack_pointer(-16),l=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),u=p;a.viewkey_decrypt(d,this.__wbg_ptr,l,u);var n=k()[d/4+0],i=k()[d/4+1],_=k()[d/4+2],o=k()[d/4+3],s=n,c=i;if(o)throw s=0,c=0,g(_);return t=s,r=c,w(s,c)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,r,1)}}};async function ve(e,t){if("function"==typeof Response&&e instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(e,t)}catch(t){if("application/wasm"==e.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const r=await e.arrayBuffer();return await WebAssembly.instantiate(r,t)}{const r=await WebAssembly.instantiate(e,t);return r instanceof WebAssembly.Instance?{instance:r,module:e}:r}}function me(){const e={wbg:{}};return e.wbg.__wbindgen_object_drop_ref=function(e){g(e)},e.wbg.__wbg_new_71801a555ad9f2aa=function(){return U((function(){return b(new XMLHttpRequest)}),arguments)},e.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return U((function(e,t,r){s(e).overrideMimeType(w(t,r))}),arguments)},e.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return U((function(e,t,r,n,i,_){s(e).open(w(t,r),w(n,i),0!==_)}),arguments)},e.wbg.__wbg_send_80d29985093c1ec5=function(){return U((function(e){s(e).send()}),arguments)},e.wbg.__wbg_response_7c2e2759084f7279=function(){return U((function(e){return b(s(e).response)}),arguments)},e.wbg.__wbg_status_d485fb5a478426fb=function(){return U((function(e){return s(e).status}),arguments)},e.wbg.__wbg_new_72fb9a18b5ae2624=function(){return b(new Object)},e.wbg.__wbindgen_string_new=function(e,t){return b(w(e,t))},e.wbg.__wbg_set_1f9b04f170055d33=function(){return U((function(e,t,r){return Reflect.set(s(e),s(t),s(r))}),arguments)},e.wbg.__wbg_new_ab6fd82b10560829=function(){return U((function(){return b(new Headers)}),arguments)},e.wbg.__wbindgen_object_clone_ref=function(e){return b(s(e))},e.wbg.__wbg_new_0d76b0581eca6298=function(){return U((function(){return b(new AbortController)}),arguments)},e.wbg.__wbg_signal_a61f78a3478fd9bc=function(e){return b(s(e).signal)},e.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return U((function(e,t,r,n,i){s(e).append(w(t,r),w(n,i))}),arguments)},e.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(e){let t;try{t=s(e)instanceof Response}catch(e){t=!1}return t},e.wbg.__wbg_status_61a01141acd3cf74=function(e){return s(e).status},e.wbg.__wbg_url_5f6dc4009ac5f99d=function(e,t){const r=v(s(t).url,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;k()[e/4+1]=n,k()[e/4+0]=r},e.wbg.__wbg_headers_9620bfada380764a=function(e){return b(s(e).headers)},e.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return b(Symbol.iterator)},e.wbg.__wbg_get_e3c254076557e348=function(){return U((function(e,t){return b(Reflect.get(s(e),s(t)))}),arguments)},e.wbg.__wbindgen_is_function=function(e){return"function"==typeof s(e)},e.wbg.__wbg_call_27c0f87801dedf93=function(){return U((function(e,t){return b(s(e).call(s(t)))}),arguments)},e.wbg.__wbindgen_is_object=function(e){const t=s(e);return"object"==typeof t&&null!==t},e.wbg.__wbg_next_40fc327bfc8770e6=function(e){return b(s(e).next)},e.wbg.__wbg_next_196c84450b364254=function(){return U((function(e){return b(s(e).next())}),arguments)},e.wbg.__wbg_done_298b57d23c0fc80c=function(e){return s(e).done},e.wbg.__wbg_value_d93c65011f51a456=function(e){return b(s(e).value)},e.wbg.__wbg_abort_2aa7521d5690750e=function(e){s(e).abort()},e.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return U((function(e){return b(JSON.stringify(s(e)))}),arguments)},e.wbg.__wbindgen_string_get=function(e,t){const r=s(t),n="string"==typeof r?r:void 0;var i=m(n)?0:v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;k()[e/4+1]=_,k()[e/4+0]=i},e.wbg.__wbg_log_0159ca40cddf5b15=function(e,t){console.log(w(e,t))},e.wbg.__wbindgen_bigint_from_u64=function(e){return b(BigInt.asUintN(64,e))},e.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return U((function(e,t,r){return b(s(e).call(s(t),s(r)))}),arguments)},e.wbg.__wbindgen_module=function(){return b(Se.__wbindgen_wasm_module)},e.wbg.__wbindgen_memory=function(){return b(a.memory)},e.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a=function(e,t,r,n){return b(_(s(e),s(t),s(r),n>>>0))},e.wbg.__wbg_executionresponse_new=function(e){return b(D.__wrap(e))},e.wbg.__wbg_keypair_new=function(e){return b(Z.__wrap(e))},e.wbg.__wbg_transaction_new=function(e){return b(we.__wrap(e))},e.wbg.__wbg_newwithlength_66ae46612e7f0234=function(e){return b(new Array(e>>>0))},e.wbg.__wbg_set_d4638f722068f043=function(e,t,r){s(e)[t>>>0]=g(r)},e.wbg.__wbindgen_cb_drop=function(e){const t=g(e).original;if(1==t.cnt--)return t.a=0,!0;return!1},e.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return b(new Array)},e.wbg.__wbg_push_a5b05aedc7234f9f=function(e,t){return s(e).push(s(t))},e.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return U((function(e){return b(s(e).arrayBuffer())}),arguments)},e.wbg.__wbg_new_63b92bc8671ed464=function(e){return b(new Uint8Array(s(e)))},e.wbg.__wbg_length_c20a40f15020d68a=function(e){return s(e).length},e.wbg.__wbg_new_81740750da40724f=function(e,t){try{var r={a:e,b:t};const n=new Promise(((e,t)=>{const n=r.a;r.a=0;try{return I(n,r.b,e,t)}finally{r.a=n}}));return b(n)}finally{r.a=r.b=0}},e.wbg.__wbindgen_number_new=function(e){return b(e)},e.wbg.__wbg_new_abda76e883ba8a5f=function(){return b(new Error)},e.wbg.__wbg_stack_658279fe44541cf6=function(e,t){const r=v(s(t).stack,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;k()[e/4+1]=n,k()[e/4+0]=r},e.wbg.__wbg_error_f851667af71bcfc6=function(e,t){let r,n;try{r=e,n=t,console.error(w(e,t))}finally{a.__wbindgen_free(r,n,1)}},e.wbg.__wbg_buffer_12d079cc21e14bdb=function(e){return b(s(e).buffer)},e.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(e,t,r){return b(new Uint8Array(s(e),t>>>0,r>>>0))},e.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return U((function(e,t){s(e).randomFillSync(g(t))}),arguments)},e.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(e,t,r){return b(s(e).subarray(t>>>0,r>>>0))},e.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return U((function(e,t){s(e).getRandomValues(s(t))}),arguments)},e.wbg.__wbg_set_a47bac70306a19a7=function(e,t,r){s(e).set(s(t),r>>>0)},e.wbg.__wbg_crypto_1d1f22824a6a080c=function(e){return b(s(e).crypto)},e.wbg.__wbg_process_4a72847cc503995b=function(e){return b(s(e).process)},e.wbg.__wbg_versions_f686565e586dd935=function(e){return b(s(e).versions)},e.wbg.__wbg_node_104a2ff8d6ea03a2=function(e){return b(s(e).node)},e.wbg.__wbindgen_is_string=function(e){return"string"==typeof s(e)},e.wbg.__wbg_require_cca90b1a94a0255b=function(){return U((function(){return b(module.require)}),arguments)},e.wbg.__wbg_msCrypto_eb05e62b530a1508=function(e){return b(s(e).msCrypto)},e.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(e){return b(new Uint8Array(e>>>0))},e.wbg.__wbg_length_cd7af8117672b8b8=function(e){return s(e).length},e.wbg.__wbg_get_bd8e338fbd5f5cc8=function(e,t){return b(s(e)[t>>>0])},e.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return U((function(){return b(self.self)}),arguments)},e.wbg.__wbg_window_c6fb939a7f436783=function(){return U((function(){return b(window.window)}),arguments)},e.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return U((function(){return b(globalThis.globalThis)}),arguments)},e.wbg.__wbg_global_207b558942527489=function(){return U((function(){return b(global.global)}),arguments)},e.wbg.__wbindgen_is_undefined=function(e){return void 0===s(e)},e.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(e,t){return b(new Function(w(e,t)))},e.wbg.__wbg_has_0af94d20077affa2=function(){return U((function(e,t){return Reflect.has(s(e),s(t))}),arguments)},e.wbg.__wbg_fetch_bc7c8e27076a5c84=function(e){return b(fetch(s(e)))},e.wbg.__wbg_fetch_921fad6ef9e883dd=function(e,t){return b(s(e).fetch(s(t)))},e.wbg.__wbindgen_debug_string=function(e,t){const r=v(K(s(t)),a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;k()[e/4+1]=n,k()[e/4+0]=r},e.wbg.__wbindgen_throw=function(e,t){throw new Error(w(e,t))},e.wbg.__wbindgen_rethrow=function(e){throw g(e)},e.wbg.__wbg_then_a73caa9a87991566=function(e,t,r){return b(s(e).then(s(t),s(r)))},e.wbg.__wbg_then_0c86a60e8fcfe9f6=function(e,t){return b(s(e).then(s(t)))},e.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(e){queueMicrotask(s(e))},e.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(e){return b(s(e).queueMicrotask)},e.wbg.__wbg_resolve_b0083a7967828ec8=function(e){return b(Promise.resolve(s(e)))},e.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return b(Atomics.waitAsync)},e.wbg.__wbg_new_8cccba86b0f574cb=function(e){return b(new Int32Array(s(e)))},e.wbg.__wbg_waitAsync_46d5c36955b71a79=function(e,t,r){return b(Atomics.waitAsync(s(e),t,r))},e.wbg.__wbg_async_19c0400d97cc72fe=function(e){return s(e).async},e.wbg.__wbg_value_571d60108110e917=function(e){return b(s(e).value)},e.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(e){const t=v("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;k()[e/4+1]=r,k()[e/4+0]=t},e.wbg.__wbg_new_d1187ae36d662ef9=function(){return U((function(e,t){return b(new Worker(w(e,t)))}),arguments)},e.wbg.__wbg_setonmessage_503809e5bb51bd33=function(e,t){s(e).onmessage=s(t)},e.wbg.__wbg_of_6a70eed8d41f469c=function(e,t,r){return b(Array.of(s(e),s(t),s(r)))},e.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return U((function(e,t){s(e).postMessage(s(t))}),arguments)},e.wbg.__wbg_data_3ce7c145ca4fbcdc=function(e){return b(s(e).data)},e.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return U((function(e,t,r){return b(new Request(w(e,t),s(r)))}),arguments)},e.wbg.__wbg_responseText_c67ed2d48db10769=function(){return U((function(e,t){const r=s(t).responseText;var n=m(r)?0:v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),i=p;k()[e/4+1]=i,k()[e/4+0]=n}),arguments)},e.wbg.__wbindgen_closure_wrapper5975=function(e,t,r){return b(T(e,t,622,E))},e.wbg.__wbindgen_closure_wrapper6001=function(e,t,r){return b(T(e,t,622,E))},e}function Pe(e,t){e.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function ke(e,t){return a=e.exports,Se.__wbindgen_wasm_module=t,x=null,P=null,u=null,a.__wbindgen_start(),a}function Ke(e,t){if(void 0!==a)return a;const r=me();Pe(r,t),e instanceof WebAssembly.Module||(e=new WebAssembly.Module(e));return ke(new WebAssembly.Instance(e,r),e)}async function Se(e,t){if(void 0!==a)return a;const r=me();("string"==typeof e||"function"==typeof Request&&e instanceof Request||"function"==typeof URL&&e instanceof URL)&&(e=fetch(e)),Pe(r,t);const{instance:n,module:i}=await ve(await e,r);return ke(n,i)}var i=Object.freeze({__proto__:null,Address:j,Execution:$,ExecutionResponse:D,Field:W,KeyPair:Z,Metadata:J,OfflineQuery:X,PrivateKey:Q,PrivateKeyCiphertext:te,Program:ne,ProgramManager:_e,ProvingKey:oe,RecordCiphertext:ce,RecordPlaintext:ge,Signature:ue,Transaction:we,VerifyingKey:pe,ViewKey:he,default:Se,initSync:Ke,initThreadPool:O,runRayonThread:B,verifyFunctionExecution:V});const Te="aleo_wasm.wasm";const{initThreadPool:Ee,Address:Fe,Execution:Re,ExecutionResponse:Ve,Field:xe,Metadata:Ae,OfflineQuery:Ce,Private:Be,PrivateKey:Oe,PrivateKeyCiphertext:Ue,Program:Ie,ProvingKey:Ne,RecordCiphertext:je,RecordPlaintext:ze,ProgramManager:$e,Signature:Me,Transaction:De,ViewKey:Le,VerifyingKey:We,verifyFunctionExecution:He}=await(async(e={})=>{let{importHook:t,serverPath:r,initializeHook:n}=e,_=Te;return null!=r&&(_=r+/[^\/\\]*$/.exec(_)[0]),null!=t&&(_=t(_)),null!=n?await n(Se,_):await Se(_),i})({importHook:()=>new URL(r(6545),r.b)});async function Ze(e){null==e&&(e=navigator.hardwareConcurrency),console.info(`Spawning ${e} threads`),await Ee(new URL(r(2851),r.b),e)}n()}catch(qe){n(qe)}}),1)},9720:(e,t,r)=>{r.d(t,{LV:()=>l});const n=Symbol("Comlink.proxy"),i=Symbol("Comlink.endpoint"),_=Symbol("Comlink.releaseProxy"),a=Symbol("Comlink.finalizer"),o=Symbol("Comlink.thrown"),s=e=>"object"==typeof e&&null!==e||"function"==typeof e,c=new Map([["proxy",{canHandle:e=>s(e)&&e[n],serialize(e){const{port1:t,port2:r}=new MessageChannel;return d(e,t),[r,[r]]},deserialize:e=>(e.start(),l(e))}],["throw",{canHandle:e=>s(e)&&o in e,serialize({value:e}){let t;return t=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[t,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function d(e,t=globalThis,r=["*"]){t.addEventListener("message",(function i(_){if(!_||!_.data)return;if(!function(e,t){for(const r of e){if(t===r||"*"===r)return!0;if(r instanceof RegExp&&r.test(t))return!0}return!1}(r,_.origin))return void console.warn(`Invalid origin '${_.origin}' for comlink proxy`);const{id:s,type:c,path:l}=Object.assign({path:[]},_.data),u=(_.data.argumentList||[]).map(m);let f;try{const t=l.slice(0,-1).reduce(((e,t)=>e[t]),e),r=l.reduce(((e,t)=>e[t]),e);switch(c){case"GET":f=r;break;case"SET":t[l.slice(-1)[0]]=m(_.data.value),f=!0;break;case"APPLY":f=r.apply(t,u);break;case"CONSTRUCT":f=function(e){return Object.assign(e,{[n]:!0})}(new r(...u));break;case"ENDPOINT":{const{port1:t,port2:r}=new MessageChannel;d(e,r),f=function(e,t){return h.set(e,t),e}(t,[t])}break;case"RELEASE":f=void 0;break;default:return}}catch(e){f={value:e,[o]:0}}Promise.resolve(f).catch((e=>({value:e,[o]:0}))).then((r=>{const[n,_]=v(r);t.postMessage(Object.assign(Object.assign({},n),{id:s}),_),"RELEASE"===c&&(t.removeEventListener("message",i),g(t),a in e&&"function"==typeof e[a]&&e[a]())})).catch((e=>{const[r,n]=v({value:new TypeError("Unserializable return value"),[o]:0});t.postMessage(Object.assign(Object.assign({},r),{id:s}),n)}))})),t.start&&t.start()}function g(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function l(e,t){return p(e,[],t)}function u(e){if(e)throw new Error("Proxy has been released and is not useable")}function f(e){return P(e,{type:"RELEASE"}).then((()=>{g(e)}))}const w=new WeakMap,b="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const t=(w.get(e)||0)-1;w.set(e,t),0===t&&f(e)}));function p(e,t=[],r=function(){}){let n=!1;const a=new Proxy(r,{get(r,i){if(u(n),i===_)return()=>{!function(e){b&&b.unregister(e)}(a),f(e),n=!0};if("then"===i){if(0===t.length)return{then:()=>a};const r=P(e,{type:"GET",path:t.map((e=>e.toString()))}).then(m);return r.then.bind(r)}return p(e,[...t,i])},set(r,i,_){u(n);const[a,o]=v(_);return P(e,{type:"SET",path:[...t,i].map((e=>e.toString())),value:a},o).then(m)},apply(r,_,a){u(n);const o=t[t.length-1];if(o===i)return P(e,{type:"ENDPOINT"}).then(m);if("bind"===o)return p(e,t.slice(0,-1));const[s,c]=y(a);return P(e,{type:"APPLY",path:t.map((e=>e.toString())),argumentList:s},c).then(m)},construct(r,i){u(n);const[_,a]=y(i);return P(e,{type:"CONSTRUCT",path:t.map((e=>e.toString())),argumentList:_},a).then(m)}});return function(e,t){const r=(w.get(t)||0)+1;w.set(t,r),b&&b.register(e,t,e)}(a,e),a}function y(e){const t=e.map(v);return[t.map((e=>e[0])),(r=t.map((e=>e[1])),Array.prototype.concat.apply([],r))];var r}const h=new WeakMap;function v(e){for(const[t,r]of c)if(r.canHandle(e)){const[n,i]=r.serialize(e);return[{type:"HANDLER",name:t,value:n},i]}return[{type:"RAW",value:e},h.get(e)||[]]}function m(e){switch(e.type){case"HANDLER":return c.get(e.name).deserialize(e.value);case"RAW":return e.value}}function P(e,t,r){return new Promise((n=>{const i=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-");e.addEventListener("message",(function t(r){r.data&&r.data.id&&r.data.id===i&&(e.removeEventListener("message",t),n(r.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:i},t),r)}))}}}]); +(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[523,857],{2851:(e,t,r)=>{e.exports=r.p+"68537c70e60b0878e521.js"},6545:(e,t,r)=>{e.exports=r.p+"49a4de3dabc57be5a0e7.wasm"},9523:(e,t,r)=>{r.a(e,(async(e,n)=>{try{r.r(t),r.d(t,{Account:()=>s,Address:()=>i.pV,AleoKeyProvider:()=>_.A,AleoKeyProviderParams:()=>_.a,AleoNetworkClient:()=>_.b,BlockHeightSearch:()=>l,CREDITS_PROGRAM_KEYS:()=>_.C,ExecutionResponse:()=>i.qp,Field:()=>i.D0,FunctionExecution:()=>i.Zc,KEY_STORE:()=>_.K,NetworkRecordProvider:()=>g,OfflineKeyProvider:()=>d,OfflineQuery:()=>i.c7,OfflineSearchParams:()=>c,PRIVATE_TO_PUBLIC_TRANSFER:()=>_.d,PRIVATE_TRANSFER:()=>_.c,PRIVATE_TRANSFER_TYPES:()=>_.e,PUBLIC_TO_PRIVATE_TRANSFER:()=>_.h,PUBLIC_TRANSFER:()=>_.f,PUBLIC_TRANSFER_AS_SIGNER:()=>_.g,PrivateKey:()=>i.ZD,PrivateKeyCiphertext:()=>i.LW,Program:()=>i.BP,ProgramManager:()=>_.P,ProgramManagerBase:()=>i.Ao,ProvingKey:()=>i.$7,RecordCiphertext:()=>i.KC,RecordPlaintext:()=>i.ZF,Signature:()=>i.to,Transaction:()=>i.ZX,VALID_TRANSFER_TYPES:()=>_.V,VerifyingKey:()=>i.pF,ViewKey:()=>i.hv,createAleoWorker:()=>f,initThreadPool:()=>i.Fs,initializeWasm:()=>w,logAndThrow:()=>_.l,verifyFunctionExecution:()=>i.Yc});r(5357);var i=r(9879),_=r(2857),a=r(9720),o=e([i,_]);[i,_]=o.then?(await o)():o;class s{_privateKey;_viewKey;_address;constructor(e={}){try{this._privateKey=this.privateKeyFromParams(e)}catch(e){throw console.error("Wrong parameter",e),new Error("Wrong Parameter")}this._viewKey=i.hv.from_private_key(this._privateKey),this._address=i.pV.from_private_key(this._privateKey)}static fromCiphertext(e,t){try{e="string"==typeof e?i.LW.fromString(e):e;const r=i.ZD.fromPrivateKeyCiphertext(e,t);return new s({privateKey:r.to_string()})}catch(e){throw new Error("Wrong password or invalid ciphertext")}}privateKeyFromParams(e){return e.seed?i.ZD.from_seed_unchecked(e.seed):e.privateKey?i.ZD.from_string(e.privateKey):new i.ZD}privateKey(){return this._privateKey}viewKey(){return this._viewKey}address(){return this._address}toString(){return this.address().to_string()}encryptAccount(e){return this._privateKey.toCiphertext(e)}decryptRecord(e){return this._viewKey.decrypt(e)}decryptRecords(e){return e.map((e=>this._viewKey.decrypt(e)))}ownsRecordCiphertext(e){if("string"!=typeof e)return e.isOwner(this._viewKey);try{return i.KC.fromString(e).isOwner(this._viewKey)}catch(e){return!1}}sign(e){return this._privateKey.sign(e)}verify(e,t){return this._address.verify(e,t)}}class c{cacheKey;verifyCreditsKeys;constructor(e,t=!1){this.cacheKey=e,this.verifyCreditsKeys=t}static bondPublicKeyParams(){return new c(_.C.bond_public.locator,!0)}static bondValidatorKeyParams(){return new c(_.C.bond_validator.locator,!0)}static claimUnbondPublicKeyParams(){return new c(_.C.claim_unbond_public.locator,!0)}static feePrivateKeyParams(){return new c(_.C.fee_private.locator,!0)}static feePublicKeyParams(){return new c(_.C.fee_public.locator,!0)}static inclusionKeyParams(){return new c(_.C.inclusion.locator,!0)}static joinKeyParams(){return new c(_.C.join.locator,!0)}static setValidatorStateKeyParams(){return new c(_.C.set_validator_state.locator,!0)}static splitKeyParams(){return new c(_.C.split.locator,!0)}static transferPrivateKeyParams(){return new c(_.C.transfer_private.locator,!0)}static transferPrivateToPublicKeyParams(){return new c(_.C.transfer_private_to_public.locator,!0)}static transferPublicKeyParams(){return new c(_.C.transfer_public.locator,!0)}static transferPublicAsSignerKeyParams(){return new c(_.C.transfer_public_as_signer.locator,!0)}static transferPublicToPrivateKeyParams(){return new c(_.C.transfer_public_to_private.locator,!0)}static unbondPublicKeyParams(){return new c(_.C.unbond_public.locator,!0)}}class d{cache;constructor(){this.cache=new Map}bondPublicKeys(){return this.functionKeys(c.bondPublicKeyParams())}bondValidatorKeys(){return this.functionKeys(c.bondValidatorKeyParams())}cacheKeys(e,t){const[r,n]=t;this.cache.set(e,[r.toBytes(),n.toBytes()])}claimUnbondPublicKeys(){return this.functionKeys(c.claimUnbondPublicKeyParams())}functionKeys(e){return new Promise(((t,r)=>{if(void 0===e)r(new Error("No search parameters provided, cannot retrieve keys"));else{const n=e.cacheKey,_=e.verifyCreditsKeys;if(this.cache.has(n)){const[e,a]=this.cache.get(n),o=i.$7.fromBytes(e),s=i.pF.fromBytes(a);if(_){this.verifyCreditsKeys(n,o,s)||r(new Error(`Cached keys do not match expected keys for ${n}`))}t([o,s])}else r(new Error("Keys not found in cache for "+n))}}))}verifyCreditsKeys(e,t,r){switch(e){case _.C.bond_public.locator:return t.isBondPublicProver()&&r.isBondPublicVerifier();case _.C.claim_unbond_public.locator:return t.isClaimUnbondPublicProver()&&r.isClaimUnbondPublicVerifier();case _.C.fee_private.locator:return t.isFeePrivateProver()&&r.isFeePrivateVerifier();case _.C.fee_public.locator:return t.isFeePublicProver()&&r.isFeePublicVerifier();case _.C.inclusion.locator:return t.isInclusionProver()&&r.isInclusionVerifier();case _.C.join.locator:return t.isJoinProver()&&r.isJoinVerifier();case _.C.set_validator_state.locator:return t.isSetValidatorStateProver()&&r.isSetValidatorStateVerifier();case _.C.split.locator:return t.isSplitProver()&&r.isSplitVerifier();case _.C.transfer_private.locator:return t.isTransferPrivateProver()&&r.isTransferPrivateVerifier();case _.C.transfer_private_to_public.locator:return t.isTransferPrivateToPublicProver()&&r.isTransferPrivateToPublicVerifier();case _.C.transfer_public.locator:return t.isTransferPublicProver()&&r.isTransferPublicVerifier();case _.C.transfer_public_to_private.locator:return t.isTransferPublicToPrivateProver()&&r.isTransferPublicToPrivateVerifier();case _.C.unbond_public.locator:return t.isUnbondPublicProver()&&r.isUnbondPublicVerifier();default:return!1}}feePrivateKeys(){return this.functionKeys(c.feePrivateKeyParams())}feePublicKeys(){return this.functionKeys(c.feePublicKeyParams())}joinKeys(){return this.functionKeys(c.joinKeyParams())}splitKeys(){return this.functionKeys(c.splitKeyParams())}transferKeys(e){if(_.c.has(e))return this.functionKeys(c.transferPrivateKeyParams());if(_.d.has(e))return this.functionKeys(c.transferPrivateToPublicKeyParams());if(_.f.has(e))return this.functionKeys(c.transferPublicKeyParams());if(_.g.has(e))return this.functionKeys(c.transferPublicAsSignerKeyParams());if(_.h.has(e))return this.functionKeys(c.transferPublicToPrivateKeyParams());throw new Error("Invalid visibility type")}async unBondPublicKeys(){return this.functionKeys(c.unbondPublicKeyParams())}insertBondPublicKeys(e){if(!e.isBondPublicProver())throw new Error("Attempted to insert invalid proving keys for bond_public");this.cache.set(_.C.bond_public.locator,[e.toBytes(),i.pF.bondPublicVerifier().toBytes()])}insertClaimUnbondPublicKeys(e){if(!e.isClaimUnbondPublicProver())throw new Error("Attempted to insert invalid proving keys for claim_unbond_public");this.cache.set(_.C.claim_unbond_public.locator,[e.toBytes(),i.pF.claimUnbondPublicVerifier().toBytes()])}insertFeePrivateKeys(e){if(!e.isFeePrivateProver())throw new Error("Attempted to insert invalid proving keys for fee_private");this.cache.set(_.C.fee_private.locator,[e.toBytes(),i.pF.feePrivateVerifier().toBytes()])}insertFeePublicKeys(e){if(!e.isFeePublicProver())throw new Error("Attempted to insert invalid proving keys for fee_public");this.cache.set(_.C.fee_public.locator,[e.toBytes(),i.pF.feePublicVerifier().toBytes()])}insertJoinKeys(e){if(!e.isJoinProver())throw new Error("Attempted to insert invalid proving keys for join");this.cache.set(_.C.join.locator,[e.toBytes(),i.pF.joinVerifier().toBytes()])}insertSetValidatorStateKeys(e){if(!e.isSetValidatorStateProver())throw new Error("Attempted to insert invalid proving keys for set_validator_state");this.cache.set(_.C.set_validator_state.locator,[e.toBytes(),i.pF.setValidatorStateVerifier().toBytes()])}insertSplitKeys(e){if(!e.isSplitProver())throw new Error("Attempted to insert invalid proving keys for split");this.cache.set(_.C.split.locator,[e.toBytes(),i.pF.splitVerifier().toBytes()])}insertTransferPrivateKeys(e){if(!e.isTransferPrivateProver())throw new Error("Attempted to insert invalid proving keys for transfer_private");this.cache.set(_.C.transfer_private.locator,[e.toBytes(),i.pF.transferPrivateVerifier().toBytes()])}insertTransferPrivateToPublicKeys(e){if(!e.isTransferPrivateToPublicProver())throw new Error("Attempted to insert invalid proving keys for transfer_private_to_public");this.cache.set(_.C.transfer_private_to_public.locator,[e.toBytes(),i.pF.transferPrivateToPublicVerifier().toBytes()])}insertTransferPublicKeys(e){if(!e.isTransferPublicProver())throw new Error("Attempted to insert invalid proving keys for transfer_public");this.cache.set(_.C.transfer_public.locator,[e.toBytes(),i.pF.transferPublicVerifier().toBytes()])}insertTransferPublicToPrivateKeys(e){if(!e.isTransferPublicToPrivateProver())throw new Error("Attempted to insert invalid proving keys for transfer_public_to_private");this.cache.set(_.C.transfer_public_to_private.locator,[e.toBytes(),i.pF.transferPublicToPrivateVerifier().toBytes()])}insertUnbondPublicKeys(e){if(!e.isUnbondPublicProver())throw new Error("Attempted to insert invalid proving keys for unbond_public");this.cache.set(_.C.unbond_public.locator,[e.toBytes(),i.pF.unbondPublicVerifier().toBytes()])}}class g{account;networkClient;constructor(e,t){this.account=e,this.networkClient=t}setAccount(e){this.account=e}async findCreditsRecords(e,t,r,n){let i=0,a=0;if(n&&("startHeight"in n&&"number"==typeof n.endHeight&&(i=n.startHeight),"endHeight"in n&&"number"==typeof n.endHeight&&(a=n.endHeight)),0==a){a=await this.networkClient.getLatestHeight()}return i>=a&&(0,_.l)("Start height must be less than end height"),await this.networkClient.findUnspentRecords(i,a,this.account.privateKey(),e,void 0,r)}async findCreditsRecord(e,t,r,n){let i=null;try{i=await this.findCreditsRecords([e],t,r,n)}catch(e){}if(i&&i.length>0)return i[0];throw console.error("Record not found with error:",i),new Error("Record not found")}async findRecord(e,t,r){throw new Error("Method not implemented.")}async findRecords(e,t,r){throw new Error("Method not implemented.")}}class l{startHeight;endHeight;constructor(e,t){this.startHeight=e,this.endHeight=t}}let u=null;const f=()=>{if(!u){const e=new Worker(new URL(r.p+r.u(229),r.b),{type:void 0});u=(0,a.LV)(e)}return u};async function w(){console.warn("initializeWasm is deprecated, you no longer need to use it")}n()}catch(b){n(b)}}))},2857:(e,t,r)=>{r.a(e,(async(e,n)=>{try{r.d(t,{A:()=>P,C:()=>u,K:()=>g,P:()=>k,V:()=>w,a:()=>m,b:()=>d,c:()=>b,d:()=>p,e:()=>f,f:()=>y,g:()=>h,h:()=>v,l:()=>a});var i=r(9879),_=e([i]);function a(e){throw console.error(e),new Error(e)}function o(e){return JSON.parse(e,(function(e,t,r){return Number.isInteger(t)?BigInt(r.source):t}))}async function s(e,t){const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not get URL "+e);return r}async function c(e,t){t.method="POST";const r=await fetch(e,t);if(!r.ok)throw new Error(r.status+" could not post URL "+e);return r}i=(_.then?(await _)():_)[0];class d{host;headers;account;constructor(e,t){this.host=e+"/testnet",t&&t.headers?this.headers=t.headers:this.headers={"X-Aleo-SDK-Version":"0.7.4"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const t=await s(this.host+e,{headers:this.headers});return o(await t.text())}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,t,r,n,_,a){if(a=a||[],e<0)throw new Error("Start height must be greater than or equal to 0");const o=new Array;let s,c,d,g,l=0,u=BigInt(0);if(void 0===r){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");d=this.account._privateKey}else try{d=r instanceof i.ZD?r:i.ZD.from_string(r)}catch(e){throw new Error("Error parsing private key provided.")}const f=d.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");g=e}catch(e){throw new Error("Error fetching latest block height.")}if(c="number"==typeof t&&t<=g?t:g,e>c)throw new Error("Start height must be less than or equal to end height.");for(;c>e;){s=c-50,s=BigInt(_))))return o;if(void 0!==n&&n.length>0){let e=0;if(t.microcredits()>n[e]){if(e+=1,o.push(t),"number"==typeof _&&(u+=t.microcredits(),u>=BigInt(_)))return o;if(o.length>=n.length)return o}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+s.toString()+"-"+c.toString()),console.warn("Error: ",e),l+=1,l>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),o}}return o}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,t){try{return await this.fetchData("/blocks?start="+e+"&end="+t)}catch(r){throw new Error(`Error fetching blocks between ${e} and ${t}.`)}}async getDeploymentTransactionIDForProgram(e){e instanceof i.BP&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const t=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(t)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/block/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return Number(await this.fetchData("/block/height/latest"))}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return i.BP.fromString(e)}catch(t){try{return i.BP.fromString(await this.getProgram(e))}catch(t){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const t={},r=(e instanceof i.BP?e:await this.getProgramObject(e)).getImports();for(let e=0;e0&&!b)try{b=await this.networkClient.getProgramImports(t)}catch(e){a(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await i.Ao.buildExecutionTransaction(y,w,r,o,n,l,this.host,b,u,f,h,v,g)}async execute(e){const t=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(t)}async run(e,t,r,n,_,a,o,s,c,d){let g=c;if(void 0===c&&void 0!==this.account&&(g=this.account.privateKey()),void 0===g)throw"No private key provided and no private key set in the ProgramManager";if(!o||!s)try{[o,s]=await this.keyProvider.functionKeys(a)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",o),console.log("Verifying key: ",s),i.Ao.executeFunctionOffline(g,e,t,r,n,!1,_,o,s,this.host,d)}async join(e,t,r,n,_,o,s,c){let d,g,l=s;if(void 0===s&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";try{d=n?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),g=await this.keyProvider.joinKeys()}catch(e){a(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[u,f]=d,[w,b]=g;try{o=n?await this.getCreditsRecord(r,[],o,_):void 0}catch(e){a(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof i.ZF?e:i.ZF.fromString(e),t=t instanceof i.ZF?t:i.ZF.fromString(t)}catch(e){a("Records provided are not valid. Please ensure they are valid plaintext records.")}const p=await i.Ao.buildJoinTransaction(l,e,t,r,o,this.host,w,b,u,f,c);return await this.networkClient.submitTransaction(p)}async split(e,t,r,n){let _,o=r;if(void 0===o&&void 0!==this.account&&(o=this.account.privateKey()),void 0===o)throw"No private key provided and no private key set in the ProgramManager";try{_=await this.keyProvider.splitKeys()}catch(e){a(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[s,c]=_;try{t=t instanceof i.ZF?t:i.ZF.fromString(t)}catch(e){a("Record provided is not valid. Please ensure it is a valid plaintext record.")}const d=await i.Ao.buildSplitTransaction(o,e,t,this.host,s,c,n);return await this.networkClient.submitTransaction(d)}async synthesizeKeys(e,t,r,n){let _,o=n;void 0===o&&(o=void 0!==this.account?this.account.privateKey():new i.ZD);try{_=await this.networkClient.getProgramImports(e);const n=await i.Ao.synthesizeKeyPair(o,e,t,r,_);return[n.provingKey(),n.verifyingKey()]}catch(e){a(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,t,r,n,_,o,s,c,d,g){r=S(r);let l,u,f=d;if(void 0===f&&void 0!==this.account&&(f=this.account.privateKey()),void 0===f)throw"No private key provided and no private key set in the ProgramManager";try{l=_?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),u=await this.keyProvider.transferKeys(r)}catch(e){a(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`)}const[w,b]=l,[p,y]=u;try{const e=[];K(r)?(s=await this.getCreditsRecord(n,[],s,o),e.push(s.nonce())):s=void 0,c=_?await this.getCreditsRecord(n,e,c,o):void 0}catch(e){a(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await i.Ao.buildTransferTransaction(f,e,t,r,s,n,c,this.host,p,y,w,b,g)}async buildTransferPublicTransaction(e,t,r,n,i){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,i)}async buildTransferPublicAsSignerTransaction(e,t,r,n,i){return this.buildTransferTransaction(e,t,"public",r,!1,void 0,void 0,void 0,n,i)}async transfer(e,t,r,n,i,_,a,o,s,c){const d=await this.buildTransferTransaction(e,t,r,n,i,_,a,o,s,c);return await this.networkClient.submitTransaction(d)}async buildBondPublicTransaction(e,t,r,n,i={}){const _=Math.trunc(1e6*n),{programName:a="credits.aleo",functionName:o="bond_public",fee:s=i.fee||.86,privateFee:c=!1,inputs:d=[e,t,r,`${_.toString()}u64`],keySearchParams:g=new m({proverUri:u.bond_public.prover,verifierUri:u.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:l=this.creditsProgram(),...f}=i,w={programName:a,functionName:o,fee:s,privateFee:c,inputs:d,keySearchParams:g,...f};return await this.buildExecutionTransaction(w)}async bondPublic(e,t,r,n,i={}){const _=await this.buildBondPublicTransaction(e,t,r,n,i);return await this.networkClient.submitTransaction(_)}async buildBondValidatorTransaction(e,t,r,n,i={}){const _=Math.trunc(1e6*r),a=Math.trunc(n),{programName:o="credits.aleo",functionName:s="bond_validator",fee:c=i.fee||.86,privateFee:d=!1,inputs:g=[e,t,`${_.toString()}u64`,`${a.toString()}u8`],keySearchParams:l=new m({proverUri:u.bond_validator.prover,verifierUri:u.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:f=this.creditsProgram(),...w}=i,b={programName:o,functionName:s,fee:c,privateFee:d,inputs:g,keySearchParams:l,...w};return await this.buildExecutionTransaction(b)}async bondValidator(e,t,r,n,i={}){const _=await this.buildBondValidatorTransaction(e,t,r,n,i);return await this.networkClient.submitTransaction(_)}async buildUnbondPublicTransaction(e,t,r={}){const n=Math.trunc(1e6*t),{programName:i="credits.aleo",functionName:_="unbond_public",fee:a=r.fee||1.3,privateFee:o=!1,inputs:s=[e,`${n.toString()}u64`],keySearchParams:c=new m({proverUri:u.unbond_public.prover,verifierUri:u.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:d=this.creditsProgram(),...g}=r,l={programName:i,functionName:_,fee:a,privateFee:o,inputs:s,keySearchParams:c,...g};return this.buildExecutionTransaction(l)}async unbondPublic(e,t,r={}){const n=await this.buildUnbondPublicTransaction(e,t,r);return await this.networkClient.submitTransaction(n)}async buildClaimUnbondPublicTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="claim_unbond_public",fee:i=t.fee||2,privateFee:_=!1,inputs:a=[e],keySearchParams:o=new m({proverUri:u.claim_unbond_public.prover,verifierUri:u.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:s=this.creditsProgram(),...c}=t,d={programName:r,functionName:n,fee:i,privateFee:_,inputs:a,keySearchParams:o,...c};return await this.buildExecutionTransaction(d)}async claimUnbondPublic(e,t={}){const r=await this.buildClaimUnbondPublicTransaction(e,t);return await this.networkClient.submitTransaction(r)}async buildSetValidatorStateTransaction(e,t={}){const{programName:r="credits.aleo",functionName:n="set_validator_state",fee:i=1,privateFee:_=!1,inputs:a=[e.toString()],keySearchParams:o=new m({proverUri:u.set_validator_state.prover,verifierUri:u.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...s}=t,c={programName:r,functionName:n,fee:i,privateFee:_,inputs:a,keySearchParams:o,...s};return await this.execute(c)}async setValidatorState(e,t={}){const r=await this.buildSetValidatorStateTransaction(e,t);return this.networkClient.submitTransaction(r)}verifyExecution(e){try{const t=e.getExecution(),r=e.getFunctionId(),n=e.getProgram(),_=e.getVerifyingKey();return(0,i.Yc)(t,_,n,r)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return i.BP.fromString(e)}creditsProgram(){return i.BP.getCreditsProgram()}verifyProgram(e){try{return i.BP.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,t,r,n){try{return r instanceof i.ZF?r:i.ZF.fromString(r)}catch(r){try{const r=this.recordProvider;return await r.findCreditsRecord(e,!0,t,n)}catch(e){a(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function K(e){return f.has(e)}function S(e){return w.has(e)?e:a(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}n()}catch(T){n(T)}}))},9879:(e,t,r)=>{r.a(e,(async(e,n)=>{try{function _(e,t,r,n){return new Promise((i=>{const _=new Worker(e,{type:"module"});_.addEventListener("message",(e=>{setTimeout((()=>{i(_),_.unref&&_.unref()}),0)}),{capture:!0,once:!0}),_.postMessage({module:t,memory:r,address:n})}))}let a;r.d(t,{$7:()=>Ne,Ao:()=>$e,BP:()=>Ie,D0:()=>Ve,Fs:()=>Ze,KC:()=>je,LW:()=>Ue,OS:()=>xe,Yc:()=>We,ZD:()=>Oe,ZF:()=>ze,ZX:()=>De,Zc:()=>Fe,c7:()=>Ae,hv:()=>Le,pF:()=>He,pV:()=>Ce,qp:()=>Re,to:()=>Me});const o=new Array(128).fill(void 0);function s(e){return o[e]}o.push(void 0,null,!0,!1);let c=o.length;function d(e){e<132||(o[e]=c,c=e)}function g(e){const t=s(e);return d(e),t}const l="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&l.decode();let u=null;function f(){return null!==u&&u.buffer===a.memory.buffer||(u=new Uint8Array(a.memory.buffer)),u}function w(e,t){return e>>>=0,l.decode(f().slice(e,e+t))}function b(e){c===o.length&&o.push(o.length+1);const t=c;return c=o[t],o[t]=e,t}let p=0;const y="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},h=function(e,t){const r=y.encode(e);return t.set(r),{read:e.length,written:r.length}};function v(e,t,r){if(void 0===r){const r=y.encode(e),n=t(r.length,1)>>>0;return f().subarray(n,n+r.length).set(r),p=r.length,n}let n=e.length,i=t(n,1)>>>0;const _=f();let a=0;for(;a127)break;_[i+a]=t}if(a!==n){0!==a&&(e=e.slice(a)),i=r(i,n,n=a+3*e.length,1)>>>0;const t=f().subarray(i+a,i+n);a+=h(e,t).written,i=r(i,n,a,1)>>>0}return p=a,i}function m(e){return null==e}let P=null;function k(){return null!==P&&P.buffer===a.memory.buffer||(P=new Int32Array(a.memory.buffer)),P}function K(e){const t=typeof e;if("number"==t||"boolean"==t||null==e)return`${e}`;if("string"==t)return`"${e}"`;if("symbol"==t){const t=e.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=e.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(e)){const t=e.length;let r="[";t>0&&(r+=K(e[0]));for(let n=1;n1))return toString.call(e);if(n=r[1],"Object"==n)try{return"Object("+JSON.stringify(e)+")"}catch(e){return"Object"}return e instanceof Error?`${e.name}: ${e.message}\n${e.stack}`:n}const S="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>{a.__wbindgen_export_3.get(e.dtor)(e.a,e.b)}));function T(e,t,r,n){const i={a:e,b:t,cnt:1,dtor:r},_=(...e)=>{i.cnt++;const t=i.a;i.a=0;try{return n(t,i.b,...e)}finally{0==--i.cnt?(a.__wbindgen_export_3.get(i.dtor)(t,i.b),S.unregister(i)):i.a=t}};return _.original=i,S.register(_,i,i),_}function E(e,t,r){a._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6a363ba3fe56b221(e,t,b(r))}function C(e,t){if(!(e instanceof t))throw new Error(`expected instance of ${t.name}`);return e.ptr}function F(e,t){const r=t(1*e.length,1)>>>0;return f().set(e,r/1),p=e.length,r}function R(e,t,r,n){try{const o=a.__wbindgen_add_to_stack_pointer(-16);C(e,$),C(t,pe),C(r,ne);const s=v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.verifyFunctionExecution(o,e.__wbg_ptr,t.__wbg_ptr,r.__wbg_ptr,s,c);var i=k()[o/4+0],_=k()[o/4+1];if(k()[o/4+2])throw g(_);return 0!==i}finally{a.__wbindgen_add_to_stack_pointer(16)}}let V=null;function x(){return null!==V&&V.buffer===a.memory.buffer||(V=new BigInt64Array(a.memory.buffer)),V}function A(e,t){return e>>>=0,f().subarray(e/1,e/1+t)}function B(e){a.runRayonThread(e)}function O(e,t){return g(a.initThreadPool(b(e),t))}function U(e,t){try{return e.apply(this,t)}catch(e){a.__wbindgen_exn_store(b(e))}}function I(e,t,r,n){a.wasm_bindgen__convert__closures__invoke2_mut__h3c510d875601a93b(e,t,b(r),b(n))}const N="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_address_free(e>>>0)));let j=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,N.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,N.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_address_free(e)}static from_private_key(t){C(t,Q);const r=a.address_from_private_key(t.__wbg_ptr);return e.__wrap(r)}static from_view_key(t){C(t,he);const r=a.address_from_view_key(t.__wbg_ptr);return e.__wrap(r)}static from_string(t){const r=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.address_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.address_to_string(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}verify(e,t){const r=F(e,a.__wbindgen_malloc),n=p;C(t,ue);return 0!==a.address_verify(this.__wbg_ptr,r,n,t.__wbg_ptr)}};const z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_execution_free(e>>>0)));let $=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,z.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,z.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_execution_free(e)}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.execution_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.execution_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const M="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_executionresponse_free(e>>>0)));let D=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,M.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,M.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_executionresponse_free(e)}getOutputs(){return g(a.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const e=a.executionresponse_getExecution(this.__wbg_ptr);return 0===e?void 0:$.__wrap(e)}getKeys(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.executionresponse_getKeys(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return Z.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const e=a.executionresponse_getProvingKey(this.__wbg_ptr);return 0===e?void 0:oe.__wrap(e)}getVerifyingKey(){const e=a.executionresponse_getVerifyingKey(this.__wbg_ptr);return pe.__wrap(e)}getFunctionId(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.executionresponse_getFunctionId(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}getProgram(){const e=a.executionresponse_getProgram(this.__wbg_ptr);return ne.__wrap(e)}};const L="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_field_free(e>>>0)));let H=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,L.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,L.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_field_free(e)}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.field_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.field_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const W="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_keypair_free(e>>>0)));class Z{static __wrap(e){e>>>=0;const t=Object.create(Z.prototype);return t.__wbg_ptr=e,W.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,W.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_keypair_free(e)}constructor(e,t){C(e,oe);var r=e.__destroy_into_raw();C(t,pe);var n=t.__destroy_into_raw();const i=a.keypair_new(r,n);return this.__wbg_ptr=i>>>0,this}provingKey(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.keypair_provingKey(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return oe.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.keypair_verifyingKey(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return pe.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}}const q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_metadata_free(e>>>0)));let J=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,q.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,q.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_metadata_free(e)}get name(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_name(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set name(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_name(this.__wbg_ptr,t,r)}get locator(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_locator(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set locator(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_locator(this.__wbg_ptr,t,r)}get prover(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_prover(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set prover(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_prover(this.__wbg_ptr,t,r)}get verifier(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_verifier(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set verifier(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_verifier(this.__wbg_ptr,t,r)}get verifyingKey(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_verifyingKey(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}set verifyingKey(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,t,r)}static baseUrl(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.metadata_baseUrl(i);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static bond_public(){const t=a.metadata_bond_public();return e.__wrap(t)}static bond_validator(){const t=a.metadata_bond_validator();return e.__wrap(t)}static claim_unbond_public(){const t=a.metadata_claim_unbond_public();return e.__wrap(t)}static fee_private(){const t=a.metadata_fee_private();return e.__wrap(t)}static fee_public(){const t=a.metadata_fee_public();return e.__wrap(t)}static inclusion(){const t=a.metadata_inclusion();return e.__wrap(t)}static join(){const t=a.metadata_join();return e.__wrap(t)}static set_validator_state(){const t=a.metadata_set_validator_state();return e.__wrap(t)}static split(){const t=a.metadata_split();return e.__wrap(t)}static transfer_private(){const t=a.metadata_transfer_private();return e.__wrap(t)}static transfer_private_to_public(){const t=a.metadata_transfer_private_to_public();return e.__wrap(t)}static transfer_public(){const t=a.metadata_transfer_public();return e.__wrap(t)}static transfer_public_as_signer(){const t=a.metadata_transfer_public_as_signer();return e.__wrap(t)}static transfer_public_to_private(){const t=a.metadata_transfer_public_to_private();return e.__wrap(t)}static unbond_public(){const t=a.metadata_unbond_public();return e.__wrap(t)}};const Y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_offlinequery_free(e>>>0)));let X=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,Y.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,Y.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_offlinequery_free(e)}constructor(e,t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.offlinequery_new(i,e,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return this.__wbg_ptr=r>>>0,this}finally{a.__wbindgen_add_to_stack_pointer(16)}}addBlockHeight(e){a.offlinequery_addBlockHeight(this.__wbg_ptr,e)}addStatePath(e,t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p,o=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.offlinequery_addStatePath(n,this.__wbg_ptr,i,_,o,s);var r=k()[n/4+0];if(k()[n/4+1])throw g(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.offlinequery_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.offlinequery_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const G="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_privatekey_free(e>>>0)));let Q=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,G.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,G.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_privatekey_free(e)}constructor(){const e=a.privatekey_new();return this.__wbg_ptr=e>>>0,this}static from_seed_unchecked(t){const r=F(t,a.__wbindgen_malloc),n=p,i=a.privatekey_from_seed_unchecked(r,n);return e.__wrap(i)}static from_string(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.privatekey_from_string(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}to_string(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.privatekey_to_string(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}to_view_key(){const e=a.privatekey_to_view_key(this.__wbg_ptr);return he.__wrap(e)}to_address(){const e=a.privatekey_to_address(this.__wbg_ptr);return j.__wrap(e)}sign(e){const t=F(e,a.__wbindgen_malloc),r=p,n=a.privatekey_sign(this.__wbg_ptr,t,r);return ue.__wrap(n)}static newEncrypted(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekey_newEncrypted(n,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return te.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekey_toCiphertext(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return te.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,r){try{const _=a.__wbindgen_add_to_stack_pointer(-16);C(t,te);const o=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.privatekey_fromPrivateKeyCiphertext(_,t.__wbg_ptr,o,s);var n=k()[_/4+0],i=k()[_/4+1];if(k()[_/4+2])throw g(i);return e.__wrap(n)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const ee="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_privatekeyciphertext_free(e>>>0)));let te=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ee.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ee.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_privatekeyciphertext_free(e)}static encryptPrivateKey(t,r){try{const _=a.__wbindgen_add_to_stack_pointer(-16);C(t,Q);const o=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.privatekey_toCiphertext(_,t.__wbg_ptr,o,s);var n=k()[_/4+0],i=k()[_/4+1];if(k()[_/4+2])throw g(i);return e.__wrap(n)}finally{a.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekeyciphertext_decryptToPrivateKey(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return Q.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.privatekeyciphertext_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.privatekeyciphertext_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const re="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_program_free(e>>>0)));let ne=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,re.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,re.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_program_free(e)}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.program_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.program_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}hasFunction(e){const t=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;return 0!==a.program_hasFunction(this.__wbg_ptr,t,r)}getFunctions(){return g(a.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getFunctionInputs(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return g(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.program_getMappings(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return g(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getRecordMembers(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return g(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getStructMembers(n,this.__wbg_ptr,i,_);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return g(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=a.program_getCreditsProgram();return e.__wrap(t)}id(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.program_id(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}address(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.program_address(r,this.__wbg_ptr);var e=k()[r/4+0],t=k()[r/4+1];if(k()[r/4+2])throw g(t);return j.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){C(t,e);return 0!==a.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return g(a.program_getImports(this.__wbg_ptr))}};const ie="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_programmanager_free(e>>>0)));let _e=class{__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ie.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_programmanager_free(e)}static buildDeploymentTransaction(e,t,r,n,i,_,o,s,c){C(e,Q);const d=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),l=p;let u=0;m(n)||(C(n,ge),u=n.__destroy_into_raw());var f=m(i)?0:v(i,a.__wbindgen_malloc,a.__wbindgen_realloc),w=p;let y=0;m(o)||(C(o,oe),y=o.__destroy_into_raw());let h=0;m(s)||(C(s,pe),h=s.__destroy_into_raw());let P=0;m(c)||(C(c,X),P=c.__destroy_into_raw());return g(a.programmanager_buildDeploymentTransaction(e.__wbg_ptr,d,l,r,u,f,w,m(_)?0:b(_),y,h,P))}static estimateDeploymentFee(e,t){const r=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;return g(a.programmanager_estimateDeploymentFee(r,n,m(t)?0:b(t)))}static estimateProgramNameCost(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.programmanager_estimateProgramNameCost(n,i,_);var t=x()[n/8+0],r=k()[n/4+2];if(k()[n/4+3])throw g(r);return BigInt.asUintN(64,t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(e,t,r,n,i,_,o,s,c,d,l){C(e,Q);const u=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),f=p,w=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(s)||(C(s,oe),h=s.__destroy_into_raw());let P=0;m(c)||(C(c,pe),P=c.__destroy_into_raw());var k=m(d)?0:v(d,a.__wbindgen_malloc,a.__wbindgen_realloc),K=p;let S=0;m(l)||(C(l,X),S=l.__destroy_into_raw());return g(a.programmanager_executeFunctionOffline(e.__wbg_ptr,u,f,w,y,b(n),i,_,m(o)?0:b(o),h,P,k,K,S))}static buildExecutionTransaction(e,t,r,n,i,_,o,s,c,d,l,u,f){C(e,Q);const w=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p,h=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),P=p;let k=0;m(_)||(C(_,ge),k=_.__destroy_into_raw());var K=m(o)?0:v(o,a.__wbindgen_malloc,a.__wbindgen_realloc),S=p;let T=0;m(c)||(C(c,oe),T=c.__destroy_into_raw());let E=0;m(d)||(C(d,pe),E=d.__destroy_into_raw());let F=0;m(l)||(C(l,oe),F=l.__destroy_into_raw());let R=0;m(u)||(C(u,pe),R=u.__destroy_into_raw());let V=0;m(f)||(C(f,X),V=f.__destroy_into_raw());return g(a.programmanager_buildExecutionTransaction(e.__wbg_ptr,w,y,h,P,b(n),i,k,K,S,m(s)?0:b(s),T,E,F,R,V))}static estimateExecutionFee(e,t,r,n,i,_,o,s,c){C(e,Q);const d=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),l=p,u=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),f=p;var w=m(i)?0:v(i,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(o)||(C(o,oe),h=o.__destroy_into_raw());let P=0;m(s)||(C(s,pe),P=s.__destroy_into_raw());let k=0;m(c)||(C(c,X),k=c.__destroy_into_raw());return g(a.programmanager_estimateExecutionFee(e.__wbg_ptr,d,l,u,f,b(n),w,y,m(_)?0:b(_),h,P,k))}static estimateFinalizeFee(e,t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.programmanager_estimateFinalizeFee(i,_,o,s,c);var r=x()[i/8+0],n=k()[i/4+2];if(k()[i/4+3])throw g(n);return BigInt.asUintN(64,r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(e,t,r,n,i,_,o,s,c,d,l){C(e,Q),C(t,ge);var u=t.__destroy_into_raw();C(r,ge);var f=r.__destroy_into_raw();let w=0;m(i)||(C(i,ge),w=i.__destroy_into_raw());var b=m(_)?0:v(_,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(o)||(C(o,oe),h=o.__destroy_into_raw());let P=0;m(s)||(C(s,pe),P=s.__destroy_into_raw());let k=0;m(c)||(C(c,oe),k=c.__destroy_into_raw());let K=0;m(d)||(C(d,pe),K=d.__destroy_into_raw());let S=0;m(l)||(C(l,X),S=l.__destroy_into_raw());return g(a.programmanager_buildJoinTransaction(e.__wbg_ptr,u,f,n,w,b,y,h,P,k,K,S))}static buildSplitTransaction(e,t,r,n,i,_,o){C(e,Q),C(r,ge);var s=r.__destroy_into_raw(),c=m(n)?0:v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),d=p;let l=0;m(i)||(C(i,oe),l=i.__destroy_into_raw());let u=0;m(_)||(C(_,pe),u=_.__destroy_into_raw());let f=0;m(o)||(C(o,X),f=o.__destroy_into_raw());return g(a.programmanager_buildSplitTransaction(e.__wbg_ptr,t,s,c,d,l,u,f))}static buildTransferTransaction(e,t,r,n,i,_,o,s,c,d,l,u,f){C(e,Q);const w=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),b=p,y=v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),h=p;let P=0;m(i)||(C(i,ge),P=i.__destroy_into_raw());let k=0;m(o)||(C(o,ge),k=o.__destroy_into_raw());var K=m(s)?0:v(s,a.__wbindgen_malloc,a.__wbindgen_realloc),S=p;let T=0;m(c)||(C(c,oe),T=c.__destroy_into_raw());let E=0;m(d)||(C(d,pe),E=d.__destroy_into_raw());let F=0;m(l)||(C(l,oe),F=l.__destroy_into_raw());let R=0;m(u)||(C(u,pe),R=u.__destroy_into_raw());let V=0;m(f)||(C(f,X),V=f.__destroy_into_raw());return g(a.programmanager_buildTransferTransaction(e.__wbg_ptr,t,w,b,y,h,P,_,k,K,S,T,E,F,R,V))}static synthesizeKeyPair(e,t,r,n,i){C(e,Q);const _=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;return g(a.programmanager_synthesizeKeyPair(e.__wbg_ptr,_,o,s,c,b(n),m(i)?0:b(i)))}};const ae="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_provingkey_free(e>>>0)));let oe=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ae.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ae.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_provingkey_free(e)}isBondPublicProver(){return 0!==a.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==a.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==a.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==a.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==a.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==a.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==a.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==a.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==a.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==a.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==a.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==a.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==a.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==a.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==a.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_checksum(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}copy(){const t=a.provingkey_copy(this.__wbg_ptr);return e.__wrap(t)}static fromBytes(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=F(t,a.__wbindgen_malloc),o=p;a.provingkey_fromBytes(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.provingkey_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_toBytes(i,this.__wbg_ptr);var e=k()[i/4+0],t=k()[i/4+1],r=k()[i/4+2];if(k()[i/4+3])throw g(r);var n=A(e,t).slice();return a.__wbindgen_free(e,1*t,1),n}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}};const se="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_recordciphertext_free(e>>>0)));let ce=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,se.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,se.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_recordciphertext_free(e)}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.recordciphertext_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordciphertext_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}decrypt(e){try{const n=a.__wbindgen_add_to_stack_pointer(-16);C(e,he),a.recordciphertext_decrypt(n,this.__wbg_ptr,e.__wbg_ptr);var t=k()[n/4+0],r=k()[n/4+1];if(k()[n/4+2])throw g(r);return ge.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}isOwner(e){C(e,he);return 0!==a.recordciphertext_isOwner(this.__wbg_ptr,e.__wbg_ptr)}};const de="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_recordplaintext_free(e>>>0)));let ge=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,de.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,de.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_recordplaintext_free(e)}commitment(e,t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.recordplaintext_commitment(i,this.__wbg_ptr,_,o,s,c);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return H.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.recordplaintext_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordplaintext_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}microcredits(){const e=a.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,e)}nonce(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordplaintext_nonce(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}serialNumberString(e,t,r){let n,i;try{const u=a.__wbindgen_add_to_stack_pointer(-16);C(e,Q);const f=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),b=p,y=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),h=p;a.recordplaintext_serialNumberString(u,this.__wbg_ptr,e.__wbg_ptr,f,b,y,h);var _=k()[u/4+0],o=k()[u/4+1],s=k()[u/4+2],c=k()[u/4+3],d=_,l=o;if(c)throw d=0,l=0,g(s);return n=d,i=l,w(d,l)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(n,i,1)}}};const le="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_signature_free(e>>>0)));let ue=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,le.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,le.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_signature_free(e)}static sign(t,r){C(t,Q);const n=F(r,a.__wbindgen_malloc),i=p,_=a.privatekey_sign(t.__wbg_ptr,n,i);return e.__wrap(_)}verify(e,t){C(e,j);const r=F(t,a.__wbindgen_malloc),n=p;return 0!==a.signature_verify(this.__wbg_ptr,e.__wbg_ptr,r,n)}static from_string(t){const r=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.signature_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.signature_to_string(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}};const fe="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_transaction_free(e>>>0)));let we=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,fe.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,fe.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_transaction_free(e)}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.transaction_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}transactionId(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_transactionId(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}transactionType(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_transactionType(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}};const be="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_verifyingkey_free(e>>>0)));let pe=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,be.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,be.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_verifyingkey_free(e)}static bondPublicVerifier(){const t=a.verifyingkey_bondPublicVerifier();return e.__wrap(t)}static bondValidatorVerifier(){const t=a.verifyingkey_bondValidatorVerifier();return e.__wrap(t)}static claimUnbondPublicVerifier(){const t=a.verifyingkey_claimUnbondPublicVerifier();return e.__wrap(t)}static feePrivateVerifier(){const t=a.verifyingkey_feePrivateVerifier();return e.__wrap(t)}static feePublicVerifier(){const t=a.verifyingkey_feePublicVerifier();return e.__wrap(t)}static inclusionVerifier(){const t=a.verifyingkey_inclusionVerifier();return e.__wrap(t)}static joinVerifier(){const t=a.verifyingkey_joinVerifier();return e.__wrap(t)}static setValidatorStateVerifier(){const t=a.verifyingkey_setValidatorStateVerifier();return e.__wrap(t)}static splitVerifier(){const t=a.verifyingkey_splitVerifier();return e.__wrap(t)}static transferPrivateVerifier(){const t=a.verifyingkey_transferPrivateVerifier();return e.__wrap(t)}static transferPrivateToPublicVerifier(){const t=a.verifyingkey_transferPrivateToPublicVerifier();return e.__wrap(t)}static transferPublicVerifier(){const t=a.verifyingkey_transferPublicVerifier();return e.__wrap(t)}static transferPublicAsSignerVerifier(){const t=a.verifyingkey_transferPublicAsSignerVerifier();return e.__wrap(t)}static transferPublicToPrivateVerifier(){const t=a.verifyingkey_transferPublicToPrivateVerifier();return e.__wrap(t)}static unbondPublicVerifier(){const t=a.verifyingkey_unbondPublicVerifier();return e.__wrap(t)}isBondPublicVerifier(){return 0!==a.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==a.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==a.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==a.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==a.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==a.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==a.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==a.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==a.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==a.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==a.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==a.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==a.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==a.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==a.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_checksum(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}copy(){const t=a.verifyingkey_copy(this.__wbg_ptr);return e.__wrap(t)}static fromBytes(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=F(t,a.__wbindgen_malloc),o=p;a.verifyingkey_fromBytes(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.verifyingkey_fromString(i,_,o);var r=k()[i/4+0],n=k()[i/4+1];if(k()[i/4+2])throw g(n);return e.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_toBytes(i,this.__wbg_ptr);var e=k()[i/4+0],t=k()[i/4+1],r=k()[i/4+2];if(k()[i/4+3])throw g(r);var n=A(e,t).slice();return a.__wbindgen_free(e,1*t,1),n}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_toString(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}};const ye="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((e=>a.__wbg_viewkey_free(e>>>0)));let he=class e{static __wrap(t){t>>>=0;const r=Object.create(e.prototype);return r.__wbg_ptr=t,ye.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const e=this.__wbg_ptr;return this.__wbg_ptr=0,ye.unregister(this),e}free(){const e=this.__destroy_into_raw();a.__wbg_viewkey_free(e)}static from_private_key(t){C(t,Q);const r=a.privatekey_to_view_key(t.__wbg_ptr);return e.__wrap(r)}static from_string(t){const r=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.viewkey_from_string(r,n);return e.__wrap(i)}to_string(){let e,t;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.viewkey_to_string(i,this.__wbg_ptr);var r=k()[i/4+0],n=k()[i/4+1];return e=r,t=n,w(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,t,1)}}to_address(){const e=a.address_from_view_key(this.__wbg_ptr);return j.__wrap(e)}decrypt(e){let t,r;try{const d=a.__wbindgen_add_to_stack_pointer(-16),l=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),u=p;a.viewkey_decrypt(d,this.__wbg_ptr,l,u);var n=k()[d/4+0],i=k()[d/4+1],_=k()[d/4+2],o=k()[d/4+3],s=n,c=i;if(o)throw s=0,c=0,g(_);return t=s,r=c,w(s,c)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,r,1)}}};async function ve(e,t){if("function"==typeof Response&&e instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(e,t)}catch(t){if("application/wasm"==e.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const r=await e.arrayBuffer();return await WebAssembly.instantiate(r,t)}{const r=await WebAssembly.instantiate(e,t);return r instanceof WebAssembly.Instance?{instance:r,module:e}:r}}function me(){const e={wbg:{}};return e.wbg.__wbindgen_object_drop_ref=function(e){g(e)},e.wbg.__wbg_new_71801a555ad9f2aa=function(){return U((function(){return b(new XMLHttpRequest)}),arguments)},e.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return U((function(e,t,r){s(e).overrideMimeType(w(t,r))}),arguments)},e.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return U((function(e,t,r,n,i,_){s(e).open(w(t,r),w(n,i),0!==_)}),arguments)},e.wbg.__wbg_send_80d29985093c1ec5=function(){return U((function(e){s(e).send()}),arguments)},e.wbg.__wbg_response_7c2e2759084f7279=function(){return U((function(e){return b(s(e).response)}),arguments)},e.wbg.__wbg_status_d485fb5a478426fb=function(){return U((function(e){return s(e).status}),arguments)},e.wbg.__wbg_new_72fb9a18b5ae2624=function(){return b(new Object)},e.wbg.__wbindgen_string_new=function(e,t){return b(w(e,t))},e.wbg.__wbg_set_1f9b04f170055d33=function(){return U((function(e,t,r){return Reflect.set(s(e),s(t),s(r))}),arguments)},e.wbg.__wbg_new_ab6fd82b10560829=function(){return U((function(){return b(new Headers)}),arguments)},e.wbg.__wbindgen_object_clone_ref=function(e){return b(s(e))},e.wbg.__wbg_new_0d76b0581eca6298=function(){return U((function(){return b(new AbortController)}),arguments)},e.wbg.__wbg_signal_a61f78a3478fd9bc=function(e){return b(s(e).signal)},e.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return U((function(e,t,r,n,i){s(e).append(w(t,r),w(n,i))}),arguments)},e.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(e){let t;try{t=s(e)instanceof Response}catch(e){t=!1}return t},e.wbg.__wbg_status_61a01141acd3cf74=function(e){return s(e).status},e.wbg.__wbg_url_5f6dc4009ac5f99d=function(e,t){const r=v(s(t).url,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;k()[e/4+1]=n,k()[e/4+0]=r},e.wbg.__wbg_headers_9620bfada380764a=function(e){return b(s(e).headers)},e.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return b(Symbol.iterator)},e.wbg.__wbg_get_e3c254076557e348=function(){return U((function(e,t){return b(Reflect.get(s(e),s(t)))}),arguments)},e.wbg.__wbindgen_is_function=function(e){return"function"==typeof s(e)},e.wbg.__wbg_call_27c0f87801dedf93=function(){return U((function(e,t){return b(s(e).call(s(t)))}),arguments)},e.wbg.__wbindgen_is_object=function(e){const t=s(e);return"object"==typeof t&&null!==t},e.wbg.__wbg_next_40fc327bfc8770e6=function(e){return b(s(e).next)},e.wbg.__wbg_next_196c84450b364254=function(){return U((function(e){return b(s(e).next())}),arguments)},e.wbg.__wbg_done_298b57d23c0fc80c=function(e){return s(e).done},e.wbg.__wbg_value_d93c65011f51a456=function(e){return b(s(e).value)},e.wbg.__wbg_abort_2aa7521d5690750e=function(e){s(e).abort()},e.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return U((function(e){return b(JSON.stringify(s(e)))}),arguments)},e.wbg.__wbindgen_string_get=function(e,t){const r=s(t),n="string"==typeof r?r:void 0;var i=m(n)?0:v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;k()[e/4+1]=_,k()[e/4+0]=i},e.wbg.__wbg_log_eb85b4536c227931=function(e,t){console.log(w(e,t))},e.wbg.__wbindgen_bigint_from_u64=function(e){return b(BigInt.asUintN(64,e))},e.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return U((function(e,t,r){return b(s(e).call(s(t),s(r)))}),arguments)},e.wbg.__wbg_transaction_new=function(e){return b(we.__wrap(e))},e.wbg.__wbg_executionresponse_new=function(e){return b(D.__wrap(e))},e.wbg.__wbg_keypair_new=function(e){return b(Z.__wrap(e))},e.wbg.__wbg_newwithlength_66ae46612e7f0234=function(e){return b(new Array(e>>>0))},e.wbg.__wbg_set_d4638f722068f043=function(e,t,r){s(e)[t>>>0]=g(r)},e.wbg.__wbindgen_module=function(){return b(Se.__wbindgen_wasm_module)},e.wbg.__wbindgen_memory=function(){return b(a.memory)},e.wbg.__wbg_spawnWorker_4026f00664f3193f=function(e,t,r,n){return b(_(s(e),s(t),s(r),n>>>0))},e.wbg.__wbindgen_cb_drop=function(e){const t=g(e).original;if(1==t.cnt--)return t.a=0,!0;return!1},e.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return b(new Array)},e.wbg.__wbg_push_a5b05aedc7234f9f=function(e,t){return s(e).push(s(t))},e.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return U((function(e){return b(s(e).arrayBuffer())}),arguments)},e.wbg.__wbg_new_63b92bc8671ed464=function(e){return b(new Uint8Array(s(e)))},e.wbg.__wbg_length_c20a40f15020d68a=function(e){return s(e).length},e.wbg.__wbg_new_81740750da40724f=function(e,t){try{var r={a:e,b:t};const n=new Promise(((e,t)=>{const n=r.a;r.a=0;try{return I(n,r.b,e,t)}finally{r.a=n}}));return b(n)}finally{r.a=r.b=0}},e.wbg.__wbindgen_number_new=function(e){return b(e)},e.wbg.__wbg_new_abda76e883ba8a5f=function(){return b(new Error)},e.wbg.__wbg_stack_658279fe44541cf6=function(e,t){const r=v(s(t).stack,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;k()[e/4+1]=n,k()[e/4+0]=r},e.wbg.__wbg_error_f851667af71bcfc6=function(e,t){let r,n;try{r=e,n=t,console.error(w(e,t))}finally{a.__wbindgen_free(r,n,1)}},e.wbg.__wbg_buffer_12d079cc21e14bdb=function(e){return b(s(e).buffer)},e.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(e,t,r){return b(new Uint8Array(s(e),t>>>0,r>>>0))},e.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return U((function(e,t){s(e).randomFillSync(g(t))}),arguments)},e.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(e,t,r){return b(s(e).subarray(t>>>0,r>>>0))},e.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return U((function(e,t){s(e).getRandomValues(s(t))}),arguments)},e.wbg.__wbg_set_a47bac70306a19a7=function(e,t,r){s(e).set(s(t),r>>>0)},e.wbg.__wbg_crypto_1d1f22824a6a080c=function(e){return b(s(e).crypto)},e.wbg.__wbg_process_4a72847cc503995b=function(e){return b(s(e).process)},e.wbg.__wbg_versions_f686565e586dd935=function(e){return b(s(e).versions)},e.wbg.__wbg_node_104a2ff8d6ea03a2=function(e){return b(s(e).node)},e.wbg.__wbindgen_is_string=function(e){return"string"==typeof s(e)},e.wbg.__wbg_require_cca90b1a94a0255b=function(){return U((function(){return b(module.require)}),arguments)},e.wbg.__wbg_msCrypto_eb05e62b530a1508=function(e){return b(s(e).msCrypto)},e.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(e){return b(new Uint8Array(e>>>0))},e.wbg.__wbg_length_cd7af8117672b8b8=function(e){return s(e).length},e.wbg.__wbg_get_bd8e338fbd5f5cc8=function(e,t){return b(s(e)[t>>>0])},e.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return U((function(){return b(self.self)}),arguments)},e.wbg.__wbg_window_c6fb939a7f436783=function(){return U((function(){return b(window.window)}),arguments)},e.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return U((function(){return b(globalThis.globalThis)}),arguments)},e.wbg.__wbg_global_207b558942527489=function(){return U((function(){return b(global.global)}),arguments)},e.wbg.__wbindgen_is_undefined=function(e){return void 0===s(e)},e.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(e,t){return b(new Function(w(e,t)))},e.wbg.__wbg_has_0af94d20077affa2=function(){return U((function(e,t){return Reflect.has(s(e),s(t))}),arguments)},e.wbg.__wbg_fetch_bc7c8e27076a5c84=function(e){return b(fetch(s(e)))},e.wbg.__wbg_fetch_921fad6ef9e883dd=function(e,t){return b(s(e).fetch(s(t)))},e.wbg.__wbindgen_debug_string=function(e,t){const r=v(K(s(t)),a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;k()[e/4+1]=n,k()[e/4+0]=r},e.wbg.__wbindgen_throw=function(e,t){throw new Error(w(e,t))},e.wbg.__wbindgen_rethrow=function(e){throw g(e)},e.wbg.__wbg_then_a73caa9a87991566=function(e,t,r){return b(s(e).then(s(t),s(r)))},e.wbg.__wbg_then_0c86a60e8fcfe9f6=function(e,t){return b(s(e).then(s(t)))},e.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(e){queueMicrotask(s(e))},e.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(e){return b(s(e).queueMicrotask)},e.wbg.__wbg_resolve_b0083a7967828ec8=function(e){return b(Promise.resolve(s(e)))},e.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return b(Atomics.waitAsync)},e.wbg.__wbg_new_8cccba86b0f574cb=function(e){return b(new Int32Array(s(e)))},e.wbg.__wbg_waitAsync_46d5c36955b71a79=function(e,t,r){return b(Atomics.waitAsync(s(e),t,r))},e.wbg.__wbg_async_19c0400d97cc72fe=function(e){return s(e).async},e.wbg.__wbg_value_571d60108110e917=function(e){return b(s(e).value)},e.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(e){const t=v("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;k()[e/4+1]=r,k()[e/4+0]=t},e.wbg.__wbg_new_d1187ae36d662ef9=function(){return U((function(e,t){return b(new Worker(w(e,t)))}),arguments)},e.wbg.__wbg_setonmessage_503809e5bb51bd33=function(e,t){s(e).onmessage=s(t)},e.wbg.__wbg_of_6a70eed8d41f469c=function(e,t,r){return b(Array.of(s(e),s(t),s(r)))},e.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return U((function(e,t){s(e).postMessage(s(t))}),arguments)},e.wbg.__wbg_data_3ce7c145ca4fbcdc=function(e){return b(s(e).data)},e.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return U((function(e,t,r){return b(new Request(w(e,t),s(r)))}),arguments)},e.wbg.__wbg_responseText_c67ed2d48db10769=function(){return U((function(e,t){const r=s(t).responseText;var n=m(r)?0:v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),i=p;k()[e/4+1]=i,k()[e/4+0]=n}),arguments)},e.wbg.__wbindgen_closure_wrapper5994=function(e,t,r){return b(T(e,t,622,E))},e.wbg.__wbindgen_closure_wrapper6020=function(e,t,r){return b(T(e,t,622,E))},e}function Pe(e,t){e.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function ke(e,t){return a=e.exports,Se.__wbindgen_wasm_module=t,V=null,P=null,u=null,a.__wbindgen_start(),a}function Ke(e,t){if(void 0!==a)return a;const r=me();Pe(r,t),e instanceof WebAssembly.Module||(e=new WebAssembly.Module(e));return ke(new WebAssembly.Instance(e,r),e)}async function Se(e,t){if(void 0!==a)return a;const r=me();("string"==typeof e||"function"==typeof Request&&e instanceof Request||"function"==typeof URL&&e instanceof URL)&&(e=fetch(e)),Pe(r,t);const{instance:n,module:i}=await ve(await e,r);return ke(n,i)}var i=Object.freeze({__proto__:null,Address:j,Execution:$,ExecutionResponse:D,Field:H,KeyPair:Z,Metadata:J,OfflineQuery:X,PrivateKey:Q,PrivateKeyCiphertext:te,Program:ne,ProgramManager:_e,ProvingKey:oe,RecordCiphertext:ce,RecordPlaintext:ge,Signature:ue,Transaction:we,VerifyingKey:pe,ViewKey:he,default:Se,initSync:Ke,initThreadPool:O,runRayonThread:B,verifyFunctionExecution:R});const Te="aleo_wasm.wasm";const{initThreadPool:Ee,Address:Ce,Execution:Fe,ExecutionResponse:Re,Field:Ve,Metadata:xe,OfflineQuery:Ae,Private:Be,PrivateKey:Oe,PrivateKeyCiphertext:Ue,Program:Ie,ProvingKey:Ne,RecordCiphertext:je,RecordPlaintext:ze,ProgramManager:$e,Signature:Me,Transaction:De,ViewKey:Le,VerifyingKey:He,verifyFunctionExecution:We}=await(async(e={})=>{let{importHook:t,serverPath:r,initializeHook:n}=e,_=Te;return null!=r&&(_=r+/[^\/\\]*$/.exec(_)[0]),null!=t&&(_=t(_)),null!=n?await n(Se,_):await Se(_),i})({importHook:()=>new URL(r(6545),r.b)});async function Ze(e){null==e&&(e=navigator.hardwareConcurrency),console.info(`Spawning ${e} threads`),await Ee(new URL(r(2851),r.b),e)}n()}catch(qe){n(qe)}}),1)},9720:(e,t,r)=>{r.d(t,{LV:()=>l});const n=Symbol("Comlink.proxy"),i=Symbol("Comlink.endpoint"),_=Symbol("Comlink.releaseProxy"),a=Symbol("Comlink.finalizer"),o=Symbol("Comlink.thrown"),s=e=>"object"==typeof e&&null!==e||"function"==typeof e,c=new Map([["proxy",{canHandle:e=>s(e)&&e[n],serialize(e){const{port1:t,port2:r}=new MessageChannel;return d(e,t),[r,[r]]},deserialize:e=>(e.start(),l(e))}],["throw",{canHandle:e=>s(e)&&o in e,serialize({value:e}){let t;return t=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[t,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function d(e,t=globalThis,r=["*"]){t.addEventListener("message",(function i(_){if(!_||!_.data)return;if(!function(e,t){for(const r of e){if(t===r||"*"===r)return!0;if(r instanceof RegExp&&r.test(t))return!0}return!1}(r,_.origin))return void console.warn(`Invalid origin '${_.origin}' for comlink proxy`);const{id:s,type:c,path:l}=Object.assign({path:[]},_.data),u=(_.data.argumentList||[]).map(m);let f;try{const t=l.slice(0,-1).reduce(((e,t)=>e[t]),e),r=l.reduce(((e,t)=>e[t]),e);switch(c){case"GET":f=r;break;case"SET":t[l.slice(-1)[0]]=m(_.data.value),f=!0;break;case"APPLY":f=r.apply(t,u);break;case"CONSTRUCT":f=function(e){return Object.assign(e,{[n]:!0})}(new r(...u));break;case"ENDPOINT":{const{port1:t,port2:r}=new MessageChannel;d(e,r),f=function(e,t){return h.set(e,t),e}(t,[t])}break;case"RELEASE":f=void 0;break;default:return}}catch(e){f={value:e,[o]:0}}Promise.resolve(f).catch((e=>({value:e,[o]:0}))).then((r=>{const[n,_]=v(r);t.postMessage(Object.assign(Object.assign({},n),{id:s}),_),"RELEASE"===c&&(t.removeEventListener("message",i),g(t),a in e&&"function"==typeof e[a]&&e[a]())})).catch((e=>{const[r,n]=v({value:new TypeError("Unserializable return value"),[o]:0});t.postMessage(Object.assign(Object.assign({},r),{id:s}),n)}))})),t.start&&t.start()}function g(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function l(e,t){return p(e,[],t)}function u(e){if(e)throw new Error("Proxy has been released and is not useable")}function f(e){return P(e,{type:"RELEASE"}).then((()=>{g(e)}))}const w=new WeakMap,b="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const t=(w.get(e)||0)-1;w.set(e,t),0===t&&f(e)}));function p(e,t=[],r=function(){}){let n=!1;const a=new Proxy(r,{get(r,i){if(u(n),i===_)return()=>{!function(e){b&&b.unregister(e)}(a),f(e),n=!0};if("then"===i){if(0===t.length)return{then:()=>a};const r=P(e,{type:"GET",path:t.map((e=>e.toString()))}).then(m);return r.then.bind(r)}return p(e,[...t,i])},set(r,i,_){u(n);const[a,o]=v(_);return P(e,{type:"SET",path:[...t,i].map((e=>e.toString())),value:a},o).then(m)},apply(r,_,a){u(n);const o=t[t.length-1];if(o===i)return P(e,{type:"ENDPOINT"}).then(m);if("bind"===o)return p(e,t.slice(0,-1));const[s,c]=y(a);return P(e,{type:"APPLY",path:t.map((e=>e.toString())),argumentList:s},c).then(m)},construct(r,i){u(n);const[_,a]=y(i);return P(e,{type:"CONSTRUCT",path:t.map((e=>e.toString())),argumentList:_},a).then(m)}});return function(e,t){const r=(w.get(t)||0)+1;w.set(t,r),b&&b.register(e,t,e)}(a,e),a}function y(e){const t=e.map(v);return[t.map((e=>e[0])),(r=t.map((e=>e[1])),Array.prototype.concat.apply([],r))];var r}const h=new WeakMap;function v(e){for(const[t,r]of c)if(r.canHandle(e)){const[n,i]=r.serialize(e);return[{type:"HANDLER",name:t,value:n},i]}return[{type:"RAW",value:e},h.get(e)||[]]}function m(e){switch(e.type){case"HANDLER":return c.get(e.name).deserialize(e.value);case"RAW":return e.value}}function P(e,t,r){return new Promise((n=>{const i=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-");e.addEventListener("message",(function t(r){r.data&&r.data.id&&r.data.id===i&&(e.removeEventListener("message",t),n(r.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:i},t),r)}))}}}]); //# sourceMappingURL=523.bundle.js.map \ No newline at end of file diff --git a/523.bundle.js.map b/523.bundle.js.map index b4846dcc1..d79291c69 100644 --- a/523.bundle.js.map +++ b/523.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"523.bundle.js","mappings":";quCA2CaA,EACXC,YACAC,SACAC,SAEAC,WAAAA,CAAYC,EAAuB,CAAC,GAClC,IACEC,KAAKL,YAAcK,KAAKC,qBAAqBF,GAC7C,MAAOG,GAEP,MADAC,QAAQC,MAAM,kBAAmBF,GAC3B,IAAIG,MAAM,mBAElBL,KAAKJ,SAAWU,EAAAA,GAAQC,iBAAiBP,KAAKL,aAC9CK,KAAKH,SAAWW,EAAAA,GAAQD,iBAAiBP,KAAKL,aAazC,qBAAOc,CAAeC,EAA2CC,GACtE,IACED,EAAoC,iBAAfA,EAA2BE,EAAAA,GAAqBC,WAAWH,GAAcA,EAC9F,MAAMf,EAAcmB,EAAAA,GAAWC,yBAAyBL,EAAYC,GACpE,OAAO,IAAIjB,EAAQ,CAAEsB,WAAYrB,EAAYsB,cAC7C,MAAMf,GACN,MAAM,IAAIG,MAAM,yCAIZJ,oBAAAA,CAAqBF,GAC3B,OAAIA,EAAOmB,KACFJ,EAAAA,GAAWK,oBAAoBpB,EAAOmB,MAE3CnB,EAAOiB,WACFF,EAAAA,GAAWM,YAAYrB,EAAOiB,YAEhC,IAAIF,EAAAA,GAGbE,UAAAA,GACE,OAAOhB,KAAKL,YAGd0B,OAAAA,GACE,OAAOrB,KAAKJ,SAGd0B,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AMiD,MACV,IAAK,UACD,OAAOq6B,EAAiB/8B,IAAIP,EAAM6G,MAAMg3B,YAAY79B,EAAMA,OAC9D,IAAK,MACD,OAAOA,EAAMA,MAEzB,CACA,SAASogC,EAAuBnC,EAAI2D,EAAKzC,GACrC,OAAO,IAAInyB,SAASC,IAChB,MAAM/G,EAeH,IAAIlE,MAAM,GACZgW,KAAK,GACL7Y,KAAI,IAAMgW,KAAK0sB,MAAM1sB,KAAK2sB,SAAW5hC,OAAO6hC,kBAAkBnjC,SAAS,MACvEqM,KAAK,KAjBNgzB,EAAG1mB,iBAAiB,WAAW,SAAS9T,EAAE26B,GACjCA,EAAG92B,MAAS82B,EAAG92B,KAAKpB,IAAMk4B,EAAG92B,KAAKpB,KAAOA,IAG9C+3B,EAAGwB,oBAAoB,UAAWh8B,GAClCwJ,EAAQmxB,EAAG92B,MACf,IACI22B,EAAGh8B,OACHg8B,EAAGh8B,QAEPg8B,EAAGpmB,YAAYnR,OAAOC,OAAO,CAAET,MAAM07B,GAAMzC,EAAU,GAE7D","sources":["webpack://aleo-website/../../src/account.ts","webpack://aleo-website/../../src/utils.ts","webpack://aleo-website/../../src/network-client.ts","webpack://aleo-website/../../src/function-key-provider.ts","webpack://aleo-website/../../src/offline-key-provider.ts","webpack://aleo-website/../../src/record-provider.ts","webpack://aleo-website/../../src/managed-worker.ts","webpack://aleo-website/../../src/program-manager.ts","webpack://aleo-website/../../src/browser.ts","webpack://aleo-website/aleo_wasm.js","webpack://aleo-website/../node_modules/comlink/dist/esm/comlink.mjs"],"sourcesContent":["import {\n Address,\n PrivateKey,\n Signature,\n ViewKey,\n PrivateKeyCiphertext,\n RecordCiphertext,\n} from \"./browser\";\n\ninterface AccountParam {\n privateKey?: string;\n seed?: Uint8Array;\n}\n\n/**\n * Key Management class. Enables the creation of a new Aleo Account, importation of an existing account from\n * an existing private key or seed, and message signing and verification functionality.\n *\n * An Aleo Account is generated from a randomly generated seed (number) from which an account private key, view key,\n * and a public account address are derived. The private key lies at the root of an Aleo account. It is a highly\n * sensitive secret and should be protected as it allows for creation of Aleo Program executions and arbitrary value\n * transfers. The View Key allows for decryption of a user's activity on the blockchain. The Address is the public\n * address to which other users of Aleo can send Aleo credits and other records to. This class should only be used\n * environments where the safety of the underlying key material can be assured.\n *\n * @example\n * // Create a new account\n * const myRandomAccount = new Account();\n *\n * // Create an account from a randomly generated seed\n * const seed = new Uint8Array([94, 91, 52, 251, 240, 230, 226, 35, 117, 253, 224, 210, 175, 13, 205, 120, 155, 214, 7, 169, 66, 62, 206, 50, 188, 40, 29, 122, 40, 250, 54, 18]);\n * const mySeededAccount = new Account({seed: seed});\n *\n * // Create an account from an existing private key\n * const myExistingAccount = new Account({privateKey: 'myExistingPrivateKey'})\n *\n * // Sign a message\n * const hello_world = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * const signature = myRandomAccount.sign(hello_world)\n *\n * // Verify a signature\n * myRandomAccount.verify(hello_world, signature)\n */\nexport class Account {\n _privateKey: PrivateKey;\n _viewKey: ViewKey;\n _address: Address;\n\n constructor(params: AccountParam = {}) {\n try {\n this._privateKey = this.privateKeyFromParams(params);\n } catch (e) {\n console.error(\"Wrong parameter\", e);\n throw new Error(\"Wrong Parameter\");\n }\n this._viewKey = ViewKey.from_private_key(this._privateKey);\n this._address = Address.from_private_key(this._privateKey);\n }\n\n /**\n * Attempts to create an account from a private key ciphertext\n * @param {PrivateKeyCiphertext | string} ciphertext\n * @param {string} password\n * @returns {PrivateKey}\n *\n * @example\n * const ciphertext = PrivateKey.newEncrypted(\"password\");\n * const account = Account.fromCiphertext(ciphertext, \"password\");\n */\n public static fromCiphertext(ciphertext: PrivateKeyCiphertext | string, password: string) {\n try {\n ciphertext = (typeof ciphertext === \"string\") ? PrivateKeyCiphertext.fromString(ciphertext) : ciphertext;\n const _privateKey = PrivateKey.fromPrivateKeyCiphertext(ciphertext, password);\n return new Account({ privateKey: _privateKey.to_string() });\n } catch(e) {\n throw new Error(\"Wrong password or invalid ciphertext\");\n }\n }\n\n private privateKeyFromParams(params: AccountParam) {\n if (params.seed) {\n return PrivateKey.from_seed_unchecked(params.seed);\n }\n if (params.privateKey) {\n return PrivateKey.from_string(params.privateKey);\n }\n return new PrivateKey();\n }\n\n privateKey() {\n return this._privateKey;\n }\n\n viewKey() {\n return this._viewKey;\n }\n\n address() {\n return this._address;\n }\n\n toString() {\n return this.address().to_string()\n }\n\n /**\n * Encrypt the account's private key with a password\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n *\n * @example\n * const account = new Account();\n * const ciphertext = account.encryptAccount(\"password\");\n */\n encryptAccount(password: string) {\n return this._privateKey.toCiphertext(password);\n }\n\n /**\n * Decrypts a Record in ciphertext form into plaintext\n * @param {string} ciphertext\n * @returns {Record}\n *\n * @example\n * const account = new Account();\n * const record = account.decryptRecord(\"record1ciphertext\");\n */\n decryptRecord(ciphertext: string) {\n return this._viewKey.decrypt(ciphertext);\n }\n\n /**\n * Decrypts an array of Records in ciphertext form into plaintext\n * @param {string[]} ciphertexts\n * @returns {Record[]}\n *\n * @example\n * const account = new Account();\n * const record = account.decryptRecords([\"record1ciphertext\", \"record2ciphertext\"]);\n */\n decryptRecords(ciphertexts: string[]) {\n return ciphertexts.map((ciphertext) => this._viewKey.decrypt(ciphertext));\n }\n\n /**\n * Determines whether the account owns a ciphertext record\n * @param {RecordCipherText | string} ciphertext\n * @returns {boolean}\n *\n * @example\n * // Create a connection to the Aleo network and an account\n * const connection = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const account = Account.fromCiphertext(\"ciphertext\", \"password\");\n *\n * // Get a record from the network\n * const record = connection.getBlock(1234);\n * const recordCipherText = record.transactions[0].execution.transitions[0].id;\n *\n * // Check if the account owns the record\n * if account.ownsRecord(recordCipherText) {\n * // Then one can do something like:\n * // Decrypt the record and check if it's spent\n * // Store the record in a local database\n * // Etc.\n * }\n */\n ownsRecordCiphertext(ciphertext: RecordCiphertext | string) {\n if (typeof ciphertext === 'string') {\n try {\n const ciphertextObject = RecordCiphertext.fromString(ciphertext);\n return ciphertextObject.isOwner(this._viewKey);\n }\n catch (e) {\n return false;\n }\n }\n else {\n return ciphertext.isOwner(this._viewKey);\n }\n }\n\n /**\n * Signs a message with the account's private key.\n * Returns a Signature.\n *\n * @param {Uint8Array} message\n * @returns {Signature}\n *\n * @example\n * const account = new Account();\n * const message = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * account.sign(message);\n */\n sign(message: Uint8Array) {\n return this._privateKey.sign(message);\n }\n\n /**\n * Verifies the Signature on a message.\n *\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n *\n * @example\n * const account = new Account();\n * const message = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * const signature = account.sign(message);\n * account.verify(message, signature);\n */\n verify(message: Uint8Array, signature: Signature) {\n return this._address.verify(message, signature);\n }\n\n}\n","export function parseJSON(json: string): any {\n function revive(key: string, value: any, context: any) {\n if (Number.isInteger(value)) {\n return BigInt(context.source);\n\n } else {\n return value;\n }\n }\n\n return JSON.parse(json, revive as any);\n}\n\n\nexport async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post, parseJSON } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./browser\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/%%NETWORK%%\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/%%NETWORK%%\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = `Error fetching blocks between ${start} and ${end}.`;\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return Number(await this.fetchData(\"/latest/height\"));\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error: any) {\n logAndThrow(\"Error fetching program imports: \" + error.message);\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error: any) {\n throw new Error(\"Error fetching program imports with error: \" + error.message);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error: any) {\n throw new Error(`Error posting transaction. Aleo network response: ${error.message}`);\n }\n } catch (error: any) {\n throw new Error(`Error posting transaction: No response received: ${error.message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./browser\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error: any) {\n throw new Error(\"Error fetching data.\" + error.message);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n throw new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n return this.fetchCreditsKeys(key);\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw new Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error: any) {\n throw new Error(`Error: fetching credits.aleo keys: ${error.message}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner: any) {\n throw new Error(\"Invalid verifying key. Error: \" + inner.message);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n FunctionKeyProvider,\n KeySearchParams,\n FunctionKeyPair,\n CachedKeyPair,\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./browser\";\n\n/**\n * Search parameters for the offline key provider. This class implements the KeySearchParams interface and includes\n * a convenience method for creating a new instance of this class for each function of the credits.aleo program.\n *\n * @example\n * // If storing a key for a custom program function\n * offlineSearchParams = new OfflineSearchParams(\"myprogram.aleo/myfunction\");\n *\n * // If storing a key for a credits.aleo program function\n * bondPublicKeyParams = OfflineSearchParams.bondPublicKeyParams();\n */\nclass OfflineSearchParams implements KeySearchParams {\n cacheKey: string | undefined;\n verifyCreditsKeys: boolean | undefined;\n\n /**\n * Create a new OfflineSearchParams instance.\n *\n * @param {string} cacheKey - Key used to store the local function proving & verifying keys. This should be stored\n * under the naming convention \"programName/functionName\" (i.e. \"myprogram.aleo/myfunction\")\n * @param {boolean} verifyCreditsKeys - Whether to verify the keys against the credits.aleo program,\n * defaults to false, but should be set to true if using keys from the credits.aleo program\n */\n constructor(cacheKey: string, verifyCreditsKeys = false) {\n this.cacheKey = cacheKey;\n this.verifyCreditsKeys = verifyCreditsKeys;\n }\n\n /**\n * Create a new OfflineSearchParams instance for the bond_public function of the credits.aleo program.\n */\n static bondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.bond_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the bond_validator function of the credits.aleo program.\n */\n static bondValidatorKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.bond_validator.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the claim_unbond_public function of the\n */\n static claimUnbondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.claim_unbond_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the fee_private function of the credits.aleo program.\n */\n static feePrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.fee_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the fee_public function of the credits.aleo program.\n */\n static feePublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.fee_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the inclusion prover function.\n */\n static inclusionKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.inclusion.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the join function of the credits.aleo program.\n */\n static joinKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.join.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the set_validator_state function of the credits.aleo program.\n */\n static setValidatorStateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.set_validator_state.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the split function of the credits.aleo program.\n */\n static splitKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.split.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_private function of the credits.aleo program.\n */\n static transferPrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_private_to_public function of the credits.aleo program.\n */\n static transferPrivateToPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public function of the credits.aleo program.\n */\n static transferPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public_as_signer function of the credits.aleo program.\n */\n static transferPublicAsSignerKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public_as_signer.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public_to_private function of the credits.aleo program.\n */\n static transferPublicToPrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the unbond_public function of the credits.aleo program.\n */\n static unbondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.unbond_public.locator, true);\n }\n}\n\n/**\n * A key provider meant for building transactions offline on devices such as hardware wallets. This key provider is not\n * able to contact the internet for key material and instead relies on the user to insert Aleo function proving &\n * verifying keys from local storage prior to usage.\n *\n * @example\n * // Create an offline program manager\n * const programManager = new ProgramManager();\n *\n * // Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * // Create the proving keys from the key bytes on the offline machine\n * console.log(\"Creating proving keys from local key files\");\n * const program = \"program hello_hello.aleo; function hello: input r0 as u32.public; input r1 as u32.private; add r0 r1 into r2; output r2 as u32.private;\";\n * const myFunctionProver = await getLocalKey(\"/path/to/my/function/hello_hello.prover\");\n * const myFunctionVerifier = await getLocalKey(\"/path/to/my/function/hello_hello.verifier\");\n * const feePublicProvingKeyBytes = await getLocalKey(\"/path/to/credits.aleo/feePublic.prover\");\n *\n * myFunctionProvingKey = ProvingKey.fromBytes(myFunctionProver);\n * myFunctionVerifyingKey = VerifyingKey.fromBytes(myFunctionVerifier);\n * const feePublicProvingKey = ProvingKey.fromBytes(feePublicKeyBytes);\n *\n * // Create an offline key provider\n * console.log(\"Creating offline key provider\");\n * const offlineKeyProvider = new OfflineKeyProvider();\n *\n * // Cache the keys\n * // Cache the proving and verifying keys for the custom hello function\n * OfflineKeyProvider.cacheKeys(\"hello_hello.aleo/hello\", myFunctionProvingKey, myFunctionVerifyingKey);\n *\n * // Cache the proving key for the fee_public function (the verifying key is automatically cached)\n * OfflineKeyProvider.insertFeePublicKey(feePublicProvingKey);\n *\n * // Create an offline query using the latest state root in order to create the inclusion proof\n * const offlineQuery = new OfflineQuery(\"latestStateRoot\");\n *\n * // Insert the key provider into the program manager\n * programManager.setKeyProvider(offlineKeyProvider);\n *\n * // Create the offline search params\n * const offlineSearchParams = new OfflineSearchParams(\"hello_hello.aleo/hello\");\n *\n * // Create the offline transaction\n * const offlineExecuteTx = await this.buildExecutionTransaction(\"hello_hello.aleo\", \"hello\", 1, false, [\"5u32\", \"5u32\"], undefined, offlineSearchParams, undefined, undefined, undefined, undefined, offlineQuery, program);\n *\n * // Broadcast the transaction later on a machine with internet access\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const txId = await networkClient.broadcastTransaction(offlineExecuteTx);\n */\nclass OfflineKeyProvider implements FunctionKeyProvider {\n cache: Map;\n\n constructor() {\n this.cache = new Map();\n }\n\n /**\n * Get bond_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.bondPublicKeyParams());\n };\n\n /**\n * Get bond_validator function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondValidatorKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.bondValidatorKeyParams());\n };\n\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n };\n\n /**\n * Get unbond_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.claimUnbondPublicKeyParams());\n };\n\n /**\n * Get arbitrary function key from the offline key provider cache.\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * /// First cache the keys from local offline resources\n * const offlineKeyProvider = new OfflineKeyProvider();\n * const myFunctionVerifyingKey = VerifyingKey.fromString(\"verifier...\");\n * const myFunctionProvingKeyBytes = await readBinaryFile('./resources/myfunction.prover');\n * const myFunctionProvingKey = ProvingKey.fromBytes(myFunctionProvingKeyBytes);\n *\n * /// Cache the keys for future use with a memorable locator\n * offlineKeyProvider.cacheKeys(\"myprogram.aleo/myfunction\", [myFunctionProvingKey, myFunctionVerifyingKey]);\n *\n * /// When they're needed, retrieve the keys from the cache\n *\n * /// First create a search parameter object with the same locator used to cache the keys\n * const keyParams = new OfflineSearchParams(\"myprogram.aleo/myfunction\");\n *\n * /// Then retrieve the keys\n * const [myFunctionProver, myFunctionVerifier] = await offlineKeyProvider.functionKeys(keyParams);\n */\n functionKeys(params?: KeySearchParams): Promise {\n return new Promise((resolve, reject) => {\n if (params === undefined) {\n reject(new Error(\"No search parameters provided, cannot retrieve keys\"));\n } else {\n const keyId = params.cacheKey;\n const verifyCreditsKeys = params.verifyCreditsKeys;\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId) as CachedKeyPair;\n const provingKey = ProvingKey.fromBytes(provingKeyBytes);\n const verifyingKey = VerifyingKey.fromBytes(verifyingKeyBytes);\n if (verifyCreditsKeys) {\n const keysMatchExpected = this.verifyCreditsKeys(keyId, provingKey, verifyingKey)\n if (!keysMatchExpected) {\n reject (new Error(`Cached keys do not match expected keys for ${keyId}`));\n }\n }\n resolve([provingKey, verifyingKey]);\n } else {\n reject(new Error(\"Keys not found in cache for \" + keyId));\n }\n }\n });\n };\n\n /**\n * Determines if the keys for a given credits function match the expected keys.\n *\n * @returns {boolean} Whether the keys match the expected keys\n */\n verifyCreditsKeys(locator: string, provingKey: ProvingKey, verifyingKey: VerifyingKey): boolean {\n switch (locator) {\n case CREDITS_PROGRAM_KEYS.bond_public.locator:\n return provingKey.isBondPublicProver() && verifyingKey.isBondPublicVerifier();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.locator:\n return provingKey.isClaimUnbondPublicProver() && verifyingKey.isClaimUnbondPublicVerifier();\n case CREDITS_PROGRAM_KEYS.fee_private.locator:\n return provingKey.isFeePrivateProver() && verifyingKey.isFeePrivateVerifier();\n case CREDITS_PROGRAM_KEYS.fee_public.locator:\n return provingKey.isFeePublicProver() && verifyingKey.isFeePublicVerifier();\n case CREDITS_PROGRAM_KEYS.inclusion.locator:\n return provingKey.isInclusionProver() && verifyingKey.isInclusionVerifier();\n case CREDITS_PROGRAM_KEYS.join.locator:\n return provingKey.isJoinProver() && verifyingKey.isJoinVerifier();\n case CREDITS_PROGRAM_KEYS.set_validator_state.locator:\n return provingKey.isSetValidatorStateProver() && verifyingKey.isSetValidatorStateVerifier();\n case CREDITS_PROGRAM_KEYS.split.locator:\n return provingKey.isSplitProver() && verifyingKey.isSplitVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_private.locator:\n return provingKey.isTransferPrivateProver() && verifyingKey.isTransferPrivateVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator:\n return provingKey.isTransferPrivateToPublicProver() && verifyingKey.isTransferPrivateToPublicVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_public.locator:\n return provingKey.isTransferPublicProver() && verifyingKey.isTransferPublicVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator:\n return provingKey.isTransferPublicToPrivateProver() && verifyingKey.isTransferPublicToPrivateVerifier();\n case CREDITS_PROGRAM_KEYS.unbond_public.locator:\n return provingKey.isUnbondPublicProver() && verifyingKey.isUnbondPublicVerifier();\n default:\n return false;\n }\n }\n\n /**\n * Get fee_private function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.feePrivateKeyParams());\n };\n\n /**\n * Get fee_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.feePublicKeyParams());\n };\n\n /**\n * Get join function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.joinKeyParams());\n };\n\n /**\n * Get split function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.splitKeyParams());\n };\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program.\n *\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new OfflineKeyProvider\n * const offlineKeyProvider = new OfflineKeyProvider();\n *\n * // Cache the keys for future use with the official locator\n * const transferPublicProvingKeyBytes = await readBinaryFile('./resources/transfer_public.prover.a74565e');\n * const transferPublicProvingKey = ProvingKey.fromBytes(transferPublicProvingKeyBytes);\n *\n * // Cache the transfer_public keys for future use with the OfflinKeyProvider's convenience method for\n * // transfer_public (the verifying key will be cached automatically)\n * offlineKeyProvider.insertTransferPublicKeys(transferPublicProvingKey);\n *\n * /// When they're needed, retrieve the keys from the cache\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPrivateKeyParams());\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPrivateToPublicKeyParams());\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicKeyParams());\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicAsSignerKeyParams());\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicToPrivateKeyParams());\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n };\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async unBondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.unbondPublicKeyParams());\n };\n\n /**\n * Insert the proving and verifying keys for the bond_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for bond_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertBondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isBondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [provingKey.toBytes(), VerifyingKey.bondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for bond_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the claim_unbond_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for claim_unbond_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertClaimUnbondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isClaimUnbondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.claim_unbond_public.locator, [provingKey.toBytes(), VerifyingKey.claimUnbondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for claim_unbond_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the fee_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for fee_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertFeePrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isFeePrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.fee_private.locator, [provingKey.toBytes(), VerifyingKey.feePrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for fee_private\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the fee_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for fee_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertFeePublicKeys(provingKey: ProvingKey) {\n if (provingKey.isFeePublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.fee_public.locator, [provingKey.toBytes(), VerifyingKey.feePublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for fee_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the join function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for join before inserting them into the cache.\n *\n * @param provingKey\n */\n insertJoinKeys(provingKey: ProvingKey) {\n if (provingKey.isJoinProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.join.locator, [provingKey.toBytes(), VerifyingKey.joinVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for join\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the set_validator_state function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for set_validator_state before inserting them into the cache.\n *\n * @param provingKey\n */\n insertSetValidatorStateKeys(provingKey: ProvingKey) {\n if (provingKey.isSetValidatorStateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.set_validator_state.locator, [provingKey.toBytes(), VerifyingKey.setValidatorStateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for set_validator_state\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the split function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for split before inserting them into the cache.\n *\n * @param provingKey\n */\n insertSplitKeys(provingKey: ProvingKey) {\n if (provingKey.isSplitProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.split.locator, [provingKey.toBytes(), VerifyingKey.splitVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for split\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_private.locator, [provingKey.toBytes(), VerifyingKey.transferPrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_private\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_private_to_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_private_to_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPrivateToPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPrivateToPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator, [provingKey.toBytes(), VerifyingKey.transferPrivateToPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_private_to_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_public.locator, [provingKey.toBytes(), VerifyingKey.transferPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_public_to_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_public_to_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPublicToPrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPublicToPrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator, [provingKey.toBytes(), VerifyingKey.transferPublicToPrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_public_to_private\");\n }\n }\n\n insertUnbondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isUnbondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.unbond_public.locator, [provingKey.toBytes(), VerifyingKey.unbondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for unbond_public\");\n }\n }\n}\n\n\nexport {OfflineKeyProvider, OfflineSearchParams}\n","import { logAndThrow, RecordPlaintext } from \"./browser\";\nimport { Account } from \"./account\";\nimport { AleoNetworkClient } from \"./network-client\";\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface RecordSearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * Interface for a record provider. A record provider is used to find records for use in deployment and execution\n * transactions on the Aleo Network. A default implementation is provided by the NetworkRecordProvider class. However,\n * a custom implementation can be provided (say if records are synced locally to a database from the network) by\n * implementing this interface.\n */\ninterface RecordProvider {\n account: Account\n\n /**\n * Find a credits.aleo record with a given number of microcredits from the chosen provider\n *\n * @param {number} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // A class implementing record provider can be used to find a record with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, its nonce should be added to the nonces array so that it is not\n * // found again if a subsequent search is performed\n * const record2 = await recordProvider.findCreditsRecord(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n findCreditsRecord(microcredits: number, unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find a list of credit.aleo records with a given number of microcredits from the chosen provider\n *\n * @param {number} microcreditAmounts A list of separate microcredit amounts to search for (e.g. [5000, 100000])\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} A list of records with a value greater or equal to the amounts specified if such records exist, otherwise an error\n *\n * @example\n * // A class implementing record provider can be used to find a record with a given number of microcredits\n * const records = await recordProvider.findCreditsRecords([5000, 5000], true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces array so that it is not\n * // found again if a subsequent search is performed\n * const nonces = [];\n * records.forEach(record => { nonces.push(record.nonce()) });\n * const records2 = await recordProvider.findCreditsRecord(5000, true, nonces);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n findCreditsRecords(microcreditAmounts: number[], unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find an arbitrary record\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // The RecordSearchParams interface can be used to create parameters for custom record searches which can then\n * // be passed to the record provider. An example of how this would be done for the credits.aleo program is shown\n * // below.\n *\n * class CustomRecordSearch implements RecordSearchParams {\n * startHeight: number;\n * endHeight: number;\n * amount: number;\n * program: string;\n * recordName: string;\n * constructor(startHeight: number, endHeight: number, credits: number, maxRecords: number, programName: string, recordName: string) {\n * this.startHeight = startHeight;\n * this.endHeight = endHeight;\n * this.amount = amount;\n * this.program = programName;\n * this.recordName = recordName;\n * }\n * }\n *\n * const params = new CustomRecordSearch(0, 100, 5000, \"credits.aleo\", \"credits\");\n *\n * const record = await recordProvider.findRecord(true, [], params);\n */\n findRecord(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find multiple records from arbitrary programs\n *\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * // The RecordSearchParams interface can be used to create parameters for custom record searches which can then\n * // be passed to the record provider. An example of how this would be done for the credits.aleo program is shown\n * // below.\n *\n * class CustomRecordSearch implements RecordSearchParams {\n * startHeight: number;\n * endHeight: number;\n * amount: number;\n * maxRecords: number;\n * programName: string;\n * recordName: string;\n * constructor(startHeight: number, endHeight: number, credits: number, maxRecords: number, programName: string, recordName: string) {\n * this.startHeight = startHeight;\n * this.endHeight = endHeight;\n * this.amount = amount;\n * this.maxRecords = maxRecords;\n * this.programName = programName;\n * this.recordName = recordName;\n * }\n * }\n *\n * const params = new CustomRecordSearch(0, 100, 5000, 2, \"credits.aleo\", \"credits\");\n * const records = await recordProvider.findRecord(true, [], params);\n */\n findRecords(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n}\n\n/**\n * A record provider implementation that uses the official Aleo API to find records for usage in program execution and\n * deployment, wallet functionality, and other use cases.\n */\nclass NetworkRecordProvider implements RecordProvider {\n account: Account;\n networkClient: AleoNetworkClient;\n constructor(account: Account, networkClient: AleoNetworkClient) {\n this.account = account;\n this.networkClient = networkClient;\n }\n\n /**\n * Set the account used to search for records\n *\n * @param {Account} account The account to use for searching for records\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Find a list of credit records with a given number of microcredits by via the official Aleo API\n *\n * @param {number[]} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces parameter so that it is not\n * // found again if a subsequent search is performed\n * const records = await recordProvider.findCreditsRecords(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * */\n async findCreditsRecords(microcredits: number[], unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n let startHeight = 0;\n let endHeight = 0;\n\n if (searchParameters) {\n if (\"startHeight\" in searchParameters && typeof searchParameters[\"endHeight\"] == \"number\") {\n startHeight = searchParameters[\"startHeight\"];\n }\n\n if (\"endHeight\" in searchParameters && typeof searchParameters[\"endHeight\"] == \"number\") {\n endHeight = searchParameters[\"endHeight\"];\n }\n }\n\n // If the end height is not specified, use the current block height\n if (endHeight == 0) {\n const end = await this.networkClient.getLatestHeight();\n endHeight = end;\n }\n\n // If the start height is greater than the end height, throw an error\n if (startHeight >= endHeight) {\n logAndThrow(\"Start height must be less than end height\");\n }\n\n return await this.networkClient.findUnspentRecords(startHeight, endHeight, this.account.privateKey(), microcredits, undefined, nonces);\n }\n\n /**\n * Find a credit record with a given number of microcredits by via the official Aleo API\n *\n * @param {number} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces parameter so that it is not\n * // found again if a subsequent search is performed\n * const records = await recordProvider.findCreditsRecords(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n async findCreditsRecord(microcredits: number, unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n let records = null;\n\n try {\n records = await this.findCreditsRecords([microcredits], unspent, nonces, searchParameters);\n } catch (e) {}\n\n if (records && records.length > 0) {\n return records[0];\n }\n\n console.error(\"Record not found with error:\", records);\n throw new Error(\"Record not found\");\n }\n\n /**\n * Find an arbitrary record. WARNING: This function is not implemented yet and will throw an error.\n */\n async findRecord(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n throw new Error(\"Method not implemented.\");\n }\n\n /**\n * Find multiple arbitrary records. WARNING: This function is not implemented yet and will throw an error.\n */\n async findRecords(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n throw new Error(\"Method not implemented.\");\n }\n\n}\n\n/**\n * BlockHeightSearch is a RecordSearchParams implementation that allows for searching for records within a given\n * block height range.\n *\n * @example\n * // Create a new BlockHeightSearch\n * const params = new BlockHeightSearch(89995, 99995);\n *\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits and the block height search\n * // can be used to find records within a given block height range\n * const record = await recordProvider.findCreditsRecord(5000, true, [], params);\n *\n */\nclass BlockHeightSearch implements RecordSearchParams {\n startHeight: number;\n endHeight: number;\n constructor(startHeight: number, endHeight: number) {\n this.startHeight = startHeight;\n this.endHeight = endHeight;\n }\n}\n\nexport { BlockHeightSearch, NetworkRecordProvider, RecordProvider, RecordSearchParams};\n","// Experimental example where SDK manages worker\n\nimport { wrap } from \"comlink\";\nimport { WorkerAPI } from './worker';\n\nlet singletonWorker: WorkerAPI | null = null;\n\nconst createAleoWorker = (): WorkerAPI => {\n if (!singletonWorker) {\n const worker = new Worker(new URL(\"worker.js\", import.meta.url), {\n type: \"module\",\n });\n singletonWorker = wrap(worker);\n }\n return singletonWorker;\n};\n\nexport { createAleoWorker };","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionExecution,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./browser\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.provable.com/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n\n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e: any) {\n logAndThrow(`Error validating program: ${e.message}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e: any) {\n logAndThrow(`Error finding ${programName}. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e: any) {\n logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e: any) {\n logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e: any) {\n logAndThrow(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program} The program object\n */\n createProgramFromSource(program: string): Program {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import \"./polyfill/shared\";\nimport {VerifyingKey, Metadata} from \"@provablehq/wasm/%%NETWORK%%.js\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n throw new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): never {\n console.error(message);\n throw new Error(message);\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm/%%NETWORK%%.js\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n","function spawnWorker(url, module, memory, address) {\n return new Promise((resolve) => {\n const worker = new Worker(url, {\n type: \"module\",\n });\n\n worker.addEventListener(\"message\", (event) => {\n // This is needed in Node to wait one extra tick, so that way\n // the Worker can fully initialize before we return.\n setTimeout(() => {\n resolve(worker);\n\n // When running in Node, this allows the process to exit\n // even though the Worker is still running.\n if (worker.unref) {\n worker.unref();\n }\n }, 0);\n }, {\n capture: true,\n once: true,\n });\n\n worker.postMessage({\n module,\n memory,\n address,\n });\n });\n }\n\nlet wasm;\n\nconst heap = new Array(128).fill(undefined);\n\nheap.push(undefined, null, true, false);\n\nfunction getObject(idx) { return heap[idx]; }\n\nlet heap_next = heap.length;\n\nfunction dropObject(idx) {\n if (idx < 132) return;\n heap[idx] = heap_next;\n heap_next = idx;\n}\n\nfunction takeObject(idx) {\n const ret = getObject(idx);\n dropObject(idx);\n return ret;\n}\n\nconst cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );\n\nif (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); }\nlet cachedUint8Memory0 = null;\n\nfunction getUint8Memory0() {\n if (cachedUint8Memory0 === null || cachedUint8Memory0.buffer !== wasm.memory.buffer) {\n cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);\n }\n return cachedUint8Memory0;\n}\n\nfunction getStringFromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return cachedTextDecoder.decode(getUint8Memory0().slice(ptr, ptr + len));\n}\n\nfunction addHeapObject(obj) {\n if (heap_next === heap.length) heap.push(heap.length + 1);\n const idx = heap_next;\n heap_next = heap[idx];\n\n heap[idx] = obj;\n return idx;\n}\n\nlet WASM_VECTOR_LEN = 0;\n\nconst cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );\n\nconst encodeString = function (arg, view) {\n const buf = cachedTextEncoder.encode(arg);\n view.set(buf);\n return {\n read: arg.length,\n written: buf.length\n };\n};\n\nfunction passStringToWasm0(arg, malloc, realloc) {\n\n if (realloc === undefined) {\n const buf = cachedTextEncoder.encode(arg);\n const ptr = malloc(buf.length, 1) >>> 0;\n getUint8Memory0().subarray(ptr, ptr + buf.length).set(buf);\n WASM_VECTOR_LEN = buf.length;\n return ptr;\n }\n\n let len = arg.length;\n let ptr = malloc(len, 1) >>> 0;\n\n const mem = getUint8Memory0();\n\n let offset = 0;\n\n for (; offset < len; offset++) {\n const code = arg.charCodeAt(offset);\n if (code > 0x7F) break;\n mem[ptr + offset] = code;\n }\n\n if (offset !== len) {\n if (offset !== 0) {\n arg = arg.slice(offset);\n }\n ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;\n const view = getUint8Memory0().subarray(ptr + offset, ptr + len);\n const ret = encodeString(arg, view);\n\n offset += ret.written;\n ptr = realloc(ptr, len, offset, 1) >>> 0;\n }\n\n WASM_VECTOR_LEN = offset;\n return ptr;\n}\n\nfunction isLikeNone(x) {\n return x === undefined || x === null;\n}\n\nlet cachedInt32Memory0 = null;\n\nfunction getInt32Memory0() {\n if (cachedInt32Memory0 === null || cachedInt32Memory0.buffer !== wasm.memory.buffer) {\n cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);\n }\n return cachedInt32Memory0;\n}\n\nfunction debugString(val) {\n // primitive types\n const type = typeof val;\n if (type == 'number' || type == 'boolean' || val == null) {\n return `${val}`;\n }\n if (type == 'string') {\n return `\"${val}\"`;\n }\n if (type == 'symbol') {\n const description = val.description;\n if (description == null) {\n return 'Symbol';\n } else {\n return `Symbol(${description})`;\n }\n }\n if (type == 'function') {\n const name = val.name;\n if (typeof name == 'string' && name.length > 0) {\n return `Function(${name})`;\n } else {\n return 'Function';\n }\n }\n // objects\n if (Array.isArray(val)) {\n const length = val.length;\n let debug = '[';\n if (length > 0) {\n debug += debugString(val[0]);\n }\n for(let i = 1; i < length; i++) {\n debug += ', ' + debugString(val[i]);\n }\n debug += ']';\n return debug;\n }\n // Test for built-in\n const builtInMatches = /\\[object ([^\\]]+)\\]/.exec(toString.call(val));\n let className;\n if (builtInMatches.length > 1) {\n className = builtInMatches[1];\n } else {\n // Failed to match the standard '[object ClassName]'\n return toString.call(val);\n }\n if (className == 'Object') {\n // we're a user defined class or Object\n // JSON.stringify avoids problems with cycles, and is generally much\n // easier than looping through ownProperties of `val`.\n try {\n return 'Object(' + JSON.stringify(val) + ')';\n } catch (_) {\n return 'Object';\n }\n }\n // errors\n if (val instanceof Error) {\n return `${val.name}: ${val.message}\\n${val.stack}`;\n }\n // TODO we could test for more things here, like `Set`s and `Map`s.\n return className;\n}\n\nconst CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(state => {\n wasm.__wbindgen_export_3.get(state.dtor)(state.a, state.b);\n});\n\nfunction makeMutClosure(arg0, arg1, dtor, f) {\n const state = { a: arg0, b: arg1, cnt: 1, dtor };\n const real = (...args) => {\n // First up with a closure we increment the internal reference\n // count. This ensures that the Rust closure environment won't\n // be deallocated while we're invoking it.\n state.cnt++;\n const a = state.a;\n state.a = 0;\n try {\n return f(a, state.b, ...args);\n } finally {\n if (--state.cnt === 0) {\n wasm.__wbindgen_export_3.get(state.dtor)(a, state.b);\n CLOSURE_DTORS.unregister(state);\n } else {\n state.a = a;\n }\n }\n };\n real.original = state;\n CLOSURE_DTORS.register(real, state, state);\n return real;\n}\nfunction __wbg_adapter_34(arg0, arg1, arg2) {\n wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha51b8a0cd6570266(arg0, arg1, addHeapObject(arg2));\n}\n\nfunction _assertClass(instance, klass) {\n if (!(instance instanceof klass)) {\n throw new Error(`expected instance of ${klass.name}`);\n }\n return instance.ptr;\n}\n\nfunction passArray8ToWasm0(arg, malloc) {\n const ptr = malloc(arg.length * 1, 1) >>> 0;\n getUint8Memory0().set(arg, ptr / 1);\n WASM_VECTOR_LEN = arg.length;\n return ptr;\n}\n/**\n* Verify an execution with a single function and a single transition. Executions with multiple\n* transitions or functions will fail to verify. Also, this does not verify that the state root of\n* the execution is included in the Aleo Network ledger.\n*\n* @param {Execution} execution The function execution to verify\n* @param {VerifyingKey} verifying_key The verifying key for the function\n* @param {Program} program The program that the function execution belongs to\n* @param {String} function_id The name of the function that was executed\n* @returns {boolean} True if the execution is valid, false otherwise\n* @param {Execution} execution\n* @param {VerifyingKey} verifying_key\n* @param {Program} program\n* @param {string} function_id\n* @returns {boolean}\n*/\nfunction verifyFunctionExecution(execution, verifying_key, program, function_id) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(execution, Execution);\n _assertClass(verifying_key, VerifyingKey);\n _assertClass(program, Program);\n const ptr0 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyFunctionExecution(retptr, execution.__wbg_ptr, verifying_key.__wbg_ptr, program.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return r0 !== 0;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n}\n\nlet cachedBigInt64Memory0 = null;\n\nfunction getBigInt64Memory0() {\n if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.buffer !== wasm.memory.buffer) {\n cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);\n }\n return cachedBigInt64Memory0;\n}\n\nfunction getArrayU8FromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);\n}\n/**\n* @param {number} receiver\n*/\nfunction runRayonThread(receiver) {\n wasm.runRayonThread(receiver);\n}\n\n/**\n* @param {URL} url\n* @param {number} num_threads\n* @returns {Promise}\n*/\nfunction initThreadPool(url, num_threads) {\n const ret = wasm.initThreadPool(addHeapObject(url), num_threads);\n return takeObject(ret);\n}\n\nfunction handleError(f, args) {\n try {\n return f.apply(this, args);\n } catch (e) {\n wasm.__wbindgen_exn_store(addHeapObject(e));\n }\n}\nfunction __wbg_adapter_281(arg0, arg1, arg2, arg3) {\n wasm.wasm_bindgen__convert__closures__invoke2_mut__h823ad1ce2c4b384e(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));\n}\n\nconst AddressFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_address_free(ptr >>> 0));\n/**\n* Public address of an Aleo account\n*/\nclass Address {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Address.prototype);\n obj.__wbg_ptr = ptr;\n AddressFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n AddressFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_address_free(ptr);\n }\n /**\n * Derive an Aleo address from a private key\n *\n * @param {PrivateKey} private_key The private key to derive the address from\n * @returns {Address} Address corresponding to the private key\n * @param {PrivateKey} private_key\n * @returns {Address}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.address_from_private_key(private_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Derive an Aleo address from a view key\n *\n * @param {ViewKey} view_key The view key to derive the address from\n * @returns {Address} Address corresponding to the view key\n * @param {ViewKey} view_key\n * @returns {Address}\n */\n static from_view_key(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.address_from_view_key(view_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Create an aleo address object from a string representation of an address\n *\n * @param {string} address String representation of an addressm\n * @returns {Address} Address\n * @param {string} address\n * @returns {Address}\n */\n static from_string(address) {\n const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.address_from_string(ptr0, len0);\n return Address.__wrap(ret);\n }\n /**\n * Get a string representation of an Aleo address object\n *\n * @param {Address} Address\n * @returns {string} String representation of the address\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.address_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Verify a signature for a message signed by the address\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {boolean} Boolean representing whether or not the signature is valid\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n */\n verify(message, signature) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n _assertClass(signature, Signature);\n const ret = wasm.address_verify(this.__wbg_ptr, ptr0, len0, signature.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst ExecutionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_execution_free(ptr >>> 0));\n/**\n* Execution of an Aleo program.\n*/\nclass Execution {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Execution.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_execution_free(ptr);\n }\n /**\n * Returns the string representation of the execution.\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.execution_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates an execution object from a string representation of an execution.\n * @param {string} execution\n * @returns {Execution}\n */\n static fromString(execution) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(execution, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.execution_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Execution.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ExecutionResponseFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_executionresponse_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo function execution response\n*\n* This object is returned by the execution of an Aleo function off-chain. It provides methods for\n* retrieving the outputs of the function execution.\n*/\nclass ExecutionResponse {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ExecutionResponse.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionResponseFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionResponseFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_executionresponse_free(ptr);\n }\n /**\n * Get the outputs of the executed function\n *\n * @returns {Array} Array of strings representing the outputs of the function\n * @returns {Array}\n */\n getOutputs() {\n const ret = wasm.executionresponse_getOutputs(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Returns the execution object if present, null if otherwise.\n *\n * @returns {Execution | undefined} The execution object if present, null if otherwise\n * @returns {Execution | undefined}\n */\n getExecution() {\n const ret = wasm.executionresponse_getExecution(this.__wbg_ptr);\n return ret === 0 ? undefined : Execution.__wrap(ret);\n }\n /**\n * Returns the program keys if present\n * @returns {KeyPair}\n */\n getKeys() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getKeys(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return KeyPair.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the proving_key if the proving key was cached in the Execution response.\n * Note the proving key is removed from the response object after the first call to this\n * function. Subsequent calls will return null.\n *\n * @returns {ProvingKey | undefined} The proving key\n * @returns {ProvingKey | undefined}\n */\n getProvingKey() {\n const ret = wasm.executionresponse_getProvingKey(this.__wbg_ptr);\n return ret === 0 ? undefined : ProvingKey.__wrap(ret);\n }\n /**\n * Returns the verifying_key associated with the program\n *\n * @returns {VerifyingKey} The verifying key\n * @returns {VerifyingKey}\n */\n getVerifyingKey() {\n const ret = wasm.executionresponse_getVerifyingKey(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the function identifier\n * @returns {string}\n */\n getFunctionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getFunctionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the program\n * @returns {Program}\n */\n getProgram() {\n const ret = wasm.executionresponse_getProgram(this.__wbg_ptr);\n return Program.__wrap(ret);\n }\n}\n\nconst FieldFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_field_free(ptr >>> 0));\n/**\n*/\nclass Field {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Field.prototype);\n obj.__wbg_ptr = ptr;\n FieldFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n FieldFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_field_free(ptr);\n }\n /**\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.field_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} field\n * @returns {Field}\n */\n static fromString(field) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(field, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.field_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst KeyPairFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_keypair_free(ptr >>> 0));\n/**\n* Key pair object containing both the function proving and verifying keys\n*/\nclass KeyPair {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(KeyPair.prototype);\n obj.__wbg_ptr = ptr;\n KeyPairFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n KeyPairFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_keypair_free(ptr);\n }\n /**\n * Create new key pair from proving and verifying keys\n *\n * @param {ProvingKey} proving_key Proving key corresponding to a function in an Aleo program\n * @param {VerifyingKey} verifying_key Verifying key corresponding to a function in an Aleo program\n * @returns {KeyPair} Key pair object containing both the function proving and verifying keys\n * @param {ProvingKey} proving_key\n * @param {VerifyingKey} verifying_key\n */\n constructor(proving_key, verifying_key) {\n _assertClass(proving_key, ProvingKey);\n var ptr0 = proving_key.__destroy_into_raw();\n _assertClass(verifying_key, VerifyingKey);\n var ptr1 = verifying_key.__destroy_into_raw();\n const ret = wasm.keypair_new(ptr0, ptr1);\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get the proving key. This method will remove the proving key from the key pair\n *\n * @returns {ProvingKey}\n * @returns {ProvingKey}\n */\n provingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_provingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the verifying key. This method will remove the verifying key from the key pair\n *\n * @returns {VerifyingKey}\n * @returns {VerifyingKey}\n */\n verifyingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst MetadataFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_metadata_free(ptr >>> 0));\n/**\n*/\nclass Metadata {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Metadata.prototype);\n obj.__wbg_ptr = ptr;\n MetadataFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n MetadataFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_metadata_free(ptr);\n }\n /**\n * @returns {string}\n */\n get name() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_name(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set name(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_name(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get locator() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_locator(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set locator(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_locator(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get prover() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_prover(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set prover(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_prover(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifier() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifier(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifier(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifier(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifyingKey() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifyingKey(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifyingKey(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n static baseUrl() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.metadata_baseUrl(retptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @returns {Metadata}\n */\n static bond_public() {\n const ret = wasm.metadata_bond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static bond_validator() {\n const ret = wasm.metadata_bond_validator();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static claim_unbond_public() {\n const ret = wasm.metadata_claim_unbond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_private() {\n const ret = wasm.metadata_fee_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_public() {\n const ret = wasm.metadata_fee_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static inclusion() {\n const ret = wasm.metadata_inclusion();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static join() {\n const ret = wasm.metadata_join();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static set_validator_state() {\n const ret = wasm.metadata_set_validator_state();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static split() {\n const ret = wasm.metadata_split();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private() {\n const ret = wasm.metadata_transfer_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private_to_public() {\n const ret = wasm.metadata_transfer_private_to_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public() {\n const ret = wasm.metadata_transfer_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_as_signer() {\n const ret = wasm.metadata_transfer_public_as_signer();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_to_private() {\n const ret = wasm.metadata_transfer_public_to_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static unbond_public() {\n const ret = wasm.metadata_unbond_public();\n return Metadata.__wrap(ret);\n }\n}\n\nconst OfflineQueryFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_offlinequery_free(ptr >>> 0));\n/**\n* An offline query object used to insert the global state root and state paths needed to create\n* a valid inclusion proof offline.\n*/\nclass OfflineQuery {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(OfflineQuery.prototype);\n obj.__wbg_ptr = ptr;\n OfflineQueryFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n OfflineQueryFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_offlinequery_free(ptr);\n }\n /**\n * Creates a new offline query object. The state root is required to be passed in as a string\n * @param {string} state_root\n */\n constructor(state_root) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(state_root, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_new(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n this.__wbg_ptr = r0 >>> 0;\n return this;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Add a new state path to the offline query object.\n *\n * @param {string} commitment: The commitment corresponding to a record inpout\n * @param {string} state_path: The state path corresponding to the commitment\n * @param {string} commitment\n * @param {string} state_path\n */\n addStatePath(commitment, state_path) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(commitment, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(state_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.offlinequery_addStatePath(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n if (r1) {\n throw takeObject(r0);\n }\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a json string representation of the offline query object\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.offlinequery_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create an offline query object from a json string representation\n * @param {string} s\n * @returns {OfflineQuery}\n */\n static fromString(s) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(s, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return OfflineQuery.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekey_free(ptr >>> 0));\n/**\n* Private key of an Aleo account\n*/\nclass PrivateKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKey.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekey_free(ptr);\n }\n /**\n * Generate a new private key using a cryptographically secure random number generator\n *\n * @returns {PrivateKey}\n */\n constructor() {\n const ret = wasm.privatekey_new();\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get a private key from a series of unchecked bytes\n *\n * @param {Uint8Array} seed Unchecked 32 byte long Uint8Array acting as the seed for the private key\n * @returns {PrivateKey}\n * @param {Uint8Array} seed\n * @returns {PrivateKey}\n */\n static from_seed_unchecked(seed) {\n const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_from_seed_unchecked(ptr0, len0);\n return PrivateKey.__wrap(ret);\n }\n /**\n * Get a private key from a string representation of a private key\n *\n * @param {string} seed String representation of a private key\n * @returns {PrivateKey}\n * @param {string} private_key\n * @returns {PrivateKey}\n */\n static from_string(private_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(private_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_from_string(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the private key. This function should be used very carefully\n * as it exposes the private key plaintext\n *\n * @returns {string} String representation of a private key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the view key corresponding to the private key\n *\n * @returns {ViewKey}\n * @returns {ViewKey}\n */\n to_view_key() {\n const ret = wasm.privatekey_to_view_key(this.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get the address corresponding to the private key\n *\n * @returns {Address}\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.privatekey_to_address(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Sign a message with the private key\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {Signature} Signature generated by signing the message with the address\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n sign(message) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(this.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a new randomly generated private key ciphertext using a secret. The secret is sensitive\n * and will be needed to decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static newEncrypted(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_newEncrypted(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Encrypt an existing private key with a secret. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n toCiphertext(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get private key from a private key ciphertext and secret originally used to encrypt it\n *\n * @param {PrivateKeyCiphertext} ciphertext Ciphertext representation of the private key\n * @param {string} secret Secret originally used to encrypt the private key\n * @returns {PrivateKey} Private key\n * @param {PrivateKeyCiphertext} ciphertext\n * @param {string} secret\n * @returns {PrivateKey}\n */\n static fromPrivateKeyCiphertext(ciphertext, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(ciphertext, PrivateKeyCiphertext);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_fromPrivateKeyCiphertext(retptr, ciphertext.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekeyciphertext_free(ptr >>> 0));\n/**\n* Private Key in ciphertext form\n*/\nclass PrivateKeyCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKeyCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekeyciphertext_free(ptr);\n }\n /**\n * Encrypt a private key using a secret string. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {PrivateKey} private_key Private key to encrypt\n * @param {string} secret Secret to encrypt the private key with\n * @returns {PrivateKeyCiphertext} Private key ciphertext\n * @param {PrivateKey} private_key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static encryptPrivateKey(private_key, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, private_key.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Decrypts a private ciphertext using a secret string. This must be the same secret used to\n * encrypt the private key\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKey} Private key\n * @param {string} secret\n * @returns {PrivateKey}\n */\n decryptToPrivateKey(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_decryptToPrivateKey(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the ciphertext string\n *\n * @returns {string} Ciphertext string\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekeyciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates a PrivateKeyCiphertext from a string\n *\n * @param {string} ciphertext Ciphertext string\n * @returns {PrivateKeyCiphertext} Private key ciphertext\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n */\n static fromString(ciphertext) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ProgramFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_program_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo program\n*/\nclass Program {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Program.prototype);\n obj.__wbg_ptr = ptr;\n ProgramFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_program_free(ptr);\n }\n /**\n * Create a program from a program string\n *\n * @param {string} program Aleo program source code\n * @returns {Program} Program object\n * @param {string} program\n * @returns {Program}\n */\n static fromString(program) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Program.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the program\n *\n * @returns {string} String containing the program source code\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Determine if a function is present in the program\n *\n * @param {string} functionName Name of the function to check for\n * @returns {boolean} True if the program is valid, false otherwise\n * @param {string} function_name\n * @returns {boolean}\n */\n hasFunction(function_name) {\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.program_hasFunction(this.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get javascript array of functions names in the program\n *\n * @returns {Array} Array of all function names present in the program\n *\n * @example\n * const expected_functions = [\n * \"mint\",\n * \"transfer_private\",\n * \"transfer_private_to_public\",\n * \"transfer_public\",\n * \"transfer_public_to_private\",\n * \"join\",\n * \"split\",\n * \"fee\"\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_functions = credits_program.getFunctions();\n * console.log(credits_functions === expected_functions); // Output should be \"true\"\n * @returns {Array}\n */\n getFunctions() {\n const ret = wasm.program_getFunctions(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Get a javascript object representation of the function inputs and types. This can be used\n * to generate a web form to capture user inputs for an execution of a function.\n *\n * @param {string} function_name Name of the function to get inputs for\n * @returns {Array} Array of function inputs\n *\n * @example\n * const expected_inputs = [\n * {\n * type:\"record\",\n * visibility:\"private\",\n * record:\"credits\",\n * members:[\n * {\n * name:\"microcredits\",\n * type:\"u64\",\n * visibility:\"private\"\n * }\n * ],\n * register:\"r0\"\n * },\n * {\n * type:\"address\",\n * visibility:\"private\",\n * register:\"r1\"\n * },\n * {\n * type:\"u64\",\n * visibility:\"private\",\n * register:\"r2\"\n * }\n * ];\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const transfer_function_inputs = credits_program.getFunctionInputs(\"transfer_private\");\n * console.log(transfer_function_inputs === expected_inputs); // Output should be \"true\"\n * @param {string} function_name\n * @returns {Array}\n */\n getFunctionInputs(function_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getFunctionInputs(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a the list of a program's mappings and the names/types of their keys and values.\n *\n * @returns {Array} - An array of objects representing the mappings in the program\n * @example\n * const expected_mappings = [\n * {\n * name: \"account\",\n * key_name: \"owner\",\n * key_type: \"address\",\n * value_name: \"microcredits\",\n * value_type: \"u64\"\n * }\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_mappings = credits_program.getMappings();\n * console.log(credits_mappings === expected_mappings); // Output should be \"true\"\n * @returns {Array}\n */\n getMappings() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_getMappings(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program record and its types\n *\n * @param {string} record_name Name of the record to get members for\n * @returns {Object} Object containing the record name, type, and members\n *\n * @example\n *\n * const expected_record = {\n * type: \"record\",\n * record: \"Credits\",\n * members: [\n * {\n * name: \"owner\",\n * type: \"address\",\n * visibility: \"private\"\n * },\n * {\n * name: \"microcredits\",\n * type: \"u64\",\n * visibility: \"private\"\n * }\n * ];\n * };\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_record = credits_program.getRecordMembers(\"Credits\");\n * console.log(credits_record === expected_record); // Output should be \"true\"\n * @param {string} record_name\n * @returns {object}\n */\n getRecordMembers(record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getRecordMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program struct and its types\n *\n * @param {string} struct_name Name of the struct to get members for\n * @returns {Array} Array containing the struct members\n *\n * @example\n *\n * const STRUCT_PROGRAM = \"program token_issue.aleo;\n *\n * struct token_metadata:\n * network as u32;\n * version as u32;\n *\n * struct token:\n * token_id as u32;\n * metadata as token_metadata;\n *\n * function no_op:\n * input r0 as u64;\n * output r0 as u64;\"\n *\n * const expected_struct_members = [\n * {\n * name: \"token_id\",\n * type: \"u32\",\n * },\n * {\n * name: \"metadata\",\n * type: \"struct\",\n * struct_id: \"token_metadata\",\n * members: [\n * {\n * name: \"network\",\n * type: \"u32\",\n * }\n * {\n * name: \"version\",\n * type: \"u32\",\n * }\n * ]\n * }\n * ];\n *\n * const program = aleo_wasm.Program.fromString(STRUCT_PROGRAM);\n * const struct_members = program.getStructMembers(\"token\");\n * console.log(struct_members === expected_struct_members); // Output should be \"true\"\n * @param {string} struct_name\n * @returns {Array}\n */\n getStructMembers(struct_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(struct_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getStructMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the credits.aleo program\n *\n * @returns {Program} The credits.aleo program\n * @returns {Program}\n */\n static getCreditsProgram() {\n const ret = wasm.program_getCreditsProgram();\n return Program.__wrap(ret);\n }\n /**\n * Get the id of the program\n *\n * @returns {string} The id of the program\n * @returns {string}\n */\n id() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_id(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get a unique address of the program\n *\n * @returns {Address} The address of the program\n * @returns {Address}\n */\n address() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_address(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Address.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determine equality with another program\n *\n * @param {Program} other The other program to compare\n * @returns {boolean} True if the programs are equal, false otherwise\n * @param {Program} other\n * @returns {boolean}\n */\n isEqual(other) {\n _assertClass(other, Program);\n const ret = wasm.program_isEqual(this.__wbg_ptr, other.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get program_imports\n *\n * @returns {Array} The program imports\n *\n * @example\n *\n * const DOUBLE_TEST = \"import multiply_test.aleo;\n *\n * program double_test.aleo;\n *\n * function double_it:\n * input r0 as u32.private;\n * call multiply_test.aleo/multiply 2u32 r0 into r1;\n * output r1 as u32.private;\";\n *\n * const expected_imports = [\n * \"multiply_test.aleo\"\n * ];\n *\n * const program = aleo_wasm.Program.fromString(DOUBLE_TEST_PROGRAM);\n * const imports = program.getImports();\n * console.log(imports === expected_imports); // Output should be \"true\"\n * @returns {Array}\n */\n getImports() {\n const ret = wasm.program_getImports(this.__wbg_ptr);\n return takeObject(ret);\n }\n}\n\nconst ProgramManagerFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_programmanager_free(ptr >>> 0));\n/**\n*/\nclass ProgramManager {\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramManagerFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_programmanager_free(ptr);\n }\n /**\n * Deploy an Aleo program\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being deployed\n * @param imports A javascript object holding the source code of any imported programs in the\n * form \\{\"program_name1\": \"program_source_code\", \"program_name2\": \"program_source_code\", ..\\}.\n * Note that all imported programs must be deployed on chain before the main program in order\n * for the deployment to succeed\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the program deployment in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildDeploymentTransaction(private_key, program, fee_credits, fee_record, url, imports, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n let ptr1 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr1 = fee_record.__destroy_into_raw();\n }\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr3 = fee_proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr4 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildDeploymentTransaction(private_key.__wbg_ptr, ptr0, len0, fee_credits, ptr1, ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the fee for a program deployment\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The source code of the program being deployed\n * @param imports (optional) Provide a list of imports to use for the deployment fee estimation\n * in the form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @returns {u64}\n * @param {string} program\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static estimateDeploymentFee(program, imports) {\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_estimateDeploymentFee(ptr0, len0, isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n /**\n * Estimate the component of the deployment cost which comes from the fee for the program name.\n * Note that this cost does not represent the entire cost of deployment. It is additional to\n * the cost of the size (in bytes) of the deployment.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param name The name of the program to be deployed\n * @returns {u64}\n * @param {string} name\n * @returns {bigint}\n */\n static estimateProgramNameCost(name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateProgramNameCost(retptr, ptr0, len0);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Execute an arbitrary function locally\n *\n * @param {PrivateKey} private_key The private key of the sender\n * @param {string} program The source code of the program being executed\n * @param {string} function The name of the function to execute\n * @param {Array} inputs A javascript array of inputs to the function\n * @param {boolean} prove_execution If true, the execution will be proven and an execution object\n * containing the proof and the encrypted inputs and outputs needed to verify the proof offline\n * will be returned.\n * @param {boolean} cache Cache the proving and verifying keys in the Execution response.\n * If this is set to 'true' the keys synthesized will be stored in the Execution Response\n * and the `ProvingKey` and `VerifyingKey` can be retrieved from the response via the `.getKeys()`\n * method.\n * @param {Object | undefined} imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param {ProvingKey | undefined} proving_key (optional) Provide a verifying key to use for the function execution\n * @param {VerifyingKey | undefined} verifying_key (optional) Provide a verifying key to use for the function execution\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {boolean} prove_execution\n * @param {boolean} cache\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {string | undefined} [url]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static executeFunctionOffline(private_key, program, _function, inputs, prove_execution, cache, imports, proving_key, verifying_key, url, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr2 = proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr3 = verifying_key.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_executeFunctionOffline(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), prove_execution, cache, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr2, ptr3, ptr4, len4, ptr5);\n return takeObject(ret);\n }\n /**\n * Execute Aleo function and create an Aleo execution transaction\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being executed\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * If this is set to 'true' the keys synthesized (or passed in as optional parameters via the\n * `proving_key` and `verifying_key` arguments) will be stored in the ProgramManager's memory\n * and used for subsequent transactions. If this is set to 'false' the proving and verifying\n * keys will be deallocated from memory after the transaction is executed.\n * @param imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the function execution\n * @param verifying_key (optional) Provide a verifying key to use for the function execution\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildExecutionTransaction(private_key, program, _function, inputs, fee_credits, fee_record, url, imports, proving_key, verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr4 = proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr5 = verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildExecutionTransaction(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), fee_credits, ptr2, ptr3, len3, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Estimate Fee for Aleo function execution. Note if \"cache\" is set to true, the proving and\n * verifying keys will be stored in the ProgramManager's memory and used for subsequent\n * program executions.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program to estimate the execution fee for\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the fee estimation in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the fee estimation\n * @param verifying_key (optional) Provide a verifying key to use for the fee estimation\n * @returns {u64} Fee in microcredits\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static estimateExecutionFee(private_key, program, _function, inputs, url, imports, proving_key, verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr3 = proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr4 = verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_estimateExecutionFee(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the finalize fee component for executing a function. This fee is additional to the\n * size of the execution of the program in bytes. If the function does not have a finalize\n * step, then the finalize fee is 0.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The program containing the function to estimate the finalize fee for\n * @param function The function to estimate the finalize fee for\n * @returns {u64} Fee in microcredits\n * @param {string} program\n * @param {string} _function\n * @returns {bigint}\n */\n static estimateFinalizeFee(program, _function) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateFinalizeFee(retptr, ptr0, len0, ptr1, len1);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Join two records together to create a new record with an amount of credits equal to the sum\n * of the credits of the two original records\n *\n * @param private_key The private key of the sender\n * @param record_1 The first record to combine\n * @param record_2 The second record to combine\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param join_proving_key (optional) Provide a proving key to use for the join function\n * @param join_verifying_key (optional) Provide a verifying key to use for the join function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction} Transaction object\n * @param {PrivateKey} private_key\n * @param {RecordPlaintext} record_1\n * @param {RecordPlaintext} record_2\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [join_proving_key]\n * @param {VerifyingKey | undefined} [join_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildJoinTransaction(private_key, record_1, record_2, fee_credits, fee_record, url, join_proving_key, join_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(record_1, RecordPlaintext);\n var ptr0 = record_1.__destroy_into_raw();\n _assertClass(record_2, RecordPlaintext);\n var ptr1 = record_2.__destroy_into_raw();\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(join_proving_key)) {\n _assertClass(join_proving_key, ProvingKey);\n ptr4 = join_proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(join_verifying_key)) {\n _assertClass(join_verifying_key, VerifyingKey);\n ptr5 = join_verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildJoinTransaction(private_key.__wbg_ptr, ptr0, ptr1, fee_credits, ptr2, ptr3, len3, ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Split an Aleo credits record into two separate records. This function does not require a fee.\n *\n * @param private_key The private key of the sender\n * @param split_amount The amount of the credit split. This amount will be subtracted from the\n * value of the record and two new records will be created with the split amount and the remainder\n * @param amount_record The record to split\n * @param url The url of the Aleo network node to send the transaction to\n * @param split_proving_key (optional) Provide a proving key to use for the split function\n * @param split_verifying_key (optional) Provide a verifying key to use for the split function\n * @returns {Transaction} Transaction object\n * @param {PrivateKey} private_key\n * @param {number} split_amount\n * @param {RecordPlaintext} amount_record\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [split_proving_key]\n * @param {VerifyingKey | undefined} [split_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildSplitTransaction(private_key, split_amount, amount_record, url, split_proving_key, split_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(amount_record, RecordPlaintext);\n var ptr0 = amount_record.__destroy_into_raw();\n var ptr1 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(split_proving_key)) {\n _assertClass(split_proving_key, ProvingKey);\n ptr2 = split_proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(split_verifying_key)) {\n _assertClass(split_verifying_key, VerifyingKey);\n ptr3 = split_verifying_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr4 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildSplitTransaction(private_key.__wbg_ptr, split_amount, ptr0, ptr1, len1, ptr2, ptr3, ptr4);\n return takeObject(ret);\n }\n /**\n * Send credits from one Aleo account to another\n *\n * @param private_key The private key of the sender\n * @param amount_credits The amount of credits to send\n * @param recipient The recipient of the transaction\n * @param transfer_type The type of the transfer (options: \"private\", \"public\", \"private_to_public\", \"public_to_private\")\n * @param amount_record The record to fund the amount from\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param transfer_verifying_key (optional) Provide a verifying key to use for the transfer\n * function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {number} amount_credits\n * @param {string} recipient\n * @param {string} transfer_type\n * @param {RecordPlaintext | undefined} amount_record\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [transfer_proving_key]\n * @param {VerifyingKey | undefined} [transfer_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildTransferTransaction(private_key, amount_credits, recipient, transfer_type, amount_record, fee_credits, fee_record, url, transfer_proving_key, transfer_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(recipient, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(transfer_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(amount_record)) {\n _assertClass(amount_record, RecordPlaintext);\n ptr2 = amount_record.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr3 = fee_record.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(transfer_proving_key)) {\n _assertClass(transfer_proving_key, ProvingKey);\n ptr5 = transfer_proving_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(transfer_verifying_key)) {\n _assertClass(transfer_verifying_key, VerifyingKey);\n ptr6 = transfer_verifying_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr7 = fee_proving_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr8 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr9 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr9 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildTransferTransaction(private_key.__wbg_ptr, amount_credits, ptr0, len0, ptr1, len1, ptr2, fee_credits, ptr3, ptr4, len4, ptr5, ptr6, ptr7, ptr8, ptr9);\n return takeObject(ret);\n }\n /**\n * Synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code of the program to synthesize keys for\n * @param function_id {string} The function to synthesize keys for\n * @param inputs {Array} The inputs to the function\n * @param imports {Object | undefined} The imports for the program\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} function_id\n * @param {Array} inputs\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static synthesizeKeyPair(private_key, program, function_id, inputs, imports) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_synthesizeKeyPair(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n}\n\nconst ProvingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_provingkey_free(ptr >>> 0));\n/**\n* Proving key for a function within an Aleo program\n*/\nclass ProvingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ProvingKey.prototype);\n obj.__wbg_ptr = ptr;\n ProvingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProvingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_provingkey_free(ptr);\n }\n /**\n * Verify if the proving key is for the bond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_public_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_public function, false if otherwise\n * @returns {boolean}\n */\n isBondPublicProver() {\n const ret = wasm.provingkey_isBondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the bond_validator function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_validator_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_validator function, false if otherwise\n * @returns {boolean}\n */\n isBondValidatorProver() {\n const ret = wasm.provingkey_isBondValidatorProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the claim_unbond function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"claim_unbond_proving_key.bin\");\n * provingKey.isClaimUnbondProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the claim_unbond function, false if otherwise\n * @returns {boolean}\n */\n isClaimUnbondPublicProver() {\n const ret = wasm.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_private_proving_key.bin\");\n * provingKey.isFeePrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_private function, false if otherwise\n * @returns {boolean}\n */\n isFeePrivateProver() {\n const ret = wasm.provingkey_isFeePrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_public_proving_key.bin\");\n * provingKey.isFeePublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_public function, false if otherwise\n * @returns {boolean}\n */\n isFeePublicProver() {\n const ret = wasm.provingkey_isFeePublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the inclusion function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"inclusion_proving_key.bin\");\n * provingKey.isInclusionProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the inclusion function, false if otherwise\n * @returns {boolean}\n */\n isInclusionProver() {\n const ret = wasm.provingkey_isInclusionProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the join function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"join_proving_key.bin\");\n * provingKey.isJoinProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the join function, false if otherwise\n * @returns {boolean}\n */\n isJoinProver() {\n const ret = wasm.provingkey_isJoinProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the set_validator_state function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"set_validator_set_proving_key.bin\");\n * provingKey.isSetValidatorStateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the set_validator_state function, false if otherwise\n * @returns {boolean}\n */\n isSetValidatorStateProver() {\n const ret = wasm.provingkey_isSetValidatorStateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the split function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"split_proving_key.bin\");\n * provingKey.isSplitProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the split function, false if otherwise\n * @returns {boolean}\n */\n isSplitProver() {\n const ret = wasm.provingkey_isSplitProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_proving_key.bin\");\n * provingKey.isTransferPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateProver() {\n const ret = wasm.provingkey_isTransferPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private_to_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_to_public_proving_key.bin\");\n * provingKey.isTransferPrivateToPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private_to_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateToPublicProver() {\n const ret = wasm.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_proving_key.bin\");\n * provingKey.isTransferPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicProver() {\n const ret = wasm.provingkey_isTransferPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_as_signer function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_as_signer_proving_key.bin\");\n * provingKey.isTransferPublicAsSignerProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicAsSignerProver() {\n const ret = wasm.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_to_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_to_private_proving_key.bin\");\n * provingKey.isTransferPublicToPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public_to_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicToPrivateProver() {\n const ret = wasm.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the unbond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"unbond_public.bin\");\n * provingKey.isUnbondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the unbond_public_prover function, false if otherwise\n * @returns {boolean}\n */\n isUnbondPublicProver() {\n const ret = wasm.provingkey_isUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Return the checksum of the proving key\n *\n * @returns {string} Checksum of the proving key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the proving key\n *\n * @returns {ProvingKey} A copy of the proving key\n * @returns {ProvingKey}\n */\n copy() {\n const ret = wasm.provingkey_copy(this.__wbg_ptr);\n return ProvingKey.__wrap(ret);\n }\n /**\n * Construct a new proving key from a byte array\n *\n * @param {Uint8Array} bytes Byte array representation of a proving key\n * @returns {ProvingKey}\n * @param {Uint8Array} bytes\n * @returns {ProvingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a proving key from string\n *\n * @param {string} String representation of the proving key\n * @param {string} string\n * @returns {ProvingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the byte representation of a proving key\n *\n * @returns {Uint8Array} Byte array representation of a proving key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the proving key\n *\n * @returns {string} String representation of the proving key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst RecordCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordciphertext_free(ptr >>> 0));\n/**\n* Encrypted Aleo record\n*/\nclass RecordCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n RecordCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordciphertext_free(ptr);\n }\n /**\n * Create a record ciphertext from a string\n *\n * @param {string} record String representation of a record ciphertext\n * @returns {RecordCiphertext} Record ciphertext\n * @param {string} record\n * @returns {RecordCiphertext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the string reprensentation of the record ciphertext\n *\n * @returns {string} String representation of the record ciphertext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Decrypt the record ciphertext into plaintext using the view key. The record will only\n * decrypt if the record was encrypted by the account corresponding to the view key\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {RecordPlaintext} Record plaintext object\n * @param {ViewKey} view_key\n * @returns {RecordPlaintext}\n */\n decrypt(view_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(view_key, ViewKey);\n wasm.recordciphertext_decrypt(retptr, this.__wbg_ptr, view_key.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determines if the account corresponding to the view key is the owner of the record\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {boolean}\n * @param {ViewKey} view_key\n * @returns {boolean}\n */\n isOwner(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.recordciphertext_isOwner(this.__wbg_ptr, view_key.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst RecordPlaintextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordplaintext_free(ptr >>> 0));\n/**\n* Plaintext representation of an Aleo record\n*/\nclass RecordPlaintext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordPlaintext.prototype);\n obj.__wbg_ptr = ptr;\n RecordPlaintextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordPlaintextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordplaintext_free(ptr);\n }\n /**\n * @param {string} program_id\n * @param {string} record_name\n * @returns {Field}\n */\n commitment(program_id, record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_commitment(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return a record plaintext from a string.\n *\n * @param {string} record String representation of a plaintext representation of an Aleo record\n * @returns {RecordPlaintext} Record plaintext\n * @param {string} record\n * @returns {RecordPlaintext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordplaintext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the record plaintext string\n *\n * @returns {string} String representation of the record plaintext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the amount of microcredits in the record\n *\n * @returns {u64} Amount of microcredits in the record\n * @returns {bigint}\n */\n microcredits() {\n const ret = wasm.recordplaintext_microcredits(this.__wbg_ptr);\n return BigInt.asUintN(64, ret);\n }\n /**\n * Returns the nonce of the record. This can be used to uniquely identify a record.\n *\n * @returns {string} Nonce of the record\n * @returns {string}\n */\n nonce() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_nonce(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Attempt to get the serial number of a record to determine whether or not is has been spent\n *\n * @param {PrivateKey} private_key Private key of the account that owns the record\n * @param {string} program_id Program ID of the program that the record is associated with\n * @param {string} record_name Name of the record\n * @returns {string} Serial number of the record\n * @param {PrivateKey} private_key\n * @param {string} program_id\n * @param {string} record_name\n * @returns {string}\n */\n serialNumberString(private_key, program_id, record_name) {\n let deferred4_0;\n let deferred4_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_serialNumberString(retptr, this.__wbg_ptr, private_key.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr3 = r0;\n var len3 = r1;\n if (r3) {\n ptr3 = 0; len3 = 0;\n throw takeObject(r2);\n }\n deferred4_0 = ptr3;\n deferred4_1 = len3;\n return getStringFromWasm0(ptr3, len3);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred4_0, deferred4_1, 1);\n }\n }\n}\n\nconst SignatureFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_signature_free(ptr >>> 0));\n/**\n* Cryptographic signature of a message signed by an Aleo account\n*/\nclass Signature {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Signature.prototype);\n obj.__wbg_ptr = ptr;\n SignatureFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n SignatureFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_signature_free(ptr);\n }\n /**\n * Sign a message with a private key\n *\n * @param {PrivateKey} private_key The private key to sign the message with\n * @param {Uint8Array} message Byte representation of the message to sign\n * @returns {Signature} Signature of the message\n * @param {PrivateKey} private_key\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n static sign(private_key, message) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(private_key.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Verify a signature of a message with an address\n *\n * @param {Address} address The address to verify the signature with\n * @param {Uint8Array} message Byte representation of the message to verify\n * @returns {boolean} True if the signature is valid, false otherwise\n * @param {Address} address\n * @param {Uint8Array} message\n * @returns {boolean}\n */\n verify(address, message) {\n _assertClass(address, Address);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_verify(this.__wbg_ptr, address.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get a signature from a string representation of a signature\n *\n * @param {string} signature String representation of a signature\n * @returns {Signature} Signature\n * @param {string} signature\n * @returns {Signature}\n */\n static from_string(signature) {\n const ptr0 = passStringToWasm0(signature, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_from_string(ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a string representation of a signature\n *\n * @returns {string} String representation of a signature\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.signature_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst TransactionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_transaction_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo transaction\n*\n* This object is created when generating an on-chain function deployment or execution and is the\n* object that should be submitted to the Aleo Network in order to deploy or execute a function.\n*/\nclass Transaction {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Transaction.prototype);\n obj.__wbg_ptr = ptr;\n TransactionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n TransactionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_transaction_free(ptr);\n }\n /**\n * Create a transaction from a string\n *\n * @param {string} transaction String representation of a transaction\n * @returns {Transaction}\n * @param {string} transaction\n * @returns {Transaction}\n */\n static fromString(transaction) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(transaction, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.transaction_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Transaction.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the transaction as a string. If you want to submit this transaction to the Aleo Network\n * this function will create the string that should be submitted in the `POST` data.\n *\n * @returns {string} String representation of the transaction\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the id of the transaction. This is the merkle root of the transaction's inclusion proof.\n *\n * This value can be used to query the status of the transaction on the Aleo Network to see\n * if it was successful. If successful, the transaction will be included in a block and this\n * value can be used to lookup the transaction data on-chain.\n *\n * @returns {string} Transaction id\n * @returns {string}\n */\n transactionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the type of the transaction (will return \"deploy\" or \"execute\")\n *\n * @returns {string} Transaction type\n * @returns {string}\n */\n transactionType() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionType(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst VerifyingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_verifyingkey_free(ptr >>> 0));\n/**\n* Verifying key for a function within an Aleo program\n*/\nclass VerifyingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(VerifyingKey.prototype);\n obj.__wbg_ptr = ptr;\n VerifyingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n VerifyingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_verifyingkey_free(ptr);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {VerifyingKey}\n */\n static bondPublicVerifier() {\n const ret = wasm.verifyingkey_bondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {VerifyingKey}\n */\n static bondValidatorVerifier() {\n const ret = wasm.verifyingkey_bondValidatorVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the claim_delegator function\n *\n * @returns {VerifyingKey} Verifying key for the claim_unbond_public function\n * @returns {VerifyingKey}\n */\n static claimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_claimUnbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_private function\n *\n * @returns {VerifyingKey} Verifying key for the fee_private function\n * @returns {VerifyingKey}\n */\n static feePrivateVerifier() {\n const ret = wasm.verifyingkey_feePrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_public function\n *\n * @returns {VerifyingKey} Verifying key for the fee_public function\n * @returns {VerifyingKey}\n */\n static feePublicVerifier() {\n const ret = wasm.verifyingkey_feePublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the inclusion function\n *\n * @returns {VerifyingKey} Verifying key for the inclusion function\n * @returns {VerifyingKey}\n */\n static inclusionVerifier() {\n const ret = wasm.verifyingkey_inclusionVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the join function\n *\n * @returns {VerifyingKey} Verifying key for the join function\n * @returns {VerifyingKey}\n */\n static joinVerifier() {\n const ret = wasm.verifyingkey_joinVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the set_validator_state function\n *\n * @returns {VerifyingKey} Verifying key for the set_validator_state function\n * @returns {VerifyingKey}\n */\n static setValidatorStateVerifier() {\n const ret = wasm.verifyingkey_setValidatorStateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the split function\n *\n * @returns {VerifyingKey} Verifying key for the split function\n * @returns {VerifyingKey}\n */\n static splitVerifier() {\n const ret = wasm.verifyingkey_splitVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private function\n * @returns {VerifyingKey}\n */\n static transferPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private_to_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private_to_public function\n * @returns {VerifyingKey}\n */\n static transferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_transferPrivateToPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public function\n * @returns {VerifyingKey}\n */\n static transferPublicVerifier() {\n const ret = wasm.verifyingkey_transferPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_as_signer function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_as_signer function\n * @returns {VerifyingKey}\n */\n static transferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_transferPublicAsSignerVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_to_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_to_private function\n * @returns {VerifyingKey}\n */\n static transferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPublicToPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the unbond_public function\n *\n * @returns {VerifyingKey} Verifying key for the unbond_public function\n * @returns {VerifyingKey}\n */\n static unbondPublicVerifier() {\n const ret = wasm.verifyingkey_unbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {boolean}\n */\n isBondPublicVerifier() {\n const ret = wasm.verifyingkey_isBondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {boolean}\n */\n isBondValidatorVerifier() {\n const ret = wasm.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the claim_delegator function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isClaimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePrivateVerifier() {\n const ret = wasm.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePublicVerifier() {\n const ret = wasm.verifyingkey_isFeePublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the inclusion function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isInclusionVerifier() {\n const ret = wasm.verifyingkey_isInclusionVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the join function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isJoinVerifier() {\n const ret = wasm.verifyingkey_isJoinVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the set_validator_state function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSetValidatorStateVerifier() {\n const ret = wasm.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the split function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSplitVerifier() {\n const ret = wasm.verifyingkey_isSplitVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private_to_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_as_signer function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_to_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the unbond_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get the checksum of the verifying key\n *\n * @returns {string} Checksum of the verifying key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the verifying key\n *\n * @returns {VerifyingKey} A copy of the verifying key\n * @returns {VerifyingKey}\n */\n copy() {\n const ret = wasm.verifyingkey_copy(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Construct a new verifying key from a byte array\n *\n * @param {Uint8Array} bytes Byte representation of a verifying key\n * @returns {VerifyingKey}\n * @param {Uint8Array} bytes\n * @returns {VerifyingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a verifying key from string\n *\n * @param {String} string String representation of a verifying key\n * @returns {VerifyingKey}\n * @param {string} string\n * @returns {VerifyingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a byte array from a verifying key\n *\n * @returns {Uint8Array} Byte representation of a verifying key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the verifying key\n *\n * @returns {String} String representation of the verifying key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst ViewKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_viewkey_free(ptr >>> 0));\n/**\n*/\nclass ViewKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ViewKey.prototype);\n obj.__wbg_ptr = ptr;\n ViewKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ViewKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_viewkey_free(ptr);\n }\n /**\n * Create a new view key from a private key\n *\n * @param {PrivateKey} private_key Private key\n * @returns {ViewKey} View key\n * @param {PrivateKey} private_key\n * @returns {ViewKey}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.privatekey_to_view_key(private_key.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Create a new view key from a string representation of a view key\n *\n * @param {string} view_key String representation of a view key\n * @returns {ViewKey} View key\n * @param {string} view_key\n * @returns {ViewKey}\n */\n static from_string(view_key) {\n const ptr0 = passStringToWasm0(view_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.viewkey_from_string(ptr0, len0);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get a string representation of a view key\n *\n * @returns {string} String representation of a view key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.viewkey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the address corresponding to a view key\n *\n * @returns {Address} Address\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.address_from_view_key(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Decrypt a record ciphertext with a view key\n *\n * @param {string} ciphertext String representation of a record ciphertext\n * @returns {string} String representation of a record plaintext\n * @param {string} ciphertext\n * @returns {string}\n */\n decrypt(ciphertext) {\n let deferred3_0;\n let deferred3_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.viewkey_decrypt(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr2 = r0;\n var len2 = r1;\n if (r3) {\n ptr2 = 0; len2 = 0;\n throw takeObject(r2);\n }\n deferred3_0 = ptr2;\n deferred3_1 = len2;\n return getStringFromWasm0(ptr2, len2);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);\n }\n }\n}\n\nasync function __wbg_load(module, imports) {\n if (typeof Response === 'function' && module instanceof Response) {\n if (typeof WebAssembly.instantiateStreaming === 'function') {\n try {\n return await WebAssembly.instantiateStreaming(module, imports);\n\n } catch (e) {\n if (module.headers.get('Content-Type') != 'application/wasm') {\n console.warn(\"`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n\", e);\n\n } else {\n throw e;\n }\n }\n }\n\n const bytes = await module.arrayBuffer();\n return await WebAssembly.instantiate(bytes, imports);\n\n } else {\n const instance = await WebAssembly.instantiate(module, imports);\n\n if (instance instanceof WebAssembly.Instance) {\n return { instance, module };\n\n } else {\n return instance;\n }\n }\n}\n\nfunction __wbg_get_imports() {\n const imports = {};\n imports.wbg = {};\n imports.wbg.__wbindgen_object_drop_ref = function(arg0) {\n takeObject(arg0);\n };\n imports.wbg.__wbg_new_71801a555ad9f2aa = function() { return handleError(function () {\n const ret = new XMLHttpRequest();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_overrideMimeType_ee9c51919ceb418b = function() { return handleError(function (arg0, arg1, arg2) {\n getObject(arg0).overrideMimeType(getStringFromWasm0(arg1, arg2));\n }, arguments) };\n imports.wbg.__wbg_open_c9eb0cf2c9d95679 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {\n getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), arg5 !== 0);\n }, arguments) };\n imports.wbg.__wbg_send_80d29985093c1ec5 = function() { return handleError(function (arg0) {\n getObject(arg0).send();\n }, arguments) };\n imports.wbg.__wbg_response_7c2e2759084f7279 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).response;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_status_d485fb5a478426fb = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).status;\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_72fb9a18b5ae2624 = function() {\n const ret = new Object();\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_string_new = function(arg0, arg1) {\n const ret = getStringFromWasm0(arg0, arg1);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_1f9b04f170055d33 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_ab6fd82b10560829 = function() { return handleError(function () {\n const ret = new Headers();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_object_clone_ref = function(arg0) {\n const ret = getObject(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_0d76b0581eca6298 = function() { return handleError(function () {\n const ret = new AbortController();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_signal_a61f78a3478fd9bc = function(arg0) {\n const ret = getObject(arg0).signal;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_append_7bfcb4937d1d5e29 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {\n getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));\n }, arguments) };\n imports.wbg.__wbg_instanceof_Response_849eb93e75734b6e = function(arg0) {\n let result;\n try {\n result = getObject(arg0) instanceof Response;\n } catch (_) {\n result = false;\n }\n const ret = result;\n return ret;\n };\n imports.wbg.__wbg_status_61a01141acd3cf74 = function(arg0) {\n const ret = getObject(arg0).status;\n return ret;\n };\n imports.wbg.__wbg_url_5f6dc4009ac5f99d = function(arg0, arg1) {\n const ret = getObject(arg1).url;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_headers_9620bfada380764a = function(arg0) {\n const ret = getObject(arg0).headers;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_iterator_2cee6dadfd956dfa = function() {\n const ret = Symbol.iterator;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_get_e3c254076557e348 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.get(getObject(arg0), getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_function = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'function';\n return ret;\n };\n imports.wbg.__wbg_call_27c0f87801dedf93 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg0).call(getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_object = function(arg0) {\n const val = getObject(arg0);\n const ret = typeof(val) === 'object' && val !== null;\n return ret;\n };\n imports.wbg.__wbg_next_40fc327bfc8770e6 = function(arg0) {\n const ret = getObject(arg0).next;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_next_196c84450b364254 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).next();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_done_298b57d23c0fc80c = function(arg0) {\n const ret = getObject(arg0).done;\n return ret;\n };\n imports.wbg.__wbg_value_d93c65011f51a456 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_abort_2aa7521d5690750e = function(arg0) {\n getObject(arg0).abort();\n };\n imports.wbg.__wbg_stringify_8887fe74e1c50d81 = function() { return handleError(function (arg0) {\n const ret = JSON.stringify(getObject(arg0));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_string_get = function(arg0, arg1) {\n const obj = getObject(arg1);\n const ret = typeof(obj) === 'string' ? obj : undefined;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_log_0159ca40cddf5b15 = function(arg0, arg1) {\n console.log(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {\n const ret = BigInt.asUintN(64, arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_call_b3ca7c6051f9bec1 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_module = function() {\n const ret = __wbg_init.__wbindgen_wasm_module;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_memory = function() {\n const ret = wasm.memory;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a = function(arg0, arg1, arg2, arg3) {\n const ret = spawnWorker(getObject(arg0), getObject(arg1), getObject(arg2), arg3 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_executionresponse_new = function(arg0) {\n const ret = ExecutionResponse.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_keypair_new = function(arg0) {\n const ret = KeyPair.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_transaction_new = function(arg0) {\n const ret = Transaction.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_66ae46612e7f0234 = function(arg0) {\n const ret = new Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_d4638f722068f043 = function(arg0, arg1, arg2) {\n getObject(arg0)[arg1 >>> 0] = takeObject(arg2);\n };\n imports.wbg.__wbindgen_cb_drop = function(arg0) {\n const obj = takeObject(arg0).original;\n if (obj.cnt-- == 1) {\n obj.a = 0;\n return true;\n }\n const ret = false;\n return ret;\n };\n imports.wbg.__wbg_new_16b304a2cfa7ff4a = function() {\n const ret = new Array();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_push_a5b05aedc7234f9f = function(arg0, arg1) {\n const ret = getObject(arg0).push(getObject(arg1));\n return ret;\n };\n imports.wbg.__wbg_arrayBuffer_29931d52c7206b02 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).arrayBuffer();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_new_63b92bc8671ed464 = function(arg0) {\n const ret = new Uint8Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_c20a40f15020d68a = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_new_81740750da40724f = function(arg0, arg1) {\n try {\n var state0 = {a: arg0, b: arg1};\n var cb0 = (arg0, arg1) => {\n const a = state0.a;\n state0.a = 0;\n try {\n return __wbg_adapter_281(a, state0.b, arg0, arg1);\n } finally {\n state0.a = a;\n }\n };\n const ret = new Promise(cb0);\n return addHeapObject(ret);\n } finally {\n state0.a = state0.b = 0;\n }\n };\n imports.wbg.__wbindgen_number_new = function(arg0) {\n const ret = arg0;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_abda76e883ba8a5f = function() {\n const ret = new Error();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_stack_658279fe44541cf6 = function(arg0, arg1) {\n const ret = getObject(arg1).stack;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {\n let deferred0_0;\n let deferred0_1;\n try {\n deferred0_0 = arg0;\n deferred0_1 = arg1;\n console.error(getStringFromWasm0(arg0, arg1));\n } finally {\n wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);\n }\n };\n imports.wbg.__wbg_buffer_12d079cc21e14bdb = function(arg0) {\n const ret = getObject(arg0).buffer;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb = function(arg0, arg1, arg2) {\n const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_randomFillSync_5c9c955aa56b6049 = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).randomFillSync(takeObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_subarray_a1f73cd4b5b42fe1 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_getRandomValues_3aa56aa6edec874c = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).getRandomValues(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_set_a47bac70306a19a7 = function(arg0, arg1, arg2) {\n getObject(arg0).set(getObject(arg1), arg2 >>> 0);\n };\n imports.wbg.__wbg_crypto_1d1f22824a6a080c = function(arg0) {\n const ret = getObject(arg0).crypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_process_4a72847cc503995b = function(arg0) {\n const ret = getObject(arg0).process;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_versions_f686565e586dd935 = function(arg0) {\n const ret = getObject(arg0).versions;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_node_104a2ff8d6ea03a2 = function(arg0) {\n const ret = getObject(arg0).node;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_is_string = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'string';\n return ret;\n };\n imports.wbg.__wbg_require_cca90b1a94a0255b = function() { return handleError(function () {\n const ret = module.require;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_msCrypto_eb05e62b530a1508 = function(arg0) {\n const ret = getObject(arg0).msCrypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_e9b4878cebadb3d3 = function(arg0) {\n const ret = new Uint8Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_cd7af8117672b8b8 = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_get_bd8e338fbd5f5cc8 = function(arg0, arg1) {\n const ret = getObject(arg0)[arg1 >>> 0];\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_self_ce0dbfc45cf2f5be = function() { return handleError(function () {\n const ret = self.self;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_window_c6fb939a7f436783 = function() { return handleError(function () {\n const ret = window.window;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_globalThis_d1e6af4856ba331b = function() { return handleError(function () {\n const ret = globalThis.globalThis;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_global_207b558942527489 = function() { return handleError(function () {\n const ret = global.global;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_undefined = function(arg0) {\n const ret = getObject(arg0) === undefined;\n return ret;\n };\n imports.wbg.__wbg_newnoargs_e258087cd0daa0ea = function(arg0, arg1) {\n const ret = new Function(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_has_0af94d20077affa2 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.has(getObject(arg0), getObject(arg1));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_fetch_bc7c8e27076a5c84 = function(arg0) {\n const ret = fetch(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_fetch_921fad6ef9e883dd = function(arg0, arg1) {\n const ret = getObject(arg0).fetch(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {\n const ret = debugString(getObject(arg1));\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbindgen_throw = function(arg0, arg1) {\n throw new Error(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_rethrow = function(arg0) {\n throw takeObject(arg0);\n };\n imports.wbg.__wbg_then_a73caa9a87991566 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_then_0c86a60e8fcfe9f6 = function(arg0, arg1) {\n const ret = getObject(arg0).then(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_queueMicrotask_481971b0d87f3dd4 = function(arg0) {\n queueMicrotask(getObject(arg0));\n };\n imports.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6 = function(arg0) {\n const ret = getObject(arg0).queueMicrotask;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_resolve_b0083a7967828ec8 = function(arg0) {\n const ret = Promise.resolve(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_5d743fc9058ba01a = function() {\n const ret = Atomics.waitAsync;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_8cccba86b0f574cb = function(arg0) {\n const ret = new Int32Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_46d5c36955b71a79 = function(arg0, arg1, arg2) {\n const ret = Atomics.waitAsync(getObject(arg0), arg1, arg2);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_async_19c0400d97cc72fe = function(arg0) {\n const ret = getObject(arg0).async;\n return ret;\n };\n imports.wbg.__wbg_value_571d60108110e917 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_link_fc1eedd35dc7e0a6 = function(arg0) {\n const ret = \"data:application/javascript,\" + encodeURIComponent(`onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n `);\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_new_d1187ae36d662ef9 = function() { return handleError(function (arg0, arg1) {\n const ret = new Worker(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_setonmessage_503809e5bb51bd33 = function(arg0, arg1) {\n getObject(arg0).onmessage = getObject(arg1);\n };\n imports.wbg.__wbg_of_6a70eed8d41f469c = function(arg0, arg1, arg2) {\n const ret = Array.of(getObject(arg0), getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_postMessage_7380d10e8b8269df = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).postMessage(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_data_3ce7c145ca4fbcdc = function(arg0) {\n const ret = getObject(arg0).data;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_responseText_c67ed2d48db10769 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg1).responseText;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n }, arguments) };\n imports.wbg.__wbindgen_closure_wrapper5975 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 622, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_closure_wrapper6001 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 622, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n\n return imports;\n}\n\nfunction __wbg_init_memory(imports, maybe_memory) {\n imports.wbg.memory = maybe_memory || new WebAssembly.Memory({initial:25,maximum:65536,shared:true});\n}\n\nfunction __wbg_finalize_init(instance, module) {\n wasm = instance.exports;\n __wbg_init.__wbindgen_wasm_module = module;\n cachedBigInt64Memory0 = null;\n cachedInt32Memory0 = null;\n cachedUint8Memory0 = null;\n\n wasm.__wbindgen_start();\n return wasm;\n}\n\nfunction initSync(module, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n const imports = __wbg_get_imports();\n\n __wbg_init_memory(imports, maybe_memory);\n\n if (!(module instanceof WebAssembly.Module)) {\n module = new WebAssembly.Module(module);\n }\n\n const instance = new WebAssembly.Instance(module, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nasync function __wbg_init(input, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n\n const imports = __wbg_get_imports();\n\n if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {\n input = fetch(input);\n }\n\n __wbg_init_memory(imports, maybe_memory);\n\n const { instance, module } = await __wbg_load(await input, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nvar exports = /*#__PURE__*/Object.freeze({\n __proto__: null,\n Address: Address,\n Execution: Execution,\n ExecutionResponse: ExecutionResponse,\n Field: Field,\n KeyPair: KeyPair,\n Metadata: Metadata,\n OfflineQuery: OfflineQuery,\n PrivateKey: PrivateKey,\n PrivateKeyCiphertext: PrivateKeyCiphertext,\n Program: Program,\n ProgramManager: ProgramManager,\n ProvingKey: ProvingKey,\n RecordCiphertext: RecordCiphertext,\n RecordPlaintext: RecordPlaintext,\n Signature: Signature,\n Transaction: Transaction,\n VerifyingKey: VerifyingKey,\n ViewKey: ViewKey,\n default: __wbg_init,\n initSync: initSync,\n initThreadPool: initThreadPool,\n runRayonThread: runRayonThread,\n verifyFunctionExecution: verifyFunctionExecution\n});\n\nconst wasm_path = \"aleo_wasm.wasm\";\n\n \n var Cargo = async (opt = {}) => {\n let {importHook, serverPath, initializeHook} = opt;\n\n let final_path = wasm_path;\n\n if (serverPath != null) {\n final_path = serverPath + /[^\\/\\\\]*$/.exec(final_path)[0];\n }\n\n if (importHook != null) {\n final_path = importHook(final_path);\n }\n\n if (initializeHook != null) {\n await initializeHook(__wbg_init, final_path);\n\n } else {\n await __wbg_init(final_path);\n }\n\n return exports;\n };\n\nexport { Cargo as default };\n//# sourceMappingURL=aleo_wasm.js.map\n","/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nconst proxyMarker = Symbol(\"Comlink.proxy\");\nconst createEndpoint = Symbol(\"Comlink.endpoint\");\nconst releaseProxy = Symbol(\"Comlink.releaseProxy\");\nconst finalizer = Symbol(\"Comlink.finalizer\");\nconst throwMarker = Symbol(\"Comlink.thrown\");\nconst isObject = (val) => (typeof val === \"object\" && val !== null) || typeof val === \"function\";\n/**\n * Internal transfer handle to handle objects marked to proxy.\n */\nconst proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n};\n/**\n * Internal transfer handler to handle thrown exceptions.\n */\nconst throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n};\n/**\n * Allows customizing the serialization of certain values.\n */\nconst transferHandlers = new Map([\n [\"proxy\", proxyTransferHandler],\n [\"throw\", throwTransferHandler],\n]);\nfunction isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === \"*\") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n}\nfunction expose(obj, ep = globalThis, allowedOrigins = [\"*\"]) {\n ep.addEventListener(\"message\", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin '${ev.origin}' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case \"GET\" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case \"SET\" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case \"APPLY\" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case \"CONSTRUCT\" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case \"ENDPOINT\" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case \"RELEASE\" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === \"RELEASE\" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener(\"message\", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === \"function\") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError(\"Unserializable return value\"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n}\nfunction isMessagePort(endpoint) {\n return endpoint.constructor.name === \"MessagePort\";\n}\nfunction closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n}\nfunction wrap(ep, target) {\n return createProxy(ep, [], target);\n}\nfunction throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error(\"Proxy has been released and is not useable\");\n }\n}\nfunction releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: \"RELEASE\" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n}\nconst proxyCounter = new WeakMap();\nconst proxyFinalizers = \"FinalizationRegistry\" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\nfunction registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n}\nfunction unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n}\nfunction createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === \"then\") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: \"GET\" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: \"SET\" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: \"ENDPOINT\" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === \"bind\") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"APPLY\" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"CONSTRUCT\" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n}\nfunction myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n}\nfunction processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n}\nconst transferCache = new WeakMap();\nfunction transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n}\nfunction proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n}\nfunction windowEndpoint(w, context = globalThis, targetOrigin = \"*\") {\n return {\n postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\n addEventListener: context.addEventListener.bind(context),\n removeEventListener: context.removeEventListener.bind(context),\n };\n}\nfunction toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: \"HANDLER\" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: \"RAW\" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n}\nfunction fromWireValue(value) {\n switch (value.type) {\n case \"HANDLER\" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case \"RAW\" /* WireValueType.RAW */:\n return value.value;\n }\n}\nfunction requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener(\"message\", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener(\"message\", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n}\nfunction generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join(\"-\");\n}\n\nexport { createEndpoint, expose, finalizer, proxy, proxyMarker, releaseProxy, transfer, transferHandlers, windowEndpoint, wrap };\n//# sourceMappingURL=comlink.mjs.map\n"],"names":["Account","_privateKey","_viewKey","_address","constructor","params","this","privateKeyFromParams","e","console","error","Error","ViewKey","from_private_key","Address","fromCiphertext","ciphertext","password","PrivateKeyCiphertext","fromString","PrivateKey","fromPrivateKeyCiphertext","privateKey","to_string","seed","from_seed_unchecked","from_string","viewKey","address","toString","encryptAccount","toCiphertext","decryptRecord","decrypt","decryptRecords","ciphertexts","map","ownsRecordCiphertext","isOwner","RecordCiphertext","sign","message","verify","signature","parseJSON","json","JSON","parse","key","value","context","Number","isInteger","BigInt","source","async","get","url","options","response","fetch","ok","status","post","method","AleoNetworkClient","host","headers","account","setAccount","getAccount","setHost","fetchData","text","findUnspentRecords","startHeight","endHeight","amounts","maxMicrocredits","nonces","records","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","length","transactions","j","confirmedTransaction","type","transaction","execution","transitions","k","transition","program","outputs","l","output","record","recordPlaintext","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","warn","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","logAndThrow","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","AleoKeyProviderParams","name","proverUri","verifierUri","cacheKey","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","KEY_STORE","Map","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","set","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","join","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","inner","unBondPublicKeys","OfflineSearchParams","verifyCreditsKeys","bondPublicKeyParams","bondValidatorKeyParams","claimUnbondPublicKeyParams","feePrivateKeyParams","feePublicKeyParams","inclusionKeyParams","joinKeyParams","setValidatorStateKeyParams","splitKeyParams","transferPrivateKeyParams","transferPrivateToPublicKeyParams","transferPublicKeyParams","transferPublicAsSignerKeyParams","transferPublicToPrivateKeyParams","unbondPublicKeyParams","OfflineKeyProvider","Promise","resolve","reject","undefined","isBondPublicProver","isBondPublicVerifier","isClaimUnbondPublicProver","isClaimUnbondPublicVerifier","isFeePrivateProver","isFeePrivateVerifier","isFeePublicProver","isFeePublicVerifier","isInclusionProver","isInclusionVerifier","isJoinProver","isJoinVerifier","isSetValidatorStateProver","isSetValidatorStateVerifier","isSplitProver","isSplitVerifier","isTransferPrivateProver","isTransferPrivateVerifier","isTransferPrivateToPublicProver","isTransferPrivateToPublicVerifier","isTransferPublicProver","isTransferPublicVerifier","isTransferPublicToPrivateProver","isTransferPublicToPrivateVerifier","isUnbondPublicProver","isUnbondPublicVerifier","insertBondPublicKeys","bondPublicVerifier","insertClaimUnbondPublicKeys","claimUnbondPublicVerifier","insertFeePrivateKeys","feePrivateVerifier","insertFeePublicKeys","feePublicVerifier","insertJoinKeys","joinVerifier","insertSetValidatorStateKeys","setValidatorStateVerifier","insertSplitKeys","splitVerifier","insertTransferPrivateKeys","transferPrivateVerifier","insertTransferPrivateToPublicKeys","transferPrivateToPublicVerifier","insertTransferPublicKeys","transferPublicVerifier","insertTransferPublicToPrivateKeys","transferPublicToPrivateVerifier","insertUnbondPublicKeys","unbondPublicVerifier","NetworkRecordProvider","networkClient","findCreditsRecords","unspent","searchParameters","findCreditsRecord","findRecord","findRecords","BlockHeightSearch","singletonWorker","createAleoWorker","worker","Worker","URL","wrap","ProgramManager","keyProvider","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set","initializeWasm","spawnWorker","module","memory","addEventListener","event","setTimeout","unref","capture","once","postMessage","wasm","heap","fill","getObject","idx","heap_next","dropObject","takeObject","ret","cachedTextDecoder","TextDecoder","ignoreBOM","fatal","decode","cachedUint8Memory0","getUint8Memory0","buffer","getStringFromWasm0","ptr","len","slice","addHeapObject","obj","WASM_VECTOR_LEN","cachedTextEncoder","TextEncoder","encode","encodeString","arg","view","buf","read","written","passStringToWasm0","malloc","realloc","subarray","mem","offset","code","charCodeAt","isLikeNone","x","cachedInt32Memory0","getInt32Memory0","Int32Array","debugString","val","description","isArray","builtInMatches","exec","call","className","stringify","_","stack","CLOSURE_DTORS","FinalizationRegistry","register","unregister","state","__wbindgen_export_3","dtor","a","b","makeMutClosure","arg0","arg1","f","cnt","real","args","original","__wbg_adapter_34","arg2","_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha51b8a0cd6570266","_assertClass","instance","klass","passArray8ToWasm0","verifyFunctionExecution$1","retptr","__wbindgen_add_to_stack_pointer","Execution$1","VerifyingKey$1","Program$1","ptr0","__wbindgen_malloc","__wbindgen_realloc","len0","__wbg_ptr","r0","r1","cachedBigInt64Memory0","getBigInt64Memory0","BigInt64Array","getArrayU8FromWasm0","runRayonThread","receiver","initThreadPool$1","num_threads","initThreadPool","handleError","apply","__wbindgen_exn_store","__wbg_adapter_281","arg3","wasm_bindgen__convert__closures__invoke2_mut__h823ad1ce2c4b384e","AddressFinalization","__wbg_address_free","__wrap","create","prototype","__destroy_into_raw","free","private_key","PrivateKey$1","address_from_private_key","from_view_key","view_key","ViewKey$1","address_from_view_key","address_from_string","deferred1_0","deferred1_1","address_to_string","__wbindgen_free","Signature$1","address_verify","ExecutionFinalization","__wbg_execution_free","Execution","execution_toString","execution_fromString","ExecutionResponseFinalization","__wbg_executionresponse_free","ExecutionResponse","getOutputs","executionresponse_getOutputs","executionresponse_getExecution","executionresponse_getKeys","KeyPair","getProvingKey","executionresponse_getProvingKey","ProvingKey$1","executionresponse_getVerifyingKey","executionresponse_getFunctionId","executionresponse_getProgram","FieldFinalization","__wbg_field_free","Field","field_toString","field","field_fromString","KeyPairFinalization","__wbg_keypair_free","ptr1","keypair_new","keypair_provingKey","keypair_verifyingKey","MetadataFinalization","__wbg_metadata_free","__wbg_get_metadata_name","__wbg_set_metadata_name","__wbg_get_metadata_locator","__wbg_set_metadata_locator","__wbg_get_metadata_prover","__wbg_set_metadata_prover","__wbg_get_metadata_verifier","__wbg_set_metadata_verifier","__wbg_get_metadata_verifyingKey","__wbg_set_metadata_verifyingKey","metadata_baseUrl","metadata_bond_public","metadata_bond_validator","metadata_claim_unbond_public","metadata_fee_private","metadata_fee_public","metadata_inclusion","metadata_join","metadata_set_validator_state","metadata_split","metadata_transfer_private","metadata_transfer_private_to_public","metadata_transfer_public","metadata_transfer_public_as_signer","metadata_transfer_public_to_private","metadata_unbond_public","OfflineQueryFinalization","__wbg_offlinequery_free","OfflineQuery","state_root","offlinequery_new","addStatePath","commitment","state_path","len1","offlinequery_addStatePath","offlinequery_toString","s","offlinequery_fromString","PrivateKeyFinalization","__wbg_privatekey_free","privatekey_new","privatekey_from_seed_unchecked","privatekey_from_string","privatekey_to_string","privatekey_to_view_key","to_address","privatekey_to_address","Address$1","privatekey_sign","newEncrypted","secret","privatekey_newEncrypted","PrivateKeyCiphertext$1","privatekey_toCiphertext","privatekey_fromPrivateKeyCiphertext","PrivateKeyCiphertextFinalization","__wbg_privatekeyciphertext_free","encryptPrivateKey","decryptToPrivateKey","privatekeyciphertext_decryptToPrivateKey","privatekeyciphertext_toString","privatekeyciphertext_fromString","ProgramFinalization","__wbg_program_free","program_fromString","program_toString","hasFunction","program_hasFunction","getFunctions","program_getFunctions","getFunctionInputs","program_getFunctionInputs","getMappings","program_getMappings","getRecordMembers","record_name","program_getRecordMembers","getStructMembers","struct_name","program_getStructMembers","program_getCreditsProgram","program_id","program_address","isEqual","other","program_isEqual","program_getImports","ProgramManagerFinalization","__wbg_programmanager_free","fee_credits","fee_record","fee_proving_key","fee_verifying_key","offline_query","RecordPlaintext$1","ptr2","len2","ptr3","ptr4","ptr5","OfflineQuery$1","programmanager_buildDeploymentTransaction","estimateDeploymentFee","programmanager_estimateDeploymentFee","estimateProgramNameCost","programmanager_estimateProgramNameCost","r2","asUintN","_function","prove_execution","len4","programmanager_executeFunctionOffline","len3","ptr6","ptr7","ptr8","programmanager_buildExecutionTransaction","estimateExecutionFee","programmanager_estimateExecutionFee","estimateFinalizeFee","programmanager_estimateFinalizeFee","record_1","record_2","join_proving_key","join_verifying_key","programmanager_buildJoinTransaction","split_amount","amount_record","split_proving_key","split_verifying_key","programmanager_buildSplitTransaction","amount_credits","transfer_type","transfer_proving_key","transfer_verifying_key","ptr9","programmanager_buildTransferTransaction","programmanager_synthesizeKeyPair","ProvingKeyFinalization","__wbg_provingkey_free","provingkey_isBondPublicProver","isBondValidatorProver","provingkey_isBondValidatorProver","provingkey_isClaimUnbondPublicProver","provingkey_isFeePrivateProver","provingkey_isFeePublicProver","provingkey_isInclusionProver","provingkey_isJoinProver","provingkey_isSetValidatorStateProver","provingkey_isSplitProver","provingkey_isTransferPrivateProver","provingkey_isTransferPrivateToPublicProver","provingkey_isTransferPublicProver","isTransferPublicAsSignerProver","provingkey_isTransferPublicAsSignerProver","provingkey_isTransferPublicToPrivateProver","provingkey_isUnbondPublicProver","checksum","provingkey_checksum","copy","provingkey_copy","bytes","provingkey_fromBytes","string","provingkey_fromString","provingkey_toBytes","v1","provingkey_toString","RecordCiphertextFinalization","__wbg_recordciphertext_free","recordciphertext_fromString","recordciphertext_toString","recordciphertext_decrypt","recordciphertext_isOwner","RecordPlaintextFinalization","__wbg_recordplaintext_free","recordplaintext_commitment","Field$1","recordplaintext_fromString","recordplaintext_toString","recordplaintext_microcredits","recordplaintext_nonce","deferred4_0","deferred4_1","recordplaintext_serialNumberString","r3","SignatureFinalization","__wbg_signature_free","Signature","signature_verify","signature_from_string","signature_to_string","TransactionFinalization","__wbg_transaction_free","transaction_fromString","transaction_toString","transactionId","transaction_transactionId","transactionType","transaction_transactionType","VerifyingKeyFinalization","__wbg_verifyingkey_free","verifyingkey_bondPublicVerifier","bondValidatorVerifier","verifyingkey_bondValidatorVerifier","verifyingkey_claimUnbondPublicVerifier","verifyingkey_feePrivateVerifier","verifyingkey_feePublicVerifier","inclusionVerifier","verifyingkey_inclusionVerifier","verifyingkey_joinVerifier","verifyingkey_setValidatorStateVerifier","verifyingkey_splitVerifier","verifyingkey_transferPrivateVerifier","verifyingkey_transferPrivateToPublicVerifier","verifyingkey_transferPublicVerifier","transferPublicAsSignerVerifier","verifyingkey_transferPublicAsSignerVerifier","verifyingkey_transferPublicToPrivateVerifier","verifyingkey_unbondPublicVerifier","verifyingkey_isBondPublicVerifier","isBondValidatorVerifier","verifyingkey_isBondValidatorVerifier","verifyingkey_isClaimUnbondPublicVerifier","verifyingkey_isFeePrivateVerifier","verifyingkey_isFeePublicVerifier","verifyingkey_isInclusionVerifier","verifyingkey_isJoinVerifier","verifyingkey_isSetValidatorStateVerifier","verifyingkey_isSplitVerifier","verifyingkey_isTransferPrivateVerifier","verifyingkey_isTransferPrivateToPublicVerifier","verifyingkey_isTransferPublicVerifier","isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicToPrivateVerifier","verifyingkey_isUnbondPublicVerifier","verifyingkey_checksum","verifyingkey_copy","verifyingkey_fromBytes","verifyingkey_fromString","verifyingkey_toBytes","verifyingkey_toString","ViewKeyFinalization","__wbg_viewkey_free","viewkey_from_string","viewkey_to_string","deferred3_0","deferred3_1","viewkey_decrypt","__wbg_load","Response","WebAssembly","instantiateStreaming","instantiate","Instance","__wbg_get_imports","wbg","__wbindgen_object_drop_ref","__wbg_new_71801a555ad9f2aa","XMLHttpRequest","arguments","__wbg_overrideMimeType_ee9c51919ceb418b","overrideMimeType","__wbg_open_c9eb0cf2c9d95679","arg4","arg5","open","__wbg_send_80d29985093c1ec5","send","__wbg_response_7c2e2759084f7279","__wbg_status_d485fb5a478426fb","__wbg_new_72fb9a18b5ae2624","__wbindgen_string_new","__wbg_set_1f9b04f170055d33","Reflect","__wbg_new_ab6fd82b10560829","Headers","__wbindgen_object_clone_ref","__wbg_new_0d76b0581eca6298","AbortController","__wbg_signal_a61f78a3478fd9bc","signal","__wbg_append_7bfcb4937d1d5e29","append","__wbg_instanceof_Response_849eb93e75734b6e","result","__wbg_status_61a01141acd3cf74","__wbg_url_5f6dc4009ac5f99d","__wbg_headers_9620bfada380764a","__wbg_iterator_2cee6dadfd956dfa","Symbol","iterator","__wbg_get_e3c254076557e348","__wbindgen_is_function","__wbg_call_27c0f87801dedf93","__wbindgen_is_object","__wbg_next_40fc327bfc8770e6","next","__wbg_next_196c84450b364254","__wbg_done_298b57d23c0fc80c","done","__wbg_value_d93c65011f51a456","__wbg_abort_2aa7521d5690750e","abort","__wbg_stringify_8887fe74e1c50d81","__wbindgen_string_get","__wbg_log_0159ca40cddf5b15","__wbindgen_bigint_from_u64","__wbg_call_b3ca7c6051f9bec1","__wbindgen_module","__wbg_init","__wbindgen_wasm_module","__wbindgen_memory","__wbg_spawnWorker_f6acaddb2e29dc4a","__wbg_executionresponse_new","ExecutionResponse$1","__wbg_keypair_new","__wbg_transaction_new","Transaction$1","__wbg_newwithlength_66ae46612e7f0234","__wbg_set_d4638f722068f043","__wbindgen_cb_drop","__wbg_new_16b304a2cfa7ff4a","__wbg_push_a5b05aedc7234f9f","__wbg_arrayBuffer_29931d52c7206b02","__wbg_new_63b92bc8671ed464","__wbg_length_c20a40f15020d68a","__wbg_new_81740750da40724f","state0","cb0","__wbindgen_number_new","__wbg_new_abda76e883ba8a5f","__wbg_stack_658279fe44541cf6","__wbg_error_f851667af71bcfc6","deferred0_0","deferred0_1","__wbg_buffer_12d079cc21e14bdb","__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb","__wbg_randomFillSync_5c9c955aa56b6049","randomFillSync","__wbg_subarray_a1f73cd4b5b42fe1","__wbg_getRandomValues_3aa56aa6edec874c","getRandomValues","__wbg_set_a47bac70306a19a7","__wbg_crypto_1d1f22824a6a080c","crypto","__wbg_process_4a72847cc503995b","process","__wbg_versions_f686565e586dd935","versions","__wbg_node_104a2ff8d6ea03a2","node","__wbindgen_is_string","__wbg_require_cca90b1a94a0255b","require","__wbg_msCrypto_eb05e62b530a1508","msCrypto","__wbg_newwithlength_e9b4878cebadb3d3","__wbg_length_cd7af8117672b8b8","__wbg_get_bd8e338fbd5f5cc8","__wbg_self_ce0dbfc45cf2f5be","self","__wbg_window_c6fb939a7f436783","window","__wbg_globalThis_d1e6af4856ba331b","globalThis","__wbg_global_207b558942527489","global","__wbindgen_is_undefined","__wbg_newnoargs_e258087cd0daa0ea","Function","__wbg_has_0af94d20077affa2","__wbg_fetch_bc7c8e27076a5c84","__wbg_fetch_921fad6ef9e883dd","__wbindgen_debug_string","__wbindgen_throw","__wbindgen_rethrow","__wbg_then_a73caa9a87991566","then","__wbg_then_0c86a60e8fcfe9f6","__wbg_queueMicrotask_481971b0d87f3dd4","queueMicrotask","__wbg_queueMicrotask_3cbae2ec6b6cd3d6","__wbg_resolve_b0083a7967828ec8","__wbg_waitAsync_5d743fc9058ba01a","Atomics","waitAsync","__wbg_new_8cccba86b0f574cb","__wbg_waitAsync_46d5c36955b71a79","__wbg_async_19c0400d97cc72fe","__wbg_value_571d60108110e917","__wbindgen_link_fc1eedd35dc7e0a6","encodeURIComponent","__wbg_new_d1187ae36d662ef9","__wbg_setonmessage_503809e5bb51bd33","onmessage","__wbg_of_6a70eed8d41f469c","of","__wbg_postMessage_7380d10e8b8269df","__wbg_data_3ce7c145ca4fbcdc","__wbg_newwithstrandinit_3fd6fba4083ff2d0","Request","__wbg_responseText_c67ed2d48db10769","responseText","__wbindgen_closure_wrapper5975","__wbindgen_closure_wrapper6001","__wbg_init_memory","maybe_memory","Memory","initial","maximum","shared","__wbg_finalize_init","exports","__wbindgen_start","initSync","Module","input","freeze","__proto__","Metadata$1","RecordCiphertext$1","default","wasm_path","opt","importHook","serverPath","initializeHook","final_path","proxyMarker","createEndpoint","releaseProxy","finalizer","throwMarker","isObject","transferHandlers","canHandle","serialize","port1","port2","MessageChannel","expose","deserialize","port","serialized","isError","ep","allowedOrigins","callback","ev","origin","allowedOrigin","RegExp","test","isAllowedOrigin","path","argumentList","fromWireValue","returnValue","parent","reduce","prop","rawValue","proxy","transfers","transferCache","catch","wireValue","transferables","toWireValue","removeEventListener","closeEndPoint","TypeError","endpoint","isMessagePort","close","target","createProxy","throwIfProxyReleased","isReleased","releaseEndpoint","requestResponseMessage","proxyCounter","WeakMap","proxyFinalizers","newCount","isProxyReleased","Proxy","_target","unregisterProxy","r","p","bind","_thisArg","rawArgumentList","last","processArguments","construct","registerProxy","processed","v","arr","concat","handler","serializedValue","msg","floor","random","MAX_SAFE_INTEGER"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"523.bundle.js","mappings":";4wCA2CaA,EACXC,YACAC,SACAC,SAEAC,WAAAA,CAAYC,EAAuB,CAAC,GAClC,IACEC,KAAKL,YAAcK,KAAKC,qBAAqBF,GAC7C,MAAOG,GAEP,MADAC,QAAQC,MAAM,kBAAmBF,GAC3B,IAAIG,MAAM,mBAElBL,KAAKJ,SAAWU,EAAAA,GAAQC,iBAAiBP,KAAKL,aAC9CK,KAAKH,SAAWW,EAAAA,GAAQD,iBAAiBP,KAAKL,aAazC,qBAAOc,CAAeC,EAA2CC,GACtE,IACED,EAAoC,iBAAfA,EAA2BE,EAAAA,GAAqBC,WAAWH,GAAcA,EAC9F,MAAMf,EAAcmB,EAAAA,GAAWC,yBAAyBL,EAAYC,GACpE,OAAO,IAAIjB,EAAQ,CAAEsB,WAAYrB,EAAYsB,cAC7C,MAAMf,GACN,MAAM,IAAIG,MAAM,yCAIZJ,oBAAAA,CAAqBF,GAC3B,OAAIA,EAAOmB,KACFJ,EAAAA,GAAWK,oBAAoBpB,EAAOmB,MAE3CnB,E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EAAYn2B,GACjB,IAAK,MAAOkG,EAAMmyB,KAAYpE,EAC1B,GAAIoE,EAAQnE,UAAUl0B,GAAQ,CAC1B,MAAOs4B,EAAiBpC,GAAiBmC,EAAQlE,UAAUn0B,GAC3D,MAAO,CACH,CACIV,KAAM,UACN4G,OACAlG,MAAOs4B,GAEXpC,EAER,CAEJ,MAAO,CACH,CACI52B,KAAM,MACNU,SAEJ+1B,EAAcp8B,IAAIqG,IAAU,GAEpC,CACA,SAASu1B,EAAcv1B,GACnB,OAAQA,EAAMV,MACV,IAAK,UACD,OAAO20B,EAAiBt6B,IAAIqG,EAAMkG,MAAMsuB,YAAYx0B,EAAMA,OAC9D,IAAK,MACD,OAAOA,EAAMA,MAEzB,CACA,SAAS+2B,EAAuBnC,EAAI2D,EAAKzC,GACrC,OAAO,IAAI18B,SAASC,IAChB,MAAM8L,EAeH,IAAI5D,MAAM,GACZiN,KAAK,GACL7Y,KAAI,IAAMwW,KAAKqsB,MAAMrsB,KAAKssB,SAAWv4B,OAAOw4B,kBAAkBtjC,SAAS,MACvEiC,KAAK,KAjBNu9B,EAAG7mB,iBAAiB,WAAW,SAASlL,EAAEkyB,GACjCA,EAAG/tB,MAAS+tB,EAAG/tB,KAAK7B,IAAM4vB,EAAG/tB,KAAK7B,KAAOA,IAG9CyvB,EAAGwB,oBAAoB,UAAWvzB,GAClCxJ,EAAQ07B,EAAG/tB,MACf,IACI4tB,EAAGpzB,OACHozB,EAAGpzB,QAEPozB,EAAGvmB,YAAY1I,OAAOC,OAAO,CAAET,MAAMozB,GAAMzC,EAAU,GAE7D","sources":["webpack://aleo-website/../../src/account.ts","webpack://aleo-website/../../src/offline-key-provider.ts","webpack://aleo-website/../../src/record-provider.ts","webpack://aleo-website/../../src/managed-worker.ts","webpack://aleo-website/../../src/browser.ts","webpack://aleo-website/../../src/utils.ts","webpack://aleo-website/../../src/network-client.ts","webpack://aleo-website/../../src/constants.ts","webpack://aleo-website/../../src/function-key-provider.ts","webpack://aleo-website/../../src/program-manager.ts","webpack://aleo-website/aleo_wasm.js","webpack://aleo-website/../node_modules/comlink/dist/esm/comlink.mjs"],"sourcesContent":["import {\n Address,\n PrivateKey,\n Signature,\n ViewKey,\n PrivateKeyCiphertext,\n RecordCiphertext,\n} from \"./wasm\";\n\ninterface AccountParam {\n privateKey?: string;\n seed?: Uint8Array;\n}\n\n/**\n * Key Management class. Enables the creation of a new Aleo Account, importation of an existing account from\n * an existing private key or seed, and message signing and verification functionality.\n *\n * An Aleo Account is generated from a randomly generated seed (number) from which an account private key, view key,\n * and a public account address are derived. The private key lies at the root of an Aleo account. It is a highly\n * sensitive secret and should be protected as it allows for creation of Aleo Program executions and arbitrary value\n * transfers. The View Key allows for decryption of a user's activity on the blockchain. The Address is the public\n * address to which other users of Aleo can send Aleo credits and other records to. This class should only be used\n * environments where the safety of the underlying key material can be assured.\n *\n * @example\n * // Create a new account\n * const myRandomAccount = new Account();\n *\n * // Create an account from a randomly generated seed\n * const seed = new Uint8Array([94, 91, 52, 251, 240, 230, 226, 35, 117, 253, 224, 210, 175, 13, 205, 120, 155, 214, 7, 169, 66, 62, 206, 50, 188, 40, 29, 122, 40, 250, 54, 18]);\n * const mySeededAccount = new Account({seed: seed});\n *\n * // Create an account from an existing private key\n * const myExistingAccount = new Account({privateKey: 'myExistingPrivateKey'})\n *\n * // Sign a message\n * const hello_world = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * const signature = myRandomAccount.sign(hello_world)\n *\n * // Verify a signature\n * myRandomAccount.verify(hello_world, signature)\n */\nexport class Account {\n _privateKey: PrivateKey;\n _viewKey: ViewKey;\n _address: Address;\n\n constructor(params: AccountParam = {}) {\n try {\n this._privateKey = this.privateKeyFromParams(params);\n } catch (e) {\n console.error(\"Wrong parameter\", e);\n throw new Error(\"Wrong Parameter\");\n }\n this._viewKey = ViewKey.from_private_key(this._privateKey);\n this._address = Address.from_private_key(this._privateKey);\n }\n\n /**\n * Attempts to create an account from a private key ciphertext\n * @param {PrivateKeyCiphertext | string} ciphertext\n * @param {string} password\n * @returns {PrivateKey}\n *\n * @example\n * const ciphertext = PrivateKey.newEncrypted(\"password\");\n * const account = Account.fromCiphertext(ciphertext, \"password\");\n */\n public static fromCiphertext(ciphertext: PrivateKeyCiphertext | string, password: string) {\n try {\n ciphertext = (typeof ciphertext === \"string\") ? PrivateKeyCiphertext.fromString(ciphertext) : ciphertext;\n const _privateKey = PrivateKey.fromPrivateKeyCiphertext(ciphertext, password);\n return new Account({ privateKey: _privateKey.to_string() });\n } catch(e) {\n throw new Error(\"Wrong password or invalid ciphertext\");\n }\n }\n\n private privateKeyFromParams(params: AccountParam) {\n if (params.seed) {\n return PrivateKey.from_seed_unchecked(params.seed);\n }\n if (params.privateKey) {\n return PrivateKey.from_string(params.privateKey);\n }\n return new PrivateKey();\n }\n\n privateKey() {\n return this._privateKey;\n }\n\n viewKey() {\n return this._viewKey;\n }\n\n address() {\n return this._address;\n }\n\n toString() {\n return this.address().to_string()\n }\n\n /**\n * Encrypt the account's private key with a password\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n *\n * @example\n * const account = new Account();\n * const ciphertext = account.encryptAccount(\"password\");\n */\n encryptAccount(password: string) {\n return this._privateKey.toCiphertext(password);\n }\n\n /**\n * Decrypts a Record in ciphertext form into plaintext\n * @param {string} ciphertext\n * @returns {Record}\n *\n * @example\n * const account = new Account();\n * const record = account.decryptRecord(\"record1ciphertext\");\n */\n decryptRecord(ciphertext: string) {\n return this._viewKey.decrypt(ciphertext);\n }\n\n /**\n * Decrypts an array of Records in ciphertext form into plaintext\n * @param {string[]} ciphertexts\n * @returns {Record[]}\n *\n * @example\n * const account = new Account();\n * const record = account.decryptRecords([\"record1ciphertext\", \"record2ciphertext\"]);\n */\n decryptRecords(ciphertexts: string[]) {\n return ciphertexts.map((ciphertext) => this._viewKey.decrypt(ciphertext));\n }\n\n /**\n * Determines whether the account owns a ciphertext record\n * @param {RecordCipherText | string} ciphertext\n * @returns {boolean}\n *\n * @example\n * // Create a connection to the Aleo network and an account\n * const connection = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const account = Account.fromCiphertext(\"ciphertext\", \"password\");\n *\n * // Get a record from the network\n * const record = connection.getBlock(1234);\n * const recordCipherText = record.transactions[0].execution.transitions[0].id;\n *\n * // Check if the account owns the record\n * if account.ownsRecord(recordCipherText) {\n * // Then one can do something like:\n * // Decrypt the record and check if it's spent\n * // Store the record in a local database\n * // Etc.\n * }\n */\n ownsRecordCiphertext(ciphertext: RecordCiphertext | string) {\n if (typeof ciphertext === 'string') {\n try {\n const ciphertextObject = RecordCiphertext.fromString(ciphertext);\n return ciphertextObject.isOwner(this._viewKey);\n }\n catch (e) {\n return false;\n }\n }\n else {\n return ciphertext.isOwner(this._viewKey);\n }\n }\n\n /**\n * Signs a message with the account's private key.\n * Returns a Signature.\n *\n * @param {Uint8Array} message\n * @returns {Signature}\n *\n * @example\n * const account = new Account();\n * const message = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * account.sign(message);\n */\n sign(message: Uint8Array) {\n return this._privateKey.sign(message);\n }\n\n /**\n * Verifies the Signature on a message.\n *\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n *\n * @example\n * const account = new Account();\n * const message = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * const signature = account.sign(message);\n * account.verify(message, signature);\n */\n verify(message: Uint8Array, signature: Signature) {\n return this._address.verify(message, signature);\n }\n\n}\n","import {\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\n\nimport {\n ProvingKey,\n VerifyingKey,\n} from \"./wasm\";\n\nimport {\n CREDITS_PROGRAM_KEYS,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n} from \"./constants\";\n\n/**\n * Search parameters for the offline key provider. This class implements the KeySearchParams interface and includes\n * a convenience method for creating a new instance of this class for each function of the credits.aleo program.\n *\n * @example\n * // If storing a key for a custom program function\n * offlineSearchParams = new OfflineSearchParams(\"myprogram.aleo/myfunction\");\n *\n * // If storing a key for a credits.aleo program function\n * bondPublicKeyParams = OfflineSearchParams.bondPublicKeyParams();\n */\nclass OfflineSearchParams implements KeySearchParams {\n cacheKey: string | undefined;\n verifyCreditsKeys: boolean | undefined;\n\n /**\n * Create a new OfflineSearchParams instance.\n *\n * @param {string} cacheKey - Key used to store the local function proving & verifying keys. This should be stored\n * under the naming convention \"programName/functionName\" (i.e. \"myprogram.aleo/myfunction\")\n * @param {boolean} verifyCreditsKeys - Whether to verify the keys against the credits.aleo program,\n * defaults to false, but should be set to true if using keys from the credits.aleo program\n */\n constructor(cacheKey: string, verifyCreditsKeys = false) {\n this.cacheKey = cacheKey;\n this.verifyCreditsKeys = verifyCreditsKeys;\n }\n\n /**\n * Create a new OfflineSearchParams instance for the bond_public function of the credits.aleo program.\n */\n static bondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.bond_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the bond_validator function of the credits.aleo program.\n */\n static bondValidatorKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.bond_validator.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the claim_unbond_public function of the\n */\n static claimUnbondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.claim_unbond_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the fee_private function of the credits.aleo program.\n */\n static feePrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.fee_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the fee_public function of the credits.aleo program.\n */\n static feePublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.fee_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the inclusion prover function.\n */\n static inclusionKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.inclusion.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the join function of the credits.aleo program.\n */\n static joinKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.join.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the set_validator_state function of the credits.aleo program.\n */\n static setValidatorStateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.set_validator_state.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the split function of the credits.aleo program.\n */\n static splitKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.split.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_private function of the credits.aleo program.\n */\n static transferPrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_private_to_public function of the credits.aleo program.\n */\n static transferPrivateToPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public function of the credits.aleo program.\n */\n static transferPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public_as_signer function of the credits.aleo program.\n */\n static transferPublicAsSignerKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public_as_signer.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public_to_private function of the credits.aleo program.\n */\n static transferPublicToPrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the unbond_public function of the credits.aleo program.\n */\n static unbondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.unbond_public.locator, true);\n }\n}\n\n/**\n * A key provider meant for building transactions offline on devices such as hardware wallets. This key provider is not\n * able to contact the internet for key material and instead relies on the user to insert Aleo function proving &\n * verifying keys from local storage prior to usage.\n *\n * @example\n * // Create an offline program manager\n * const programManager = new ProgramManager();\n *\n * // Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * // Create the proving keys from the key bytes on the offline machine\n * console.log(\"Creating proving keys from local key files\");\n * const program = \"program hello_hello.aleo; function hello: input r0 as u32.public; input r1 as u32.private; add r0 r1 into r2; output r2 as u32.private;\";\n * const myFunctionProver = await getLocalKey(\"/path/to/my/function/hello_hello.prover\");\n * const myFunctionVerifier = await getLocalKey(\"/path/to/my/function/hello_hello.verifier\");\n * const feePublicProvingKeyBytes = await getLocalKey(\"/path/to/credits.aleo/feePublic.prover\");\n *\n * myFunctionProvingKey = ProvingKey.fromBytes(myFunctionProver);\n * myFunctionVerifyingKey = VerifyingKey.fromBytes(myFunctionVerifier);\n * const feePublicProvingKey = ProvingKey.fromBytes(feePublicKeyBytes);\n *\n * // Create an offline key provider\n * console.log(\"Creating offline key provider\");\n * const offlineKeyProvider = new OfflineKeyProvider();\n *\n * // Cache the keys\n * // Cache the proving and verifying keys for the custom hello function\n * OfflineKeyProvider.cacheKeys(\"hello_hello.aleo/hello\", myFunctionProvingKey, myFunctionVerifyingKey);\n *\n * // Cache the proving key for the fee_public function (the verifying key is automatically cached)\n * OfflineKeyProvider.insertFeePublicKey(feePublicProvingKey);\n *\n * // Create an offline query using the latest state root in order to create the inclusion proof\n * const offlineQuery = new OfflineQuery(\"latestStateRoot\");\n *\n * // Insert the key provider into the program manager\n * programManager.setKeyProvider(offlineKeyProvider);\n *\n * // Create the offline search params\n * const offlineSearchParams = new OfflineSearchParams(\"hello_hello.aleo/hello\");\n *\n * // Create the offline transaction\n * const offlineExecuteTx = await this.buildExecutionTransaction(\"hello_hello.aleo\", \"hello\", 1, false, [\"5u32\", \"5u32\"], undefined, offlineSearchParams, undefined, undefined, undefined, undefined, offlineQuery, program);\n *\n * // Broadcast the transaction later on a machine with internet access\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const txId = await networkClient.broadcastTransaction(offlineExecuteTx);\n */\nclass OfflineKeyProvider implements FunctionKeyProvider {\n cache: Map;\n\n constructor() {\n this.cache = new Map();\n }\n\n /**\n * Get bond_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.bondPublicKeyParams());\n };\n\n /**\n * Get bond_validator function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondValidatorKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.bondValidatorKeyParams());\n };\n\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n };\n\n /**\n * Get unbond_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.claimUnbondPublicKeyParams());\n };\n\n /**\n * Get arbitrary function key from the offline key provider cache.\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * /// First cache the keys from local offline resources\n * const offlineKeyProvider = new OfflineKeyProvider();\n * const myFunctionVerifyingKey = VerifyingKey.fromString(\"verifier...\");\n * const myFunctionProvingKeyBytes = await readBinaryFile('./resources/myfunction.prover');\n * const myFunctionProvingKey = ProvingKey.fromBytes(myFunctionProvingKeyBytes);\n *\n * /// Cache the keys for future use with a memorable locator\n * offlineKeyProvider.cacheKeys(\"myprogram.aleo/myfunction\", [myFunctionProvingKey, myFunctionVerifyingKey]);\n *\n * /// When they're needed, retrieve the keys from the cache\n *\n * /// First create a search parameter object with the same locator used to cache the keys\n * const keyParams = new OfflineSearchParams(\"myprogram.aleo/myfunction\");\n *\n * /// Then retrieve the keys\n * const [myFunctionProver, myFunctionVerifier] = await offlineKeyProvider.functionKeys(keyParams);\n */\n functionKeys(params?: KeySearchParams): Promise {\n return new Promise((resolve, reject) => {\n if (params === undefined) {\n reject(new Error(\"No search parameters provided, cannot retrieve keys\"));\n } else {\n const keyId = params.cacheKey;\n const verifyCreditsKeys = params.verifyCreditsKeys;\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId) as CachedKeyPair;\n const provingKey = ProvingKey.fromBytes(provingKeyBytes);\n const verifyingKey = VerifyingKey.fromBytes(verifyingKeyBytes);\n if (verifyCreditsKeys) {\n const keysMatchExpected = this.verifyCreditsKeys(keyId, provingKey, verifyingKey)\n if (!keysMatchExpected) {\n reject (new Error(`Cached keys do not match expected keys for ${keyId}`));\n }\n }\n resolve([provingKey, verifyingKey]);\n } else {\n reject(new Error(\"Keys not found in cache for \" + keyId));\n }\n }\n });\n };\n\n /**\n * Determines if the keys for a given credits function match the expected keys.\n *\n * @returns {boolean} Whether the keys match the expected keys\n */\n verifyCreditsKeys(locator: string, provingKey: ProvingKey, verifyingKey: VerifyingKey): boolean {\n switch (locator) {\n case CREDITS_PROGRAM_KEYS.bond_public.locator:\n return provingKey.isBondPublicProver() && verifyingKey.isBondPublicVerifier();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.locator:\n return provingKey.isClaimUnbondPublicProver() && verifyingKey.isClaimUnbondPublicVerifier();\n case CREDITS_PROGRAM_KEYS.fee_private.locator:\n return provingKey.isFeePrivateProver() && verifyingKey.isFeePrivateVerifier();\n case CREDITS_PROGRAM_KEYS.fee_public.locator:\n return provingKey.isFeePublicProver() && verifyingKey.isFeePublicVerifier();\n case CREDITS_PROGRAM_KEYS.inclusion.locator:\n return provingKey.isInclusionProver() && verifyingKey.isInclusionVerifier();\n case CREDITS_PROGRAM_KEYS.join.locator:\n return provingKey.isJoinProver() && verifyingKey.isJoinVerifier();\n case CREDITS_PROGRAM_KEYS.set_validator_state.locator:\n return provingKey.isSetValidatorStateProver() && verifyingKey.isSetValidatorStateVerifier();\n case CREDITS_PROGRAM_KEYS.split.locator:\n return provingKey.isSplitProver() && verifyingKey.isSplitVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_private.locator:\n return provingKey.isTransferPrivateProver() && verifyingKey.isTransferPrivateVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator:\n return provingKey.isTransferPrivateToPublicProver() && verifyingKey.isTransferPrivateToPublicVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_public.locator:\n return provingKey.isTransferPublicProver() && verifyingKey.isTransferPublicVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator:\n return provingKey.isTransferPublicToPrivateProver() && verifyingKey.isTransferPublicToPrivateVerifier();\n case CREDITS_PROGRAM_KEYS.unbond_public.locator:\n return provingKey.isUnbondPublicProver() && verifyingKey.isUnbondPublicVerifier();\n default:\n return false;\n }\n }\n\n /**\n * Get fee_private function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.feePrivateKeyParams());\n };\n\n /**\n * Get fee_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.feePublicKeyParams());\n };\n\n /**\n * Get join function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.joinKeyParams());\n };\n\n /**\n * Get split function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.splitKeyParams());\n };\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program.\n *\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new OfflineKeyProvider\n * const offlineKeyProvider = new OfflineKeyProvider();\n *\n * // Cache the keys for future use with the official locator\n * const transferPublicProvingKeyBytes = await readBinaryFile('./resources/transfer_public.prover.a74565e');\n * const transferPublicProvingKey = ProvingKey.fromBytes(transferPublicProvingKeyBytes);\n *\n * // Cache the transfer_public keys for future use with the OfflinKeyProvider's convenience method for\n * // transfer_public (the verifying key will be cached automatically)\n * offlineKeyProvider.insertTransferPublicKeys(transferPublicProvingKey);\n *\n * /// When they're needed, retrieve the keys from the cache\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPrivateKeyParams());\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPrivateToPublicKeyParams());\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicKeyParams());\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicAsSignerKeyParams());\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicToPrivateKeyParams());\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n };\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async unBondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.unbondPublicKeyParams());\n };\n\n /**\n * Insert the proving and verifying keys for the bond_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for bond_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertBondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isBondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [provingKey.toBytes(), VerifyingKey.bondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for bond_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the claim_unbond_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for claim_unbond_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertClaimUnbondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isClaimUnbondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.claim_unbond_public.locator, [provingKey.toBytes(), VerifyingKey.claimUnbondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for claim_unbond_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the fee_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for fee_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertFeePrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isFeePrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.fee_private.locator, [provingKey.toBytes(), VerifyingKey.feePrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for fee_private\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the fee_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for fee_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertFeePublicKeys(provingKey: ProvingKey) {\n if (provingKey.isFeePublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.fee_public.locator, [provingKey.toBytes(), VerifyingKey.feePublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for fee_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the join function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for join before inserting them into the cache.\n *\n * @param provingKey\n */\n insertJoinKeys(provingKey: ProvingKey) {\n if (provingKey.isJoinProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.join.locator, [provingKey.toBytes(), VerifyingKey.joinVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for join\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the set_validator_state function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for set_validator_state before inserting them into the cache.\n *\n * @param provingKey\n */\n insertSetValidatorStateKeys(provingKey: ProvingKey) {\n if (provingKey.isSetValidatorStateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.set_validator_state.locator, [provingKey.toBytes(), VerifyingKey.setValidatorStateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for set_validator_state\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the split function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for split before inserting them into the cache.\n *\n * @param provingKey\n */\n insertSplitKeys(provingKey: ProvingKey) {\n if (provingKey.isSplitProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.split.locator, [provingKey.toBytes(), VerifyingKey.splitVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for split\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_private.locator, [provingKey.toBytes(), VerifyingKey.transferPrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_private\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_private_to_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_private_to_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPrivateToPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPrivateToPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator, [provingKey.toBytes(), VerifyingKey.transferPrivateToPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_private_to_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_public.locator, [provingKey.toBytes(), VerifyingKey.transferPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_public_to_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_public_to_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPublicToPrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPublicToPrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator, [provingKey.toBytes(), VerifyingKey.transferPublicToPrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_public_to_private\");\n }\n }\n\n insertUnbondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isUnbondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.unbond_public.locator, [provingKey.toBytes(), VerifyingKey.unbondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for unbond_public\");\n }\n }\n}\n\n\nexport {OfflineKeyProvider, OfflineSearchParams}\n","import { RecordPlaintext } from \"./wasm\";\nimport { logAndThrow } from \"./utils\";\nimport { Account } from \"./account\";\nimport { AleoNetworkClient } from \"./network-client\";\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface RecordSearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * Interface for a record provider. A record provider is used to find records for use in deployment and execution\n * transactions on the Aleo Network. A default implementation is provided by the NetworkRecordProvider class. However,\n * a custom implementation can be provided (say if records are synced locally to a database from the network) by\n * implementing this interface.\n */\ninterface RecordProvider {\n account: Account\n\n /**\n * Find a credits.aleo record with a given number of microcredits from the chosen provider\n *\n * @param {number} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // A class implementing record provider can be used to find a record with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, its nonce should be added to the nonces array so that it is not\n * // found again if a subsequent search is performed\n * const record2 = await recordProvider.findCreditsRecord(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n findCreditsRecord(microcredits: number, unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find a list of credit.aleo records with a given number of microcredits from the chosen provider\n *\n * @param {number} microcreditAmounts A list of separate microcredit amounts to search for (e.g. [5000, 100000])\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} A list of records with a value greater or equal to the amounts specified if such records exist, otherwise an error\n *\n * @example\n * // A class implementing record provider can be used to find a record with a given number of microcredits\n * const records = await recordProvider.findCreditsRecords([5000, 5000], true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces array so that it is not\n * // found again if a subsequent search is performed\n * const nonces = [];\n * records.forEach(record => { nonces.push(record.nonce()) });\n * const records2 = await recordProvider.findCreditsRecord(5000, true, nonces);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n findCreditsRecords(microcreditAmounts: number[], unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find an arbitrary record\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // The RecordSearchParams interface can be used to create parameters for custom record searches which can then\n * // be passed to the record provider. An example of how this would be done for the credits.aleo program is shown\n * // below.\n *\n * class CustomRecordSearch implements RecordSearchParams {\n * startHeight: number;\n * endHeight: number;\n * amount: number;\n * program: string;\n * recordName: string;\n * constructor(startHeight: number, endHeight: number, credits: number, maxRecords: number, programName: string, recordName: string) {\n * this.startHeight = startHeight;\n * this.endHeight = endHeight;\n * this.amount = amount;\n * this.program = programName;\n * this.recordName = recordName;\n * }\n * }\n *\n * const params = new CustomRecordSearch(0, 100, 5000, \"credits.aleo\", \"credits\");\n *\n * const record = await recordProvider.findRecord(true, [], params);\n */\n findRecord(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find multiple records from arbitrary programs\n *\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * // The RecordSearchParams interface can be used to create parameters for custom record searches which can then\n * // be passed to the record provider. An example of how this would be done for the credits.aleo program is shown\n * // below.\n *\n * class CustomRecordSearch implements RecordSearchParams {\n * startHeight: number;\n * endHeight: number;\n * amount: number;\n * maxRecords: number;\n * programName: string;\n * recordName: string;\n * constructor(startHeight: number, endHeight: number, credits: number, maxRecords: number, programName: string, recordName: string) {\n * this.startHeight = startHeight;\n * this.endHeight = endHeight;\n * this.amount = amount;\n * this.maxRecords = maxRecords;\n * this.programName = programName;\n * this.recordName = recordName;\n * }\n * }\n *\n * const params = new CustomRecordSearch(0, 100, 5000, 2, \"credits.aleo\", \"credits\");\n * const records = await recordProvider.findRecord(true, [], params);\n */\n findRecords(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n}\n\n/**\n * A record provider implementation that uses the official Aleo API to find records for usage in program execution and\n * deployment, wallet functionality, and other use cases.\n */\nclass NetworkRecordProvider implements RecordProvider {\n account: Account;\n networkClient: AleoNetworkClient;\n constructor(account: Account, networkClient: AleoNetworkClient) {\n this.account = account;\n this.networkClient = networkClient;\n }\n\n /**\n * Set the account used to search for records\n *\n * @param {Account} account The account to use for searching for records\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Find a list of credit records with a given number of microcredits by via the official Aleo API\n *\n * @param {number[]} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces parameter so that it is not\n * // found again if a subsequent search is performed\n * const records = await recordProvider.findCreditsRecords(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * */\n async findCreditsRecords(microcredits: number[], unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n let startHeight = 0;\n let endHeight = 0;\n\n if (searchParameters) {\n if (\"startHeight\" in searchParameters && typeof searchParameters[\"endHeight\"] == \"number\") {\n startHeight = searchParameters[\"startHeight\"];\n }\n\n if (\"endHeight\" in searchParameters && typeof searchParameters[\"endHeight\"] == \"number\") {\n endHeight = searchParameters[\"endHeight\"];\n }\n }\n\n // If the end height is not specified, use the current block height\n if (endHeight == 0) {\n const end = await this.networkClient.getLatestHeight();\n endHeight = end;\n }\n\n // If the start height is greater than the end height, throw an error\n if (startHeight >= endHeight) {\n logAndThrow(\"Start height must be less than end height\");\n }\n\n return await this.networkClient.findUnspentRecords(startHeight, endHeight, this.account.privateKey(), microcredits, undefined, nonces);\n }\n\n /**\n * Find a credit record with a given number of microcredits by via the official Aleo API\n *\n * @param {number} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces parameter so that it is not\n * // found again if a subsequent search is performed\n * const records = await recordProvider.findCreditsRecords(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n async findCreditsRecord(microcredits: number, unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n let records = null;\n\n try {\n records = await this.findCreditsRecords([microcredits], unspent, nonces, searchParameters);\n } catch (e) {}\n\n if (records && records.length > 0) {\n return records[0];\n }\n\n console.error(\"Record not found with error:\", records);\n throw new Error(\"Record not found\");\n }\n\n /**\n * Find an arbitrary record. WARNING: This function is not implemented yet and will throw an error.\n */\n async findRecord(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n throw new Error(\"Method not implemented.\");\n }\n\n /**\n * Find multiple arbitrary records. WARNING: This function is not implemented yet and will throw an error.\n */\n async findRecords(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n throw new Error(\"Method not implemented.\");\n }\n\n}\n\n/**\n * BlockHeightSearch is a RecordSearchParams implementation that allows for searching for records within a given\n * block height range.\n *\n * @example\n * // Create a new BlockHeightSearch\n * const params = new BlockHeightSearch(89995, 99995);\n *\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits and the block height search\n * // can be used to find records within a given block height range\n * const record = await recordProvider.findCreditsRecord(5000, true, [], params);\n *\n */\nclass BlockHeightSearch implements RecordSearchParams {\n startHeight: number;\n endHeight: number;\n constructor(startHeight: number, endHeight: number) {\n this.startHeight = startHeight;\n this.endHeight = endHeight;\n }\n}\n\nexport { BlockHeightSearch, NetworkRecordProvider, RecordProvider, RecordSearchParams};\n","// Experimental example where SDK manages worker\n\nimport { wrap } from \"comlink\";\nimport { WorkerAPI } from './worker';\n\nlet singletonWorker: WorkerAPI | null = null;\n\nconst createAleoWorker = (): WorkerAPI => {\n if (!singletonWorker) {\n const worker = new Worker(new URL(\"worker.js\", import.meta.url), {\n type: \"module\",\n });\n singletonWorker = wrap(worker);\n }\n return singletonWorker;\n};\n\nexport { createAleoWorker };","import \"./polyfill/shared\";\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport { logAndThrow } from \"./utils\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"./wasm\";\n\nexport { initializeWasm };\n\nexport {\n Key,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n} from \"./constants\";\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n};\n","export function logAndThrow(message: string): never {\n console.error(message);\n throw new Error(message);\n}\n\n\nexport function parseJSON(json: string): any {\n function revive(key: string, value: any, context: any) {\n if (Number.isInteger(value)) {\n return BigInt(context.source);\n\n } else {\n return value;\n }\n }\n\n return JSON.parse(json, revive as any);\n}\n\n\nexport async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post, parseJSON, logAndThrow } from \"./utils\";\nimport { Account } from \"./account\";\nimport { Block } from \"./models/block\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport {\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n} from \"./wasm\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/%%NETWORK%%\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/%%NETWORK%%\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = `Error fetching blocks between ${start} and ${end}.`;\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/block/latest\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return Number(await this.fetchData(\"/block/height/latest\"));\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error: any) {\n logAndThrow(\"Error fetching program imports: \" + error.message);\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error: any) {\n throw new Error(\"Error fetching program imports with error: \" + error.message);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/stateRoot/latest\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error: any) {\n throw new Error(`Error posting transaction. Aleo network response: ${error.message}`);\n }\n } catch (error: any) {\n throw new Error(`Error posting transaction: No response received: ${error.message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {VerifyingKey, Metadata} from \"./wasm\";\n\nexport const KEY_STORE = Metadata.baseUrl();\n\nexport interface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nexport const CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n throw new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nexport const PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\n\nexport const VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\n\nexport const PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\n\nexport const PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\n\nexport const PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\n\nexport const PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\n\nexport const PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n","import {\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n} from \"./constants\";\n\nimport {\n ProvingKey,\n VerifyingKey,\n} from \"./wasm\";\n\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error: any) {\n throw new Error(\"Error fetching data.\" + error.message);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n throw new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n return this.fetchCreditsKeys(key);\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw new Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error: any) {\n throw new Error(`Error: fetching credits.aleo keys: ${error.message}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner: any) {\n throw new Error(\"Invalid verifying key. Error: \" + inner.message);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\n\nimport {\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\n\nimport {\n ExecutionResponse,\n Execution as FunctionExecution,\n OfflineQuery,\n RecordPlaintext,\n PrivateKey,\n Program,\n ProvingKey,\n VerifyingKey,\n Transaction,\n ProgramManager as WasmProgramManager,\n verifyFunctionExecution,\n} from \"./wasm\";\n\nimport {\n CREDITS_PROGRAM_KEYS,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n} from \"./constants\";\n\nimport { logAndThrow } from \"./utils\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.provable.com/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n\n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e: any) {\n logAndThrow(`Error validating program: ${e.message}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e: any) {\n logAndThrow(`Error finding ${programName}. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e: any) {\n logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e: any) {\n logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e: any) {\n logAndThrow(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program} The program object\n */\n createProgramFromSource(program: string): Program {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","function spawnWorker(url, module, memory, address) {\n return new Promise((resolve) => {\n const worker = new Worker(url, {\n type: \"module\",\n });\n\n worker.addEventListener(\"message\", (event) => {\n // This is needed in Node to wait one extra tick, so that way\n // the Worker can fully initialize before we return.\n setTimeout(() => {\n resolve(worker);\n\n // When running in Node, this allows the process to exit\n // even though the Worker is still running.\n if (worker.unref) {\n worker.unref();\n }\n }, 0);\n }, {\n capture: true,\n once: true,\n });\n\n worker.postMessage({\n module,\n memory,\n address,\n });\n });\n }\n\nlet wasm;\n\nconst heap = new Array(128).fill(undefined);\n\nheap.push(undefined, null, true, false);\n\nfunction getObject(idx) { return heap[idx]; }\n\nlet heap_next = heap.length;\n\nfunction dropObject(idx) {\n if (idx < 132) return;\n heap[idx] = heap_next;\n heap_next = idx;\n}\n\nfunction takeObject(idx) {\n const ret = getObject(idx);\n dropObject(idx);\n return ret;\n}\n\nconst cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );\n\nif (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); }\nlet cachedUint8Memory0 = null;\n\nfunction getUint8Memory0() {\n if (cachedUint8Memory0 === null || cachedUint8Memory0.buffer !== wasm.memory.buffer) {\n cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);\n }\n return cachedUint8Memory0;\n}\n\nfunction getStringFromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return cachedTextDecoder.decode(getUint8Memory0().slice(ptr, ptr + len));\n}\n\nfunction addHeapObject(obj) {\n if (heap_next === heap.length) heap.push(heap.length + 1);\n const idx = heap_next;\n heap_next = heap[idx];\n\n heap[idx] = obj;\n return idx;\n}\n\nlet WASM_VECTOR_LEN = 0;\n\nconst cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );\n\nconst encodeString = function (arg, view) {\n const buf = cachedTextEncoder.encode(arg);\n view.set(buf);\n return {\n read: arg.length,\n written: buf.length\n };\n};\n\nfunction passStringToWasm0(arg, malloc, realloc) {\n\n if (realloc === undefined) {\n const buf = cachedTextEncoder.encode(arg);\n const ptr = malloc(buf.length, 1) >>> 0;\n getUint8Memory0().subarray(ptr, ptr + buf.length).set(buf);\n WASM_VECTOR_LEN = buf.length;\n return ptr;\n }\n\n let len = arg.length;\n let ptr = malloc(len, 1) >>> 0;\n\n const mem = getUint8Memory0();\n\n let offset = 0;\n\n for (; offset < len; offset++) {\n const code = arg.charCodeAt(offset);\n if (code > 0x7F) break;\n mem[ptr + offset] = code;\n }\n\n if (offset !== len) {\n if (offset !== 0) {\n arg = arg.slice(offset);\n }\n ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;\n const view = getUint8Memory0().subarray(ptr + offset, ptr + len);\n const ret = encodeString(arg, view);\n\n offset += ret.written;\n ptr = realloc(ptr, len, offset, 1) >>> 0;\n }\n\n WASM_VECTOR_LEN = offset;\n return ptr;\n}\n\nfunction isLikeNone(x) {\n return x === undefined || x === null;\n}\n\nlet cachedInt32Memory0 = null;\n\nfunction getInt32Memory0() {\n if (cachedInt32Memory0 === null || cachedInt32Memory0.buffer !== wasm.memory.buffer) {\n cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);\n }\n return cachedInt32Memory0;\n}\n\nfunction debugString(val) {\n // primitive types\n const type = typeof val;\n if (type == 'number' || type == 'boolean' || val == null) {\n return `${val}`;\n }\n if (type == 'string') {\n return `\"${val}\"`;\n }\n if (type == 'symbol') {\n const description = val.description;\n if (description == null) {\n return 'Symbol';\n } else {\n return `Symbol(${description})`;\n }\n }\n if (type == 'function') {\n const name = val.name;\n if (typeof name == 'string' && name.length > 0) {\n return `Function(${name})`;\n } else {\n return 'Function';\n }\n }\n // objects\n if (Array.isArray(val)) {\n const length = val.length;\n let debug = '[';\n if (length > 0) {\n debug += debugString(val[0]);\n }\n for(let i = 1; i < length; i++) {\n debug += ', ' + debugString(val[i]);\n }\n debug += ']';\n return debug;\n }\n // Test for built-in\n const builtInMatches = /\\[object ([^\\]]+)\\]/.exec(toString.call(val));\n let className;\n if (builtInMatches.length > 1) {\n className = builtInMatches[1];\n } else {\n // Failed to match the standard '[object ClassName]'\n return toString.call(val);\n }\n if (className == 'Object') {\n // we're a user defined class or Object\n // JSON.stringify avoids problems with cycles, and is generally much\n // easier than looping through ownProperties of `val`.\n try {\n return 'Object(' + JSON.stringify(val) + ')';\n } catch (_) {\n return 'Object';\n }\n }\n // errors\n if (val instanceof Error) {\n return `${val.name}: ${val.message}\\n${val.stack}`;\n }\n // TODO we could test for more things here, like `Set`s and `Map`s.\n return className;\n}\n\nconst CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(state => {\n wasm.__wbindgen_export_3.get(state.dtor)(state.a, state.b);\n});\n\nfunction makeMutClosure(arg0, arg1, dtor, f) {\n const state = { a: arg0, b: arg1, cnt: 1, dtor };\n const real = (...args) => {\n // First up with a closure we increment the internal reference\n // count. This ensures that the Rust closure environment won't\n // be deallocated while we're invoking it.\n state.cnt++;\n const a = state.a;\n state.a = 0;\n try {\n return f(a, state.b, ...args);\n } finally {\n if (--state.cnt === 0) {\n wasm.__wbindgen_export_3.get(state.dtor)(a, state.b);\n CLOSURE_DTORS.unregister(state);\n } else {\n state.a = a;\n }\n }\n };\n real.original = state;\n CLOSURE_DTORS.register(real, state, state);\n return real;\n}\nfunction __wbg_adapter_34(arg0, arg1, arg2) {\n wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6a363ba3fe56b221(arg0, arg1, addHeapObject(arg2));\n}\n\nfunction _assertClass(instance, klass) {\n if (!(instance instanceof klass)) {\n throw new Error(`expected instance of ${klass.name}`);\n }\n return instance.ptr;\n}\n\nfunction passArray8ToWasm0(arg, malloc) {\n const ptr = malloc(arg.length * 1, 1) >>> 0;\n getUint8Memory0().set(arg, ptr / 1);\n WASM_VECTOR_LEN = arg.length;\n return ptr;\n}\n/**\n* Verify an execution with a single function and a single transition. Executions with multiple\n* transitions or functions will fail to verify. Also, this does not verify that the state root of\n* the execution is included in the Aleo Network ledger.\n*\n* @param {Execution} execution The function execution to verify\n* @param {VerifyingKey} verifying_key The verifying key for the function\n* @param {Program} program The program that the function execution belongs to\n* @param {String} function_id The name of the function that was executed\n* @returns {boolean} True if the execution is valid, false otherwise\n* @param {Execution} execution\n* @param {VerifyingKey} verifying_key\n* @param {Program} program\n* @param {string} function_id\n* @returns {boolean}\n*/\nfunction verifyFunctionExecution(execution, verifying_key, program, function_id) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(execution, Execution);\n _assertClass(verifying_key, VerifyingKey);\n _assertClass(program, Program);\n const ptr0 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyFunctionExecution(retptr, execution.__wbg_ptr, verifying_key.__wbg_ptr, program.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return r0 !== 0;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n}\n\nlet cachedBigInt64Memory0 = null;\n\nfunction getBigInt64Memory0() {\n if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.buffer !== wasm.memory.buffer) {\n cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);\n }\n return cachedBigInt64Memory0;\n}\n\nfunction getArrayU8FromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);\n}\n/**\n* @param {number} receiver\n*/\nfunction runRayonThread(receiver) {\n wasm.runRayonThread(receiver);\n}\n\n/**\n* @param {URL} url\n* @param {number} num_threads\n* @returns {Promise}\n*/\nfunction initThreadPool(url, num_threads) {\n const ret = wasm.initThreadPool(addHeapObject(url), num_threads);\n return takeObject(ret);\n}\n\nfunction handleError(f, args) {\n try {\n return f.apply(this, args);\n } catch (e) {\n wasm.__wbindgen_exn_store(addHeapObject(e));\n }\n}\nfunction __wbg_adapter_282(arg0, arg1, arg2, arg3) {\n wasm.wasm_bindgen__convert__closures__invoke2_mut__h3c510d875601a93b(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));\n}\n\nconst AddressFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_address_free(ptr >>> 0));\n/**\n* Public address of an Aleo account\n*/\nclass Address {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Address.prototype);\n obj.__wbg_ptr = ptr;\n AddressFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n AddressFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_address_free(ptr);\n }\n /**\n * Derive an Aleo address from a private key\n *\n * @param {PrivateKey} private_key The private key to derive the address from\n * @returns {Address} Address corresponding to the private key\n * @param {PrivateKey} private_key\n * @returns {Address}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.address_from_private_key(private_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Derive an Aleo address from a view key\n *\n * @param {ViewKey} view_key The view key to derive the address from\n * @returns {Address} Address corresponding to the view key\n * @param {ViewKey} view_key\n * @returns {Address}\n */\n static from_view_key(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.address_from_view_key(view_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Create an aleo address object from a string representation of an address\n *\n * @param {string} address String representation of an addressm\n * @returns {Address} Address\n * @param {string} address\n * @returns {Address}\n */\n static from_string(address) {\n const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.address_from_string(ptr0, len0);\n return Address.__wrap(ret);\n }\n /**\n * Get a string representation of an Aleo address object\n *\n * @param {Address} Address\n * @returns {string} String representation of the address\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.address_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Verify a signature for a message signed by the address\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {boolean} Boolean representing whether or not the signature is valid\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n */\n verify(message, signature) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n _assertClass(signature, Signature);\n const ret = wasm.address_verify(this.__wbg_ptr, ptr0, len0, signature.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst ExecutionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_execution_free(ptr >>> 0));\n/**\n* Execution of an Aleo program.\n*/\nclass Execution {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Execution.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_execution_free(ptr);\n }\n /**\n * Returns the string representation of the execution.\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.execution_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates an execution object from a string representation of an execution.\n * @param {string} execution\n * @returns {Execution}\n */\n static fromString(execution) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(execution, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.execution_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Execution.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ExecutionResponseFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_executionresponse_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo function execution response\n*\n* This object is returned by the execution of an Aleo function off-chain. It provides methods for\n* retrieving the outputs of the function execution.\n*/\nclass ExecutionResponse {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ExecutionResponse.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionResponseFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionResponseFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_executionresponse_free(ptr);\n }\n /**\n * Get the outputs of the executed function\n *\n * @returns {Array} Array of strings representing the outputs of the function\n * @returns {Array}\n */\n getOutputs() {\n const ret = wasm.executionresponse_getOutputs(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Returns the execution object if present, null if otherwise.\n *\n * @returns {Execution | undefined} The execution object if present, null if otherwise\n * @returns {Execution | undefined}\n */\n getExecution() {\n const ret = wasm.executionresponse_getExecution(this.__wbg_ptr);\n return ret === 0 ? undefined : Execution.__wrap(ret);\n }\n /**\n * Returns the program keys if present\n * @returns {KeyPair}\n */\n getKeys() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getKeys(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return KeyPair.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the proving_key if the proving key was cached in the Execution response.\n * Note the proving key is removed from the response object after the first call to this\n * function. Subsequent calls will return null.\n *\n * @returns {ProvingKey | undefined} The proving key\n * @returns {ProvingKey | undefined}\n */\n getProvingKey() {\n const ret = wasm.executionresponse_getProvingKey(this.__wbg_ptr);\n return ret === 0 ? undefined : ProvingKey.__wrap(ret);\n }\n /**\n * Returns the verifying_key associated with the program\n *\n * @returns {VerifyingKey} The verifying key\n * @returns {VerifyingKey}\n */\n getVerifyingKey() {\n const ret = wasm.executionresponse_getVerifyingKey(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the function identifier\n * @returns {string}\n */\n getFunctionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getFunctionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the program\n * @returns {Program}\n */\n getProgram() {\n const ret = wasm.executionresponse_getProgram(this.__wbg_ptr);\n return Program.__wrap(ret);\n }\n}\n\nconst FieldFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_field_free(ptr >>> 0));\n/**\n*/\nclass Field {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Field.prototype);\n obj.__wbg_ptr = ptr;\n FieldFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n FieldFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_field_free(ptr);\n }\n /**\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.field_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} field\n * @returns {Field}\n */\n static fromString(field) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(field, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.field_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst KeyPairFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_keypair_free(ptr >>> 0));\n/**\n* Key pair object containing both the function proving and verifying keys\n*/\nclass KeyPair {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(KeyPair.prototype);\n obj.__wbg_ptr = ptr;\n KeyPairFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n KeyPairFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_keypair_free(ptr);\n }\n /**\n * Create new key pair from proving and verifying keys\n *\n * @param {ProvingKey} proving_key Proving key corresponding to a function in an Aleo program\n * @param {VerifyingKey} verifying_key Verifying key corresponding to a function in an Aleo program\n * @returns {KeyPair} Key pair object containing both the function proving and verifying keys\n * @param {ProvingKey} proving_key\n * @param {VerifyingKey} verifying_key\n */\n constructor(proving_key, verifying_key) {\n _assertClass(proving_key, ProvingKey);\n var ptr0 = proving_key.__destroy_into_raw();\n _assertClass(verifying_key, VerifyingKey);\n var ptr1 = verifying_key.__destroy_into_raw();\n const ret = wasm.keypair_new(ptr0, ptr1);\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get the proving key. This method will remove the proving key from the key pair\n *\n * @returns {ProvingKey}\n * @returns {ProvingKey}\n */\n provingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_provingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the verifying key. This method will remove the verifying key from the key pair\n *\n * @returns {VerifyingKey}\n * @returns {VerifyingKey}\n */\n verifyingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst MetadataFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_metadata_free(ptr >>> 0));\n/**\n*/\nclass Metadata {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Metadata.prototype);\n obj.__wbg_ptr = ptr;\n MetadataFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n MetadataFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_metadata_free(ptr);\n }\n /**\n * @returns {string}\n */\n get name() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_name(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set name(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_name(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get locator() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_locator(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set locator(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_locator(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get prover() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_prover(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set prover(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_prover(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifier() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifier(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifier(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifier(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifyingKey() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifyingKey(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifyingKey(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n static baseUrl() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.metadata_baseUrl(retptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @returns {Metadata}\n */\n static bond_public() {\n const ret = wasm.metadata_bond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static bond_validator() {\n const ret = wasm.metadata_bond_validator();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static claim_unbond_public() {\n const ret = wasm.metadata_claim_unbond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_private() {\n const ret = wasm.metadata_fee_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_public() {\n const ret = wasm.metadata_fee_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static inclusion() {\n const ret = wasm.metadata_inclusion();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static join() {\n const ret = wasm.metadata_join();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static set_validator_state() {\n const ret = wasm.metadata_set_validator_state();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static split() {\n const ret = wasm.metadata_split();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private() {\n const ret = wasm.metadata_transfer_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private_to_public() {\n const ret = wasm.metadata_transfer_private_to_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public() {\n const ret = wasm.metadata_transfer_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_as_signer() {\n const ret = wasm.metadata_transfer_public_as_signer();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_to_private() {\n const ret = wasm.metadata_transfer_public_to_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static unbond_public() {\n const ret = wasm.metadata_unbond_public();\n return Metadata.__wrap(ret);\n }\n}\n\nconst OfflineQueryFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_offlinequery_free(ptr >>> 0));\n/**\n* An offline query object used to insert the global state root and state paths needed to create\n* a valid inclusion proof offline.\n*/\nclass OfflineQuery {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(OfflineQuery.prototype);\n obj.__wbg_ptr = ptr;\n OfflineQueryFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n OfflineQueryFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_offlinequery_free(ptr);\n }\n /**\n * Creates a new offline query object. The state root is required to be passed in as a string\n * @param {number} block_height\n * @param {string} state_root\n */\n constructor(block_height, state_root) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(state_root, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_new(retptr, block_height, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n this.__wbg_ptr = r0 >>> 0;\n return this;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Add a new block height to the offline query object.\n * @param {number} block_height\n */\n addBlockHeight(block_height) {\n wasm.offlinequery_addBlockHeight(this.__wbg_ptr, block_height);\n }\n /**\n * Add a new state path to the offline query object.\n *\n * @param {string} commitment: The commitment corresponding to a record inpout\n * @param {string} state_path: The state path corresponding to the commitment\n * @param {string} commitment\n * @param {string} state_path\n */\n addStatePath(commitment, state_path) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(commitment, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(state_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.offlinequery_addStatePath(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n if (r1) {\n throw takeObject(r0);\n }\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a json string representation of the offline query object\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.offlinequery_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create an offline query object from a json string representation\n * @param {string} s\n * @returns {OfflineQuery}\n */\n static fromString(s) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(s, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return OfflineQuery.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekey_free(ptr >>> 0));\n/**\n* Private key of an Aleo account\n*/\nclass PrivateKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKey.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekey_free(ptr);\n }\n /**\n * Generate a new private key using a cryptographically secure random number generator\n *\n * @returns {PrivateKey}\n */\n constructor() {\n const ret = wasm.privatekey_new();\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get a private key from a series of unchecked bytes\n *\n * @param {Uint8Array} seed Unchecked 32 byte long Uint8Array acting as the seed for the private key\n * @returns {PrivateKey}\n * @param {Uint8Array} seed\n * @returns {PrivateKey}\n */\n static from_seed_unchecked(seed) {\n const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_from_seed_unchecked(ptr0, len0);\n return PrivateKey.__wrap(ret);\n }\n /**\n * Get a private key from a string representation of a private key\n *\n * @param {string} seed String representation of a private key\n * @returns {PrivateKey}\n * @param {string} private_key\n * @returns {PrivateKey}\n */\n static from_string(private_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(private_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_from_string(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the private key. This function should be used very carefully\n * as it exposes the private key plaintext\n *\n * @returns {string} String representation of a private key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the view key corresponding to the private key\n *\n * @returns {ViewKey}\n * @returns {ViewKey}\n */\n to_view_key() {\n const ret = wasm.privatekey_to_view_key(this.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get the address corresponding to the private key\n *\n * @returns {Address}\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.privatekey_to_address(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Sign a message with the private key\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {Signature} Signature generated by signing the message with the address\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n sign(message) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(this.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a new randomly generated private key ciphertext using a secret. The secret is sensitive\n * and will be needed to decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static newEncrypted(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_newEncrypted(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Encrypt an existing private key with a secret. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n toCiphertext(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get private key from a private key ciphertext and secret originally used to encrypt it\n *\n * @param {PrivateKeyCiphertext} ciphertext Ciphertext representation of the private key\n * @param {string} secret Secret originally used to encrypt the private key\n * @returns {PrivateKey} Private key\n * @param {PrivateKeyCiphertext} ciphertext\n * @param {string} secret\n * @returns {PrivateKey}\n */\n static fromPrivateKeyCiphertext(ciphertext, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(ciphertext, PrivateKeyCiphertext);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_fromPrivateKeyCiphertext(retptr, ciphertext.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekeyciphertext_free(ptr >>> 0));\n/**\n* Private Key in ciphertext form\n*/\nclass PrivateKeyCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKeyCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekeyciphertext_free(ptr);\n }\n /**\n * Encrypt a private key using a secret string. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {PrivateKey} private_key Private key to encrypt\n * @param {string} secret Secret to encrypt the private key with\n * @returns {PrivateKeyCiphertext} Private key ciphertext\n * @param {PrivateKey} private_key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static encryptPrivateKey(private_key, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, private_key.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Decrypts a private ciphertext using a secret string. This must be the same secret used to\n * encrypt the private key\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKey} Private key\n * @param {string} secret\n * @returns {PrivateKey}\n */\n decryptToPrivateKey(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_decryptToPrivateKey(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the ciphertext string\n *\n * @returns {string} Ciphertext string\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekeyciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates a PrivateKeyCiphertext from a string\n *\n * @param {string} ciphertext Ciphertext string\n * @returns {PrivateKeyCiphertext} Private key ciphertext\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n */\n static fromString(ciphertext) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ProgramFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_program_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo program\n*/\nclass Program {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Program.prototype);\n obj.__wbg_ptr = ptr;\n ProgramFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_program_free(ptr);\n }\n /**\n * Create a program from a program string\n *\n * @param {string} program Aleo program source code\n * @returns {Program} Program object\n * @param {string} program\n * @returns {Program}\n */\n static fromString(program) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Program.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the program\n *\n * @returns {string} String containing the program source code\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Determine if a function is present in the program\n *\n * @param {string} functionName Name of the function to check for\n * @returns {boolean} True if the program is valid, false otherwise\n * @param {string} function_name\n * @returns {boolean}\n */\n hasFunction(function_name) {\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.program_hasFunction(this.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get javascript array of functions names in the program\n *\n * @returns {Array} Array of all function names present in the program\n *\n * @example\n * const expected_functions = [\n * \"mint\",\n * \"transfer_private\",\n * \"transfer_private_to_public\",\n * \"transfer_public\",\n * \"transfer_public_to_private\",\n * \"join\",\n * \"split\",\n * \"fee\"\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_functions = credits_program.getFunctions();\n * console.log(credits_functions === expected_functions); // Output should be \"true\"\n * @returns {Array}\n */\n getFunctions() {\n const ret = wasm.program_getFunctions(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Get a javascript object representation of the function inputs and types. This can be used\n * to generate a web form to capture user inputs for an execution of a function.\n *\n * @param {string} function_name Name of the function to get inputs for\n * @returns {Array} Array of function inputs\n *\n * @example\n * const expected_inputs = [\n * {\n * type:\"record\",\n * visibility:\"private\",\n * record:\"credits\",\n * members:[\n * {\n * name:\"microcredits\",\n * type:\"u64\",\n * visibility:\"private\"\n * }\n * ],\n * register:\"r0\"\n * },\n * {\n * type:\"address\",\n * visibility:\"private\",\n * register:\"r1\"\n * },\n * {\n * type:\"u64\",\n * visibility:\"private\",\n * register:\"r2\"\n * }\n * ];\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const transfer_function_inputs = credits_program.getFunctionInputs(\"transfer_private\");\n * console.log(transfer_function_inputs === expected_inputs); // Output should be \"true\"\n * @param {string} function_name\n * @returns {Array}\n */\n getFunctionInputs(function_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getFunctionInputs(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a the list of a program's mappings and the names/types of their keys and values.\n *\n * @returns {Array} - An array of objects representing the mappings in the program\n * @example\n * const expected_mappings = [\n * {\n * name: \"account\",\n * key_name: \"owner\",\n * key_type: \"address\",\n * value_name: \"microcredits\",\n * value_type: \"u64\"\n * }\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_mappings = credits_program.getMappings();\n * console.log(credits_mappings === expected_mappings); // Output should be \"true\"\n * @returns {Array}\n */\n getMappings() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_getMappings(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program record and its types\n *\n * @param {string} record_name Name of the record to get members for\n * @returns {Object} Object containing the record name, type, and members\n *\n * @example\n *\n * const expected_record = {\n * type: \"record\",\n * record: \"Credits\",\n * members: [\n * {\n * name: \"owner\",\n * type: \"address\",\n * visibility: \"private\"\n * },\n * {\n * name: \"microcredits\",\n * type: \"u64\",\n * visibility: \"private\"\n * }\n * ];\n * };\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_record = credits_program.getRecordMembers(\"Credits\");\n * console.log(credits_record === expected_record); // Output should be \"true\"\n * @param {string} record_name\n * @returns {object}\n */\n getRecordMembers(record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getRecordMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program struct and its types\n *\n * @param {string} struct_name Name of the struct to get members for\n * @returns {Array} Array containing the struct members\n *\n * @example\n *\n * const STRUCT_PROGRAM = \"program token_issue.aleo;\n *\n * struct token_metadata:\n * network as u32;\n * version as u32;\n *\n * struct token:\n * token_id as u32;\n * metadata as token_metadata;\n *\n * function no_op:\n * input r0 as u64;\n * output r0 as u64;\"\n *\n * const expected_struct_members = [\n * {\n * name: \"token_id\",\n * type: \"u32\",\n * },\n * {\n * name: \"metadata\",\n * type: \"struct\",\n * struct_id: \"token_metadata\",\n * members: [\n * {\n * name: \"network\",\n * type: \"u32\",\n * }\n * {\n * name: \"version\",\n * type: \"u32\",\n * }\n * ]\n * }\n * ];\n *\n * const program = aleo_wasm.Program.fromString(STRUCT_PROGRAM);\n * const struct_members = program.getStructMembers(\"token\");\n * console.log(struct_members === expected_struct_members); // Output should be \"true\"\n * @param {string} struct_name\n * @returns {Array}\n */\n getStructMembers(struct_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(struct_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getStructMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the credits.aleo program\n *\n * @returns {Program} The credits.aleo program\n * @returns {Program}\n */\n static getCreditsProgram() {\n const ret = wasm.program_getCreditsProgram();\n return Program.__wrap(ret);\n }\n /**\n * Get the id of the program\n *\n * @returns {string} The id of the program\n * @returns {string}\n */\n id() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_id(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get a unique address of the program\n *\n * @returns {Address} The address of the program\n * @returns {Address}\n */\n address() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_address(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Address.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determine equality with another program\n *\n * @param {Program} other The other program to compare\n * @returns {boolean} True if the programs are equal, false otherwise\n * @param {Program} other\n * @returns {boolean}\n */\n isEqual(other) {\n _assertClass(other, Program);\n const ret = wasm.program_isEqual(this.__wbg_ptr, other.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get program_imports\n *\n * @returns {Array} The program imports\n *\n * @example\n *\n * const DOUBLE_TEST = \"import multiply_test.aleo;\n *\n * program double_test.aleo;\n *\n * function double_it:\n * input r0 as u32.private;\n * call multiply_test.aleo/multiply 2u32 r0 into r1;\n * output r1 as u32.private;\";\n *\n * const expected_imports = [\n * \"multiply_test.aleo\"\n * ];\n *\n * const program = aleo_wasm.Program.fromString(DOUBLE_TEST_PROGRAM);\n * const imports = program.getImports();\n * console.log(imports === expected_imports); // Output should be \"true\"\n * @returns {Array}\n */\n getImports() {\n const ret = wasm.program_getImports(this.__wbg_ptr);\n return takeObject(ret);\n }\n}\n\nconst ProgramManagerFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_programmanager_free(ptr >>> 0));\n/**\n*/\nclass ProgramManager {\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramManagerFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_programmanager_free(ptr);\n }\n /**\n * Deploy an Aleo program\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being deployed\n * @param imports A javascript object holding the source code of any imported programs in the\n * form \\{\"program_name1\": \"program_source_code\", \"program_name2\": \"program_source_code\", ..\\}.\n * Note that all imported programs must be deployed on chain before the main program in order\n * for the deployment to succeed\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the program deployment in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildDeploymentTransaction(private_key, program, fee_credits, fee_record, url, imports, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n let ptr1 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr1 = fee_record.__destroy_into_raw();\n }\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr3 = fee_proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr4 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildDeploymentTransaction(private_key.__wbg_ptr, ptr0, len0, fee_credits, ptr1, ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the fee for a program deployment\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The source code of the program being deployed\n * @param imports (optional) Provide a list of imports to use for the deployment fee estimation\n * in the form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @returns {u64}\n * @param {string} program\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static estimateDeploymentFee(program, imports) {\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_estimateDeploymentFee(ptr0, len0, isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n /**\n * Estimate the component of the deployment cost which comes from the fee for the program name.\n * Note that this cost does not represent the entire cost of deployment. It is additional to\n * the cost of the size (in bytes) of the deployment.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param name The name of the program to be deployed\n * @returns {u64}\n * @param {string} name\n * @returns {bigint}\n */\n static estimateProgramNameCost(name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateProgramNameCost(retptr, ptr0, len0);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Execute an arbitrary function locally\n *\n * @param {PrivateKey} private_key The private key of the sender\n * @param {string} program The source code of the program being executed\n * @param {string} function The name of the function to execute\n * @param {Array} inputs A javascript array of inputs to the function\n * @param {boolean} prove_execution If true, the execution will be proven and an execution object\n * containing the proof and the encrypted inputs and outputs needed to verify the proof offline\n * will be returned.\n * @param {boolean} cache Cache the proving and verifying keys in the Execution response.\n * If this is set to 'true' the keys synthesized will be stored in the Execution Response\n * and the `ProvingKey` and `VerifyingKey` can be retrieved from the response via the `.getKeys()`\n * method.\n * @param {Object | undefined} imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param {ProvingKey | undefined} proving_key (optional) Provide a verifying key to use for the function execution\n * @param {VerifyingKey | undefined} verifying_key (optional) Provide a verifying key to use for the function execution\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {boolean} prove_execution\n * @param {boolean} cache\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {string | undefined} [url]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static executeFunctionOffline(private_key, program, _function, inputs, prove_execution, cache, imports, proving_key, verifying_key, url, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr2 = proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr3 = verifying_key.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_executeFunctionOffline(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), prove_execution, cache, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr2, ptr3, ptr4, len4, ptr5);\n return takeObject(ret);\n }\n /**\n * Execute Aleo function and create an Aleo execution transaction\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being executed\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * If this is set to 'true' the keys synthesized (or passed in as optional parameters via the\n * `proving_key` and `verifying_key` arguments) will be stored in the ProgramManager's memory\n * and used for subsequent transactions. If this is set to 'false' the proving and verifying\n * keys will be deallocated from memory after the transaction is executed.\n * @param imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the function execution\n * @param verifying_key (optional) Provide a verifying key to use for the function execution\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildExecutionTransaction(private_key, program, _function, inputs, fee_credits, fee_record, url, imports, proving_key, verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr4 = proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr5 = verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildExecutionTransaction(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), fee_credits, ptr2, ptr3, len3, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Estimate Fee for Aleo function execution. Note if \"cache\" is set to true, the proving and\n * verifying keys will be stored in the ProgramManager's memory and used for subsequent\n * program executions.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program to estimate the execution fee for\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the fee estimation in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the fee estimation\n * @param verifying_key (optional) Provide a verifying key to use for the fee estimation\n * @returns {u64} Fee in microcredits\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static estimateExecutionFee(private_key, program, _function, inputs, url, imports, proving_key, verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr3 = proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr4 = verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_estimateExecutionFee(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the finalize fee component for executing a function. This fee is additional to the\n * size of the execution of the program in bytes. If the function does not have a finalize\n * step, then the finalize fee is 0.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The program containing the function to estimate the finalize fee for\n * @param function The function to estimate the finalize fee for\n * @returns {u64} Fee in microcredits\n * @param {string} program\n * @param {string} _function\n * @returns {bigint}\n */\n static estimateFinalizeFee(program, _function) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateFinalizeFee(retptr, ptr0, len0, ptr1, len1);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Join two records together to create a new record with an amount of credits equal to the sum\n * of the credits of the two original records\n *\n * @param private_key The private key of the sender\n * @param record_1 The first record to combine\n * @param record_2 The second record to combine\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param join_proving_key (optional) Provide a proving key to use for the join function\n * @param join_verifying_key (optional) Provide a verifying key to use for the join function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction} Transaction object\n * @param {PrivateKey} private_key\n * @param {RecordPlaintext} record_1\n * @param {RecordPlaintext} record_2\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [join_proving_key]\n * @param {VerifyingKey | undefined} [join_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildJoinTransaction(private_key, record_1, record_2, fee_credits, fee_record, url, join_proving_key, join_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(record_1, RecordPlaintext);\n var ptr0 = record_1.__destroy_into_raw();\n _assertClass(record_2, RecordPlaintext);\n var ptr1 = record_2.__destroy_into_raw();\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(join_proving_key)) {\n _assertClass(join_proving_key, ProvingKey);\n ptr4 = join_proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(join_verifying_key)) {\n _assertClass(join_verifying_key, VerifyingKey);\n ptr5 = join_verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildJoinTransaction(private_key.__wbg_ptr, ptr0, ptr1, fee_credits, ptr2, ptr3, len3, ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Split an Aleo credits record into two separate records. This function does not require a fee.\n *\n * @param private_key The private key of the sender\n * @param split_amount The amount of the credit split. This amount will be subtracted from the\n * value of the record and two new records will be created with the split amount and the remainder\n * @param amount_record The record to split\n * @param url The url of the Aleo network node to send the transaction to\n * @param split_proving_key (optional) Provide a proving key to use for the split function\n * @param split_verifying_key (optional) Provide a verifying key to use for the split function\n * @returns {Transaction} Transaction object\n * @param {PrivateKey} private_key\n * @param {number} split_amount\n * @param {RecordPlaintext} amount_record\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [split_proving_key]\n * @param {VerifyingKey | undefined} [split_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildSplitTransaction(private_key, split_amount, amount_record, url, split_proving_key, split_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(amount_record, RecordPlaintext);\n var ptr0 = amount_record.__destroy_into_raw();\n var ptr1 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(split_proving_key)) {\n _assertClass(split_proving_key, ProvingKey);\n ptr2 = split_proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(split_verifying_key)) {\n _assertClass(split_verifying_key, VerifyingKey);\n ptr3 = split_verifying_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr4 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildSplitTransaction(private_key.__wbg_ptr, split_amount, ptr0, ptr1, len1, ptr2, ptr3, ptr4);\n return takeObject(ret);\n }\n /**\n * Send credits from one Aleo account to another\n *\n * @param private_key The private key of the sender\n * @param amount_credits The amount of credits to send\n * @param recipient The recipient of the transaction\n * @param transfer_type The type of the transfer (options: \"private\", \"public\", \"private_to_public\", \"public_to_private\")\n * @param amount_record The record to fund the amount from\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param transfer_verifying_key (optional) Provide a verifying key to use for the transfer\n * function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {number} amount_credits\n * @param {string} recipient\n * @param {string} transfer_type\n * @param {RecordPlaintext | undefined} amount_record\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [transfer_proving_key]\n * @param {VerifyingKey | undefined} [transfer_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildTransferTransaction(private_key, amount_credits, recipient, transfer_type, amount_record, fee_credits, fee_record, url, transfer_proving_key, transfer_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(recipient, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(transfer_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(amount_record)) {\n _assertClass(amount_record, RecordPlaintext);\n ptr2 = amount_record.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr3 = fee_record.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(transfer_proving_key)) {\n _assertClass(transfer_proving_key, ProvingKey);\n ptr5 = transfer_proving_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(transfer_verifying_key)) {\n _assertClass(transfer_verifying_key, VerifyingKey);\n ptr6 = transfer_verifying_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr7 = fee_proving_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr8 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr9 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr9 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildTransferTransaction(private_key.__wbg_ptr, amount_credits, ptr0, len0, ptr1, len1, ptr2, fee_credits, ptr3, ptr4, len4, ptr5, ptr6, ptr7, ptr8, ptr9);\n return takeObject(ret);\n }\n /**\n * Synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code of the program to synthesize keys for\n * @param function_id {string} The function to synthesize keys for\n * @param inputs {Array} The inputs to the function\n * @param imports {Object | undefined} The imports for the program\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} function_id\n * @param {Array} inputs\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static synthesizeKeyPair(private_key, program, function_id, inputs, imports) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_synthesizeKeyPair(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n}\n\nconst ProvingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_provingkey_free(ptr >>> 0));\n/**\n* Proving key for a function within an Aleo program\n*/\nclass ProvingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ProvingKey.prototype);\n obj.__wbg_ptr = ptr;\n ProvingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProvingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_provingkey_free(ptr);\n }\n /**\n * Verify if the proving key is for the bond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_public_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_public function, false if otherwise\n * @returns {boolean}\n */\n isBondPublicProver() {\n const ret = wasm.provingkey_isBondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the bond_validator function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_validator_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_validator function, false if otherwise\n * @returns {boolean}\n */\n isBondValidatorProver() {\n const ret = wasm.provingkey_isBondValidatorProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the claim_unbond function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"claim_unbond_proving_key.bin\");\n * provingKey.isClaimUnbondProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the claim_unbond function, false if otherwise\n * @returns {boolean}\n */\n isClaimUnbondPublicProver() {\n const ret = wasm.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_private_proving_key.bin\");\n * provingKey.isFeePrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_private function, false if otherwise\n * @returns {boolean}\n */\n isFeePrivateProver() {\n const ret = wasm.provingkey_isFeePrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_public_proving_key.bin\");\n * provingKey.isFeePublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_public function, false if otherwise\n * @returns {boolean}\n */\n isFeePublicProver() {\n const ret = wasm.provingkey_isFeePublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the inclusion function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"inclusion_proving_key.bin\");\n * provingKey.isInclusionProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the inclusion function, false if otherwise\n * @returns {boolean}\n */\n isInclusionProver() {\n const ret = wasm.provingkey_isInclusionProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the join function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"join_proving_key.bin\");\n * provingKey.isJoinProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the join function, false if otherwise\n * @returns {boolean}\n */\n isJoinProver() {\n const ret = wasm.provingkey_isJoinProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the set_validator_state function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"set_validator_set_proving_key.bin\");\n * provingKey.isSetValidatorStateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the set_validator_state function, false if otherwise\n * @returns {boolean}\n */\n isSetValidatorStateProver() {\n const ret = wasm.provingkey_isSetValidatorStateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the split function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"split_proving_key.bin\");\n * provingKey.isSplitProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the split function, false if otherwise\n * @returns {boolean}\n */\n isSplitProver() {\n const ret = wasm.provingkey_isSplitProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_proving_key.bin\");\n * provingKey.isTransferPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateProver() {\n const ret = wasm.provingkey_isTransferPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private_to_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_to_public_proving_key.bin\");\n * provingKey.isTransferPrivateToPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private_to_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateToPublicProver() {\n const ret = wasm.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_proving_key.bin\");\n * provingKey.isTransferPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicProver() {\n const ret = wasm.provingkey_isTransferPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_as_signer function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_as_signer_proving_key.bin\");\n * provingKey.isTransferPublicAsSignerProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicAsSignerProver() {\n const ret = wasm.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_to_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_to_private_proving_key.bin\");\n * provingKey.isTransferPublicToPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public_to_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicToPrivateProver() {\n const ret = wasm.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the unbond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"unbond_public.bin\");\n * provingKey.isUnbondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the unbond_public_prover function, false if otherwise\n * @returns {boolean}\n */\n isUnbondPublicProver() {\n const ret = wasm.provingkey_isUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Return the checksum of the proving key\n *\n * @returns {string} Checksum of the proving key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the proving key\n *\n * @returns {ProvingKey} A copy of the proving key\n * @returns {ProvingKey}\n */\n copy() {\n const ret = wasm.provingkey_copy(this.__wbg_ptr);\n return ProvingKey.__wrap(ret);\n }\n /**\n * Construct a new proving key from a byte array\n *\n * @param {Uint8Array} bytes Byte array representation of a proving key\n * @returns {ProvingKey}\n * @param {Uint8Array} bytes\n * @returns {ProvingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a proving key from string\n *\n * @param {string} String representation of the proving key\n * @param {string} string\n * @returns {ProvingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the byte representation of a proving key\n *\n * @returns {Uint8Array} Byte array representation of a proving key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the proving key\n *\n * @returns {string} String representation of the proving key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst RecordCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordciphertext_free(ptr >>> 0));\n/**\n* Encrypted Aleo record\n*/\nclass RecordCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n RecordCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordciphertext_free(ptr);\n }\n /**\n * Create a record ciphertext from a string\n *\n * @param {string} record String representation of a record ciphertext\n * @returns {RecordCiphertext} Record ciphertext\n * @param {string} record\n * @returns {RecordCiphertext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the string reprensentation of the record ciphertext\n *\n * @returns {string} String representation of the record ciphertext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Decrypt the record ciphertext into plaintext using the view key. The record will only\n * decrypt if the record was encrypted by the account corresponding to the view key\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {RecordPlaintext} Record plaintext object\n * @param {ViewKey} view_key\n * @returns {RecordPlaintext}\n */\n decrypt(view_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(view_key, ViewKey);\n wasm.recordciphertext_decrypt(retptr, this.__wbg_ptr, view_key.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determines if the account corresponding to the view key is the owner of the record\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {boolean}\n * @param {ViewKey} view_key\n * @returns {boolean}\n */\n isOwner(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.recordciphertext_isOwner(this.__wbg_ptr, view_key.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst RecordPlaintextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordplaintext_free(ptr >>> 0));\n/**\n* Plaintext representation of an Aleo record\n*/\nclass RecordPlaintext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordPlaintext.prototype);\n obj.__wbg_ptr = ptr;\n RecordPlaintextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordPlaintextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordplaintext_free(ptr);\n }\n /**\n * @param {string} program_id\n * @param {string} record_name\n * @returns {Field}\n */\n commitment(program_id, record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_commitment(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return a record plaintext from a string.\n *\n * @param {string} record String representation of a plaintext representation of an Aleo record\n * @returns {RecordPlaintext} Record plaintext\n * @param {string} record\n * @returns {RecordPlaintext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordplaintext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the record plaintext string\n *\n * @returns {string} String representation of the record plaintext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the amount of microcredits in the record\n *\n * @returns {u64} Amount of microcredits in the record\n * @returns {bigint}\n */\n microcredits() {\n const ret = wasm.recordplaintext_microcredits(this.__wbg_ptr);\n return BigInt.asUintN(64, ret);\n }\n /**\n * Returns the nonce of the record. This can be used to uniquely identify a record.\n *\n * @returns {string} Nonce of the record\n * @returns {string}\n */\n nonce() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_nonce(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Attempt to get the serial number of a record to determine whether or not is has been spent\n *\n * @param {PrivateKey} private_key Private key of the account that owns the record\n * @param {string} program_id Program ID of the program that the record is associated with\n * @param {string} record_name Name of the record\n * @returns {string} Serial number of the record\n * @param {PrivateKey} private_key\n * @param {string} program_id\n * @param {string} record_name\n * @returns {string}\n */\n serialNumberString(private_key, program_id, record_name) {\n let deferred4_0;\n let deferred4_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_serialNumberString(retptr, this.__wbg_ptr, private_key.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr3 = r0;\n var len3 = r1;\n if (r3) {\n ptr3 = 0; len3 = 0;\n throw takeObject(r2);\n }\n deferred4_0 = ptr3;\n deferred4_1 = len3;\n return getStringFromWasm0(ptr3, len3);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred4_0, deferred4_1, 1);\n }\n }\n}\n\nconst SignatureFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_signature_free(ptr >>> 0));\n/**\n* Cryptographic signature of a message signed by an Aleo account\n*/\nclass Signature {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Signature.prototype);\n obj.__wbg_ptr = ptr;\n SignatureFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n SignatureFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_signature_free(ptr);\n }\n /**\n * Sign a message with a private key\n *\n * @param {PrivateKey} private_key The private key to sign the message with\n * @param {Uint8Array} message Byte representation of the message to sign\n * @returns {Signature} Signature of the message\n * @param {PrivateKey} private_key\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n static sign(private_key, message) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(private_key.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Verify a signature of a message with an address\n *\n * @param {Address} address The address to verify the signature with\n * @param {Uint8Array} message Byte representation of the message to verify\n * @returns {boolean} True if the signature is valid, false otherwise\n * @param {Address} address\n * @param {Uint8Array} message\n * @returns {boolean}\n */\n verify(address, message) {\n _assertClass(address, Address);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_verify(this.__wbg_ptr, address.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get a signature from a string representation of a signature\n *\n * @param {string} signature String representation of a signature\n * @returns {Signature} Signature\n * @param {string} signature\n * @returns {Signature}\n */\n static from_string(signature) {\n const ptr0 = passStringToWasm0(signature, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_from_string(ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a string representation of a signature\n *\n * @returns {string} String representation of a signature\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.signature_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst TransactionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_transaction_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo transaction\n*\n* This object is created when generating an on-chain function deployment or execution and is the\n* object that should be submitted to the Aleo Network in order to deploy or execute a function.\n*/\nclass Transaction {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Transaction.prototype);\n obj.__wbg_ptr = ptr;\n TransactionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n TransactionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_transaction_free(ptr);\n }\n /**\n * Create a transaction from a string\n *\n * @param {string} transaction String representation of a transaction\n * @returns {Transaction}\n * @param {string} transaction\n * @returns {Transaction}\n */\n static fromString(transaction) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(transaction, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.transaction_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Transaction.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the transaction as a string. If you want to submit this transaction to the Aleo Network\n * this function will create the string that should be submitted in the `POST` data.\n *\n * @returns {string} String representation of the transaction\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the id of the transaction. This is the merkle root of the transaction's inclusion proof.\n *\n * This value can be used to query the status of the transaction on the Aleo Network to see\n * if it was successful. If successful, the transaction will be included in a block and this\n * value can be used to lookup the transaction data on-chain.\n *\n * @returns {string} Transaction id\n * @returns {string}\n */\n transactionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the type of the transaction (will return \"deploy\" or \"execute\")\n *\n * @returns {string} Transaction type\n * @returns {string}\n */\n transactionType() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionType(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst VerifyingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_verifyingkey_free(ptr >>> 0));\n/**\n* Verifying key for a function within an Aleo program\n*/\nclass VerifyingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(VerifyingKey.prototype);\n obj.__wbg_ptr = ptr;\n VerifyingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n VerifyingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_verifyingkey_free(ptr);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {VerifyingKey}\n */\n static bondPublicVerifier() {\n const ret = wasm.verifyingkey_bondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {VerifyingKey}\n */\n static bondValidatorVerifier() {\n const ret = wasm.verifyingkey_bondValidatorVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the claim_delegator function\n *\n * @returns {VerifyingKey} Verifying key for the claim_unbond_public function\n * @returns {VerifyingKey}\n */\n static claimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_claimUnbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_private function\n *\n * @returns {VerifyingKey} Verifying key for the fee_private function\n * @returns {VerifyingKey}\n */\n static feePrivateVerifier() {\n const ret = wasm.verifyingkey_feePrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_public function\n *\n * @returns {VerifyingKey} Verifying key for the fee_public function\n * @returns {VerifyingKey}\n */\n static feePublicVerifier() {\n const ret = wasm.verifyingkey_feePublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the inclusion function\n *\n * @returns {VerifyingKey} Verifying key for the inclusion function\n * @returns {VerifyingKey}\n */\n static inclusionVerifier() {\n const ret = wasm.verifyingkey_inclusionVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the join function\n *\n * @returns {VerifyingKey} Verifying key for the join function\n * @returns {VerifyingKey}\n */\n static joinVerifier() {\n const ret = wasm.verifyingkey_joinVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the set_validator_state function\n *\n * @returns {VerifyingKey} Verifying key for the set_validator_state function\n * @returns {VerifyingKey}\n */\n static setValidatorStateVerifier() {\n const ret = wasm.verifyingkey_setValidatorStateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the split function\n *\n * @returns {VerifyingKey} Verifying key for the split function\n * @returns {VerifyingKey}\n */\n static splitVerifier() {\n const ret = wasm.verifyingkey_splitVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private function\n * @returns {VerifyingKey}\n */\n static transferPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private_to_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private_to_public function\n * @returns {VerifyingKey}\n */\n static transferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_transferPrivateToPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public function\n * @returns {VerifyingKey}\n */\n static transferPublicVerifier() {\n const ret = wasm.verifyingkey_transferPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_as_signer function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_as_signer function\n * @returns {VerifyingKey}\n */\n static transferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_transferPublicAsSignerVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_to_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_to_private function\n * @returns {VerifyingKey}\n */\n static transferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPublicToPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the unbond_public function\n *\n * @returns {VerifyingKey} Verifying key for the unbond_public function\n * @returns {VerifyingKey}\n */\n static unbondPublicVerifier() {\n const ret = wasm.verifyingkey_unbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {boolean}\n */\n isBondPublicVerifier() {\n const ret = wasm.verifyingkey_isBondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {boolean}\n */\n isBondValidatorVerifier() {\n const ret = wasm.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the claim_delegator function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isClaimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePrivateVerifier() {\n const ret = wasm.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePublicVerifier() {\n const ret = wasm.verifyingkey_isFeePublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the inclusion function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isInclusionVerifier() {\n const ret = wasm.verifyingkey_isInclusionVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the join function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isJoinVerifier() {\n const ret = wasm.verifyingkey_isJoinVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the set_validator_state function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSetValidatorStateVerifier() {\n const ret = wasm.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the split function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSplitVerifier() {\n const ret = wasm.verifyingkey_isSplitVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private_to_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_as_signer function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_to_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the unbond_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get the checksum of the verifying key\n *\n * @returns {string} Checksum of the verifying key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the verifying key\n *\n * @returns {VerifyingKey} A copy of the verifying key\n * @returns {VerifyingKey}\n */\n copy() {\n const ret = wasm.verifyingkey_copy(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Construct a new verifying key from a byte array\n *\n * @param {Uint8Array} bytes Byte representation of a verifying key\n * @returns {VerifyingKey}\n * @param {Uint8Array} bytes\n * @returns {VerifyingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a verifying key from string\n *\n * @param {String} string String representation of a verifying key\n * @returns {VerifyingKey}\n * @param {string} string\n * @returns {VerifyingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a byte array from a verifying key\n *\n * @returns {Uint8Array} Byte representation of a verifying key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the verifying key\n *\n * @returns {String} String representation of the verifying key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst ViewKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_viewkey_free(ptr >>> 0));\n/**\n*/\nclass ViewKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ViewKey.prototype);\n obj.__wbg_ptr = ptr;\n ViewKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ViewKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_viewkey_free(ptr);\n }\n /**\n * Create a new view key from a private key\n *\n * @param {PrivateKey} private_key Private key\n * @returns {ViewKey} View key\n * @param {PrivateKey} private_key\n * @returns {ViewKey}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.privatekey_to_view_key(private_key.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Create a new view key from a string representation of a view key\n *\n * @param {string} view_key String representation of a view key\n * @returns {ViewKey} View key\n * @param {string} view_key\n * @returns {ViewKey}\n */\n static from_string(view_key) {\n const ptr0 = passStringToWasm0(view_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.viewkey_from_string(ptr0, len0);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get a string representation of a view key\n *\n * @returns {string} String representation of a view key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.viewkey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the address corresponding to a view key\n *\n * @returns {Address} Address\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.address_from_view_key(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Decrypt a record ciphertext with a view key\n *\n * @param {string} ciphertext String representation of a record ciphertext\n * @returns {string} String representation of a record plaintext\n * @param {string} ciphertext\n * @returns {string}\n */\n decrypt(ciphertext) {\n let deferred3_0;\n let deferred3_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.viewkey_decrypt(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr2 = r0;\n var len2 = r1;\n if (r3) {\n ptr2 = 0; len2 = 0;\n throw takeObject(r2);\n }\n deferred3_0 = ptr2;\n deferred3_1 = len2;\n return getStringFromWasm0(ptr2, len2);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);\n }\n }\n}\n\nasync function __wbg_load(module, imports) {\n if (typeof Response === 'function' && module instanceof Response) {\n if (typeof WebAssembly.instantiateStreaming === 'function') {\n try {\n return await WebAssembly.instantiateStreaming(module, imports);\n\n } catch (e) {\n if (module.headers.get('Content-Type') != 'application/wasm') {\n console.warn(\"`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n\", e);\n\n } else {\n throw e;\n }\n }\n }\n\n const bytes = await module.arrayBuffer();\n return await WebAssembly.instantiate(bytes, imports);\n\n } else {\n const instance = await WebAssembly.instantiate(module, imports);\n\n if (instance instanceof WebAssembly.Instance) {\n return { instance, module };\n\n } else {\n return instance;\n }\n }\n}\n\nfunction __wbg_get_imports() {\n const imports = {};\n imports.wbg = {};\n imports.wbg.__wbindgen_object_drop_ref = function(arg0) {\n takeObject(arg0);\n };\n imports.wbg.__wbg_new_71801a555ad9f2aa = function() { return handleError(function () {\n const ret = new XMLHttpRequest();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_overrideMimeType_ee9c51919ceb418b = function() { return handleError(function (arg0, arg1, arg2) {\n getObject(arg0).overrideMimeType(getStringFromWasm0(arg1, arg2));\n }, arguments) };\n imports.wbg.__wbg_open_c9eb0cf2c9d95679 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {\n getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), arg5 !== 0);\n }, arguments) };\n imports.wbg.__wbg_send_80d29985093c1ec5 = function() { return handleError(function (arg0) {\n getObject(arg0).send();\n }, arguments) };\n imports.wbg.__wbg_response_7c2e2759084f7279 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).response;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_status_d485fb5a478426fb = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).status;\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_72fb9a18b5ae2624 = function() {\n const ret = new Object();\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_string_new = function(arg0, arg1) {\n const ret = getStringFromWasm0(arg0, arg1);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_1f9b04f170055d33 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_ab6fd82b10560829 = function() { return handleError(function () {\n const ret = new Headers();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_object_clone_ref = function(arg0) {\n const ret = getObject(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_0d76b0581eca6298 = function() { return handleError(function () {\n const ret = new AbortController();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_signal_a61f78a3478fd9bc = function(arg0) {\n const ret = getObject(arg0).signal;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_append_7bfcb4937d1d5e29 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {\n getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));\n }, arguments) };\n imports.wbg.__wbg_instanceof_Response_849eb93e75734b6e = function(arg0) {\n let result;\n try {\n result = getObject(arg0) instanceof Response;\n } catch (_) {\n result = false;\n }\n const ret = result;\n return ret;\n };\n imports.wbg.__wbg_status_61a01141acd3cf74 = function(arg0) {\n const ret = getObject(arg0).status;\n return ret;\n };\n imports.wbg.__wbg_url_5f6dc4009ac5f99d = function(arg0, arg1) {\n const ret = getObject(arg1).url;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_headers_9620bfada380764a = function(arg0) {\n const ret = getObject(arg0).headers;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_iterator_2cee6dadfd956dfa = function() {\n const ret = Symbol.iterator;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_get_e3c254076557e348 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.get(getObject(arg0), getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_function = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'function';\n return ret;\n };\n imports.wbg.__wbg_call_27c0f87801dedf93 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg0).call(getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_object = function(arg0) {\n const val = getObject(arg0);\n const ret = typeof(val) === 'object' && val !== null;\n return ret;\n };\n imports.wbg.__wbg_next_40fc327bfc8770e6 = function(arg0) {\n const ret = getObject(arg0).next;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_next_196c84450b364254 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).next();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_done_298b57d23c0fc80c = function(arg0) {\n const ret = getObject(arg0).done;\n return ret;\n };\n imports.wbg.__wbg_value_d93c65011f51a456 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_abort_2aa7521d5690750e = function(arg0) {\n getObject(arg0).abort();\n };\n imports.wbg.__wbg_stringify_8887fe74e1c50d81 = function() { return handleError(function (arg0) {\n const ret = JSON.stringify(getObject(arg0));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_string_get = function(arg0, arg1) {\n const obj = getObject(arg1);\n const ret = typeof(obj) === 'string' ? obj : undefined;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_log_eb85b4536c227931 = function(arg0, arg1) {\n console.log(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {\n const ret = BigInt.asUintN(64, arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_call_b3ca7c6051f9bec1 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_transaction_new = function(arg0) {\n const ret = Transaction.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_executionresponse_new = function(arg0) {\n const ret = ExecutionResponse.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_keypair_new = function(arg0) {\n const ret = KeyPair.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_66ae46612e7f0234 = function(arg0) {\n const ret = new Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_d4638f722068f043 = function(arg0, arg1, arg2) {\n getObject(arg0)[arg1 >>> 0] = takeObject(arg2);\n };\n imports.wbg.__wbindgen_module = function() {\n const ret = __wbg_init.__wbindgen_wasm_module;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_memory = function() {\n const ret = wasm.memory;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_spawnWorker_4026f00664f3193f = function(arg0, arg1, arg2, arg3) {\n const ret = spawnWorker(getObject(arg0), getObject(arg1), getObject(arg2), arg3 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_cb_drop = function(arg0) {\n const obj = takeObject(arg0).original;\n if (obj.cnt-- == 1) {\n obj.a = 0;\n return true;\n }\n const ret = false;\n return ret;\n };\n imports.wbg.__wbg_new_16b304a2cfa7ff4a = function() {\n const ret = new Array();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_push_a5b05aedc7234f9f = function(arg0, arg1) {\n const ret = getObject(arg0).push(getObject(arg1));\n return ret;\n };\n imports.wbg.__wbg_arrayBuffer_29931d52c7206b02 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).arrayBuffer();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_new_63b92bc8671ed464 = function(arg0) {\n const ret = new Uint8Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_c20a40f15020d68a = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_new_81740750da40724f = function(arg0, arg1) {\n try {\n var state0 = {a: arg0, b: arg1};\n var cb0 = (arg0, arg1) => {\n const a = state0.a;\n state0.a = 0;\n try {\n return __wbg_adapter_282(a, state0.b, arg0, arg1);\n } finally {\n state0.a = a;\n }\n };\n const ret = new Promise(cb0);\n return addHeapObject(ret);\n } finally {\n state0.a = state0.b = 0;\n }\n };\n imports.wbg.__wbindgen_number_new = function(arg0) {\n const ret = arg0;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_abda76e883ba8a5f = function() {\n const ret = new Error();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_stack_658279fe44541cf6 = function(arg0, arg1) {\n const ret = getObject(arg1).stack;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {\n let deferred0_0;\n let deferred0_1;\n try {\n deferred0_0 = arg0;\n deferred0_1 = arg1;\n console.error(getStringFromWasm0(arg0, arg1));\n } finally {\n wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);\n }\n };\n imports.wbg.__wbg_buffer_12d079cc21e14bdb = function(arg0) {\n const ret = getObject(arg0).buffer;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb = function(arg0, arg1, arg2) {\n const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_randomFillSync_5c9c955aa56b6049 = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).randomFillSync(takeObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_subarray_a1f73cd4b5b42fe1 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_getRandomValues_3aa56aa6edec874c = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).getRandomValues(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_set_a47bac70306a19a7 = function(arg0, arg1, arg2) {\n getObject(arg0).set(getObject(arg1), arg2 >>> 0);\n };\n imports.wbg.__wbg_crypto_1d1f22824a6a080c = function(arg0) {\n const ret = getObject(arg0).crypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_process_4a72847cc503995b = function(arg0) {\n const ret = getObject(arg0).process;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_versions_f686565e586dd935 = function(arg0) {\n const ret = getObject(arg0).versions;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_node_104a2ff8d6ea03a2 = function(arg0) {\n const ret = getObject(arg0).node;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_is_string = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'string';\n return ret;\n };\n imports.wbg.__wbg_require_cca90b1a94a0255b = function() { return handleError(function () {\n const ret = module.require;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_msCrypto_eb05e62b530a1508 = function(arg0) {\n const ret = getObject(arg0).msCrypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_e9b4878cebadb3d3 = function(arg0) {\n const ret = new Uint8Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_cd7af8117672b8b8 = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_get_bd8e338fbd5f5cc8 = function(arg0, arg1) {\n const ret = getObject(arg0)[arg1 >>> 0];\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_self_ce0dbfc45cf2f5be = function() { return handleError(function () {\n const ret = self.self;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_window_c6fb939a7f436783 = function() { return handleError(function () {\n const ret = window.window;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_globalThis_d1e6af4856ba331b = function() { return handleError(function () {\n const ret = globalThis.globalThis;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_global_207b558942527489 = function() { return handleError(function () {\n const ret = global.global;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_undefined = function(arg0) {\n const ret = getObject(arg0) === undefined;\n return ret;\n };\n imports.wbg.__wbg_newnoargs_e258087cd0daa0ea = function(arg0, arg1) {\n const ret = new Function(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_has_0af94d20077affa2 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.has(getObject(arg0), getObject(arg1));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_fetch_bc7c8e27076a5c84 = function(arg0) {\n const ret = fetch(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_fetch_921fad6ef9e883dd = function(arg0, arg1) {\n const ret = getObject(arg0).fetch(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {\n const ret = debugString(getObject(arg1));\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbindgen_throw = function(arg0, arg1) {\n throw new Error(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_rethrow = function(arg0) {\n throw takeObject(arg0);\n };\n imports.wbg.__wbg_then_a73caa9a87991566 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_then_0c86a60e8fcfe9f6 = function(arg0, arg1) {\n const ret = getObject(arg0).then(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_queueMicrotask_481971b0d87f3dd4 = function(arg0) {\n queueMicrotask(getObject(arg0));\n };\n imports.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6 = function(arg0) {\n const ret = getObject(arg0).queueMicrotask;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_resolve_b0083a7967828ec8 = function(arg0) {\n const ret = Promise.resolve(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_5d743fc9058ba01a = function() {\n const ret = Atomics.waitAsync;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_8cccba86b0f574cb = function(arg0) {\n const ret = new Int32Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_46d5c36955b71a79 = function(arg0, arg1, arg2) {\n const ret = Atomics.waitAsync(getObject(arg0), arg1, arg2);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_async_19c0400d97cc72fe = function(arg0) {\n const ret = getObject(arg0).async;\n return ret;\n };\n imports.wbg.__wbg_value_571d60108110e917 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_link_fc1eedd35dc7e0a6 = function(arg0) {\n const ret = \"data:application/javascript,\" + encodeURIComponent(`onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n `);\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_new_d1187ae36d662ef9 = function() { return handleError(function (arg0, arg1) {\n const ret = new Worker(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_setonmessage_503809e5bb51bd33 = function(arg0, arg1) {\n getObject(arg0).onmessage = getObject(arg1);\n };\n imports.wbg.__wbg_of_6a70eed8d41f469c = function(arg0, arg1, arg2) {\n const ret = Array.of(getObject(arg0), getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_postMessage_7380d10e8b8269df = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).postMessage(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_data_3ce7c145ca4fbcdc = function(arg0) {\n const ret = getObject(arg0).data;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_responseText_c67ed2d48db10769 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg1).responseText;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n }, arguments) };\n imports.wbg.__wbindgen_closure_wrapper5994 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 622, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_closure_wrapper6020 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 622, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n\n return imports;\n}\n\nfunction __wbg_init_memory(imports, maybe_memory) {\n imports.wbg.memory = maybe_memory || new WebAssembly.Memory({initial:25,maximum:65536,shared:true});\n}\n\nfunction __wbg_finalize_init(instance, module) {\n wasm = instance.exports;\n __wbg_init.__wbindgen_wasm_module = module;\n cachedBigInt64Memory0 = null;\n cachedInt32Memory0 = null;\n cachedUint8Memory0 = null;\n\n wasm.__wbindgen_start();\n return wasm;\n}\n\nfunction initSync(module, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n const imports = __wbg_get_imports();\n\n __wbg_init_memory(imports, maybe_memory);\n\n if (!(module instanceof WebAssembly.Module)) {\n module = new WebAssembly.Module(module);\n }\n\n const instance = new WebAssembly.Instance(module, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nasync function __wbg_init(input, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n\n const imports = __wbg_get_imports();\n\n if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {\n input = fetch(input);\n }\n\n __wbg_init_memory(imports, maybe_memory);\n\n const { instance, module } = await __wbg_load(await input, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nvar exports = /*#__PURE__*/Object.freeze({\n __proto__: null,\n Address: Address,\n Execution: Execution,\n ExecutionResponse: ExecutionResponse,\n Field: Field,\n KeyPair: KeyPair,\n Metadata: Metadata,\n OfflineQuery: OfflineQuery,\n PrivateKey: PrivateKey,\n PrivateKeyCiphertext: PrivateKeyCiphertext,\n Program: Program,\n ProgramManager: ProgramManager,\n ProvingKey: ProvingKey,\n RecordCiphertext: RecordCiphertext,\n RecordPlaintext: RecordPlaintext,\n Signature: Signature,\n Transaction: Transaction,\n VerifyingKey: VerifyingKey,\n ViewKey: ViewKey,\n default: __wbg_init,\n initSync: initSync,\n initThreadPool: initThreadPool,\n runRayonThread: runRayonThread,\n verifyFunctionExecution: verifyFunctionExecution\n});\n\nconst wasm_path = \"aleo_wasm.wasm\";\n\n \n var Cargo = async (opt = {}) => {\n let {importHook, serverPath, initializeHook} = opt;\n\n let final_path = wasm_path;\n\n if (serverPath != null) {\n final_path = serverPath + /[^\\/\\\\]*$/.exec(final_path)[0];\n }\n\n if (importHook != null) {\n final_path = importHook(final_path);\n }\n\n if (initializeHook != null) {\n await initializeHook(__wbg_init, final_path);\n\n } else {\n await __wbg_init(final_path);\n }\n\n return exports;\n };\n\nexport { Cargo as default };\n//# sourceMappingURL=aleo_wasm.js.map\n","/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nconst proxyMarker = Symbol(\"Comlink.proxy\");\nconst createEndpoint = Symbol(\"Comlink.endpoint\");\nconst releaseProxy = Symbol(\"Comlink.releaseProxy\");\nconst finalizer = Symbol(\"Comlink.finalizer\");\nconst throwMarker = Symbol(\"Comlink.thrown\");\nconst isObject = (val) => (typeof val === \"object\" && val !== null) || typeof val === \"function\";\n/**\n * Internal transfer handle to handle objects marked to proxy.\n */\nconst proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n};\n/**\n * Internal transfer handler to handle thrown exceptions.\n */\nconst throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n};\n/**\n * Allows customizing the serialization of certain values.\n */\nconst transferHandlers = new Map([\n [\"proxy\", proxyTransferHandler],\n [\"throw\", throwTransferHandler],\n]);\nfunction isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === \"*\") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n}\nfunction expose(obj, ep = globalThis, allowedOrigins = [\"*\"]) {\n ep.addEventListener(\"message\", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin '${ev.origin}' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case \"GET\" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case \"SET\" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case \"APPLY\" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case \"CONSTRUCT\" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case \"ENDPOINT\" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case \"RELEASE\" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === \"RELEASE\" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener(\"message\", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === \"function\") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError(\"Unserializable return value\"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n}\nfunction isMessagePort(endpoint) {\n return endpoint.constructor.name === \"MessagePort\";\n}\nfunction closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n}\nfunction wrap(ep, target) {\n return createProxy(ep, [], target);\n}\nfunction throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error(\"Proxy has been released and is not useable\");\n }\n}\nfunction releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: \"RELEASE\" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n}\nconst proxyCounter = new WeakMap();\nconst proxyFinalizers = \"FinalizationRegistry\" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\nfunction registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n}\nfunction unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n}\nfunction createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === \"then\") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: \"GET\" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: \"SET\" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: \"ENDPOINT\" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === \"bind\") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"APPLY\" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"CONSTRUCT\" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n}\nfunction myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n}\nfunction processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n}\nconst transferCache = new WeakMap();\nfunction transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n}\nfunction proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n}\nfunction windowEndpoint(w, context = globalThis, targetOrigin = \"*\") {\n return {\n postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\n addEventListener: context.addEventListener.bind(context),\n removeEventListener: context.removeEventListener.bind(context),\n };\n}\nfunction toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: \"HANDLER\" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: \"RAW\" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n}\nfunction fromWireValue(value) {\n switch (value.type) {\n case \"HANDLER\" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case \"RAW\" /* WireValueType.RAW */:\n return value.value;\n }\n}\nfunction requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener(\"message\", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener(\"message\", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n}\nfunction generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join(\"-\");\n}\n\nexport { createEndpoint, expose, finalizer, proxy, proxyMarker, releaseProxy, transfer, transferHandlers, windowEndpoint, wrap };\n//# sourceMappingURL=comlink.mjs.map\n"],"names":["Account","_privateKey","_viewKey","_address","constructor","params","this","privateKeyFromParams","e","console","error","Error","ViewKey","from_private_key","Address","fromCiphertext","ciphertext","password","PrivateKeyCiphertext","fromString","PrivateKey","fromPrivateKeyCiphertext","privateKey","to_string","seed","from_seed_unchecked","from_string","viewKey","address","toString","encryptAccount","toCiphertext","decryptRecord","decrypt","decryptRecords","ciphertexts","map","ownsRecordCiphertext","isOwner","RecordCiphertext","sign","message","verify","signature","OfflineSearchParams","cacheKey","verifyCreditsKeys","bondPublicKeyParams","CREDITS_PROGRAM_KEYS","bond_public","locator","bondValidatorKeyParams","bond_validator","claimUnbondPublicKeyParams","claim_unbond_public","feePrivateKeyParams","fee_private","feePublicKeyParams","fee_public","inclusionKeyParams","inclusion","joinKeyParams","join","setValidatorStateKeyParams","set_validator_state","splitKeyParams","split","transferPrivateKeyParams","transfer_private","transferPrivateToPublicKeyParams","transfer_private_to_public","transferPublicKeyParams","transfer_public","transferPublicAsSignerKeyParams","transfer_public_as_signer","transferPublicToPrivateKeyParams","transfer_public_to_private","unbondPublicKeyParams","unbond_public","OfflineKeyProvider","cache","Map","bondPublicKeys","functionKeys","bondValidatorKeys","cacheKeys","keyId","keys","provingKey","verifyingKey","set","toBytes","claimUnbondPublicKeys","Promise","resolve","reject","undefined","has","provingKeyBytes","verifyingKeyBytes","get","ProvingKey","fromBytes","VerifyingKey","isBondPublicProver","isBondPublicVerifier","isClaimUnbondPublicProver","isClaimUnbondPublicVerifier","isFeePrivateProver","isFeePrivateVerifier","isFeePublicProver","isFeePublicVerifier","isInclusionProver","isInclusionVerifier","isJoinProver","isJoinVerifier","isSetValidatorStateProver","isSetValidatorStateVerifier","isSplitProver","isSplitVerifier","isTransferPrivateProver","isTransferPrivateVerifier","isTransferPrivateToPublicProver","isTransferPrivateToPublicVerifier","isTransferPublicProver","isTransferPublicVerifier","isTransferPublicToPrivateProver","isTransferPublicToPrivateVerifier","isUnbondPublicProver","isUnbondPublicVerifier","feePrivateKeys","feePublicKeys","joinKeys","splitKeys","transferKeys","visibility","PRIVATE_TRANSFER","PRIVATE_TO_PUBLIC_TRANSFER","PUBLIC_TRANSFER","PUBLIC_TRANSFER_AS_SIGNER","PUBLIC_TO_PRIVATE_TRANSFER","unBondPublicKeys","insertBondPublicKeys","bondPublicVerifier","insertClaimUnbondPublicKeys","claimUnbondPublicVerifier","insertFeePrivateKeys","feePrivateVerifier","insertFeePublicKeys","feePublicVerifier","insertJoinKeys","joinVerifier","insertSetValidatorStateKeys","setValidatorStateVerifier","insertSplitKeys","splitVerifier","insertTransferPrivateKeys","transferPrivateVerifier","insertTransferPrivateToPublicKeys","transferPrivateToPublicVerifier","insertTransferPublicKeys","transferPublicVerifier","insertTransferPublicToPrivateKeys","transferPublicToPrivateVerifier","insertUnbondPublicKeys","unbondPublicVerifier","NetworkRecordProvider","account","networkClient","setAccount","findCreditsRecords","microcredits","unspent","nonces","searchParameters","startHeight","endHeight","getLatestHeight","logAndThrow","findUnspentRecords","findCreditsRecord","records","length","findRecord","findRecords","BlockHeightSearch","singletonWorker","createAleoWorker","worker","Worker","URL","type","wrap","async","initializeWasm","warn","parseJSON","json","JSON","parse","key","value","context","Number","isInteger","BigInt","source","url","options","response","fetch","ok","status","post","method","AleoNetworkClient","host","headers","getAccount","setHost","fetchData","text","amounts","maxMicrocredits","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","to_view_key","blockHeight","blocks","getBlockRange","i","transactions","j","confirmedTransaction","transaction","execution","transitions","k","transition","program","outputs","l","output","record","recordPlaintext","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","amounts_found","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","KEY_STORE","Metadata","baseUrl","convert","metadata","name","prover","verifier","getKey","PRIVATE_TRANSFER_TYPES","Set","VALID_TRANSFER_TYPES","AleoKeyProviderParams","proverUri","verifierUri","AleoKeyProvider","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","useCache","clearCache","clear","containsKeys","deleteKeys","delete","getKeys","debug","proverUrl","verifierUrl","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","keyPair","verifying_key","proving_key","inner","ProgramManager","keyProvider","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","spawnWorker","module","memory","addEventListener","event","setTimeout","unref","capture","once","postMessage","wasm","heap","fill","getObject","idx","heap_next","dropObject","takeObject","ret","cachedTextDecoder","TextDecoder","ignoreBOM","fatal","decode","cachedUint8Memory0","getUint8Memory0","buffer","getStringFromWasm0","ptr","len","slice","addHeapObject","obj","WASM_VECTOR_LEN","cachedTextEncoder","TextEncoder","encode","encodeString","arg","view","buf","read","written","passStringToWasm0","malloc","realloc","subarray","mem","offset","code","charCodeAt","isLikeNone","x","cachedInt32Memory0","getInt32Memory0","Int32Array","debugString","val","description","isArray","builtInMatches","exec","call","className","stringify","_","stack","CLOSURE_DTORS","FinalizationRegistry","register","unregister","state","__wbindgen_export_3","dtor","a","b","makeMutClosure","arg0","arg1","f","cnt","real","args","original","__wbg_adapter_34","arg2","_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6a363ba3fe56b221","_assertClass","instance","klass","passArray8ToWasm0","verifyFunctionExecution$1","retptr","__wbindgen_add_to_stack_pointer","Execution$1","VerifyingKey$1","Program$1","ptr0","__wbindgen_malloc","__wbindgen_realloc","len0","__wbg_ptr","r0","r1","cachedBigInt64Memory0","getBigInt64Memory0","BigInt64Array","getArrayU8FromWasm0","runRayonThread","receiver","initThreadPool$1","num_threads","initThreadPool","handleError","apply","__wbindgen_exn_store","__wbg_adapter_282","arg3","wasm_bindgen__convert__closures__invoke2_mut__h3c510d875601a93b","AddressFinalization","__wbg_address_free","__wrap","create","prototype","__destroy_into_raw","free","private_key","PrivateKey$1","address_from_private_key","from_view_key","view_key","ViewKey$1","address_from_view_key","address_from_string","deferred1_0","deferred1_1","address_to_string","__wbindgen_free","Signature$1","address_verify","ExecutionFinalization","__wbg_execution_free","Execution","execution_toString","execution_fromString","ExecutionResponseFinalization","__wbg_executionresponse_free","ExecutionResponse","getOutputs","executionresponse_getOutputs","executionresponse_getExecution","executionresponse_getKeys","KeyPair","getProvingKey","executionresponse_getProvingKey","ProvingKey$1","executionresponse_getVerifyingKey","executionresponse_getFunctionId","executionresponse_getProgram","FieldFinalization","__wbg_field_free","Field","field_toString","field","field_fromString","KeyPairFinalization","__wbg_keypair_free","ptr1","keypair_new","keypair_provingKey","keypair_verifyingKey","MetadataFinalization","__wbg_metadata_free","__wbg_get_metadata_name","__wbg_set_metadata_name","__wbg_get_metadata_locator","__wbg_set_metadata_locator","__wbg_get_metadata_prover","__wbg_set_metadata_prover","__wbg_get_metadata_verifier","__wbg_set_metadata_verifier","__wbg_get_metadata_verifyingKey","__wbg_set_metadata_verifyingKey","metadata_baseUrl","metadata_bond_public","metadata_bond_validator","metadata_claim_unbond_public","metadata_fee_private","metadata_fee_public","metadata_inclusion","metadata_join","metadata_set_validator_state","metadata_split","metadata_transfer_private","metadata_transfer_private_to_public","metadata_transfer_public","metadata_transfer_public_as_signer","metadata_transfer_public_to_private","metadata_unbond_public","OfflineQueryFinalization","__wbg_offlinequery_free","OfflineQuery","block_height","state_root","offlinequery_new","addBlockHeight","offlinequery_addBlockHeight","addStatePath","commitment","state_path","len1","offlinequery_addStatePath","offlinequery_toString","s","offlinequery_fromString","PrivateKeyFinalization","__wbg_privatekey_free","privatekey_new","privatekey_from_seed_unchecked","privatekey_from_string","privatekey_to_string","privatekey_to_view_key","to_address","privatekey_to_address","Address$1","privatekey_sign","newEncrypted","secret","privatekey_newEncrypted","PrivateKeyCiphertext$1","privatekey_toCiphertext","privatekey_fromPrivateKeyCiphertext","PrivateKeyCiphertextFinalization","__wbg_privatekeyciphertext_free","encryptPrivateKey","decryptToPrivateKey","privatekeyciphertext_decryptToPrivateKey","privatekeyciphertext_toString","privatekeyciphertext_fromString","ProgramFinalization","__wbg_program_free","program_fromString","program_toString","hasFunction","program_hasFunction","getFunctions","program_getFunctions","getFunctionInputs","program_getFunctionInputs","getMappings","program_getMappings","getRecordMembers","record_name","program_getRecordMembers","getStructMembers","struct_name","program_getStructMembers","program_getCreditsProgram","program_id","program_address","isEqual","other","program_isEqual","program_getImports","ProgramManagerFinalization","__wbg_programmanager_free","fee_credits","fee_record","fee_proving_key","fee_verifying_key","offline_query","RecordPlaintext$1","ptr2","len2","ptr3","ptr4","ptr5","OfflineQuery$1","programmanager_buildDeploymentTransaction","estimateDeploymentFee","programmanager_estimateDeploymentFee","estimateProgramNameCost","programmanager_estimateProgramNameCost","r2","asUintN","_function","prove_execution","len4","programmanager_executeFunctionOffline","len3","ptr6","ptr7","ptr8","programmanager_buildExecutionTransaction","estimateExecutionFee","programmanager_estimateExecutionFee","estimateFinalizeFee","programmanager_estimateFinalizeFee","record_1","record_2","join_proving_key","join_verifying_key","programmanager_buildJoinTransaction","split_amount","amount_record","split_proving_key","split_verifying_key","programmanager_buildSplitTransaction","amount_credits","transfer_type","transfer_proving_key","transfer_verifying_key","ptr9","programmanager_buildTransferTransaction","programmanager_synthesizeKeyPair","ProvingKeyFinalization","__wbg_provingkey_free","provingkey_isBondPublicProver","isBondValidatorProver","provingkey_isBondValidatorProver","provingkey_isClaimUnbondPublicProver","provingkey_isFeePrivateProver","provingkey_isFeePublicProver","provingkey_isInclusionProver","provingkey_isJoinProver","provingkey_isSetValidatorStateProver","provingkey_isSplitProver","provingkey_isTransferPrivateProver","provingkey_isTransferPrivateToPublicProver","provingkey_isTransferPublicProver","isTransferPublicAsSignerProver","provingkey_isTransferPublicAsSignerProver","provingkey_isTransferPublicToPrivateProver","provingkey_isUnbondPublicProver","checksum","provingkey_checksum","copy","provingkey_copy","bytes","provingkey_fromBytes","string","provingkey_fromString","provingkey_toBytes","v1","provingkey_toString","RecordCiphertextFinalization","__wbg_recordciphertext_free","recordciphertext_fromString","recordciphertext_toString","recordciphertext_decrypt","recordciphertext_isOwner","RecordPlaintextFinalization","__wbg_recordplaintext_free","recordplaintext_commitment","Field$1","recordplaintext_fromString","recordplaintext_toString","recordplaintext_microcredits","recordplaintext_nonce","deferred4_0","deferred4_1","recordplaintext_serialNumberString","r3","SignatureFinalization","__wbg_signature_free","Signature","signature_verify","signature_from_string","signature_to_string","TransactionFinalization","__wbg_transaction_free","transaction_fromString","transaction_toString","transactionId","transaction_transactionId","transactionType","transaction_transactionType","VerifyingKeyFinalization","__wbg_verifyingkey_free","verifyingkey_bondPublicVerifier","bondValidatorVerifier","verifyingkey_bondValidatorVerifier","verifyingkey_claimUnbondPublicVerifier","verifyingkey_feePrivateVerifier","verifyingkey_feePublicVerifier","inclusionVerifier","verifyingkey_inclusionVerifier","verifyingkey_joinVerifier","verifyingkey_setValidatorStateVerifier","verifyingkey_splitVerifier","verifyingkey_transferPrivateVerifier","verifyingkey_transferPrivateToPublicVerifier","verifyingkey_transferPublicVerifier","transferPublicAsSignerVerifier","verifyingkey_transferPublicAsSignerVerifier","verifyingkey_transferPublicToPrivateVerifier","verifyingkey_unbondPublicVerifier","verifyingkey_isBondPublicVerifier","isBondValidatorVerifier","verifyingkey_isBondValidatorVerifier","verifyingkey_isClaimUnbondPublicVerifier","verifyingkey_isFeePrivateVerifier","verifyingkey_isFeePublicVerifier","verifyingkey_isInclusionVerifier","verifyingkey_isJoinVerifier","verifyingkey_isSetValidatorStateVerifier","verifyingkey_isSplitVerifier","verifyingkey_isTransferPrivateVerifier","verifyingkey_isTransferPrivateToPublicVerifier","verifyingkey_isTransferPublicVerifier","isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicToPrivateVerifier","verifyingkey_isUnbondPublicVerifier","verifyingkey_checksum","verifyingkey_copy","verifyingkey_fromBytes","verifyingkey_fromString","verifyingkey_toBytes","verifyingkey_toString","ViewKeyFinalization","__wbg_viewkey_free","viewkey_from_string","viewkey_to_string","deferred3_0","deferred3_1","viewkey_decrypt","__wbg_load","Response","WebAssembly","instantiateStreaming","instantiate","Instance","__wbg_get_imports","wbg","__wbindgen_object_drop_ref","__wbg_new_71801a555ad9f2aa","XMLHttpRequest","arguments","__wbg_overrideMimeType_ee9c51919ceb418b","overrideMimeType","__wbg_open_c9eb0cf2c9d95679","arg4","arg5","open","__wbg_send_80d29985093c1ec5","send","__wbg_response_7c2e2759084f7279","__wbg_status_d485fb5a478426fb","__wbg_new_72fb9a18b5ae2624","__wbindgen_string_new","__wbg_set_1f9b04f170055d33","Reflect","__wbg_new_ab6fd82b10560829","Headers","__wbindgen_object_clone_ref","__wbg_new_0d76b0581eca6298","AbortController","__wbg_signal_a61f78a3478fd9bc","signal","__wbg_append_7bfcb4937d1d5e29","append","__wbg_instanceof_Response_849eb93e75734b6e","result","__wbg_status_61a01141acd3cf74","__wbg_url_5f6dc4009ac5f99d","__wbg_headers_9620bfada380764a","__wbg_iterator_2cee6dadfd956dfa","Symbol","iterator","__wbg_get_e3c254076557e348","__wbindgen_is_function","__wbg_call_27c0f87801dedf93","__wbindgen_is_object","__wbg_next_40fc327bfc8770e6","next","__wbg_next_196c84450b364254","__wbg_done_298b57d23c0fc80c","done","__wbg_value_d93c65011f51a456","__wbg_abort_2aa7521d5690750e","abort","__wbg_stringify_8887fe74e1c50d81","__wbindgen_string_get","__wbg_log_eb85b4536c227931","__wbindgen_bigint_from_u64","__wbg_call_b3ca7c6051f9bec1","__wbg_transaction_new","Transaction$1","__wbg_executionresponse_new","ExecutionResponse$1","__wbg_keypair_new","__wbg_newwithlength_66ae46612e7f0234","__wbg_set_d4638f722068f043","__wbindgen_module","__wbg_init","__wbindgen_wasm_module","__wbindgen_memory","__wbg_spawnWorker_4026f00664f3193f","__wbindgen_cb_drop","__wbg_new_16b304a2cfa7ff4a","__wbg_push_a5b05aedc7234f9f","__wbg_arrayBuffer_29931d52c7206b02","__wbg_new_63b92bc8671ed464","__wbg_length_c20a40f15020d68a","__wbg_new_81740750da40724f","state0","cb0","__wbindgen_number_new","__wbg_new_abda76e883ba8a5f","__wbg_stack_658279fe44541cf6","__wbg_error_f851667af71bcfc6","deferred0_0","deferred0_1","__wbg_buffer_12d079cc21e14bdb","__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb","__wbg_randomFillSync_5c9c955aa56b6049","randomFillSync","__wbg_subarray_a1f73cd4b5b42fe1","__wbg_getRandomValues_3aa56aa6edec874c","getRandomValues","__wbg_set_a47bac70306a19a7","__wbg_crypto_1d1f22824a6a080c","crypto","__wbg_process_4a72847cc503995b","process","__wbg_versions_f686565e586dd935","versions","__wbg_node_104a2ff8d6ea03a2","node","__wbindgen_is_string","__wbg_require_cca90b1a94a0255b","require","__wbg_msCrypto_eb05e62b530a1508","msCrypto","__wbg_newwithlength_e9b4878cebadb3d3","__wbg_length_cd7af8117672b8b8","__wbg_get_bd8e338fbd5f5cc8","__wbg_self_ce0dbfc45cf2f5be","self","__wbg_window_c6fb939a7f436783","window","__wbg_globalThis_d1e6af4856ba331b","globalThis","__wbg_global_207b558942527489","global","__wbindgen_is_undefined","__wbg_newnoargs_e258087cd0daa0ea","Function","__wbg_has_0af94d20077affa2","__wbg_fetch_bc7c8e27076a5c84","__wbg_fetch_921fad6ef9e883dd","__wbindgen_debug_string","__wbindgen_throw","__wbindgen_rethrow","__wbg_then_a73caa9a87991566","then","__wbg_then_0c86a60e8fcfe9f6","__wbg_queueMicrotask_481971b0d87f3dd4","queueMicrotask","__wbg_queueMicrotask_3cbae2ec6b6cd3d6","__wbg_resolve_b0083a7967828ec8","__wbg_waitAsync_5d743fc9058ba01a","Atomics","waitAsync","__wbg_new_8cccba86b0f574cb","__wbg_waitAsync_46d5c36955b71a79","__wbg_async_19c0400d97cc72fe","__wbg_value_571d60108110e917","__wbindgen_link_fc1eedd35dc7e0a6","encodeURIComponent","__wbg_new_d1187ae36d662ef9","__wbg_setonmessage_503809e5bb51bd33","onmessage","__wbg_of_6a70eed8d41f469c","of","__wbg_postMessage_7380d10e8b8269df","__wbg_data_3ce7c145ca4fbcdc","__wbg_newwithstrandinit_3fd6fba4083ff2d0","Request","__wbg_responseText_c67ed2d48db10769","responseText","__wbindgen_closure_wrapper5994","__wbindgen_closure_wrapper6020","__wbg_init_memory","maybe_memory","Memory","initial","maximum","shared","__wbg_finalize_init","exports","__wbindgen_start","initSync","Module","input","freeze","__proto__","Metadata$1","RecordCiphertext$1","default","wasm_path","opt","importHook","serverPath","initializeHook","final_path","proxyMarker","createEndpoint","releaseProxy","finalizer","throwMarker","isObject","transferHandlers","canHandle","serialize","port1","port2","MessageChannel","expose","deserialize","port","serialized","isError","ep","allowedOrigins","callback","ev","origin","allowedOrigin","RegExp","test","isAllowedOrigin","path","argumentList","fromWireValue","returnValue","parent","reduce","prop","rawValue","proxy","transfers","transferCache","catch","wireValue","transferables","toWireValue","removeEventListener","closeEndPoint","TypeError","endpoint","isMessagePort","close","target","createProxy","throwIfProxyReleased","isReleased","releaseEndpoint","requestResponseMessage","proxyCounter","WeakMap","proxyFinalizers","newCount","isProxyReleased","Proxy","_target","unregisterProxy","r","p","bind","_thisArg","rawArgumentList","last","processArguments","construct","registerProxy","processed","v","arr","concat","handler","serializedValue","msg","floor","random","MAX_SAFE_INTEGER"],"sourceRoot":""} \ No newline at end of file diff --git a/530.bundle.js b/530.bundle.js deleted file mode 100644 index da7f0eaa8..000000000 --- a/530.bundle.js +++ /dev/null @@ -1,3 +0,0 @@ -/*! For license information please see 530.bundle.js.LICENSE.txt */ -(()=>{var e,r,t,i,n,a,o={5052:(e,r,t)=>{t.a(e,(async(e,i)=>{try{t.d(r,{AleoKeyProvider:()=>y,AleoKeyProviderParams:()=>d,ProgramManager:()=>p});var n=t(9933),a=e([n]);n=(a.then?(await a)():a)[0];async function o(e,r){const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not get URL "+e);return t}async function s(e,r){r.method="POST";const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not post URL "+e);return t}class f{host;headers;account;constructor(e,r){this.host=e+"/testnet",r&&r.headers?this.headers=r.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const r=await o(this.host+e,{headers:this.headers});return await r.json()}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,r,t,i,a,o){if(o=o||[],e<0)throw new Error("Start height must be greater than or equal to 0");const s=new Array;let c,h,u,l,f=0,d=BigInt(0);if(void 0===t){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");u=this.account._privateKey}else try{u=t instanceof n._q?t:n._q.from_string(t)}catch(e){throw new Error("Error parsing private key provided.")}const y=u.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");l=e}catch(e){throw new Error("Error fetching latest block height.")}if(h="number"==typeof r&&r<=l?r:l,e>h)throw new Error("Start height must be less than or equal to end height.");for(;h>e;){c=h-50,c=BigInt(a))))return s;if(void 0!==i&&i.length>0){let e=0;if(r.microcredits()>i[e]){if(e+=1,s.push(r),"number"==typeof a&&(d+=r.microcredits(),d>=BigInt(a)))return s;if(s.length>=i.length)return s}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+c.toString()+"-"+h.toString()),console.warn("Error: ",e),f+=1,f>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),s}}return s}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,r){try{return await this.fetchData("/blocks?start="+e+"&end="+r)}catch(t){throw new Error("Error fetching blocks between "+e+" and "+r+".")}}async getDeploymentTransactionIDForProgram(e){e instanceof n.$r&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const r=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(r)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return await this.fetchData("/latest/height")}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return n.$r.fromString(e)}catch(r){try{return n.$r.fromString(await this.getProgram(e))}catch(r){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const r={},t=(e instanceof n.$r?e:await this.getProgramObject(e)).getImports();for(let e=0;e0&&!g)try{g=await this.networkClient.getProgramImports(r)}catch(e){throw l(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await n.L.buildExecutionTransaction(w,p,t,o,i,f,this.host,g,d,y,m,b,u)}async execute(e){const r=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(r)}async run(e,r,t,i,a,o,s,c,h,u){let l=h;if(void 0===h&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";if(!s||!c)try{[s,c]=await this.keyProvider.functionKeys(o)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",s),console.log("Verifying key: ",c),n.L.executeFunctionOffline(l,e,r,t,i,!1,a,s,c,this.host,u)}async join(e,r,t,i,a,o,s,c){let h,u,f=s;if(void 0===s&&void 0!==this.account&&(f=this.account.privateKey()),void 0===f)throw"No private key provided and no private key set in the ProgramManager";try{h=i?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),u=await this.keyProvider.joinKeys()}catch(e){throw l(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[d,y]=h,[p,g]=u;try{o=i?await this.getCreditsRecord(t,[],o,a):void 0}catch(e){throw l(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof n.PD?e:n.PD.fromString(e),r=r instanceof n.PD?r:n.PD.fromString(r)}catch(e){throw l("Records provided are not valid. Please ensure they are valid plaintext records.")}const v=await n.L.buildJoinTransaction(f,e,r,t,o,this.host,p,g,d,y,c);return await this.networkClient.submitTransaction(v)}async split(e,r,t,i){let a,o=t;if(void 0===o&&void 0!==this.account&&(o=this.account.privateKey()),void 0===o)throw"No private key provided and no private key set in the ProgramManager";try{a=await this.keyProvider.splitKeys()}catch(e){throw l(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[s,c]=a;try{r=r instanceof n.PD?r:n.PD.fromString(r)}catch(e){throw l("Record provided is not valid. Please ensure it is a valid plaintext record.")}const h=await n.L.buildSplitTransaction(o,e,r,this.host,s,c,i);return await this.networkClient.submitTransaction(h)}async synthesizeKeys(e,r,t,i){let a,o=i;void 0===o&&(o=void 0!==this.account?this.account.privateKey():new n._q);try{a=await this.networkClient.getProgramImports(e);const i=await n.L.synthesizeKeyPair(o,e,r,t,a);return[i.provingKey(),i.verifyingKey()]}catch(e){throw l(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,r,t,i,a,o,s,u,f,d){t=h(t);let y,p,g=f;if(void 0===g&&void 0!==this.account&&(g=this.account.privateKey()),void 0===g)throw"No private key provided and no private key set in the ProgramManager";try{y=a?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),p=await this.keyProvider.transferKeys(t)}catch(e){throw l(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[v,w]=y,[m,b]=p;try{const e=[];c(t)?(s=await this.getCreditsRecord(i,[],s,o),e.push(s.nonce())):s=void 0,u=a?await this.getCreditsRecord(i,e,u,o):void 0}catch(e){throw l(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await n.L.buildTransferTransaction(g,e,r,t,s,i,u,this.host,m,b,v,w,d)}async buildTransferPublicTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async buildTransferPublicAsSignerTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async transfer(e,r,t,i,n,a,o,s,c,h){const u=await this.buildTransferTransaction(e,r,t,i,n,a,o,s,c,h);return await this.networkClient.submitTransaction(u)}async buildBondPublicTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*i),{programName:o="credits.aleo",functionName:s="bond_public",fee:c=n.fee||.86,privateFee:h=!1,inputs:u=[e,r,t,`${a.toString()}u64`],keySearchParams:l=new d({proverUri:v.bond_public.prover,verifierUri:v.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:f=this.creditsProgram(),...y}=n,p={programName:o,functionName:s,fee:c,privateFee:h,inputs:u,keySearchParams:l,...y};return await this.buildExecutionTransaction(p)}async bondPublic(e,r,t,i,n={}){const a=await this.buildBondPublicTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildBondValidatorTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*t),o=Math.trunc(i),{programName:s="credits.aleo",functionName:c="bond_validator",fee:h=n.fee||.86,privateFee:u=!1,inputs:l=[e,r,`${a.toString()}u64`,`${o.toString()}u8`],keySearchParams:f=new d({proverUri:v.bond_validator.prover,verifierUri:v.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:y=this.creditsProgram(),...p}=n,g={programName:s,functionName:c,fee:h,privateFee:u,inputs:l,keySearchParams:f,...p};return await this.buildExecutionTransaction(g)}async bondValidator(e,r,t,i,n={}){const a=await this.buildBondValidatorTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildUnbondPublicTransaction(e,r,t={}){const i=Math.trunc(1e6*r),{programName:n="credits.aleo",functionName:a="unbond_public",fee:o=t.fee||1.3,privateFee:s=!1,inputs:c=[e,`${i.toString()}u64`],keySearchParams:h=new d({proverUri:v.unbond_public.prover,verifierUri:v.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:u=this.creditsProgram(),...l}=t,f={programName:n,functionName:a,fee:o,privateFee:s,inputs:c,keySearchParams:h,...l};return this.buildExecutionTransaction(f)}async unbondPublic(e,r,t={}){const i=await this.buildUnbondPublicTransaction(e,r,t);return await this.networkClient.submitTransaction(i)}async buildClaimUnbondPublicTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="claim_unbond_public",fee:n=r.fee||2,privateFee:a=!1,inputs:o=[e],keySearchParams:s=new d({proverUri:v.claim_unbond_public.prover,verifierUri:v.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:c=this.creditsProgram(),...h}=r,u={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...h};return await this.buildExecutionTransaction(u)}async claimUnbondPublic(e,r={}){const t=await this.buildClaimUnbondPublicTransaction(e,r);return await this.networkClient.submitTransaction(t)}async buildSetValidatorStateTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="set_validator_state",fee:n=1,privateFee:a=!1,inputs:o=[e.toString()],keySearchParams:s=new d({proverUri:v.set_validator_state.prover,verifierUri:v.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...c}=r,h={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...c};return await this.execute(h)}async setValidatorState(e,r={}){const t=await this.buildSetValidatorStateTransaction(e,r);return this.networkClient.submitTransaction(t)}verifyExecution(e){try{const r=e.getExecution(),t=e.getFunctionId(),i=e.getProgram(),a=e.getVerifyingKey();return(0,n.hz)(r,a,i,t)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return n.$r.fromString(e)}creditsProgram(){return n.$r.getCreditsProgram()}verifyProgram(e){try{return n.$r.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,r,t,i){try{return t instanceof n.PD?t:n.PD.fromString(t)}catch(t){try{const t=this.recordProvider;return await t.findCreditsRecord(e,!0,r,i)}catch(e){throw l(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function c(e){return w.has(e)}function h(e){return m.has(e)?e:l(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const g=n.SF.baseUrl();function u(e){const r=n.XV[e.verifyingKey];if(!r)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:r}}const v={bond_public:u(n.SF.bond_public()),bond_validator:u(n.SF.bond_validator()),claim_unbond_public:u(n.SF.claim_unbond_public()),fee_private:u(n.SF.fee_private()),fee_public:u(n.SF.fee_public()),inclusion:u(n.SF.inclusion()),join:u(n.SF.join()),set_validator_state:u(n.SF.set_validator_state()),split:u(n.SF.split()),transfer_private:u(n.SF.transfer_private()),transfer_private_to_public:u(n.SF.transfer_private_to_public()),transfer_public:u(n.SF.transfer_public()),transfer_public_as_signer:u(n.SF.transfer_public_as_signer()),transfer_public_to_private:u(n.SF.transfer_public_to_private()),unbond_public:u(n.SF.unbond_public()),getKey:function(e){return this.hasOwnProperty(e)?this[e]:new Error(`Key "${e}" not found.`)}},w=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),m=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),b=new Set(["private","transfer_private","transferPrivate"]),_=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),P=new Set(["public","transfer_public","transferPublic"]),k=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),E=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function l(e){throw console.error(e),e}i()}catch(K){i(K)}}))},9669:(e,r,t)=>{t.a(e,(async(e,r)=>{try{var i=t(5052),n=t(6891),a=t(9933),o=e([i,a]);[i,a]=o.then?(await o)():o,await(0,a.CK)();const h="https://api.explorer.aleo.org/v1",u=new i.AleoKeyProvider,l=new i.ProgramManager(h,u,void 0);u.useCache(!0);let f="";async function s(e,r,t,n,o=!1){console.log("Web worker: Executing function locally...");const s=performance.now();try{const c=l.createProgramFromSource(e);if(c instanceof Error)throw"Error creating program from source";const h=c.id();if(!c.hasFunction(r))throw`Program ${h} does not contain function ${r}`;const d=`${h}:${r}`,y=await l.networkClient.getProgramImports(e);if(y instanceof Error)throw"Error getting program imports";if(f!==e){const i=await l.synthesizeKeys(e,r,t,a._q.from_string(n));l.keyProvider.cacheKeys(d,i),f=e}const p=new i.AleoKeyProviderParams({cacheKey:d}),g=await l.run(e,r,t,o,y,p,void 0,void 0,a._q.from_string(n));console.log(`Web worker: Local execution completed in ${performance.now()-s} ms`);const v=g.getOutputs(),w=g.getExecution();let m="";const b=u.getKeys(d);if(b instanceof Error)throw"Could not get verifying key";const _=b[1];return w?((0,a.hz)(w,_,c,"hello"),m=w.toString(),console.log("Execution verified successfully: "+w)):m="",console.log(`Function execution response: ${v}`),{outputs:v,execution:m}}catch(e){return console.error(e),e?e.toString():"Unknown error"}}async function c(){return(new a._q).to_string()}const d={run:s,getPrivateKey:c};(0,n.Jj)(d),r()}catch(y){r(y)}}),1)},6891:(e,r,t)=>{t.d(r,{Jj:()=>u});const i=Symbol("Comlink.proxy"),n=Symbol("Comlink.endpoint"),a=Symbol("Comlink.releaseProxy"),o=Symbol("Comlink.finalizer"),s=Symbol("Comlink.thrown"),c=e=>"object"==typeof e&&null!==e||"function"==typeof e,h=new Map([["proxy",{canHandle:e=>c(e)&&e[i],serialize(e){const{port1:r,port2:t}=new MessageChannel;return u(e,r),[t,[t]]},deserialize(e){return e.start(),g(e,[],r);var r}}],["throw",{canHandle:e=>c(e)&&s in e,serialize({value:e}){let r;return r=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[r,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function u(e,r=globalThis,t=["*"]){r.addEventListener("message",(function n(a){if(!a||!a.data)return;if(!function(e,r){for(const t of e){if(r===t||"*"===t)return!0;if(t instanceof RegExp&&t.test(r))return!0}return!1}(t,a.origin))return void console.warn(`Invalid origin '${a.origin}' for comlink proxy`);const{id:c,type:h,path:f}=Object.assign({path:[]},a.data),d=(a.data.argumentList||[]).map(b);let y;try{const r=f.slice(0,-1).reduce(((e,r)=>e[r]),e),t=f.reduce(((e,r)=>e[r]),e);switch(h){case"GET":y=t;break;case"SET":r[f.slice(-1)[0]]=b(a.data.value),y=!0;break;case"APPLY":y=t.apply(r,d);break;case"CONSTRUCT":y=function(e){return Object.assign(e,{[i]:!0})}(new t(...d));break;case"ENDPOINT":{const{port1:r,port2:t}=new MessageChannel;u(e,t),y=function(e,r){return w.set(e,r),e}(r,[r])}break;case"RELEASE":y=void 0;break;default:return}}catch(e){y={value:e,[s]:0}}Promise.resolve(y).catch((e=>({value:e,[s]:0}))).then((t=>{const[i,a]=m(t);r.postMessage(Object.assign(Object.assign({},i),{id:c}),a),"RELEASE"===h&&(r.removeEventListener("message",n),l(r),o in e&&"function"==typeof e[o]&&e[o]())})).catch((e=>{const[t,i]=m({value:new TypeError("Unserializable return value"),[s]:0});r.postMessage(Object.assign(Object.assign({},t),{id:c}),i)}))})),r.start&&r.start()}function l(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function f(e){if(e)throw new Error("Proxy has been released and is not useable")}function d(e){return _(e,{type:"RELEASE"}).then((()=>{l(e)}))}const y=new WeakMap,p="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const r=(y.get(e)||0)-1;y.set(e,r),0===r&&d(e)}));function g(e,r=[],t=function(){}){let i=!1;const o=new Proxy(t,{get(t,n){if(f(i),n===a)return()=>{!function(e){p&&p.unregister(e)}(o),d(e),i=!0};if("then"===n){if(0===r.length)return{then:()=>o};const t=_(e,{type:"GET",path:r.map((e=>e.toString()))}).then(b);return t.then.bind(t)}return g(e,[...r,n])},set(t,n,a){f(i);const[o,s]=m(a);return _(e,{type:"SET",path:[...r,n].map((e=>e.toString())),value:o},s).then(b)},apply(t,a,o){f(i);const s=r[r.length-1];if(s===n)return _(e,{type:"ENDPOINT"}).then(b);if("bind"===s)return g(e,r.slice(0,-1));const[c,h]=v(o);return _(e,{type:"APPLY",path:r.map((e=>e.toString())),argumentList:c},h).then(b)},construct(t,n){f(i);const[a,o]=v(n);return _(e,{type:"CONSTRUCT",path:r.map((e=>e.toString())),argumentList:a},o).then(b)}});return function(e,r){const t=(y.get(r)||0)+1;y.set(r,t),p&&p.register(e,r,e)}(o,e),o}function v(e){const r=e.map(m);return[r.map((e=>e[0])),(t=r.map((e=>e[1])),Array.prototype.concat.apply([],t))];var t}const w=new WeakMap;function m(e){for(const[r,t]of h)if(t.canHandle(e)){const[i,n]=t.serialize(e);return[{type:"HANDLER",name:r,value:i},n]}return[{type:"RAW",value:e},w.get(e)||[]]}function b(e){switch(e.type){case"HANDLER":return h.get(e.name).deserialize(e.value);case"RAW":return e.value}}function _(e,r,t){return new Promise((i=>{const n=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-");e.addEventListener("message",(function r(t){t.data&&t.data.id&&t.data.id===n&&(e.removeEventListener("message",r),i(t.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:n},r),t)}))}}},s={};function c(e){var r=s[e];if(void 0!==r)return r.exports;var t=s[e]={exports:{}};return o[e](t,t.exports,c),t.exports}c.m=o,c.x=()=>{var e=c.O(void 0,[933],(()=>c(9669)));return e=c.O(e)},e="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",r="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",i=e=>{e&&e.d<1&&(e.d=1,e.forEach((e=>e.r--)),e.forEach((e=>e.r--?e.r++:e())))},c.a=(n,a,o)=>{var s;o&&((s=[]).d=-1);var c,h,u,l=new Set,f=n.exports,d=new Promise(((e,r)=>{u=r,h=e}));d[r]=f,d[e]=e=>(s&&e(s),l.forEach(e),d.catch((e=>{}))),n.exports=d,a((n=>{var a;c=(n=>n.map((n=>{if(null!==n&&"object"==typeof n){if(n[e])return n;if(n.then){var a=[];a.d=0,n.then((e=>{o[r]=e,i(a)}),(e=>{o[t]=e,i(a)}));var o={};return o[e]=e=>e(a),o}}var s={};return s[e]=e=>{},s[r]=n,s})))(n);var o=()=>c.map((e=>{if(e[t])throw e[t];return e[r]})),h=new Promise((r=>{(a=()=>r(o)).r=0;var t=e=>e!==s&&!l.has(e)&&(l.add(e),e&&!e.d&&(a.r++,e.push(a)));c.map((r=>r[e](t)))}));return a.r?h:o()}),(e=>(e?u(d[t]=e):h(f),i(s)))),s&&s.d<0&&(s.d=0)},n=[],c.O=(e,r,t,i)=>{if(!r){var a=1/0;for(u=0;u=i)&&Object.keys(c.O).every((e=>c.O[e](r[s])))?r.splice(s--,1):(o=!1,i0&&n[u-1][2]>i;u--)n[u]=n[u-1];n[u]=[r,t,i]},c.d=(e,r)=>{for(var t in r)c.o(r,t)&&!c.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},c.f={},c.e=e=>Promise.all(Object.keys(c.f).reduce(((r,t)=>(c.f[t](e,r),r)),[])),c.u=e=>e+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=(e,r)=>Object.prototype.hasOwnProperty.call(e,r),(()=>{var e;c.g.importScripts&&(e=c.g.location+"");var r=c.g.document;if(!e&&r&&(r.currentScript&&(e=r.currentScript.src),!e)){var t=r.getElementsByTagName("script");if(t.length)for(var i=t.length-1;i>-1&&!e;)e=t[i--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=e})(),(()=>{c.b=self.location+"";var e={530:1};c.f.i=(r,t)=>{e[r]||importScripts(c.p+c.u(r))};var r=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=r.push.bind(r);r.push=r=>{var[i,n,a]=r;for(var o in n)c.o(n,o)&&(c.m[o]=n[o]);for(a&&a(c);i.length;)e[i.pop()]=1;t(r)}})(),a=c.x,c.x=()=>c.e(933).then(a);c.x()})(); -//# sourceMappingURL=530.bundle.js.map \ No newline at end of file diff --git a/530.bundle.js.LICENSE.txt b/530.bundle.js.LICENSE.txt deleted file mode 100644 index 479a8e58b..000000000 --- a/530.bundle.js.LICENSE.txt +++ /dev/null @@ -1,5 +0,0 @@ -/** - * @license - * Copyright 2019 Google LLC - * SPDX-License-Identifier: Apache-2.0 - */ diff --git a/530.bundle.js.map b/530.bundle.js.map deleted file mode 100644 index fe5449411..000000000 --- a/530.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"530.bundle.js","mappings":";UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,+KCAGC,eAAeC,EAAIC,EAAmBC,GACzC,MAAMC,QAAiBC,MAAMH,EAAKC,GAElC,IAAKC,EAASE,GACV,MAAM,IAAIC,MAAMH,EAASI,OAAS,sBAAwBN,GAG9D,OAAOE,CACX,CAGOJ,eAAeS,EAAKP,EAAmBC,GAC1CA,EAAQO,OAAS,OAEjB,MAAMN,QAAiBC,MAAMH,EAAKC,GAElC,IAAKC,EAASE,GACV,MAAM,IAAIC,MAAMH,EAASI,OAAS,uBAAyBN,GAG/D,OAAOE,CACX,CCUA,MAAMO,EACJC,KACAC,QACAC,QAEAC,WAAAA,CAAYH,EAAcT,GACxBa,KAAKJ,KAAOA,EAAO,WAEfT,GAAWA,EAAQU,QACrBG,KAAKH,QAAUV,EAAQU,QAGvBG,KAAKH,QAAU,CAEb,qBAAsB,UAa5BI,UAAAA,CAAWH,GACTE,KAAKF,QAAUA,EASjBI,UAAAA,GACE,OAAOF,KAAKF,QASdK,OAAAA,CAAQP,GACNI,KAAKJ,KAAOA,EAAO,WAGrB,eAAMQ,CACFlB,EAAM,KAER,IACA,MAAME,QAAiBH,EAAIe,KAAKJ,KAAOV,EAAK,CAC1CW,QAASG,KAAKH,UAGhB,aAAaT,EAASiB,OACpB,MAAOC,GACP,MAAM,IAAIf,MAAM,yBA2BpB,wBAAMgB,CACFC,EACAC,EACAC,EACAC,EACAC,EACAC,GAIF,GAFAA,EAASA,GAAU,GAEfL,EAAc,EAChB,MAAM,IAAIjB,MAAM,mDAIlB,MAAMuB,EAAU,IAAIC,MACpB,IAAIC,EACAC,EACAC,EAGAC,EAFAC,EAAW,EACXC,EAAmBC,OAAO,GAI9B,QAA0B,IAAfZ,EAA4B,CACrC,QAA4B,IAAjBV,KAAKF,QACd,MAAM,IAAIP,MAA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AIiS,KAAYgE,EAChBjE,EAAoBwC,EAAEyB,EAAahE,KACrCD,EAAoBM,EAAEL,GAAYgE,EAAYhE,IAIhD,IADGiE,GAASA,EAAQlE,GACdgC,EAASnZ,QACdib,EAAgB9B,EAASmC,OAAS,EACnCH,EAA2BhW,EAAK,MfnB7BrI,EAAOqa,EAAoBO,EAC/BP,EAAoBO,EAAI,IAChBP,EAAoBzN,EAAE,KAAKwK,KAAKpX,GgBDdqa,EAAoBO","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/../src/utils.ts","webpack://aleo-website/../src/network-client.ts","webpack://aleo-website/../src/function-key-provider.ts","webpack://aleo-website/../src/program-manager.ts","webpack://aleo-website/../src/index.ts","webpack://aleo-website/../src/worker.ts","webpack://aleo-website/../node_modules/comlink/dist/esm/comlink.mjs","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn __webpack_require__.e(933).then(next);\n};","export async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./index\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/testnet\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/testnet\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n return await response.json();\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise | Error> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n if (!(blocks instanceof Error)) {\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = \"Error fetching blocks between \" + start + \" and \" + end + \".\"\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return await this.fetchData(\"/latest/height\");\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error) {\n throw logAndThrow(\"Error fetching program imports: \" + error)\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error) {\n throw new Error(\"Error fetching program imports with error: \" + error);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise | Error> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise | Error> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string | Error} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n return await response.json();\n\n } catch (error) {\n throw new Error(`Error posting transaction. Aleo network response: ${(error as Error).message}`);\n }\n } catch (error) {\n throw new Error(`Error posting transaction: No response received: ${(error as Error).message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./index\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error) {\n throw new Error(\"Error fetching data.\" + error);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair | Error} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair | Error {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n return new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n if (!(key instanceof Error)) {\n return this.fetchCreditsKeys(key);\n }\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error) {\n throw new Error(`Error: fetching credits.aleo keys: ${error}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner) {\n return new Error(\"Invalid verifying key. Error: \" + inner);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./index\";\nimport {Execution} from \"@provablehq/wasm/dist/crates/aleo_wasm\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.aleo.org/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n \n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string | Error} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e) {\n throw logAndThrow(`Error validating program: ${e}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e) {\n throw logAndThrow(`Error finding ${programName}. Network response: '${e}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e) {\n throw logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e) {\n throw logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e) {\n throw logAndThrow(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program | Error} The program object\n */\n createProgramFromSource(program: string): Program | Error {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string | Error {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import {VerifyingKey, Metadata} from \"@provablehq/wasm\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key | Error {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n return new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): Error {\n console.error(message);\n throw message;\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n","import {initThreadPool, ProgramManager, PrivateKey, verifyFunctionExecution, FunctionKeyPair} from \"./index\";\nimport { AleoKeyProvider, AleoKeyProviderParams} from \"./function-key-provider\";\nimport { expose } from \"comlink\";\n\nawait initThreadPool();\n\nconst defaultHost = \"https://api.explorer.aleo.org/v1\";\nconst keyProvider = new AleoKeyProvider();\nconst programManager = new ProgramManager(\n defaultHost,\n keyProvider,\n undefined\n);\n\nkeyProvider.useCache(true);\n\nlet lastLocalProgram: string = \"\";\n\nexport interface WorkerAPI {\n run: (\n localProgram: string,\n aleoFunction: string,\n inputs: string[],\n privateKey: string\n ) => Promise<{ outputs: any; execution: string } | string>;\n\n getPrivateKey: () => Promise;\n}\nasync function run(\n localProgram: string,\n aleoFunction: string,\n inputs: string[],\n privateKey: string,\n proveExecution = false\n) {\n console.log(\"Web worker: Executing function locally...\");\n const startTime = performance.now();\n\n try {\n // Ensure the program is valid and that it contains the function specified\n const program = programManager.createProgramFromSource(localProgram);\n if (program instanceof Error) {\n throw \"Error creating program from source\";\n }\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw `Program ${program_id} does not contain function ${aleoFunction}`;\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n\n // Get the program imports\n const imports = await programManager.networkClient.getProgramImports(\n localProgram\n );\n\n if (imports instanceof Error) {\n throw \"Error getting program imports\";\n }\n // Get the proving and verifying keys for the function\n if (lastLocalProgram !== localProgram) {\n const keys = await programManager.synthesizeKeys(\n localProgram,\n aleoFunction,\n inputs,\n PrivateKey.from_string(privateKey)\n );\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n lastLocalProgram = localProgram;\n }\n\n // Pass the cache key to the execute function\n const keyParams = new AleoKeyProviderParams({\n cacheKey: cacheKey,\n });\n\n // Execute the function locally\n const response = await programManager.run(\n localProgram,\n aleoFunction,\n inputs,\n proveExecution,\n imports,\n keyParams,\n undefined,\n undefined,\n PrivateKey.from_string(privateKey),\n );\n\n // Return the outputs to the main thread\n console.log(\n `Web worker: Local execution completed in ${\n performance.now() - startTime\n } ms`\n );\n const outputs = response.getOutputs();\n const execution = response.getExecution();\n let executionString = \"\";\n\n const keys = keyProvider.getKeys(cacheKey);\n\n if (keys instanceof Error) {\n throw \"Could not get verifying key\";\n }\n\n const verifyingKey = keys[1];\n\n if (execution) {\n verifyFunctionExecution(\n execution,\n verifyingKey,\n program,\n \"hello\"\n );\n executionString = execution.toString();\n console.log(\"Execution verified successfully: \" + execution);\n } else {\n executionString = \"\";\n }\n\n console.log(`Function execution response: ${outputs}`);\n\n return { outputs: outputs, execution: executionString };\n } catch (error) {\n console.error(error);\n return error ? error.toString() : \"Unknown error\";\n }\n}\n\nasync function getPrivateKey() {\n const privateKey = new PrivateKey();\n return privateKey.to_string();\n}\n\nconst workerAPI = { run, getPrivateKey };\nexpose(workerAPI);\n","/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nconst proxyMarker = Symbol(\"Comlink.proxy\");\nconst createEndpoint = Symbol(\"Comlink.endpoint\");\nconst releaseProxy = Symbol(\"Comlink.releaseProxy\");\nconst finalizer = Symbol(\"Comlink.finalizer\");\nconst throwMarker = Symbol(\"Comlink.thrown\");\nconst isObject = (val) => (typeof val === \"object\" && val !== null) || typeof val === \"function\";\n/**\n * Internal transfer handle to handle objects marked to proxy.\n */\nconst proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n};\n/**\n * Internal transfer handler to handle thrown exceptions.\n */\nconst throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n};\n/**\n * Allows customizing the serialization of certain values.\n */\nconst transferHandlers = new Map([\n [\"proxy\", proxyTransferHandler],\n [\"throw\", throwTransferHandler],\n]);\nfunction isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === \"*\") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n}\nfunction expose(obj, ep = globalThis, allowedOrigins = [\"*\"]) {\n ep.addEventListener(\"message\", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin '${ev.origin}' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case \"GET\" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case \"SET\" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case \"APPLY\" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case \"CONSTRUCT\" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case \"ENDPOINT\" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case \"RELEASE\" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === \"RELEASE\" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener(\"message\", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === \"function\") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError(\"Unserializable return value\"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n}\nfunction isMessagePort(endpoint) {\n return endpoint.constructor.name === \"MessagePort\";\n}\nfunction closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n}\nfunction wrap(ep, target) {\n return createProxy(ep, [], target);\n}\nfunction throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error(\"Proxy has been released and is not useable\");\n }\n}\nfunction releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: \"RELEASE\" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n}\nconst proxyCounter = new WeakMap();\nconst proxyFinalizers = \"FinalizationRegistry\" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\nfunction registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n}\nfunction unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n}\nfunction createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === \"then\") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: \"GET\" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: \"SET\" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: \"ENDPOINT\" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === \"bind\") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"APPLY\" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"CONSTRUCT\" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n}\nfunction myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n}\nfunction processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n}\nconst transferCache = new WeakMap();\nfunction transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n}\nfunction proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n}\nfunction windowEndpoint(w, context = globalThis, targetOrigin = \"*\") {\n return {\n postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\n addEventListener: context.addEventListener.bind(context),\n removeEventListener: context.removeEventListener.bind(context),\n };\n}\nfunction toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: \"HANDLER\" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: \"RAW\" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n}\nfunction fromWireValue(value) {\n switch (value.type) {\n case \"HANDLER\" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case \"RAW\" /* WireValueType.RAW */:\n return value.value;\n }\n}\nfunction requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener(\"message\", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener(\"message\", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n}\nfunction generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join(\"-\");\n}\n\nexport { createEndpoint, expose, finalizer, proxy, proxyMarker, releaseProxy, transfer, transferHandlers, windowEndpoint, wrap };\n//# sourceMappingURL=comlink.mjs.map\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [933], () => (__webpack_require__(9669)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && !scriptUrl) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t530: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","async","get","url","options","response","fetch","ok","Error","status","post","method","AleoNetworkClient","host","headers","account","constructor","this","setAccount","getAccount","setHost","fetchData","json","error","findUnspentRecords","startHeight","endHeight","privateKey","amounts","maxMicrocredits","nonces","records","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","BigInt","_privateKey","PrivateKey","from_string","viewKey","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","length","transactions","j","confirmedTransaction","type","transaction","execution","transitions","k","transition","program","outputs","l","output","record","RecordCiphertext","fromString","value","isOwner","recordPlaintext","decrypt","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","console","warn","toString","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","key","logAndThrow","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","message","AleoKeyProviderParams","name","proverUri","verifierUri","cacheKey","params","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","KEY_STORE","Map","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","set","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","join","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","text","e","inner","unBondPublicKeys","ProgramManager","keyProvider","networkClient","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","undefined","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","findCreditsRecord","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set","initThreadPool","defaultHost","programManager","lastLocalProgram","localProgram","aleoFunction","startTime","performance","now","program_id","hasFunction","keyParams","getOutputs","executionString","getPrivateKey","to_string","workerAPI","expose","proxyMarker","Symbol","createEndpoint","releaseProxy","finalizer","throwMarker","isObject","val","transferHandlers","canHandle","serialize","obj","port1","port2","MessageChannel","deserialize","port","createProxy","target","serialized","isError","stack","ep","globalThis","allowedOrigins","addEventListener","callback","ev","origin","allowedOrigin","RegExp","test","isAllowedOrigin","path","argumentList","map","fromWireValue","returnValue","parent","slice","reduce","prop","rawValue","apply","proxy","transfers","transferCache","Promise","resolve","catch","then","wireValue","transferables","toWireValue","postMessage","removeEventListener","closeEndPoint","TypeError","endpoint","isMessagePort","close","throwIfProxyReleased","isReleased","releaseEndpoint","requestResponseMessage","proxyCounter","WeakMap","proxyFinalizers","FinalizationRegistry","newCount","isProxyReleased","Proxy","_target","unregister","unregisterProxy","r","p","bind","_thisArg","rawArgumentList","last","processArguments","construct","register","registerProxy","processed","v","arr","prototype","concat","handler","serializedValue","msg","fill","floor","random","Number","MAX_SAFE_INTEGER","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","queue","d","forEach","fn","a","hasAwait","currentDeps","outerResolve","reject","depQueues","promise","rej","deps","dep","ret","wrapDeps","getResult","fnQueue","q","add","err","result","chunkIds","priority","notFulfilled","Infinity","fulfilled","every","splice","definition","o","defineProperty","enumerable","f","chunkId","all","promises","u","g","Function","window","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/58342153fc9a001d7976.wasm b/58342153fc9a001d7976.wasm deleted file mode 100644 index d98df8e58..000000000 Binary files a/58342153fc9a001d7976.wasm and /dev/null differ diff --git a/587.bundle.js b/587.bundle.js index 82549835e..74b4c284f 100644 --- a/587.bundle.js +++ b/587.bundle.js @@ -1,2 +1,2 @@ -(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,879,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={587:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,879,312].map(c.e,c)).then(n);c.x()})(); +(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,857,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={587:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,857,312].map(c.e,c)).then(n);c.x()})(); //# sourceMappingURL=587.bundle.js.map \ No newline at end of file diff --git a/587.bundle.js.map b/587.bundle.js.map index 826754adb..66bd27d5d 100644 --- a/587.bundle.js.map +++ b/587.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"587.bundle.js","mappings":"UAAIA,EACAC,E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AI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,879,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,879,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t587: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"587.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGr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k loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,857,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,857,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t587: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/59.bundle.js b/59.bundle.js deleted file mode 100644 index 09a5d4485..000000000 --- a/59.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{var r,e,t,o,a,n,i={},p={};function c(r){var e=p[r];if(void 0!==e)return e.exports;var t=p[r]={exports:{}};return i[r](t,t.exports,c),t.exports}c.m=i,c.x=()=>{var r=c.O(void 0,[933,383],(()=>c(5383)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,i)=>{var p;i&&((p=[]).d=-1);var c,s,f,l=new Set,u=a.exports,b=new Promise(((r,e)=>{f=e,s=r}));b[e]=u,b[r]=r=>(p&&r(p),l.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{i[e]=r,o(n)}),(r=>{i[t]=r,o(n)}));var i={};return i[r]=r=>r(n),i}}var p={};return p[r]=r=>{},p[e]=a,p})))(a);var i=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(i)).r=0;var t=r=>r!==p&&!l.has(r)&&(l.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:i()}),(r=>(r?f(b[t]=r):s(u),o(p)))),p&&p.d<0&&(p.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(f=0;f=o)&&Object.keys(c.O).every((r=>c.O[r](e[p])))?e.splice(p--,1):(i=!1,o0&&a[f-1][2]>o;f--)a[f]=a[f-1];a[f]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&!r;)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={59:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var i in a)c.o(a,i)&&(c.m[i]=a[i]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([c.e(933),c.e(383)]).then(n);c.x()})(); -//# sourceMappingURL=59.bundle.js.map \ No newline at end of file diff --git a/59.bundle.js.map b/59.bundle.js.map deleted file mode 100644 index 365684014..000000000 --- a/59.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"59.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUI,EAAQA,EAAOD,QAASJ,GAG/CK,EAAOD,OACf,CAGAJ,EAAoBO,EAAID,EAGxBN,EAAoBQ,EAAI,KAGvB,IAAIC,EAAsBT,EAAoBU,OAAEP,EAAW,CAAC,IAAI,MAAM,IAAOH,EAAoB,QAEjG,OADAS,EAAsBT,EAAoBU,EAAED,EAClB,EHjCvBhB,EAAkC,mBAAXkB,OAAwBA,OAAO,kBAAoB,qBAC1EjB,EAAmC,mBAAXiB,OAAwBA,OAAO,mBAAqB,sBAC5EhB,EAAiC,mBAAXgB,OAAwBA,OAAO,iBAAmB,oBACxEf,EAAgBgB,IAChBA,GAASA,EAAMC,EAAI,IACrBD,EAAMC,EAAI,EACVD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/E,EAAoBwF,EAAIxF,EAAoBoE,EAAEJ,GAE9D,EAGD,IAAI4B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBlD,KAAKoD,KAAKF,GAC9DA,EAAmBlD,KAvBCqD,IACnB,IAAKlD,EAAUmD,EAAaC,GAAWF,EACvC,IAAI,IAAI9F,KAAY+F,EAChBhG,EAAoB2D,EAAEqC,EAAa/F,KACrCD,EAAoBO,EAAEN,GAAY+F,EAAY/F,IAIhD,IADGgG,GAASA,EAAQjG,GACd6C,EAASK,QACdyC,EAAgB9C,EAASqD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BjG,EAAOE,EAAoBQ,EAC/BR,EAAoBQ,EAAI,IAChBkB,QAAQuC,IAAI,CAClBjE,EAAoBkC,EAAE,KACtBlC,EAAoBkC,EAAE,OACpBF,KAAKlC,GSJiBE,EAAoBQ,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(933),\n\t\t__webpack_require__.e(383)\n\t]).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [933,383], () => (__webpack_require__(5383)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && !scriptUrl) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t59: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/63.bundle.js b/63.bundle.js index be1a20874..4375621f5 100644 --- a/63.bundle.js +++ b/63.bundle.js @@ -1,2 +1,2 @@ -(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,879,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={63:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,879,312].map(c.e,c)).then(n);c.x()})(); +(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,857,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={63:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,857,312].map(c.e,c)).then(n);c.x()})(); //# sourceMappingURL=63.bundle.js.map \ No newline at end of file diff --git a/63.bundle.js.map b/63.bundle.js.map index a3d1e6063..b338fe0c7 100644 --- a/63.bundle.js.map +++ b/63.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"63.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAGpEK,EAAOD,OACf,CAGAJ,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAI,KAGvB,IAAIC,EAAsBV,EAAoBW,OAAER,EAAW,CAAC,IAAI,IAAI,MAAM,IAAOH,EAAoB,QAErG,OADAU,EAAsBV,EAAoBW,EAAED,EAClB,EHjCvBjB,EAAkC,mBAAXmB,OAAwBA,OAAO,kBAAoB,qBAC1ElB,EAAmC,mBAAXkB,OAAwBA,OAAO,mBAAqB,sBA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,QAAQ,YAAa,KACpF1F,EAAoB2F,EAAIb,C,WClBxB9E,EAAoB4F,EAAIC,KAAKb,SAAW,GAIxC,IAAIc,EAAkB,CACrB,GAAI,GAgBL9F,EAAoBgE,EAAEd,EAAI,CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,879,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,879,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t63: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"63.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAGpEK,EAAOD,OACf,CAGAJ,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAI,KAGvB,IAAIC,EAAsBV,EAAoBW,OAAER,EAAW,CAAC,IAAI,IAAI,MAAM,IAAOH,EAAoB,QAErG,OADAU,EAAsBV,EAAoBW,EAAED,EAClB,EHjCvBjB,EAAkC,mBAAXmB,OAAwBA,OAAO,kBAAoB,qBAC1ElB,EAAmC,mBAAXkB,OAAwBA,OAAO,mBAAqB,sBAC5EjB,EAAiC,mBAAXiB,OAAwBA,OAAO,iBAAmB,oBACxEhB,EAAgBiB,IAChBA,GAASA,EAAMC,EAAI,IACrBD,EAAMC,EAAI,EACVD,EAAME,SAASC,GAAQA,EAAGC,MA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CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,857,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,857,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t63: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/647.bundle.js b/647.bundle.js deleted file mode 100644 index 66fa715dd..000000000 --- a/647.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{var r,e,t,o,a,n,i={},p={};function c(r){var e=p[r];if(void 0!==e)return e.exports;var t=p[r]={exports:{}};return i[r](t,t.exports,c),t.exports}c.m=i,c.x=()=>{var r=c.O(void 0,[933,383],(()=>c(5383)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,i)=>{var p;i&&((p=[]).d=-1);var c,s,f,l=new Set,u=a.exports,b=new Promise(((r,e)=>{f=e,s=r}));b[e]=u,b[r]=r=>(p&&r(p),l.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{i[e]=r,o(n)}),(r=>{i[t]=r,o(n)}));var i={};return i[r]=r=>r(n),i}}var p={};return p[r]=r=>{},p[e]=a,p})))(a);var i=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(i)).r=0;var t=r=>r!==p&&!l.has(r)&&(l.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:i()}),(r=>(r?f(b[t]=r):s(u),o(p)))),p&&p.d<0&&(p.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(f=0;f=o)&&Object.keys(c.O).every((r=>c.O[r](e[p])))?e.splice(p--,1):(i=!1,o0&&a[f-1][2]>o;f--)a[f]=a[f-1];a[f]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&!r;)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={647:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var i in a)c.o(a,i)&&(c.m[i]=a[i]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([c.e(933),c.e(383)]).then(n);c.x()})(); -//# sourceMappingURL=647.bundle.js.map \ No newline at end of file diff --git a/647.bundle.js.map b/647.bundle.js.map deleted file mode 100644 index 13475754e..000000000 --- a/647.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"647.bundle.js","mappings":"UAA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","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(933),\n\t\t__webpack_require__.e(383)\n\t]).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [933,383], () => (__webpack_require__(5383)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript)\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && !scriptUrl) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t647: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","call","scriptUrl","importScripts","location","document","currentScript","src","scripts","getElementsByTagName","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/66.bundle.js b/66.bundle.js deleted file mode 100644 index e8643a8d9..000000000 --- a/66.bundle.js +++ /dev/null @@ -1,3 +0,0 @@ -/*! For license information please see 66.bundle.js.LICENSE.txt */ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[66],{66:(e,t,r)=>{r.a(e,(async(e,t)=>{try{var n=r(495),o=e([n]);function u(e){return u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},u(e)}function l(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function f(e,t){if(e){if("string"==typeof e)return p(e,t);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?p(e,t):void 0}}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=Array(t);r=0;--a){var c=this.tryEntries[a],i=c.completion;if("root"===c.tryLoc)return o("end");if(c.tryLoc<=this.prev){var s=n.call(c,"catchLoc"),u=n.call(c,"finallyLoc");if(s&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),S(r),d}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;S(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:N(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),d}},t}function g(e,t,r,n,o,a,c){try{var i=e[a](c),s=i.value}catch(e){return void r(e)}i.done?t(s):Promise.resolve(s).then(n,o)}function m(e){return function(){var t=this,r=arguments;return new Promise((function(n,o){var a=e.apply(t,r);function c(e){g(a,n,o,c,i,"next",e)}function i(e){g(a,n,o,c,i,"throw",e)}c(void 0)}))}}n=(o.then?(await o)():o)[0],await n.initThreadPool();var a="https://api.explorer.aleo.org/v1",c=new n.AleoKeyProvider,i=new n.ProgramManager(a,c,void 0);c.useCache(!0),self.postMessage({type:"ALEO_WORKER_READY"});var s=null;self.addEventListener("message",(function(e){if("ALEO_EXECUTE_PROGRAM_LOCAL"===e.data.type){var t=e.data,r=t.localProgram,o=t.aleoFunction,u=t.inputs,p=t.privateKey;console.log("Web worker: Executing function locally...");var g=performance.now();m(v().mark((function e(){var t,a,l,f,y,h,m,d,w,E;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(e.prev=0,t=n.PrivateKey.from_string(p),a=i.createProgramFromSource(r),l=a.id(),a.hasFunction(o)){e.next=6;break}throw"Program ".concat(l," does not contain function ").concat(o);case 6:if(f="".concat(l,":").concat(o),y=i.networkClient.getProgramImports(r),s===r){e.next=14;break}return e.next=11,i.synthesizeKeys(r,o,u,t);case 11:h=e.sent,i.keyProvider.cacheKeys(f,h),s=r;case 14:return m=new n.AleoKeyProviderParams({cacheKey:f}),e.next=17,i.run(r,o,u,!1,y,m,void 0,void 0,t,void 0);case 17:d=e.sent,console.log("Web worker: Local execution completed in ".concat(performance.now()-g," ms")),w=d.getOutputs(),(E=d.getExecution())?(n.verifyFunctionExecution(E,c.getKeys(f)[1],a,"hello"),E=E.toString(),console.log("Execution verified successfully: "+E)):E="",console.log("Function execution response: ".concat(w)),self.postMessage({type:"OFFLINE_EXECUTION_COMPLETED",outputs:{outputs:w,execution:E}}),e.next=30;break;case 26:e.prev=26,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 30:case"end":return e.stop()}}),e,null,[[0,26]])})))()}else if("ALEO_EXECUTE_PROGRAM_ON_CHAIN"===e.data.type){var d=e.data,w=d.remoteProgram,E=d.aleoFunction,b=d.inputs,x=d.privateKey,k=d.fee,O=d.privateFee,P=d.feeRecord,_=d.url;console.log("Web worker: Creating execution...");var L=performance.now();m(v().mark((function e(){var t,r,o,c,s,u,l;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=n.PrivateKey.from_string(x),e.next=4,i.networkClient.getProgramObject(w);case 4:if(r=e.sent,o=r.id(),r.hasFunction(E)){e.next=8;break}throw"Program ".concat(o," does not contain function ").concat(E);case 8:if(c="".concat(o,":").concat(E),i.keyProvider.containsKeys(c)){e.next=15;break}return console.log("Web worker: Synthesizing proving & verifying keys for: '".concat(o,":").concat(E,"'")),e.next=13,i.synthesizeKeys(w,E,b,t);case 13:s=e.sent,i.keyProvider.cacheKeys(c,s);case 15:return u=new n.AleoKeyProviderParams({cacheKey:c}),"string"==typeof _&&i.setHost(_),e.next=19,i.execute({programName:o,functionName:E,fee:k,privateFee:O,inputs:b,keySearchParams:u,feeRecord:P,privateKey:t});case 19:l=e.sent,console.log("Web worker: On-chain execution transaction created in ".concat(performance.now()-L," ms")),self.postMessage({type:"EXECUTION_TRANSACTION_COMPLETED",executeTransaction:l}),e.next=28;break;case 24:e.prev=24,e.t0=e.catch(0),console.error("Error creating execution transaction: ".concat(e.t0)),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 28:return e.prev=28,i.setHost(a),e.finish(28);case 31:case"end":return e.stop()}}),e,null,[[0,24,28,31]])})))()}else if("ALEO_ESTIMATE_EXECUTION_FEE"===e.data.type){var T=e.data,R=T.remoteProgram,M=T.privateKey,S=T.aleoFunction,A=T.inputs,N=T.url;console.log("Web worker: Estimating execution fee...");var C=performance.now();m(v().mark((function e(){var t,r,o,a,c,s,u,p,g,m,d;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=n.PrivateKey.from_string(M),e.next=4,i.networkClient.getProgramObject(R);case 4:if(r=e.sent,o=r.id(),r.getFunctions().includes(S)){e.next=8;break}throw"Program ".concat(o," does not contain function ").concat(S);case 8:return a="".concat(o,":").concat(S),e.next=11,i.networkClient.getProgramImports(R);case 11:if(c=e.sent,i.keyProvider.containsKeys(a)){e.next=18;break}return console.log("Web worker: Synthesizing proving & verifying keys for: '".concat(o,":").concat(S,"'")),e.next=16,i.synthesizeKeys(r.toString(),S,A,t);case 16:s=e.sent,i.keyProvider.cacheKeys(a,s);case 18:return u=i.keyProvider.getKeys(a),w=2,p=h(v=u)||y(v,w)||f(v,w)||l(),g=p[0],m=p[1],e.next=21,n.ProgramManagerBase.estimateExecutionFee(t,R,S,A,N,c,g,m,void 0);case 21:d=e.sent,console.log("Web worker: Execution fee estimated in ".concat(performance.now()-C," ms")),console.log("Execution Fee Estimation: ".concat(d," microcredits")),self.postMessage({type:"EXECUTION_FEE_ESTIMATION_COMPLETED",executionFee:Number(d)/1e6+.01}),e.next=31;break;case 27:e.prev=27,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 31:case"end":return e.stop()}var v,w}),e,null,[[0,27]])})))()}else if("ALEO_ESTIMATE_DEPLOYMENT_FEE"===e.data.type){var F=e.data,K=F.program;F.url;console.log("Web worker: Estimating deployment fee...");var I=performance.now();m(v().mark((function e(){var t,r;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,i.networkClient.getProgramImports(K);case 3:return t=e.sent,console.log("Estimating deployment fee.."),e.next=7,n.ProgramManagerBase.estimateDeploymentFee(K,t);case 7:r=e.sent,console.log("Web worker: Deployment fee estimation completed in ".concat(performance.now()-I," ms")),console.log("Deployment Fee Estimation: ".concat(r," microcredits")),self.postMessage({type:"DEPLOYMENT_FEE_ESTIMATION_COMPLETED",deploymentFee:Number(r)/1e6+.01}),e.next=17;break;case 13:e.prev=13,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 17:case"end":return e.stop()}}),e,null,[[0,13]])})))()}else if("ALEO_TRANSFER"===e.data.type){var j=e.data,W=j.privateKey,D=j.amountCredits,H=j.recipient,G=j.transfer_type,U=j.amountRecord,Y=j.fee,X=j.privateFee,z=j.feeRecord,J=j.url;console.log("Web worker: Creating transfer of type ".concat(G,"..."));var B=performance.now();m(v().mark((function e(){var t;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof J&&i.setHost(J),e.next=4,i.transfer(D,H,G,Y,X,void 0,U,z,n.PrivateKey.from_string(W),void 0);case 4:t=e.sent,console.log("Web worker: Transfer transaction ".concat(t," created in ").concat(performance.now()-B," ms")),self.postMessage({type:"TRANSFER_TRANSACTION_COMPLETED",transferTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.error(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,i.setHost(a),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}else if("ALEO_DEPLOY"===e.data.type){var $=e.data,q=$.program,Q=$.privateKey,V=$.fee,Z=$.privateFee,ee=$.feeRecord,te=$.url;console.log("Web worker: Creating deployment...");var re=performance.now();m(v().mark((function e(){var t,r,o;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof te&&i.setHost(te),t=i.createProgramFromSource(q),r=!1,e.prev=4,e.next=7,i.networkClient.getProgram(t.id());case 7:r=!0,e.next=13;break;case 10:e.prev=10,e.t0=e.catch(4),console.log("Program not found on the Aleo Network - proceeding with deployment...");case 13:if(!r){e.next=15;break}throw"Program ".concat(t.id()," already exists on the network");case 15:return console.log("fee is: ",V),e.next=18,i.deploy(q,V,Z,void 0,ee,n.PrivateKey.from_string(Q));case 18:o=e.sent,console.log("Web worker: Deployment transaction ".concat(o," created in ").concat(performance.now()-re," ms")),self.postMessage({type:"DEPLOY_TRANSACTION_COMPLETED",deployTransaction:o}),e.next=27;break;case 23:e.prev=23,e.t1=e.catch(0),console.log(e.t1),self.postMessage({type:"ERROR",errorMessage:e.t1.toString()});case 27:return e.prev=27,i.setHost(a),e.finish(27);case 30:case"end":return e.stop()}}),e,null,[[0,23,27,30],[4,10]])})))()}else if("ALEO_SPLIT"===e.data.type){var ne=e.data,oe=ne.splitAmount,ae=ne.record,ce=ne.privateKey,ie=ne.url;console.log("Web worker: Creating split...");var se=performance.now();m(v().mark((function e(){var t;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof ie&&i.setHost(ie),e.next=4,i.split(oe,ae,n.PrivateKey.from_string(ce),void 0);case 4:t=e.sent,console.log("Web worker: Split transaction ".concat(t," created in ").concat(performance.now()-se," ms")),self.postMessage({type:"SPLIT_TRANSACTION_COMPLETED",splitTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,i.setHost(a),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}else if("ALEO_JOIN"===e.data.type){var ue=e.data,le=ue.recordOne,fe=ue.recordTwo,pe=ue.fee,ye=ue.privateFee,he=ue.feeRecord,ve=ue.privateKey,ge=ue.url;console.log("Web worker: Creating join...");var me=performance.now();m(v().mark((function e(){var t;return v().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,"string"==typeof ge&&i.setHost(ge),e.next=4,i.join(le,fe,pe,ye,void 0,he,n.PrivateKey.from_string(ve),void 0);case 4:t=e.sent,console.log("Web worker: Join transaction ".concat(t," created in ").concat(performance.now()-me," ms")),self.postMessage({type:"JOIN_TRANSACTION_COMPLETED",joinTransaction:t}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0),self.postMessage({type:"ERROR",errorMessage:e.t0.toString()});case 13:return e.prev=13,i.setHost(a),e.finish(13);case 16:case"end":return e.stop()}}),e,null,[[0,9,13,16]])})))()}})),t()}catch(d){t(d)}}),1)}}]); -//# sourceMappingURL=66.bundle.js.map \ No newline at end of file diff --git a/66.bundle.js.LICENSE.txt b/66.bundle.js.LICENSE.txt deleted file mode 100644 index ae386fb79..000000000 --- a/66.bundle.js.LICENSE.txt +++ /dev/null @@ -1 +0,0 @@ -/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ diff --git a/66.bundle.js.map b/66.bundle.js.map deleted file mode 100644 index 9650655c8..000000000 --- a/66.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"66.bundle.js","mappings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AnE,GAAMD,aACrB,QAEiC,OAFjCoE,EAAAjI,KAAA,GAEHkB,EAAe0D,QAAQ5D,GAAaiH,EAAA1H,OAAA,6BAAA0H,EAAA9H,OAAA,GAAA6H,EAAA,uBA/B5CtH,EAkCJ,CACJ","sources":["webpack://aleo-website/./src/workers/worker.js"],"sourcesContent":["import * as aleo from \"@provablehq/sdk\";\n\nawait aleo.initThreadPool();\n\nconst defaultHost = \"https://api.explorer.aleo.org/v1\";\nconst keyProvider = new aleo.AleoKeyProvider();\nconst programManager = new aleo.ProgramManager(defaultHost, keyProvider, undefined);\nkeyProvider.useCache(true);\n\nself.postMessage({\n type: \"ALEO_WORKER_READY\",\n});\n\nlet lastLocalProgram = null;\nself.addEventListener(\"message\", (ev) => {\n if (ev.data.type === \"ALEO_EXECUTE_PROGRAM_LOCAL\") {\n const { localProgram, aleoFunction, inputs, privateKey } = ev.data;\n\n console.log(\"Web worker: Executing function locally...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey);\n // Ensure the program is valid and that it contains the function specified\n const program = programManager.createProgramFromSource(localProgram);\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw `Program ${program_id} does not contain function ${aleoFunction}`;\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n\n // Get the program imports\n const imports = programManager.networkClient.getProgramImports(localProgram);\n\n // Get the proving and verifying keys for the function\n if (lastLocalProgram !== localProgram) {\n const keys = await programManager.synthesizeKeys(localProgram, aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n lastLocalProgram = localProgram;\n }\n\n // Pass the cache key to the execute function\n const keyParams = new aleo.AleoKeyProviderParams({\"cacheKey\": cacheKey});\n\n // Execute the function locally\n let response = await programManager.run(\n localProgram,\n aleoFunction,\n inputs,\n false,\n imports,\n keyParams,\n undefined,\n undefined,\n privateKeyObject,\n undefined\n );\n\n // Return the outputs to the main thread\n console.log(`Web worker: Local execution completed in ${performance.now() - startTime} ms`);\n const outputs = response.getOutputs();\n let execution = response.getExecution();\n if (execution) {\n aleo.verifyFunctionExecution(execution, keyProvider.getKeys(cacheKey)[1], program, \"hello\");\n execution = execution.toString();\n console.log(\"Execution verified successfully: \" + execution);\n } else {\n execution = \"\";\n }\n\n console.log(`Function execution response: ${outputs}`);\n self.postMessage({\n type: \"OFFLINE_EXECUTION_COMPLETED\",\n outputs: {outputs: outputs, execution: execution}\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_EXECUTE_PROGRAM_ON_CHAIN\") {\n const {\n remoteProgram,\n aleoFunction,\n inputs,\n privateKey,\n fee,\n privateFee,\n feeRecord,\n url,\n } = ev.data;\n\n console.log(\"Web worker: Creating execution...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey)\n // Ensure the program is valid and that it contains the function specified\n const program = await programManager.networkClient.getProgramObject(remoteProgram);\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw `Program ${program_id} does not contain function ${aleoFunction}`;\n }\n\n // Get the proving and verifying keys for the function\n const cacheKey = `${program_id}:${aleoFunction}`;\n if (!programManager.keyProvider.containsKeys(cacheKey)) {\n console.log(`Web worker: Synthesizing proving & verifying keys for: '${program_id}:${aleoFunction}'`);\n const keys = await programManager.synthesizeKeys(remoteProgram, aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n }\n\n // Pass the cache key to the execute function\n const keyParams = new aleo.AleoKeyProviderParams({\"cacheKey\": cacheKey})\n\n // Set the host to the provided URL if provided\n if (typeof url === \"string\") { programManager.setHost(url); }\n const transaction = await programManager.execute({\n programName: program_id,\n functionName: aleoFunction,\n fee: fee,\n privateFee: privateFee,\n inputs: inputs,\n keySearchParams: keyParams,\n feeRecord: feeRecord,\n privateKey: privateKeyObject\n });\n\n // Return the transaction id to the main thread\n console.log(`Web worker: On-chain execution transaction created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"EXECUTION_TRANSACTION_COMPLETED\",\n executeTransaction: transaction,\n });\n } catch (error) {\n console.error(`Error creating execution transaction: ${error}`);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_ESTIMATE_EXECUTION_FEE\") {\n const { remoteProgram, privateKey, aleoFunction, inputs, url } =\n ev.data;\n\n console.log(\"Web worker: Estimating execution fee...\");\n let startTime = performance.now();\n\n (async function () {\n try {\n const privateKeyObject = aleo.PrivateKey.from_string(privateKey);\n // Ensure the program is valid and that it contains the function specified\n const program = await programManager.networkClient.getProgramObject(remoteProgram);\n const program_id = program.id();\n if (!program.getFunctions().includes(aleoFunction)) {\n throw `Program ${program_id} does not contain function ${aleoFunction}`;\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n const imports = await programManager.networkClient.getProgramImports(remoteProgram);\n\n // Get the proving and verifying keys for the function\n if (!programManager.keyProvider.containsKeys(cacheKey)) {\n console.log(`Web worker: Synthesizing proving & verifying keys for: '${program_id}:${aleoFunction}'`);\n const keys = await programManager.synthesizeKeys(program.toString(), aleoFunction, inputs, privateKeyObject);\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n }\n\n // Estimate the execution fee\n const [provingKey, verifyingKey] = programManager.keyProvider.getKeys(cacheKey);\n let executeFee = await aleo.ProgramManagerBase.estimateExecutionFee(\n privateKeyObject,\n remoteProgram,\n aleoFunction,\n inputs,\n url,\n imports,\n provingKey,\n verifyingKey,\n undefined\n );\n\n // Return the execution fee estimate to the main thread\n console.log(`Web worker: Execution fee estimated in ${performance.now() - startTime} ms`);\n console.log(`Execution Fee Estimation: ${executeFee} microcredits`);\n self.postMessage({\n type: \"EXECUTION_FEE_ESTIMATION_COMPLETED\",\n executionFee: Number(executeFee) / 1000000 + 0.01,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_ESTIMATE_DEPLOYMENT_FEE\") {\n const { program, url } = ev.data;\n\n console.log(\"Web worker: Estimating deployment fee...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n const imports = await programManager.networkClient.getProgramImports(program);\n console.log(\"Estimating deployment fee..\");\n let deploymentFee =\n await aleo.ProgramManagerBase.estimateDeploymentFee(\n program,\n imports,\n );\n\n // Return the deployment fee estimate to the main thread\n console.log(`Web worker: Deployment fee estimation completed in ${performance.now() - startTime} ms`);\n console.log(`Deployment Fee Estimation: ${deploymentFee} microcredits`);\n self.postMessage({\n type: \"DEPLOYMENT_FEE_ESTIMATION_COMPLETED\",\n deploymentFee: Number(deploymentFee) / 1000000 + 0.01,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n }\n })();\n } else if (ev.data.type === \"ALEO_TRANSFER\") {\n const {\n privateKey,\n amountCredits,\n recipient,\n transfer_type,\n amountRecord,\n fee,\n privateFee,\n feeRecord,\n url,\n } = ev.data;\n\n console.log(\n `Web worker: Creating transfer of type ${transfer_type}...`,\n );\n let startTime = performance.now();\n\n (async function () {\n try {\n // Set the host to the provided URL if provided\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the transfer transaction and submit it to the network\n const transaction = await programManager.transfer(\n amountCredits,\n recipient,\n transfer_type,\n fee,\n privateFee,\n undefined,\n amountRecord,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Transfer transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"TRANSFER_TRANSACTION_COMPLETED\",\n transferTransaction: transaction,\n });\n } catch (error) {\n console.error(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_DEPLOY\") {\n const { program, privateKey, fee, privateFee, feeRecord, url } = ev.data;\n\n console.log(\"Web worker: Creating deployment...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Check if the program is valid\n const programObject = programManager.createProgramFromSource(program);\n\n // Check if the program already exists on the network. If so, throw an error\n let programExists = false;\n try {\n await programManager.networkClient.getProgram(programObject.id());\n programExists = true;\n } catch (e) {\n console.log(\n `Program not found on the Aleo Network - proceeding with deployment...`,\n );\n }\n\n if (programExists) {\n throw `Program ${programObject.id()} already exists on the network`;\n }\n\n console.log(\"fee is: \", fee);\n // Create the deployment transaction and submit it to the network\n let transaction = await programManager.deploy(\n program,\n fee,\n privateFee,\n undefined,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n )\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Deployment transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"DEPLOY_TRANSACTION_COMPLETED\",\n deployTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_SPLIT\") {\n const { splitAmount, record, privateKey, url } = ev.data;\n\n console.log(\"Web worker: Creating split...\");\n\n let startTime = performance.now();\n (async function () {\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the split transaction and submit to the network\n const transaction = await programManager.split(\n splitAmount,\n record,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Split transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"SPLIT_TRANSACTION_COMPLETED\",\n splitTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n } else if (ev.data.type === \"ALEO_JOIN\") {\n const { recordOne, recordTwo, fee, privateFee, feeRecord, privateKey, url } =\n ev.data;\n\n console.log(\"Web worker: Creating join...\");\n\n let startTime = performance.now();\n (async function () {\n\n try {\n // Set the network client host if specified\n if (typeof url === \"string\") { programManager.setHost(url); }\n\n // Create the join transaction and submit it to the network\n const transaction = await programManager.join(\n recordOne,\n recordTwo,\n fee,\n privateFee,\n undefined,\n feeRecord,\n aleo.PrivateKey.from_string(privateKey),\n undefined\n );\n\n // Return the transaction id to the main thread\n console.log(`Web worker: Join transaction ${transaction} created in ${performance.now() - startTime} ms`);\n self.postMessage({\n type: \"JOIN_TRANSACTION_COMPLETED\",\n joinTransaction: transaction,\n });\n } catch (error) {\n console.log(error);\n self.postMessage({\n type: \"ERROR\",\n errorMessage: error.toString(),\n });\n } finally {\n programManager.setHost(defaultHost);\n }\n })();\n }\n});\n"],"names":["_regeneratorRuntime","e","t","r","Object","prototype","n","hasOwnProperty","o","defineProperty","value","i","Symbol","a","iterator","c","asyncIterator","u","toStringTag","define","enumerable","configurable","writable","wrap","Generator","create","Context","makeInvokeMethod","tryCatch","type","arg","call","h","l","f","s","y","GeneratorFunction","GeneratorFunctionPrototype","p","d","getPrototypeOf","v","values","g","defineIteratorMethods","forEach","_invoke","AsyncIterator","invoke","_typeof","resolve","__await","then","callInvokeWithMethodAndArg","Error","done","method","delegate","maybeInvokeDelegate","sent","_sent","dispatchException","abrupt","TypeError","resultName","next","nextLoc","pushTryEntry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","push","resetTryEntry","completion","reset","isNaN","length","displayName","isGeneratorFunction","constructor","name","mark","setPrototypeOf","__proto__","awrap","async","Promise","keys","reverse","pop","prev","charAt","slice","stop","rval","handle","complete","finish","delegateYield","asyncGeneratorStep","_asyncToGenerator","arguments","apply","_next","_throw","aleo","defaultHost","keyProvider","programManager","undefined","useCache","self","postMessage","lastLocalProgram","addEventListener","ev","data","_ev$data","localProgram","aleoFunction","inputs","privateKey","console","log","startTime","performance","now","_callee","privateKeyObject","program","program_id","cacheKey","imports","keyParams","response","outputs","execution","_context","from_string","createProgramFromSource","id","hasFunction","concat","networkClient","getProgramImports","synthesizeKeys","cacheKeys","run","getOutputs","getExecution","getKeys","toString","t0","error","errorMessage","_ev$data2","remoteProgram","fee","privateFee","feeRecord","url","_callee2","transaction","_context2","getProgramObject","containsKeys","setHost","execute","programName","functionName","keySearchParams","executeTransaction","_ev$data3","_callee3","_programManager$keyPr","_programManager$keyPr2","provingKey","verifyingKey","executeFee","_context3","getFunctions","includes","estimateExecutionFee","executionFee","Number","_ev$data4","_callee4","deploymentFee","_context4","estimateDeploymentFee","_ev$data5","amountCredits","recipient","transfer_type","amountRecord","_callee5","_context5","transfer","transferTransaction","_ev$data6","_callee6","programObject","programExists","_context6","getProgram","deploy","deployTransaction","t1","_ev$data7","splitAmount","record","_callee7","_context7","split","splitTransaction","_ev$data8","recordOne","recordTwo","_callee8","_context8","join","joinTransaction"],"sourceRoot":""} \ No newline at end of file diff --git a/682.bundle.js b/682.bundle.js index 75bcf5aad..4cbb6dffd 100644 --- a/682.bundle.js +++ b/682.bundle.js @@ -1,2 +1,2 @@ -(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,879,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={682:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,879,312].map(c.e,c)).then(n);c.x()})(); +(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,857,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={682:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,857,312].map(c.e,c)).then(n);c.x()})(); //# sourceMappingURL=682.bundle.js.map \ No newline at end of file diff --git a/682.bundle.js.map b/682.bundle.js.map index aa853063a..5faf354ae 100644 --- a/682.bundle.js.map +++ b/682.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"682.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC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aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,879,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,879,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t682: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"682.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAA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AAYG,EAASC,cAAcG,MAC/BP,GAAW,CACf,IAAIQ,EAAUL,EAASM,qBAAqB,UAC5C,GAAGD,EAAQnC,OAEV,IADA,IAAID,EAAIoC,EAAQnC,OAAS,EAClBD,GAAK,KAAO4B,IAAc,aAAaU,KAAKV,KAAaA,EAAYQ,EAAQpC,KAAKmC,GAE3F,CAID,IAAKP,EAAW,MAAM,IAAIW,MAAM,yDAChCX,EAAYA,EAAUY,QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpF1F,EAAoB2F,EAAIb,C,WClBxB9E,EAAoB4F,EAAIC,KAAKb,SAAW,GAIxC,IAAIc,EAAkB,CACrB,IAAK,GAgBN9F,EAAoBgE,EAAEd,EAAI,CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,857,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,857,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t682: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/68537c70e60b0878e521.js b/68537c70e60b0878e521.js new file mode 100644 index 000000000..4df7d03f6 --- /dev/null +++ b/68537c70e60b0878e521.js @@ -0,0 +1 @@ +let _;const t=new Array(128).fill(void 0);function e(_){return t[_]}t.push(void 0,null,!0,!1);let r=t.length;function n(_){const n=e(_);return function(_){_<132||(t[_]=r,r=_)}(_),n}const i="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&i.decode();let o=null;function a(){return null!==o&&o.buffer===_.memory.buffer||(o=new Uint8Array(_.memory.buffer)),o}function s(_,t){return _>>>=0,i.decode(a().slice(_,_+t))}function c(_){r===t.length&&t.push(t.length+1);const e=r;return r=t[e],t[e]=_,e}let g=0;const w="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}};function d(_,t,e){if(void 0===e){const e=w.encode(_),r=t(e.length,1)>>>0;return a().subarray(r,r+e.length).set(e),g=e.length,r}let r=_.length,n=t(r,1)>>>0;const i=a();let o=0;for(;o127)break;i[n+o]=t}if(o!==r){0!==o&&(_=_.slice(o)),n=e(n,r,r=o+3*_.length,1)>>>0;const t=function(_,t){const e=w.encode(_);return t.set(e),{read:_.length,written:e.length}}(_,a().subarray(n+o,n+r));o+=t.written,n=e(n,r,o,1)>>>0}return g=o,n}function b(_){return null==_}let l=null;function u(){return null!==l&&l.buffer===_.memory.buffer||(l=new Int32Array(_.memory.buffer)),l}function f(_){const t=typeof _;if("number"==t||"boolean"==t||null==_)return`${_}`;if("string"==t)return`"${_}"`;if("symbol"==t){const t=_.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=_.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(_)){const t=_.length;let e="[";t>0&&(e+=f(_[0]));for(let r=1;r1))return toString.call(_);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(_)+")"}catch(_){return"Object"}return _ instanceof Error?`${_.name}: ${_.message}\n${_.stack}`:r}const p="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>{_.__wbindgen_export_3.get(t.dtor)(t.a,t.b)}));function y(t,e,r,n){const i={a:t,b:e,cnt:1,dtor:r},o=(...t)=>{i.cnt++;const e=i.a;i.a=0;try{return n(e,i.b,...t)}finally{0==--i.cnt?(_.__wbindgen_export_3.get(i.dtor)(e,i.b),p.unregister(i)):i.a=e}};return o.original=i,p.register(o,i,i),o}function m(t,e,r){_._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6a363ba3fe56b221(t,e,c(r))}function h(_,t){if(!(_ instanceof t))throw new Error(`expected instance of ${t.name}`);return _.ptr}function v(_,t){const e=t(1*_.length,1)>>>0;return a().set(_,e/1),g=_.length,e}let k=null;function P(){return null!==k&&k.buffer===_.memory.buffer||(k=new BigInt64Array(_.memory.buffer)),k}function S(_,t){return _>>>=0,a().subarray(_/1,_/1+t)}function V(t,e){try{return t.apply(this,e)}catch(t){_.__wbindgen_exn_store(c(t))}}const x="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_address_free(t>>>0)));class F{static __wrap(_){_>>>=0;const t=Object.create(F.prototype);return t.__wbg_ptr=_,x.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,x.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_address_free(t)}static from_private_key(t){h(t,q);const e=_.address_from_private_key(t.__wbg_ptr);return F.__wrap(e)}static from_view_key(t){h(t,o_);const e=_.address_from_view_key(t.__wbg_ptr);return F.__wrap(e)}static from_string(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.address_from_string(e,r);return F.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.address_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}verify(t,e){const r=v(t,_.__wbindgen_malloc),n=g;h(e,__);return 0!==_.address_verify(this.__wbg_ptr,r,n,e.__wbg_ptr)}}const T="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_execution_free(t>>>0)));class R{static __wrap(_){_>>>=0;const t=Object.create(R.prototype);return t.__wbg_ptr=_,T.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,T.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_execution_free(t)}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.execution_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.execution_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return R.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_executionresponse_free(t>>>0)));class A{static __wrap(_){_>>>=0;const t=Object.create(A.prototype);return t.__wbg_ptr=_,z.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,z.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_executionresponse_free(t)}getOutputs(){return n(_.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const t=_.executionresponse_getExecution(this.__wbg_ptr);return 0===t?void 0:R.__wrap(t)}getKeys(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.executionresponse_getKeys(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return K.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const t=_.executionresponse_getProvingKey(this.__wbg_ptr);return 0===t?void 0:L.__wrap(t)}getVerifyingKey(){const t=_.executionresponse_getVerifyingKey(this.__wbg_ptr);return n_.__wrap(t)}getFunctionId(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.executionresponse_getFunctionId(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}getProgram(){const t=_.executionresponse_getProgram(this.__wbg_ptr);return D.__wrap(t)}}const O="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_field_free(t>>>0)));class j{static __wrap(_){_>>>=0;const t=Object.create(j.prototype);return t.__wbg_ptr=_,O.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,O.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_field_free(t)}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.field_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.field_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return j.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const B="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_keypair_free(t>>>0)));class K{static __wrap(_){_>>>=0;const t=Object.create(K.prototype);return t.__wbg_ptr=_,B.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,B.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_keypair_free(t)}constructor(t,e){h(t,L);var r=t.__destroy_into_raw();h(e,n_);var n=e.__destroy_into_raw();const i=_.keypair_new(r,n);return this.__wbg_ptr=i>>>0,this}provingKey(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.keypair_provingKey(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return L.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.keypair_verifyingKey(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return n_.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const M="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_metadata_free(t>>>0)));class E{static __wrap(_){_>>>=0;const t=Object.create(E.prototype);return t.__wbg_ptr=_,M.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,M.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_metadata_free(t)}get name(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_name(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set name(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_name(this.__wbg_ptr,e,r)}get locator(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_locator(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set locator(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_locator(this.__wbg_ptr,e,r)}get prover(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_prover(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set prover(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_prover(this.__wbg_ptr,e,r)}get verifier(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_verifier(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set verifier(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_verifier(this.__wbg_ptr,e,r)}get verifyingKey(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_verifyingKey(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set verifyingKey(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,e,r)}static baseUrl(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.metadata_baseUrl(i);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static bond_public(){const t=_.metadata_bond_public();return E.__wrap(t)}static bond_validator(){const t=_.metadata_bond_validator();return E.__wrap(t)}static claim_unbond_public(){const t=_.metadata_claim_unbond_public();return E.__wrap(t)}static fee_private(){const t=_.metadata_fee_private();return E.__wrap(t)}static fee_public(){const t=_.metadata_fee_public();return E.__wrap(t)}static inclusion(){const t=_.metadata_inclusion();return E.__wrap(t)}static join(){const t=_.metadata_join();return E.__wrap(t)}static set_validator_state(){const t=_.metadata_set_validator_state();return E.__wrap(t)}static split(){const t=_.metadata_split();return E.__wrap(t)}static transfer_private(){const t=_.metadata_transfer_private();return E.__wrap(t)}static transfer_private_to_public(){const t=_.metadata_transfer_private_to_public();return E.__wrap(t)}static transfer_public(){const t=_.metadata_transfer_public();return E.__wrap(t)}static transfer_public_as_signer(){const t=_.metadata_transfer_public_as_signer();return E.__wrap(t)}static transfer_public_to_private(){const t=_.metadata_transfer_public_to_private();return E.__wrap(t)}static unbond_public(){const t=_.metadata_unbond_public();return E.__wrap(t)}}const I="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_offlinequery_free(t>>>0)));class U{static __wrap(_){_>>>=0;const t=Object.create(U.prototype);return t.__wbg_ptr=_,I.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,I.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_offlinequery_free(t)}constructor(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16),a=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g;_.offlinequery_new(o,t,a,s);var r=u()[o/4+0],i=u()[o/4+1];if(u()[o/4+2])throw n(i);return this.__wbg_ptr=r>>>0,this}finally{_.__wbindgen_add_to_stack_pointer(16)}}addBlockHeight(t){_.offlinequery_addBlockHeight(this.__wbg_ptr,t)}addStatePath(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g,s=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),c=g;_.offlinequery_addStatePath(i,this.__wbg_ptr,o,a,s,c);var r=u()[i/4+0];if(u()[i/4+1])throw n(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.offlinequery_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.offlinequery_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return U.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const C="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_privatekey_free(t>>>0)));class q{static __wrap(_){_>>>=0;const t=Object.create(q.prototype);return t.__wbg_ptr=_,C.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,C.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_privatekey_free(t)}constructor(){const t=_.privatekey_new();return this.__wbg_ptr=t>>>0,this}static from_seed_unchecked(t){const e=v(t,_.__wbindgen_malloc),r=g,n=_.privatekey_from_seed_unchecked(e,r);return q.__wrap(n)}static from_string(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_from_string(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return q.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.privatekey_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}to_view_key(){const t=_.privatekey_to_view_key(this.__wbg_ptr);return o_.__wrap(t)}to_address(){const t=_.privatekey_to_address(this.__wbg_ptr);return F.__wrap(t)}sign(t){const e=v(t,_.__wbindgen_malloc),r=g,n=_.privatekey_sign(this.__wbg_ptr,e,r);return __.__wrap(n)}static newEncrypted(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_newEncrypted(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return N.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_toCiphertext(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return N.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16);h(t,N);const a=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g;_.privatekey_fromPrivateKeyCiphertext(o,t.__wbg_ptr,a,s);var r=u()[o/4+0],i=u()[o/4+1];if(u()[o/4+2])throw n(i);return q.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const W="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_privatekeyciphertext_free(t>>>0)));class N{static __wrap(_){_>>>=0;const t=Object.create(N.prototype);return t.__wbg_ptr=_,W.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,W.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_privatekeyciphertext_free(t)}static encryptPrivateKey(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16);h(t,q);const a=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g;_.privatekey_toCiphertext(o,t.__wbg_ptr,a,s);var r=u()[o/4+0],i=u()[o/4+1];if(u()[o/4+2])throw n(i);return N.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekeyciphertext_decryptToPrivateKey(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return q.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.privatekeyciphertext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekeyciphertext_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return N.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const $="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_program_free(t>>>0)));class D{static __wrap(_){_>>>=0;const t=Object.create(D.prototype);return t.__wbg_ptr=_,$.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,$.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_program_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return D.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.program_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}hasFunction(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;return 0!==_.program_hasFunction(this.__wbg_ptr,e,r)}getFunctions(){return n(_.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getFunctionInputs(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.program_getMappings(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return n(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getRecordMembers(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getStructMembers(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=_.program_getCreditsProgram();return D.__wrap(t)}id(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.program_id(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}address(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.program_address(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return F.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){h(t,D);return 0!==_.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return n(_.program_getImports(this.__wbg_ptr))}}const J="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_programmanager_free(t>>>0)));const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_provingkey_free(t>>>0)));class L{static __wrap(_){_>>>=0;const t=Object.create(L.prototype);return t.__wbg_ptr=_,H.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_provingkey_free(t)}isBondPublicProver(){return 0!==_.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==_.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==_.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==_.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==_.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==_.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==_.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==_.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==_.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==_.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==_.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==_.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==_.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==_.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==_.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_checksum(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}copy(){const t=_.provingkey_copy(this.__wbg_ptr);return L.__wrap(t)}static fromBytes(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=v(t,_.__wbindgen_malloc),a=g;_.provingkey_fromBytes(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return L.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.provingkey_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return L.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const o=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_toBytes(o,this.__wbg_ptr);var t=u()[o/4+0],e=u()[o/4+1],r=u()[o/4+2];if(u()[o/4+3])throw n(r);var i=S(t,e).slice();return _.__wbindgen_free(t,1*e,1),i}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const Q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_recordciphertext_free(t>>>0)));class X{static __wrap(_){_>>>=0;const t=Object.create(X.prototype);return t.__wbg_ptr=_,Q.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Q.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_recordciphertext_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.recordciphertext_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return X.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordciphertext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}decrypt(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16);h(t,o_),_.recordciphertext_decrypt(i,this.__wbg_ptr,t.__wbg_ptr);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return Y.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}isOwner(t){h(t,o_);return 0!==_.recordciphertext_isOwner(this.__wbg_ptr,t.__wbg_ptr)}}const G="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_recordplaintext_free(t>>>0)));class Y{static __wrap(_){_>>>=0;const t=Object.create(Y.prototype);return t.__wbg_ptr=_,G.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,G.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_recordplaintext_free(t)}commitment(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16),a=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,c=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.recordplaintext_commitment(o,this.__wbg_ptr,a,s,c,w);var r=u()[o/4+0],i=u()[o/4+1];if(u()[o/4+2])throw n(i);return j.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.recordplaintext_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return Y.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordplaintext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}microcredits(){const t=_.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,t)}nonce(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordplaintext_nonce(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}serialNumberString(t,e,r){let i,o;try{const p=_.__wbindgen_add_to_stack_pointer(-16);h(t,q);const y=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g,v=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),k=g;_.recordplaintext_serialNumberString(p,this.__wbg_ptr,t.__wbg_ptr,y,m,v,k);var a=u()[p/4+0],c=u()[p/4+1],w=u()[p/4+2],b=u()[p/4+3],l=a,f=c;if(b)throw l=0,f=0,n(w);return i=l,o=f,s(l,f)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(i,o,1)}}}const Z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_signature_free(t>>>0)));class __{static __wrap(_){_>>>=0;const t=Object.create(__.prototype);return t.__wbg_ptr=_,Z.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_signature_free(t)}static sign(t,e){h(t,q);const r=v(e,_.__wbindgen_malloc),n=g,i=_.privatekey_sign(t.__wbg_ptr,r,n);return __.__wrap(i)}verify(t,e){h(t,F);const r=v(e,_.__wbindgen_malloc),n=g;return 0!==_.signature_verify(this.__wbg_ptr,t.__wbg_ptr,r,n)}static from_string(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.signature_from_string(e,r);return __.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.signature_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const t_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_transaction_free(t>>>0)));class e_{static __wrap(_){_>>>=0;const t=Object.create(e_.prototype);return t.__wbg_ptr=_,t_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,t_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_transaction_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.transaction_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return e_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}transactionId(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_transactionId(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}transactionType(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_transactionType(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const r_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_verifyingkey_free(t>>>0)));class n_{static __wrap(_){_>>>=0;const t=Object.create(n_.prototype);return t.__wbg_ptr=_,r_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,r_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_verifyingkey_free(t)}static bondPublicVerifier(){const t=_.verifyingkey_bondPublicVerifier();return n_.__wrap(t)}static bondValidatorVerifier(){const t=_.verifyingkey_bondValidatorVerifier();return n_.__wrap(t)}static claimUnbondPublicVerifier(){const t=_.verifyingkey_claimUnbondPublicVerifier();return n_.__wrap(t)}static feePrivateVerifier(){const t=_.verifyingkey_feePrivateVerifier();return n_.__wrap(t)}static feePublicVerifier(){const t=_.verifyingkey_feePublicVerifier();return n_.__wrap(t)}static inclusionVerifier(){const t=_.verifyingkey_inclusionVerifier();return n_.__wrap(t)}static joinVerifier(){const t=_.verifyingkey_joinVerifier();return n_.__wrap(t)}static setValidatorStateVerifier(){const t=_.verifyingkey_setValidatorStateVerifier();return n_.__wrap(t)}static splitVerifier(){const t=_.verifyingkey_splitVerifier();return n_.__wrap(t)}static transferPrivateVerifier(){const t=_.verifyingkey_transferPrivateVerifier();return n_.__wrap(t)}static transferPrivateToPublicVerifier(){const t=_.verifyingkey_transferPrivateToPublicVerifier();return n_.__wrap(t)}static transferPublicVerifier(){const t=_.verifyingkey_transferPublicVerifier();return n_.__wrap(t)}static transferPublicAsSignerVerifier(){const t=_.verifyingkey_transferPublicAsSignerVerifier();return n_.__wrap(t)}static transferPublicToPrivateVerifier(){const t=_.verifyingkey_transferPublicToPrivateVerifier();return n_.__wrap(t)}static unbondPublicVerifier(){const t=_.verifyingkey_unbondPublicVerifier();return n_.__wrap(t)}isBondPublicVerifier(){return 0!==_.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==_.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==_.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==_.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==_.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==_.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==_.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==_.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==_.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==_.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==_.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==_.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==_.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==_.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==_.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_checksum(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}copy(){const t=_.verifyingkey_copy(this.__wbg_ptr);return n_.__wrap(t)}static fromBytes(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=v(t,_.__wbindgen_malloc),a=g;_.verifyingkey_fromBytes(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.verifyingkey_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const o=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_toBytes(o,this.__wbg_ptr);var t=u()[o/4+0],e=u()[o/4+1],r=u()[o/4+2];if(u()[o/4+3])throw n(r);var i=S(t,e).slice();return _.__wbindgen_free(t,1*e,1),i}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const i_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_viewkey_free(t>>>0)));class o_{static __wrap(_){_>>>=0;const t=Object.create(o_.prototype);return t.__wbg_ptr=_,i_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,i_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_viewkey_free(t)}static from_private_key(t){h(t,q);const e=_.privatekey_to_view_key(t.__wbg_ptr);return o_.__wrap(e)}static from_string(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.viewkey_from_string(e,r);return o_.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.viewkey_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}to_address(){const t=_.address_from_view_key(this.__wbg_ptr);return F.__wrap(t)}decrypt(t){let e,r;try{const l=_.__wbindgen_add_to_stack_pointer(-16),f=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),p=g;_.viewkey_decrypt(l,this.__wbg_ptr,f,p);var i=u()[l/4+0],o=u()[l/4+1],a=u()[l/4+2],c=u()[l/4+3],w=i,b=o;if(c)throw w=0,b=0,n(a);return e=w,r=b,s(w,b)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(e,r,1)}}}function a_(){const t={wbg:{}};return t.wbg.__wbindgen_object_drop_ref=function(_){n(_)},t.wbg.__wbg_new_71801a555ad9f2aa=function(){return V((function(){return c(new XMLHttpRequest)}),arguments)},t.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return V((function(_,t,r){e(_).overrideMimeType(s(t,r))}),arguments)},t.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return V((function(_,t,r,n,i,o){e(_).open(s(t,r),s(n,i),0!==o)}),arguments)},t.wbg.__wbg_send_80d29985093c1ec5=function(){return V((function(_){e(_).send()}),arguments)},t.wbg.__wbg_response_7c2e2759084f7279=function(){return V((function(_){return c(e(_).response)}),arguments)},t.wbg.__wbg_status_d485fb5a478426fb=function(){return V((function(_){return e(_).status}),arguments)},t.wbg.__wbg_new_72fb9a18b5ae2624=function(){return c(new Object)},t.wbg.__wbindgen_string_new=function(_,t){return c(s(_,t))},t.wbg.__wbg_set_1f9b04f170055d33=function(){return V((function(_,t,r){return Reflect.set(e(_),e(t),e(r))}),arguments)},t.wbg.__wbg_new_ab6fd82b10560829=function(){return V((function(){return c(new Headers)}),arguments)},t.wbg.__wbindgen_object_clone_ref=function(_){return c(e(_))},t.wbg.__wbg_new_0d76b0581eca6298=function(){return V((function(){return c(new AbortController)}),arguments)},t.wbg.__wbg_signal_a61f78a3478fd9bc=function(_){return c(e(_).signal)},t.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return V((function(_,t,r,n,i){e(_).append(s(t,r),s(n,i))}),arguments)},t.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(_){let t;try{t=e(_)instanceof Response}catch(_){t=!1}return t},t.wbg.__wbg_status_61a01141acd3cf74=function(_){return e(_).status},t.wbg.__wbg_url_5f6dc4009ac5f99d=function(t,r){const n=d(e(r).url,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;u()[t/4+1]=i,u()[t/4+0]=n},t.wbg.__wbg_headers_9620bfada380764a=function(_){return c(e(_).headers)},t.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return c(Symbol.iterator)},t.wbg.__wbg_get_e3c254076557e348=function(){return V((function(_,t){return c(Reflect.get(e(_),e(t)))}),arguments)},t.wbg.__wbindgen_is_function=function(_){return"function"==typeof e(_)},t.wbg.__wbg_call_27c0f87801dedf93=function(){return V((function(_,t){return c(e(_).call(e(t)))}),arguments)},t.wbg.__wbindgen_is_object=function(_){const t=e(_);return"object"==typeof t&&null!==t},t.wbg.__wbg_next_40fc327bfc8770e6=function(_){return c(e(_).next)},t.wbg.__wbg_next_196c84450b364254=function(){return V((function(_){return c(e(_).next())}),arguments)},t.wbg.__wbg_done_298b57d23c0fc80c=function(_){return e(_).done},t.wbg.__wbg_value_d93c65011f51a456=function(_){return c(e(_).value)},t.wbg.__wbg_abort_2aa7521d5690750e=function(_){e(_).abort()},t.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return V((function(_){return c(JSON.stringify(e(_)))}),arguments)},t.wbg.__wbindgen_string_get=function(t,r){const n=e(r),i="string"==typeof n?n:void 0;var o=b(i)?0:d(i,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;u()[t/4+1]=a,u()[t/4+0]=o},t.wbg.__wbg_log_eb85b4536c227931=function(_,t){console.log(s(_,t))},t.wbg.__wbindgen_bigint_from_u64=function(_){return c(BigInt.asUintN(64,_))},t.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return V((function(_,t,r){return c(e(_).call(e(t),e(r)))}),arguments)},t.wbg.__wbg_transaction_new=function(_){return c(e_.__wrap(_))},t.wbg.__wbg_executionresponse_new=function(_){return c(A.__wrap(_))},t.wbg.__wbg_keypair_new=function(_){return c(K.__wrap(_))},t.wbg.__wbg_newwithlength_66ae46612e7f0234=function(_){return c(new Array(_>>>0))},t.wbg.__wbg_set_d4638f722068f043=function(_,t,r){e(_)[t>>>0]=n(r)},t.wbg.__wbindgen_module=function(){return c(g_.__wbindgen_wasm_module)},t.wbg.__wbindgen_memory=function(){return c(_.memory)},t.wbg.__wbg_spawnWorker_4026f00664f3193f=function(_,t,r,n){return c(function(_,t,e,r){return new Promise((n=>{const i=new Worker(_,{type:"module"});i.addEventListener("message",(_=>{setTimeout((()=>{n(i),i.unref&&i.unref()}),0)}),{capture:!0,once:!0}),i.postMessage({module:t,memory:e,address:r})}))}(e(_),e(t),e(r),n>>>0))},t.wbg.__wbindgen_cb_drop=function(_){const t=n(_).original;if(1==t.cnt--)return t.a=0,!0;return!1},t.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return c(new Array)},t.wbg.__wbg_push_a5b05aedc7234f9f=function(_,t){return e(_).push(e(t))},t.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return V((function(_){return c(e(_).arrayBuffer())}),arguments)},t.wbg.__wbg_new_63b92bc8671ed464=function(_){return c(new Uint8Array(e(_)))},t.wbg.__wbg_length_c20a40f15020d68a=function(_){return e(_).length},t.wbg.__wbg_new_81740750da40724f=function(t,e){try{var r={a:t,b:e};const n=new Promise(((t,e)=>{const n=r.a;r.a=0;try{return function(t,e,r,n){_.wasm_bindgen__convert__closures__invoke2_mut__h3c510d875601a93b(t,e,c(r),c(n))}(n,r.b,t,e)}finally{r.a=n}}));return c(n)}finally{r.a=r.b=0}},t.wbg.__wbindgen_number_new=function(_){return c(_)},t.wbg.__wbg_new_abda76e883ba8a5f=function(){return c(new Error)},t.wbg.__wbg_stack_658279fe44541cf6=function(t,r){const n=d(e(r).stack,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;u()[t/4+1]=i,u()[t/4+0]=n},t.wbg.__wbg_error_f851667af71bcfc6=function(t,e){let r,n;try{r=t,n=e,console.error(s(t,e))}finally{_.__wbindgen_free(r,n,1)}},t.wbg.__wbg_buffer_12d079cc21e14bdb=function(_){return c(e(_).buffer)},t.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(_,t,r){return c(new Uint8Array(e(_),t>>>0,r>>>0))},t.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return V((function(_,t){e(_).randomFillSync(n(t))}),arguments)},t.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(_,t,r){return c(e(_).subarray(t>>>0,r>>>0))},t.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return V((function(_,t){e(_).getRandomValues(e(t))}),arguments)},t.wbg.__wbg_set_a47bac70306a19a7=function(_,t,r){e(_).set(e(t),r>>>0)},t.wbg.__wbg_crypto_1d1f22824a6a080c=function(_){return c(e(_).crypto)},t.wbg.__wbg_process_4a72847cc503995b=function(_){return c(e(_).process)},t.wbg.__wbg_versions_f686565e586dd935=function(_){return c(e(_).versions)},t.wbg.__wbg_node_104a2ff8d6ea03a2=function(_){return c(e(_).node)},t.wbg.__wbindgen_is_string=function(_){return"string"==typeof e(_)},t.wbg.__wbg_require_cca90b1a94a0255b=function(){return V((function(){return c(module.require)}),arguments)},t.wbg.__wbg_msCrypto_eb05e62b530a1508=function(_){return c(e(_).msCrypto)},t.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(_){return c(new Uint8Array(_>>>0))},t.wbg.__wbg_length_cd7af8117672b8b8=function(_){return e(_).length},t.wbg.__wbg_get_bd8e338fbd5f5cc8=function(_,t){return c(e(_)[t>>>0])},t.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return V((function(){return c(self.self)}),arguments)},t.wbg.__wbg_window_c6fb939a7f436783=function(){return V((function(){return c(window.window)}),arguments)},t.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return V((function(){return c(globalThis.globalThis)}),arguments)},t.wbg.__wbg_global_207b558942527489=function(){return V((function(){return c(global.global)}),arguments)},t.wbg.__wbindgen_is_undefined=function(_){return void 0===e(_)},t.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(_,t){return c(new Function(s(_,t)))},t.wbg.__wbg_has_0af94d20077affa2=function(){return V((function(_,t){return Reflect.has(e(_),e(t))}),arguments)},t.wbg.__wbg_fetch_bc7c8e27076a5c84=function(_){return c(fetch(e(_)))},t.wbg.__wbg_fetch_921fad6ef9e883dd=function(_,t){return c(e(_).fetch(e(t)))},t.wbg.__wbindgen_debug_string=function(t,r){const n=d(f(e(r)),_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;u()[t/4+1]=i,u()[t/4+0]=n},t.wbg.__wbindgen_throw=function(_,t){throw new Error(s(_,t))},t.wbg.__wbindgen_rethrow=function(_){throw n(_)},t.wbg.__wbg_then_a73caa9a87991566=function(_,t,r){return c(e(_).then(e(t),e(r)))},t.wbg.__wbg_then_0c86a60e8fcfe9f6=function(_,t){return c(e(_).then(e(t)))},t.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(_){queueMicrotask(e(_))},t.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(_){return c(e(_).queueMicrotask)},t.wbg.__wbg_resolve_b0083a7967828ec8=function(_){return c(Promise.resolve(e(_)))},t.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return c(Atomics.waitAsync)},t.wbg.__wbg_new_8cccba86b0f574cb=function(_){return c(new Int32Array(e(_)))},t.wbg.__wbg_waitAsync_46d5c36955b71a79=function(_,t,r){return c(Atomics.waitAsync(e(_),t,r))},t.wbg.__wbg_async_19c0400d97cc72fe=function(_){return e(_).async},t.wbg.__wbg_value_571d60108110e917=function(_){return c(e(_).value)},t.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(t){const e=d("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;u()[t/4+1]=r,u()[t/4+0]=e},t.wbg.__wbg_new_d1187ae36d662ef9=function(){return V((function(_,t){return c(new Worker(s(_,t)))}),arguments)},t.wbg.__wbg_setonmessage_503809e5bb51bd33=function(_,t){e(_).onmessage=e(t)},t.wbg.__wbg_of_6a70eed8d41f469c=function(_,t,r){return c(Array.of(e(_),e(t),e(r)))},t.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return V((function(_,t){e(_).postMessage(e(t))}),arguments)},t.wbg.__wbg_data_3ce7c145ca4fbcdc=function(_){return c(e(_).data)},t.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return V((function(_,t,r){return c(new Request(s(_,t),e(r)))}),arguments)},t.wbg.__wbg_responseText_c67ed2d48db10769=function(){return V((function(t,r){const n=e(r).responseText;var i=b(n)?0:d(n,_.__wbindgen_malloc,_.__wbindgen_realloc),o=g;u()[t/4+1]=o,u()[t/4+0]=i}),arguments)},t.wbg.__wbindgen_closure_wrapper5994=function(_,t,e){return c(y(_,t,622,m))},t.wbg.__wbindgen_closure_wrapper6020=function(_,t,e){return c(y(_,t,622,m))},t}function s_(_,t){_.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function c_(t,e){return _=t.exports,g_.__wbindgen_wasm_module=e,k=null,l=null,o=null,_.__wbindgen_start(),_}async function g_(t,e){if(void 0!==_)return _;const r=a_();("string"==typeof t||"function"==typeof Request&&t instanceof Request||"function"==typeof URL&&t instanceof URL)&&(t=fetch(t)),s_(r,e);const{instance:n,module:i}=await async function(_,t){if("function"==typeof Response&&_ instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(_,t)}catch(t){if("application/wasm"==_.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await _.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(_,t);return e instanceof WebAssembly.Instance?{instance:e,module:_}:e}}(await t,r);return c_(n,i)}var w_=Object.freeze({__proto__:null,Address:F,Execution:R,ExecutionResponse:A,Field:j,KeyPair:K,Metadata:E,OfflineQuery:U,PrivateKey:q,PrivateKeyCiphertext:N,Program:D,ProgramManager:class{__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,J.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_programmanager_free(t)}static buildDeploymentTransaction(t,e,r,i,o,a,s,w,l){h(t,q);const u=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),f=g;let p=0;b(i)||(h(i,Y),p=i.__destroy_into_raw());var y=b(o)?0:d(o,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g;let v=0;b(s)||(h(s,L),v=s.__destroy_into_raw());let k=0;b(w)||(h(w,n_),k=w.__destroy_into_raw());let P=0;b(l)||(h(l,U),P=l.__destroy_into_raw());return n(_.programmanager_buildDeploymentTransaction(t.__wbg_ptr,u,f,r,p,y,m,b(a)?0:c(a),v,k,P))}static estimateDeploymentFee(t,e){const r=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;return n(_.programmanager_estimateDeploymentFee(r,i,b(e)?0:c(e)))}static estimateProgramNameCost(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.programmanager_estimateProgramNameCost(i,o,a);var e=P()[i/8+0],r=u()[i/4+2];if(u()[i/4+3])throw n(r);return BigInt.asUintN(64,e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(t,e,r,i,o,a,s,w,l,u,f){h(t,q);const p=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),y=g,m=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),v=g;let k=0;b(w)||(h(w,L),k=w.__destroy_into_raw());let P=0;b(l)||(h(l,n_),P=l.__destroy_into_raw());var S=b(u)?0:d(u,_.__wbindgen_malloc,_.__wbindgen_realloc),V=g;let x=0;b(f)||(h(f,U),x=f.__destroy_into_raw());return n(_.programmanager_executeFunctionOffline(t.__wbg_ptr,p,y,m,v,c(i),o,a,b(s)?0:c(s),k,P,S,V,x))}static buildExecutionTransaction(t,e,r,i,o,a,s,w,l,u,f,p,y){h(t,q);const m=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),v=g,k=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),P=g;let S=0;b(a)||(h(a,Y),S=a.__destroy_into_raw());var V=b(s)?0:d(s,_.__wbindgen_malloc,_.__wbindgen_realloc),x=g;let F=0;b(l)||(h(l,L),F=l.__destroy_into_raw());let T=0;b(u)||(h(u,n_),T=u.__destroy_into_raw());let R=0;b(f)||(h(f,L),R=f.__destroy_into_raw());let z=0;b(p)||(h(p,n_),z=p.__destroy_into_raw());let A=0;b(y)||(h(y,U),A=y.__destroy_into_raw());return n(_.programmanager_buildExecutionTransaction(t.__wbg_ptr,m,v,k,P,c(i),o,S,V,x,b(w)?0:c(w),F,T,R,z,A))}static estimateExecutionFee(t,e,r,i,o,a,s,w,l){h(t,q);const u=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),f=g,p=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),y=g;var m=b(o)?0:d(o,_.__wbindgen_malloc,_.__wbindgen_realloc),v=g;let k=0;b(s)||(h(s,L),k=s.__destroy_into_raw());let P=0;b(w)||(h(w,n_),P=w.__destroy_into_raw());let S=0;b(l)||(h(l,U),S=l.__destroy_into_raw());return n(_.programmanager_estimateExecutionFee(t.__wbg_ptr,u,f,p,y,c(i),m,v,b(a)?0:c(a),k,P,S))}static estimateFinalizeFee(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16),a=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,c=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.programmanager_estimateFinalizeFee(o,a,s,c,w);var r=P()[o/8+0],i=u()[o/4+2];if(u()[o/4+3])throw n(i);return BigInt.asUintN(64,r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(t,e,r,i,o,a,s,c,w,l,u){h(t,q),h(e,Y);var f=e.__destroy_into_raw();h(r,Y);var p=r.__destroy_into_raw();let y=0;b(o)||(h(o,Y),y=o.__destroy_into_raw());var m=b(a)?0:d(a,_.__wbindgen_malloc,_.__wbindgen_realloc),v=g;let k=0;b(s)||(h(s,L),k=s.__destroy_into_raw());let P=0;b(c)||(h(c,n_),P=c.__destroy_into_raw());let S=0;b(w)||(h(w,L),S=w.__destroy_into_raw());let V=0;b(l)||(h(l,n_),V=l.__destroy_into_raw());let x=0;b(u)||(h(u,U),x=u.__destroy_into_raw());return n(_.programmanager_buildJoinTransaction(t.__wbg_ptr,f,p,i,y,m,v,k,P,S,V,x))}static buildSplitTransaction(t,e,r,i,o,a,s){h(t,q),h(r,Y);var c=r.__destroy_into_raw(),w=b(i)?0:d(i,_.__wbindgen_malloc,_.__wbindgen_realloc),l=g;let u=0;b(o)||(h(o,L),u=o.__destroy_into_raw());let f=0;b(a)||(h(a,n_),f=a.__destroy_into_raw());let p=0;b(s)||(h(s,U),p=s.__destroy_into_raw());return n(_.programmanager_buildSplitTransaction(t.__wbg_ptr,e,c,w,l,u,f,p))}static buildTransferTransaction(t,e,r,i,o,a,s,c,w,l,u,f,p){h(t,q);const y=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g,v=d(i,_.__wbindgen_malloc,_.__wbindgen_realloc),k=g;let P=0;b(o)||(h(o,Y),P=o.__destroy_into_raw());let S=0;b(s)||(h(s,Y),S=s.__destroy_into_raw());var V=b(c)?0:d(c,_.__wbindgen_malloc,_.__wbindgen_realloc),x=g;let F=0;b(w)||(h(w,L),F=w.__destroy_into_raw());let T=0;b(l)||(h(l,n_),T=l.__destroy_into_raw());let R=0;b(u)||(h(u,L),R=u.__destroy_into_raw());let z=0;b(f)||(h(f,n_),z=f.__destroy_into_raw());let A=0;b(p)||(h(p,U),A=p.__destroy_into_raw());return n(_.programmanager_buildTransferTransaction(t.__wbg_ptr,e,y,m,v,k,P,a,S,V,x,F,T,R,z,A))}static synthesizeKeyPair(t,e,r,i,o){h(t,q);const a=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,w=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),l=g;return n(_.programmanager_synthesizeKeyPair(t.__wbg_ptr,a,s,w,l,c(i),b(o)?0:c(o)))}},ProvingKey:L,RecordCiphertext:X,RecordPlaintext:Y,Signature:__,Transaction:e_,VerifyingKey:n_,ViewKey:o_,default:g_,initSync:function(t,e){if(void 0!==_)return _;const r=a_();return s_(r,e),t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t)),c_(new WebAssembly.Instance(t,r),t)},initThreadPool:function(t,e){return n(_.initThreadPool(c(t),e))},runRayonThread:function(t){_.runRayonThread(t)},verifyFunctionExecution:function(t,e,r,i){try{const s=_.__wbindgen_add_to_stack_pointer(-16);h(t,R),h(e,n_),h(r,D);const c=d(i,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.verifyFunctionExecution(s,t.__wbg_ptr,e.__wbg_ptr,r.__wbg_ptr,c,w);var o=u()[s/4+0],a=u()[s/4+1];if(u()[s/4+2])throw n(a);return 0!==o}finally{_.__wbindgen_add_to_stack_pointer(16)}}});await async function(_){const[t,{module:e,memory:r,address:n}]=await Promise.all([_,new Promise((_=>{addEventListener("message",(t=>{_(t.data)}),{capture:!0,once:!0})}))]),i=await t({initializeHook:(_,t)=>_(e,r)});postMessage(null),i.runRayonThread(n),close()}((async(_={})=>{let{importHook:t,serverPath:e,initializeHook:r}=_,n="aleo_wasm.wasm";return null!=e&&(n=e+/[^\/\\]*$/.exec(n)[0]),null!=t&&(n=t(n)),null!=r?await r(g_,n):await g_(n),w_})); \ No newline at end of file diff --git a/825.bundle.js b/825.bundle.js index e5a1868ab..47c8d5e86 100644 --- a/825.bundle.js +++ b/825.bundle.js @@ -1,2 +1,2 @@ -(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,879,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={825:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,879,312].map(c.e,c)).then(n);c.x()})(); +(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,857,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={825:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,857,312].map(c.e,c)).then(n);c.x()})(); //# sourceMappingURL=825.bundle.js.map \ No newline at end of file diff --git a/825.bundle.js.map b/825.bundle.js.map index 465201ae4..df3b42f3d 100644 --- a/825.bundle.js.map +++ b/825.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"825.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAGpEK,EAAOD,OACf,CAGAJ,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAI,KAGvB,IAAIC,EAAsBV,EAAoBW,OAAER,EAAW,CAAC,IAAI,IAAI,MAAM,IAAOH,EAAoB,QAErG,OADAU,EAAsBV,EAAoBW,EAAED,EAClB,EHjCvBjB,EAAkC,mBAAXmB,OAAwBA,OAAO,kBAAoB,qBAC1ElB,EAAmC,mBAAXkB,OAAwBA,OAAO,mBAAqB,sBAC5EjB,EAAiC,mBAAXiB,OAAwBA,OAAO,iBAAmB,oBACxEhB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oB4F,EAAIC,KAAKb,SAAW,GAIxC,IAAIc,EAAkB,CACrB,IAAK,GAgBN9F,EAAoBgE,EAAEd,EAAI,CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,879,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,879,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t825: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"825.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAGpEK,EAAOD,OACf,CAGAJ,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAI,KAGvB,IAAIC,EAAsBV,EAAoBW,OAAER,EAAW,CAAC,IAAI,IAAI,MAAM,IAAOH,EAAoB,QAErG,OADAU,EAAsBV,EAAoBW,EAAED,EAClB,EHjCvBjB,EAAkC,mBAAXmB,OAAwBA,OAAO,kBAAoB,qBAC1ElB,EAAmC,mBAAXkB,OAAwBA,OAAO,mBAAqB,sBAC5EjB,EAAiC,mBAAXiB,OAAwBA,OAAO,iBAAmB,oBACxEhB,EAAgBiB,IAChBA,GAASA,EAAMC,EAAI,IACrBD,EAAMC,EAAI,EACVD,EAAME,SAASC,GAAQA,EAAGC,MAC1BJ,EAAME,SAASC,GAAQA,EAAGC,IAAMD,EAAGC,IAAMD,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,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,857,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,857,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t825: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/857.bundle.js b/857.bundle.js new file mode 100644 index 000000000..170dac2c2 --- /dev/null +++ b/857.bundle.js @@ -0,0 +1,2 @@ +(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[857],{2851:(t,e,r)=>{t.exports=r.p+"68537c70e60b0878e521.js"},6545:(t,e,r)=>{t.exports=r.p+"49a4de3dabc57be5a0e7.wasm"},2857:(t,e,r)=>{r.a(t,(async(t,n)=>{try{r.d(e,{A:()=>k,P:()=>P,a:()=>m});var i=r(9879),_=t([i]);function a(t){throw console.error(t),new Error(t)}function o(t){return JSON.parse(t,(function(t,e,r){return Number.isInteger(e)?BigInt(r.source):e}))}async function s(t,e){const r=await fetch(t,e);if(!r.ok)throw new Error(r.status+" could not get URL "+t);return r}async function c(t,e){e.method="POST";const r=await fetch(t,e);if(!r.ok)throw new Error(r.status+" could not post URL "+t);return r}i=(_.then?(await _)():_)[0];class g{host;headers;account;constructor(t,e){this.host=t+"/testnet",e&&e.headers?this.headers=e.headers:this.headers={"X-Aleo-SDK-Version":"0.7.4"}}setAccount(t){this.account=t}getAccount(){return this.account}setHost(t){this.host=t+"/testnet"}async fetchData(t="/"){try{const e=await s(this.host+t,{headers:this.headers});return o(await e.text())}catch(t){throw new Error("Error fetching data.")}}async findUnspentRecords(t,e,r,n,_,a){if(a=a||[],t<0)throw new Error("Start height must be greater than or equal to 0");const o=new Array;let s,c,g,d,w=0,u=BigInt(0);if(void 0===r){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");g=this.account._privateKey}else try{g=r instanceof i.ZD?r:i.ZD.from_string(r)}catch(t){throw new Error("Error parsing private key provided.")}const l=g.to_view_key();try{const t=await this.getLatestHeight();if("number"!=typeof t)throw new Error("Error fetching latest block height.");d=t}catch(t){throw new Error("Error fetching latest block height.")}if(c="number"==typeof e&&e<=d?e:d,t>c)throw new Error("Start height must be less than or equal to end height.");for(;c>t;){s=c-50,s=BigInt(_))))return o;if(void 0!==n&&n.length>0){let t=0;if(e.microcredits()>n[t]){if(t+=1,o.push(e),"number"==typeof _&&(u+=e.microcredits(),u>=BigInt(_)))return o;if(o.length>=n.length)return o}}}}}catch(t){}}}}}}}catch(t){if(console.warn("Error fetching blocks in range: "+s.toString()+"-"+c.toString()),console.warn("Error: ",t),w+=1,w>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),o}}return o}async getBlock(t){try{return await this.fetchData("/block/"+t)}catch(t){throw new Error("Error fetching block.")}}async getBlockRange(t,e){try{return await this.fetchData("/blocks?start="+t+"&end="+e)}catch(r){throw new Error(`Error fetching blocks between ${t} and ${e}.`)}}async getDeploymentTransactionIDForProgram(t){t instanceof i.BP&&(t=t.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+t)).replace('"',"")}catch(t){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(t){try{const e=await this.getDeploymentTransactionIDForProgram(t);return await this.getTransaction(e)}catch(t){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/block/latest")}catch(t){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(t){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return Number(await this.fetchData("/block/height/latest"))}catch(t){throw new Error("Error fetching latest height.")}}async getProgram(t){try{return await this.fetchData("/program/"+t)}catch(t){throw new Error("Error fetching program")}}async getProgramObject(t){try{return i.BP.fromString(t)}catch(e){try{return i.BP.fromString(await this.getProgram(t))}catch(e){throw new Error(`${t} is neither a program name or a valid program`)}}}async getProgramImports(t){try{const e={},r=(t instanceof i.BP?t:await this.getProgramObject(t)).getImports();for(let t=0;t0&&!f)try{f=await this.networkClient.getProgramImports(e)}catch(t){a(`Error finding program imports. Network response: '${t.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await i.Ao.buildExecutionTransaction(y,b,r,o,n,w,this.host,f,u,l,h,v,d)}async execute(t){const e=await this.buildExecutionTransaction(t);return await this.networkClient.submitTransaction(e)}async run(t,e,r,n,_,a,o,s,c,g){let d=c;if(void 0===c&&void 0!==this.account&&(d=this.account.privateKey()),void 0===d)throw"No private key provided and no private key set in the ProgramManager";if(!o||!s)try{[o,s]=await this.keyProvider.functionKeys(a)}catch(t){console.log(`Function keys not found. Key finder response: '${t}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",o),console.log("Verifying key: ",s),i.Ao.executeFunctionOffline(d,t,e,r,n,!1,_,o,s,this.host,g)}async join(t,e,r,n,_,o,s,c){let g,d,w=s;if(void 0===s&&void 0!==this.account&&(w=this.account.privateKey()),void 0===w)throw"No private key provided and no private key set in the ProgramManager";try{g=n?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),d=await this.keyProvider.joinKeys()}catch(t){a(`Error finding fee keys. Key finder response: '${t.message}'. Please ensure your key provider is configured correctly.`)}const[u,l]=g,[b,f]=d;try{o=n?await this.getCreditsRecord(r,[],o,_):void 0}catch(t){a(`Error finding fee record. Record finder response: '${t.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{t=t instanceof i.ZF?t:i.ZF.fromString(t),e=e instanceof i.ZF?e:i.ZF.fromString(e)}catch(t){a("Records provided are not valid. Please ensure they are valid plaintext records.")}const p=await i.Ao.buildJoinTransaction(w,t,e,r,o,this.host,b,f,u,l,c);return await this.networkClient.submitTransaction(p)}async split(t,e,r,n){let _,o=r;if(void 0===o&&void 0!==this.account&&(o=this.account.privateKey()),void 0===o)throw"No private key provided and no private key set in the ProgramManager";try{_=await this.keyProvider.splitKeys()}catch(t){a(`Error finding fee keys. Key finder response: '${t.message}'. Please ensure your key provider is configured correctly.`)}const[s,c]=_;try{e=e instanceof i.ZF?e:i.ZF.fromString(e)}catch(t){a("Record provided is not valid. Please ensure it is a valid plaintext record.")}const g=await i.Ao.buildSplitTransaction(o,t,e,this.host,s,c,n);return await this.networkClient.submitTransaction(g)}async synthesizeKeys(t,e,r,n){let _,o=n;void 0===o&&(o=void 0!==this.account?this.account.privateKey():new i.ZD);try{_=await this.networkClient.getProgramImports(t);const n=await i.Ao.synthesizeKeyPair(o,t,e,r,_);return[n.provingKey(),n.verifyingKey()]}catch(t){a(`Could not synthesize keys - error ${t.message}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(t,e,r,n,_,o,s,c,g,d){r=K(r);let w,u,l=g;if(void 0===l&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";try{w=_?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),u=await this.keyProvider.transferKeys(r)}catch(t){a(`Error finding fee keys. Key finder response: '${t.message}'. Please ensure your key provider is configured correctly.`)}const[b,f]=w,[p,y]=u;try{const t=[];S(r)?(s=await this.getCreditsRecord(n,[],s,o),t.push(s.nonce())):s=void 0,c=_?await this.getCreditsRecord(n,t,c,o):void 0}catch(t){a(`Error finding fee record. Record finder response: '${t.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await i.Ao.buildTransferTransaction(l,t,e,r,s,n,c,this.host,p,y,b,f,d)}async buildTransferPublicTransaction(t,e,r,n,i){return this.buildTransferTransaction(t,e,"public",r,!1,void 0,void 0,void 0,n,i)}async buildTransferPublicAsSignerTransaction(t,e,r,n,i){return this.buildTransferTransaction(t,e,"public",r,!1,void 0,void 0,void 0,n,i)}async transfer(t,e,r,n,i,_,a,o,s,c){const g=await this.buildTransferTransaction(t,e,r,n,i,_,a,o,s,c);return await this.networkClient.submitTransaction(g)}async buildBondPublicTransaction(t,e,r,n,i={}){const _=Math.trunc(1e6*n),{programName:a="credits.aleo",functionName:o="bond_public",fee:s=i.fee||.86,privateFee:c=!1,inputs:g=[t,e,r,`${_.toString()}u64`],keySearchParams:d=new m({proverUri:u.bond_public.prover,verifierUri:u.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:w=this.creditsProgram(),...l}=i,b={programName:a,functionName:o,fee:s,privateFee:c,inputs:g,keySearchParams:d,...l};return await this.buildExecutionTransaction(b)}async bondPublic(t,e,r,n,i={}){const _=await this.buildBondPublicTransaction(t,e,r,n,i);return await this.networkClient.submitTransaction(_)}async buildBondValidatorTransaction(t,e,r,n,i={}){const _=Math.trunc(1e6*r),a=Math.trunc(n),{programName:o="credits.aleo",functionName:s="bond_validator",fee:c=i.fee||.86,privateFee:g=!1,inputs:d=[t,e,`${_.toString()}u64`,`${a.toString()}u8`],keySearchParams:w=new m({proverUri:u.bond_validator.prover,verifierUri:u.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:l=this.creditsProgram(),...b}=i,f={programName:o,functionName:s,fee:c,privateFee:g,inputs:d,keySearchParams:w,...b};return await this.buildExecutionTransaction(f)}async bondValidator(t,e,r,n,i={}){const _=await this.buildBondValidatorTransaction(t,e,r,n,i);return await this.networkClient.submitTransaction(_)}async buildUnbondPublicTransaction(t,e,r={}){const n=Math.trunc(1e6*e),{programName:i="credits.aleo",functionName:_="unbond_public",fee:a=r.fee||1.3,privateFee:o=!1,inputs:s=[t,`${n.toString()}u64`],keySearchParams:c=new m({proverUri:u.unbond_public.prover,verifierUri:u.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:g=this.creditsProgram(),...d}=r,w={programName:i,functionName:_,fee:a,privateFee:o,inputs:s,keySearchParams:c,...d};return this.buildExecutionTransaction(w)}async unbondPublic(t,e,r={}){const n=await this.buildUnbondPublicTransaction(t,e,r);return await this.networkClient.submitTransaction(n)}async buildClaimUnbondPublicTransaction(t,e={}){const{programName:r="credits.aleo",functionName:n="claim_unbond_public",fee:i=e.fee||2,privateFee:_=!1,inputs:a=[t],keySearchParams:o=new m({proverUri:u.claim_unbond_public.prover,verifierUri:u.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:s=this.creditsProgram(),...c}=e,g={programName:r,functionName:n,fee:i,privateFee:_,inputs:a,keySearchParams:o,...c};return await this.buildExecutionTransaction(g)}async claimUnbondPublic(t,e={}){const r=await this.buildClaimUnbondPublicTransaction(t,e);return await this.networkClient.submitTransaction(r)}async buildSetValidatorStateTransaction(t,e={}){const{programName:r="credits.aleo",functionName:n="set_validator_state",fee:i=1,privateFee:_=!1,inputs:a=[t.toString()],keySearchParams:o=new m({proverUri:u.set_validator_state.prover,verifierUri:u.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...s}=e,c={programName:r,functionName:n,fee:i,privateFee:_,inputs:a,keySearchParams:o,...s};return await this.execute(c)}async setValidatorState(t,e={}){const r=await this.buildSetValidatorStateTransaction(t,e);return this.networkClient.submitTransaction(r)}verifyExecution(t){try{const e=t.getExecution(),r=t.getFunctionId(),n=t.getProgram(),_=t.getVerifyingKey();return(0,i.Yc)(e,_,n,r)}catch(t){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(t){return i.BP.fromString(t)}creditsProgram(){return i.BP.getCreditsProgram()}verifyProgram(t){try{return i.BP.fromString(t),!0}catch(t){return!1}}async getCreditsRecord(t,e,r,n){try{return r instanceof i.ZF?r:i.ZF.fromString(r)}catch(r){try{const r=this.recordProvider;return await r.findCreditsRecord(t,!0,e,n)}catch(t){a(`Error finding fee record. Record finder response: '${t.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function S(t){return l.has(t)}function K(t){return b.has(t)?t:a(`Invalid transfer type '${t}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}n()}catch(T){n(T)}}))},9879:(t,e,r)=>{r.a(t,(async(t,n)=>{try{function _(t,e,r,n){return new Promise((i=>{const _=new Worker(t,{type:"module"});_.addEventListener("message",(t=>{setTimeout((()=>{i(_),_.unref&&_.unref()}),0)}),{capture:!0,once:!0}),_.postMessage({module:e,memory:r,address:n})}))}let a;r.d(e,{$7:()=>It,Ao:()=>jt,BP:()=>$t,Fs:()=>Ht,KC:()=>zt,OS:()=>Ct,Yc:()=>Zt,ZD:()=>Ot,ZF:()=>Nt,ZX:()=>Dt,pF:()=>Wt});const o=new Array(128).fill(void 0);function s(t){return o[t]}o.push(void 0,null,!0,!1);let c=o.length;function g(t){t<132||(o[t]=c,c=t)}function d(t){const e=s(t);return g(t),e}const w="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&w.decode();let u=null;function l(){return null!==u&&u.buffer===a.memory.buffer||(u=new Uint8Array(a.memory.buffer)),u}function b(t,e){return t>>>=0,w.decode(l().slice(t,t+e))}function f(t){c===o.length&&o.push(o.length+1);const e=c;return c=o[e],o[e]=t,e}let p=0;const y="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},h=function(t,e){const r=y.encode(t);return e.set(r),{read:t.length,written:r.length}};function v(t,e,r){if(void 0===r){const r=y.encode(t),n=e(r.length,1)>>>0;return l().subarray(n,n+r.length).set(r),p=r.length,n}let n=t.length,i=e(n,1)>>>0;const _=l();let a=0;for(;a127)break;_[i+a]=e}if(a!==n){0!==a&&(t=t.slice(a)),i=r(i,n,n=a+3*t.length,1)>>>0;const e=l().subarray(i+a,i+n);a+=h(t,e).written,i=r(i,n,a,1)>>>0}return p=a,i}function m(t){return null==t}let k=null;function P(){return null!==k&&k.buffer===a.memory.buffer||(k=new Int32Array(a.memory.buffer)),k}function S(t){const e=typeof t;if("number"==e||"boolean"==e||null==t)return`${t}`;if("string"==e)return`"${t}"`;if("symbol"==e){const e=t.description;return null==e?"Symbol":`Symbol(${e})`}if("function"==e){const e=t.name;return"string"==typeof e&&e.length>0?`Function(${e})`:"Function"}if(Array.isArray(t)){const e=t.length;let r="[";e>0&&(r+=S(t[0]));for(let n=1;n1))return toString.call(t);if(n=r[1],"Object"==n)try{return"Object("+JSON.stringify(t)+")"}catch(t){return"Object"}return t instanceof Error?`${t.name}: ${t.message}\n${t.stack}`:n}const K="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>{a.__wbindgen_export_3.get(t.dtor)(t.a,t.b)}));function T(t,e,r,n){const i={a:t,b:e,cnt:1,dtor:r},_=(...t)=>{i.cnt++;const e=i.a;i.a=0;try{return n(e,i.b,...t)}finally{0==--i.cnt?(a.__wbindgen_export_3.get(i.dtor)(e,i.b),K.unregister(i)):i.a=e}};return _.original=i,K.register(_,i,i),_}function E(t,e,r){a._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6a363ba3fe56b221(t,e,f(r))}function x(t,e){if(!(t instanceof e))throw new Error(`expected instance of ${e.name}`);return t.ptr}function F(t,e){const r=e(1*t.length,1)>>>0;return l().set(t,r/1),p=t.length,r}function R(t,e,r,n){try{const o=a.__wbindgen_add_to_stack_pointer(-16);x(t,j),x(e,pt),x(r,nt);const s=v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.verifyFunctionExecution(o,t.__wbg_ptr,e.__wbg_ptr,r.__wbg_ptr,s,c);var i=P()[o/4+0],_=P()[o/4+1];if(P()[o/4+2])throw d(_);return 0!==i}finally{a.__wbindgen_add_to_stack_pointer(16)}}let V=null;function C(){return null!==V&&V.buffer===a.memory.buffer||(V=new BigInt64Array(a.memory.buffer)),V}function B(t,e){return t>>>=0,l().subarray(t/1,t/1+e)}function A(t){a.runRayonThread(t)}function O(t,e){return d(a.initThreadPool(f(t),e))}function U(t,e){try{return t.apply(this,e)}catch(t){a.__wbindgen_exn_store(f(t))}}function $(t,e,r,n){a.wasm_bindgen__convert__closures__invoke2_mut__h3c510d875601a93b(t,e,f(r),f(n))}const I="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_address_free(t>>>0)));let z=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,I.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,I.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_address_free(t)}static from_private_key(e){x(e,G);const r=a.address_from_private_key(e.__wbg_ptr);return t.__wrap(r)}static from_view_key(e){x(e,ht);const r=a.address_from_view_key(e.__wbg_ptr);return t.__wrap(r)}static from_string(e){const r=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.address_from_string(r,n);return t.__wrap(i)}to_string(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.address_to_string(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}verify(t,e){const r=F(t,a.__wbindgen_malloc),n=p;x(e,ut);return 0!==a.address_verify(this.__wbg_ptr,r,n,e.__wbg_ptr)}};const N="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_execution_free(t>>>0)));let j=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,N.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,N.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_execution_free(t)}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.execution_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.execution_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const M="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_executionresponse_free(t>>>0)));let D=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,M.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,M.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_executionresponse_free(t)}getOutputs(){return d(a.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const t=a.executionresponse_getExecution(this.__wbg_ptr);return 0===t?void 0:j.__wrap(t)}getKeys(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.executionresponse_getKeys(r,this.__wbg_ptr);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw d(e);return H.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const t=a.executionresponse_getProvingKey(this.__wbg_ptr);return 0===t?void 0:ot.__wrap(t)}getVerifyingKey(){const t=a.executionresponse_getVerifyingKey(this.__wbg_ptr);return pt.__wrap(t)}getFunctionId(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.executionresponse_getFunctionId(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}getProgram(){const t=a.executionresponse_getProgram(this.__wbg_ptr);return nt.__wrap(t)}};const q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_field_free(t>>>0)));let W=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,q.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,q.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_field_free(t)}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.field_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.field_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const Z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_keypair_free(t>>>0)));class H{static __wrap(t){t>>>=0;const e=Object.create(H.prototype);return e.__wbg_ptr=t,Z.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_keypair_free(t)}constructor(t,e){x(t,ot);var r=t.__destroy_into_raw();x(e,pt);var n=e.__destroy_into_raw();const i=a.keypair_new(r,n);return this.__wbg_ptr=i>>>0,this}provingKey(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.keypair_provingKey(r,this.__wbg_ptr);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw d(e);return ot.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.keypair_verifyingKey(r,this.__wbg_ptr);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw d(e);return pt.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}}const L="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_metadata_free(t>>>0)));let J=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,L.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,L.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_metadata_free(t)}get name(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_name(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}set name(t){const e=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_name(this.__wbg_ptr,e,r)}get locator(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_locator(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}set locator(t){const e=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_locator(this.__wbg_ptr,e,r)}get prover(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_prover(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}set prover(t){const e=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_prover(this.__wbg_ptr,e,r)}get verifier(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_verifier(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}set verifier(t){const e=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_verifier(this.__wbg_ptr,e,r)}get verifyingKey(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.__wbg_get_metadata_verifyingKey(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}set verifyingKey(t){const e=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;a.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,e,r)}static baseUrl(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.metadata_baseUrl(i);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}static bond_public(){const e=a.metadata_bond_public();return t.__wrap(e)}static bond_validator(){const e=a.metadata_bond_validator();return t.__wrap(e)}static claim_unbond_public(){const e=a.metadata_claim_unbond_public();return t.__wrap(e)}static fee_private(){const e=a.metadata_fee_private();return t.__wrap(e)}static fee_public(){const e=a.metadata_fee_public();return t.__wrap(e)}static inclusion(){const e=a.metadata_inclusion();return t.__wrap(e)}static join(){const e=a.metadata_join();return t.__wrap(e)}static set_validator_state(){const e=a.metadata_set_validator_state();return t.__wrap(e)}static split(){const e=a.metadata_split();return t.__wrap(e)}static transfer_private(){const e=a.metadata_transfer_private();return t.__wrap(e)}static transfer_private_to_public(){const e=a.metadata_transfer_private_to_public();return t.__wrap(e)}static transfer_public(){const e=a.metadata_transfer_public();return t.__wrap(e)}static transfer_public_as_signer(){const e=a.metadata_transfer_public_as_signer();return t.__wrap(e)}static transfer_public_to_private(){const e=a.metadata_transfer_public_to_private();return t.__wrap(e)}static unbond_public(){const e=a.metadata_unbond_public();return t.__wrap(e)}};const X="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_offlinequery_free(t>>>0)));let Q=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,X.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,X.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_offlinequery_free(t)}constructor(t,e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.offlinequery_new(i,t,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return this.__wbg_ptr=r>>>0,this}finally{a.__wbindgen_add_to_stack_pointer(16)}}addBlockHeight(t){a.offlinequery_addBlockHeight(this.__wbg_ptr,t)}addStatePath(t,e){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p,o=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.offlinequery_addStatePath(n,this.__wbg_ptr,i,_,o,s);var r=P()[n/4+0];if(P()[n/4+1])throw d(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.offlinequery_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.offlinequery_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const Y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_privatekey_free(t>>>0)));let G=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,Y.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,Y.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_privatekey_free(t)}constructor(){const t=a.privatekey_new();return this.__wbg_ptr=t>>>0,this}static from_seed_unchecked(e){const r=F(e,a.__wbindgen_malloc),n=p,i=a.privatekey_from_seed_unchecked(r,n);return t.__wrap(i)}static from_string(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.privatekey_from_string(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}to_string(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.privatekey_to_string(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}to_view_key(){const t=a.privatekey_to_view_key(this.__wbg_ptr);return ht.__wrap(t)}to_address(){const t=a.privatekey_to_address(this.__wbg_ptr);return z.__wrap(t)}sign(t){const e=F(t,a.__wbindgen_malloc),r=p,n=a.privatekey_sign(this.__wbg_ptr,e,r);return ut.__wrap(n)}static newEncrypted(t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekey_newEncrypted(n,i,_);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw d(r);return et.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekey_toCiphertext(n,this.__wbg_ptr,i,_);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw d(r);return et.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(e,r){try{const _=a.__wbindgen_add_to_stack_pointer(-16);x(e,et);const o=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.privatekey_fromPrivateKeyCiphertext(_,e.__wbg_ptr,o,s);var n=P()[_/4+0],i=P()[_/4+1];if(P()[_/4+2])throw d(i);return t.__wrap(n)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const tt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_privatekeyciphertext_free(t>>>0)));let et=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,tt.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,tt.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_privatekeyciphertext_free(t)}static encryptPrivateKey(e,r){try{const _=a.__wbindgen_add_to_stack_pointer(-16);x(e,G);const o=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),s=p;a.privatekey_toCiphertext(_,e.__wbg_ptr,o,s);var n=P()[_/4+0],i=P()[_/4+1];if(P()[_/4+2])throw d(i);return t.__wrap(n)}finally{a.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.privatekeyciphertext_decryptToPrivateKey(n,this.__wbg_ptr,i,_);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw d(r);return G.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.privatekeyciphertext_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.privatekeyciphertext_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}};const rt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_program_free(t>>>0)));let nt=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,rt.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,rt.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_program_free(t)}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.program_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.program_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}hasFunction(t){const e=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;return 0!==a.program_hasFunction(this.__wbg_ptr,e,r)}getFunctions(){return d(a.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getFunctionInputs(n,this.__wbg_ptr,i,_);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw d(r);return d(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.program_getMappings(r,this.__wbg_ptr);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw d(e);return d(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getRecordMembers(n,this.__wbg_ptr,i,_);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw d(r);return d(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.program_getStructMembers(n,this.__wbg_ptr,i,_);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw d(r);return d(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const e=a.program_getCreditsProgram();return t.__wrap(e)}id(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.program_id(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}address(){try{const r=a.__wbindgen_add_to_stack_pointer(-16);a.program_address(r,this.__wbg_ptr);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw d(e);return z.__wrap(t)}finally{a.__wbindgen_add_to_stack_pointer(16)}}isEqual(e){x(e,t);return 0!==a.program_isEqual(this.__wbg_ptr,e.__wbg_ptr)}getImports(){return d(a.program_getImports(this.__wbg_ptr))}};const it="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_programmanager_free(t>>>0)));let _t=class{__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,it.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_programmanager_free(t)}static buildDeploymentTransaction(t,e,r,n,i,_,o,s,c){x(t,G);const g=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),w=p;let u=0;m(n)||(x(n,dt),u=n.__destroy_into_raw());var l=m(i)?0:v(i,a.__wbindgen_malloc,a.__wbindgen_realloc),b=p;let y=0;m(o)||(x(o,ot),y=o.__destroy_into_raw());let h=0;m(s)||(x(s,pt),h=s.__destroy_into_raw());let k=0;m(c)||(x(c,Q),k=c.__destroy_into_raw());return d(a.programmanager_buildDeploymentTransaction(t.__wbg_ptr,g,w,r,u,l,b,m(_)?0:f(_),y,h,k))}static estimateDeploymentFee(t,e){const r=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;return d(a.programmanager_estimateDeploymentFee(r,n,m(e)?0:f(e)))}static estimateProgramNameCost(t){try{const n=a.__wbindgen_add_to_stack_pointer(-16),i=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;a.programmanager_estimateProgramNameCost(n,i,_);var e=C()[n/8+0],r=P()[n/4+2];if(P()[n/4+3])throw d(r);return BigInt.asUintN(64,e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(t,e,r,n,i,_,o,s,c,g,w){x(t,G);const u=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),l=p,b=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(s)||(x(s,ot),h=s.__destroy_into_raw());let k=0;m(c)||(x(c,pt),k=c.__destroy_into_raw());var P=m(g)?0:v(g,a.__wbindgen_malloc,a.__wbindgen_realloc),S=p;let K=0;m(w)||(x(w,Q),K=w.__destroy_into_raw());return d(a.programmanager_executeFunctionOffline(t.__wbg_ptr,u,l,b,y,f(n),i,_,m(o)?0:f(o),h,k,P,S,K))}static buildExecutionTransaction(t,e,r,n,i,_,o,s,c,g,w,u,l){x(t,G);const b=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p,h=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),k=p;let P=0;m(_)||(x(_,dt),P=_.__destroy_into_raw());var S=m(o)?0:v(o,a.__wbindgen_malloc,a.__wbindgen_realloc),K=p;let T=0;m(c)||(x(c,ot),T=c.__destroy_into_raw());let E=0;m(g)||(x(g,pt),E=g.__destroy_into_raw());let F=0;m(w)||(x(w,ot),F=w.__destroy_into_raw());let R=0;m(u)||(x(u,pt),R=u.__destroy_into_raw());let V=0;m(l)||(x(l,Q),V=l.__destroy_into_raw());return d(a.programmanager_buildExecutionTransaction(t.__wbg_ptr,b,y,h,k,f(n),i,P,S,K,m(s)?0:f(s),T,E,F,R,V))}static estimateExecutionFee(t,e,r,n,i,_,o,s,c){x(t,G);const g=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),w=p,u=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),l=p;var b=m(i)?0:v(i,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(o)||(x(o,ot),h=o.__destroy_into_raw());let k=0;m(s)||(x(s,pt),k=s.__destroy_into_raw());let P=0;m(c)||(x(c,Q),P=c.__destroy_into_raw());return d(a.programmanager_estimateExecutionFee(t.__wbg_ptr,g,w,u,l,f(n),b,y,m(_)?0:f(_),h,k,P))}static estimateFinalizeFee(t,e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.programmanager_estimateFinalizeFee(i,_,o,s,c);var r=C()[i/8+0],n=P()[i/4+2];if(P()[i/4+3])throw d(n);return BigInt.asUintN(64,r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(t,e,r,n,i,_,o,s,c,g,w){x(t,G),x(e,dt);var u=e.__destroy_into_raw();x(r,dt);var l=r.__destroy_into_raw();let b=0;m(i)||(x(i,dt),b=i.__destroy_into_raw());var f=m(_)?0:v(_,a.__wbindgen_malloc,a.__wbindgen_realloc),y=p;let h=0;m(o)||(x(o,ot),h=o.__destroy_into_raw());let k=0;m(s)||(x(s,pt),k=s.__destroy_into_raw());let P=0;m(c)||(x(c,ot),P=c.__destroy_into_raw());let S=0;m(g)||(x(g,pt),S=g.__destroy_into_raw());let K=0;m(w)||(x(w,Q),K=w.__destroy_into_raw());return d(a.programmanager_buildJoinTransaction(t.__wbg_ptr,u,l,n,b,f,y,h,k,P,S,K))}static buildSplitTransaction(t,e,r,n,i,_,o){x(t,G),x(r,dt);var s=r.__destroy_into_raw(),c=m(n)?0:v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),g=p;let w=0;m(i)||(x(i,ot),w=i.__destroy_into_raw());let u=0;m(_)||(x(_,pt),u=_.__destroy_into_raw());let l=0;m(o)||(x(o,Q),l=o.__destroy_into_raw());return d(a.programmanager_buildSplitTransaction(t.__wbg_ptr,e,s,c,g,w,u,l))}static buildTransferTransaction(t,e,r,n,i,_,o,s,c,g,w,u,l){x(t,G);const b=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),f=p,y=v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),h=p;let k=0;m(i)||(x(i,dt),k=i.__destroy_into_raw());let P=0;m(o)||(x(o,dt),P=o.__destroy_into_raw());var S=m(s)?0:v(s,a.__wbindgen_malloc,a.__wbindgen_realloc),K=p;let T=0;m(c)||(x(c,ot),T=c.__destroy_into_raw());let E=0;m(g)||(x(g,pt),E=g.__destroy_into_raw());let F=0;m(w)||(x(w,ot),F=w.__destroy_into_raw());let R=0;m(u)||(x(u,pt),R=u.__destroy_into_raw());let V=0;m(l)||(x(l,Q),V=l.__destroy_into_raw());return d(a.programmanager_buildTransferTransaction(t.__wbg_ptr,e,b,f,y,h,k,_,P,S,K,T,E,F,R,V))}static synthesizeKeyPair(t,e,r,n,i){x(t,G);const _=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;return d(a.programmanager_synthesizeKeyPair(t.__wbg_ptr,_,o,s,c,f(n),m(i)?0:f(i)))}};const at="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_provingkey_free(t>>>0)));let ot=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,at.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,at.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_provingkey_free(t)}isBondPublicProver(){return 0!==a.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==a.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==a.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==a.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==a.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==a.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==a.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==a.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==a.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==a.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==a.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==a.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==a.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==a.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==a.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_checksum(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}copy(){const e=a.provingkey_copy(this.__wbg_ptr);return t.__wrap(e)}static fromBytes(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=F(e,a.__wbindgen_malloc),o=p;a.provingkey_fromBytes(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.provingkey_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_toBytes(i,this.__wbg_ptr);var t=P()[i/4+0],e=P()[i/4+1],r=P()[i/4+2];if(P()[i/4+3])throw d(r);var n=B(t,e).slice();return a.__wbindgen_free(t,1*e,1),n}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.provingkey_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}};const st="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_recordciphertext_free(t>>>0)));let ct=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,st.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,st.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_recordciphertext_free(t)}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.recordciphertext_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordciphertext_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}decrypt(t){try{const n=a.__wbindgen_add_to_stack_pointer(-16);x(t,ht),a.recordciphertext_decrypt(n,this.__wbg_ptr,t.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw d(r);return dt.__wrap(e)}finally{a.__wbindgen_add_to_stack_pointer(16)}}isOwner(t){x(t,ht);return 0!==a.recordciphertext_isOwner(this.__wbg_ptr,t.__wbg_ptr)}};const gt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_recordplaintext_free(t>>>0)));let dt=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,gt.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,gt.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_recordplaintext_free(t)}commitment(t,e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p,s=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),c=p;a.recordplaintext_commitment(i,this.__wbg_ptr,_,o,s,c);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return W.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.recordplaintext_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordplaintext_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}microcredits(){const t=a.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,t)}nonce(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.recordplaintext_nonce(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}serialNumberString(t,e,r){let n,i;try{const u=a.__wbindgen_add_to_stack_pointer(-16);x(t,G);const l=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),f=p,y=v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),h=p;a.recordplaintext_serialNumberString(u,this.__wbg_ptr,t.__wbg_ptr,l,f,y,h);var _=P()[u/4+0],o=P()[u/4+1],s=P()[u/4+2],c=P()[u/4+3],g=_,w=o;if(c)throw g=0,w=0,d(s);return n=g,i=w,b(g,w)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(n,i,1)}}};const wt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_signature_free(t>>>0)));let ut=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,wt.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,wt.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_signature_free(t)}static sign(e,r){x(e,G);const n=F(r,a.__wbindgen_malloc),i=p,_=a.privatekey_sign(e.__wbg_ptr,n,i);return t.__wrap(_)}verify(t,e){x(t,z);const r=F(e,a.__wbindgen_malloc),n=p;return 0!==a.signature_verify(this.__wbg_ptr,t.__wbg_ptr,r,n)}static from_string(e){const r=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.signature_from_string(r,n);return t.__wrap(i)}to_string(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.signature_to_string(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}};const lt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_transaction_free(t>>>0)));let bt=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,lt.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,lt.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_transaction_free(t)}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.transaction_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}transactionId(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_transactionId(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}transactionType(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.transaction_transactionType(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}};const ft="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_verifyingkey_free(t>>>0)));let pt=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,ft.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,ft.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_verifyingkey_free(t)}static bondPublicVerifier(){const e=a.verifyingkey_bondPublicVerifier();return t.__wrap(e)}static bondValidatorVerifier(){const e=a.verifyingkey_bondValidatorVerifier();return t.__wrap(e)}static claimUnbondPublicVerifier(){const e=a.verifyingkey_claimUnbondPublicVerifier();return t.__wrap(e)}static feePrivateVerifier(){const e=a.verifyingkey_feePrivateVerifier();return t.__wrap(e)}static feePublicVerifier(){const e=a.verifyingkey_feePublicVerifier();return t.__wrap(e)}static inclusionVerifier(){const e=a.verifyingkey_inclusionVerifier();return t.__wrap(e)}static joinVerifier(){const e=a.verifyingkey_joinVerifier();return t.__wrap(e)}static setValidatorStateVerifier(){const e=a.verifyingkey_setValidatorStateVerifier();return t.__wrap(e)}static splitVerifier(){const e=a.verifyingkey_splitVerifier();return t.__wrap(e)}static transferPrivateVerifier(){const e=a.verifyingkey_transferPrivateVerifier();return t.__wrap(e)}static transferPrivateToPublicVerifier(){const e=a.verifyingkey_transferPrivateToPublicVerifier();return t.__wrap(e)}static transferPublicVerifier(){const e=a.verifyingkey_transferPublicVerifier();return t.__wrap(e)}static transferPublicAsSignerVerifier(){const e=a.verifyingkey_transferPublicAsSignerVerifier();return t.__wrap(e)}static transferPublicToPrivateVerifier(){const e=a.verifyingkey_transferPublicToPrivateVerifier();return t.__wrap(e)}static unbondPublicVerifier(){const e=a.verifyingkey_unbondPublicVerifier();return t.__wrap(e)}isBondPublicVerifier(){return 0!==a.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==a.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==a.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==a.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==a.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==a.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==a.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==a.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==a.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==a.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==a.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==a.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==a.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==a.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==a.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_checksum(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}copy(){const e=a.verifyingkey_copy(this.__wbg_ptr);return t.__wrap(e)}static fromBytes(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=F(e,a.__wbindgen_malloc),o=p;a.verifyingkey_fromBytes(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}static fromString(e){try{const i=a.__wbindgen_add_to_stack_pointer(-16),_=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),o=p;a.verifyingkey_fromString(i,_,o);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw d(n);return t.__wrap(r)}finally{a.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_toBytes(i,this.__wbg_ptr);var t=P()[i/4+0],e=P()[i/4+1],r=P()[i/4+2];if(P()[i/4+3])throw d(r);var n=B(t,e).slice();return a.__wbindgen_free(t,1*e,1),n}finally{a.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.verifyingkey_toString(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}};const yt="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>a.__wbg_viewkey_free(t>>>0)));let ht=class t{static __wrap(e){e>>>=0;const r=Object.create(t.prototype);return r.__wbg_ptr=e,yt.register(r,r.__wbg_ptr,r),r}__destroy_into_raw(){const t=this.__wbg_ptr;return this.__wbg_ptr=0,yt.unregister(this),t}free(){const t=this.__destroy_into_raw();a.__wbg_viewkey_free(t)}static from_private_key(e){x(e,G);const r=a.privatekey_to_view_key(e.__wbg_ptr);return t.__wrap(r)}static from_string(e){const r=v(e,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p,i=a.viewkey_from_string(r,n);return t.__wrap(i)}to_string(){let t,e;try{const i=a.__wbindgen_add_to_stack_pointer(-16);a.viewkey_to_string(i,this.__wbg_ptr);var r=P()[i/4+0],n=P()[i/4+1];return t=r,e=n,b(r,n)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(t,e,1)}}to_address(){const t=a.address_from_view_key(this.__wbg_ptr);return z.__wrap(t)}decrypt(t){let e,r;try{const g=a.__wbindgen_add_to_stack_pointer(-16),w=v(t,a.__wbindgen_malloc,a.__wbindgen_realloc),u=p;a.viewkey_decrypt(g,this.__wbg_ptr,w,u);var n=P()[g/4+0],i=P()[g/4+1],_=P()[g/4+2],o=P()[g/4+3],s=n,c=i;if(o)throw s=0,c=0,d(_);return e=s,r=c,b(s,c)}finally{a.__wbindgen_add_to_stack_pointer(16),a.__wbindgen_free(e,r,1)}}};async function vt(t,e){if("function"==typeof Response&&t instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(t,e)}catch(e){if("application/wasm"==t.headers.get("Content-Type"))throw e;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",e)}const r=await t.arrayBuffer();return await WebAssembly.instantiate(r,e)}{const r=await WebAssembly.instantiate(t,e);return r instanceof WebAssembly.Instance?{instance:r,module:t}:r}}function mt(){const t={wbg:{}};return t.wbg.__wbindgen_object_drop_ref=function(t){d(t)},t.wbg.__wbg_new_71801a555ad9f2aa=function(){return U((function(){return f(new XMLHttpRequest)}),arguments)},t.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return U((function(t,e,r){s(t).overrideMimeType(b(e,r))}),arguments)},t.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return U((function(t,e,r,n,i,_){s(t).open(b(e,r),b(n,i),0!==_)}),arguments)},t.wbg.__wbg_send_80d29985093c1ec5=function(){return U((function(t){s(t).send()}),arguments)},t.wbg.__wbg_response_7c2e2759084f7279=function(){return U((function(t){return f(s(t).response)}),arguments)},t.wbg.__wbg_status_d485fb5a478426fb=function(){return U((function(t){return s(t).status}),arguments)},t.wbg.__wbg_new_72fb9a18b5ae2624=function(){return f(new Object)},t.wbg.__wbindgen_string_new=function(t,e){return f(b(t,e))},t.wbg.__wbg_set_1f9b04f170055d33=function(){return U((function(t,e,r){return Reflect.set(s(t),s(e),s(r))}),arguments)},t.wbg.__wbg_new_ab6fd82b10560829=function(){return U((function(){return f(new Headers)}),arguments)},t.wbg.__wbindgen_object_clone_ref=function(t){return f(s(t))},t.wbg.__wbg_new_0d76b0581eca6298=function(){return U((function(){return f(new AbortController)}),arguments)},t.wbg.__wbg_signal_a61f78a3478fd9bc=function(t){return f(s(t).signal)},t.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return U((function(t,e,r,n,i){s(t).append(b(e,r),b(n,i))}),arguments)},t.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(t){let e;try{e=s(t)instanceof Response}catch(t){e=!1}return e},t.wbg.__wbg_status_61a01141acd3cf74=function(t){return s(t).status},t.wbg.__wbg_url_5f6dc4009ac5f99d=function(t,e){const r=v(s(e).url,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;P()[t/4+1]=n,P()[t/4+0]=r},t.wbg.__wbg_headers_9620bfada380764a=function(t){return f(s(t).headers)},t.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return f(Symbol.iterator)},t.wbg.__wbg_get_e3c254076557e348=function(){return U((function(t,e){return f(Reflect.get(s(t),s(e)))}),arguments)},t.wbg.__wbindgen_is_function=function(t){return"function"==typeof s(t)},t.wbg.__wbg_call_27c0f87801dedf93=function(){return U((function(t,e){return f(s(t).call(s(e)))}),arguments)},t.wbg.__wbindgen_is_object=function(t){const e=s(t);return"object"==typeof e&&null!==e},t.wbg.__wbg_next_40fc327bfc8770e6=function(t){return f(s(t).next)},t.wbg.__wbg_next_196c84450b364254=function(){return U((function(t){return f(s(t).next())}),arguments)},t.wbg.__wbg_done_298b57d23c0fc80c=function(t){return s(t).done},t.wbg.__wbg_value_d93c65011f51a456=function(t){return f(s(t).value)},t.wbg.__wbg_abort_2aa7521d5690750e=function(t){s(t).abort()},t.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return U((function(t){return f(JSON.stringify(s(t)))}),arguments)},t.wbg.__wbindgen_string_get=function(t,e){const r=s(e),n="string"==typeof r?r:void 0;var i=m(n)?0:v(n,a.__wbindgen_malloc,a.__wbindgen_realloc),_=p;P()[t/4+1]=_,P()[t/4+0]=i},t.wbg.__wbg_log_eb85b4536c227931=function(t,e){console.log(b(t,e))},t.wbg.__wbindgen_bigint_from_u64=function(t){return f(BigInt.asUintN(64,t))},t.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return U((function(t,e,r){return f(s(t).call(s(e),s(r)))}),arguments)},t.wbg.__wbg_transaction_new=function(t){return f(bt.__wrap(t))},t.wbg.__wbg_executionresponse_new=function(t){return f(D.__wrap(t))},t.wbg.__wbg_keypair_new=function(t){return f(H.__wrap(t))},t.wbg.__wbg_newwithlength_66ae46612e7f0234=function(t){return f(new Array(t>>>0))},t.wbg.__wbg_set_d4638f722068f043=function(t,e,r){s(t)[e>>>0]=d(r)},t.wbg.__wbindgen_module=function(){return f(Kt.__wbindgen_wasm_module)},t.wbg.__wbindgen_memory=function(){return f(a.memory)},t.wbg.__wbg_spawnWorker_4026f00664f3193f=function(t,e,r,n){return f(_(s(t),s(e),s(r),n>>>0))},t.wbg.__wbindgen_cb_drop=function(t){const e=d(t).original;if(1==e.cnt--)return e.a=0,!0;return!1},t.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return f(new Array)},t.wbg.__wbg_push_a5b05aedc7234f9f=function(t,e){return s(t).push(s(e))},t.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return U((function(t){return f(s(t).arrayBuffer())}),arguments)},t.wbg.__wbg_new_63b92bc8671ed464=function(t){return f(new Uint8Array(s(t)))},t.wbg.__wbg_length_c20a40f15020d68a=function(t){return s(t).length},t.wbg.__wbg_new_81740750da40724f=function(t,e){try{var r={a:t,b:e};const n=new Promise(((t,e)=>{const n=r.a;r.a=0;try{return $(n,r.b,t,e)}finally{r.a=n}}));return f(n)}finally{r.a=r.b=0}},t.wbg.__wbindgen_number_new=function(t){return f(t)},t.wbg.__wbg_new_abda76e883ba8a5f=function(){return f(new Error)},t.wbg.__wbg_stack_658279fe44541cf6=function(t,e){const r=v(s(e).stack,a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;P()[t/4+1]=n,P()[t/4+0]=r},t.wbg.__wbg_error_f851667af71bcfc6=function(t,e){let r,n;try{r=t,n=e,console.error(b(t,e))}finally{a.__wbindgen_free(r,n,1)}},t.wbg.__wbg_buffer_12d079cc21e14bdb=function(t){return f(s(t).buffer)},t.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(t,e,r){return f(new Uint8Array(s(t),e>>>0,r>>>0))},t.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return U((function(t,e){s(t).randomFillSync(d(e))}),arguments)},t.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(t,e,r){return f(s(t).subarray(e>>>0,r>>>0))},t.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return U((function(t,e){s(t).getRandomValues(s(e))}),arguments)},t.wbg.__wbg_set_a47bac70306a19a7=function(t,e,r){s(t).set(s(e),r>>>0)},t.wbg.__wbg_crypto_1d1f22824a6a080c=function(t){return f(s(t).crypto)},t.wbg.__wbg_process_4a72847cc503995b=function(t){return f(s(t).process)},t.wbg.__wbg_versions_f686565e586dd935=function(t){return f(s(t).versions)},t.wbg.__wbg_node_104a2ff8d6ea03a2=function(t){return f(s(t).node)},t.wbg.__wbindgen_is_string=function(t){return"string"==typeof s(t)},t.wbg.__wbg_require_cca90b1a94a0255b=function(){return U((function(){return f(module.require)}),arguments)},t.wbg.__wbg_msCrypto_eb05e62b530a1508=function(t){return f(s(t).msCrypto)},t.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(t){return f(new Uint8Array(t>>>0))},t.wbg.__wbg_length_cd7af8117672b8b8=function(t){return s(t).length},t.wbg.__wbg_get_bd8e338fbd5f5cc8=function(t,e){return f(s(t)[e>>>0])},t.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return U((function(){return f(self.self)}),arguments)},t.wbg.__wbg_window_c6fb939a7f436783=function(){return U((function(){return f(window.window)}),arguments)},t.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return U((function(){return f(globalThis.globalThis)}),arguments)},t.wbg.__wbg_global_207b558942527489=function(){return U((function(){return f(global.global)}),arguments)},t.wbg.__wbindgen_is_undefined=function(t){return void 0===s(t)},t.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(t,e){return f(new Function(b(t,e)))},t.wbg.__wbg_has_0af94d20077affa2=function(){return U((function(t,e){return Reflect.has(s(t),s(e))}),arguments)},t.wbg.__wbg_fetch_bc7c8e27076a5c84=function(t){return f(fetch(s(t)))},t.wbg.__wbg_fetch_921fad6ef9e883dd=function(t,e){return f(s(t).fetch(s(e)))},t.wbg.__wbindgen_debug_string=function(t,e){const r=v(S(s(e)),a.__wbindgen_malloc,a.__wbindgen_realloc),n=p;P()[t/4+1]=n,P()[t/4+0]=r},t.wbg.__wbindgen_throw=function(t,e){throw new Error(b(t,e))},t.wbg.__wbindgen_rethrow=function(t){throw d(t)},t.wbg.__wbg_then_a73caa9a87991566=function(t,e,r){return f(s(t).then(s(e),s(r)))},t.wbg.__wbg_then_0c86a60e8fcfe9f6=function(t,e){return f(s(t).then(s(e)))},t.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(t){queueMicrotask(s(t))},t.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(t){return f(s(t).queueMicrotask)},t.wbg.__wbg_resolve_b0083a7967828ec8=function(t){return f(Promise.resolve(s(t)))},t.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return f(Atomics.waitAsync)},t.wbg.__wbg_new_8cccba86b0f574cb=function(t){return f(new Int32Array(s(t)))},t.wbg.__wbg_waitAsync_46d5c36955b71a79=function(t,e,r){return f(Atomics.waitAsync(s(t),e,r))},t.wbg.__wbg_async_19c0400d97cc72fe=function(t){return s(t).async},t.wbg.__wbg_value_571d60108110e917=function(t){return f(s(t).value)},t.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(t){const e=v("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),a.__wbindgen_malloc,a.__wbindgen_realloc),r=p;P()[t/4+1]=r,P()[t/4+0]=e},t.wbg.__wbg_new_d1187ae36d662ef9=function(){return U((function(t,e){return f(new Worker(b(t,e)))}),arguments)},t.wbg.__wbg_setonmessage_503809e5bb51bd33=function(t,e){s(t).onmessage=s(e)},t.wbg.__wbg_of_6a70eed8d41f469c=function(t,e,r){return f(Array.of(s(t),s(e),s(r)))},t.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return U((function(t,e){s(t).postMessage(s(e))}),arguments)},t.wbg.__wbg_data_3ce7c145ca4fbcdc=function(t){return f(s(t).data)},t.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return U((function(t,e,r){return f(new Request(b(t,e),s(r)))}),arguments)},t.wbg.__wbg_responseText_c67ed2d48db10769=function(){return U((function(t,e){const r=s(e).responseText;var n=m(r)?0:v(r,a.__wbindgen_malloc,a.__wbindgen_realloc),i=p;P()[t/4+1]=i,P()[t/4+0]=n}),arguments)},t.wbg.__wbindgen_closure_wrapper5994=function(t,e,r){return f(T(t,e,622,E))},t.wbg.__wbindgen_closure_wrapper6020=function(t,e,r){return f(T(t,e,622,E))},t}function kt(t,e){t.wbg.memory=e||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function Pt(t,e){return a=t.exports,Kt.__wbindgen_wasm_module=e,V=null,k=null,u=null,a.__wbindgen_start(),a}function St(t,e){if(void 0!==a)return a;const r=mt();kt(r,e),t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t));return Pt(new WebAssembly.Instance(t,r),t)}async function Kt(t,e){if(void 0!==a)return a;const r=mt();("string"==typeof t||"function"==typeof Request&&t instanceof Request||"function"==typeof URL&&t instanceof URL)&&(t=fetch(t)),kt(r,e);const{instance:n,module:i}=await vt(await t,r);return Pt(n,i)}var i=Object.freeze({__proto__:null,Address:z,Execution:j,ExecutionResponse:D,Field:W,KeyPair:H,Metadata:J,OfflineQuery:Q,PrivateKey:G,PrivateKeyCiphertext:et,Program:nt,ProgramManager:_t,ProvingKey:ot,RecordCiphertext:ct,RecordPlaintext:dt,Signature:ut,Transaction:bt,VerifyingKey:pt,ViewKey:ht,default:Kt,initSync:St,initThreadPool:O,runRayonThread:A,verifyFunctionExecution:R});const Tt="aleo_wasm.wasm";const{initThreadPool:Et,Address:xt,Execution:Ft,ExecutionResponse:Rt,Field:Vt,Metadata:Ct,OfflineQuery:Bt,Private:At,PrivateKey:Ot,PrivateKeyCiphertext:Ut,Program:$t,ProvingKey:It,RecordCiphertext:zt,RecordPlaintext:Nt,ProgramManager:jt,Signature:Mt,Transaction:Dt,ViewKey:qt,VerifyingKey:Wt,verifyFunctionExecution:Zt}=await(async(t={})=>{let{importHook:e,serverPath:r,initializeHook:n}=t,_=Tt;return null!=r&&(_=r+/[^\/\\]*$/.exec(_)[0]),null!=e&&(_=e(_)),null!=n?await n(Kt,_):await Kt(_),i})({importHook:()=>new URL(r(6545),r.b)});async function Ht(t){null==t&&(t=navigator.hardwareConcurrency),console.info(`Spawning ${t} threads`),await Et(new URL(r(2851),r.b),t)}n()}catch(Lt){n(Lt)}}),1)}}]); +//# sourceMappingURL=857.bundle.js.map \ No newline at end of file diff --git a/857.bundle.js.map b/857.bundle.js.map new file mode 100644 index 000000000..824956079 --- /dev/null +++ b/857.bundle.js.map @@ -0,0 +1 @@ +{"version":3,"file":"857.bundle.js","mappings":"gSAAM,SAAUA,EAAYC,GAExB,MADAC,QAAQC,MAAMF,GACR,IAAIG,MAAMH,EACpB,CAGM,SAAUI,EAAUC,G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iB,EAAQ,OAAE5F,SAAiBke,SAAiBwK,EAAOt1B,GAE3D,OAAOi1B,GAAoBziB,EAAU5F,EACzC,CAEA,IAAIsoB,EAAuB9zB,OAAOo0B,OAAO,CACrCC,UAAW,KACXhhB,QAAS8G,EACTpF,UAAWrD,EACX0D,kBAAmBqY,EACnBvX,MAAOqN,EACP9N,QAASA,EACTtV,SAAUm0B,EACV5b,aAAcmF,EACdviB,WAAYuY,EACZoH,qBAAsBR,GACtBzc,QAAS4T,GACT/L,eAAgBoB,GAChB5C,WAAYuR,GACZ9Y,iBAAkBy3B,GAClBpsB,gBAAiBoV,GACjB2G,UAAWvP,GACX7U,YAAaytB,GACb/sB,aAAcmR,GACdyX,QAASnV,GACTugB,QAAS1G,GACTkG,SAAUA,GACVphB,eAAgBF,EAChBF,eAAgBA,EAChBtH,wBAAyBqG,IAG7B,MAAMkjB,GAAY,iB,qUAGMx7B,OAAOy7B,EAAM,CAAC,KACtB,IAAI,WAACC,EAAU,WAAEC,EAAU,eAAEC,GAAkBH,EAE3CI,EAAaL,GAiBjB,OAfkB,MAAdG,IACAE,EAAaF,EAAa,YAAYnlB,KAAKqlB,GAAY,IAGzC,MAAdH,IACAG,EAAaH,EAAWG,IAGN,MAAlBD,QACMA,EAAe/G,GAAYgH,SAG3BhH,GAAWgH,GAGdhB,CAAO,E","sources":["webpack://aleo-website/../../src/utils.ts","webpack://aleo-website/../../src/network-client.ts","webpack://aleo-website/../../src/constants.ts","webpack://aleo-website/../../src/function-key-provider.ts","webpack://aleo-website/../../src/program-manager.ts","webpack://aleo-website/aleo_wasm.js"],"sourcesContent":["export function logAndThrow(message: string): never {\n console.error(message);\n throw new Error(message);\n}\n\n\nexport function parseJSON(json: string): any {\n function revive(key: string, value: any, context: any) {\n if (Number.isInteger(value)) {\n return BigInt(context.source);\n\n } else {\n return value;\n }\n }\n\n return JSON.parse(json, revive as any);\n}\n\n\nexport async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post, parseJSON, logAndThrow } from \"./utils\";\nimport { Account } from \"./account\";\nimport { Block } from \"./models/block\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport {\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n} from \"./wasm\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/%%NETWORK%%\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/%%NETWORK%%\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = `Error fetching blocks between ${start} and ${end}.`;\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/block/latest\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return Number(await this.fetchData(\"/block/height/latest\"));\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error: any) {\n logAndThrow(\"Error fetching program imports: \" + error.message);\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error: any) {\n throw new Error(\"Error fetching program imports with error: \" + error.message);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/stateRoot/latest\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n const text = await response.text();\n return parseJSON(text);\n\n } catch (error: any) {\n throw new Error(`Error posting transaction. Aleo network response: ${error.message}`);\n }\n } catch (error: any) {\n throw new Error(`Error posting transaction: No response received: ${error.message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {VerifyingKey, Metadata} from \"./wasm\";\n\nexport const KEY_STORE = Metadata.baseUrl();\n\nexport interface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nexport const CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n throw new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nexport const PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\n\nexport const VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\n\nexport const PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\n\nexport const PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\n\nexport const PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\n\nexport const PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\n\nexport const PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n","import {\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n} from \"./constants\";\n\nimport {\n ProvingKey,\n VerifyingKey,\n} from \"./wasm\";\n\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error: any) {\n throw new Error(\"Error fetching data.\" + error.message);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n throw new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n return this.fetchCreditsKeys(key);\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw new Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error: any) {\n throw new Error(`Error: ${error.message} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error: any) {\n throw new Error(`Error: fetching credits.aleo keys: ${error.message}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner: any) {\n throw new Error(\"Invalid verifying key. Error: \" + inner.message);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\n\nimport {\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\n\nimport {\n ExecutionResponse,\n Execution as FunctionExecution,\n OfflineQuery,\n RecordPlaintext,\n PrivateKey,\n Program,\n ProvingKey,\n VerifyingKey,\n Transaction,\n ProgramManager as WasmProgramManager,\n verifyFunctionExecution,\n} from \"./wasm\";\n\nimport {\n CREDITS_PROGRAM_KEYS,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n} from \"./constants\";\n\nimport { logAndThrow } from \"./utils\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.provable.com/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n\n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e: any) {\n logAndThrow(`Error validating program: ${e.message}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e: any) {\n logAndThrow(`Error finding ${programName}. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e: any) {\n logAndThrow(`Error finding program imports. Network response: '${e.message}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e: any) {\n logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e: any) {\n logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e: any) {\n logAndThrow(`Could not synthesize keys - error ${e.message}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e: any) {\n logAndThrow(`Error finding fee keys. Key finder response: '${e.message}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.provable.com/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.provable.com/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program} The program object\n */\n createProgramFromSource(program: string): Program {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e: any) {\n logAndThrow(`Error finding fee record. Record finder response: '${e.message}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","function spawnWorker(url, module, memory, address) {\n return new Promise((resolve) => {\n const worker = new Worker(url, {\n type: \"module\",\n });\n\n worker.addEventListener(\"message\", (event) => {\n // This is needed in Node to wait one extra tick, so that way\n // the Worker can fully initialize before we return.\n setTimeout(() => {\n resolve(worker);\n\n // When running in Node, this allows the process to exit\n // even though the Worker is still running.\n if (worker.unref) {\n worker.unref();\n }\n }, 0);\n }, {\n capture: true,\n once: true,\n });\n\n worker.postMessage({\n module,\n memory,\n address,\n });\n });\n }\n\nlet wasm;\n\nconst heap = new Array(128).fill(undefined);\n\nheap.push(undefined, null, true, false);\n\nfunction getObject(idx) { return heap[idx]; }\n\nlet heap_next = heap.length;\n\nfunction dropObject(idx) {\n if (idx < 132) return;\n heap[idx] = heap_next;\n heap_next = idx;\n}\n\nfunction takeObject(idx) {\n const ret = getObject(idx);\n dropObject(idx);\n return ret;\n}\n\nconst cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );\n\nif (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); }\nlet cachedUint8Memory0 = null;\n\nfunction getUint8Memory0() {\n if (cachedUint8Memory0 === null || cachedUint8Memory0.buffer !== wasm.memory.buffer) {\n cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);\n }\n return cachedUint8Memory0;\n}\n\nfunction getStringFromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return cachedTextDecoder.decode(getUint8Memory0().slice(ptr, ptr + len));\n}\n\nfunction addHeapObject(obj) {\n if (heap_next === heap.length) heap.push(heap.length + 1);\n const idx = heap_next;\n heap_next = heap[idx];\n\n heap[idx] = obj;\n return idx;\n}\n\nlet WASM_VECTOR_LEN = 0;\n\nconst cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );\n\nconst encodeString = function (arg, view) {\n const buf = cachedTextEncoder.encode(arg);\n view.set(buf);\n return {\n read: arg.length,\n written: buf.length\n };\n};\n\nfunction passStringToWasm0(arg, malloc, realloc) {\n\n if (realloc === undefined) {\n const buf = cachedTextEncoder.encode(arg);\n const ptr = malloc(buf.length, 1) >>> 0;\n getUint8Memory0().subarray(ptr, ptr + buf.length).set(buf);\n WASM_VECTOR_LEN = buf.length;\n return ptr;\n }\n\n let len = arg.length;\n let ptr = malloc(len, 1) >>> 0;\n\n const mem = getUint8Memory0();\n\n let offset = 0;\n\n for (; offset < len; offset++) {\n const code = arg.charCodeAt(offset);\n if (code > 0x7F) break;\n mem[ptr + offset] = code;\n }\n\n if (offset !== len) {\n if (offset !== 0) {\n arg = arg.slice(offset);\n }\n ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;\n const view = getUint8Memory0().subarray(ptr + offset, ptr + len);\n const ret = encodeString(arg, view);\n\n offset += ret.written;\n ptr = realloc(ptr, len, offset, 1) >>> 0;\n }\n\n WASM_VECTOR_LEN = offset;\n return ptr;\n}\n\nfunction isLikeNone(x) {\n return x === undefined || x === null;\n}\n\nlet cachedInt32Memory0 = null;\n\nfunction getInt32Memory0() {\n if (cachedInt32Memory0 === null || cachedInt32Memory0.buffer !== wasm.memory.buffer) {\n cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);\n }\n return cachedInt32Memory0;\n}\n\nfunction debugString(val) {\n // primitive types\n const type = typeof val;\n if (type == 'number' || type == 'boolean' || val == null) {\n return `${val}`;\n }\n if (type == 'string') {\n return `\"${val}\"`;\n }\n if (type == 'symbol') {\n const description = val.description;\n if (description == null) {\n return 'Symbol';\n } else {\n return `Symbol(${description})`;\n }\n }\n if (type == 'function') {\n const name = val.name;\n if (typeof name == 'string' && name.length > 0) {\n return `Function(${name})`;\n } else {\n return 'Function';\n }\n }\n // objects\n if (Array.isArray(val)) {\n const length = val.length;\n let debug = '[';\n if (length > 0) {\n debug += debugString(val[0]);\n }\n for(let i = 1; i < length; i++) {\n debug += ', ' + debugString(val[i]);\n }\n debug += ']';\n return debug;\n }\n // Test for built-in\n const builtInMatches = /\\[object ([^\\]]+)\\]/.exec(toString.call(val));\n let className;\n if (builtInMatches.length > 1) {\n className = builtInMatches[1];\n } else {\n // Failed to match the standard '[object ClassName]'\n return toString.call(val);\n }\n if (className == 'Object') {\n // we're a user defined class or Object\n // JSON.stringify avoids problems with cycles, and is generally much\n // easier than looping through ownProperties of `val`.\n try {\n return 'Object(' + JSON.stringify(val) + ')';\n } catch (_) {\n return 'Object';\n }\n }\n // errors\n if (val instanceof Error) {\n return `${val.name}: ${val.message}\\n${val.stack}`;\n }\n // TODO we could test for more things here, like `Set`s and `Map`s.\n return className;\n}\n\nconst CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(state => {\n wasm.__wbindgen_export_3.get(state.dtor)(state.a, state.b);\n});\n\nfunction makeMutClosure(arg0, arg1, dtor, f) {\n const state = { a: arg0, b: arg1, cnt: 1, dtor };\n const real = (...args) => {\n // First up with a closure we increment the internal reference\n // count. This ensures that the Rust closure environment won't\n // be deallocated while we're invoking it.\n state.cnt++;\n const a = state.a;\n state.a = 0;\n try {\n return f(a, state.b, ...args);\n } finally {\n if (--state.cnt === 0) {\n wasm.__wbindgen_export_3.get(state.dtor)(a, state.b);\n CLOSURE_DTORS.unregister(state);\n } else {\n state.a = a;\n }\n }\n };\n real.original = state;\n CLOSURE_DTORS.register(real, state, state);\n return real;\n}\nfunction __wbg_adapter_34(arg0, arg1, arg2) {\n wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6a363ba3fe56b221(arg0, arg1, addHeapObject(arg2));\n}\n\nfunction _assertClass(instance, klass) {\n if (!(instance instanceof klass)) {\n throw new Error(`expected instance of ${klass.name}`);\n }\n return instance.ptr;\n}\n\nfunction passArray8ToWasm0(arg, malloc) {\n const ptr = malloc(arg.length * 1, 1) >>> 0;\n getUint8Memory0().set(arg, ptr / 1);\n WASM_VECTOR_LEN = arg.length;\n return ptr;\n}\n/**\n* Verify an execution with a single function and a single transition. Executions with multiple\n* transitions or functions will fail to verify. Also, this does not verify that the state root of\n* the execution is included in the Aleo Network ledger.\n*\n* @param {Execution} execution The function execution to verify\n* @param {VerifyingKey} verifying_key The verifying key for the function\n* @param {Program} program The program that the function execution belongs to\n* @param {String} function_id The name of the function that was executed\n* @returns {boolean} True if the execution is valid, false otherwise\n* @param {Execution} execution\n* @param {VerifyingKey} verifying_key\n* @param {Program} program\n* @param {string} function_id\n* @returns {boolean}\n*/\nfunction verifyFunctionExecution(execution, verifying_key, program, function_id) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(execution, Execution);\n _assertClass(verifying_key, VerifyingKey);\n _assertClass(program, Program);\n const ptr0 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyFunctionExecution(retptr, execution.__wbg_ptr, verifying_key.__wbg_ptr, program.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return r0 !== 0;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n}\n\nlet cachedBigInt64Memory0 = null;\n\nfunction getBigInt64Memory0() {\n if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.buffer !== wasm.memory.buffer) {\n cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);\n }\n return cachedBigInt64Memory0;\n}\n\nfunction getArrayU8FromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);\n}\n/**\n* @param {number} receiver\n*/\nfunction runRayonThread(receiver) {\n wasm.runRayonThread(receiver);\n}\n\n/**\n* @param {URL} url\n* @param {number} num_threads\n* @returns {Promise}\n*/\nfunction initThreadPool(url, num_threads) {\n const ret = wasm.initThreadPool(addHeapObject(url), num_threads);\n return takeObject(ret);\n}\n\nfunction handleError(f, args) {\n try {\n return f.apply(this, args);\n } catch (e) {\n wasm.__wbindgen_exn_store(addHeapObject(e));\n }\n}\nfunction __wbg_adapter_282(arg0, arg1, arg2, arg3) {\n wasm.wasm_bindgen__convert__closures__invoke2_mut__h3c510d875601a93b(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));\n}\n\nconst AddressFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_address_free(ptr >>> 0));\n/**\n* Public address of an Aleo account\n*/\nclass Address {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Address.prototype);\n obj.__wbg_ptr = ptr;\n AddressFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n AddressFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_address_free(ptr);\n }\n /**\n * Derive an Aleo address from a private key\n *\n * @param {PrivateKey} private_key The private key to derive the address from\n * @returns {Address} Address corresponding to the private key\n * @param {PrivateKey} private_key\n * @returns {Address}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.address_from_private_key(private_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Derive an Aleo address from a view key\n *\n * @param {ViewKey} view_key The view key to derive the address from\n * @returns {Address} Address corresponding to the view key\n * @param {ViewKey} view_key\n * @returns {Address}\n */\n static from_view_key(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.address_from_view_key(view_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Create an aleo address object from a string representation of an address\n *\n * @param {string} address String representation of an addressm\n * @returns {Address} Address\n * @param {string} address\n * @returns {Address}\n */\n static from_string(address) {\n const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.address_from_string(ptr0, len0);\n return Address.__wrap(ret);\n }\n /**\n * Get a string representation of an Aleo address object\n *\n * @param {Address} Address\n * @returns {string} String representation of the address\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.address_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Verify a signature for a message signed by the address\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {boolean} Boolean representing whether or not the signature is valid\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n */\n verify(message, signature) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n _assertClass(signature, Signature);\n const ret = wasm.address_verify(this.__wbg_ptr, ptr0, len0, signature.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst ExecutionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_execution_free(ptr >>> 0));\n/**\n* Execution of an Aleo program.\n*/\nclass Execution {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Execution.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_execution_free(ptr);\n }\n /**\n * Returns the string representation of the execution.\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.execution_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates an execution object from a string representation of an execution.\n * @param {string} execution\n * @returns {Execution}\n */\n static fromString(execution) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(execution, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.execution_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Execution.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ExecutionResponseFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_executionresponse_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo function execution response\n*\n* This object is returned by the execution of an Aleo function off-chain. It provides methods for\n* retrieving the outputs of the function execution.\n*/\nclass ExecutionResponse {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ExecutionResponse.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionResponseFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionResponseFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_executionresponse_free(ptr);\n }\n /**\n * Get the outputs of the executed function\n *\n * @returns {Array} Array of strings representing the outputs of the function\n * @returns {Array}\n */\n getOutputs() {\n const ret = wasm.executionresponse_getOutputs(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Returns the execution object if present, null if otherwise.\n *\n * @returns {Execution | undefined} The execution object if present, null if otherwise\n * @returns {Execution | undefined}\n */\n getExecution() {\n const ret = wasm.executionresponse_getExecution(this.__wbg_ptr);\n return ret === 0 ? undefined : Execution.__wrap(ret);\n }\n /**\n * Returns the program keys if present\n * @returns {KeyPair}\n */\n getKeys() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getKeys(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return KeyPair.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the proving_key if the proving key was cached in the Execution response.\n * Note the proving key is removed from the response object after the first call to this\n * function. Subsequent calls will return null.\n *\n * @returns {ProvingKey | undefined} The proving key\n * @returns {ProvingKey | undefined}\n */\n getProvingKey() {\n const ret = wasm.executionresponse_getProvingKey(this.__wbg_ptr);\n return ret === 0 ? undefined : ProvingKey.__wrap(ret);\n }\n /**\n * Returns the verifying_key associated with the program\n *\n * @returns {VerifyingKey} The verifying key\n * @returns {VerifyingKey}\n */\n getVerifyingKey() {\n const ret = wasm.executionresponse_getVerifyingKey(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the function identifier\n * @returns {string}\n */\n getFunctionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getFunctionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the program\n * @returns {Program}\n */\n getProgram() {\n const ret = wasm.executionresponse_getProgram(this.__wbg_ptr);\n return Program.__wrap(ret);\n }\n}\n\nconst FieldFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_field_free(ptr >>> 0));\n/**\n*/\nclass Field {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Field.prototype);\n obj.__wbg_ptr = ptr;\n FieldFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n FieldFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_field_free(ptr);\n }\n /**\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.field_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} field\n * @returns {Field}\n */\n static fromString(field) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(field, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.field_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst KeyPairFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_keypair_free(ptr >>> 0));\n/**\n* Key pair object containing both the function proving and verifying keys\n*/\nclass KeyPair {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(KeyPair.prototype);\n obj.__wbg_ptr = ptr;\n KeyPairFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n KeyPairFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_keypair_free(ptr);\n }\n /**\n * Create new key pair from proving and verifying keys\n *\n * @param {ProvingKey} proving_key Proving key corresponding to a function in an Aleo program\n * @param {VerifyingKey} verifying_key Verifying key corresponding to a function in an Aleo program\n * @returns {KeyPair} Key pair object containing both the function proving and verifying keys\n * @param {ProvingKey} proving_key\n * @param {VerifyingKey} verifying_key\n */\n constructor(proving_key, verifying_key) {\n _assertClass(proving_key, ProvingKey);\n var ptr0 = proving_key.__destroy_into_raw();\n _assertClass(verifying_key, VerifyingKey);\n var ptr1 = verifying_key.__destroy_into_raw();\n const ret = wasm.keypair_new(ptr0, ptr1);\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get the proving key. This method will remove the proving key from the key pair\n *\n * @returns {ProvingKey}\n * @returns {ProvingKey}\n */\n provingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_provingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the verifying key. This method will remove the verifying key from the key pair\n *\n * @returns {VerifyingKey}\n * @returns {VerifyingKey}\n */\n verifyingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst MetadataFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_metadata_free(ptr >>> 0));\n/**\n*/\nclass Metadata {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Metadata.prototype);\n obj.__wbg_ptr = ptr;\n MetadataFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n MetadataFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_metadata_free(ptr);\n }\n /**\n * @returns {string}\n */\n get name() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_name(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set name(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_name(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get locator() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_locator(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set locator(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_locator(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get prover() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_prover(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set prover(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_prover(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifier() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifier(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifier(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifier(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifyingKey() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifyingKey(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifyingKey(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n static baseUrl() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.metadata_baseUrl(retptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @returns {Metadata}\n */\n static bond_public() {\n const ret = wasm.metadata_bond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static bond_validator() {\n const ret = wasm.metadata_bond_validator();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static claim_unbond_public() {\n const ret = wasm.metadata_claim_unbond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_private() {\n const ret = wasm.metadata_fee_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_public() {\n const ret = wasm.metadata_fee_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static inclusion() {\n const ret = wasm.metadata_inclusion();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static join() {\n const ret = wasm.metadata_join();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static set_validator_state() {\n const ret = wasm.metadata_set_validator_state();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static split() {\n const ret = wasm.metadata_split();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private() {\n const ret = wasm.metadata_transfer_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private_to_public() {\n const ret = wasm.metadata_transfer_private_to_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public() {\n const ret = wasm.metadata_transfer_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_as_signer() {\n const ret = wasm.metadata_transfer_public_as_signer();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_to_private() {\n const ret = wasm.metadata_transfer_public_to_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static unbond_public() {\n const ret = wasm.metadata_unbond_public();\n return Metadata.__wrap(ret);\n }\n}\n\nconst OfflineQueryFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_offlinequery_free(ptr >>> 0));\n/**\n* An offline query object used to insert the global state root and state paths needed to create\n* a valid inclusion proof offline.\n*/\nclass OfflineQuery {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(OfflineQuery.prototype);\n obj.__wbg_ptr = ptr;\n OfflineQueryFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n OfflineQueryFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_offlinequery_free(ptr);\n }\n /**\n * Creates a new offline query object. The state root is required to be passed in as a string\n * @param {number} block_height\n * @param {string} state_root\n */\n constructor(block_height, state_root) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(state_root, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_new(retptr, block_height, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n this.__wbg_ptr = r0 >>> 0;\n return this;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Add a new block height to the offline query object.\n * @param {number} block_height\n */\n addBlockHeight(block_height) {\n wasm.offlinequery_addBlockHeight(this.__wbg_ptr, block_height);\n }\n /**\n * Add a new state path to the offline query object.\n *\n * @param {string} commitment: The commitment corresponding to a record inpout\n * @param {string} state_path: The state path corresponding to the commitment\n * @param {string} commitment\n * @param {string} state_path\n */\n addStatePath(commitment, state_path) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(commitment, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(state_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.offlinequery_addStatePath(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n if (r1) {\n throw takeObject(r0);\n }\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a json string representation of the offline query object\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.offlinequery_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create an offline query object from a json string representation\n * @param {string} s\n * @returns {OfflineQuery}\n */\n static fromString(s) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(s, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return OfflineQuery.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekey_free(ptr >>> 0));\n/**\n* Private key of an Aleo account\n*/\nclass PrivateKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKey.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekey_free(ptr);\n }\n /**\n * Generate a new private key using a cryptographically secure random number generator\n *\n * @returns {PrivateKey}\n */\n constructor() {\n const ret = wasm.privatekey_new();\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get a private key from a series of unchecked bytes\n *\n * @param {Uint8Array} seed Unchecked 32 byte long Uint8Array acting as the seed for the private key\n * @returns {PrivateKey}\n * @param {Uint8Array} seed\n * @returns {PrivateKey}\n */\n static from_seed_unchecked(seed) {\n const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_from_seed_unchecked(ptr0, len0);\n return PrivateKey.__wrap(ret);\n }\n /**\n * Get a private key from a string representation of a private key\n *\n * @param {string} seed String representation of a private key\n * @returns {PrivateKey}\n * @param {string} private_key\n * @returns {PrivateKey}\n */\n static from_string(private_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(private_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_from_string(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the private key. This function should be used very carefully\n * as it exposes the private key plaintext\n *\n * @returns {string} String representation of a private key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the view key corresponding to the private key\n *\n * @returns {ViewKey}\n * @returns {ViewKey}\n */\n to_view_key() {\n const ret = wasm.privatekey_to_view_key(this.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get the address corresponding to the private key\n *\n * @returns {Address}\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.privatekey_to_address(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Sign a message with the private key\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {Signature} Signature generated by signing the message with the address\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n sign(message) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(this.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a new randomly generated private key ciphertext using a secret. The secret is sensitive\n * and will be needed to decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static newEncrypted(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_newEncrypted(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Encrypt an existing private key with a secret. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n toCiphertext(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get private key from a private key ciphertext and secret originally used to encrypt it\n *\n * @param {PrivateKeyCiphertext} ciphertext Ciphertext representation of the private key\n * @param {string} secret Secret originally used to encrypt the private key\n * @returns {PrivateKey} Private key\n * @param {PrivateKeyCiphertext} ciphertext\n * @param {string} secret\n * @returns {PrivateKey}\n */\n static fromPrivateKeyCiphertext(ciphertext, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(ciphertext, PrivateKeyCiphertext);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_fromPrivateKeyCiphertext(retptr, ciphertext.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekeyciphertext_free(ptr >>> 0));\n/**\n* Private Key in ciphertext form\n*/\nclass PrivateKeyCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKeyCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekeyciphertext_free(ptr);\n }\n /**\n * Encrypt a private key using a secret string. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {PrivateKey} private_key Private key to encrypt\n * @param {string} secret Secret to encrypt the private key with\n * @returns {PrivateKeyCiphertext} Private key ciphertext\n * @param {PrivateKey} private_key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static encryptPrivateKey(private_key, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, private_key.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Decrypts a private ciphertext using a secret string. This must be the same secret used to\n * encrypt the private key\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKey} Private key\n * @param {string} secret\n * @returns {PrivateKey}\n */\n decryptToPrivateKey(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_decryptToPrivateKey(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the ciphertext string\n *\n * @returns {string} Ciphertext string\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekeyciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates a PrivateKeyCiphertext from a string\n *\n * @param {string} ciphertext Ciphertext string\n * @returns {PrivateKeyCiphertext} Private key ciphertext\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n */\n static fromString(ciphertext) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ProgramFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_program_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo program\n*/\nclass Program {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Program.prototype);\n obj.__wbg_ptr = ptr;\n ProgramFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_program_free(ptr);\n }\n /**\n * Create a program from a program string\n *\n * @param {string} program Aleo program source code\n * @returns {Program} Program object\n * @param {string} program\n * @returns {Program}\n */\n static fromString(program) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Program.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the program\n *\n * @returns {string} String containing the program source code\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Determine if a function is present in the program\n *\n * @param {string} functionName Name of the function to check for\n * @returns {boolean} True if the program is valid, false otherwise\n * @param {string} function_name\n * @returns {boolean}\n */\n hasFunction(function_name) {\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.program_hasFunction(this.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get javascript array of functions names in the program\n *\n * @returns {Array} Array of all function names present in the program\n *\n * @example\n * const expected_functions = [\n * \"mint\",\n * \"transfer_private\",\n * \"transfer_private_to_public\",\n * \"transfer_public\",\n * \"transfer_public_to_private\",\n * \"join\",\n * \"split\",\n * \"fee\"\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_functions = credits_program.getFunctions();\n * console.log(credits_functions === expected_functions); // Output should be \"true\"\n * @returns {Array}\n */\n getFunctions() {\n const ret = wasm.program_getFunctions(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Get a javascript object representation of the function inputs and types. This can be used\n * to generate a web form to capture user inputs for an execution of a function.\n *\n * @param {string} function_name Name of the function to get inputs for\n * @returns {Array} Array of function inputs\n *\n * @example\n * const expected_inputs = [\n * {\n * type:\"record\",\n * visibility:\"private\",\n * record:\"credits\",\n * members:[\n * {\n * name:\"microcredits\",\n * type:\"u64\",\n * visibility:\"private\"\n * }\n * ],\n * register:\"r0\"\n * },\n * {\n * type:\"address\",\n * visibility:\"private\",\n * register:\"r1\"\n * },\n * {\n * type:\"u64\",\n * visibility:\"private\",\n * register:\"r2\"\n * }\n * ];\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const transfer_function_inputs = credits_program.getFunctionInputs(\"transfer_private\");\n * console.log(transfer_function_inputs === expected_inputs); // Output should be \"true\"\n * @param {string} function_name\n * @returns {Array}\n */\n getFunctionInputs(function_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getFunctionInputs(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a the list of a program's mappings and the names/types of their keys and values.\n *\n * @returns {Array} - An array of objects representing the mappings in the program\n * @example\n * const expected_mappings = [\n * {\n * name: \"account\",\n * key_name: \"owner\",\n * key_type: \"address\",\n * value_name: \"microcredits\",\n * value_type: \"u64\"\n * }\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_mappings = credits_program.getMappings();\n * console.log(credits_mappings === expected_mappings); // Output should be \"true\"\n * @returns {Array}\n */\n getMappings() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_getMappings(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program record and its types\n *\n * @param {string} record_name Name of the record to get members for\n * @returns {Object} Object containing the record name, type, and members\n *\n * @example\n *\n * const expected_record = {\n * type: \"record\",\n * record: \"Credits\",\n * members: [\n * {\n * name: \"owner\",\n * type: \"address\",\n * visibility: \"private\"\n * },\n * {\n * name: \"microcredits\",\n * type: \"u64\",\n * visibility: \"private\"\n * }\n * ];\n * };\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_record = credits_program.getRecordMembers(\"Credits\");\n * console.log(credits_record === expected_record); // Output should be \"true\"\n * @param {string} record_name\n * @returns {object}\n */\n getRecordMembers(record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getRecordMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program struct and its types\n *\n * @param {string} struct_name Name of the struct to get members for\n * @returns {Array} Array containing the struct members\n *\n * @example\n *\n * const STRUCT_PROGRAM = \"program token_issue.aleo;\n *\n * struct token_metadata:\n * network as u32;\n * version as u32;\n *\n * struct token:\n * token_id as u32;\n * metadata as token_metadata;\n *\n * function no_op:\n * input r0 as u64;\n * output r0 as u64;\"\n *\n * const expected_struct_members = [\n * {\n * name: \"token_id\",\n * type: \"u32\",\n * },\n * {\n * name: \"metadata\",\n * type: \"struct\",\n * struct_id: \"token_metadata\",\n * members: [\n * {\n * name: \"network\",\n * type: \"u32\",\n * }\n * {\n * name: \"version\",\n * type: \"u32\",\n * }\n * ]\n * }\n * ];\n *\n * const program = aleo_wasm.Program.fromString(STRUCT_PROGRAM);\n * const struct_members = program.getStructMembers(\"token\");\n * console.log(struct_members === expected_struct_members); // Output should be \"true\"\n * @param {string} struct_name\n * @returns {Array}\n */\n getStructMembers(struct_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(struct_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getStructMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the credits.aleo program\n *\n * @returns {Program} The credits.aleo program\n * @returns {Program}\n */\n static getCreditsProgram() {\n const ret = wasm.program_getCreditsProgram();\n return Program.__wrap(ret);\n }\n /**\n * Get the id of the program\n *\n * @returns {string} The id of the program\n * @returns {string}\n */\n id() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_id(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get a unique address of the program\n *\n * @returns {Address} The address of the program\n * @returns {Address}\n */\n address() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_address(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Address.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determine equality with another program\n *\n * @param {Program} other The other program to compare\n * @returns {boolean} True if the programs are equal, false otherwise\n * @param {Program} other\n * @returns {boolean}\n */\n isEqual(other) {\n _assertClass(other, Program);\n const ret = wasm.program_isEqual(this.__wbg_ptr, other.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get program_imports\n *\n * @returns {Array} The program imports\n *\n * @example\n *\n * const DOUBLE_TEST = \"import multiply_test.aleo;\n *\n * program double_test.aleo;\n *\n * function double_it:\n * input r0 as u32.private;\n * call multiply_test.aleo/multiply 2u32 r0 into r1;\n * output r1 as u32.private;\";\n *\n * const expected_imports = [\n * \"multiply_test.aleo\"\n * ];\n *\n * const program = aleo_wasm.Program.fromString(DOUBLE_TEST_PROGRAM);\n * const imports = program.getImports();\n * console.log(imports === expected_imports); // Output should be \"true\"\n * @returns {Array}\n */\n getImports() {\n const ret = wasm.program_getImports(this.__wbg_ptr);\n return takeObject(ret);\n }\n}\n\nconst ProgramManagerFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_programmanager_free(ptr >>> 0));\n/**\n*/\nclass ProgramManager {\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramManagerFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_programmanager_free(ptr);\n }\n /**\n * Deploy an Aleo program\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being deployed\n * @param imports A javascript object holding the source code of any imported programs in the\n * form \\{\"program_name1\": \"program_source_code\", \"program_name2\": \"program_source_code\", ..\\}.\n * Note that all imported programs must be deployed on chain before the main program in order\n * for the deployment to succeed\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the program deployment in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildDeploymentTransaction(private_key, program, fee_credits, fee_record, url, imports, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n let ptr1 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr1 = fee_record.__destroy_into_raw();\n }\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr3 = fee_proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr4 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildDeploymentTransaction(private_key.__wbg_ptr, ptr0, len0, fee_credits, ptr1, ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the fee for a program deployment\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The source code of the program being deployed\n * @param imports (optional) Provide a list of imports to use for the deployment fee estimation\n * in the form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @returns {u64}\n * @param {string} program\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static estimateDeploymentFee(program, imports) {\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_estimateDeploymentFee(ptr0, len0, isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n /**\n * Estimate the component of the deployment cost which comes from the fee for the program name.\n * Note that this cost does not represent the entire cost of deployment. It is additional to\n * the cost of the size (in bytes) of the deployment.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param name The name of the program to be deployed\n * @returns {u64}\n * @param {string} name\n * @returns {bigint}\n */\n static estimateProgramNameCost(name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateProgramNameCost(retptr, ptr0, len0);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Execute an arbitrary function locally\n *\n * @param {PrivateKey} private_key The private key of the sender\n * @param {string} program The source code of the program being executed\n * @param {string} function The name of the function to execute\n * @param {Array} inputs A javascript array of inputs to the function\n * @param {boolean} prove_execution If true, the execution will be proven and an execution object\n * containing the proof and the encrypted inputs and outputs needed to verify the proof offline\n * will be returned.\n * @param {boolean} cache Cache the proving and verifying keys in the Execution response.\n * If this is set to 'true' the keys synthesized will be stored in the Execution Response\n * and the `ProvingKey` and `VerifyingKey` can be retrieved from the response via the `.getKeys()`\n * method.\n * @param {Object | undefined} imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param {ProvingKey | undefined} proving_key (optional) Provide a verifying key to use for the function execution\n * @param {VerifyingKey | undefined} verifying_key (optional) Provide a verifying key to use for the function execution\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {boolean} prove_execution\n * @param {boolean} cache\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {string | undefined} [url]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static executeFunctionOffline(private_key, program, _function, inputs, prove_execution, cache, imports, proving_key, verifying_key, url, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr2 = proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr3 = verifying_key.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_executeFunctionOffline(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), prove_execution, cache, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr2, ptr3, ptr4, len4, ptr5);\n return takeObject(ret);\n }\n /**\n * Execute Aleo function and create an Aleo execution transaction\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being executed\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * If this is set to 'true' the keys synthesized (or passed in as optional parameters via the\n * `proving_key` and `verifying_key` arguments) will be stored in the ProgramManager's memory\n * and used for subsequent transactions. If this is set to 'false' the proving and verifying\n * keys will be deallocated from memory after the transaction is executed.\n * @param imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the function execution\n * @param verifying_key (optional) Provide a verifying key to use for the function execution\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildExecutionTransaction(private_key, program, _function, inputs, fee_credits, fee_record, url, imports, proving_key, verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr4 = proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr5 = verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildExecutionTransaction(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), fee_credits, ptr2, ptr3, len3, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Estimate Fee for Aleo function execution. Note if \"cache\" is set to true, the proving and\n * verifying keys will be stored in the ProgramManager's memory and used for subsequent\n * program executions.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program to estimate the execution fee for\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the fee estimation in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the fee estimation\n * @param verifying_key (optional) Provide a verifying key to use for the fee estimation\n * @returns {u64} Fee in microcredits\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static estimateExecutionFee(private_key, program, _function, inputs, url, imports, proving_key, verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr3 = proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr4 = verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_estimateExecutionFee(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the finalize fee component for executing a function. This fee is additional to the\n * size of the execution of the program in bytes. If the function does not have a finalize\n * step, then the finalize fee is 0.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The program containing the function to estimate the finalize fee for\n * @param function The function to estimate the finalize fee for\n * @returns {u64} Fee in microcredits\n * @param {string} program\n * @param {string} _function\n * @returns {bigint}\n */\n static estimateFinalizeFee(program, _function) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateFinalizeFee(retptr, ptr0, len0, ptr1, len1);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Join two records together to create a new record with an amount of credits equal to the sum\n * of the credits of the two original records\n *\n * @param private_key The private key of the sender\n * @param record_1 The first record to combine\n * @param record_2 The second record to combine\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param join_proving_key (optional) Provide a proving key to use for the join function\n * @param join_verifying_key (optional) Provide a verifying key to use for the join function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction} Transaction object\n * @param {PrivateKey} private_key\n * @param {RecordPlaintext} record_1\n * @param {RecordPlaintext} record_2\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [join_proving_key]\n * @param {VerifyingKey | undefined} [join_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildJoinTransaction(private_key, record_1, record_2, fee_credits, fee_record, url, join_proving_key, join_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(record_1, RecordPlaintext);\n var ptr0 = record_1.__destroy_into_raw();\n _assertClass(record_2, RecordPlaintext);\n var ptr1 = record_2.__destroy_into_raw();\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(join_proving_key)) {\n _assertClass(join_proving_key, ProvingKey);\n ptr4 = join_proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(join_verifying_key)) {\n _assertClass(join_verifying_key, VerifyingKey);\n ptr5 = join_verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildJoinTransaction(private_key.__wbg_ptr, ptr0, ptr1, fee_credits, ptr2, ptr3, len3, ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Split an Aleo credits record into two separate records. This function does not require a fee.\n *\n * @param private_key The private key of the sender\n * @param split_amount The amount of the credit split. This amount will be subtracted from the\n * value of the record and two new records will be created with the split amount and the remainder\n * @param amount_record The record to split\n * @param url The url of the Aleo network node to send the transaction to\n * @param split_proving_key (optional) Provide a proving key to use for the split function\n * @param split_verifying_key (optional) Provide a verifying key to use for the split function\n * @returns {Transaction} Transaction object\n * @param {PrivateKey} private_key\n * @param {number} split_amount\n * @param {RecordPlaintext} amount_record\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [split_proving_key]\n * @param {VerifyingKey | undefined} [split_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildSplitTransaction(private_key, split_amount, amount_record, url, split_proving_key, split_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(amount_record, RecordPlaintext);\n var ptr0 = amount_record.__destroy_into_raw();\n var ptr1 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(split_proving_key)) {\n _assertClass(split_proving_key, ProvingKey);\n ptr2 = split_proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(split_verifying_key)) {\n _assertClass(split_verifying_key, VerifyingKey);\n ptr3 = split_verifying_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr4 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildSplitTransaction(private_key.__wbg_ptr, split_amount, ptr0, ptr1, len1, ptr2, ptr3, ptr4);\n return takeObject(ret);\n }\n /**\n * Send credits from one Aleo account to another\n *\n * @param private_key The private key of the sender\n * @param amount_credits The amount of credits to send\n * @param recipient The recipient of the transaction\n * @param transfer_type The type of the transfer (options: \"private\", \"public\", \"private_to_public\", \"public_to_private\")\n * @param amount_record The record to fund the amount from\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param transfer_verifying_key (optional) Provide a verifying key to use for the transfer\n * function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {number} amount_credits\n * @param {string} recipient\n * @param {string} transfer_type\n * @param {RecordPlaintext | undefined} amount_record\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [transfer_proving_key]\n * @param {VerifyingKey | undefined} [transfer_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildTransferTransaction(private_key, amount_credits, recipient, transfer_type, amount_record, fee_credits, fee_record, url, transfer_proving_key, transfer_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(recipient, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(transfer_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(amount_record)) {\n _assertClass(amount_record, RecordPlaintext);\n ptr2 = amount_record.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr3 = fee_record.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(transfer_proving_key)) {\n _assertClass(transfer_proving_key, ProvingKey);\n ptr5 = transfer_proving_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(transfer_verifying_key)) {\n _assertClass(transfer_verifying_key, VerifyingKey);\n ptr6 = transfer_verifying_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr7 = fee_proving_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr8 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr9 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr9 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildTransferTransaction(private_key.__wbg_ptr, amount_credits, ptr0, len0, ptr1, len1, ptr2, fee_credits, ptr3, ptr4, len4, ptr5, ptr6, ptr7, ptr8, ptr9);\n return takeObject(ret);\n }\n /**\n * Synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code of the program to synthesize keys for\n * @param function_id {string} The function to synthesize keys for\n * @param inputs {Array} The inputs to the function\n * @param imports {Object | undefined} The imports for the program\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} function_id\n * @param {Array} inputs\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static synthesizeKeyPair(private_key, program, function_id, inputs, imports) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_synthesizeKeyPair(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n}\n\nconst ProvingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_provingkey_free(ptr >>> 0));\n/**\n* Proving key for a function within an Aleo program\n*/\nclass ProvingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ProvingKey.prototype);\n obj.__wbg_ptr = ptr;\n ProvingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProvingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_provingkey_free(ptr);\n }\n /**\n * Verify if the proving key is for the bond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_public_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_public function, false if otherwise\n * @returns {boolean}\n */\n isBondPublicProver() {\n const ret = wasm.provingkey_isBondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the bond_validator function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_validator_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_validator function, false if otherwise\n * @returns {boolean}\n */\n isBondValidatorProver() {\n const ret = wasm.provingkey_isBondValidatorProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the claim_unbond function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"claim_unbond_proving_key.bin\");\n * provingKey.isClaimUnbondProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the claim_unbond function, false if otherwise\n * @returns {boolean}\n */\n isClaimUnbondPublicProver() {\n const ret = wasm.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_private_proving_key.bin\");\n * provingKey.isFeePrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_private function, false if otherwise\n * @returns {boolean}\n */\n isFeePrivateProver() {\n const ret = wasm.provingkey_isFeePrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_public_proving_key.bin\");\n * provingKey.isFeePublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_public function, false if otherwise\n * @returns {boolean}\n */\n isFeePublicProver() {\n const ret = wasm.provingkey_isFeePublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the inclusion function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"inclusion_proving_key.bin\");\n * provingKey.isInclusionProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the inclusion function, false if otherwise\n * @returns {boolean}\n */\n isInclusionProver() {\n const ret = wasm.provingkey_isInclusionProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the join function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"join_proving_key.bin\");\n * provingKey.isJoinProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the join function, false if otherwise\n * @returns {boolean}\n */\n isJoinProver() {\n const ret = wasm.provingkey_isJoinProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the set_validator_state function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"set_validator_set_proving_key.bin\");\n * provingKey.isSetValidatorStateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the set_validator_state function, false if otherwise\n * @returns {boolean}\n */\n isSetValidatorStateProver() {\n const ret = wasm.provingkey_isSetValidatorStateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the split function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"split_proving_key.bin\");\n * provingKey.isSplitProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the split function, false if otherwise\n * @returns {boolean}\n */\n isSplitProver() {\n const ret = wasm.provingkey_isSplitProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_proving_key.bin\");\n * provingKey.isTransferPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateProver() {\n const ret = wasm.provingkey_isTransferPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private_to_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_to_public_proving_key.bin\");\n * provingKey.isTransferPrivateToPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private_to_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateToPublicProver() {\n const ret = wasm.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_proving_key.bin\");\n * provingKey.isTransferPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicProver() {\n const ret = wasm.provingkey_isTransferPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_as_signer function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_as_signer_proving_key.bin\");\n * provingKey.isTransferPublicAsSignerProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicAsSignerProver() {\n const ret = wasm.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_to_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_to_private_proving_key.bin\");\n * provingKey.isTransferPublicToPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public_to_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicToPrivateProver() {\n const ret = wasm.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the unbond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"unbond_public.bin\");\n * provingKey.isUnbondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the unbond_public_prover function, false if otherwise\n * @returns {boolean}\n */\n isUnbondPublicProver() {\n const ret = wasm.provingkey_isUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Return the checksum of the proving key\n *\n * @returns {string} Checksum of the proving key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the proving key\n *\n * @returns {ProvingKey} A copy of the proving key\n * @returns {ProvingKey}\n */\n copy() {\n const ret = wasm.provingkey_copy(this.__wbg_ptr);\n return ProvingKey.__wrap(ret);\n }\n /**\n * Construct a new proving key from a byte array\n *\n * @param {Uint8Array} bytes Byte array representation of a proving key\n * @returns {ProvingKey}\n * @param {Uint8Array} bytes\n * @returns {ProvingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a proving key from string\n *\n * @param {string} String representation of the proving key\n * @param {string} string\n * @returns {ProvingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the byte representation of a proving key\n *\n * @returns {Uint8Array} Byte array representation of a proving key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the proving key\n *\n * @returns {string} String representation of the proving key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst RecordCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordciphertext_free(ptr >>> 0));\n/**\n* Encrypted Aleo record\n*/\nclass RecordCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n RecordCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordciphertext_free(ptr);\n }\n /**\n * Create a record ciphertext from a string\n *\n * @param {string} record String representation of a record ciphertext\n * @returns {RecordCiphertext} Record ciphertext\n * @param {string} record\n * @returns {RecordCiphertext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the string reprensentation of the record ciphertext\n *\n * @returns {string} String representation of the record ciphertext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Decrypt the record ciphertext into plaintext using the view key. The record will only\n * decrypt if the record was encrypted by the account corresponding to the view key\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {RecordPlaintext} Record plaintext object\n * @param {ViewKey} view_key\n * @returns {RecordPlaintext}\n */\n decrypt(view_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(view_key, ViewKey);\n wasm.recordciphertext_decrypt(retptr, this.__wbg_ptr, view_key.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determines if the account corresponding to the view key is the owner of the record\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {boolean}\n * @param {ViewKey} view_key\n * @returns {boolean}\n */\n isOwner(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.recordciphertext_isOwner(this.__wbg_ptr, view_key.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst RecordPlaintextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordplaintext_free(ptr >>> 0));\n/**\n* Plaintext representation of an Aleo record\n*/\nclass RecordPlaintext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordPlaintext.prototype);\n obj.__wbg_ptr = ptr;\n RecordPlaintextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordPlaintextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordplaintext_free(ptr);\n }\n /**\n * @param {string} program_id\n * @param {string} record_name\n * @returns {Field}\n */\n commitment(program_id, record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_commitment(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return a record plaintext from a string.\n *\n * @param {string} record String representation of a plaintext representation of an Aleo record\n * @returns {RecordPlaintext} Record plaintext\n * @param {string} record\n * @returns {RecordPlaintext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordplaintext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the record plaintext string\n *\n * @returns {string} String representation of the record plaintext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the amount of microcredits in the record\n *\n * @returns {u64} Amount of microcredits in the record\n * @returns {bigint}\n */\n microcredits() {\n const ret = wasm.recordplaintext_microcredits(this.__wbg_ptr);\n return BigInt.asUintN(64, ret);\n }\n /**\n * Returns the nonce of the record. This can be used to uniquely identify a record.\n *\n * @returns {string} Nonce of the record\n * @returns {string}\n */\n nonce() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_nonce(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Attempt to get the serial number of a record to determine whether or not is has been spent\n *\n * @param {PrivateKey} private_key Private key of the account that owns the record\n * @param {string} program_id Program ID of the program that the record is associated with\n * @param {string} record_name Name of the record\n * @returns {string} Serial number of the record\n * @param {PrivateKey} private_key\n * @param {string} program_id\n * @param {string} record_name\n * @returns {string}\n */\n serialNumberString(private_key, program_id, record_name) {\n let deferred4_0;\n let deferred4_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_serialNumberString(retptr, this.__wbg_ptr, private_key.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr3 = r0;\n var len3 = r1;\n if (r3) {\n ptr3 = 0; len3 = 0;\n throw takeObject(r2);\n }\n deferred4_0 = ptr3;\n deferred4_1 = len3;\n return getStringFromWasm0(ptr3, len3);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred4_0, deferred4_1, 1);\n }\n }\n}\n\nconst SignatureFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_signature_free(ptr >>> 0));\n/**\n* Cryptographic signature of a message signed by an Aleo account\n*/\nclass Signature {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Signature.prototype);\n obj.__wbg_ptr = ptr;\n SignatureFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n SignatureFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_signature_free(ptr);\n }\n /**\n * Sign a message with a private key\n *\n * @param {PrivateKey} private_key The private key to sign the message with\n * @param {Uint8Array} message Byte representation of the message to sign\n * @returns {Signature} Signature of the message\n * @param {PrivateKey} private_key\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n static sign(private_key, message) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(private_key.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Verify a signature of a message with an address\n *\n * @param {Address} address The address to verify the signature with\n * @param {Uint8Array} message Byte representation of the message to verify\n * @returns {boolean} True if the signature is valid, false otherwise\n * @param {Address} address\n * @param {Uint8Array} message\n * @returns {boolean}\n */\n verify(address, message) {\n _assertClass(address, Address);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_verify(this.__wbg_ptr, address.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get a signature from a string representation of a signature\n *\n * @param {string} signature String representation of a signature\n * @returns {Signature} Signature\n * @param {string} signature\n * @returns {Signature}\n */\n static from_string(signature) {\n const ptr0 = passStringToWasm0(signature, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_from_string(ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a string representation of a signature\n *\n * @returns {string} String representation of a signature\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.signature_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst TransactionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_transaction_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo transaction\n*\n* This object is created when generating an on-chain function deployment or execution and is the\n* object that should be submitted to the Aleo Network in order to deploy or execute a function.\n*/\nclass Transaction {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Transaction.prototype);\n obj.__wbg_ptr = ptr;\n TransactionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n TransactionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_transaction_free(ptr);\n }\n /**\n * Create a transaction from a string\n *\n * @param {string} transaction String representation of a transaction\n * @returns {Transaction}\n * @param {string} transaction\n * @returns {Transaction}\n */\n static fromString(transaction) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(transaction, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.transaction_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Transaction.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the transaction as a string. If you want to submit this transaction to the Aleo Network\n * this function will create the string that should be submitted in the `POST` data.\n *\n * @returns {string} String representation of the transaction\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the id of the transaction. This is the merkle root of the transaction's inclusion proof.\n *\n * This value can be used to query the status of the transaction on the Aleo Network to see\n * if it was successful. If successful, the transaction will be included in a block and this\n * value can be used to lookup the transaction data on-chain.\n *\n * @returns {string} Transaction id\n * @returns {string}\n */\n transactionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the type of the transaction (will return \"deploy\" or \"execute\")\n *\n * @returns {string} Transaction type\n * @returns {string}\n */\n transactionType() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionType(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst VerifyingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_verifyingkey_free(ptr >>> 0));\n/**\n* Verifying key for a function within an Aleo program\n*/\nclass VerifyingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(VerifyingKey.prototype);\n obj.__wbg_ptr = ptr;\n VerifyingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n VerifyingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_verifyingkey_free(ptr);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {VerifyingKey}\n */\n static bondPublicVerifier() {\n const ret = wasm.verifyingkey_bondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {VerifyingKey}\n */\n static bondValidatorVerifier() {\n const ret = wasm.verifyingkey_bondValidatorVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the claim_delegator function\n *\n * @returns {VerifyingKey} Verifying key for the claim_unbond_public function\n * @returns {VerifyingKey}\n */\n static claimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_claimUnbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_private function\n *\n * @returns {VerifyingKey} Verifying key for the fee_private function\n * @returns {VerifyingKey}\n */\n static feePrivateVerifier() {\n const ret = wasm.verifyingkey_feePrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_public function\n *\n * @returns {VerifyingKey} Verifying key for the fee_public function\n * @returns {VerifyingKey}\n */\n static feePublicVerifier() {\n const ret = wasm.verifyingkey_feePublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the inclusion function\n *\n * @returns {VerifyingKey} Verifying key for the inclusion function\n * @returns {VerifyingKey}\n */\n static inclusionVerifier() {\n const ret = wasm.verifyingkey_inclusionVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the join function\n *\n * @returns {VerifyingKey} Verifying key for the join function\n * @returns {VerifyingKey}\n */\n static joinVerifier() {\n const ret = wasm.verifyingkey_joinVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the set_validator_state function\n *\n * @returns {VerifyingKey} Verifying key for the set_validator_state function\n * @returns {VerifyingKey}\n */\n static setValidatorStateVerifier() {\n const ret = wasm.verifyingkey_setValidatorStateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the split function\n *\n * @returns {VerifyingKey} Verifying key for the split function\n * @returns {VerifyingKey}\n */\n static splitVerifier() {\n const ret = wasm.verifyingkey_splitVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private function\n * @returns {VerifyingKey}\n */\n static transferPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private_to_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private_to_public function\n * @returns {VerifyingKey}\n */\n static transferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_transferPrivateToPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public function\n * @returns {VerifyingKey}\n */\n static transferPublicVerifier() {\n const ret = wasm.verifyingkey_transferPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_as_signer function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_as_signer function\n * @returns {VerifyingKey}\n */\n static transferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_transferPublicAsSignerVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_to_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_to_private function\n * @returns {VerifyingKey}\n */\n static transferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPublicToPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the unbond_public function\n *\n * @returns {VerifyingKey} Verifying key for the unbond_public function\n * @returns {VerifyingKey}\n */\n static unbondPublicVerifier() {\n const ret = wasm.verifyingkey_unbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {boolean}\n */\n isBondPublicVerifier() {\n const ret = wasm.verifyingkey_isBondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {boolean}\n */\n isBondValidatorVerifier() {\n const ret = wasm.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the claim_delegator function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isClaimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePrivateVerifier() {\n const ret = wasm.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePublicVerifier() {\n const ret = wasm.verifyingkey_isFeePublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the inclusion function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isInclusionVerifier() {\n const ret = wasm.verifyingkey_isInclusionVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the join function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isJoinVerifier() {\n const ret = wasm.verifyingkey_isJoinVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the set_validator_state function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSetValidatorStateVerifier() {\n const ret = wasm.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the split function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSplitVerifier() {\n const ret = wasm.verifyingkey_isSplitVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private_to_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_as_signer function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_to_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the unbond_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get the checksum of the verifying key\n *\n * @returns {string} Checksum of the verifying key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the verifying key\n *\n * @returns {VerifyingKey} A copy of the verifying key\n * @returns {VerifyingKey}\n */\n copy() {\n const ret = wasm.verifyingkey_copy(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Construct a new verifying key from a byte array\n *\n * @param {Uint8Array} bytes Byte representation of a verifying key\n * @returns {VerifyingKey}\n * @param {Uint8Array} bytes\n * @returns {VerifyingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a verifying key from string\n *\n * @param {String} string String representation of a verifying key\n * @returns {VerifyingKey}\n * @param {string} string\n * @returns {VerifyingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a byte array from a verifying key\n *\n * @returns {Uint8Array} Byte representation of a verifying key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the verifying key\n *\n * @returns {String} String representation of the verifying key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst ViewKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_viewkey_free(ptr >>> 0));\n/**\n*/\nclass ViewKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ViewKey.prototype);\n obj.__wbg_ptr = ptr;\n ViewKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ViewKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_viewkey_free(ptr);\n }\n /**\n * Create a new view key from a private key\n *\n * @param {PrivateKey} private_key Private key\n * @returns {ViewKey} View key\n * @param {PrivateKey} private_key\n * @returns {ViewKey}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.privatekey_to_view_key(private_key.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Create a new view key from a string representation of a view key\n *\n * @param {string} view_key String representation of a view key\n * @returns {ViewKey} View key\n * @param {string} view_key\n * @returns {ViewKey}\n */\n static from_string(view_key) {\n const ptr0 = passStringToWasm0(view_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.viewkey_from_string(ptr0, len0);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get a string representation of a view key\n *\n * @returns {string} String representation of a view key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.viewkey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the address corresponding to a view key\n *\n * @returns {Address} Address\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.address_from_view_key(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Decrypt a record ciphertext with a view key\n *\n * @param {string} ciphertext String representation of a record ciphertext\n * @returns {string} String representation of a record plaintext\n * @param {string} ciphertext\n * @returns {string}\n */\n decrypt(ciphertext) {\n let deferred3_0;\n let deferred3_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.viewkey_decrypt(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr2 = r0;\n var len2 = r1;\n if (r3) {\n ptr2 = 0; len2 = 0;\n throw takeObject(r2);\n }\n deferred3_0 = ptr2;\n deferred3_1 = len2;\n return getStringFromWasm0(ptr2, len2);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);\n }\n }\n}\n\nasync function __wbg_load(module, imports) {\n if (typeof Response === 'function' && module instanceof Response) {\n if (typeof WebAssembly.instantiateStreaming === 'function') {\n try {\n return await WebAssembly.instantiateStreaming(module, imports);\n\n } catch (e) {\n if (module.headers.get('Content-Type') != 'application/wasm') {\n console.warn(\"`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n\", e);\n\n } else {\n throw e;\n }\n }\n }\n\n const bytes = await module.arrayBuffer();\n return await WebAssembly.instantiate(bytes, imports);\n\n } else {\n const instance = await WebAssembly.instantiate(module, imports);\n\n if (instance instanceof WebAssembly.Instance) {\n return { instance, module };\n\n } else {\n return instance;\n }\n }\n}\n\nfunction __wbg_get_imports() {\n const imports = {};\n imports.wbg = {};\n imports.wbg.__wbindgen_object_drop_ref = function(arg0) {\n takeObject(arg0);\n };\n imports.wbg.__wbg_new_71801a555ad9f2aa = function() { return handleError(function () {\n const ret = new XMLHttpRequest();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_overrideMimeType_ee9c51919ceb418b = function() { return handleError(function (arg0, arg1, arg2) {\n getObject(arg0).overrideMimeType(getStringFromWasm0(arg1, arg2));\n }, arguments) };\n imports.wbg.__wbg_open_c9eb0cf2c9d95679 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {\n getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), arg5 !== 0);\n }, arguments) };\n imports.wbg.__wbg_send_80d29985093c1ec5 = function() { return handleError(function (arg0) {\n getObject(arg0).send();\n }, arguments) };\n imports.wbg.__wbg_response_7c2e2759084f7279 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).response;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_status_d485fb5a478426fb = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).status;\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_72fb9a18b5ae2624 = function() {\n const ret = new Object();\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_string_new = function(arg0, arg1) {\n const ret = getStringFromWasm0(arg0, arg1);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_1f9b04f170055d33 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_ab6fd82b10560829 = function() { return handleError(function () {\n const ret = new Headers();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_object_clone_ref = function(arg0) {\n const ret = getObject(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_0d76b0581eca6298 = function() { return handleError(function () {\n const ret = new AbortController();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_signal_a61f78a3478fd9bc = function(arg0) {\n const ret = getObject(arg0).signal;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_append_7bfcb4937d1d5e29 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {\n getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));\n }, arguments) };\n imports.wbg.__wbg_instanceof_Response_849eb93e75734b6e = function(arg0) {\n let result;\n try {\n result = getObject(arg0) instanceof Response;\n } catch (_) {\n result = false;\n }\n const ret = result;\n return ret;\n };\n imports.wbg.__wbg_status_61a01141acd3cf74 = function(arg0) {\n const ret = getObject(arg0).status;\n return ret;\n };\n imports.wbg.__wbg_url_5f6dc4009ac5f99d = function(arg0, arg1) {\n const ret = getObject(arg1).url;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_headers_9620bfada380764a = function(arg0) {\n const ret = getObject(arg0).headers;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_iterator_2cee6dadfd956dfa = function() {\n const ret = Symbol.iterator;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_get_e3c254076557e348 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.get(getObject(arg0), getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_function = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'function';\n return ret;\n };\n imports.wbg.__wbg_call_27c0f87801dedf93 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg0).call(getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_object = function(arg0) {\n const val = getObject(arg0);\n const ret = typeof(val) === 'object' && val !== null;\n return ret;\n };\n imports.wbg.__wbg_next_40fc327bfc8770e6 = function(arg0) {\n const ret = getObject(arg0).next;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_next_196c84450b364254 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).next();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_done_298b57d23c0fc80c = function(arg0) {\n const ret = getObject(arg0).done;\n return ret;\n };\n imports.wbg.__wbg_value_d93c65011f51a456 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_abort_2aa7521d5690750e = function(arg0) {\n getObject(arg0).abort();\n };\n imports.wbg.__wbg_stringify_8887fe74e1c50d81 = function() { return handleError(function (arg0) {\n const ret = JSON.stringify(getObject(arg0));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_string_get = function(arg0, arg1) {\n const obj = getObject(arg1);\n const ret = typeof(obj) === 'string' ? obj : undefined;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_log_eb85b4536c227931 = function(arg0, arg1) {\n console.log(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {\n const ret = BigInt.asUintN(64, arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_call_b3ca7c6051f9bec1 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_transaction_new = function(arg0) {\n const ret = Transaction.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_executionresponse_new = function(arg0) {\n const ret = ExecutionResponse.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_keypair_new = function(arg0) {\n const ret = KeyPair.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_66ae46612e7f0234 = function(arg0) {\n const ret = new Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_d4638f722068f043 = function(arg0, arg1, arg2) {\n getObject(arg0)[arg1 >>> 0] = takeObject(arg2);\n };\n imports.wbg.__wbindgen_module = function() {\n const ret = __wbg_init.__wbindgen_wasm_module;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_memory = function() {\n const ret = wasm.memory;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_spawnWorker_4026f00664f3193f = function(arg0, arg1, arg2, arg3) {\n const ret = spawnWorker(getObject(arg0), getObject(arg1), getObject(arg2), arg3 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_cb_drop = function(arg0) {\n const obj = takeObject(arg0).original;\n if (obj.cnt-- == 1) {\n obj.a = 0;\n return true;\n }\n const ret = false;\n return ret;\n };\n imports.wbg.__wbg_new_16b304a2cfa7ff4a = function() {\n const ret = new Array();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_push_a5b05aedc7234f9f = function(arg0, arg1) {\n const ret = getObject(arg0).push(getObject(arg1));\n return ret;\n };\n imports.wbg.__wbg_arrayBuffer_29931d52c7206b02 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).arrayBuffer();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_new_63b92bc8671ed464 = function(arg0) {\n const ret = new Uint8Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_c20a40f15020d68a = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_new_81740750da40724f = function(arg0, arg1) {\n try {\n var state0 = {a: arg0, b: arg1};\n var cb0 = (arg0, arg1) => {\n const a = state0.a;\n state0.a = 0;\n try {\n return __wbg_adapter_282(a, state0.b, arg0, arg1);\n } finally {\n state0.a = a;\n }\n };\n const ret = new Promise(cb0);\n return addHeapObject(ret);\n } finally {\n state0.a = state0.b = 0;\n }\n };\n imports.wbg.__wbindgen_number_new = function(arg0) {\n const ret = arg0;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_abda76e883ba8a5f = function() {\n const ret = new Error();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_stack_658279fe44541cf6 = function(arg0, arg1) {\n const ret = getObject(arg1).stack;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {\n let deferred0_0;\n let deferred0_1;\n try {\n deferred0_0 = arg0;\n deferred0_1 = arg1;\n console.error(getStringFromWasm0(arg0, arg1));\n } finally {\n wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);\n }\n };\n imports.wbg.__wbg_buffer_12d079cc21e14bdb = function(arg0) {\n const ret = getObject(arg0).buffer;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb = function(arg0, arg1, arg2) {\n const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_randomFillSync_5c9c955aa56b6049 = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).randomFillSync(takeObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_subarray_a1f73cd4b5b42fe1 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_getRandomValues_3aa56aa6edec874c = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).getRandomValues(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_set_a47bac70306a19a7 = function(arg0, arg1, arg2) {\n getObject(arg0).set(getObject(arg1), arg2 >>> 0);\n };\n imports.wbg.__wbg_crypto_1d1f22824a6a080c = function(arg0) {\n const ret = getObject(arg0).crypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_process_4a72847cc503995b = function(arg0) {\n const ret = getObject(arg0).process;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_versions_f686565e586dd935 = function(arg0) {\n const ret = getObject(arg0).versions;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_node_104a2ff8d6ea03a2 = function(arg0) {\n const ret = getObject(arg0).node;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_is_string = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'string';\n return ret;\n };\n imports.wbg.__wbg_require_cca90b1a94a0255b = function() { return handleError(function () {\n const ret = module.require;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_msCrypto_eb05e62b530a1508 = function(arg0) {\n const ret = getObject(arg0).msCrypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_e9b4878cebadb3d3 = function(arg0) {\n const ret = new Uint8Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_cd7af8117672b8b8 = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_get_bd8e338fbd5f5cc8 = function(arg0, arg1) {\n const ret = getObject(arg0)[arg1 >>> 0];\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_self_ce0dbfc45cf2f5be = function() { return handleError(function () {\n const ret = self.self;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_window_c6fb939a7f436783 = function() { return handleError(function () {\n const ret = window.window;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_globalThis_d1e6af4856ba331b = function() { return handleError(function () {\n const ret = globalThis.globalThis;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_global_207b558942527489 = function() { return handleError(function () {\n const ret = global.global;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_undefined = function(arg0) {\n const ret = getObject(arg0) === undefined;\n return ret;\n };\n imports.wbg.__wbg_newnoargs_e258087cd0daa0ea = function(arg0, arg1) {\n const ret = new Function(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_has_0af94d20077affa2 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.has(getObject(arg0), getObject(arg1));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_fetch_bc7c8e27076a5c84 = function(arg0) {\n const ret = fetch(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_fetch_921fad6ef9e883dd = function(arg0, arg1) {\n const ret = getObject(arg0).fetch(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {\n const ret = debugString(getObject(arg1));\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbindgen_throw = function(arg0, arg1) {\n throw new Error(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_rethrow = function(arg0) {\n throw takeObject(arg0);\n };\n imports.wbg.__wbg_then_a73caa9a87991566 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_then_0c86a60e8fcfe9f6 = function(arg0, arg1) {\n const ret = getObject(arg0).then(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_queueMicrotask_481971b0d87f3dd4 = function(arg0) {\n queueMicrotask(getObject(arg0));\n };\n imports.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6 = function(arg0) {\n const ret = getObject(arg0).queueMicrotask;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_resolve_b0083a7967828ec8 = function(arg0) {\n const ret = Promise.resolve(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_5d743fc9058ba01a = function() {\n const ret = Atomics.waitAsync;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_8cccba86b0f574cb = function(arg0) {\n const ret = new Int32Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_46d5c36955b71a79 = function(arg0, arg1, arg2) {\n const ret = Atomics.waitAsync(getObject(arg0), arg1, arg2);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_async_19c0400d97cc72fe = function(arg0) {\n const ret = getObject(arg0).async;\n return ret;\n };\n imports.wbg.__wbg_value_571d60108110e917 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_link_fc1eedd35dc7e0a6 = function(arg0) {\n const ret = \"data:application/javascript,\" + encodeURIComponent(`onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n `);\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_new_d1187ae36d662ef9 = function() { return handleError(function (arg0, arg1) {\n const ret = new Worker(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_setonmessage_503809e5bb51bd33 = function(arg0, arg1) {\n getObject(arg0).onmessage = getObject(arg1);\n };\n imports.wbg.__wbg_of_6a70eed8d41f469c = function(arg0, arg1, arg2) {\n const ret = Array.of(getObject(arg0), getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_postMessage_7380d10e8b8269df = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).postMessage(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_data_3ce7c145ca4fbcdc = function(arg0) {\n const ret = getObject(arg0).data;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_responseText_c67ed2d48db10769 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg1).responseText;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n }, arguments) };\n imports.wbg.__wbindgen_closure_wrapper5994 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 622, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_closure_wrapper6020 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 622, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n\n return imports;\n}\n\nfunction __wbg_init_memory(imports, maybe_memory) {\n imports.wbg.memory = maybe_memory || new WebAssembly.Memory({initial:25,maximum:65536,shared:true});\n}\n\nfunction __wbg_finalize_init(instance, module) {\n wasm = instance.exports;\n __wbg_init.__wbindgen_wasm_module = module;\n cachedBigInt64Memory0 = null;\n cachedInt32Memory0 = null;\n cachedUint8Memory0 = null;\n\n wasm.__wbindgen_start();\n return wasm;\n}\n\nfunction initSync(module, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n const imports = __wbg_get_imports();\n\n __wbg_init_memory(imports, maybe_memory);\n\n if (!(module instanceof WebAssembly.Module)) {\n module = new WebAssembly.Module(module);\n }\n\n const instance = new WebAssembly.Instance(module, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nasync function __wbg_init(input, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n\n const imports = __wbg_get_imports();\n\n if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {\n input = fetch(input);\n }\n\n __wbg_init_memory(imports, maybe_memory);\n\n const { instance, module } = await __wbg_load(await input, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nvar exports = /*#__PURE__*/Object.freeze({\n __proto__: null,\n Address: Address,\n Execution: Execution,\n ExecutionResponse: ExecutionResponse,\n Field: Field,\n KeyPair: KeyPair,\n Metadata: Metadata,\n OfflineQuery: OfflineQuery,\n PrivateKey: PrivateKey,\n PrivateKeyCiphertext: PrivateKeyCiphertext,\n Program: Program,\n ProgramManager: ProgramManager,\n ProvingKey: ProvingKey,\n RecordCiphertext: RecordCiphertext,\n RecordPlaintext: RecordPlaintext,\n Signature: Signature,\n Transaction: Transaction,\n VerifyingKey: VerifyingKey,\n ViewKey: ViewKey,\n default: __wbg_init,\n initSync: initSync,\n initThreadPool: initThreadPool,\n runRayonThread: runRayonThread,\n verifyFunctionExecution: verifyFunctionExecution\n});\n\nconst wasm_path = \"aleo_wasm.wasm\";\n\n \n var Cargo = async (opt = {}) => {\n let {importHook, serverPath, initializeHook} = opt;\n\n let final_path = wasm_path;\n\n if (serverPath != null) {\n final_path = serverPath + /[^\\/\\\\]*$/.exec(final_path)[0];\n }\n\n if (importHook != null) {\n final_path = importHook(final_path);\n }\n\n if (initializeHook != null) {\n await initializeHook(__wbg_init, final_path);\n\n } else {\n await __wbg_init(final_path);\n }\n\n return exports;\n };\n\nexport { Cargo as default };\n//# sourceMappingURL=aleo_wasm.js.map\n"],"names":["logAndThrow","message","console","error","Error","parseJSON","json","JSON","parse","key","value","context","Number","isInteger","BigInt","source","async","get","url","options","response","fetch","ok","status","post","method","AleoNetworkClient","host","headers","account","constructor","this","setAccount","getAccount","setHost","fetchData","text","findUnspentRecords","startHeight","endHeight","privateKey","amounts","maxMicrocredits","nonces","records","Array","start","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","_privateKey","PrivateKey","from_string","viewKey","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","length","transactions","j","confirmedTransaction","type","transaction","execution","transitions","k","transition","program","outputs","l","output","record","RecordCiphertext","fromString","isOwner","recordPlaintext","decrypt","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","warn","toString","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","id","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","Object","assign","KEY_STORE","Metadata","baseUrl","convert","metadata","verifyingKey","VerifyingKey","name","locator","prover","verifier","CREDITS_PROGRAM_KEYS","bond_public","bond_validator","claim_unbond_public","fee_private","fee_public","inclusion","join","set_validator_state","split","transfer_private","transfer_private_to_public","transfer_public","transfer_public_as_signer","transfer_public_to_private","unbond_public","getKey","PRIVATE_TRANSFER_TYPES","Set","VALID_TRANSFER_TYPES","PRIVATE_TRANSFER","PRIVATE_TO_PUBLIC_TRANSFER","PUBLIC_TRANSFER","PUBLIC_TRANSFER_AS_SIGNER","PUBLIC_TO_PRIVATE_TRANSFER","AleoKeyProviderParams","proverUri","verifierUri","cacheKey","params","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","data","arrayBuffer","Uint8Array","Map","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","set","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","functionKeys","proverUrl","verifierUrl","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","keyPair","verifying_key","proving_key","bondPublicKeys","bondValidatorKeys","claimUnbondPublicKeys","transferKeys","visibility","joinKeys","splitKeys","feePrivateKeys","feePublicKeys","e","inner","unBondPublicKeys","ProgramManager","keyProvider","networkClient","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","undefined","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","transfer","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","Math","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","findCreditsRecord","spawnWorker","module","memory","address","Promise","resolve","worker","Worker","addEventListener","event","setTimeout","unref","capture","once","postMessage","wasm","heap","fill","getObject","idx","heap_next","dropObject","takeObject","ret","cachedTextDecoder","TextDecoder","ignoreBOM","fatal","decode","cachedUint8Memory0","getUint8Memory0","buffer","getStringFromWasm0","ptr","len","slice","addHeapObject","obj","WASM_VECTOR_LEN","cachedTextEncoder","TextEncoder","encode","encodeString","arg","view","buf","read","written","passStringToWasm0","malloc","realloc","subarray","mem","offset","code","charCodeAt","isLikeNone","x","cachedInt32Memory0","getInt32Memory0","Int32Array","debugString","val","description","isArray","builtInMatches","exec","call","className","stringify","_","stack","CLOSURE_DTORS","FinalizationRegistry","register","unregister","state","__wbindgen_export_3","dtor","a","b","makeMutClosure","arg0","arg1","f","cnt","real","args","original","__wbg_adapter_34","arg2","_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h6a363ba3fe56b221","_assertClass","instance","klass","passArray8ToWasm0","verifyFunctionExecution$1","retptr","__wbindgen_add_to_stack_pointer","Execution$1","VerifyingKey$1","Program$1","ptr0","__wbindgen_malloc","__wbindgen_realloc","len0","__wbg_ptr","r0","r1","cachedBigInt64Memory0","getBigInt64Memory0","BigInt64Array","getArrayU8FromWasm0","runRayonThread","receiver","initThreadPool$1","num_threads","initThreadPool","handleError","apply","__wbindgen_exn_store","__wbg_adapter_282","arg3","wasm_bindgen__convert__closures__invoke2_mut__h3c510d875601a93b","AddressFinalization","__wbg_address_free","Address","__wrap","create","prototype","__destroy_into_raw","free","from_private_key","private_key","PrivateKey$1","address_from_private_key","from_view_key","view_key","ViewKey$1","address_from_view_key","address_from_string","to_string","deferred1_0","deferred1_1","address_to_string","__wbindgen_free","verify","signature","Signature$1","address_verify","ExecutionFinalization","__wbg_execution_free","Execution","execution_toString","execution_fromString","ExecutionResponseFinalization","__wbg_executionresponse_free","ExecutionResponse","getOutputs","executionresponse_getOutputs","executionresponse_getExecution","executionresponse_getKeys","KeyPair","getProvingKey","executionresponse_getProvingKey","ProvingKey$1","executionresponse_getVerifyingKey","executionresponse_getFunctionId","executionresponse_getProgram","FieldFinalization","__wbg_field_free","Field","field_toString","field","field_fromString","KeyPairFinalization","__wbg_keypair_free","ptr1","keypair_new","keypair_provingKey","keypair_verifyingKey","MetadataFinalization","__wbg_metadata_free","__wbg_get_metadata_name","__wbg_set_metadata_name","__wbg_get_metadata_locator","__wbg_set_metadata_locator","__wbg_get_metadata_prover","__wbg_set_metadata_prover","__wbg_get_metadata_verifier","__wbg_set_metadata_verifier","__wbg_get_metadata_verifyingKey","__wbg_set_metadata_verifyingKey","metadata_baseUrl","metadata_bond_public","metadata_bond_validator","metadata_claim_unbond_public","metadata_fee_private","metadata_fee_public","metadata_inclusion","metadata_join","metadata_set_validator_state","metadata_split","metadata_transfer_private","metadata_transfer_private_to_public","metadata_transfer_public","metadata_transfer_public_as_signer","metadata_transfer_public_to_private","metadata_unbond_public","OfflineQueryFinalization","__wbg_offlinequery_free","OfflineQuery","block_height","state_root","offlinequery_new","addBlockHeight","offlinequery_addBlockHeight","addStatePath","commitment","state_path","len1","offlinequery_addStatePath","offlinequery_toString","s","offlinequery_fromString","PrivateKeyFinalization","__wbg_privatekey_free","privatekey_new","from_seed_unchecked","seed","privatekey_from_seed_unchecked","privatekey_from_string","privatekey_to_string","privatekey_to_view_key","to_address","privatekey_to_address","Address$1","sign","privatekey_sign","newEncrypted","secret","privatekey_newEncrypted","PrivateKeyCiphertext$1","toCiphertext","privatekey_toCiphertext","fromPrivateKeyCiphertext","ciphertext","privatekey_fromPrivateKeyCiphertext","PrivateKeyCiphertextFinalization","__wbg_privatekeyciphertext_free","PrivateKeyCiphertext","encryptPrivateKey","decryptToPrivateKey","privatekeyciphertext_decryptToPrivateKey","privatekeyciphertext_toString","privatekeyciphertext_fromString","ProgramFinalization","__wbg_program_free","program_fromString","program_toString","hasFunction","program_hasFunction","getFunctions","program_getFunctions","getFunctionInputs","program_getFunctionInputs","getMappings","program_getMappings","getRecordMembers","record_name","program_getRecordMembers","getStructMembers","struct_name","program_getStructMembers","program_getCreditsProgram","program_id","program_address","isEqual","other","program_isEqual","program_getImports","ProgramManagerFinalization","__wbg_programmanager_free","fee_credits","fee_record","fee_proving_key","fee_verifying_key","offline_query","RecordPlaintext$1","ptr2","len2","ptr3","ptr4","ptr5","OfflineQuery$1","programmanager_buildDeploymentTransaction","estimateDeploymentFee","programmanager_estimateDeploymentFee","estimateProgramNameCost","programmanager_estimateProgramNameCost","r2","asUintN","_function","prove_execution","len4","programmanager_executeFunctionOffline","len3","ptr6","ptr7","ptr8","programmanager_buildExecutionTransaction","estimateExecutionFee","programmanager_estimateExecutionFee","estimateFinalizeFee","programmanager_estimateFinalizeFee","record_1","record_2","join_proving_key","join_verifying_key","programmanager_buildJoinTransaction","split_amount","amount_record","split_proving_key","split_verifying_key","programmanager_buildSplitTransaction","amount_credits","transfer_type","transfer_proving_key","transfer_verifying_key","ptr9","programmanager_buildTransferTransaction","programmanager_synthesizeKeyPair","ProvingKeyFinalization","__wbg_provingkey_free","isBondPublicProver","provingkey_isBondPublicProver","isBondValidatorProver","provingkey_isBondValidatorProver","isClaimUnbondPublicProver","provingkey_isClaimUnbondPublicProver","isFeePrivateProver","provingkey_isFeePrivateProver","isFeePublicProver","provingkey_isFeePublicProver","isInclusionProver","provingkey_isInclusionProver","isJoinProver","provingkey_isJoinProver","isSetValidatorStateProver","provingkey_isSetValidatorStateProver","isSplitProver","provingkey_isSplitProver","isTransferPrivateProver","provingkey_isTransferPrivateProver","isTransferPrivateToPublicProver","provingkey_isTransferPrivateToPublicProver","isTransferPublicProver","provingkey_isTransferPublicProver","isTransferPublicAsSignerProver","provingkey_isTransferPublicAsSignerProver","isTransferPublicToPrivateProver","provingkey_isTransferPublicToPrivateProver","isUnbondPublicProver","provingkey_isUnbondPublicProver","checksum","provingkey_checksum","copy","provingkey_copy","bytes","provingkey_fromBytes","string","provingkey_fromString","provingkey_toBytes","v1","provingkey_toString","RecordCiphertextFinalization","__wbg_recordciphertext_free","recordciphertext_fromString","recordciphertext_toString","recordciphertext_decrypt","recordciphertext_isOwner","RecordPlaintextFinalization","__wbg_recordplaintext_free","recordplaintext_commitment","Field$1","recordplaintext_fromString","recordplaintext_toString","recordplaintext_microcredits","recordplaintext_nonce","deferred4_0","deferred4_1","recordplaintext_serialNumberString","r3","SignatureFinalization","__wbg_signature_free","Signature","signature_verify","signature_from_string","signature_to_string","TransactionFinalization","__wbg_transaction_free","transaction_fromString","transaction_toString","transactionId","transaction_transactionId","transactionType","transaction_transactionType","VerifyingKeyFinalization","__wbg_verifyingkey_free","bondPublicVerifier","verifyingkey_bondPublicVerifier","bondValidatorVerifier","verifyingkey_bondValidatorVerifier","claimUnbondPublicVerifier","verifyingkey_claimUnbondPublicVerifier","feePrivateVerifier","verifyingkey_feePrivateVerifier","feePublicVerifier","verifyingkey_feePublicVerifier","inclusionVerifier","verifyingkey_inclusionVerifier","joinVerifier","verifyingkey_joinVerifier","setValidatorStateVerifier","verifyingkey_setValidatorStateVerifier","splitVerifier","verifyingkey_splitVerifier","transferPrivateVerifier","verifyingkey_transferPrivateVerifier","transferPrivateToPublicVerifier","verifyingkey_transferPrivateToPublicVerifier","transferPublicVerifier","verifyingkey_transferPublicVerifier","transferPublicAsSignerVerifier","verifyingkey_transferPublicAsSignerVerifier","transferPublicToPrivateVerifier","verifyingkey_transferPublicToPrivateVerifier","unbondPublicVerifier","verifyingkey_unbondPublicVerifier","isBondPublicVerifier","verifyingkey_isBondPublicVerifier","isBondValidatorVerifier","verifyingkey_isBondValidatorVerifier","isClaimUnbondPublicVerifier","verifyingkey_isClaimUnbondPublicVerifier","isFeePrivateVerifier","verifyingkey_isFeePrivateVerifier","isFeePublicVerifier","verifyingkey_isFeePublicVerifier","isInclusionVerifier","verifyingkey_isInclusionVerifier","isJoinVerifier","verifyingkey_isJoinVerifier","isSetValidatorStateVerifier","verifyingkey_isSetValidatorStateVerifier","isSplitVerifier","verifyingkey_isSplitVerifier","isTransferPrivateVerifier","verifyingkey_isTransferPrivateVerifier","isTransferPrivateToPublicVerifier","verifyingkey_isTransferPrivateToPublicVerifier","isTransferPublicVerifier","verifyingkey_isTransferPublicVerifier","isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicAsSignerVerifier","isTransferPublicToPrivateVerifier","verifyingkey_isTransferPublicToPrivateVerifier","isUnbondPublicVerifier","verifyingkey_isUnbondPublicVerifier","verifyingkey_checksum","verifyingkey_copy","verifyingkey_fromBytes","verifyingkey_fromString","verifyingkey_toBytes","verifyingkey_toString","ViewKeyFinalization","__wbg_viewkey_free","ViewKey","viewkey_from_string","viewkey_to_string","deferred3_0","deferred3_1","viewkey_decrypt","__wbg_load","Response","WebAssembly","instantiateStreaming","instantiate","Instance","__wbg_get_imports","wbg","__wbindgen_object_drop_ref","__wbg_new_71801a555ad9f2aa","XMLHttpRequest","arguments","__wbg_overrideMimeType_ee9c51919ceb418b","overrideMimeType","__wbg_open_c9eb0cf2c9d95679","arg4","arg5","open","__wbg_send_80d29985093c1ec5","send","__wbg_response_7c2e2759084f7279","__wbg_status_d485fb5a478426fb","__wbg_new_72fb9a18b5ae2624","__wbindgen_string_new","__wbg_set_1f9b04f170055d33","Reflect","__wbg_new_ab6fd82b10560829","Headers","__wbindgen_object_clone_ref","__wbg_new_0d76b0581eca6298","AbortController","__wbg_signal_a61f78a3478fd9bc","signal","__wbg_append_7bfcb4937d1d5e29","append","__wbg_instanceof_Response_849eb93e75734b6e","result","__wbg_status_61a01141acd3cf74","__wbg_url_5f6dc4009ac5f99d","__wbg_headers_9620bfada380764a","__wbg_iterator_2cee6dadfd956dfa","Symbol","iterator","__wbg_get_e3c254076557e348","__wbindgen_is_function","__wbg_call_27c0f87801dedf93","__wbindgen_is_object","__wbg_next_40fc327bfc8770e6","next","__wbg_next_196c84450b364254","__wbg_done_298b57d23c0fc80c","done","__wbg_value_d93c65011f51a456","__wbg_abort_2aa7521d5690750e","abort","__wbg_stringify_8887fe74e1c50d81","__wbindgen_string_get","__wbg_log_eb85b4536c227931","__wbindgen_bigint_from_u64","__wbg_call_b3ca7c6051f9bec1","__wbg_transaction_new","Transaction$1","__wbg_executionresponse_new","ExecutionResponse$1","__wbg_keypair_new","__wbg_newwithlength_66ae46612e7f0234","__wbg_set_d4638f722068f043","__wbindgen_module","__wbg_init","__wbindgen_wasm_module","__wbindgen_memory","__wbg_spawnWorker_4026f00664f3193f","__wbindgen_cb_drop","__wbg_new_16b304a2cfa7ff4a","__wbg_push_a5b05aedc7234f9f","__wbg_arrayBuffer_29931d52c7206b02","__wbg_new_63b92bc8671ed464","__wbg_length_c20a40f15020d68a","__wbg_new_81740750da40724f","state0","cb0","__wbindgen_number_new","__wbg_new_abda76e883ba8a5f","__wbg_stack_658279fe44541cf6","__wbg_error_f851667af71bcfc6","deferred0_0","deferred0_1","__wbg_buffer_12d079cc21e14bdb","__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb","__wbg_randomFillSync_5c9c955aa56b6049","randomFillSync","__wbg_subarray_a1f73cd4b5b42fe1","__wbg_getRandomValues_3aa56aa6edec874c","getRandomValues","__wbg_set_a47bac70306a19a7","__wbg_crypto_1d1f22824a6a080c","crypto","__wbg_process_4a72847cc503995b","process","__wbg_versions_f686565e586dd935","versions","__wbg_node_104a2ff8d6ea03a2","node","__wbindgen_is_string","__wbg_require_cca90b1a94a0255b","require","__wbg_msCrypto_eb05e62b530a1508","msCrypto","__wbg_newwithlength_e9b4878cebadb3d3","__wbg_length_cd7af8117672b8b8","__wbg_get_bd8e338fbd5f5cc8","__wbg_self_ce0dbfc45cf2f5be","self","__wbg_window_c6fb939a7f436783","window","__wbg_globalThis_d1e6af4856ba331b","globalThis","__wbg_global_207b558942527489","global","__wbindgen_is_undefined","__wbg_newnoargs_e258087cd0daa0ea","Function","__wbg_has_0af94d20077affa2","__wbg_fetch_bc7c8e27076a5c84","__wbg_fetch_921fad6ef9e883dd","__wbindgen_debug_string","__wbindgen_throw","__wbindgen_rethrow","__wbg_then_a73caa9a87991566","then","__wbg_then_0c86a60e8fcfe9f6","__wbg_queueMicrotask_481971b0d87f3dd4","queueMicrotask","__wbg_queueMicrotask_3cbae2ec6b6cd3d6","__wbg_resolve_b0083a7967828ec8","__wbg_waitAsync_5d743fc9058ba01a","Atomics","waitAsync","__wbg_new_8cccba86b0f574cb","__wbg_waitAsync_46d5c36955b71a79","__wbg_async_19c0400d97cc72fe","__wbg_value_571d60108110e917","__wbindgen_link_fc1eedd35dc7e0a6","encodeURIComponent","__wbg_new_d1187ae36d662ef9","__wbg_setonmessage_503809e5bb51bd33","onmessage","__wbg_of_6a70eed8d41f469c","of","__wbg_postMessage_7380d10e8b8269df","__wbg_data_3ce7c145ca4fbcdc","__wbg_newwithstrandinit_3fd6fba4083ff2d0","Request","__wbg_responseText_c67ed2d48db10769","responseText","__wbindgen_closure_wrapper5994","__wbindgen_closure_wrapper6020","__wbg_init_memory","maybe_memory","Memory","initial","maximum","shared","__wbg_finalize_init","exports","__wbindgen_start","initSync","Module","input","URL","freeze","__proto__","Metadata$1","RecordCiphertext$1","default","wasm_path","opt","importHook","serverPath","initializeHook","final_path"],"sourceRoot":""} \ No newline at end of file diff --git a/876.bundle.js b/876.bundle.js deleted file mode 100644 index 506ceae0f..000000000 --- a/876.bundle.js +++ /dev/null @@ -1,3 +0,0 @@ -/*! For license information please see 876.bundle.js.LICENSE.txt */ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[876,495],{720:(e,r,t)=>{t.d(r,{LV:()=>f});const i=Symbol("Comlink.proxy"),n=Symbol("Comlink.endpoint"),a=Symbol("Comlink.releaseProxy"),o=Symbol("Comlink.finalizer"),s=Symbol("Comlink.thrown"),c=e=>"object"==typeof e&&null!==e||"function"==typeof e,u=new Map([["proxy",{canHandle:e=>c(e)&&e[i],serialize(e){const{port1:r,port2:t}=new MessageChannel;return h(e,r),[t,[t]]},deserialize:e=>(e.start(),f(e))}],["throw",{canHandle:e=>c(e)&&s in e,serialize({value:e}){let r;return r=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[r,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function h(e,r=globalThis,t=["*"]){r.addEventListener("message",(function n(a){if(!a||!a.data)return;if(!function(e,r){for(const t of e){if(r===t||"*"===t)return!0;if(t instanceof RegExp&&t.test(r))return!0}return!1}(t,a.origin))return void console.warn(`Invalid origin '${a.origin}' for comlink proxy`);const{id:c,type:u,path:f}=Object.assign({path:[]},a.data),y=(a.data.argumentList||[]).map(P);let d;try{const r=f.slice(0,-1).reduce(((e,r)=>e[r]),e),t=f.reduce(((e,r)=>e[r]),e);switch(u){case"GET":d=t;break;case"SET":r[f.slice(-1)[0]]=P(a.data.value),d=!0;break;case"APPLY":d=t.apply(r,y);break;case"CONSTRUCT":d=function(e){return Object.assign(e,{[i]:!0})}(new t(...y));break;case"ENDPOINT":{const{port1:r,port2:t}=new MessageChannel;h(e,t),d=function(e,r){return w.set(e,r),e}(r,[r])}break;case"RELEASE":d=void 0;break;default:return}}catch(e){d={value:e,[s]:0}}Promise.resolve(d).catch((e=>({value:e,[s]:0}))).then((t=>{const[i,a]=m(t);r.postMessage(Object.assign(Object.assign({},i),{id:c}),a),"RELEASE"===u&&(r.removeEventListener("message",n),l(r),o in e&&"function"==typeof e[o]&&e[o]())})).catch((e=>{const[t,i]=m({value:new TypeError("Unserializable return value"),[s]:0});r.postMessage(Object.assign(Object.assign({},t),{id:c}),i)}))})),r.start&&r.start()}function l(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function f(e,r){return g(e,[],r)}function y(e){if(e)throw new Error("Proxy has been released and is not useable")}function d(e){return _(e,{type:"RELEASE"}).then((()=>{l(e)}))}const p=new WeakMap,v="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const r=(p.get(e)||0)-1;p.set(e,r),0===r&&d(e)}));function g(e,r=[],t=function(){}){let i=!1;const o=new Proxy(t,{get(t,n){if(y(i),n===a)return()=>{!function(e){v&&v.unregister(e)}(o),d(e),i=!0};if("then"===n){if(0===r.length)return{then:()=>o};const t=_(e,{type:"GET",path:r.map((e=>e.toString()))}).then(P);return t.then.bind(t)}return g(e,[...r,n])},set(t,n,a){y(i);const[o,s]=m(a);return _(e,{type:"SET",path:[...r,n].map((e=>e.toString())),value:o},s).then(P)},apply(t,a,o){y(i);const s=r[r.length-1];if(s===n)return _(e,{type:"ENDPOINT"}).then(P);if("bind"===s)return g(e,r.slice(0,-1));const[c,u]=b(o);return _(e,{type:"APPLY",path:r.map((e=>e.toString())),argumentList:c},u).then(P)},construct(t,n){y(i);const[a,o]=b(n);return _(e,{type:"CONSTRUCT",path:r.map((e=>e.toString())),argumentList:a},o).then(P)}});return function(e,r){const t=(p.get(r)||0)+1;p.set(r,t),v&&v.register(e,r,e)}(o,e),o}function b(e){const r=e.map(m);return[r.map((e=>e[0])),(t=r.map((e=>e[1])),Array.prototype.concat.apply([],t))];var t}const w=new WeakMap;function m(e){for(const[r,t]of u)if(t.canHandle(e)){const[i,n]=t.serialize(e);return[{type:"HANDLER",name:r,value:i},n]}return[{type:"RAW",value:e},w.get(e)||[]]}function P(e){switch(e.type){case"HANDLER":return u.get(e.name).deserialize(e.value);case"RAW":return e.value}}function _(e,r,t){return new Promise((i=>{const n=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-");e.addEventListener("message",(function r(t){t.data&&t.data.id&&t.data.id===n&&(e.removeEventListener("message",r),i(t.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:n},r),t)}))}},495:(e,r,t)=>{t.a(e,(async(e,i)=>{try{t.r(r),t.d(r,{Account:()=>s,Address:()=>n.pV,AleoKeyProvider:()=>f,AleoKeyProviderParams:()=>l,AleoNetworkClient:()=>h,BlockHeightSearch:()=>v,CREDITS_PROGRAM_KEYS:()=>k,ExecutionResponse:()=>n.qp,Field:()=>n.D0,FunctionExecution:()=>n.Zc,KEY_STORE:()=>_,NetworkRecordProvider:()=>p,OfflineKeyProvider:()=>d,OfflineQuery:()=>n.c7,OfflineSearchParams:()=>y,PRIVATE_TO_PUBLIC_TRANSFER:()=>C,PRIVATE_TRANSFER:()=>S,PRIVATE_TRANSFER_TYPES:()=>E,PUBLIC_TO_PRIVATE_TRANSFER:()=>A,PUBLIC_TRANSFER:()=>B,PUBLIC_TRANSFER_AS_SIGNER:()=>R,PrivateKey:()=>n.ZD,PrivateKeyCiphertext:()=>n.LW,Program:()=>n.BP,ProgramManager:()=>w,ProgramManagerBase:()=>n.Ao,ProvingKey:()=>n.$7,RecordCiphertext:()=>n.KC,RecordPlaintext:()=>n.ZF,Signature:()=>n.to,Transaction:()=>n.ZX,VALID_TRANSFER_TYPES:()=>T,VerifyingKey:()=>n.pF,ViewKey:()=>n.hv,createAleoWorker:()=>b,initThreadPool:()=>n.Fs,initializeWasm:()=>V,logAndThrow:()=>F,verifyFunctionExecution:()=>n.Yc});var n=t(877),a=t(720),o=e([n]);n=(o.then?(await o)():o)[0];class s{_privateKey;_viewKey;_address;constructor(e={}){try{this._privateKey=this.privateKeyFromParams(e)}catch(e){throw console.error("Wrong parameter",e),new Error("Wrong Parameter")}this._viewKey=n.hv.from_private_key(this._privateKey),this._address=n.pV.from_private_key(this._privateKey)}static fromCiphertext(e,r){try{e="string"==typeof e?n.LW.fromString(e):e;const t=n.ZD.fromPrivateKeyCiphertext(e,r);return new s({privateKey:t.to_string()})}catch(e){throw new Error("Wrong password or invalid ciphertext")}}privateKeyFromParams(e){return e.seed?n.ZD.from_seed_unchecked(e.seed):e.privateKey?n.ZD.from_string(e.privateKey):new n.ZD}privateKey(){return this._privateKey}viewKey(){return this._viewKey}address(){return this._address}toString(){return this.address().to_string()}encryptAccount(e){return this._privateKey.toCiphertext(e)}decryptRecord(e){return this._viewKey.decrypt(e)}decryptRecords(e){return e.map((e=>this._viewKey.decrypt(e)))}ownsRecordCiphertext(e){if("string"!=typeof e)return e.isOwner(this._viewKey);try{return n.KC.fromString(e).isOwner(this._viewKey)}catch(e){return!1}}sign(e){return this._privateKey.sign(e)}verify(e,r){return this._address.verify(e,r)}}async function c(e,r){const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not get URL "+e);return t}async function u(e,r){r.method="POST";const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not post URL "+e);return t}class h{host;headers;account;constructor(e,r){this.host=e+"/testnet",r&&r.headers?this.headers=r.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const r=await c(this.host+e,{headers:this.headers});return await r.json()}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,r,t,i,a,o){if(o=o||[],e<0)throw new Error("Start height must be greater than or equal to 0");const s=new Array;let c,u,h,l,f=0,y=BigInt(0);if(void 0===t){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");h=this.account._privateKey}else try{h=t instanceof n.ZD?t:n.ZD.from_string(t)}catch(e){throw new Error("Error parsing private key provided.")}const d=h.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");l=e}catch(e){throw new Error("Error fetching latest block height.")}if(u="number"==typeof r&&r<=l?r:l,e>u)throw new Error("Start height must be less than or equal to end height.");for(;u>e;){c=u-50,c=BigInt(a))))return s;if(void 0!==i&&i.length>0){let e=0;if(r.microcredits()>i[e]){if(e+=1,s.push(r),"number"==typeof a&&(y+=r.microcredits(),y>=BigInt(a)))return s;if(s.length>=i.length)return s}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+c.toString()+"-"+u.toString()),console.warn("Error: ",e),f+=1,f>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),s}}return s}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,r){try{return await this.fetchData("/blocks?start="+e+"&end="+r)}catch(t){throw new Error("Error fetching blocks between "+e+" and "+r+".")}}async getDeploymentTransactionIDForProgram(e){e instanceof n.BP&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const r=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(r)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return await this.fetchData("/latest/height")}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return n.BP.fromString(e)}catch(r){try{return n.BP.fromString(await this.getProgram(e))}catch(r){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const r={},t=(e instanceof n.BP?e:await this.getProgramObject(e)).getImports();for(let e=0;e{if(void 0===e)t(new Error("No search parameters provided, cannot retrieve keys"));else{const i=e.cacheKey,a=e.verifyCreditsKeys;if(this.cache.has(i)){const[e,o]=this.cache.get(i),s=n.$7.fromBytes(e),c=n.pF.fromBytes(o);if(a){this.verifyCreditsKeys(i,s,c)||t(new Error(`Cached keys do not match expected keys for ${i}`))}r([s,c])}else t(new Error("Keys not found in cache for "+i))}}))}verifyCreditsKeys(e,r,t){switch(e){case k.bond_public.locator:return r.isBondPublicProver()&&t.isBondPublicVerifier();case k.claim_unbond_public.locator:return r.isClaimUnbondPublicProver()&&t.isClaimUnbondPublicVerifier();case k.fee_private.locator:return r.isFeePrivateProver()&&t.isFeePrivateVerifier();case k.fee_public.locator:return r.isFeePublicProver()&&t.isFeePublicVerifier();case k.inclusion.locator:return r.isInclusionProver()&&t.isInclusionVerifier();case k.join.locator:return r.isJoinProver()&&t.isJoinVerifier();case k.set_validator_state.locator:return r.isSetValidatorStateProver()&&t.isSetValidatorStateVerifier();case k.split.locator:return r.isSplitProver()&&t.isSplitVerifier();case k.transfer_private.locator:return r.isTransferPrivateProver()&&t.isTransferPrivateVerifier();case k.transfer_private_to_public.locator:return r.isTransferPrivateToPublicProver()&&t.isTransferPrivateToPublicVerifier();case k.transfer_public.locator:return r.isTransferPublicProver()&&t.isTransferPublicVerifier();case k.transfer_public_to_private.locator:return r.isTransferPublicToPrivateProver()&&t.isTransferPublicToPrivateVerifier();case k.unbond_public.locator:return r.isUnbondPublicProver()&&t.isUnbondPublicVerifier();default:return!1}}feePrivateKeys(){return this.functionKeys(y.feePrivateKeyParams())}feePublicKeys(){return this.functionKeys(y.feePublicKeyParams())}joinKeys(){return this.functionKeys(y.joinKeyParams())}splitKeys(){return this.functionKeys(y.splitKeyParams())}transferKeys(e){if(S.has(e))return this.functionKeys(y.transferPrivateKeyParams());if(C.has(e))return this.functionKeys(y.transferPrivateToPublicKeyParams());if(B.has(e))return this.functionKeys(y.transferPublicKeyParams());if(R.has(e))return this.functionKeys(y.transferPublicAsSignerKeyParams());if(A.has(e))return this.functionKeys(y.transferPublicToPrivateKeyParams());throw new Error("Invalid visibility type")}async unBondPublicKeys(){return this.functionKeys(y.unbondPublicKeyParams())}insertBondPublicKeys(e){if(!e.isBondPublicProver())throw new Error("Attempted to insert invalid proving keys for bond_public");this.cache.set(k.bond_public.locator,[e.toBytes(),n.pF.bondPublicVerifier().toBytes()])}insertClaimUnbondPublicKeys(e){if(!e.isClaimUnbondPublicProver())throw new Error("Attempted to insert invalid proving keys for claim_unbond_public");this.cache.set(k.claim_unbond_public.locator,[e.toBytes(),n.pF.claimUnbondPublicVerifier().toBytes()])}insertFeePrivateKeys(e){if(!e.isFeePrivateProver())throw new Error("Attempted to insert invalid proving keys for fee_private");this.cache.set(k.fee_private.locator,[e.toBytes(),n.pF.feePrivateVerifier().toBytes()])}insertFeePublicKeys(e){if(!e.isFeePublicProver())throw new Error("Attempted to insert invalid proving keys for fee_public");this.cache.set(k.fee_public.locator,[e.toBytes(),n.pF.feePublicVerifier().toBytes()])}insertJoinKeys(e){if(!e.isJoinProver())throw new Error("Attempted to insert invalid proving keys for join");this.cache.set(k.join.locator,[e.toBytes(),n.pF.joinVerifier().toBytes()])}insertSetValidatorStateKeys(e){if(!e.isSetValidatorStateProver())throw new Error("Attempted to insert invalid proving keys for set_validator_state");this.cache.set(k.set_validator_state.locator,[e.toBytes(),n.pF.setValidatorStateVerifier().toBytes()])}insertSplitKeys(e){if(!e.isSplitProver())throw new Error("Attempted to insert invalid proving keys for split");this.cache.set(k.split.locator,[e.toBytes(),n.pF.splitVerifier().toBytes()])}insertTransferPrivateKeys(e){if(!e.isTransferPrivateProver())throw new Error("Attempted to insert invalid proving keys for transfer_private");this.cache.set(k.transfer_private.locator,[e.toBytes(),n.pF.transferPrivateVerifier().toBytes()])}insertTransferPrivateToPublicKeys(e){if(!e.isTransferPrivateToPublicProver())throw new Error("Attempted to insert invalid proving keys for transfer_private_to_public");this.cache.set(k.transfer_private_to_public.locator,[e.toBytes(),n.pF.transferPrivateToPublicVerifier().toBytes()])}insertTransferPublicKeys(e){if(!e.isTransferPublicProver())throw new Error("Attempted to insert invalid proving keys for transfer_public");this.cache.set(k.transfer_public.locator,[e.toBytes(),n.pF.transferPublicVerifier().toBytes()])}insertTransferPublicToPrivateKeys(e){if(!e.isTransferPublicToPrivateProver())throw new Error("Attempted to insert invalid proving keys for transfer_public_to_private");this.cache.set(k.transfer_public_to_private.locator,[e.toBytes(),n.pF.transferPublicToPrivateVerifier().toBytes()])}insertUnbondPublicKeys(e){if(!e.isUnbondPublicProver())throw new Error("Attempted to insert invalid proving keys for unbond_public");this.cache.set(k.unbond_public.locator,[e.toBytes(),n.pF.unbondPublicVerifier().toBytes()])}}class p{account;networkClient;constructor(e,r){this.account=e,this.networkClient=r}setAccount(e){this.account=e}async findCreditsRecords(e,r,t,i){let n=0,a=0;if(i&&("startHeight"in i&&"number"==typeof i.endHeight&&(n=i.startHeight),"endHeight"in i&&"number"==typeof i.endHeight&&(a=i.endHeight)),0==a){const e=await this.networkClient.getLatestHeight();if(e instanceof Error)throw F("Unable to get current block height from the network");a=e}if(n>=a)throw F("Start height must be less than end height");return await this.networkClient.findUnspentRecords(n,a,this.account.privateKey(),e,void 0,t)}async findCreditsRecord(e,r,t,i){const n=await this.findCreditsRecords([e],r,t,i);return!(n instanceof Error)&&n.length>0?n[0]:(console.error("Record not found with error:",n),new Error("Record not found"))}async findRecord(e,r,t){throw new Error("Method not implemented.")}async findRecords(e,r,t){throw new Error("Method not implemented.")}}class v{startHeight;endHeight;constructor(e,r){this.startHeight=e,this.endHeight=r}}let g=null;const b=()=>{if(!g){const e=new Worker(new URL(t.p+t.u(587),t.b),{type:void 0});g=(0,a.LV)(e)}return g};class w{account;keyProvider;host;networkClient;recordProvider;constructor(e,r,t){this.host=e||"https://api.explorer.aleo.org/v1",this.networkClient=new h(this.host),this.keyProvider=r||new f,this.recordProvider=t}setAccount(e){this.account=e}setKeyProvider(e){this.keyProvider=e}setHost(e){this.host=e,this.networkClient.setHost(e)}setRecordProvider(e){this.recordProvider=e}async deploy(e,r,t,i,a,o){try{const r=n.BP.fromString(e);let t;try{t=await this.networkClient.getProgram(r.id())}catch(e){console.log(`Program ${r.id()} does not exist on the network, deploying...`)}if("string"==typeof t)throw`Program ${r.id()} already exists on the network, please rename your program`}catch(e){throw F(`Error validating program: ${e}`)}let s,c=o;if(void 0===o&&void 0!==this.account&&(c=this.account.privateKey()),void 0===c)throw"No private key provided and no private key set in the ProgramManager";try{a=t?await this.getCreditsRecord(r,[],a,i):void 0}catch(e){throw F(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{s=t?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys()}catch(e){throw F(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[u,h]=s;let l;try{l=await this.networkClient.getProgramImports(e)}catch(e){throw F(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}const f=await n.Ao.buildDeploymentTransaction(c,e,r,a,this.host,l,u,h);return await this.networkClient.submitTransaction(f)}async buildExecutionTransaction(e){const{programName:r,functionName:t,fee:i,privateFee:a,inputs:o,recordSearchParams:s,keySearchParams:c,privateKey:u,offlineQuery:h}=e;let l=e.feeRecord,f=e.provingKey,y=e.verifyingKey,d=e.program,p=e.imports;if(void 0===d)try{d=await this.networkClient.getProgram(r)}catch(e){throw F(`Error finding ${r}. Network response: '${e}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`)}else d instanceof n.BP&&(d=d.toString());let v,g=u;if(void 0===u&&void 0!==this.account&&(g=this.account.privateKey()),void 0===g)throw"No private key provided and no private key set in the ProgramManager";try{l=a?await this.getCreditsRecord(i,[],l,s):void 0}catch(e){throw F(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{v=a?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys()}catch(e){throw F(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[b,w]=v;if(!f||!y)try{[f,y]=await this.keyProvider.functionKeys(c)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}if(n.BP.fromString(d).getImports().length>0&&!p)try{p=await this.networkClient.getProgramImports(r)}catch(e){throw F(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await n.Ao.buildExecutionTransaction(g,d,t,o,i,l,this.host,p,f,y,b,w,h)}async execute(e){const r=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(r)}async run(e,r,t,i,a,o,s,c,u,h){let l=u;if(void 0===u&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";if(!s||!c)try{[s,c]=await this.keyProvider.functionKeys(o)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",s),console.log("Verifying key: ",c),n.Ao.executeFunctionOffline(l,e,r,t,i,!1,a,s,c,this.host,h)}async join(e,r,t,i,a,o,s,c){let u,h,l=s;if(void 0===s&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";try{u=i?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),h=await this.keyProvider.joinKeys()}catch(e){throw F(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[f,y]=u,[d,p]=h;try{o=i?await this.getCreditsRecord(t,[],o,a):void 0}catch(e){throw F(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof n.ZF?e:n.ZF.fromString(e),r=r instanceof n.ZF?r:n.ZF.fromString(r)}catch(e){throw F("Records provided are not valid. Please ensure they are valid plaintext records.")}const v=await n.Ao.buildJoinTransaction(l,e,r,t,o,this.host,d,p,f,y,c);return await this.networkClient.submitTransaction(v)}async split(e,r,t,i){let a,o=t;if(void 0===o&&void 0!==this.account&&(o=this.account.privateKey()),void 0===o)throw"No private key provided and no private key set in the ProgramManager";try{a=await this.keyProvider.splitKeys()}catch(e){throw F(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[s,c]=a;try{r=r instanceof n.ZF?r:n.ZF.fromString(r)}catch(e){throw F("Record provided is not valid. Please ensure it is a valid plaintext record.")}const u=await n.Ao.buildSplitTransaction(o,e,r,this.host,s,c,i);return await this.networkClient.submitTransaction(u)}async synthesizeKeys(e,r,t,i){let a,o=i;void 0===o&&(o=void 0!==this.account?this.account.privateKey():new n.ZD);try{a=await this.networkClient.getProgramImports(e);const i=await n.Ao.synthesizeKeyPair(o,e,r,t,a);return[i.provingKey(),i.verifyingKey()]}catch(e){throw F(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,r,t,i,a,o,s,c,u,h){t=P(t);let l,f,y=u;if(void 0===y&&void 0!==this.account&&(y=this.account.privateKey()),void 0===y)throw"No private key provided and no private key set in the ProgramManager";try{l=a?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),f=await this.keyProvider.transferKeys(t)}catch(e){throw F(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[d,p]=l,[v,g]=f;try{const e=[];m(t)?(s=await this.getCreditsRecord(i,[],s,o),e.push(s.nonce())):s=void 0,c=a?await this.getCreditsRecord(i,e,c,o):void 0}catch(e){throw F(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await n.Ao.buildTransferTransaction(y,e,r,t,s,i,c,this.host,v,g,d,p,h)}async buildTransferPublicTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async buildTransferPublicAsSignerTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async transfer(e,r,t,i,n,a,o,s,c,u){const h=await this.buildTransferTransaction(e,r,t,i,n,a,o,s,c,u);return await this.networkClient.submitTransaction(h)}async buildBondPublicTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*i),{programName:o="credits.aleo",functionName:s="bond_public",fee:c=n.fee||.86,privateFee:u=!1,inputs:h=[e,r,t,`${a.toString()}u64`],keySearchParams:f=new l({proverUri:k.bond_public.prover,verifierUri:k.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:y=this.creditsProgram(),...d}=n,p={programName:o,functionName:s,fee:c,privateFee:u,inputs:h,keySearchParams:f,...d};return await this.buildExecutionTransaction(p)}async bondPublic(e,r,t,i,n={}){const a=await this.buildBondPublicTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildBondValidatorTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*t),o=Math.trunc(i),{programName:s="credits.aleo",functionName:c="bond_validator",fee:u=n.fee||.86,privateFee:h=!1,inputs:f=[e,r,`${a.toString()}u64`,`${o.toString()}u8`],keySearchParams:y=new l({proverUri:k.bond_validator.prover,verifierUri:k.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:d=this.creditsProgram(),...p}=n,v={programName:s,functionName:c,fee:u,privateFee:h,inputs:f,keySearchParams:y,...p};return await this.buildExecutionTransaction(v)}async bondValidator(e,r,t,i,n={}){const a=await this.buildBondValidatorTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildUnbondPublicTransaction(e,r,t={}){const i=Math.trunc(1e6*r),{programName:n="credits.aleo",functionName:a="unbond_public",fee:o=t.fee||1.3,privateFee:s=!1,inputs:c=[e,`${i.toString()}u64`],keySearchParams:u=new l({proverUri:k.unbond_public.prover,verifierUri:k.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:h=this.creditsProgram(),...f}=t,y={programName:n,functionName:a,fee:o,privateFee:s,inputs:c,keySearchParams:u,...f};return this.buildExecutionTransaction(y)}async unbondPublic(e,r,t={}){const i=await this.buildUnbondPublicTransaction(e,r,t);return await this.networkClient.submitTransaction(i)}async buildClaimUnbondPublicTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="claim_unbond_public",fee:n=r.fee||2,privateFee:a=!1,inputs:o=[e],keySearchParams:s=new l({proverUri:k.claim_unbond_public.prover,verifierUri:k.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:c=this.creditsProgram(),...u}=r,h={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...u};return await this.buildExecutionTransaction(h)}async claimUnbondPublic(e,r={}){const t=await this.buildClaimUnbondPublicTransaction(e,r);return await this.networkClient.submitTransaction(t)}async buildSetValidatorStateTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="set_validator_state",fee:n=1,privateFee:a=!1,inputs:o=[e.toString()],keySearchParams:s=new l({proverUri:k.set_validator_state.prover,verifierUri:k.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...c}=r,u={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...c};return await this.execute(u)}async setValidatorState(e,r={}){const t=await this.buildSetValidatorStateTransaction(e,r);return this.networkClient.submitTransaction(t)}verifyExecution(e){try{const r=e.getExecution(),t=e.getFunctionId(),i=e.getProgram(),a=e.getVerifyingKey();return(0,n.Yc)(r,a,i,t)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return n.BP.fromString(e)}creditsProgram(){return n.BP.getCreditsProgram()}verifyProgram(e){try{return n.BP.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,r,t,i){try{return t instanceof n.ZF?t:n.ZF.fromString(t)}catch(t){try{const t=this.recordProvider;return await t.findCreditsRecord(e,!0,r,i)}catch(e){throw F(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function m(e){return E.has(e)}function P(e){return T.has(e)?e:F(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const _=n.OS.baseUrl();function K(e){const r=n.pF[e.verifyingKey];if(!r)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:r}}const k={bond_public:K(n.OS.bond_public()),bond_validator:K(n.OS.bond_validator()),claim_unbond_public:K(n.OS.claim_unbond_public()),fee_private:K(n.OS.fee_private()),fee_public:K(n.OS.fee_public()),inclusion:K(n.OS.inclusion()),join:K(n.OS.join()),set_validator_state:K(n.OS.set_validator_state()),split:K(n.OS.split()),transfer_private:K(n.OS.transfer_private()),transfer_private_to_public:K(n.OS.transfer_private_to_public()),transfer_public:K(n.OS.transfer_public()),transfer_public_as_signer:K(n.OS.transfer_public_as_signer()),transfer_public_to_private:K(n.OS.transfer_public_to_private()),unbond_public:K(n.OS.unbond_public()),getKey:function(e){return this.hasOwnProperty(e)?this[e]:new Error(`Key "${e}" not found.`)}},E=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),T=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),S=new Set(["private","transfer_private","transferPrivate"]),C=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),B=new Set(["public","transfer_public","transferPublic"]),R=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),A=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function F(e){throw console.error(e),e}async function V(){console.warn("initializeWasm is deprecated, you no longer need to use it")}i()}catch(U){i(U)}}))}}]); -//# sourceMappingURL=876.bundle.js.map \ No newline at end of file diff --git a/876.bundle.js.LICENSE.txt b/876.bundle.js.LICENSE.txt deleted file mode 100644 index 479a8e58b..000000000 --- a/876.bundle.js.LICENSE.txt +++ /dev/null @@ -1,5 +0,0 @@ -/** - * @license - * Copyright 2019 Google LLC - * SPDX-License-Identifier: Apache-2.0 - */ diff --git a/876.bundle.js.map b/876.bundle.js.map deleted file mode 100644 index 20b156d66..000000000 --- a/876.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"876.bundle.js","mappings":";mHAKA,MAAMA,EAAcC,OAAO,iBACrBC,EAAiBD,OAAO,oBACxBE,EAAeF,OAAO,wBACtBG,EAAYH,OAAO,qBACnBI,EAAcJ,OAAO,kBACrBK,EAAYC,GAAwB,iBAARA,GAA4B,OAARA,GAAgC,mBAARA,EAgDxEC,EAAmB,IAAIC,IAAI,CAC7B,CAAC,QA7CwB,CACzBC,UAAYH,GAAQD,EAASC,IAAQA,EAAIP,GACzC,SAAAW,CAAUC,GACN,MAAM,MAAEC,EAAK,MAAEC,GAAU,IAAIC,eAE7B,OADAC,EAAOJ,EAAKC,GACL,CAACC,EAAO,CAACA,GACpB,EACAG,YAAYC,IACRA,EAAKC,QACEC,EAAKF,MAqChB,CAAC,QA/BwB,CACzBR,UAAYW,GAAUf,EAASe,IA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,kBACA,4BACA,SACA,mBACA,iBACA,yBACA,6BACA,kBACA,iBACA,4BAEEtM,EAAmB,IAAIsM,IAAI,CAC7B,UACA,mBACA,oBAEEpM,EAA6B,IAAIoM,IAAI,CACvC,oBACA,kBACA,6BACA,4BAEElM,EAAkB,IAAIkM,IAAI,CAC5B,SACA,kBACA,mBAEEhM,EAA4B,IAAIgM,IAAI,CACtC,mBACA,4BACA,2BAEE9L,EAA6B,IAAI8L,IAAI,CACvC,oBACA,kBACA,6BACA,4BAGJ,SAASzQ,EAAY1N,GAEjB,MADAiB,QAAQ+B,MAAMhD,GACRA,CACV,CA+BAyI,eAAe2V,IACXnd,QAAQC,KAAK,6DACjB","sources":["webpack://aleo-website/../node_modules/comlink/dist/esm/comlink.mjs","webpack://aleo-website/../src/account.ts","webpack://aleo-website/../src/utils.ts","webpack://aleo-website/../src/network-client.ts","webpack://aleo-website/../src/function-key-provider.ts","webpack://aleo-website/../src/offline-key-provider.ts","webpack://aleo-website/../src/record-provider.ts","webpack://aleo-website/../src/managed-worker.ts","webpack://aleo-website/../src/program-manager.ts","webpack://aleo-website/../src/index.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nconst proxyMarker = Symbol(\"Comlink.proxy\");\nconst createEndpoint = Symbol(\"Comlink.endpoint\");\nconst releaseProxy = Symbol(\"Comlink.releaseProxy\");\nconst finalizer = Symbol(\"Comlink.finalizer\");\nconst throwMarker = Symbol(\"Comlink.thrown\");\nconst isObject = (val) => (typeof val === \"object\" && val !== null) || typeof val === \"function\";\n/**\n * Internal transfer handle to handle objects marked to proxy.\n */\nconst proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n};\n/**\n * Internal transfer handler to handle thrown exceptions.\n */\nconst throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n};\n/**\n * Allows customizing the serialization of certain values.\n */\nconst transferHandlers = new Map([\n [\"proxy\", proxyTransferHandler],\n [\"throw\", throwTransferHandler],\n]);\nfunction isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === \"*\") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n}\nfunction expose(obj, ep = globalThis, allowedOrigins = [\"*\"]) {\n ep.addEventListener(\"message\", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin '${ev.origin}' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case \"GET\" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case \"SET\" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case \"APPLY\" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case \"CONSTRUCT\" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case \"ENDPOINT\" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case \"RELEASE\" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === \"RELEASE\" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener(\"message\", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === \"function\") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError(\"Unserializable return value\"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n}\nfunction isMessagePort(endpoint) {\n return endpoint.constructor.name === \"MessagePort\";\n}\nfunction closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n}\nfunction wrap(ep, target) {\n return createProxy(ep, [], target);\n}\nfunction throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error(\"Proxy has been released and is not useable\");\n }\n}\nfunction releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: \"RELEASE\" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n}\nconst proxyCounter = new WeakMap();\nconst proxyFinalizers = \"FinalizationRegistry\" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\nfunction registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n}\nfunction unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n}\nfunction createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === \"then\") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: \"GET\" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: \"SET\" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: \"ENDPOINT\" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === \"bind\") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"APPLY\" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"CONSTRUCT\" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n}\nfunction myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n}\nfunction processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n}\nconst transferCache = new WeakMap();\nfunction transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n}\nfunction proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n}\nfunction windowEndpoint(w, context = globalThis, targetOrigin = \"*\") {\n return {\n postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\n addEventListener: context.addEventListener.bind(context),\n removeEventListener: context.removeEventListener.bind(context),\n };\n}\nfunction toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: \"HANDLER\" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: \"RAW\" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n}\nfunction fromWireValue(value) {\n switch (value.type) {\n case \"HANDLER\" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case \"RAW\" /* WireValueType.RAW */:\n return value.value;\n }\n}\nfunction requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener(\"message\", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener(\"message\", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n}\nfunction generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join(\"-\");\n}\n\nexport { createEndpoint, expose, finalizer, proxy, proxyMarker, releaseProxy, transfer, transferHandlers, windowEndpoint, wrap };\n//# sourceMappingURL=comlink.mjs.map\n","import {\n Address,\n PrivateKey,\n Signature,\n ViewKey,\n PrivateKeyCiphertext,\n RecordCiphertext,\n} from \"./index\";\n\ninterface AccountParam {\n privateKey?: string;\n seed?: Uint8Array;\n}\n\n/**\n * Key Management class. Enables the creation of a new Aleo Account, importation of an existing account from\n * an existing private key or seed, and message signing and verification functionality.\n *\n * An Aleo Account is generated from a randomly generated seed (number) from which an account private key, view key,\n * and a public account address are derived. The private key lies at the root of an Aleo account. It is a highly\n * sensitive secret and should be protected as it allows for creation of Aleo Program executions and arbitrary value\n * transfers. The View Key allows for decryption of a user's activity on the blockchain. The Address is the public\n * address to which other users of Aleo can send Aleo credits and other records to. This class should only be used\n * environments where the safety of the underlying key material can be assured.\n *\n * @example\n * // Create a new account\n * const myRandomAccount = new Account();\n *\n * // Create an account from a randomly generated seed\n * const seed = new Uint8Array([94, 91, 52, 251, 240, 230, 226, 35, 117, 253, 224, 210, 175, 13, 205, 120, 155, 214, 7, 169, 66, 62, 206, 50, 188, 40, 29, 122, 40, 250, 54, 18]);\n * const mySeededAccount = new Account({seed: seed});\n *\n * // Create an account from an existing private key\n * const myExistingAccount = new Account({privateKey: 'myExistingPrivateKey'})\n *\n * // Sign a message\n * const hello_world = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * const signature = myRandomAccount.sign(hello_world)\n *\n * // Verify a signature\n * myRandomAccount.verify(hello_world, signature)\n */\nexport class Account {\n _privateKey: PrivateKey;\n _viewKey: ViewKey;\n _address: Address;\n\n constructor(params: AccountParam = {}) {\n try {\n this._privateKey = this.privateKeyFromParams(params);\n } catch (e) {\n console.error(\"Wrong parameter\", e);\n throw new Error(\"Wrong Parameter\");\n }\n this._viewKey = ViewKey.from_private_key(this._privateKey);\n this._address = Address.from_private_key(this._privateKey);\n }\n\n /**\n * Attempts to create an account from a private key ciphertext\n * @param {PrivateKeyCiphertext | string} ciphertext\n * @param {string} password\n * @returns {PrivateKey | Error}\n *\n * @example\n * const ciphertext = PrivateKey.newEncrypted(\"password\");\n * const account = Account.fromCiphertext(ciphertext, \"password\");\n */\n public static fromCiphertext(ciphertext: PrivateKeyCiphertext | string, password: string) {\n try {\n ciphertext = (typeof ciphertext === \"string\") ? PrivateKeyCiphertext.fromString(ciphertext) : ciphertext;\n const _privateKey = PrivateKey.fromPrivateKeyCiphertext(ciphertext, password);\n return new Account({ privateKey: _privateKey.to_string() });\n } catch(e) {\n throw new Error(\"Wrong password or invalid ciphertext\");\n }\n }\n\n private privateKeyFromParams(params: AccountParam) {\n if (params.seed) {\n return PrivateKey.from_seed_unchecked(params.seed);\n }\n if (params.privateKey) {\n return PrivateKey.from_string(params.privateKey);\n }\n return new PrivateKey();\n }\n\n privateKey() {\n return this._privateKey;\n }\n\n viewKey() {\n return this._viewKey;\n }\n\n address() {\n return this._address;\n }\n\n toString() {\n return this.address().to_string()\n }\n\n /**\n * Encrypt the account's private key with a password\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n *\n * @example\n * const account = new Account();\n * const ciphertext = account.encryptAccount(\"password\");\n */\n encryptAccount(password: string) {\n return this._privateKey.toCiphertext(password);\n }\n\n /**\n * Decrypts a Record in ciphertext form into plaintext\n * @param {string} ciphertext\n * @returns {Record}\n *\n * @example\n * const account = new Account();\n * const record = account.decryptRecord(\"record1ciphertext\");\n */\n decryptRecord(ciphertext: string) {\n return this._viewKey.decrypt(ciphertext);\n }\n\n /**\n * Decrypts an array of Records in ciphertext form into plaintext\n * @param {string[]} ciphertexts\n * @returns {Record[]}\n *\n * @example\n * const account = new Account();\n * const record = account.decryptRecords([\"record1ciphertext\", \"record2ciphertext\"]);\n */\n decryptRecords(ciphertexts: string[]) {\n return ciphertexts.map((ciphertext) => this._viewKey.decrypt(ciphertext));\n }\n\n /**\n * Determines whether the account owns a ciphertext record\n * @param {RecordCipherText | string} ciphertext\n * @returns {boolean}\n *\n * @example\n * // Create a connection to the Aleo network and an account\n * const connection = new NodeConnection(\"vm.aleo.org/api\");\n * const account = Account.fromCiphertext(\"ciphertext\", \"password\");\n *\n * // Get a record from the network\n * const record = connection.getBlock(1234);\n * const recordCipherText = record.transactions[0].execution.transitions[0].id;\n *\n * // Check if the account owns the record\n * if account.ownsRecord(recordCipherText) {\n * // Then one can do something like:\n * // Decrypt the record and check if it's spent\n * // Store the record in a local database\n * // Etc.\n * }\n */\n ownsRecordCiphertext(ciphertext: RecordCiphertext | string) {\n if (typeof ciphertext === 'string') {\n try {\n const ciphertextObject = RecordCiphertext.fromString(ciphertext);\n return ciphertextObject.isOwner(this._viewKey);\n }\n catch (e) {\n return false;\n }\n }\n else {\n return ciphertext.isOwner(this._viewKey);\n }\n }\n\n /**\n * Signs a message with the account's private key.\n * Returns a Signature.\n *\n * @param {Uint8Array} message\n * @returns {Signature}\n *\n * @example\n * const account = new Account();\n * const message = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * account.sign(message);\n */\n sign(message: Uint8Array) {\n return this._privateKey.sign(message);\n }\n\n /**\n * Verifies the Signature on a message.\n *\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n *\n * @example\n * const account = new Account();\n * const message = Uint8Array.from([104, 101, 108, 108, 111 119, 111, 114, 108, 100])\n * const signature = account.sign(message);\n * account.verify(message, signature);\n */\n verify(message: Uint8Array, signature: Signature) {\n return this._address.verify(message, signature);\n }\n\n}\n","export async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./index\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/testnet\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/testnet\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n return await response.json();\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise | Error> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n if (!(blocks instanceof Error)) {\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = \"Error fetching blocks between \" + start + \" and \" + end + \".\"\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return await this.fetchData(\"/latest/height\");\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error) {\n throw logAndThrow(\"Error fetching program imports: \" + error)\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error) {\n throw new Error(\"Error fetching program imports with error: \" + error);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise | Error> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise | Error> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string | Error} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n return await response.json();\n\n } catch (error) {\n throw new Error(`Error posting transaction. Aleo network response: ${(error as Error).message}`);\n }\n } catch (error) {\n throw new Error(`Error posting transaction: No response received: ${(error as Error).message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./index\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error) {\n throw new Error(\"Error fetching data.\" + error);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair | Error} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair | Error {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n return new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n if (!(key instanceof Error)) {\n return this.fetchCreditsKeys(key);\n }\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error) {\n throw new Error(`Error: fetching credits.aleo keys: ${error}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner) {\n return new Error(\"Invalid verifying key. Error: \" + inner);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n FunctionKeyProvider,\n KeySearchParams,\n FunctionKeyPair,\n CachedKeyPair,\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./index\";\n\n/**\n * Search parameters for the offline key provider. This class implements the KeySearchParams interface and includes\n * a convenience method for creating a new instance of this class for each function of the credits.aleo program.\n *\n * @example\n * // If storing a key for a custom program function\n * offlineSearchParams = new OfflineSearchParams(\"myprogram.aleo/myfunction\");\n *\n * // If storing a key for a credits.aleo program function\n * bondPublicKeyParams = OfflineSearchParams.bondPublicKeyParams();\n */\nclass OfflineSearchParams implements KeySearchParams {\n cacheKey: string | undefined;\n verifyCreditsKeys: boolean | undefined;\n\n /**\n * Create a new OfflineSearchParams instance.\n *\n * @param {string} cacheKey - Key used to store the local function proving & verifying keys. This should be stored\n * under the naming convention \"programName/functionName\" (i.e. \"myprogram.aleo/myfunction\")\n * @param {boolean} verifyCreditsKeys - Whether to verify the keys against the credits.aleo program,\n * defaults to false, but should be set to true if using keys from the credits.aleo program\n */\n constructor(cacheKey: string, verifyCreditsKeys = false) {\n this.cacheKey = cacheKey;\n this.verifyCreditsKeys = verifyCreditsKeys;\n }\n\n /**\n * Create a new OfflineSearchParams instance for the bond_public function of the credits.aleo program.\n */\n static bondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.bond_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the bond_validator function of the credits.aleo program.\n */\n static bondValidatorKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.bond_validator.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the claim_unbond_public function of the\n */\n static claimUnbondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.claim_unbond_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the fee_private function of the credits.aleo program.\n */\n static feePrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.fee_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the fee_public function of the credits.aleo program.\n */\n static feePublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.fee_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the inclusion prover function.\n */\n static inclusionKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.inclusion.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the join function of the credits.aleo program.\n */\n static joinKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.join.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the set_validator_state function of the credits.aleo program.\n */\n static setValidatorStateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.set_validator_state.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the split function of the credits.aleo program.\n */\n static splitKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.split.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_private function of the credits.aleo program.\n */\n static transferPrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_private_to_public function of the credits.aleo program.\n */\n static transferPrivateToPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public function of the credits.aleo program.\n */\n static transferPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public_as_signer function of the credits.aleo program.\n */\n static transferPublicAsSignerKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public_as_signer.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the transfer_public_to_private function of the credits.aleo program.\n */\n static transferPublicToPrivateKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator, true);\n }\n\n /**\n * Create a new OfflineSearchParams instance for the unbond_public function of the credits.aleo program.\n */\n static unbondPublicKeyParams(): OfflineSearchParams {\n return new OfflineSearchParams(CREDITS_PROGRAM_KEYS.unbond_public.locator, true);\n }\n}\n\n/**\n * A key provider meant for building transactions offline on devices such as hardware wallets. This key provider is not\n * able to contact the internet for key material and instead relies on the user to insert Aleo function proving &\n * verifying keys from local storage prior to usage.\n *\n * @example\n * // Create an offline program manager\n * const programManager = new ProgramManager();\n *\n * // Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * // Create the proving keys from the key bytes on the offline machine\n * console.log(\"Creating proving keys from local key files\");\n * const program = \"program hello_hello.aleo; function hello: input r0 as u32.public; input r1 as u32.private; add r0 r1 into r2; output r2 as u32.private;\";\n * const myFunctionProver = await getLocalKey(\"/path/to/my/function/hello_hello.prover\");\n * const myFunctionVerifier = await getLocalKey(\"/path/to/my/function/hello_hello.verifier\");\n * const feePublicProvingKeyBytes = await getLocalKey(\"/path/to/credits.aleo/feePublic.prover\");\n *\n * myFunctionProvingKey = ProvingKey.fromBytes(myFunctionProver);\n * myFunctionVerifyingKey = VerifyingKey.fromBytes(myFunctionVerifier);\n * const feePublicProvingKey = ProvingKey.fromBytes(feePublicKeyBytes);\n *\n * // Create an offline key provider\n * console.log(\"Creating offline key provider\");\n * const offlineKeyProvider = new OfflineKeyProvider();\n *\n * // Cache the keys\n * // Cache the proving and verifying keys for the custom hello function\n * OfflineKeyProvider.cacheKeys(\"hello_hello.aleo/hello\", myFunctionProvingKey, myFunctionVerifyingKey);\n *\n * // Cache the proving key for the fee_public function (the verifying key is automatically cached)\n * OfflineKeyProvider.insertFeePublicKey(feePublicProvingKey);\n *\n * // Create an offline query using the latest state root in order to create the inclusion proof\n * const offlineQuery = new OfflineQuery(\"latestStateRoot\");\n *\n * // Insert the key provider into the program manager\n * programManager.setKeyProvider(offlineKeyProvider);\n *\n * // Create the offline search params\n * const offlineSearchParams = new OfflineSearchParams(\"hello_hello.aleo/hello\");\n *\n * // Create the offline transaction\n * const offlineExecuteTx = await this.buildExecutionTransaction(\"hello_hello.aleo\", \"hello\", 1, false, [\"5u32\", \"5u32\"], undefined, offlineSearchParams, undefined, undefined, undefined, undefined, offlineQuery, program);\n *\n * // Broadcast the transaction later on a machine with internet access\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const txId = await networkClient.broadcastTransaction(offlineExecuteTx);\n */\nclass OfflineKeyProvider implements FunctionKeyProvider {\n cache: Map;\n\n constructor() {\n this.cache = new Map();\n }\n\n /**\n * Get bond_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.bondPublicKeyParams());\n };\n\n /**\n * Get bond_validator function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondValidatorKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.bondValidatorKeyParams());\n };\n\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n };\n\n /**\n * Get unbond_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.claimUnbondPublicKeyParams());\n };\n\n /**\n * Get arbitrary function key from the offline key provider cache.\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * /// First cache the keys from local offline resources\n * const offlineKeyProvider = new OfflineKeyProvider();\n * const myFunctionVerifyingKey = VerifyingKey.fromString(\"verifier...\");\n * const myFunctionProvingKeyBytes = await readBinaryFile('./resources/myfunction.prover');\n * const myFunctionProvingKey = ProvingKey.fromBytes(myFunctionProvingKeyBytes);\n *\n * /// Cache the keys for future use with a memorable locator\n * offlineKeyProvider.cacheKeys(\"myprogram.aleo/myfunction\", [myFunctionProvingKey, myFunctionVerifyingKey]);\n *\n * /// When they're needed, retrieve the keys from the cache\n *\n * /// First create a search parameter object with the same locator used to cache the keys\n * const keyParams = new OfflineSearchParams(\"myprogram.aleo/myfunction\");\n *\n * /// Then retrieve the keys\n * const [myFunctionProver, myFunctionVerifier] = await offlineKeyProvider.functionKeys(keyParams);\n */\n functionKeys(params?: KeySearchParams): Promise {\n return new Promise((resolve, reject) => {\n if (params === undefined) {\n reject(new Error(\"No search parameters provided, cannot retrieve keys\"));\n } else {\n const keyId = params.cacheKey;\n const verifyCreditsKeys = params.verifyCreditsKeys;\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId) as CachedKeyPair;\n const provingKey = ProvingKey.fromBytes(provingKeyBytes);\n const verifyingKey = VerifyingKey.fromBytes(verifyingKeyBytes);\n if (verifyCreditsKeys) {\n const keysMatchExpected = this.verifyCreditsKeys(keyId, provingKey, verifyingKey)\n if (!keysMatchExpected) {\n reject (new Error(`Cached keys do not match expected keys for ${keyId}`));\n }\n }\n resolve([provingKey, verifyingKey]);\n } else {\n reject(new Error(\"Keys not found in cache for \" + keyId));\n }\n }\n });\n };\n\n /**\n * Determines if the keys for a given credits function match the expected keys.\n *\n * @returns {boolean} Whether the keys match the expected keys\n */\n verifyCreditsKeys(locator: string, provingKey: ProvingKey, verifyingKey: VerifyingKey): boolean {\n switch (locator) {\n case CREDITS_PROGRAM_KEYS.bond_public.locator:\n return provingKey.isBondPublicProver() && verifyingKey.isBondPublicVerifier();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.locator:\n return provingKey.isClaimUnbondPublicProver() && verifyingKey.isClaimUnbondPublicVerifier();\n case CREDITS_PROGRAM_KEYS.fee_private.locator:\n return provingKey.isFeePrivateProver() && verifyingKey.isFeePrivateVerifier();\n case CREDITS_PROGRAM_KEYS.fee_public.locator:\n return provingKey.isFeePublicProver() && verifyingKey.isFeePublicVerifier();\n case CREDITS_PROGRAM_KEYS.inclusion.locator:\n return provingKey.isInclusionProver() && verifyingKey.isInclusionVerifier();\n case CREDITS_PROGRAM_KEYS.join.locator:\n return provingKey.isJoinProver() && verifyingKey.isJoinVerifier();\n case CREDITS_PROGRAM_KEYS.set_validator_state.locator:\n return provingKey.isSetValidatorStateProver() && verifyingKey.isSetValidatorStateVerifier();\n case CREDITS_PROGRAM_KEYS.split.locator:\n return provingKey.isSplitProver() && verifyingKey.isSplitVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_private.locator:\n return provingKey.isTransferPrivateProver() && verifyingKey.isTransferPrivateVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator:\n return provingKey.isTransferPrivateToPublicProver() && verifyingKey.isTransferPrivateToPublicVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_public.locator:\n return provingKey.isTransferPublicProver() && verifyingKey.isTransferPublicVerifier();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator:\n return provingKey.isTransferPublicToPrivateProver() && verifyingKey.isTransferPublicToPrivateVerifier();\n case CREDITS_PROGRAM_KEYS.unbond_public.locator:\n return provingKey.isUnbondPublicProver() && verifyingKey.isUnbondPublicVerifier();\n default:\n return false;\n }\n }\n\n /**\n * Get fee_private function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.feePrivateKeyParams());\n };\n\n /**\n * Get fee_public function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.feePublicKeyParams());\n };\n\n /**\n * Get join function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.joinKeyParams());\n };\n\n /**\n * Get split function keys from the credits.aleo program. The keys must be cached prior to calling this\n * method for it to work.\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.splitKeyParams());\n };\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program.\n *\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new OfflineKeyProvider\n * const offlineKeyProvider = new OfflineKeyProvider();\n *\n * // Cache the keys for future use with the official locator\n * const transferPublicProvingKeyBytes = await readBinaryFile('./resources/transfer_public.prover.a74565e');\n * const transferPublicProvingKey = ProvingKey.fromBytes(transferPublicProvingKeyBytes);\n *\n * // Cache the transfer_public keys for future use with the OfflinKeyProvider's convenience method for\n * // transfer_public (the verifying key will be cached automatically)\n * offlineKeyProvider.insertTransferPublicKeys(transferPublicProvingKey);\n *\n * /// When they're needed, retrieve the keys from the cache\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPrivateKeyParams());\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPrivateToPublicKeyParams());\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicKeyParams());\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicAsSignerKeyParams());\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return this.functionKeys(OfflineSearchParams.transferPublicToPrivateKeyParams());\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n };\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async unBondPublicKeys(): Promise {\n return this.functionKeys(OfflineSearchParams.unbondPublicKeyParams());\n };\n\n /**\n * Insert the proving and verifying keys for the bond_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for bond_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertBondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isBondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [provingKey.toBytes(), VerifyingKey.bondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for bond_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the claim_unbond_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for claim_unbond_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertClaimUnbondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isClaimUnbondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.claim_unbond_public.locator, [provingKey.toBytes(), VerifyingKey.claimUnbondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for claim_unbond_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the fee_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for fee_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertFeePrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isFeePrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.fee_private.locator, [provingKey.toBytes(), VerifyingKey.feePrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for fee_private\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the fee_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for fee_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertFeePublicKeys(provingKey: ProvingKey) {\n if (provingKey.isFeePublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.fee_public.locator, [provingKey.toBytes(), VerifyingKey.feePublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for fee_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the join function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for join before inserting them into the cache.\n *\n * @param provingKey\n */\n insertJoinKeys(provingKey: ProvingKey) {\n if (provingKey.isJoinProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.join.locator, [provingKey.toBytes(), VerifyingKey.joinVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for join\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the set_validator_state function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for set_validator_state before inserting them into the cache.\n *\n * @param provingKey\n */\n insertSetValidatorStateKeys(provingKey: ProvingKey) {\n if (provingKey.isSetValidatorStateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.set_validator_state.locator, [provingKey.toBytes(), VerifyingKey.setValidatorStateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for set_validator_state\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the split function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for split before inserting them into the cache.\n *\n * @param provingKey\n */\n insertSplitKeys(provingKey: ProvingKey) {\n if (provingKey.isSplitProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.split.locator, [provingKey.toBytes(), VerifyingKey.splitVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for split\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_private.locator, [provingKey.toBytes(), VerifyingKey.transferPrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_private\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_private_to_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_private_to_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPrivateToPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPrivateToPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_private_to_public.locator, [provingKey.toBytes(), VerifyingKey.transferPrivateToPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_private_to_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_public function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_public before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_public.locator, [provingKey.toBytes(), VerifyingKey.transferPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_public\");\n }\n }\n\n /**\n * Insert the proving and verifying keys for the transfer_public_to_private function into the cache. Only the proving key needs\n * to be inserted, the verifying key is automatically inserted by the SDK. This function will automatically check\n * that the keys match the expected checksum for transfer_public_to_private before inserting them into the cache.\n *\n * @param provingKey\n */\n insertTransferPublicToPrivateKeys(provingKey: ProvingKey) {\n if (provingKey.isTransferPublicToPrivateProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.transfer_public_to_private.locator, [provingKey.toBytes(), VerifyingKey.transferPublicToPrivateVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for transfer_public_to_private\");\n }\n }\n\n insertUnbondPublicKeys(provingKey: ProvingKey) {\n if (provingKey.isUnbondPublicProver()) {\n this.cache.set(CREDITS_PROGRAM_KEYS.unbond_public.locator, [provingKey.toBytes(), VerifyingKey.unbondPublicVerifier().toBytes()]);\n } else {\n throw new Error(\"Attempted to insert invalid proving keys for unbond_public\");\n }\n }\n}\n\n\nexport {OfflineKeyProvider, OfflineSearchParams}\n","import { logAndThrow, RecordPlaintext } from \"./index\";\nimport { Account } from \"./account\";\nimport { AleoNetworkClient } from \"./network-client\";\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface RecordSearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * Interface for a record provider. A record provider is used to find records for use in deployment and execution\n * transactions on the Aleo Network. A default implementation is provided by the NetworkRecordProvider class. However,\n * a custom implementation can be provided (say if records are synced locally to a database from the network) by\n * implementing this interface.\n */\ninterface RecordProvider {\n account: Account\n\n /**\n * Find a credits.aleo record with a given number of microcredits from the chosen provider\n *\n * @param {number} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // A class implementing record provider can be used to find a record with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, its nonce should be added to the nonces array so that it is not\n * // found again if a subsequent search is performed\n * const record2 = await recordProvider.findCreditsRecord(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n findCreditsRecord(microcredits: number, unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find a list of credit.aleo records with a given number of microcredits from the chosen provider\n *\n * @param {number} microcreditAmounts A list of separate microcredit amounts to search for (e.g. [5000, 100000])\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} A list of records with a value greater or equal to the amounts specified if such records exist, otherwise an error\n *\n * @example\n * // A class implementing record provider can be used to find a record with a given number of microcredits\n * const records = await recordProvider.findCreditsRecords([5000, 5000], true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces array so that it is not\n * // found again if a subsequent search is performed\n * const nonces = [];\n * records.forEach(record => { nonces.push(record.nonce()) });\n * const records2 = await recordProvider.findCreditsRecord(5000, true, nonces);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n findCreditsRecords(microcreditAmounts: number[], unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find an arbitrary record\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // The RecordSearchParams interface can be used to create parameters for custom record searches which can then\n * // be passed to the record provider. An example of how this would be done for the credits.aleo program is shown\n * // below.\n *\n * class CustomRecordSearch implements RecordSearchParams {\n * startHeight: number;\n * endHeight: number;\n * amount: number;\n * program: string;\n * recordName: string;\n * constructor(startHeight: number, endHeight: number, credits: number, maxRecords: number, programName: string, recordName: string) {\n * this.startHeight = startHeight;\n * this.endHeight = endHeight;\n * this.amount = amount;\n * this.program = programName;\n * this.recordName = recordName;\n * }\n * }\n *\n * const params = new CustomRecordSearch(0, 100, 5000, \"credits.aleo\", \"credits\");\n *\n * const record = await recordProvider.findRecord(true, [], params);\n */\n findRecord(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n\n /**\n * Find multiple records from arbitrary programs\n *\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * // The RecordSearchParams interface can be used to create parameters for custom record searches which can then\n * // be passed to the record provider. An example of how this would be done for the credits.aleo program is shown\n * // below.\n *\n * class CustomRecordSearch implements RecordSearchParams {\n * startHeight: number;\n * endHeight: number;\n * amount: number;\n * maxRecords: number;\n * programName: string;\n * recordName: string;\n * constructor(startHeight: number, endHeight: number, credits: number, maxRecords: number, programName: string, recordName: string) {\n * this.startHeight = startHeight;\n * this.endHeight = endHeight;\n * this.amount = amount;\n * this.maxRecords = maxRecords;\n * this.programName = programName;\n * this.recordName = recordName;\n * }\n * }\n *\n * const params = new CustomRecordSearch(0, 100, 5000, 2, \"credits.aleo\", \"credits\");\n * const records = await recordProvider.findRecord(true, [], params);\n */\n findRecords(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise;\n}\n\n/**\n * A record provider implementation that uses the official Aleo API to find records for usage in program execution and\n * deployment, wallet functionality, and other use cases.\n */\nclass NetworkRecordProvider implements RecordProvider {\n account: Account;\n networkClient: AleoNetworkClient;\n constructor(account: Account, networkClient: AleoNetworkClient) {\n this.account = account;\n this.networkClient = networkClient;\n }\n\n /**\n * Set the account used to search for records\n *\n * @param {Account} account The account to use for searching for records\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Find a list of credit records with a given number of microcredits by via the official Aleo API\n *\n * @param {number[]} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces parameter so that it is not\n * // found again if a subsequent search is performed\n * const records = await recordProvider.findCreditsRecords(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * */\n async findCreditsRecords(microcredits: number[], unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n let startHeight = 0;\n let endHeight = 0;\n\n if (searchParameters) {\n if (\"startHeight\" in searchParameters && typeof searchParameters[\"endHeight\"] == \"number\") {\n startHeight = searchParameters[\"startHeight\"];\n }\n\n if (\"endHeight\" in searchParameters && typeof searchParameters[\"endHeight\"] == \"number\") {\n endHeight = searchParameters[\"endHeight\"];\n }\n }\n\n // If the end height is not specified, use the current block height\n if (endHeight == 0) {\n const end = await this.networkClient.getLatestHeight();\n if (end instanceof Error) {\n throw logAndThrow(\"Unable to get current block height from the network\")\n }\n endHeight = end;\n }\n\n // If the start height is greater than the end height, throw an error\n if (startHeight >= endHeight) {\n throw logAndThrow(\"Start height must be less than end height\");\n }\n\n return await this.networkClient.findUnspentRecords(startHeight, endHeight, this.account.privateKey(), microcredits, undefined, nonces);\n }\n\n /**\n * Find a credit record with a given number of microcredits by via the official Aleo API\n *\n * @param {number} microcredits The number of microcredits to search for\n * @param {boolean} unspent Whether or not the record is unspent\n * @param {string[]} nonces Nonces of records already found so that they are not found again\n * @param {RecordSearchParams} searchParameters Additional parameters to search for\n * @returns {Promise} The record if found, otherwise an error\n *\n * @example\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits\n * const record = await recordProvider.findCreditsRecord(5000, true, []);\n *\n * // When a record is found but not yet used, it's nonce should be added to the nonces parameter so that it is not\n * // found again if a subsequent search is performed\n * const records = await recordProvider.findCreditsRecords(5000, true, [record.nonce()]);\n *\n * // When the program manager is initialized with the record provider it will be used to find automatically find\n * // fee records and amount records for value transfers so that they do not need to be specified manually\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n */\n async findCreditsRecord(microcredits: number, unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n const records = await this.findCreditsRecords([microcredits], unspent, nonces, searchParameters);\n if (!(records instanceof Error) && records.length > 0) {\n return records[0];\n }\n console.error(\"Record not found with error:\", records);\n return new Error(\"Record not found\");\n }\n\n /**\n * Find an arbitrary record. WARNING: This function is not implemented yet and will throw an error.\n */\n async findRecord(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n throw new Error(\"Method not implemented.\");\n }\n\n /**\n * Find multiple arbitrary records. WARNING: This function is not implemented yet and will throw an error.\n */\n async findRecords(unspent: boolean, nonces?: string[], searchParameters?: RecordSearchParams): Promise {\n throw new Error(\"Method not implemented.\");\n }\n\n}\n\n/**\n * BlockHeightSearch is a RecordSearchParams implementation that allows for searching for records within a given\n * block height range.\n *\n * @example\n * // Create a new BlockHeightSearch\n * const params = new BlockHeightSearch(89995, 99995);\n *\n * // Create a new NetworkRecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // The record provider can be used to find records with a given number of microcredits and the block height search\n * // can be used to find records within a given block height range\n * const record = await recordProvider.findCreditsRecord(5000, true, [], params);\n *\n */\nclass BlockHeightSearch implements RecordSearchParams {\n startHeight: number;\n endHeight: number;\n constructor(startHeight: number, endHeight: number) {\n this.startHeight = startHeight;\n this.endHeight = endHeight;\n }\n}\n\nexport { BlockHeightSearch, NetworkRecordProvider, RecordProvider, RecordSearchParams};\n","// Experimental example where SDK manages worker\n\nimport { wrap } from \"comlink\";\nimport { WorkerAPI } from './worker';\n\nlet singletonWorker: WorkerAPI | null = null;\n\nconst createAleoWorker = (): WorkerAPI => {\n if (!singletonWorker) {\n const worker = new Worker(new URL(\"worker.js\", import.meta.url), {\n type: \"module\",\n });\n singletonWorker = wrap(worker);\n }\n return singletonWorker;\n};\n\nexport { createAleoWorker };","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./index\";\nimport {Execution} from \"@provablehq/wasm/dist/crates/aleo_wasm\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.aleo.org/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n \n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string | Error} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e) {\n throw logAndThrow(`Error validating program: ${e}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e) {\n throw logAndThrow(`Error finding ${programName}. Network response: '${e}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e) {\n throw logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e) {\n throw logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e) {\n throw logAndThrow(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program | Error} The program object\n */\n createProgramFromSource(program: string): Program | Error {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string | Error {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import {VerifyingKey, Metadata} from \"@provablehq/wasm\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key | Error {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n return new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): Error {\n console.error(message);\n throw message;\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n"],"names":["proxyMarker","Symbol","createEndpoint","releaseProxy","finalizer","throwMarker","isObject","val","transferHandlers","Map","canHandle","serialize","obj","port1","port2","MessageChannel","expose","deserialize","port","start","wrap","value","serialized","Error","isError","message","name","stack","Object","assign","ep","globalThis","allowedOrigins","addEventListener","callback","ev","data","origin","allowedOrigin","RegExp","test","isAllowedOrigin","console","warn","id","type","path","argumentList","map","fromWireValue","returnValue","parent","slice","reduce","prop","rawValue","apply","proxy","transfers","transferCache","set","transfer","undefined","Promise","resolve","catch","then","wireValue","transferables","toWireValue","postMessage","removeEventListener","closeEndPoint","error","TypeError","endpoint","constructor","isMessagePort","close","target","createProxy","throwIfProxyReleased","isReleased","releaseEndpoint","requestResponseMessage","proxyCounter","WeakMap","proxyFinalizers","FinalizationRegistry","newCount","get","isProxyReleased","Proxy","_target","unregister","unregisterProxy","length","r","p","toString","bind","_thisArg","rawArgumentList","last","processArguments","construct","register","registerProxy","processed","v","arr","Array","prototype","concat","handler","serializedValue","msg","fill","Math","floor","random","Number","MAX_SAFE_INTEGER","join","l","Account","_privateKey","_viewKey","_address","params","this","privateKeyFromParams","e","ViewKey","from_private_key","Address","fromCiphertext","ciphertext","password","PrivateKeyCiphertext","fromString","PrivateKey","fromPrivateKeyCiphertext","privateKey","to_string","seed","from_seed_unchecked","from_string","viewKey","address","encryptAccount","toCiphertext","decryptRecord","decrypt","decryptRecords","ciphertexts","ownsRecordCiphertext","isOwner","RecordCiphertext","sign","verify","signature","async","url","options","response","fetch","ok","status","post","method","AleoNetworkClient","host","headers","account","setAccount","getAccount","setHost","fetchData","json","findUnspentRecords","startHeight","endHeight","amounts","maxMicrocredits","nonces","records","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","BigInt","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","transactions","j","confirmedTransaction","transaction","execution","transitions","k","transition","program","outputs","output","record","recordPlaintext","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","key","logAndThrow","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","AleoKeyProviderParams","proverUri","verifierUri","cacheKey","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","arrayBuffer","Uint8Array","KEY_STORE","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","text","inner","unBondPublicKeys","OfflineSearchParams","verifyCreditsKeys","bondPublicKeyParams","bondValidatorKeyParams","claimUnbondPublicKeyParams","feePrivateKeyParams","feePublicKeyParams","inclusionKeyParams","joinKeyParams","setValidatorStateKeyParams","splitKeyParams","transferPrivateKeyParams","transferPrivateToPublicKeyParams","transferPublicKeyParams","transferPublicAsSignerKeyParams","transferPublicToPrivateKeyParams","unbondPublicKeyParams","OfflineKeyProvider","reject","isBondPublicProver","isBondPublicVerifier","isClaimUnbondPublicProver","isClaimUnbondPublicVerifier","isFeePrivateProver","isFeePrivateVerifier","isFeePublicProver","isFeePublicVerifier","isInclusionProver","isInclusionVerifier","isJoinProver","isJoinVerifier","isSetValidatorStateProver","isSetValidatorStateVerifier","isSplitProver","isSplitVerifier","isTransferPrivateProver","isTransferPrivateVerifier","isTransferPrivateToPublicProver","isTransferPrivateToPublicVerifier","isTransferPublicProver","isTransferPublicVerifier","isTransferPublicToPrivateProver","isTransferPublicToPrivateVerifier","isUnbondPublicProver","isUnbondPublicVerifier","insertBondPublicKeys","bondPublicVerifier","insertClaimUnbondPublicKeys","claimUnbondPublicVerifier","insertFeePrivateKeys","feePrivateVerifier","insertFeePublicKeys","feePublicVerifier","insertJoinKeys","joinVerifier","insertSetValidatorStateKeys","setValidatorStateVerifier","insertSplitKeys","splitVerifier","insertTransferPrivateKeys","transferPrivateVerifier","insertTransferPrivateToPublicKeys","transferPrivateToPublicVerifier","insertTransferPublicKeys","transferPublicVerifier","insertTransferPublicToPrivateKeys","transferPublicToPrivateVerifier","insertUnbondPublicKeys","unbondPublicVerifier","NetworkRecordProvider","networkClient","findCreditsRecords","unspent","searchParameters","findCreditsRecord","findRecord","findRecords","BlockHeightSearch","singletonWorker","createAleoWorker","worker","Worker","URL","ProgramManager","keyProvider","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set","initializeWasm"],"sourceRoot":""} \ No newline at end of file diff --git a/877.bundle.js b/877.bundle.js deleted file mode 100644 index 8d1e8d5f2..000000000 --- a/877.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[877,258],{81:(_,t,e)=>{_.exports=e.p+"58342153fc9a001d7976.wasm"},977:(_,t,e)=>{_.exports=e.p+"2d6a4d794221941c07b8.js"},877:(_,t,e)=>{e.a(_,(async(_,r)=>{try{function i(_,t,e,r){return new Promise((n=>{const i=new Worker(_,{type:"module"});i.addEventListener("message",(_=>{setTimeout((()=>{n(i),i.unref&&i.unref()}),0)}),{capture:!0,once:!0}),i.postMessage({module:t,memory:e,address:r})}))}let o;e.d(t,{$7:()=>B_,Ao:()=>q_,BP:()=>M_,Fs:()=>L_,KC:()=>U_,OS:()=>O_,Yc:()=>J_,ZD:()=>C_,ZF:()=>I_,ZX:()=>$_,pF:()=>D_});const a=new Array(128).fill(void 0);function s(_){return a[_]}a.push(void 0,null,!0,!1);let c=a.length;function g(_){_<132||(a[_]=c,c=_)}function w(_){const t=s(_);return g(_),t}const d="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&d.decode();let b=null;function l(){return null!==b&&b.buffer===o.memory.buffer||(b=new Uint8Array(o.memory.buffer)),b}function u(_,t){return _>>>=0,d.decode(l().slice(_,_+t))}function f(_){c===a.length&&a.push(a.length+1);const t=c;return c=a[t],a[t]=_,t}let p=0;const y="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},m=function(_,t){const e=y.encode(_);return t.set(e),{read:_.length,written:e.length}};function h(_,t,e){if(void 0===e){const e=y.encode(_),r=t(e.length,1)>>>0;return l().subarray(r,r+e.length).set(e),p=e.length,r}let r=_.length,n=t(r,1)>>>0;const i=l();let o=0;for(;o127)break;i[n+o]=t}if(o!==r){0!==o&&(_=_.slice(o)),n=e(n,r,r=o+3*_.length,1)>>>0;const t=l().subarray(n+o,n+r);o+=m(_,t).written,n=e(n,r,o,1)>>>0}return p=o,n}function v(_){return null==_}let k=null;function P(){return null!==k&&k.buffer===o.memory.buffer||(k=new Int32Array(o.memory.buffer)),k}function S(_){const t=typeof _;if("number"==t||"boolean"==t||null==_)return`${_}`;if("string"==t)return`"${_}"`;if("symbol"==t){const t=_.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=_.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(_)){const t=_.length;let e="[";t>0&&(e+=S(_[0]));for(let r=1;r1))return toString.call(_);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(_)+")"}catch(_){return"Object"}return _ instanceof Error?`${_.name}: ${_.message}\n${_.stack}`:r}const x="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>{o.__wbindgen_export_3.get(_.dtor)(_.a,_.b)}));function V(_,t,e,r){const n={a:_,b:t,cnt:1,dtor:e},i=(..._)=>{n.cnt++;const t=n.a;n.a=0;try{return r(t,n.b,..._)}finally{0==--n.cnt?(o.__wbindgen_export_3.get(n.dtor)(t,n.b),x.unregister(n)):n.a=t}};return i.original=n,x.register(i,n,n),i}function F(_,t,e){o._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(_,t,f(e))}function T(_,t){if(!(_ instanceof t))throw new Error(`expected instance of ${t.name}`);return _.ptr}function R(_,t){const e=t(1*_.length,1)>>>0;return l().set(_,e/1),p=_.length,e}function z(_,t,e,r){try{const a=o.__wbindgen_add_to_stack_pointer(-16);T(_,q),T(t,p_),T(e,r_);const s=h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.verifyFunctionExecution(a,_.__wbg_ptr,t.__wbg_ptr,e.__wbg_ptr,s,c);var n=P()[a/4+0],i=P()[a/4+1];if(P()[a/4+2])throw w(i);return 0!==n}finally{o.__wbindgen_add_to_stack_pointer(16)}}let A=null;function O(){return null!==A&&A.buffer===o.memory.buffer||(A=new BigInt64Array(o.memory.buffer)),A}function j(_,t){return _>>>=0,l().subarray(_/1,_/1+t)}function K(_){o.runRayonThread(_)}function C(_,t){return w(o.initThreadPool(f(_),t))}function E(_,t){try{return _.apply(this,t)}catch(_){o.__wbindgen_exn_store(f(_))}}function M(_,t,e,r){o.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(_,t,f(e),f(r))}const B="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_address_free(_>>>0)));let U=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,B.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,B.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_address_free(_)}static from_private_key(t){T(t,G);const e=o.address_from_private_key(t.__wbg_ptr);return _.__wrap(e)}static from_view_key(t){T(t,m_);const e=o.address_from_view_key(t.__wbg_ptr);return _.__wrap(e)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.address_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.address_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}verify(_,t){const e=R(_,o.__wbindgen_malloc),r=p;T(t,b_);return 0!==o.address_verify(this.__wbg_ptr,e,r,t.__wbg_ptr)}};const I="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_execution_free(_>>>0)));let q=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,I.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,I.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_execution_free(_)}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.execution_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.execution_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const W="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_executionresponse_free(_>>>0)));let $=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,W.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,W.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_executionresponse_free(_)}getOutputs(){return w(o.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const _=o.executionresponse_getExecution(this.__wbg_ptr);return 0===_?void 0:q.__wrap(_)}getKeys(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.executionresponse_getKeys(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return L.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const _=o.executionresponse_getProvingKey(this.__wbg_ptr);return 0===_?void 0:a_.__wrap(_)}getVerifyingKey(){const _=o.executionresponse_getVerifyingKey(this.__wbg_ptr);return p_.__wrap(_)}getFunctionId(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.executionresponse_getFunctionId(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}getProgram(){const _=o.executionresponse_getProgram(this.__wbg_ptr);return r_.__wrap(_)}};const N="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_field_free(_>>>0)));let D=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,N.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,N.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_field_free(_)}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.field_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.field_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const J="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_keypair_free(_>>>0)));class L{static __wrap(_){_>>>=0;const t=Object.create(L.prototype);return t.__wbg_ptr=_,J.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,J.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_keypair_free(_)}constructor(_,t){T(_,a_);var e=_.__destroy_into_raw();T(t,p_);var r=t.__destroy_into_raw();const n=o.keypair_new(e,r);return this.__wbg_ptr=n>>>0,this}provingKey(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.keypair_provingKey(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return a_.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.keypair_verifyingKey(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return p_.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}}const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_metadata_free(_>>>0)));let Z=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,H.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_metadata_free(_)}get name(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_name(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set name(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_name(this.__wbg_ptr,t,e)}get locator(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_locator(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set locator(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_locator(this.__wbg_ptr,t,e)}get prover(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_prover(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set prover(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_prover(this.__wbg_ptr,t,e)}get verifier(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_verifier(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set verifier(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_verifier(this.__wbg_ptr,t,e)}get verifyingKey(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_verifyingKey(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set verifyingKey(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,t,e)}static baseUrl(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.metadata_baseUrl(n);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static bond_public(){const t=o.metadata_bond_public();return _.__wrap(t)}static bond_validator(){const t=o.metadata_bond_validator();return _.__wrap(t)}static claim_unbond_public(){const t=o.metadata_claim_unbond_public();return _.__wrap(t)}static fee_private(){const t=o.metadata_fee_private();return _.__wrap(t)}static fee_public(){const t=o.metadata_fee_public();return _.__wrap(t)}static inclusion(){const t=o.metadata_inclusion();return _.__wrap(t)}static join(){const t=o.metadata_join();return _.__wrap(t)}static set_validator_state(){const t=o.metadata_set_validator_state();return _.__wrap(t)}static split(){const t=o.metadata_split();return _.__wrap(t)}static transfer_private(){const t=o.metadata_transfer_private();return _.__wrap(t)}static transfer_private_to_public(){const t=o.metadata_transfer_private_to_public();return _.__wrap(t)}static transfer_public(){const t=o.metadata_transfer_public();return _.__wrap(t)}static transfer_public_as_signer(){const t=o.metadata_transfer_public_as_signer();return _.__wrap(t)}static transfer_public_to_private(){const t=o.metadata_transfer_public_to_private();return _.__wrap(t)}static unbond_public(){const t=o.metadata_unbond_public();return _.__wrap(t)}};const Q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_offlinequery_free(_>>>0)));let X=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,Q.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Q.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_offlinequery_free(_)}constructor(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.offlinequery_new(r,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return this.__wbg_ptr=t>>>0,this}finally{o.__wbindgen_add_to_stack_pointer(16)}}addStatePath(_,t){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p,a=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.offlinequery_addStatePath(r,this.__wbg_ptr,n,i,a,s);var e=P()[r/4+0];if(P()[r/4+1])throw w(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.offlinequery_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.offlinequery_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const Y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_privatekey_free(_>>>0)));let G=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,Y.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Y.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_privatekey_free(_)}constructor(){const _=o.privatekey_new();return this.__wbg_ptr=_>>>0,this}static from_seed_unchecked(t){const e=R(t,o.__wbindgen_malloc),r=p,n=o.privatekey_from_seed_unchecked(e,r);return _.__wrap(n)}static from_string(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.privatekey_from_string(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.privatekey_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}to_view_key(){const _=o.privatekey_to_view_key(this.__wbg_ptr);return m_.__wrap(_)}to_address(){const _=o.privatekey_to_address(this.__wbg_ptr);return U.__wrap(_)}sign(_){const t=R(_,o.__wbindgen_malloc),e=p,r=o.privatekey_sign(this.__wbg_ptr,t,e);return b_.__wrap(r)}static newEncrypted(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekey_newEncrypted(r,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return t_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekey_toCiphertext(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return t_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,e){try{const i=o.__wbindgen_add_to_stack_pointer(-16);T(t,t_);const a=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.privatekey_fromPrivateKeyCiphertext(i,t.__wbg_ptr,a,s);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw w(n);return _.__wrap(r)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const __="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_privatekeyciphertext_free(_>>>0)));let t_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,__.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,__.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_privatekeyciphertext_free(_)}static encryptPrivateKey(t,e){try{const i=o.__wbindgen_add_to_stack_pointer(-16);T(t,G);const a=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.privatekey_toCiphertext(i,t.__wbg_ptr,a,s);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw w(n);return _.__wrap(r)}finally{o.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekeyciphertext_decryptToPrivateKey(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return G.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.privatekeyciphertext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.privatekeyciphertext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const e_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_program_free(_>>>0)));let r_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,e_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,e_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_program_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.program_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.program_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}hasFunction(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;return 0!==o.program_hasFunction(this.__wbg_ptr,t,e)}getFunctions(){return w(o.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getFunctionInputs(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.program_getMappings(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return w(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getRecordMembers(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getStructMembers(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=o.program_getCreditsProgram();return _.__wrap(t)}id(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.program_id(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}address(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.program_address(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return U.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){T(t,_);return 0!==o.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return w(o.program_getImports(this.__wbg_ptr))}};const n_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_programmanager_free(_>>>0)));let i_=class{__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,n_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_programmanager_free(_)}static buildDeploymentTransaction(_,t,e,r,n,i,a,s,c){T(_,G);const g=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),d=p;let b=0;v(r)||(T(r,w_),b=r.__destroy_into_raw());var l=v(n)?0:h(n,o.__wbindgen_malloc,o.__wbindgen_realloc),u=p;let y=0;v(a)||(T(a,a_),y=a.__destroy_into_raw());let m=0;v(s)||(T(s,p_),m=s.__destroy_into_raw());let k=0;v(c)||(T(c,X),k=c.__destroy_into_raw());return w(o.programmanager_buildDeploymentTransaction(_.__wbg_ptr,g,d,e,b,l,u,v(i)?0:f(i),y,m,k))}static estimateDeploymentFee(_,t){const e=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;return w(o.programmanager_estimateDeploymentFee(e,r,v(t)?0:f(t)))}static estimateProgramNameCost(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.programmanager_estimateProgramNameCost(r,n,i);var t=O()[r/8+0],e=P()[r/4+2];if(P()[r/4+3])throw w(e);return BigInt.asUintN(64,t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(_,t,e,r,n,i,a,s,c,g,d){T(_,G);const b=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),l=p,u=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(s)||(T(s,a_),m=s.__destroy_into_raw());let k=0;v(c)||(T(c,p_),k=c.__destroy_into_raw());var P=v(g)?0:h(g,o.__wbindgen_malloc,o.__wbindgen_realloc),S=p;let x=0;v(d)||(T(d,X),x=d.__destroy_into_raw());return w(o.programmanager_executeFunctionOffline(_.__wbg_ptr,b,l,u,y,f(r),n,i,v(a)?0:f(a),m,k,P,S,x))}static buildExecutionTransaction(_,t,e,r,n,i,a,s,c,g,d,b,l){T(_,G);const u=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p,m=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),k=p;let P=0;v(i)||(T(i,w_),P=i.__destroy_into_raw());var S=v(a)?0:h(a,o.__wbindgen_malloc,o.__wbindgen_realloc),x=p;let V=0;v(c)||(T(c,a_),V=c.__destroy_into_raw());let F=0;v(g)||(T(g,p_),F=g.__destroy_into_raw());let R=0;v(d)||(T(d,a_),R=d.__destroy_into_raw());let z=0;v(b)||(T(b,p_),z=b.__destroy_into_raw());let A=0;v(l)||(T(l,X),A=l.__destroy_into_raw());return w(o.programmanager_buildExecutionTransaction(_.__wbg_ptr,u,y,m,k,f(r),n,P,S,x,v(s)?0:f(s),V,F,R,z,A))}static estimateExecutionFee(_,t,e,r,n,i,a,s,c){T(_,G);const g=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),d=p,b=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),l=p;var u=v(n)?0:h(n,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(a)||(T(a,a_),m=a.__destroy_into_raw());let k=0;v(s)||(T(s,p_),k=s.__destroy_into_raw());let P=0;v(c)||(T(c,X),P=c.__destroy_into_raw());return w(o.programmanager_estimateExecutionFee(_.__wbg_ptr,g,d,b,l,f(r),u,y,v(i)?0:f(i),m,k,P))}static estimateFinalizeFee(_,t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.programmanager_estimateFinalizeFee(n,i,a,s,c);var e=O()[n/8+0],r=P()[n/4+2];if(P()[n/4+3])throw w(r);return BigInt.asUintN(64,e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(_,t,e,r,n,i,a,s,c,g,d){T(_,G),T(t,w_);var b=t.__destroy_into_raw();T(e,w_);var l=e.__destroy_into_raw();let u=0;v(n)||(T(n,w_),u=n.__destroy_into_raw());var f=v(i)?0:h(i,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(a)||(T(a,a_),m=a.__destroy_into_raw());let k=0;v(s)||(T(s,p_),k=s.__destroy_into_raw());let P=0;v(c)||(T(c,a_),P=c.__destroy_into_raw());let S=0;v(g)||(T(g,p_),S=g.__destroy_into_raw());let x=0;v(d)||(T(d,X),x=d.__destroy_into_raw());return w(o.programmanager_buildJoinTransaction(_.__wbg_ptr,b,l,r,u,f,y,m,k,P,S,x))}static buildSplitTransaction(_,t,e,r,n,i,a){T(_,G),T(e,w_);var s=e.__destroy_into_raw(),c=v(r)?0:h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),g=p;let d=0;v(n)||(T(n,a_),d=n.__destroy_into_raw());let b=0;v(i)||(T(i,p_),b=i.__destroy_into_raw());let l=0;v(a)||(T(a,X),l=a.__destroy_into_raw());return w(o.programmanager_buildSplitTransaction(_.__wbg_ptr,t,s,c,g,d,b,l))}static buildTransferTransaction(_,t,e,r,n,i,a,s,c,g,d,b,l){T(_,G);const u=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),f=p,y=h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),m=p;let k=0;v(n)||(T(n,w_),k=n.__destroy_into_raw());let P=0;v(a)||(T(a,w_),P=a.__destroy_into_raw());var S=v(s)?0:h(s,o.__wbindgen_malloc,o.__wbindgen_realloc),x=p;let V=0;v(c)||(T(c,a_),V=c.__destroy_into_raw());let F=0;v(g)||(T(g,p_),F=g.__destroy_into_raw());let R=0;v(d)||(T(d,a_),R=d.__destroy_into_raw());let z=0;v(b)||(T(b,p_),z=b.__destroy_into_raw());let A=0;v(l)||(T(l,X),A=l.__destroy_into_raw());return w(o.programmanager_buildTransferTransaction(_.__wbg_ptr,t,u,f,y,m,k,i,P,S,x,V,F,R,z,A))}static synthesizeKeyPair(_,t,e,r,n){T(_,G);const i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;return w(o.programmanager_synthesizeKeyPair(_.__wbg_ptr,i,a,s,c,f(r),v(n)?0:f(n)))}};const o_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_provingkey_free(_>>>0)));let a_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,o_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,o_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_provingkey_free(_)}isBondPublicProver(){return 0!==o.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==o.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==o.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==o.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==o.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==o.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==o.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==o.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==o.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==o.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==o.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==o.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==o.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==o.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==o.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_checksum(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}copy(){const t=o.provingkey_copy(this.__wbg_ptr);return _.__wrap(t)}static fromBytes(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=R(t,o.__wbindgen_malloc),a=p;o.provingkey_fromBytes(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.provingkey_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_toBytes(n,this.__wbg_ptr);var _=P()[n/4+0],t=P()[n/4+1],e=P()[n/4+2];if(P()[n/4+3])throw w(e);var r=j(_,t).slice();return o.__wbindgen_free(_,1*t,1),r}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const s_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_recordciphertext_free(_>>>0)));let c_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,s_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,s_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_recordciphertext_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.recordciphertext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordciphertext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}decrypt(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16);T(_,m_),o.recordciphertext_decrypt(r,this.__wbg_ptr,_.__wbg_ptr);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}isOwner(_){T(_,m_);return 0!==o.recordciphertext_isOwner(this.__wbg_ptr,_.__wbg_ptr)}};const g_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_recordplaintext_free(_>>>0)));let w_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,g_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,g_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_recordplaintext_free(_)}commitment(_,t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.recordplaintext_commitment(n,this.__wbg_ptr,i,a,s,c);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return D.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.recordplaintext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordplaintext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}microcredits(){const _=o.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,_)}nonce(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordplaintext_nonce(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}serialNumberString(_,t,e){let r,n;try{const b=o.__wbindgen_add_to_stack_pointer(-16);T(_,G);const l=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),f=p,y=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),m=p;o.recordplaintext_serialNumberString(b,this.__wbg_ptr,_.__wbg_ptr,l,f,y,m);var i=P()[b/4+0],a=P()[b/4+1],s=P()[b/4+2],c=P()[b/4+3],g=i,d=a;if(c)throw g=0,d=0,w(s);return r=g,n=d,u(g,d)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(r,n,1)}}};const d_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_signature_free(_>>>0)));let b_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,d_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,d_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_signature_free(_)}static sign(t,e){T(t,G);const r=R(e,o.__wbindgen_malloc),n=p,i=o.privatekey_sign(t.__wbg_ptr,r,n);return _.__wrap(i)}verify(_,t){T(_,U);const e=R(t,o.__wbindgen_malloc),r=p;return 0!==o.signature_verify(this.__wbg_ptr,_.__wbg_ptr,e,r)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.signature_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.signature_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const l_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_transaction_free(_>>>0)));let u_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,l_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,l_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_transaction_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.transaction_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}transactionId(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_transactionId(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}transactionType(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_transactionType(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const f_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_verifyingkey_free(_>>>0)));let p_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,f_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,f_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_verifyingkey_free(_)}static bondPublicVerifier(){const t=o.verifyingkey_bondPublicVerifier();return _.__wrap(t)}static bondValidatorVerifier(){const t=o.verifyingkey_bondValidatorVerifier();return _.__wrap(t)}static claimUnbondPublicVerifier(){const t=o.verifyingkey_claimUnbondPublicVerifier();return _.__wrap(t)}static feePrivateVerifier(){const t=o.verifyingkey_feePrivateVerifier();return _.__wrap(t)}static feePublicVerifier(){const t=o.verifyingkey_feePublicVerifier();return _.__wrap(t)}static inclusionVerifier(){const t=o.verifyingkey_inclusionVerifier();return _.__wrap(t)}static joinVerifier(){const t=o.verifyingkey_joinVerifier();return _.__wrap(t)}static setValidatorStateVerifier(){const t=o.verifyingkey_setValidatorStateVerifier();return _.__wrap(t)}static splitVerifier(){const t=o.verifyingkey_splitVerifier();return _.__wrap(t)}static transferPrivateVerifier(){const t=o.verifyingkey_transferPrivateVerifier();return _.__wrap(t)}static transferPrivateToPublicVerifier(){const t=o.verifyingkey_transferPrivateToPublicVerifier();return _.__wrap(t)}static transferPublicVerifier(){const t=o.verifyingkey_transferPublicVerifier();return _.__wrap(t)}static transferPublicAsSignerVerifier(){const t=o.verifyingkey_transferPublicAsSignerVerifier();return _.__wrap(t)}static transferPublicToPrivateVerifier(){const t=o.verifyingkey_transferPublicToPrivateVerifier();return _.__wrap(t)}static unbondPublicVerifier(){const t=o.verifyingkey_unbondPublicVerifier();return _.__wrap(t)}isBondPublicVerifier(){return 0!==o.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==o.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==o.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==o.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==o.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==o.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==o.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==o.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==o.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==o.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==o.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==o.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==o.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==o.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==o.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_checksum(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}copy(){const t=o.verifyingkey_copy(this.__wbg_ptr);return _.__wrap(t)}static fromBytes(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=R(t,o.__wbindgen_malloc),a=p;o.verifyingkey_fromBytes(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.verifyingkey_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_toBytes(n,this.__wbg_ptr);var _=P()[n/4+0],t=P()[n/4+1],e=P()[n/4+2];if(P()[n/4+3])throw w(e);var r=j(_,t).slice();return o.__wbindgen_free(_,1*t,1),r}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const y_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_viewkey_free(_>>>0)));let m_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,y_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,y_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_viewkey_free(_)}static from_private_key(t){T(t,G);const e=o.privatekey_to_view_key(t.__wbg_ptr);return _.__wrap(e)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.viewkey_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.viewkey_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}to_address(){const _=o.address_from_view_key(this.__wbg_ptr);return U.__wrap(_)}decrypt(_){let t,e;try{const g=o.__wbindgen_add_to_stack_pointer(-16),d=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),b=p;o.viewkey_decrypt(g,this.__wbg_ptr,d,b);var r=P()[g/4+0],n=P()[g/4+1],i=P()[g/4+2],a=P()[g/4+3],s=r,c=n;if(a)throw s=0,c=0,w(i);return t=s,e=c,u(s,c)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(t,e,1)}}};async function h_(_,t){if("function"==typeof Response&&_ instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(_,t)}catch(t){if("application/wasm"==_.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await _.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(_,t);return e instanceof WebAssembly.Instance?{instance:e,module:_}:e}}function v_(){const _={wbg:{}};return _.wbg.__wbindgen_object_drop_ref=function(_){w(_)},_.wbg.__wbg_new_71801a555ad9f2aa=function(){return E((function(){return f(new XMLHttpRequest)}),arguments)},_.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return E((function(_,t,e){s(_).overrideMimeType(u(t,e))}),arguments)},_.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return E((function(_,t,e,r,n,i){s(_).open(u(t,e),u(r,n),0!==i)}),arguments)},_.wbg.__wbg_send_80d29985093c1ec5=function(){return E((function(_){s(_).send()}),arguments)},_.wbg.__wbg_response_7c2e2759084f7279=function(){return E((function(_){return f(s(_).response)}),arguments)},_.wbg.__wbg_status_d485fb5a478426fb=function(){return E((function(_){return s(_).status}),arguments)},_.wbg.__wbg_new_72fb9a18b5ae2624=function(){return f(new Object)},_.wbg.__wbindgen_string_new=function(_,t){return f(u(_,t))},_.wbg.__wbg_set_1f9b04f170055d33=function(){return E((function(_,t,e){return Reflect.set(s(_),s(t),s(e))}),arguments)},_.wbg.__wbg_new_ab6fd82b10560829=function(){return E((function(){return f(new Headers)}),arguments)},_.wbg.__wbindgen_object_clone_ref=function(_){return f(s(_))},_.wbg.__wbg_new_0d76b0581eca6298=function(){return E((function(){return f(new AbortController)}),arguments)},_.wbg.__wbg_signal_a61f78a3478fd9bc=function(_){return f(s(_).signal)},_.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return E((function(_,t,e,r,n){s(_).append(u(t,e),u(r,n))}),arguments)},_.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(_){let t;try{t=s(_)instanceof Response}catch(_){t=!1}return t},_.wbg.__wbg_status_61a01141acd3cf74=function(_){return s(_).status},_.wbg.__wbg_url_5f6dc4009ac5f99d=function(_,t){const e=h(s(t).url,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbg_headers_9620bfada380764a=function(_){return f(s(_).headers)},_.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return f(Symbol.iterator)},_.wbg.__wbg_get_e3c254076557e348=function(){return E((function(_,t){return f(Reflect.get(s(_),s(t)))}),arguments)},_.wbg.__wbindgen_is_function=function(_){return"function"==typeof s(_)},_.wbg.__wbg_call_27c0f87801dedf93=function(){return E((function(_,t){return f(s(_).call(s(t)))}),arguments)},_.wbg.__wbindgen_is_object=function(_){const t=s(_);return"object"==typeof t&&null!==t},_.wbg.__wbg_next_40fc327bfc8770e6=function(_){return f(s(_).next)},_.wbg.__wbg_next_196c84450b364254=function(){return E((function(_){return f(s(_).next())}),arguments)},_.wbg.__wbg_done_298b57d23c0fc80c=function(_){return s(_).done},_.wbg.__wbg_value_d93c65011f51a456=function(_){return f(s(_).value)},_.wbg.__wbg_abort_2aa7521d5690750e=function(_){s(_).abort()},_.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return E((function(_){return f(JSON.stringify(s(_)))}),arguments)},_.wbg.__wbindgen_string_get=function(_,t){const e=s(t),r="string"==typeof e?e:void 0;var n=v(r)?0:h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;P()[_/4+1]=i,P()[_/4+0]=n},_.wbg.__wbg_log_0159ca40cddf5b15=function(_,t){console.log(u(_,t))},_.wbg.__wbindgen_bigint_from_u64=function(_){return f(BigInt.asUintN(64,_))},_.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return E((function(_,t,e){return f(s(_).call(s(t),s(e)))}),arguments)},_.wbg.__wbg_transaction_new=function(_){return f(u_.__wrap(_))},_.wbg.__wbg_keypair_new=function(_){return f(L.__wrap(_))},_.wbg.__wbindgen_module=function(){return f(x_.__wbindgen_wasm_module)},_.wbg.__wbindgen_memory=function(){return f(o.memory)},_.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a=function(_,t,e,r){return f(i(s(_),s(t),s(e),r>>>0))},_.wbg.__wbg_executionresponse_new=function(_){return f($.__wrap(_))},_.wbg.__wbg_newwithlength_66ae46612e7f0234=function(_){return f(new Array(_>>>0))},_.wbg.__wbg_set_d4638f722068f043=function(_,t,e){s(_)[t>>>0]=w(e)},_.wbg.__wbindgen_cb_drop=function(_){const t=w(_).original;if(1==t.cnt--)return t.a=0,!0;return!1},_.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return f(new Array)},_.wbg.__wbg_push_a5b05aedc7234f9f=function(_,t){return s(_).push(s(t))},_.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return E((function(_){return f(s(_).arrayBuffer())}),arguments)},_.wbg.__wbg_new_63b92bc8671ed464=function(_){return f(new Uint8Array(s(_)))},_.wbg.__wbg_length_c20a40f15020d68a=function(_){return s(_).length},_.wbg.__wbg_new_81740750da40724f=function(_,t){try{var e={a:_,b:t};const r=new Promise(((_,t)=>{const r=e.a;e.a=0;try{return M(r,e.b,_,t)}finally{e.a=r}}));return f(r)}finally{e.a=e.b=0}},_.wbg.__wbindgen_number_new=function(_){return f(_)},_.wbg.__wbg_new_abda76e883ba8a5f=function(){return f(new Error)},_.wbg.__wbg_stack_658279fe44541cf6=function(_,t){const e=h(s(t).stack,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbg_error_f851667af71bcfc6=function(_,t){let e,r;try{e=_,r=t,console.error(u(_,t))}finally{o.__wbindgen_free(e,r,1)}},_.wbg.__wbg_buffer_12d079cc21e14bdb=function(_){return f(s(_).buffer)},_.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(_,t,e){return f(new Uint8Array(s(_),t>>>0,e>>>0))},_.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return E((function(_,t){s(_).randomFillSync(w(t))}),arguments)},_.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(_,t,e){return f(s(_).subarray(t>>>0,e>>>0))},_.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return E((function(_,t){s(_).getRandomValues(s(t))}),arguments)},_.wbg.__wbg_set_a47bac70306a19a7=function(_,t,e){s(_).set(s(t),e>>>0)},_.wbg.__wbg_crypto_1d1f22824a6a080c=function(_){return f(s(_).crypto)},_.wbg.__wbg_process_4a72847cc503995b=function(_){return f(s(_).process)},_.wbg.__wbg_versions_f686565e586dd935=function(_){return f(s(_).versions)},_.wbg.__wbg_node_104a2ff8d6ea03a2=function(_){return f(s(_).node)},_.wbg.__wbindgen_is_string=function(_){return"string"==typeof s(_)},_.wbg.__wbg_require_cca90b1a94a0255b=function(){return E((function(){return f(module.require)}),arguments)},_.wbg.__wbg_msCrypto_eb05e62b530a1508=function(_){return f(s(_).msCrypto)},_.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(_){return f(new Uint8Array(_>>>0))},_.wbg.__wbg_length_cd7af8117672b8b8=function(_){return s(_).length},_.wbg.__wbg_get_bd8e338fbd5f5cc8=function(_,t){return f(s(_)[t>>>0])},_.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return E((function(){return f(self.self)}),arguments)},_.wbg.__wbg_window_c6fb939a7f436783=function(){return E((function(){return f(window.window)}),arguments)},_.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return E((function(){return f(globalThis.globalThis)}),arguments)},_.wbg.__wbg_global_207b558942527489=function(){return E((function(){return f(global.global)}),arguments)},_.wbg.__wbindgen_is_undefined=function(_){return void 0===s(_)},_.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(_,t){return f(new Function(u(_,t)))},_.wbg.__wbg_has_0af94d20077affa2=function(){return E((function(_,t){return Reflect.has(s(_),s(t))}),arguments)},_.wbg.__wbg_fetch_bc7c8e27076a5c84=function(_){return f(fetch(s(_)))},_.wbg.__wbg_fetch_921fad6ef9e883dd=function(_,t){return f(s(_).fetch(s(t)))},_.wbg.__wbindgen_debug_string=function(_,t){const e=h(S(s(t)),o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbindgen_throw=function(_,t){throw new Error(u(_,t))},_.wbg.__wbindgen_rethrow=function(_){throw w(_)},_.wbg.__wbg_then_a73caa9a87991566=function(_,t,e){return f(s(_).then(s(t),s(e)))},_.wbg.__wbg_then_0c86a60e8fcfe9f6=function(_,t){return f(s(_).then(s(t)))},_.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(_){queueMicrotask(s(_))},_.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(_){return f(s(_).queueMicrotask)},_.wbg.__wbg_resolve_b0083a7967828ec8=function(_){return f(Promise.resolve(s(_)))},_.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return f(Atomics.waitAsync)},_.wbg.__wbg_new_8cccba86b0f574cb=function(_){return f(new Int32Array(s(_)))},_.wbg.__wbg_waitAsync_46d5c36955b71a79=function(_,t,e){return f(Atomics.waitAsync(s(_),t,e))},_.wbg.__wbg_async_19c0400d97cc72fe=function(_){return s(_).async},_.wbg.__wbg_value_571d60108110e917=function(_){return f(s(_).value)},_.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(_){const t=h("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;P()[_/4+1]=e,P()[_/4+0]=t},_.wbg.__wbg_new_d1187ae36d662ef9=function(){return E((function(_,t){return f(new Worker(u(_,t)))}),arguments)},_.wbg.__wbg_setonmessage_503809e5bb51bd33=function(_,t){s(_).onmessage=s(t)},_.wbg.__wbg_of_6a70eed8d41f469c=function(_,t,e){return f(Array.of(s(_),s(t),s(e)))},_.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return E((function(_,t){s(_).postMessage(s(t))}),arguments)},_.wbg.__wbg_data_3ce7c145ca4fbcdc=function(_){return f(s(_).data)},_.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return E((function(_,t,e){return f(new Request(u(_,t),s(e)))}),arguments)},_.wbg.__wbg_responseText_c67ed2d48db10769=function(){return E((function(_,t){const e=s(t).responseText;var r=v(e)?0:h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),n=p;P()[_/4+1]=n,P()[_/4+0]=r}),arguments)},_.wbg.__wbindgen_closure_wrapper5837=function(_,t,e){return f(V(_,t,538,F))},_.wbg.__wbindgen_closure_wrapper5862=function(_,t,e){return f(V(_,t,538,F))},_}function k_(_,t){_.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function P_(_,t){return o=_.exports,x_.__wbindgen_wasm_module=t,A=null,k=null,b=null,o.__wbindgen_start(),o}function S_(_,t){if(void 0!==o)return o;const e=v_();k_(e,t),_ instanceof WebAssembly.Module||(_=new WebAssembly.Module(_));return P_(new WebAssembly.Instance(_,e),_)}async function x_(_,t){if(void 0!==o)return o;const e=v_();("string"==typeof _||"function"==typeof Request&&_ instanceof Request||"function"==typeof URL&&_ instanceof URL)&&(_=fetch(_)),k_(e,t);const{instance:r,module:n}=await h_(await _,e);return P_(r,n)}var n=Object.freeze({__proto__:null,Address:U,Execution:q,ExecutionResponse:$,Field:D,KeyPair:L,Metadata:Z,OfflineQuery:X,PrivateKey:G,PrivateKeyCiphertext:t_,Program:r_,ProgramManager:i_,ProvingKey:a_,RecordCiphertext:c_,RecordPlaintext:w_,Signature:b_,Transaction:u_,VerifyingKey:p_,ViewKey:m_,default:x_,initSync:S_,initThreadPool:C,runRayonThread:K,verifyFunctionExecution:z});const V_="assets/aleo_wasm.wasm";const{initThreadPool:F_,Address:T_,Execution:R_,ExecutionResponse:z_,Field:A_,Metadata:O_,OfflineQuery:j_,Private:K_,PrivateKey:C_,PrivateKeyCiphertext:E_,Program:M_,ProvingKey:B_,RecordCiphertext:U_,RecordPlaintext:I_,ProgramManager:q_,Signature:W_,Transaction:$_,ViewKey:N_,VerifyingKey:D_,verifyFunctionExecution:J_}=await(async(_={})=>{let{importHook:t,serverPath:e,initializeHook:r}=_,i=V_;return null!=e&&(i=e+/[^\/\\]*$/.exec(i)[0]),null!=t&&(i=t(i)),null!=r?await r(x_,i):await x_(i),n})({importHook:()=>new URL(e(81),e.b)});async function L_(_){null==_&&(_=navigator.hardwareConcurrency),console.info(`Spawning ${_} threads`),await F_(new URL(e(977),e.b),_)}r()}catch(H_){r(H_)}}),1)}}]); -//# sourceMappingURL=877.bundle.js.map \ No newline at end of file diff --git a/877.bundle.js.map b/877.bundle.js.map deleted file mode 100644 index 59d330159..000000000 --- a/877.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"877.bundle.js","mappings":"wOAAA,SAASA,EAAYC,EAAKC,EAAQC,EAAQC,GAClC,OAAO,IAAIC,SAASC,IAChB,MAAMC,EAAS,IAAIC,OAAOP,EAAK,CAC3BQ,KAAM,WAGVF,EAAOG,iBAAiB,WAAYC,IAGhCC,YAAW,KACPN,EAAQC,GAIJA,EAAOM,OACPN,EAAOM,OAC/B,GACmB,EAAE,GACN,CACCC,SAAS,EACTC,MAAM,IAGVR,EAAOS,YAAY,CACfd,SACAC,SACAC,WACF,GAEd,CAEA,IAAIa,E,uHAEJ,MAAMC,EAAO,IAAIC,MAAM,KAAKC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Pje,GAAU,qBACVyB,GAAoB,QACpBQ,GAAO,WACP6F,GAAU,iBACV8C,GAAgB,gBAChBU,GAAe,eACfqS,GAAc,UACdrR,GAAS,YACTM,GAAW,QACX+E,GAAO,aACPrE,GAAY,wBACZ/W,SD26IoB0b,OAAOiM,EAAM,CAAC,KACtB,IAAI,WAACC,EAAU,WAAEC,EAAU,eAAEC,GAAkBH,EAE3CI,EAAaP,GAiBjB,OAfkB,MAAdK,IACAE,EAAaF,EAAa,YAAY7qB,KAAK+qB,GAAY,IAGzC,MAAdH,IACAG,EAAaH,EAAWG,IAGN,MAAlBD,QACMA,EAAe3H,GAAY4H,SAG3B5H,GAAW4H,GAGdpB,CAAO,EC97IpBqB,CAAK,CACXJ,WAAYA,IACD,IAAIZ,IAAI,aAIvBtL,eAAe9a,GAAeqnB,GACX,MAAXA,IACAA,EAAUC,UAAUC,qBAGxBnM,QAAQoM,KAAK,YAAYH,mBAEnBR,GAAmB,IAAIT,IAAI,YAA+BiB,EACpE,C","sources":["webpack://aleo-website/wasm.js","webpack://aleo-website/../js/index.js"],"sourcesContent":["function spawnWorker(url, module, memory, address) {\n return new Promise((resolve) => {\n const worker = new Worker(url, {\n type: \"module\",\n });\n\n worker.addEventListener(\"message\", (event) => {\n // This is needed in Node to wait one extra tick, so that way\n // the Worker can fully initialize before we return.\n setTimeout(() => {\n resolve(worker);\n\n // When running in Node, this allows the process to exit\n // even though the Worker is still running.\n if (worker.unref) {\n worker.unref();\n }\n }, 0);\n }, {\n capture: true,\n once: true,\n });\n\n worker.postMessage({\n module,\n memory,\n address,\n });\n });\n }\n\nlet wasm;\n\nconst heap = new Array(128).fill(undefined);\n\nheap.push(undefined, null, true, false);\n\nfunction getObject(idx) { return heap[idx]; }\n\nlet heap_next = heap.length;\n\nfunction dropObject(idx) {\n if (idx < 132) return;\n heap[idx] = heap_next;\n heap_next = idx;\n}\n\nfunction takeObject(idx) {\n const ret = getObject(idx);\n dropObject(idx);\n return ret;\n}\n\nconst cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );\n\nif (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); }\nlet cachedUint8Memory0 = null;\n\nfunction getUint8Memory0() {\n if (cachedUint8Memory0 === null || cachedUint8Memory0.buffer !== wasm.memory.buffer) {\n cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);\n }\n return cachedUint8Memory0;\n}\n\nfunction getStringFromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return cachedTextDecoder.decode(getUint8Memory0().slice(ptr, ptr + len));\n}\n\nfunction addHeapObject(obj) {\n if (heap_next === heap.length) heap.push(heap.length + 1);\n const idx = heap_next;\n heap_next = heap[idx];\n\n heap[idx] = obj;\n return idx;\n}\n\nlet WASM_VECTOR_LEN = 0;\n\nconst cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );\n\nconst encodeString = function (arg, view) {\n const buf = cachedTextEncoder.encode(arg);\n view.set(buf);\n return {\n read: arg.length,\n written: buf.length\n };\n};\n\nfunction passStringToWasm0(arg, malloc, realloc) {\n\n if (realloc === undefined) {\n const buf = cachedTextEncoder.encode(arg);\n const ptr = malloc(buf.length, 1) >>> 0;\n getUint8Memory0().subarray(ptr, ptr + buf.length).set(buf);\n WASM_VECTOR_LEN = buf.length;\n return ptr;\n }\n\n let len = arg.length;\n let ptr = malloc(len, 1) >>> 0;\n\n const mem = getUint8Memory0();\n\n let offset = 0;\n\n for (; offset < len; offset++) {\n const code = arg.charCodeAt(offset);\n if (code > 0x7F) break;\n mem[ptr + offset] = code;\n }\n\n if (offset !== len) {\n if (offset !== 0) {\n arg = arg.slice(offset);\n }\n ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;\n const view = getUint8Memory0().subarray(ptr + offset, ptr + len);\n const ret = encodeString(arg, view);\n\n offset += ret.written;\n ptr = realloc(ptr, len, offset, 1) >>> 0;\n }\n\n WASM_VECTOR_LEN = offset;\n return ptr;\n}\n\nfunction isLikeNone(x) {\n return x === undefined || x === null;\n}\n\nlet cachedInt32Memory0 = null;\n\nfunction getInt32Memory0() {\n if (cachedInt32Memory0 === null || cachedInt32Memory0.buffer !== wasm.memory.buffer) {\n cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);\n }\n return cachedInt32Memory0;\n}\n\nfunction debugString(val) {\n // primitive types\n const type = typeof val;\n if (type == 'number' || type == 'boolean' || val == null) {\n return `${val}`;\n }\n if (type == 'string') {\n return `\"${val}\"`;\n }\n if (type == 'symbol') {\n const description = val.description;\n if (description == null) {\n return 'Symbol';\n } else {\n return `Symbol(${description})`;\n }\n }\n if (type == 'function') {\n const name = val.name;\n if (typeof name == 'string' && name.length > 0) {\n return `Function(${name})`;\n } else {\n return 'Function';\n }\n }\n // objects\n if (Array.isArray(val)) {\n const length = val.length;\n let debug = '[';\n if (length > 0) {\n debug += debugString(val[0]);\n }\n for(let i = 1; i < length; i++) {\n debug += ', ' + debugString(val[i]);\n }\n debug += ']';\n return debug;\n }\n // Test for built-in\n const builtInMatches = /\\[object ([^\\]]+)\\]/.exec(toString.call(val));\n let className;\n if (builtInMatches.length > 1) {\n className = builtInMatches[1];\n } else {\n // Failed to match the standard '[object ClassName]'\n return toString.call(val);\n }\n if (className == 'Object') {\n // we're a user defined class or Object\n // JSON.stringify avoids problems with cycles, and is generally much\n // easier than looping through ownProperties of `val`.\n try {\n return 'Object(' + JSON.stringify(val) + ')';\n } catch (_) {\n return 'Object';\n }\n }\n // errors\n if (val instanceof Error) {\n return `${val.name}: ${val.message}\\n${val.stack}`;\n }\n // TODO we could test for more things here, like `Set`s and `Map`s.\n return className;\n}\n\nconst CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(state => {\n wasm.__wbindgen_export_3.get(state.dtor)(state.a, state.b);\n});\n\nfunction makeMutClosure(arg0, arg1, dtor, f) {\n const state = { a: arg0, b: arg1, cnt: 1, dtor };\n const real = (...args) => {\n // First up with a closure we increment the internal reference\n // count. This ensures that the Rust closure environment won't\n // be deallocated while we're invoking it.\n state.cnt++;\n const a = state.a;\n state.a = 0;\n try {\n return f(a, state.b, ...args);\n } finally {\n if (--state.cnt === 0) {\n wasm.__wbindgen_export_3.get(state.dtor)(a, state.b);\n CLOSURE_DTORS.unregister(state);\n } else {\n state.a = a;\n }\n }\n };\n real.original = state;\n CLOSURE_DTORS.register(real, state, state);\n return real;\n}\nfunction __wbg_adapter_34(arg0, arg1, arg2) {\n wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(arg0, arg1, addHeapObject(arg2));\n}\n\nfunction _assertClass(instance, klass) {\n if (!(instance instanceof klass)) {\n throw new Error(`expected instance of ${klass.name}`);\n }\n return instance.ptr;\n}\n\nfunction passArray8ToWasm0(arg, malloc) {\n const ptr = malloc(arg.length * 1, 1) >>> 0;\n getUint8Memory0().set(arg, ptr / 1);\n WASM_VECTOR_LEN = arg.length;\n return ptr;\n}\n/**\n* Verify an execution with a single function and a single transition. Executions with multiple\n* transitions or functions will fail to verify. Also, this does not verify that the state root of\n* the execution is included in the Aleo Network ledger.\n*\n* @param {Execution} execution The function execution to verify\n* @param {VerifyingKey} verifying_key The verifying key for the function\n* @param {Program} program The program that the function execution belongs to\n* @param {String} function_id The name of the function that was executed\n* @returns {boolean} True if the execution is valid, false otherwise\n* @param {Execution} execution\n* @param {VerifyingKey} verifying_key\n* @param {Program} program\n* @param {string} function_id\n* @returns {boolean}\n*/\nfunction verifyFunctionExecution(execution, verifying_key, program, function_id) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(execution, Execution);\n _assertClass(verifying_key, VerifyingKey);\n _assertClass(program, Program);\n const ptr0 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyFunctionExecution(retptr, execution.__wbg_ptr, verifying_key.__wbg_ptr, program.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return r0 !== 0;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n}\n\nlet cachedBigInt64Memory0 = null;\n\nfunction getBigInt64Memory0() {\n if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.buffer !== wasm.memory.buffer) {\n cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);\n }\n return cachedBigInt64Memory0;\n}\n\nfunction getArrayU8FromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);\n}\n/**\n* @param {number} receiver\n*/\nfunction runRayonThread(receiver) {\n wasm.runRayonThread(receiver);\n}\n\n/**\n* @param {URL} url\n* @param {number} num_threads\n* @returns {Promise}\n*/\nfunction initThreadPool(url, num_threads) {\n const ret = wasm.initThreadPool(addHeapObject(url), num_threads);\n return takeObject(ret);\n}\n\nfunction handleError(f, args) {\n try {\n return f.apply(this, args);\n } catch (e) {\n wasm.__wbindgen_exn_store(addHeapObject(e));\n }\n}\nfunction __wbg_adapter_281(arg0, arg1, arg2, arg3) {\n wasm.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));\n}\n\nconst AddressFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_address_free(ptr >>> 0));\n/**\n* Public address of an Aleo account\n*/\nclass Address {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Address.prototype);\n obj.__wbg_ptr = ptr;\n AddressFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n AddressFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_address_free(ptr);\n }\n /**\n * Derive an Aleo address from a private key\n *\n * @param {PrivateKey} private_key The private key to derive the address from\n * @returns {Address} Address corresponding to the private key\n * @param {PrivateKey} private_key\n * @returns {Address}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.address_from_private_key(private_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Derive an Aleo address from a view key\n *\n * @param {ViewKey} view_key The view key to derive the address from\n * @returns {Address} Address corresponding to the view key\n * @param {ViewKey} view_key\n * @returns {Address}\n */\n static from_view_key(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.address_from_view_key(view_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Create an aleo address object from a string representation of an address\n *\n * @param {string} address String representation of an addressm\n * @returns {Address} Address\n * @param {string} address\n * @returns {Address}\n */\n static from_string(address) {\n const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.address_from_string(ptr0, len0);\n return Address.__wrap(ret);\n }\n /**\n * Get a string representation of an Aleo address object\n *\n * @param {Address} Address\n * @returns {string} String representation of the address\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.address_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Verify a signature for a message signed by the address\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {boolean} Boolean representing whether or not the signature is valid\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n */\n verify(message, signature) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n _assertClass(signature, Signature);\n const ret = wasm.address_verify(this.__wbg_ptr, ptr0, len0, signature.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst ExecutionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_execution_free(ptr >>> 0));\n/**\n* Execution of an Aleo program.\n*/\nclass Execution {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Execution.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_execution_free(ptr);\n }\n /**\n * Returns the string representation of the execution.\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.execution_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates an execution object from a string representation of an execution.\n * @param {string} execution\n * @returns {Execution}\n */\n static fromString(execution) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(execution, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.execution_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Execution.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ExecutionResponseFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_executionresponse_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo function execution response\n*\n* This object is returned by the execution of an Aleo function off-chain. It provides methods for\n* retrieving the outputs of the function execution.\n*/\nclass ExecutionResponse {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ExecutionResponse.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionResponseFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionResponseFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_executionresponse_free(ptr);\n }\n /**\n * Get the outputs of the executed function\n *\n * @returns {Array} Array of strings representing the outputs of the function\n * @returns {Array}\n */\n getOutputs() {\n const ret = wasm.executionresponse_getOutputs(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Returns the execution object if present, null if otherwise.\n *\n * @returns {Execution | undefined} The execution object if present, null if otherwise\n * @returns {Execution | undefined}\n */\n getExecution() {\n const ret = wasm.executionresponse_getExecution(this.__wbg_ptr);\n return ret === 0 ? undefined : Execution.__wrap(ret);\n }\n /**\n * Returns the program keys if present\n * @returns {KeyPair}\n */\n getKeys() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getKeys(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return KeyPair.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the proving_key if the proving key was cached in the Execution response.\n * Note the proving key is removed from the response object after the first call to this\n * function. Subsequent calls will return null.\n *\n * @returns {ProvingKey | undefined} The proving key\n * @returns {ProvingKey | undefined}\n */\n getProvingKey() {\n const ret = wasm.executionresponse_getProvingKey(this.__wbg_ptr);\n return ret === 0 ? undefined : ProvingKey.__wrap(ret);\n }\n /**\n * Returns the verifying_key associated with the program\n *\n * @returns {VerifyingKey} The verifying key\n * @returns {VerifyingKey}\n */\n getVerifyingKey() {\n const ret = wasm.executionresponse_getVerifyingKey(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the function identifier\n * @returns {string}\n */\n getFunctionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getFunctionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the program\n * @returns {Program}\n */\n getProgram() {\n const ret = wasm.executionresponse_getProgram(this.__wbg_ptr);\n return Program.__wrap(ret);\n }\n}\n\nconst FieldFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_field_free(ptr >>> 0));\n/**\n*/\nclass Field {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Field.prototype);\n obj.__wbg_ptr = ptr;\n FieldFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n FieldFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_field_free(ptr);\n }\n /**\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.field_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} field\n * @returns {Field}\n */\n static fromString(field) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(field, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.field_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst KeyPairFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_keypair_free(ptr >>> 0));\n/**\n* Key pair object containing both the function proving and verifying keys\n*/\nclass KeyPair {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(KeyPair.prototype);\n obj.__wbg_ptr = ptr;\n KeyPairFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n KeyPairFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_keypair_free(ptr);\n }\n /**\n * Create new key pair from proving and verifying keys\n *\n * @param {ProvingKey} proving_key Proving key corresponding to a function in an Aleo program\n * @param {VerifyingKey} verifying_key Verifying key corresponding to a function in an Aleo program\n * @returns {KeyPair} Key pair object containing both the function proving and verifying keys\n * @param {ProvingKey} proving_key\n * @param {VerifyingKey} verifying_key\n */\n constructor(proving_key, verifying_key) {\n _assertClass(proving_key, ProvingKey);\n var ptr0 = proving_key.__destroy_into_raw();\n _assertClass(verifying_key, VerifyingKey);\n var ptr1 = verifying_key.__destroy_into_raw();\n const ret = wasm.keypair_new(ptr0, ptr1);\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get the proving key. This method will remove the proving key from the key pair\n *\n * @returns {ProvingKey | Error}\n * @returns {ProvingKey}\n */\n provingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_provingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the verifying key. This method will remove the verifying key from the key pair\n *\n * @returns {VerifyingKey | Error}\n * @returns {VerifyingKey}\n */\n verifyingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst MetadataFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_metadata_free(ptr >>> 0));\n/**\n*/\nclass Metadata {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Metadata.prototype);\n obj.__wbg_ptr = ptr;\n MetadataFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n MetadataFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_metadata_free(ptr);\n }\n /**\n * @returns {string}\n */\n get name() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_name(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set name(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_name(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get locator() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_locator(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set locator(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_locator(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get prover() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_prover(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set prover(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_prover(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifier() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifier(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifier(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifier(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifyingKey() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifyingKey(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifyingKey(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n static baseUrl() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.metadata_baseUrl(retptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @returns {Metadata}\n */\n static bond_public() {\n const ret = wasm.metadata_bond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static bond_validator() {\n const ret = wasm.metadata_bond_validator();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static claim_unbond_public() {\n const ret = wasm.metadata_claim_unbond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_private() {\n const ret = wasm.metadata_fee_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_public() {\n const ret = wasm.metadata_fee_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static inclusion() {\n const ret = wasm.metadata_inclusion();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static join() {\n const ret = wasm.metadata_join();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static set_validator_state() {\n const ret = wasm.metadata_set_validator_state();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static split() {\n const ret = wasm.metadata_split();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private() {\n const ret = wasm.metadata_transfer_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private_to_public() {\n const ret = wasm.metadata_transfer_private_to_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public() {\n const ret = wasm.metadata_transfer_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_as_signer() {\n const ret = wasm.metadata_transfer_public_as_signer();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_to_private() {\n const ret = wasm.metadata_transfer_public_to_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static unbond_public() {\n const ret = wasm.metadata_unbond_public();\n return Metadata.__wrap(ret);\n }\n}\n\nconst OfflineQueryFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_offlinequery_free(ptr >>> 0));\n/**\n* An offline query object used to insert the global state root and state paths needed to create\n* a valid inclusion proof offline.\n*/\nclass OfflineQuery {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(OfflineQuery.prototype);\n obj.__wbg_ptr = ptr;\n OfflineQueryFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n OfflineQueryFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_offlinequery_free(ptr);\n }\n /**\n * Creates a new offline query object. The state root is required to be passed in as a string\n * @param {string} state_root\n */\n constructor(state_root) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(state_root, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_new(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n this.__wbg_ptr = r0 >>> 0;\n return this;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Add a new state path to the offline query object.\n *\n * @param {string} commitment: The commitment corresponding to a record inpout\n * @param {string} state_path: The state path corresponding to the commitment\n * @param {string} commitment\n * @param {string} state_path\n */\n addStatePath(commitment, state_path) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(commitment, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(state_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.offlinequery_addStatePath(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n if (r1) {\n throw takeObject(r0);\n }\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a json string representation of the offline query object\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.offlinequery_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create an offline query object from a json string representation\n * @param {string} s\n * @returns {OfflineQuery}\n */\n static fromString(s) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(s, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return OfflineQuery.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekey_free(ptr >>> 0));\n/**\n* Private key of an Aleo account\n*/\nclass PrivateKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKey.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekey_free(ptr);\n }\n /**\n * Generate a new private key using a cryptographically secure random number generator\n *\n * @returns {PrivateKey}\n */\n constructor() {\n const ret = wasm.privatekey_new();\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get a private key from a series of unchecked bytes\n *\n * @param {Uint8Array} seed Unchecked 32 byte long Uint8Array acting as the seed for the private key\n * @returns {PrivateKey}\n * @param {Uint8Array} seed\n * @returns {PrivateKey}\n */\n static from_seed_unchecked(seed) {\n const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_from_seed_unchecked(ptr0, len0);\n return PrivateKey.__wrap(ret);\n }\n /**\n * Get a private key from a string representation of a private key\n *\n * @param {string} seed String representation of a private key\n * @returns {PrivateKey}\n * @param {string} private_key\n * @returns {PrivateKey}\n */\n static from_string(private_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(private_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_from_string(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the private key. This function should be used very carefully\n * as it exposes the private key plaintext\n *\n * @returns {string} String representation of a private key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the view key corresponding to the private key\n *\n * @returns {ViewKey}\n * @returns {ViewKey}\n */\n to_view_key() {\n const ret = wasm.privatekey_to_view_key(this.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get the address corresponding to the private key\n *\n * @returns {Address}\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.privatekey_to_address(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Sign a message with the private key\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {Signature} Signature generated by signing the message with the address\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n sign(message) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(this.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a new randomly generated private key ciphertext using a secret. The secret is sensitive\n * and will be needed to decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext | Error} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static newEncrypted(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_newEncrypted(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Encrypt an existing private key with a secret. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext | Error} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n toCiphertext(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get private key from a private key ciphertext and secret originally used to encrypt it\n *\n * @param {PrivateKeyCiphertext} ciphertext Ciphertext representation of the private key\n * @param {string} secret Secret originally used to encrypt the private key\n * @returns {PrivateKey | Error} Private key\n * @param {PrivateKeyCiphertext} ciphertext\n * @param {string} secret\n * @returns {PrivateKey}\n */\n static fromPrivateKeyCiphertext(ciphertext, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(ciphertext, PrivateKeyCiphertext);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_fromPrivateKeyCiphertext(retptr, ciphertext.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekeyciphertext_free(ptr >>> 0));\n/**\n* Private Key in ciphertext form\n*/\nclass PrivateKeyCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKeyCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekeyciphertext_free(ptr);\n }\n /**\n * Encrypt a private key using a secret string. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {PrivateKey} private_key Private key to encrypt\n * @param {string} secret Secret to encrypt the private key with\n * @returns {PrivateKeyCiphertext | Error} Private key ciphertext\n * @param {PrivateKey} private_key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static encryptPrivateKey(private_key, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, private_key.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Decrypts a private ciphertext using a secret string. This must be the same secret used to\n * encrypt the private key\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKey | Error} Private key\n * @param {string} secret\n * @returns {PrivateKey}\n */\n decryptToPrivateKey(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_decryptToPrivateKey(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the ciphertext string\n *\n * @returns {string} Ciphertext string\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekeyciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates a PrivateKeyCiphertext from a string\n *\n * @param {string} ciphertext Ciphertext string\n * @returns {PrivateKeyCiphertext | Error} Private key ciphertext\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n */\n static fromString(ciphertext) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ProgramFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_program_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo program\n*/\nclass Program {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Program.prototype);\n obj.__wbg_ptr = ptr;\n ProgramFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_program_free(ptr);\n }\n /**\n * Create a program from a program string\n *\n * @param {string} program Aleo program source code\n * @returns {Program | Error} Program object\n * @param {string} program\n * @returns {Program}\n */\n static fromString(program) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Program.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the program\n *\n * @returns {string} String containing the program source code\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Determine if a function is present in the program\n *\n * @param {string} functionName Name of the function to check for\n * @returns {boolean} True if the program is valid, false otherwise\n * @param {string} function_name\n * @returns {boolean}\n */\n hasFunction(function_name) {\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.program_hasFunction(this.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get javascript array of functions names in the program\n *\n * @returns {Array} Array of all function names present in the program\n *\n * @example\n * const expected_functions = [\n * \"mint\",\n * \"transfer_private\",\n * \"transfer_private_to_public\",\n * \"transfer_public\",\n * \"transfer_public_to_private\",\n * \"join\",\n * \"split\",\n * \"fee\"\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_functions = credits_program.getFunctions();\n * console.log(credits_functions === expected_functions); // Output should be \"true\"\n * @returns {Array}\n */\n getFunctions() {\n const ret = wasm.program_getFunctions(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Get a javascript object representation of the function inputs and types. This can be used\n * to generate a web form to capture user inputs for an execution of a function.\n *\n * @param {string} function_name Name of the function to get inputs for\n * @returns {Array | Error} Array of function inputs\n *\n * @example\n * const expected_inputs = [\n * {\n * type:\"record\",\n * visibility:\"private\",\n * record:\"credits\",\n * members:[\n * {\n * name:\"microcredits\",\n * type:\"u64\",\n * visibility:\"private\"\n * }\n * ],\n * register:\"r0\"\n * },\n * {\n * type:\"address\",\n * visibility:\"private\",\n * register:\"r1\"\n * },\n * {\n * type:\"u64\",\n * visibility:\"private\",\n * register:\"r2\"\n * }\n * ];\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const transfer_function_inputs = credits_program.getFunctionInputs(\"transfer_private\");\n * console.log(transfer_function_inputs === expected_inputs); // Output should be \"true\"\n * @param {string} function_name\n * @returns {Array}\n */\n getFunctionInputs(function_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getFunctionInputs(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a the list of a program's mappings and the names/types of their keys and values.\n *\n * @returns {Array | Error} - An array of objects representing the mappings in the program\n * @example\n * const expected_mappings = [\n * {\n * name: \"account\",\n * key_name: \"owner\",\n * key_type: \"address\",\n * value_name: \"microcredits\",\n * value_type: \"u64\"\n * }\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_mappings = credits_program.getMappings();\n * console.log(credits_mappings === expected_mappings); // Output should be \"true\"\n * @returns {Array}\n */\n getMappings() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_getMappings(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program record and its types\n *\n * @param {string} record_name Name of the record to get members for\n * @returns {Object | Error} Object containing the record name, type, and members\n *\n * @example\n *\n * const expected_record = {\n * type: \"record\",\n * record: \"Credits\",\n * members: [\n * {\n * name: \"owner\",\n * type: \"address\",\n * visibility: \"private\"\n * },\n * {\n * name: \"microcredits\",\n * type: \"u64\",\n * visibility: \"private\"\n * }\n * ];\n * };\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_record = credits_program.getRecordMembers(\"Credits\");\n * console.log(credits_record === expected_record); // Output should be \"true\"\n * @param {string} record_name\n * @returns {object}\n */\n getRecordMembers(record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getRecordMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program struct and its types\n *\n * @param {string} struct_name Name of the struct to get members for\n * @returns {Array | Error} Array containing the struct members\n *\n * @example\n *\n * const STRUCT_PROGRAM = \"program token_issue.aleo;\n *\n * struct token_metadata:\n * network as u32;\n * version as u32;\n *\n * struct token:\n * token_id as u32;\n * metadata as token_metadata;\n *\n * function no_op:\n * input r0 as u64;\n * output r0 as u64;\"\n *\n * const expected_struct_members = [\n * {\n * name: \"token_id\",\n * type: \"u32\",\n * },\n * {\n * name: \"metadata\",\n * type: \"struct\",\n * struct_id: \"token_metadata\",\n * members: [\n * {\n * name: \"network\",\n * type: \"u32\",\n * }\n * {\n * name: \"version\",\n * type: \"u32\",\n * }\n * ]\n * }\n * ];\n *\n * const program = aleo_wasm.Program.fromString(STRUCT_PROGRAM);\n * const struct_members = program.getStructMembers(\"token\");\n * console.log(struct_members === expected_struct_members); // Output should be \"true\"\n * @param {string} struct_name\n * @returns {Array}\n */\n getStructMembers(struct_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(struct_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getStructMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the credits.aleo program\n *\n * @returns {Program} The credits.aleo program\n * @returns {Program}\n */\n static getCreditsProgram() {\n const ret = wasm.program_getCreditsProgram();\n return Program.__wrap(ret);\n }\n /**\n * Get the id of the program\n *\n * @returns {string} The id of the program\n * @returns {string}\n */\n id() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_id(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get a unique address of the program\n *\n * @returns {Address} The address of the program\n * @returns {Address}\n */\n address() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_address(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Address.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determine equality with another program\n *\n * @param {Program} other The other program to compare\n * @returns {boolean} True if the programs are equal, false otherwise\n * @param {Program} other\n * @returns {boolean}\n */\n isEqual(other) {\n _assertClass(other, Program);\n const ret = wasm.program_isEqual(this.__wbg_ptr, other.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get program_imports\n *\n * @returns {Array} The program imports\n *\n * @example\n *\n * const DOUBLE_TEST = \"import multiply_test.aleo;\n *\n * program double_test.aleo;\n *\n * function double_it:\n * input r0 as u32.private;\n * call multiply_test.aleo/multiply 2u32 r0 into r1;\n * output r1 as u32.private;\";\n *\n * const expected_imports = [\n * \"multiply_test.aleo\"\n * ];\n *\n * const program = aleo_wasm.Program.fromString(DOUBLE_TEST_PROGRAM);\n * const imports = program.getImports();\n * console.log(imports === expected_imports); // Output should be \"true\"\n * @returns {Array}\n */\n getImports() {\n const ret = wasm.program_getImports(this.__wbg_ptr);\n return takeObject(ret);\n }\n}\n\nconst ProgramManagerFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_programmanager_free(ptr >>> 0));\n/**\n*/\nclass ProgramManager {\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramManagerFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_programmanager_free(ptr);\n }\n /**\n * Deploy an Aleo program\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being deployed\n * @param imports A javascript object holding the source code of any imported programs in the\n * form \\{\"program_name1\": \"program_source_code\", \"program_name2\": \"program_source_code\", ..\\}.\n * Note that all imported programs must be deployed on chain before the main program in order\n * for the deployment to succeed\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the program deployment in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildDeploymentTransaction(private_key, program, fee_credits, fee_record, url, imports, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n let ptr1 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr1 = fee_record.__destroy_into_raw();\n }\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr3 = fee_proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr4 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildDeploymentTransaction(private_key.__wbg_ptr, ptr0, len0, fee_credits, ptr1, ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the fee for a program deployment\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The source code of the program being deployed\n * @param imports (optional) Provide a list of imports to use for the deployment fee estimation\n * in the form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @returns {u64 | Error}\n * @param {string} program\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static estimateDeploymentFee(program, imports) {\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_estimateDeploymentFee(ptr0, len0, isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n /**\n * Estimate the component of the deployment cost which comes from the fee for the program name.\n * Note that this cost does not represent the entire cost of deployment. It is additional to\n * the cost of the size (in bytes) of the deployment.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param name The name of the program to be deployed\n * @returns {u64 | Error}\n * @param {string} name\n * @returns {bigint}\n */\n static estimateProgramNameCost(name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateProgramNameCost(retptr, ptr0, len0);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Execute an arbitrary function locally\n *\n * @param {PrivateKey} private_key The private key of the sender\n * @param {string} program The source code of the program being executed\n * @param {string} function The name of the function to execute\n * @param {Array} inputs A javascript array of inputs to the function\n * @param {boolean} prove_execution If true, the execution will be proven and an execution object\n * containing the proof and the encrypted inputs and outputs needed to verify the proof offline\n * will be returned.\n * @param {boolean} cache Cache the proving and verifying keys in the Execution response.\n * If this is set to 'true' the keys synthesized will be stored in the Execution Response\n * and the `ProvingKey` and `VerifyingKey` can be retrieved from the response via the `.getKeys()`\n * method.\n * @param {Object | undefined} imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param {ProvingKey | undefined} proving_key (optional) Provide a verifying key to use for the function execution\n * @param {VerifyingKey | undefined} verifying_key (optional) Provide a verifying key to use for the function execution\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {boolean} prove_execution\n * @param {boolean} cache\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {string | undefined} [url]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static executeFunctionOffline(private_key, program, _function, inputs, prove_execution, cache, imports, proving_key, verifying_key, url, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr2 = proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr3 = verifying_key.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_executeFunctionOffline(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), prove_execution, cache, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr2, ptr3, ptr4, len4, ptr5);\n return takeObject(ret);\n }\n /**\n * Execute Aleo function and create an Aleo execution transaction\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being executed\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * If this is set to 'true' the keys synthesized (or passed in as optional parameters via the\n * `proving_key` and `verifying_key` arguments) will be stored in the ProgramManager's memory\n * and used for subsequent transactions. If this is set to 'false' the proving and verifying\n * keys will be deallocated from memory after the transaction is executed.\n * @param imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the function execution\n * @param verifying_key (optional) Provide a verifying key to use for the function execution\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildExecutionTransaction(private_key, program, _function, inputs, fee_credits, fee_record, url, imports, proving_key, verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr4 = proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr5 = verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildExecutionTransaction(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), fee_credits, ptr2, ptr3, len3, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Estimate Fee for Aleo function execution. Note if \"cache\" is set to true, the proving and\n * verifying keys will be stored in the ProgramManager's memory and used for subsequent\n * program executions.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program to estimate the execution fee for\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the fee estimation in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the fee estimation\n * @param verifying_key (optional) Provide a verifying key to use for the fee estimation\n * @returns {u64 | Error} Fee in microcredits\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static estimateExecutionFee(private_key, program, _function, inputs, url, imports, proving_key, verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr3 = proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr4 = verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_estimateExecutionFee(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the finalize fee component for executing a function. This fee is additional to the\n * size of the execution of the program in bytes. If the function does not have a finalize\n * step, then the finalize fee is 0.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The program containing the function to estimate the finalize fee for\n * @param function The function to estimate the finalize fee for\n * @returns {u64 | Error} Fee in microcredits\n * @param {string} program\n * @param {string} _function\n * @returns {bigint}\n */\n static estimateFinalizeFee(program, _function) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateFinalizeFee(retptr, ptr0, len0, ptr1, len1);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Join two records together to create a new record with an amount of credits equal to the sum\n * of the credits of the two original records\n *\n * @param private_key The private key of the sender\n * @param record_1 The first record to combine\n * @param record_2 The second record to combine\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param join_proving_key (optional) Provide a proving key to use for the join function\n * @param join_verifying_key (optional) Provide a verifying key to use for the join function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error} Transaction object\n * @param {PrivateKey} private_key\n * @param {RecordPlaintext} record_1\n * @param {RecordPlaintext} record_2\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [join_proving_key]\n * @param {VerifyingKey | undefined} [join_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildJoinTransaction(private_key, record_1, record_2, fee_credits, fee_record, url, join_proving_key, join_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(record_1, RecordPlaintext);\n var ptr0 = record_1.__destroy_into_raw();\n _assertClass(record_2, RecordPlaintext);\n var ptr1 = record_2.__destroy_into_raw();\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(join_proving_key)) {\n _assertClass(join_proving_key, ProvingKey);\n ptr4 = join_proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(join_verifying_key)) {\n _assertClass(join_verifying_key, VerifyingKey);\n ptr5 = join_verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildJoinTransaction(private_key.__wbg_ptr, ptr0, ptr1, fee_credits, ptr2, ptr3, len3, ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Split an Aleo credits record into two separate records. This function does not require a fee.\n *\n * @param private_key The private key of the sender\n * @param split_amount The amount of the credit split. This amount will be subtracted from the\n * value of the record and two new records will be created with the split amount and the remainder\n * @param amount_record The record to split\n * @param url The url of the Aleo network node to send the transaction to\n * @param split_proving_key (optional) Provide a proving key to use for the split function\n * @param split_verifying_key (optional) Provide a verifying key to use for the split function\n * @returns {Transaction | Error} Transaction object\n * @param {PrivateKey} private_key\n * @param {number} split_amount\n * @param {RecordPlaintext} amount_record\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [split_proving_key]\n * @param {VerifyingKey | undefined} [split_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildSplitTransaction(private_key, split_amount, amount_record, url, split_proving_key, split_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(amount_record, RecordPlaintext);\n var ptr0 = amount_record.__destroy_into_raw();\n var ptr1 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(split_proving_key)) {\n _assertClass(split_proving_key, ProvingKey);\n ptr2 = split_proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(split_verifying_key)) {\n _assertClass(split_verifying_key, VerifyingKey);\n ptr3 = split_verifying_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr4 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildSplitTransaction(private_key.__wbg_ptr, split_amount, ptr0, ptr1, len1, ptr2, ptr3, ptr4);\n return takeObject(ret);\n }\n /**\n * Send credits from one Aleo account to another\n *\n * @param private_key The private key of the sender\n * @param amount_credits The amount of credits to send\n * @param recipient The recipient of the transaction\n * @param transfer_type The type of the transfer (options: \"private\", \"public\", \"private_to_public\", \"public_to_private\")\n * @param amount_record The record to fund the amount from\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param transfer_verifying_key (optional) Provide a verifying key to use for the transfer\n * function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {number} amount_credits\n * @param {string} recipient\n * @param {string} transfer_type\n * @param {RecordPlaintext | undefined} amount_record\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [transfer_proving_key]\n * @param {VerifyingKey | undefined} [transfer_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildTransferTransaction(private_key, amount_credits, recipient, transfer_type, amount_record, fee_credits, fee_record, url, transfer_proving_key, transfer_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(recipient, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(transfer_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(amount_record)) {\n _assertClass(amount_record, RecordPlaintext);\n ptr2 = amount_record.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr3 = fee_record.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(transfer_proving_key)) {\n _assertClass(transfer_proving_key, ProvingKey);\n ptr5 = transfer_proving_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(transfer_verifying_key)) {\n _assertClass(transfer_verifying_key, VerifyingKey);\n ptr6 = transfer_verifying_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr7 = fee_proving_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr8 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr9 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr9 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildTransferTransaction(private_key.__wbg_ptr, amount_credits, ptr0, len0, ptr1, len1, ptr2, fee_credits, ptr3, ptr4, len4, ptr5, ptr6, ptr7, ptr8, ptr9);\n return takeObject(ret);\n }\n /**\n * Synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code of the program to synthesize keys for\n * @param function_id {string} The function to synthesize keys for\n * @param inputs {Array} The inputs to the function\n * @param imports {Object | undefined} The imports for the program\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} function_id\n * @param {Array} inputs\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static synthesizeKeyPair(private_key, program, function_id, inputs, imports) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_synthesizeKeyPair(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n}\n\nconst ProvingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_provingkey_free(ptr >>> 0));\n/**\n* Proving key for a function within an Aleo program\n*/\nclass ProvingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ProvingKey.prototype);\n obj.__wbg_ptr = ptr;\n ProvingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProvingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_provingkey_free(ptr);\n }\n /**\n * Verify if the proving key is for the bond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_public_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_public function, false if otherwise\n * @returns {boolean}\n */\n isBondPublicProver() {\n const ret = wasm.provingkey_isBondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the bond_validator function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_validator_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_validator function, false if otherwise\n * @returns {boolean}\n */\n isBondValidatorProver() {\n const ret = wasm.provingkey_isBondValidatorProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the claim_unbond function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"claim_unbond_proving_key.bin\");\n * provingKey.isClaimUnbondProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the claim_unbond function, false if otherwise\n * @returns {boolean}\n */\n isClaimUnbondPublicProver() {\n const ret = wasm.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_private_proving_key.bin\");\n * provingKey.isFeePrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_private function, false if otherwise\n * @returns {boolean}\n */\n isFeePrivateProver() {\n const ret = wasm.provingkey_isFeePrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_public_proving_key.bin\");\n * provingKey.isFeePublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_public function, false if otherwise\n * @returns {boolean}\n */\n isFeePublicProver() {\n const ret = wasm.provingkey_isFeePublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the inclusion function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"inclusion_proving_key.bin\");\n * provingKey.isInclusionProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the inclusion function, false if otherwise\n * @returns {boolean}\n */\n isInclusionProver() {\n const ret = wasm.provingkey_isInclusionProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the join function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"join_proving_key.bin\");\n * provingKey.isJoinProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the join function, false if otherwise\n * @returns {boolean}\n */\n isJoinProver() {\n const ret = wasm.provingkey_isJoinProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the set_validator_state function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"set_validator_set_proving_key.bin\");\n * provingKey.isSetValidatorStateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the set_validator_state function, false if otherwise\n * @returns {boolean}\n */\n isSetValidatorStateProver() {\n const ret = wasm.provingkey_isSetValidatorStateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the split function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"split_proving_key.bin\");\n * provingKey.isSplitProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the split function, false if otherwise\n * @returns {boolean}\n */\n isSplitProver() {\n const ret = wasm.provingkey_isSplitProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_proving_key.bin\");\n * provingKey.isTransferPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateProver() {\n const ret = wasm.provingkey_isTransferPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private_to_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_to_public_proving_key.bin\");\n * provingKey.isTransferPrivateToPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private_to_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateToPublicProver() {\n const ret = wasm.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_proving_key.bin\");\n * provingKey.isTransferPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicProver() {\n const ret = wasm.provingkey_isTransferPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_as_signer function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_as_signer_proving_key.bin\");\n * provingKey.isTransferPublicAsSignerProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicAsSignerProver() {\n const ret = wasm.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_to_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_to_private_proving_key.bin\");\n * provingKey.isTransferPublicToPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public_to_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicToPrivateProver() {\n const ret = wasm.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the unbond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"unbond_public.bin\");\n * provingKey.isUnbondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the unbond_public_prover function, false if otherwise\n * @returns {boolean}\n */\n isUnbondPublicProver() {\n const ret = wasm.provingkey_isUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Return the checksum of the proving key\n *\n * @returns {string} Checksum of the proving key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the proving key\n *\n * @returns {ProvingKey} A copy of the proving key\n * @returns {ProvingKey}\n */\n copy() {\n const ret = wasm.provingkey_copy(this.__wbg_ptr);\n return ProvingKey.__wrap(ret);\n }\n /**\n * Construct a new proving key from a byte array\n *\n * @param {Uint8Array} bytes Byte array representation of a proving key\n * @returns {ProvingKey | Error}\n * @param {Uint8Array} bytes\n * @returns {ProvingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a proving key from string\n *\n * @param {string | Error} String representation of the proving key\n * @param {string} string\n * @returns {ProvingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the byte representation of a proving key\n *\n * @returns {Uint8Array | Error} Byte array representation of a proving key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the proving key\n *\n * @returns {string} String representation of the proving key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst RecordCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordciphertext_free(ptr >>> 0));\n/**\n* Encrypted Aleo record\n*/\nclass RecordCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n RecordCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordciphertext_free(ptr);\n }\n /**\n * Create a record ciphertext from a string\n *\n * @param {string} record String representation of a record ciphertext\n * @returns {RecordCiphertext | Error} Record ciphertext\n * @param {string} record\n * @returns {RecordCiphertext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the string reprensentation of the record ciphertext\n *\n * @returns {string} String representation of the record ciphertext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Decrypt the record ciphertext into plaintext using the view key. The record will only\n * decrypt if the record was encrypted by the account corresponding to the view key\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {RecordPlaintext | Error} Record plaintext object\n * @param {ViewKey} view_key\n * @returns {RecordPlaintext}\n */\n decrypt(view_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(view_key, ViewKey);\n wasm.recordciphertext_decrypt(retptr, this.__wbg_ptr, view_key.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determines if the account corresponding to the view key is the owner of the record\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {boolean}\n * @param {ViewKey} view_key\n * @returns {boolean}\n */\n isOwner(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.recordciphertext_isOwner(this.__wbg_ptr, view_key.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst RecordPlaintextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordplaintext_free(ptr >>> 0));\n/**\n* Plaintext representation of an Aleo record\n*/\nclass RecordPlaintext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordPlaintext.prototype);\n obj.__wbg_ptr = ptr;\n RecordPlaintextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordPlaintextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordplaintext_free(ptr);\n }\n /**\n * @param {string} program_id\n * @param {string} record_name\n * @returns {Field}\n */\n commitment(program_id, record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_commitment(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return a record plaintext from a string.\n *\n * @param {string} record String representation of a plaintext representation of an Aleo record\n * @returns {RecordPlaintext | Error} Record plaintext\n * @param {string} record\n * @returns {RecordPlaintext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordplaintext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the record plaintext string\n *\n * @returns {string} String representation of the record plaintext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the amount of microcredits in the record\n *\n * @returns {u64} Amount of microcredits in the record\n * @returns {bigint}\n */\n microcredits() {\n const ret = wasm.recordplaintext_microcredits(this.__wbg_ptr);\n return BigInt.asUintN(64, ret);\n }\n /**\n * Returns the nonce of the record. This can be used to uniquely identify a record.\n *\n * @returns {string} Nonce of the record\n * @returns {string}\n */\n nonce() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_nonce(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Attempt to get the serial number of a record to determine whether or not is has been spent\n *\n * @param {PrivateKey} private_key Private key of the account that owns the record\n * @param {string} program_id Program ID of the program that the record is associated with\n * @param {string} record_name Name of the record\n * @returns {string | Error} Serial number of the record\n * @param {PrivateKey} private_key\n * @param {string} program_id\n * @param {string} record_name\n * @returns {string}\n */\n serialNumberString(private_key, program_id, record_name) {\n let deferred4_0;\n let deferred4_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_serialNumberString(retptr, this.__wbg_ptr, private_key.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr3 = r0;\n var len3 = r1;\n if (r3) {\n ptr3 = 0; len3 = 0;\n throw takeObject(r2);\n }\n deferred4_0 = ptr3;\n deferred4_1 = len3;\n return getStringFromWasm0(ptr3, len3);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred4_0, deferred4_1, 1);\n }\n }\n}\n\nconst SignatureFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_signature_free(ptr >>> 0));\n/**\n* Cryptographic signature of a message signed by an Aleo account\n*/\nclass Signature {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Signature.prototype);\n obj.__wbg_ptr = ptr;\n SignatureFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n SignatureFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_signature_free(ptr);\n }\n /**\n * Sign a message with a private key\n *\n * @param {PrivateKey} private_key The private key to sign the message with\n * @param {Uint8Array} message Byte representation of the message to sign\n * @returns {Signature} Signature of the message\n * @param {PrivateKey} private_key\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n static sign(private_key, message) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(private_key.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Verify a signature of a message with an address\n *\n * @param {Address} address The address to verify the signature with\n * @param {Uint8Array} message Byte representation of the message to verify\n * @returns {boolean} True if the signature is valid, false otherwise\n * @param {Address} address\n * @param {Uint8Array} message\n * @returns {boolean}\n */\n verify(address, message) {\n _assertClass(address, Address);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_verify(this.__wbg_ptr, address.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get a signature from a string representation of a signature\n *\n * @param {string} signature String representation of a signature\n * @returns {Signature} Signature\n * @param {string} signature\n * @returns {Signature}\n */\n static from_string(signature) {\n const ptr0 = passStringToWasm0(signature, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_from_string(ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a string representation of a signature\n *\n * @returns {string} String representation of a signature\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.signature_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst TransactionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_transaction_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo transaction\n*\n* This object is created when generating an on-chain function deployment or execution and is the\n* object that should be submitted to the Aleo Network in order to deploy or execute a function.\n*/\nclass Transaction {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Transaction.prototype);\n obj.__wbg_ptr = ptr;\n TransactionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n TransactionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_transaction_free(ptr);\n }\n /**\n * Create a transaction from a string\n *\n * @param {string} transaction String representation of a transaction\n * @returns {Transaction | Error}\n * @param {string} transaction\n * @returns {Transaction}\n */\n static fromString(transaction) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(transaction, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.transaction_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Transaction.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the transaction as a string. If you want to submit this transaction to the Aleo Network\n * this function will create the string that should be submitted in the `POST` data.\n *\n * @returns {string} String representation of the transaction\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the id of the transaction. This is the merkle root of the transaction's inclusion proof.\n *\n * This value can be used to query the status of the transaction on the Aleo Network to see\n * if it was successful. If successful, the transaction will be included in a block and this\n * value can be used to lookup the transaction data on-chain.\n *\n * @returns {string} Transaction id\n * @returns {string}\n */\n transactionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the type of the transaction (will return \"deploy\" or \"execute\")\n *\n * @returns {string} Transaction type\n * @returns {string}\n */\n transactionType() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionType(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst VerifyingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_verifyingkey_free(ptr >>> 0));\n/**\n* Verifying key for a function within an Aleo program\n*/\nclass VerifyingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(VerifyingKey.prototype);\n obj.__wbg_ptr = ptr;\n VerifyingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n VerifyingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_verifyingkey_free(ptr);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {VerifyingKey}\n */\n static bondPublicVerifier() {\n const ret = wasm.verifyingkey_bondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {VerifyingKey}\n */\n static bondValidatorVerifier() {\n const ret = wasm.verifyingkey_bondValidatorVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the claim_delegator function\n *\n * @returns {VerifyingKey} Verifying key for the claim_unbond_public function\n * @returns {VerifyingKey}\n */\n static claimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_claimUnbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_private function\n *\n * @returns {VerifyingKey} Verifying key for the fee_private function\n * @returns {VerifyingKey}\n */\n static feePrivateVerifier() {\n const ret = wasm.verifyingkey_feePrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_public function\n *\n * @returns {VerifyingKey} Verifying key for the fee_public function\n * @returns {VerifyingKey}\n */\n static feePublicVerifier() {\n const ret = wasm.verifyingkey_feePublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the inclusion function\n *\n * @returns {VerifyingKey} Verifying key for the inclusion function\n * @returns {VerifyingKey}\n */\n static inclusionVerifier() {\n const ret = wasm.verifyingkey_inclusionVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the join function\n *\n * @returns {VerifyingKey} Verifying key for the join function\n * @returns {VerifyingKey}\n */\n static joinVerifier() {\n const ret = wasm.verifyingkey_joinVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the set_validator_state function\n *\n * @returns {VerifyingKey} Verifying key for the set_validator_state function\n * @returns {VerifyingKey}\n */\n static setValidatorStateVerifier() {\n const ret = wasm.verifyingkey_setValidatorStateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the split function\n *\n * @returns {VerifyingKey} Verifying key for the split function\n * @returns {VerifyingKey}\n */\n static splitVerifier() {\n const ret = wasm.verifyingkey_splitVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private function\n * @returns {VerifyingKey}\n */\n static transferPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private_to_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private_to_public function\n * @returns {VerifyingKey}\n */\n static transferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_transferPrivateToPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public function\n * @returns {VerifyingKey}\n */\n static transferPublicVerifier() {\n const ret = wasm.verifyingkey_transferPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_as_signer function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_as_signer function\n * @returns {VerifyingKey}\n */\n static transferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_transferPublicAsSignerVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_to_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_to_private function\n * @returns {VerifyingKey}\n */\n static transferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPublicToPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the unbond_public function\n *\n * @returns {VerifyingKey} Verifying key for the unbond_public function\n * @returns {VerifyingKey}\n */\n static unbondPublicVerifier() {\n const ret = wasm.verifyingkey_unbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {boolean}\n */\n isBondPublicVerifier() {\n const ret = wasm.verifyingkey_isBondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {boolean}\n */\n isBondValidatorVerifier() {\n const ret = wasm.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the claim_delegator function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isClaimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePrivateVerifier() {\n const ret = wasm.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePublicVerifier() {\n const ret = wasm.verifyingkey_isFeePublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the inclusion function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isInclusionVerifier() {\n const ret = wasm.verifyingkey_isInclusionVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the join function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isJoinVerifier() {\n const ret = wasm.verifyingkey_isJoinVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the set_validator_state function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSetValidatorStateVerifier() {\n const ret = wasm.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the split function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSplitVerifier() {\n const ret = wasm.verifyingkey_isSplitVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private_to_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_as_signer function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_to_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the unbond_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get the checksum of the verifying key\n *\n * @returns {string} Checksum of the verifying key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the verifying key\n *\n * @returns {VerifyingKey} A copy of the verifying key\n * @returns {VerifyingKey}\n */\n copy() {\n const ret = wasm.verifyingkey_copy(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Construct a new verifying key from a byte array\n *\n * @param {Uint8Array} bytes Byte representation of a verifying key\n * @returns {VerifyingKey | Error}\n * @param {Uint8Array} bytes\n * @returns {VerifyingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a verifying key from string\n *\n * @param {String} string String representation of a verifying key\n * @returns {VerifyingKey | Error}\n * @param {string} string\n * @returns {VerifyingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a byte array from a verifying key\n *\n * @returns {Uint8Array | Error} Byte representation of a verifying key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the verifying key\n *\n * @returns {String} String representation of the verifying key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst ViewKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_viewkey_free(ptr >>> 0));\n/**\n*/\nclass ViewKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ViewKey.prototype);\n obj.__wbg_ptr = ptr;\n ViewKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ViewKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_viewkey_free(ptr);\n }\n /**\n * Create a new view key from a private key\n *\n * @param {PrivateKey} private_key Private key\n * @returns {ViewKey} View key\n * @param {PrivateKey} private_key\n * @returns {ViewKey}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.privatekey_to_view_key(private_key.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Create a new view key from a string representation of a view key\n *\n * @param {string} view_key String representation of a view key\n * @returns {ViewKey} View key\n * @param {string} view_key\n * @returns {ViewKey}\n */\n static from_string(view_key) {\n const ptr0 = passStringToWasm0(view_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.viewkey_from_string(ptr0, len0);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get a string representation of a view key\n *\n * @returns {string} String representation of a view key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.viewkey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the address corresponding to a view key\n *\n * @returns {Address} Address\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.address_from_view_key(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Decrypt a record ciphertext with a view key\n *\n * @param {string} ciphertext String representation of a record ciphertext\n * @returns {string} String representation of a record plaintext\n * @param {string} ciphertext\n * @returns {string}\n */\n decrypt(ciphertext) {\n let deferred3_0;\n let deferred3_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.viewkey_decrypt(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr2 = r0;\n var len2 = r1;\n if (r3) {\n ptr2 = 0; len2 = 0;\n throw takeObject(r2);\n }\n deferred3_0 = ptr2;\n deferred3_1 = len2;\n return getStringFromWasm0(ptr2, len2);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);\n }\n }\n}\n\nasync function __wbg_load(module, imports) {\n if (typeof Response === 'function' && module instanceof Response) {\n if (typeof WebAssembly.instantiateStreaming === 'function') {\n try {\n return await WebAssembly.instantiateStreaming(module, imports);\n\n } catch (e) {\n if (module.headers.get('Content-Type') != 'application/wasm') {\n console.warn(\"`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n\", e);\n\n } else {\n throw e;\n }\n }\n }\n\n const bytes = await module.arrayBuffer();\n return await WebAssembly.instantiate(bytes, imports);\n\n } else {\n const instance = await WebAssembly.instantiate(module, imports);\n\n if (instance instanceof WebAssembly.Instance) {\n return { instance, module };\n\n } else {\n return instance;\n }\n }\n}\n\nfunction __wbg_get_imports() {\n const imports = {};\n imports.wbg = {};\n imports.wbg.__wbindgen_object_drop_ref = function(arg0) {\n takeObject(arg0);\n };\n imports.wbg.__wbg_new_71801a555ad9f2aa = function() { return handleError(function () {\n const ret = new XMLHttpRequest();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_overrideMimeType_ee9c51919ceb418b = function() { return handleError(function (arg0, arg1, arg2) {\n getObject(arg0).overrideMimeType(getStringFromWasm0(arg1, arg2));\n }, arguments) };\n imports.wbg.__wbg_open_c9eb0cf2c9d95679 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {\n getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), arg5 !== 0);\n }, arguments) };\n imports.wbg.__wbg_send_80d29985093c1ec5 = function() { return handleError(function (arg0) {\n getObject(arg0).send();\n }, arguments) };\n imports.wbg.__wbg_response_7c2e2759084f7279 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).response;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_status_d485fb5a478426fb = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).status;\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_72fb9a18b5ae2624 = function() {\n const ret = new Object();\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_string_new = function(arg0, arg1) {\n const ret = getStringFromWasm0(arg0, arg1);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_1f9b04f170055d33 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_ab6fd82b10560829 = function() { return handleError(function () {\n const ret = new Headers();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_object_clone_ref = function(arg0) {\n const ret = getObject(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_0d76b0581eca6298 = function() { return handleError(function () {\n const ret = new AbortController();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_signal_a61f78a3478fd9bc = function(arg0) {\n const ret = getObject(arg0).signal;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_append_7bfcb4937d1d5e29 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {\n getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));\n }, arguments) };\n imports.wbg.__wbg_instanceof_Response_849eb93e75734b6e = function(arg0) {\n let result;\n try {\n result = getObject(arg0) instanceof Response;\n } catch (_) {\n result = false;\n }\n const ret = result;\n return ret;\n };\n imports.wbg.__wbg_status_61a01141acd3cf74 = function(arg0) {\n const ret = getObject(arg0).status;\n return ret;\n };\n imports.wbg.__wbg_url_5f6dc4009ac5f99d = function(arg0, arg1) {\n const ret = getObject(arg1).url;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_headers_9620bfada380764a = function(arg0) {\n const ret = getObject(arg0).headers;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_iterator_2cee6dadfd956dfa = function() {\n const ret = Symbol.iterator;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_get_e3c254076557e348 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.get(getObject(arg0), getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_function = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'function';\n return ret;\n };\n imports.wbg.__wbg_call_27c0f87801dedf93 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg0).call(getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_object = function(arg0) {\n const val = getObject(arg0);\n const ret = typeof(val) === 'object' && val !== null;\n return ret;\n };\n imports.wbg.__wbg_next_40fc327bfc8770e6 = function(arg0) {\n const ret = getObject(arg0).next;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_next_196c84450b364254 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).next();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_done_298b57d23c0fc80c = function(arg0) {\n const ret = getObject(arg0).done;\n return ret;\n };\n imports.wbg.__wbg_value_d93c65011f51a456 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_abort_2aa7521d5690750e = function(arg0) {\n getObject(arg0).abort();\n };\n imports.wbg.__wbg_stringify_8887fe74e1c50d81 = function() { return handleError(function (arg0) {\n const ret = JSON.stringify(getObject(arg0));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_string_get = function(arg0, arg1) {\n const obj = getObject(arg1);\n const ret = typeof(obj) === 'string' ? obj : undefined;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_log_0159ca40cddf5b15 = function(arg0, arg1) {\n console.log(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {\n const ret = BigInt.asUintN(64, arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_call_b3ca7c6051f9bec1 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_transaction_new = function(arg0) {\n const ret = Transaction.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_keypair_new = function(arg0) {\n const ret = KeyPair.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_module = function() {\n const ret = __wbg_init.__wbindgen_wasm_module;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_memory = function() {\n const ret = wasm.memory;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a = function(arg0, arg1, arg2, arg3) {\n const ret = spawnWorker(getObject(arg0), getObject(arg1), getObject(arg2), arg3 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_executionresponse_new = function(arg0) {\n const ret = ExecutionResponse.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_66ae46612e7f0234 = function(arg0) {\n const ret = new Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_d4638f722068f043 = function(arg0, arg1, arg2) {\n getObject(arg0)[arg1 >>> 0] = takeObject(arg2);\n };\n imports.wbg.__wbindgen_cb_drop = function(arg0) {\n const obj = takeObject(arg0).original;\n if (obj.cnt-- == 1) {\n obj.a = 0;\n return true;\n }\n const ret = false;\n return ret;\n };\n imports.wbg.__wbg_new_16b304a2cfa7ff4a = function() {\n const ret = new Array();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_push_a5b05aedc7234f9f = function(arg0, arg1) {\n const ret = getObject(arg0).push(getObject(arg1));\n return ret;\n };\n imports.wbg.__wbg_arrayBuffer_29931d52c7206b02 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).arrayBuffer();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_new_63b92bc8671ed464 = function(arg0) {\n const ret = new Uint8Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_c20a40f15020d68a = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_new_81740750da40724f = function(arg0, arg1) {\n try {\n var state0 = {a: arg0, b: arg1};\n var cb0 = (arg0, arg1) => {\n const a = state0.a;\n state0.a = 0;\n try {\n return __wbg_adapter_281(a, state0.b, arg0, arg1);\n } finally {\n state0.a = a;\n }\n };\n const ret = new Promise(cb0);\n return addHeapObject(ret);\n } finally {\n state0.a = state0.b = 0;\n }\n };\n imports.wbg.__wbindgen_number_new = function(arg0) {\n const ret = arg0;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_abda76e883ba8a5f = function() {\n const ret = new Error();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_stack_658279fe44541cf6 = function(arg0, arg1) {\n const ret = getObject(arg1).stack;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {\n let deferred0_0;\n let deferred0_1;\n try {\n deferred0_0 = arg0;\n deferred0_1 = arg1;\n console.error(getStringFromWasm0(arg0, arg1));\n } finally {\n wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);\n }\n };\n imports.wbg.__wbg_buffer_12d079cc21e14bdb = function(arg0) {\n const ret = getObject(arg0).buffer;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb = function(arg0, arg1, arg2) {\n const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_randomFillSync_5c9c955aa56b6049 = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).randomFillSync(takeObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_subarray_a1f73cd4b5b42fe1 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_getRandomValues_3aa56aa6edec874c = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).getRandomValues(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_set_a47bac70306a19a7 = function(arg0, arg1, arg2) {\n getObject(arg0).set(getObject(arg1), arg2 >>> 0);\n };\n imports.wbg.__wbg_crypto_1d1f22824a6a080c = function(arg0) {\n const ret = getObject(arg0).crypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_process_4a72847cc503995b = function(arg0) {\n const ret = getObject(arg0).process;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_versions_f686565e586dd935 = function(arg0) {\n const ret = getObject(arg0).versions;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_node_104a2ff8d6ea03a2 = function(arg0) {\n const ret = getObject(arg0).node;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_is_string = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'string';\n return ret;\n };\n imports.wbg.__wbg_require_cca90b1a94a0255b = function() { return handleError(function () {\n const ret = module.require;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_msCrypto_eb05e62b530a1508 = function(arg0) {\n const ret = getObject(arg0).msCrypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_e9b4878cebadb3d3 = function(arg0) {\n const ret = new Uint8Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_cd7af8117672b8b8 = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_get_bd8e338fbd5f5cc8 = function(arg0, arg1) {\n const ret = getObject(arg0)[arg1 >>> 0];\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_self_ce0dbfc45cf2f5be = function() { return handleError(function () {\n const ret = self.self;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_window_c6fb939a7f436783 = function() { return handleError(function () {\n const ret = window.window;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_globalThis_d1e6af4856ba331b = function() { return handleError(function () {\n const ret = globalThis.globalThis;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_global_207b558942527489 = function() { return handleError(function () {\n const ret = global.global;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_undefined = function(arg0) {\n const ret = getObject(arg0) === undefined;\n return ret;\n };\n imports.wbg.__wbg_newnoargs_e258087cd0daa0ea = function(arg0, arg1) {\n const ret = new Function(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_has_0af94d20077affa2 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.has(getObject(arg0), getObject(arg1));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_fetch_bc7c8e27076a5c84 = function(arg0) {\n const ret = fetch(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_fetch_921fad6ef9e883dd = function(arg0, arg1) {\n const ret = getObject(arg0).fetch(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {\n const ret = debugString(getObject(arg1));\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbindgen_throw = function(arg0, arg1) {\n throw new Error(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_rethrow = function(arg0) {\n throw takeObject(arg0);\n };\n imports.wbg.__wbg_then_a73caa9a87991566 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_then_0c86a60e8fcfe9f6 = function(arg0, arg1) {\n const ret = getObject(arg0).then(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_queueMicrotask_481971b0d87f3dd4 = function(arg0) {\n queueMicrotask(getObject(arg0));\n };\n imports.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6 = function(arg0) {\n const ret = getObject(arg0).queueMicrotask;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_resolve_b0083a7967828ec8 = function(arg0) {\n const ret = Promise.resolve(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_5d743fc9058ba01a = function() {\n const ret = Atomics.waitAsync;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_8cccba86b0f574cb = function(arg0) {\n const ret = new Int32Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_46d5c36955b71a79 = function(arg0, arg1, arg2) {\n const ret = Atomics.waitAsync(getObject(arg0), arg1, arg2);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_async_19c0400d97cc72fe = function(arg0) {\n const ret = getObject(arg0).async;\n return ret;\n };\n imports.wbg.__wbg_value_571d60108110e917 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_link_fc1eedd35dc7e0a6 = function(arg0) {\n const ret = \"data:application/javascript,\" + encodeURIComponent(`onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n `);\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_new_d1187ae36d662ef9 = function() { return handleError(function (arg0, arg1) {\n const ret = new Worker(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_setonmessage_503809e5bb51bd33 = function(arg0, arg1) {\n getObject(arg0).onmessage = getObject(arg1);\n };\n imports.wbg.__wbg_of_6a70eed8d41f469c = function(arg0, arg1, arg2) {\n const ret = Array.of(getObject(arg0), getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_postMessage_7380d10e8b8269df = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).postMessage(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_data_3ce7c145ca4fbcdc = function(arg0) {\n const ret = getObject(arg0).data;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_responseText_c67ed2d48db10769 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg1).responseText;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n }, arguments) };\n imports.wbg.__wbindgen_closure_wrapper5837 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 538, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_closure_wrapper5862 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 538, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n\n return imports;\n}\n\nfunction __wbg_init_memory(imports, maybe_memory) {\n imports.wbg.memory = maybe_memory || new WebAssembly.Memory({initial:25,maximum:65536,shared:true});\n}\n\nfunction __wbg_finalize_init(instance, module) {\n wasm = instance.exports;\n __wbg_init.__wbindgen_wasm_module = module;\n cachedBigInt64Memory0 = null;\n cachedInt32Memory0 = null;\n cachedUint8Memory0 = null;\n\n wasm.__wbindgen_start();\n return wasm;\n}\n\nfunction initSync(module, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n const imports = __wbg_get_imports();\n\n __wbg_init_memory(imports, maybe_memory);\n\n if (!(module instanceof WebAssembly.Module)) {\n module = new WebAssembly.Module(module);\n }\n\n const instance = new WebAssembly.Instance(module, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nasync function __wbg_init(input, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n\n const imports = __wbg_get_imports();\n\n if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {\n input = fetch(input);\n }\n\n __wbg_init_memory(imports, maybe_memory);\n\n const { instance, module } = await __wbg_load(await input, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nvar exports = /*#__PURE__*/Object.freeze({\n __proto__: null,\n Address: Address,\n Execution: Execution,\n ExecutionResponse: ExecutionResponse,\n Field: Field,\n KeyPair: KeyPair,\n Metadata: Metadata,\n OfflineQuery: OfflineQuery,\n PrivateKey: PrivateKey,\n PrivateKeyCiphertext: PrivateKeyCiphertext,\n Program: Program,\n ProgramManager: ProgramManager,\n ProvingKey: ProvingKey,\n RecordCiphertext: RecordCiphertext,\n RecordPlaintext: RecordPlaintext,\n Signature: Signature,\n Transaction: Transaction,\n VerifyingKey: VerifyingKey,\n ViewKey: ViewKey,\n default: __wbg_init,\n initSync: initSync,\n initThreadPool: initThreadPool,\n runRayonThread: runRayonThread,\n verifyFunctionExecution: verifyFunctionExecution\n});\n\nconst wasm_path = \"assets/aleo_wasm.wasm\";\n\n \n var Cargo = async (opt = {}) => {\n let {importHook, serverPath, initializeHook} = opt;\n\n let final_path = wasm_path;\n\n if (serverPath != null) {\n final_path = serverPath + /[^\\/\\\\]*$/.exec(final_path)[0];\n }\n\n if (importHook != null) {\n final_path = importHook(final_path);\n }\n\n if (initializeHook != null) {\n await initializeHook(__wbg_init, final_path);\n\n } else {\n await __wbg_init(final_path);\n }\n\n return exports;\n };\n\nexport { Cargo as default };\n//# sourceMappingURL=wasm.js.map\n","import wasm from \"../dist/wasm.js\";\n\nconst {\n initThreadPool: wasmInitThreadPool,\n Address,\n Execution,\n ExecutionResponse,\n Field,\n Metadata,\n OfflineQuery,\n Private,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n ProgramManager,\n Signature,\n Transaction,\n ViewKey,\n VerifyingKey,\n verifyFunctionExecution,\n} = await wasm({\n importHook: () => {\n return new URL(\"assets/aleo_wasm.wasm\", import.meta.url);\n },\n});\n\nasync function initThreadPool(threads) {\n if (threads == null) {\n threads = navigator.hardwareConcurrency;\n }\n\n console.info(`Spawning ${threads} threads`);\n\n await wasmInitThreadPool(new URL(\"worker.js\", import.meta.url), threads);\n}\n\nexport {\n initThreadPool,\n Address,\n Execution,\n ExecutionResponse,\n Field,\n Metadata,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n ProgramManager,\n Signature,\n Transaction,\n ViewKey,\n VerifyingKey,\n verifyFunctionExecution,\n};\n"],"names":["spawnWorker","url","module","memory","address","Promise","resolve","worker","Worker","type","addEventListener","event","setTimeout","unref","capture","once","postMessage","wasm","heap","Array","fill","undefined","getObject","idx","push","heap_next","length","dropObject","takeObject","ret","cachedTextDecoder","TextDecoder","ignoreBOM","fatal","decode","Error","cachedUint8Memory0","getUint8Memory0","buffer","Uint8Array","getStringFromWasm0","ptr","len","slice","addHeapObject","obj","WASM_VECTOR_LEN","cachedTextEncoder","TextEncoder","encode","encodeString","arg","view","buf","set","read","written","passStringToWasm0","malloc","realloc","subarray","mem","offset","code","charCodeAt","isLikeNone","x","cachedInt32Memory0","getInt32Memory0","Int32Array","debugString","val","description","name","isArray","debug","i","builtInMatches","exec","toString","call","className","JSON","stringify","_","message","stack","CLOSURE_DTORS","FinalizationRegistry","register","unregister","state","__wbindgen_export_3","get","dtor","a","b","makeMutClosure","arg0","arg1","f","cnt","real","args","original","__wbg_adapter_34","arg2","_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3","_assertClass","instance","klass","passArray8ToWasm0","verifyFunctionExecution$1","execution","verifying_key","program","function_id","retptr","__wbindgen_add_to_stack_pointer","Execution$1","VerifyingKey$1","Program$1","ptr0","__wbindgen_malloc","__wbindgen_realloc","len0","verifyFunctionExecution","__wbg_ptr","r0","r1","cachedBigInt64Memory0","getBigInt64Memory0","BigInt64Array","getArrayU8FromWasm0","runRayonThread","receiver","initThreadPool$1","num_threads","initThreadPool","handleError","apply","this","e","__wbindgen_exn_store","__wbg_adapter_281","arg3","wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7","AddressFinalization","__wbg_address_free","Address","__wrap","Object","create","prototype","__destroy_into_raw","free","from_private_key","private_key","PrivateKey$1","address_from_private_key","from_view_key","view_key","ViewKey$1","address_from_view_key","from_string","address_from_string","to_string","deferred1_0","deferred1_1","address_to_string","__wbindgen_free","verify","signature","Signature$1","address_verify","ExecutionFinalization","__wbg_execution_free","Execution","execution_toString","fromString","execution_fromString","ExecutionResponseFinalization","__wbg_executionresponse_free","ExecutionResponse","getOutputs","executionresponse_getOutputs","getExecution","executionresponse_getExecution","getKeys","executionresponse_getKeys","KeyPair","getProvingKey","executionresponse_getProvingKey","ProvingKey$1","getVerifyingKey","executionresponse_getVerifyingKey","getFunctionId","executionresponse_getFunctionId","getProgram","executionresponse_getProgram","FieldFinalization","__wbg_field_free","Field","field_toString","field","field_fromString","KeyPairFinalization","__wbg_keypair_free","constructor","proving_key","ptr1","keypair_new","provingKey","keypair_provingKey","verifyingKey","keypair_verifyingKey","MetadataFinalization","__wbg_metadata_free","Metadata","__wbg_get_metadata_name","__wbg_set_metadata_name","locator","__wbg_get_metadata_locator","__wbg_set_metadata_locator","prover","__wbg_get_metadata_prover","__wbg_set_metadata_prover","verifier","__wbg_get_metadata_verifier","__wbg_set_metadata_verifier","__wbg_get_metadata_verifyingKey","__wbg_set_metadata_verifyingKey","baseUrl","metadata_baseUrl","bond_public","metadata_bond_public","bond_validator","metadata_bond_validator","claim_unbond_public","metadata_claim_unbond_public","fee_private","metadata_fee_private","fee_public","metadata_fee_public","inclusion","metadata_inclusion","join","metadata_join","set_validator_state","metadata_set_validator_state","split","metadata_split","transfer_private","metadata_transfer_private","transfer_private_to_public","metadata_transfer_private_to_public","transfer_public","metadata_transfer_public","transfer_public_as_signer","metadata_transfer_public_as_signer","transfer_public_to_private","metadata_transfer_public_to_private","unbond_public","metadata_unbond_public","OfflineQueryFinalization","__wbg_offlinequery_free","OfflineQuery","state_root","offlinequery_new","addStatePath","commitment","state_path","len1","offlinequery_addStatePath","offlinequery_toString","s","offlinequery_fromString","PrivateKeyFinalization","__wbg_privatekey_free","PrivateKey","privatekey_new","from_seed_unchecked","seed","privatekey_from_seed_unchecked","privatekey_from_string","privatekey_to_string","to_view_key","privatekey_to_view_key","to_address","privatekey_to_address","Address$1","sign","privatekey_sign","newEncrypted","secret","privatekey_newEncrypted","PrivateKeyCiphertext$1","toCiphertext","privatekey_toCiphertext","fromPrivateKeyCiphertext","ciphertext","privatekey_fromPrivateKeyCiphertext","PrivateKeyCiphertextFinalization","__wbg_privatekeyciphertext_free","PrivateKeyCiphertext","encryptPrivateKey","decryptToPrivateKey","privatekeyciphertext_decryptToPrivateKey","privatekeyciphertext_toString","privatekeyciphertext_fromString","ProgramFinalization","__wbg_program_free","Program","program_fromString","program_toString","hasFunction","function_name","program_hasFunction","getFunctions","program_getFunctions","getFunctionInputs","program_getFunctionInputs","getMappings","program_getMappings","getRecordMembers","record_name","program_getRecordMembers","getStructMembers","struct_name","program_getStructMembers","getCreditsProgram","program_getCreditsProgram","id","program_id","program_address","isEqual","other","program_isEqual","getImports","program_getImports","ProgramManagerFinalization","__wbg_programmanager_free","buildDeploymentTransaction","fee_credits","fee_record","imports","fee_proving_key","fee_verifying_key","offline_query","RecordPlaintext$1","ptr2","len2","ptr3","ptr4","ptr5","OfflineQuery$1","programmanager_buildDeploymentTransaction","estimateDeploymentFee","programmanager_estimateDeploymentFee","estimateProgramNameCost","programmanager_estimateProgramNameCost","r2","BigInt","asUintN","executeFunctionOffline","_function","inputs","prove_execution","cache","len4","programmanager_executeFunctionOffline","buildExecutionTransaction","len3","ptr6","ptr7","ptr8","programmanager_buildExecutionTransaction","estimateExecutionFee","programmanager_estimateExecutionFee","estimateFinalizeFee","programmanager_estimateFinalizeFee","buildJoinTransaction","record_1","record_2","join_proving_key","join_verifying_key","programmanager_buildJoinTransaction","buildSplitTransaction","split_amount","amount_record","split_proving_key","split_verifying_key","programmanager_buildSplitTransaction","buildTransferTransaction","amount_credits","recipient","transfer_type","transfer_proving_key","transfer_verifying_key","ptr9","programmanager_buildTransferTransaction","synthesizeKeyPair","programmanager_synthesizeKeyPair","ProvingKeyFinalization","__wbg_provingkey_free","ProvingKey","isBondPublicProver","provingkey_isBondPublicProver","isBondValidatorProver","provingkey_isBondValidatorProver","isClaimUnbondPublicProver","provingkey_isClaimUnbondPublicProver","isFeePrivateProver","provingkey_isFeePrivateProver","isFeePublicProver","provingkey_isFeePublicProver","isInclusionProver","provingkey_isInclusionProver","isJoinProver","provingkey_isJoinProver","isSetValidatorStateProver","provingkey_isSetValidatorStateProver","isSplitProver","provingkey_isSplitProver","isTransferPrivateProver","provingkey_isTransferPrivateProver","isTransferPrivateToPublicProver","provingkey_isTransferPrivateToPublicProver","isTransferPublicProver","provingkey_isTransferPublicProver","isTransferPublicAsSignerProver","provingkey_isTransferPublicAsSignerProver","isTransferPublicToPrivateProver","provingkey_isTransferPublicToPrivateProver","isUnbondPublicProver","provingkey_isUnbondPublicProver","checksum","provingkey_checksum","copy","provingkey_copy","fromBytes","bytes","provingkey_fromBytes","string","provingkey_fromString","toBytes","provingkey_toBytes","v1","provingkey_toString","RecordCiphertextFinalization","__wbg_recordciphertext_free","RecordCiphertext","record","recordciphertext_fromString","recordciphertext_toString","decrypt","recordciphertext_decrypt","isOwner","recordciphertext_isOwner","RecordPlaintextFinalization","__wbg_recordplaintext_free","RecordPlaintext","recordplaintext_commitment","Field$1","recordplaintext_fromString","recordplaintext_toString","microcredits","recordplaintext_microcredits","nonce","recordplaintext_nonce","serialNumberString","deferred4_0","deferred4_1","recordplaintext_serialNumberString","r3","SignatureFinalization","__wbg_signature_free","Signature","signature_verify","signature_from_string","signature_to_string","TransactionFinalization","__wbg_transaction_free","Transaction","transaction","transaction_fromString","transaction_toString","transactionId","transaction_transactionId","transactionType","transaction_transactionType","VerifyingKeyFinalization","__wbg_verifyingkey_free","VerifyingKey","bondPublicVerifier","verifyingkey_bondPublicVerifier","bondValidatorVerifier","verifyingkey_bondValidatorVerifier","claimUnbondPublicVerifier","verifyingkey_claimUnbondPublicVerifier","feePrivateVerifier","verifyingkey_feePrivateVerifier","feePublicVerifier","verifyingkey_feePublicVerifier","inclusionVerifier","verifyingkey_inclusionVerifier","joinVerifier","verifyingkey_joinVerifier","setValidatorStateVerifier","verifyingkey_setValidatorStateVerifier","splitVerifier","verifyingkey_splitVerifier","transferPrivateVerifier","verifyingkey_transferPrivateVerifier","transferPrivateToPublicVerifier","verifyingkey_transferPrivateToPublicVerifier","transferPublicVerifier","verifyingkey_transferPublicVerifier","transferPublicAsSignerVerifier","verifyingkey_transferPublicAsSignerVerifier","transferPublicToPrivateVerifier","verifyingkey_transferPublicToPrivateVerifier","unbondPublicVerifier","verifyingkey_unbondPublicVerifier","isBondPublicVerifier","verifyingkey_isBondPublicVerifier","isBondValidatorVerifier","verifyingkey_isBondValidatorVerifier","isClaimUnbondPublicVerifier","verifyingkey_isClaimUnbondPublicVerifier","isFeePrivateVerifier","verifyingkey_isFeePrivateVerifier","isFeePublicVerifier","verifyingkey_isFeePublicVerifier","isInclusionVerifier","verifyingkey_isInclusionVerifier","isJoinVerifier","verifyingkey_isJoinVerifier","isSetValidatorStateVerifier","verifyingkey_isSetValidatorStateVerifier","isSplitVerifier","verifyingkey_isSplitVerifier","isTransferPrivateVerifier","verifyingkey_isTransferPrivateVerifier","isTransferPrivateToPublicVerifier","verifyingkey_isTransferPrivateToPublicVerifier","isTransferPublicVerifier","verifyingkey_isTransferPublicVerifier","isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicAsSignerVerifier","isTransferPublicToPrivateVerifier","verifyingkey_isTransferPublicToPrivateVerifier","isUnbondPublicVerifier","verifyingkey_isUnbondPublicVerifier","verifyingkey_checksum","verifyingkey_copy","verifyingkey_fromBytes","verifyingkey_fromString","verifyingkey_toBytes","verifyingkey_toString","ViewKeyFinalization","__wbg_viewkey_free","ViewKey","viewkey_from_string","viewkey_to_string","deferred3_0","deferred3_1","viewkey_decrypt","async","__wbg_load","Response","WebAssembly","instantiateStreaming","headers","console","warn","arrayBuffer","instantiate","Instance","__wbg_get_imports","wbg","__wbindgen_object_drop_ref","__wbg_new_71801a555ad9f2aa","XMLHttpRequest","arguments","__wbg_overrideMimeType_ee9c51919ceb418b","overrideMimeType","__wbg_open_c9eb0cf2c9d95679","arg4","arg5","open","__wbg_send_80d29985093c1ec5","send","__wbg_response_7c2e2759084f7279","response","__wbg_status_d485fb5a478426fb","status","__wbg_new_72fb9a18b5ae2624","__wbindgen_string_new","__wbg_set_1f9b04f170055d33","Reflect","__wbg_new_ab6fd82b10560829","Headers","__wbindgen_object_clone_ref","__wbg_new_0d76b0581eca6298","AbortController","__wbg_signal_a61f78a3478fd9bc","signal","__wbg_append_7bfcb4937d1d5e29","append","__wbg_instanceof_Response_849eb93e75734b6e","result","__wbg_status_61a01141acd3cf74","__wbg_url_5f6dc4009ac5f99d","__wbg_headers_9620bfada380764a","__wbg_iterator_2cee6dadfd956dfa","Symbol","iterator","__wbg_get_e3c254076557e348","__wbindgen_is_function","__wbg_call_27c0f87801dedf93","__wbindgen_is_object","__wbg_next_40fc327bfc8770e6","next","__wbg_next_196c84450b364254","__wbg_done_298b57d23c0fc80c","done","__wbg_value_d93c65011f51a456","value","__wbg_abort_2aa7521d5690750e","abort","__wbg_stringify_8887fe74e1c50d81","__wbindgen_string_get","__wbg_log_0159ca40cddf5b15","log","__wbindgen_bigint_from_u64","__wbg_call_b3ca7c6051f9bec1","__wbg_transaction_new","Transaction$1","__wbg_keypair_new","__wbindgen_module","__wbg_init","__wbindgen_wasm_module","__wbindgen_memory","__wbg_spawnWorker_f6acaddb2e29dc4a","__wbg_executionresponse_new","ExecutionResponse$1","__wbg_newwithlength_66ae46612e7f0234","__wbg_set_d4638f722068f043","__wbindgen_cb_drop","__wbg_new_16b304a2cfa7ff4a","__wbg_push_a5b05aedc7234f9f","__wbg_arrayBuffer_29931d52c7206b02","__wbg_new_63b92bc8671ed464","__wbg_length_c20a40f15020d68a","__wbg_new_81740750da40724f","state0","cb0","__wbindgen_number_new","__wbg_new_abda76e883ba8a5f","__wbg_stack_658279fe44541cf6","__wbg_error_f851667af71bcfc6","deferred0_0","deferred0_1","error","__wbg_buffer_12d079cc21e14bdb","__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb","__wbg_randomFillSync_5c9c955aa56b6049","randomFillSync","__wbg_subarray_a1f73cd4b5b42fe1","__wbg_getRandomValues_3aa56aa6edec874c","getRandomValues","__wbg_set_a47bac70306a19a7","__wbg_crypto_1d1f22824a6a080c","crypto","__wbg_process_4a72847cc503995b","process","__wbg_versions_f686565e586dd935","versions","__wbg_node_104a2ff8d6ea03a2","node","__wbindgen_is_string","__wbg_require_cca90b1a94a0255b","require","__wbg_msCrypto_eb05e62b530a1508","msCrypto","__wbg_newwithlength_e9b4878cebadb3d3","__wbg_length_cd7af8117672b8b8","__wbg_get_bd8e338fbd5f5cc8","__wbg_self_ce0dbfc45cf2f5be","self","__wbg_window_c6fb939a7f436783","window","__wbg_globalThis_d1e6af4856ba331b","globalThis","__wbg_global_207b558942527489","global","__wbindgen_is_undefined","__wbg_newnoargs_e258087cd0daa0ea","Function","__wbg_has_0af94d20077affa2","has","__wbg_fetch_bc7c8e27076a5c84","fetch","__wbg_fetch_921fad6ef9e883dd","__wbindgen_debug_string","__wbindgen_throw","__wbindgen_rethrow","__wbg_then_a73caa9a87991566","then","__wbg_then_0c86a60e8fcfe9f6","__wbg_queueMicrotask_481971b0d87f3dd4","queueMicrotask","__wbg_queueMicrotask_3cbae2ec6b6cd3d6","__wbg_resolve_b0083a7967828ec8","__wbg_waitAsync_5d743fc9058ba01a","Atomics","waitAsync","__wbg_new_8cccba86b0f574cb","__wbg_waitAsync_46d5c36955b71a79","__wbg_async_19c0400d97cc72fe","__wbg_value_571d60108110e917","__wbindgen_link_fc1eedd35dc7e0a6","encodeURIComponent","__wbg_new_d1187ae36d662ef9","__wbg_setonmessage_503809e5bb51bd33","onmessage","__wbg_of_6a70eed8d41f469c","of","__wbg_postMessage_7380d10e8b8269df","__wbg_data_3ce7c145ca4fbcdc","data","__wbg_newwithstrandinit_3fd6fba4083ff2d0","Request","__wbg_responseText_c67ed2d48db10769","responseText","__wbindgen_closure_wrapper5837","__wbindgen_closure_wrapper5862","__wbg_init_memory","maybe_memory","Memory","initial","maximum","shared","__wbg_finalize_init","exports","__wbindgen_start","initSync","Module","input","URL","freeze","__proto__","Metadata$1","ProgramManager","ProgramManager$1","RecordCiphertext$1","default","wasm_path","wasmInitThreadPool","Private","opt","importHook","serverPath","initializeHook","final_path","Cargo","threads","navigator","hardwareConcurrency","info"],"sourceRoot":""} \ No newline at end of file diff --git a/879.bundle.js b/879.bundle.js deleted file mode 100644 index 1d57c8d8a..000000000 --- a/879.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[879],{2851:(_,t,e)=>{_.exports=e.p+"ed5d9d6957e80846ebe2.js"},6545:(_,t,e)=>{_.exports=e.p+"210d0782d748f9305082.wasm"},9879:(_,t,e)=>{e.a(_,(async(_,r)=>{try{function i(_,t,e,r){return new Promise((n=>{const i=new Worker(_,{type:"module"});i.addEventListener("message",(_=>{setTimeout((()=>{n(i),i.unref&&i.unref()}),0)}),{capture:!0,once:!0}),i.postMessage({module:t,memory:e,address:r})}))}let o;e.d(t,{$7:()=>B_,Ao:()=>q_,BP:()=>M_,Fs:()=>L_,KC:()=>U_,OS:()=>O_,Yc:()=>J_,ZD:()=>C_,ZF:()=>I_,ZX:()=>$_,pF:()=>D_});const a=new Array(128).fill(void 0);function s(_){return a[_]}a.push(void 0,null,!0,!1);let c=a.length;function g(_){_<132||(a[_]=c,c=_)}function w(_){const t=s(_);return g(_),t}const d="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&d.decode();let b=null;function l(){return null!==b&&b.buffer===o.memory.buffer||(b=new Uint8Array(o.memory.buffer)),b}function u(_,t){return _>>>=0,d.decode(l().slice(_,_+t))}function f(_){c===a.length&&a.push(a.length+1);const t=c;return c=a[t],a[t]=_,t}let p=0;const y="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},m=function(_,t){const e=y.encode(_);return t.set(e),{read:_.length,written:e.length}};function h(_,t,e){if(void 0===e){const e=y.encode(_),r=t(e.length,1)>>>0;return l().subarray(r,r+e.length).set(e),p=e.length,r}let r=_.length,n=t(r,1)>>>0;const i=l();let o=0;for(;o127)break;i[n+o]=t}if(o!==r){0!==o&&(_=_.slice(o)),n=e(n,r,r=o+3*_.length,1)>>>0;const t=l().subarray(n+o,n+r);o+=m(_,t).written,n=e(n,r,o,1)>>>0}return p=o,n}function v(_){return null==_}let k=null;function P(){return null!==k&&k.buffer===o.memory.buffer||(k=new Int32Array(o.memory.buffer)),k}function S(_){const t=typeof _;if("number"==t||"boolean"==t||null==_)return`${_}`;if("string"==t)return`"${_}"`;if("symbol"==t){const t=_.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=_.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(_)){const t=_.length;let e="[";t>0&&(e+=S(_[0]));for(let r=1;r1))return toString.call(_);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(_)+")"}catch(_){return"Object"}return _ instanceof Error?`${_.name}: ${_.message}\n${_.stack}`:r}const x="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>{o.__wbindgen_export_3.get(_.dtor)(_.a,_.b)}));function V(_,t,e,r){const n={a:_,b:t,cnt:1,dtor:e},i=(..._)=>{n.cnt++;const t=n.a;n.a=0;try{return r(t,n.b,..._)}finally{0==--n.cnt?(o.__wbindgen_export_3.get(n.dtor)(t,n.b),x.unregister(n)):n.a=t}};return i.original=n,x.register(i,n,n),i}function F(_,t,e){o._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha51b8a0cd6570266(_,t,f(e))}function T(_,t){if(!(_ instanceof t))throw new Error(`expected instance of ${t.name}`);return _.ptr}function R(_,t){const e=t(1*_.length,1)>>>0;return l().set(_,e/1),p=_.length,e}function z(_,t,e,r){try{const a=o.__wbindgen_add_to_stack_pointer(-16);T(_,q),T(t,p_),T(e,r_);const s=h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.verifyFunctionExecution(a,_.__wbg_ptr,t.__wbg_ptr,e.__wbg_ptr,s,c);var n=P()[a/4+0],i=P()[a/4+1];if(P()[a/4+2])throw w(i);return 0!==n}finally{o.__wbindgen_add_to_stack_pointer(16)}}let A=null;function O(){return null!==A&&A.buffer===o.memory.buffer||(A=new BigInt64Array(o.memory.buffer)),A}function j(_,t){return _>>>=0,l().subarray(_/1,_/1+t)}function K(_){o.runRayonThread(_)}function C(_,t){return w(o.initThreadPool(f(_),t))}function E(_,t){try{return _.apply(this,t)}catch(_){o.__wbindgen_exn_store(f(_))}}function M(_,t,e,r){o.wasm_bindgen__convert__closures__invoke2_mut__h823ad1ce2c4b384e(_,t,f(e),f(r))}const B="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_address_free(_>>>0)));let U=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,B.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,B.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_address_free(_)}static from_private_key(t){T(t,G);const e=o.address_from_private_key(t.__wbg_ptr);return _.__wrap(e)}static from_view_key(t){T(t,m_);const e=o.address_from_view_key(t.__wbg_ptr);return _.__wrap(e)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.address_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.address_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}verify(_,t){const e=R(_,o.__wbindgen_malloc),r=p;T(t,b_);return 0!==o.address_verify(this.__wbg_ptr,e,r,t.__wbg_ptr)}};const I="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_execution_free(_>>>0)));let q=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,I.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,I.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_execution_free(_)}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.execution_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.execution_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const W="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_executionresponse_free(_>>>0)));let $=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,W.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,W.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_executionresponse_free(_)}getOutputs(){return w(o.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const _=o.executionresponse_getExecution(this.__wbg_ptr);return 0===_?void 0:q.__wrap(_)}getKeys(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.executionresponse_getKeys(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return L.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const _=o.executionresponse_getProvingKey(this.__wbg_ptr);return 0===_?void 0:a_.__wrap(_)}getVerifyingKey(){const _=o.executionresponse_getVerifyingKey(this.__wbg_ptr);return p_.__wrap(_)}getFunctionId(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.executionresponse_getFunctionId(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}getProgram(){const _=o.executionresponse_getProgram(this.__wbg_ptr);return r_.__wrap(_)}};const N="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_field_free(_>>>0)));let D=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,N.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,N.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_field_free(_)}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.field_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.field_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const J="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_keypair_free(_>>>0)));class L{static __wrap(_){_>>>=0;const t=Object.create(L.prototype);return t.__wbg_ptr=_,J.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,J.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_keypair_free(_)}constructor(_,t){T(_,a_);var e=_.__destroy_into_raw();T(t,p_);var r=t.__destroy_into_raw();const n=o.keypair_new(e,r);return this.__wbg_ptr=n>>>0,this}provingKey(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.keypair_provingKey(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return a_.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.keypair_verifyingKey(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return p_.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}}const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_metadata_free(_>>>0)));let Z=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,H.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_metadata_free(_)}get name(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_name(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set name(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_name(this.__wbg_ptr,t,e)}get locator(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_locator(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set locator(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_locator(this.__wbg_ptr,t,e)}get prover(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_prover(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set prover(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_prover(this.__wbg_ptr,t,e)}get verifier(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_verifier(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set verifier(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_verifier(this.__wbg_ptr,t,e)}get verifyingKey(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.__wbg_get_metadata_verifyingKey(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}set verifyingKey(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;o.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,t,e)}static baseUrl(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.metadata_baseUrl(n);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static bond_public(){const t=o.metadata_bond_public();return _.__wrap(t)}static bond_validator(){const t=o.metadata_bond_validator();return _.__wrap(t)}static claim_unbond_public(){const t=o.metadata_claim_unbond_public();return _.__wrap(t)}static fee_private(){const t=o.metadata_fee_private();return _.__wrap(t)}static fee_public(){const t=o.metadata_fee_public();return _.__wrap(t)}static inclusion(){const t=o.metadata_inclusion();return _.__wrap(t)}static join(){const t=o.metadata_join();return _.__wrap(t)}static set_validator_state(){const t=o.metadata_set_validator_state();return _.__wrap(t)}static split(){const t=o.metadata_split();return _.__wrap(t)}static transfer_private(){const t=o.metadata_transfer_private();return _.__wrap(t)}static transfer_private_to_public(){const t=o.metadata_transfer_private_to_public();return _.__wrap(t)}static transfer_public(){const t=o.metadata_transfer_public();return _.__wrap(t)}static transfer_public_as_signer(){const t=o.metadata_transfer_public_as_signer();return _.__wrap(t)}static transfer_public_to_private(){const t=o.metadata_transfer_public_to_private();return _.__wrap(t)}static unbond_public(){const t=o.metadata_unbond_public();return _.__wrap(t)}};const Q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_offlinequery_free(_>>>0)));let X=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,Q.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Q.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_offlinequery_free(_)}constructor(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.offlinequery_new(r,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return this.__wbg_ptr=t>>>0,this}finally{o.__wbindgen_add_to_stack_pointer(16)}}addStatePath(_,t){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p,a=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.offlinequery_addStatePath(r,this.__wbg_ptr,n,i,a,s);var e=P()[r/4+0];if(P()[r/4+1])throw w(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.offlinequery_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.offlinequery_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const Y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_privatekey_free(_>>>0)));let G=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,Y.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Y.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_privatekey_free(_)}constructor(){const _=o.privatekey_new();return this.__wbg_ptr=_>>>0,this}static from_seed_unchecked(t){const e=R(t,o.__wbindgen_malloc),r=p,n=o.privatekey_from_seed_unchecked(e,r);return _.__wrap(n)}static from_string(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.privatekey_from_string(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.privatekey_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}to_view_key(){const _=o.privatekey_to_view_key(this.__wbg_ptr);return m_.__wrap(_)}to_address(){const _=o.privatekey_to_address(this.__wbg_ptr);return U.__wrap(_)}sign(_){const t=R(_,o.__wbindgen_malloc),e=p,r=o.privatekey_sign(this.__wbg_ptr,t,e);return b_.__wrap(r)}static newEncrypted(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekey_newEncrypted(r,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return t_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekey_toCiphertext(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return t_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,e){try{const i=o.__wbindgen_add_to_stack_pointer(-16);T(t,t_);const a=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.privatekey_fromPrivateKeyCiphertext(i,t.__wbg_ptr,a,s);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw w(n);return _.__wrap(r)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const __="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_privatekeyciphertext_free(_>>>0)));let t_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,__.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,__.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_privatekeyciphertext_free(_)}static encryptPrivateKey(t,e){try{const i=o.__wbindgen_add_to_stack_pointer(-16);T(t,G);const a=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),s=p;o.privatekey_toCiphertext(i,t.__wbg_ptr,a,s);var r=P()[i/4+0],n=P()[i/4+1];if(P()[i/4+2])throw w(n);return _.__wrap(r)}finally{o.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.privatekeyciphertext_decryptToPrivateKey(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return G.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.privatekeyciphertext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.privatekeyciphertext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}};const e_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_program_free(_>>>0)));let r_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,e_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,e_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_program_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.program_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.program_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}hasFunction(_){const t=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;return 0!==o.program_hasFunction(this.__wbg_ptr,t,e)}getFunctions(){return w(o.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getFunctionInputs(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.program_getMappings(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return w(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getRecordMembers(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.program_getStructMembers(r,this.__wbg_ptr,n,i);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=o.program_getCreditsProgram();return _.__wrap(t)}id(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.program_id(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}address(){try{const e=o.__wbindgen_add_to_stack_pointer(-16);o.program_address(e,this.__wbg_ptr);var _=P()[e/4+0],t=P()[e/4+1];if(P()[e/4+2])throw w(t);return U.__wrap(_)}finally{o.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){T(t,_);return 0!==o.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return w(o.program_getImports(this.__wbg_ptr))}};const n_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_programmanager_free(_>>>0)));let i_=class{__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,n_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_programmanager_free(_)}static buildDeploymentTransaction(_,t,e,r,n,i,a,s,c){T(_,G);const g=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),d=p;let b=0;v(r)||(T(r,w_),b=r.__destroy_into_raw());var l=v(n)?0:h(n,o.__wbindgen_malloc,o.__wbindgen_realloc),u=p;let y=0;v(a)||(T(a,a_),y=a.__destroy_into_raw());let m=0;v(s)||(T(s,p_),m=s.__destroy_into_raw());let k=0;v(c)||(T(c,X),k=c.__destroy_into_raw());return w(o.programmanager_buildDeploymentTransaction(_.__wbg_ptr,g,d,e,b,l,u,v(i)?0:f(i),y,m,k))}static estimateDeploymentFee(_,t){const e=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;return w(o.programmanager_estimateDeploymentFee(e,r,v(t)?0:f(t)))}static estimateProgramNameCost(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16),n=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;o.programmanager_estimateProgramNameCost(r,n,i);var t=O()[r/8+0],e=P()[r/4+2];if(P()[r/4+3])throw w(e);return BigInt.asUintN(64,t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(_,t,e,r,n,i,a,s,c,g,d){T(_,G);const b=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),l=p,u=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(s)||(T(s,a_),m=s.__destroy_into_raw());let k=0;v(c)||(T(c,p_),k=c.__destroy_into_raw());var P=v(g)?0:h(g,o.__wbindgen_malloc,o.__wbindgen_realloc),S=p;let x=0;v(d)||(T(d,X),x=d.__destroy_into_raw());return w(o.programmanager_executeFunctionOffline(_.__wbg_ptr,b,l,u,y,f(r),n,i,v(a)?0:f(a),m,k,P,S,x))}static buildExecutionTransaction(_,t,e,r,n,i,a,s,c,g,d,b,l){T(_,G);const u=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p,m=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),k=p;let P=0;v(i)||(T(i,w_),P=i.__destroy_into_raw());var S=v(a)?0:h(a,o.__wbindgen_malloc,o.__wbindgen_realloc),x=p;let V=0;v(c)||(T(c,a_),V=c.__destroy_into_raw());let F=0;v(g)||(T(g,p_),F=g.__destroy_into_raw());let R=0;v(d)||(T(d,a_),R=d.__destroy_into_raw());let z=0;v(b)||(T(b,p_),z=b.__destroy_into_raw());let A=0;v(l)||(T(l,X),A=l.__destroy_into_raw());return w(o.programmanager_buildExecutionTransaction(_.__wbg_ptr,u,y,m,k,f(r),n,P,S,x,v(s)?0:f(s),V,F,R,z,A))}static estimateExecutionFee(_,t,e,r,n,i,a,s,c){T(_,G);const g=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),d=p,b=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),l=p;var u=v(n)?0:h(n,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(a)||(T(a,a_),m=a.__destroy_into_raw());let k=0;v(s)||(T(s,p_),k=s.__destroy_into_raw());let P=0;v(c)||(T(c,X),P=c.__destroy_into_raw());return w(o.programmanager_estimateExecutionFee(_.__wbg_ptr,g,d,b,l,f(r),u,y,v(i)?0:f(i),m,k,P))}static estimateFinalizeFee(_,t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.programmanager_estimateFinalizeFee(n,i,a,s,c);var e=O()[n/8+0],r=P()[n/4+2];if(P()[n/4+3])throw w(r);return BigInt.asUintN(64,e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(_,t,e,r,n,i,a,s,c,g,d){T(_,G),T(t,w_);var b=t.__destroy_into_raw();T(e,w_);var l=e.__destroy_into_raw();let u=0;v(n)||(T(n,w_),u=n.__destroy_into_raw());var f=v(i)?0:h(i,o.__wbindgen_malloc,o.__wbindgen_realloc),y=p;let m=0;v(a)||(T(a,a_),m=a.__destroy_into_raw());let k=0;v(s)||(T(s,p_),k=s.__destroy_into_raw());let P=0;v(c)||(T(c,a_),P=c.__destroy_into_raw());let S=0;v(g)||(T(g,p_),S=g.__destroy_into_raw());let x=0;v(d)||(T(d,X),x=d.__destroy_into_raw());return w(o.programmanager_buildJoinTransaction(_.__wbg_ptr,b,l,r,u,f,y,m,k,P,S,x))}static buildSplitTransaction(_,t,e,r,n,i,a){T(_,G),T(e,w_);var s=e.__destroy_into_raw(),c=v(r)?0:h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),g=p;let d=0;v(n)||(T(n,a_),d=n.__destroy_into_raw());let b=0;v(i)||(T(i,p_),b=i.__destroy_into_raw());let l=0;v(a)||(T(a,X),l=a.__destroy_into_raw());return w(o.programmanager_buildSplitTransaction(_.__wbg_ptr,t,s,c,g,d,b,l))}static buildTransferTransaction(_,t,e,r,n,i,a,s,c,g,d,b,l){T(_,G);const u=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),f=p,y=h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),m=p;let k=0;v(n)||(T(n,w_),k=n.__destroy_into_raw());let P=0;v(a)||(T(a,w_),P=a.__destroy_into_raw());var S=v(s)?0:h(s,o.__wbindgen_malloc,o.__wbindgen_realloc),x=p;let V=0;v(c)||(T(c,a_),V=c.__destroy_into_raw());let F=0;v(g)||(T(g,p_),F=g.__destroy_into_raw());let R=0;v(d)||(T(d,a_),R=d.__destroy_into_raw());let z=0;v(b)||(T(b,p_),z=b.__destroy_into_raw());let A=0;v(l)||(T(l,X),A=l.__destroy_into_raw());return w(o.programmanager_buildTransferTransaction(_.__wbg_ptr,t,u,f,y,m,k,i,P,S,x,V,F,R,z,A))}static synthesizeKeyPair(_,t,e,r,n){T(_,G);const i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;return w(o.programmanager_synthesizeKeyPair(_.__wbg_ptr,i,a,s,c,f(r),v(n)?0:f(n)))}};const o_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_provingkey_free(_>>>0)));let a_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,o_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,o_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_provingkey_free(_)}isBondPublicProver(){return 0!==o.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==o.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==o.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==o.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==o.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==o.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==o.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==o.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==o.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==o.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==o.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==o.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==o.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==o.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==o.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_checksum(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}copy(){const t=o.provingkey_copy(this.__wbg_ptr);return _.__wrap(t)}static fromBytes(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=R(t,o.__wbindgen_malloc),a=p;o.provingkey_fromBytes(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.provingkey_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_toBytes(n,this.__wbg_ptr);var _=P()[n/4+0],t=P()[n/4+1],e=P()[n/4+2];if(P()[n/4+3])throw w(e);var r=j(_,t).slice();return o.__wbindgen_free(_,1*t,1),r}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.provingkey_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const s_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_recordciphertext_free(_>>>0)));let c_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,s_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,s_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_recordciphertext_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.recordciphertext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordciphertext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}decrypt(_){try{const r=o.__wbindgen_add_to_stack_pointer(-16);T(_,m_),o.recordciphertext_decrypt(r,this.__wbg_ptr,_.__wbg_ptr);var t=P()[r/4+0],e=P()[r/4+1];if(P()[r/4+2])throw w(e);return w_.__wrap(t)}finally{o.__wbindgen_add_to_stack_pointer(16)}}isOwner(_){T(_,m_);return 0!==o.recordciphertext_isOwner(this.__wbg_ptr,_.__wbg_ptr)}};const g_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_recordplaintext_free(_>>>0)));let w_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,g_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,g_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_recordplaintext_free(_)}commitment(_,t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p,s=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),c=p;o.recordplaintext_commitment(n,this.__wbg_ptr,i,a,s,c);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return D.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.recordplaintext_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordplaintext_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}microcredits(){const _=o.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,_)}nonce(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.recordplaintext_nonce(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}serialNumberString(_,t,e){let r,n;try{const b=o.__wbindgen_add_to_stack_pointer(-16);T(_,G);const l=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),f=p,y=h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),m=p;o.recordplaintext_serialNumberString(b,this.__wbg_ptr,_.__wbg_ptr,l,f,y,m);var i=P()[b/4+0],a=P()[b/4+1],s=P()[b/4+2],c=P()[b/4+3],g=i,d=a;if(c)throw g=0,d=0,w(s);return r=g,n=d,u(g,d)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(r,n,1)}}};const d_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_signature_free(_>>>0)));let b_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,d_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,d_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_signature_free(_)}static sign(t,e){T(t,G);const r=R(e,o.__wbindgen_malloc),n=p,i=o.privatekey_sign(t.__wbg_ptr,r,n);return _.__wrap(i)}verify(_,t){T(_,U);const e=R(t,o.__wbindgen_malloc),r=p;return 0!==o.signature_verify(this.__wbg_ptr,_.__wbg_ptr,e,r)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.signature_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.signature_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const l_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_transaction_free(_>>>0)));let u_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,l_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,l_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_transaction_free(_)}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.transaction_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}transactionId(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_transactionId(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}transactionType(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.transaction_transactionType(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const f_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_verifyingkey_free(_>>>0)));let p_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,f_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,f_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_verifyingkey_free(_)}static bondPublicVerifier(){const t=o.verifyingkey_bondPublicVerifier();return _.__wrap(t)}static bondValidatorVerifier(){const t=o.verifyingkey_bondValidatorVerifier();return _.__wrap(t)}static claimUnbondPublicVerifier(){const t=o.verifyingkey_claimUnbondPublicVerifier();return _.__wrap(t)}static feePrivateVerifier(){const t=o.verifyingkey_feePrivateVerifier();return _.__wrap(t)}static feePublicVerifier(){const t=o.verifyingkey_feePublicVerifier();return _.__wrap(t)}static inclusionVerifier(){const t=o.verifyingkey_inclusionVerifier();return _.__wrap(t)}static joinVerifier(){const t=o.verifyingkey_joinVerifier();return _.__wrap(t)}static setValidatorStateVerifier(){const t=o.verifyingkey_setValidatorStateVerifier();return _.__wrap(t)}static splitVerifier(){const t=o.verifyingkey_splitVerifier();return _.__wrap(t)}static transferPrivateVerifier(){const t=o.verifyingkey_transferPrivateVerifier();return _.__wrap(t)}static transferPrivateToPublicVerifier(){const t=o.verifyingkey_transferPrivateToPublicVerifier();return _.__wrap(t)}static transferPublicVerifier(){const t=o.verifyingkey_transferPublicVerifier();return _.__wrap(t)}static transferPublicAsSignerVerifier(){const t=o.verifyingkey_transferPublicAsSignerVerifier();return _.__wrap(t)}static transferPublicToPrivateVerifier(){const t=o.verifyingkey_transferPublicToPrivateVerifier();return _.__wrap(t)}static unbondPublicVerifier(){const t=o.verifyingkey_unbondPublicVerifier();return _.__wrap(t)}isBondPublicVerifier(){return 0!==o.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==o.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==o.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==o.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==o.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==o.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==o.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==o.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==o.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==o.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==o.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==o.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==o.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==o.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==o.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_checksum(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}copy(){const t=o.verifyingkey_copy(this.__wbg_ptr);return _.__wrap(t)}static fromBytes(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=R(t,o.__wbindgen_malloc),a=p;o.verifyingkey_fromBytes(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=o.__wbindgen_add_to_stack_pointer(-16),i=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),a=p;o.verifyingkey_fromString(n,i,a);var e=P()[n/4+0],r=P()[n/4+1];if(P()[n/4+2])throw w(r);return _.__wrap(e)}finally{o.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_toBytes(n,this.__wbg_ptr);var _=P()[n/4+0],t=P()[n/4+1],e=P()[n/4+2];if(P()[n/4+3])throw w(e);var r=j(_,t).slice();return o.__wbindgen_free(_,1*t,1),r}finally{o.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.verifyingkey_toString(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}};const y_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>o.__wbg_viewkey_free(_>>>0)));let m_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,y_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,y_.unregister(this),_}free(){const _=this.__destroy_into_raw();o.__wbg_viewkey_free(_)}static from_private_key(t){T(t,G);const e=o.privatekey_to_view_key(t.__wbg_ptr);return _.__wrap(e)}static from_string(t){const e=h(t,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p,n=o.viewkey_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=o.__wbindgen_add_to_stack_pointer(-16);o.viewkey_to_string(n,this.__wbg_ptr);var e=P()[n/4+0],r=P()[n/4+1];return _=e,t=r,u(e,r)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(_,t,1)}}to_address(){const _=o.address_from_view_key(this.__wbg_ptr);return U.__wrap(_)}decrypt(_){let t,e;try{const g=o.__wbindgen_add_to_stack_pointer(-16),d=h(_,o.__wbindgen_malloc,o.__wbindgen_realloc),b=p;o.viewkey_decrypt(g,this.__wbg_ptr,d,b);var r=P()[g/4+0],n=P()[g/4+1],i=P()[g/4+2],a=P()[g/4+3],s=r,c=n;if(a)throw s=0,c=0,w(i);return t=s,e=c,u(s,c)}finally{o.__wbindgen_add_to_stack_pointer(16),o.__wbindgen_free(t,e,1)}}};async function h_(_,t){if("function"==typeof Response&&_ instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(_,t)}catch(t){if("application/wasm"==_.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await _.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(_,t);return e instanceof WebAssembly.Instance?{instance:e,module:_}:e}}function v_(){const _={wbg:{}};return _.wbg.__wbindgen_object_drop_ref=function(_){w(_)},_.wbg.__wbg_new_71801a555ad9f2aa=function(){return E((function(){return f(new XMLHttpRequest)}),arguments)},_.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return E((function(_,t,e){s(_).overrideMimeType(u(t,e))}),arguments)},_.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return E((function(_,t,e,r,n,i){s(_).open(u(t,e),u(r,n),0!==i)}),arguments)},_.wbg.__wbg_send_80d29985093c1ec5=function(){return E((function(_){s(_).send()}),arguments)},_.wbg.__wbg_response_7c2e2759084f7279=function(){return E((function(_){return f(s(_).response)}),arguments)},_.wbg.__wbg_status_d485fb5a478426fb=function(){return E((function(_){return s(_).status}),arguments)},_.wbg.__wbg_new_72fb9a18b5ae2624=function(){return f(new Object)},_.wbg.__wbindgen_string_new=function(_,t){return f(u(_,t))},_.wbg.__wbg_set_1f9b04f170055d33=function(){return E((function(_,t,e){return Reflect.set(s(_),s(t),s(e))}),arguments)},_.wbg.__wbg_new_ab6fd82b10560829=function(){return E((function(){return f(new Headers)}),arguments)},_.wbg.__wbindgen_object_clone_ref=function(_){return f(s(_))},_.wbg.__wbg_new_0d76b0581eca6298=function(){return E((function(){return f(new AbortController)}),arguments)},_.wbg.__wbg_signal_a61f78a3478fd9bc=function(_){return f(s(_).signal)},_.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return E((function(_,t,e,r,n){s(_).append(u(t,e),u(r,n))}),arguments)},_.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(_){let t;try{t=s(_)instanceof Response}catch(_){t=!1}return t},_.wbg.__wbg_status_61a01141acd3cf74=function(_){return s(_).status},_.wbg.__wbg_url_5f6dc4009ac5f99d=function(_,t){const e=h(s(t).url,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbg_headers_9620bfada380764a=function(_){return f(s(_).headers)},_.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return f(Symbol.iterator)},_.wbg.__wbg_get_e3c254076557e348=function(){return E((function(_,t){return f(Reflect.get(s(_),s(t)))}),arguments)},_.wbg.__wbindgen_is_function=function(_){return"function"==typeof s(_)},_.wbg.__wbg_call_27c0f87801dedf93=function(){return E((function(_,t){return f(s(_).call(s(t)))}),arguments)},_.wbg.__wbindgen_is_object=function(_){const t=s(_);return"object"==typeof t&&null!==t},_.wbg.__wbg_next_40fc327bfc8770e6=function(_){return f(s(_).next)},_.wbg.__wbg_next_196c84450b364254=function(){return E((function(_){return f(s(_).next())}),arguments)},_.wbg.__wbg_done_298b57d23c0fc80c=function(_){return s(_).done},_.wbg.__wbg_value_d93c65011f51a456=function(_){return f(s(_).value)},_.wbg.__wbg_abort_2aa7521d5690750e=function(_){s(_).abort()},_.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return E((function(_){return f(JSON.stringify(s(_)))}),arguments)},_.wbg.__wbindgen_string_get=function(_,t){const e=s(t),r="string"==typeof e?e:void 0;var n=v(r)?0:h(r,o.__wbindgen_malloc,o.__wbindgen_realloc),i=p;P()[_/4+1]=i,P()[_/4+0]=n},_.wbg.__wbg_log_0159ca40cddf5b15=function(_,t){console.log(u(_,t))},_.wbg.__wbindgen_bigint_from_u64=function(_){return f(BigInt.asUintN(64,_))},_.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return E((function(_,t,e){return f(s(_).call(s(t),s(e)))}),arguments)},_.wbg.__wbindgen_module=function(){return f(x_.__wbindgen_wasm_module)},_.wbg.__wbindgen_memory=function(){return f(o.memory)},_.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a=function(_,t,e,r){return f(i(s(_),s(t),s(e),r>>>0))},_.wbg.__wbg_executionresponse_new=function(_){return f($.__wrap(_))},_.wbg.__wbg_keypair_new=function(_){return f(L.__wrap(_))},_.wbg.__wbg_transaction_new=function(_){return f(u_.__wrap(_))},_.wbg.__wbg_newwithlength_66ae46612e7f0234=function(_){return f(new Array(_>>>0))},_.wbg.__wbg_set_d4638f722068f043=function(_,t,e){s(_)[t>>>0]=w(e)},_.wbg.__wbindgen_cb_drop=function(_){const t=w(_).original;if(1==t.cnt--)return t.a=0,!0;return!1},_.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return f(new Array)},_.wbg.__wbg_push_a5b05aedc7234f9f=function(_,t){return s(_).push(s(t))},_.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return E((function(_){return f(s(_).arrayBuffer())}),arguments)},_.wbg.__wbg_new_63b92bc8671ed464=function(_){return f(new Uint8Array(s(_)))},_.wbg.__wbg_length_c20a40f15020d68a=function(_){return s(_).length},_.wbg.__wbg_new_81740750da40724f=function(_,t){try{var e={a:_,b:t};const r=new Promise(((_,t)=>{const r=e.a;e.a=0;try{return M(r,e.b,_,t)}finally{e.a=r}}));return f(r)}finally{e.a=e.b=0}},_.wbg.__wbindgen_number_new=function(_){return f(_)},_.wbg.__wbg_new_abda76e883ba8a5f=function(){return f(new Error)},_.wbg.__wbg_stack_658279fe44541cf6=function(_,t){const e=h(s(t).stack,o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbg_error_f851667af71bcfc6=function(_,t){let e,r;try{e=_,r=t,console.error(u(_,t))}finally{o.__wbindgen_free(e,r,1)}},_.wbg.__wbg_buffer_12d079cc21e14bdb=function(_){return f(s(_).buffer)},_.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(_,t,e){return f(new Uint8Array(s(_),t>>>0,e>>>0))},_.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return E((function(_,t){s(_).randomFillSync(w(t))}),arguments)},_.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(_,t,e){return f(s(_).subarray(t>>>0,e>>>0))},_.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return E((function(_,t){s(_).getRandomValues(s(t))}),arguments)},_.wbg.__wbg_set_a47bac70306a19a7=function(_,t,e){s(_).set(s(t),e>>>0)},_.wbg.__wbg_crypto_1d1f22824a6a080c=function(_){return f(s(_).crypto)},_.wbg.__wbg_process_4a72847cc503995b=function(_){return f(s(_).process)},_.wbg.__wbg_versions_f686565e586dd935=function(_){return f(s(_).versions)},_.wbg.__wbg_node_104a2ff8d6ea03a2=function(_){return f(s(_).node)},_.wbg.__wbindgen_is_string=function(_){return"string"==typeof s(_)},_.wbg.__wbg_require_cca90b1a94a0255b=function(){return E((function(){return f(module.require)}),arguments)},_.wbg.__wbg_msCrypto_eb05e62b530a1508=function(_){return f(s(_).msCrypto)},_.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(_){return f(new Uint8Array(_>>>0))},_.wbg.__wbg_length_cd7af8117672b8b8=function(_){return s(_).length},_.wbg.__wbg_get_bd8e338fbd5f5cc8=function(_,t){return f(s(_)[t>>>0])},_.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return E((function(){return f(self.self)}),arguments)},_.wbg.__wbg_window_c6fb939a7f436783=function(){return E((function(){return f(window.window)}),arguments)},_.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return E((function(){return f(globalThis.globalThis)}),arguments)},_.wbg.__wbg_global_207b558942527489=function(){return E((function(){return f(global.global)}),arguments)},_.wbg.__wbindgen_is_undefined=function(_){return void 0===s(_)},_.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(_,t){return f(new Function(u(_,t)))},_.wbg.__wbg_has_0af94d20077affa2=function(){return E((function(_,t){return Reflect.has(s(_),s(t))}),arguments)},_.wbg.__wbg_fetch_bc7c8e27076a5c84=function(_){return f(fetch(s(_)))},_.wbg.__wbg_fetch_921fad6ef9e883dd=function(_,t){return f(s(_).fetch(s(t)))},_.wbg.__wbindgen_debug_string=function(_,t){const e=h(S(s(t)),o.__wbindgen_malloc,o.__wbindgen_realloc),r=p;P()[_/4+1]=r,P()[_/4+0]=e},_.wbg.__wbindgen_throw=function(_,t){throw new Error(u(_,t))},_.wbg.__wbindgen_rethrow=function(_){throw w(_)},_.wbg.__wbg_then_a73caa9a87991566=function(_,t,e){return f(s(_).then(s(t),s(e)))},_.wbg.__wbg_then_0c86a60e8fcfe9f6=function(_,t){return f(s(_).then(s(t)))},_.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(_){queueMicrotask(s(_))},_.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(_){return f(s(_).queueMicrotask)},_.wbg.__wbg_resolve_b0083a7967828ec8=function(_){return f(Promise.resolve(s(_)))},_.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return f(Atomics.waitAsync)},_.wbg.__wbg_new_8cccba86b0f574cb=function(_){return f(new Int32Array(s(_)))},_.wbg.__wbg_waitAsync_46d5c36955b71a79=function(_,t,e){return f(Atomics.waitAsync(s(_),t,e))},_.wbg.__wbg_async_19c0400d97cc72fe=function(_){return s(_).async},_.wbg.__wbg_value_571d60108110e917=function(_){return f(s(_).value)},_.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(_){const t=h("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),o.__wbindgen_malloc,o.__wbindgen_realloc),e=p;P()[_/4+1]=e,P()[_/4+0]=t},_.wbg.__wbg_new_d1187ae36d662ef9=function(){return E((function(_,t){return f(new Worker(u(_,t)))}),arguments)},_.wbg.__wbg_setonmessage_503809e5bb51bd33=function(_,t){s(_).onmessage=s(t)},_.wbg.__wbg_of_6a70eed8d41f469c=function(_,t,e){return f(Array.of(s(_),s(t),s(e)))},_.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return E((function(_,t){s(_).postMessage(s(t))}),arguments)},_.wbg.__wbg_data_3ce7c145ca4fbcdc=function(_){return f(s(_).data)},_.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return E((function(_,t,e){return f(new Request(u(_,t),s(e)))}),arguments)},_.wbg.__wbg_responseText_c67ed2d48db10769=function(){return E((function(_,t){const e=s(t).responseText;var r=v(e)?0:h(e,o.__wbindgen_malloc,o.__wbindgen_realloc),n=p;P()[_/4+1]=n,P()[_/4+0]=r}),arguments)},_.wbg.__wbindgen_closure_wrapper5975=function(_,t,e){return f(V(_,t,622,F))},_.wbg.__wbindgen_closure_wrapper6001=function(_,t,e){return f(V(_,t,622,F))},_}function k_(_,t){_.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function P_(_,t){return o=_.exports,x_.__wbindgen_wasm_module=t,A=null,k=null,b=null,o.__wbindgen_start(),o}function S_(_,t){if(void 0!==o)return o;const e=v_();k_(e,t),_ instanceof WebAssembly.Module||(_=new WebAssembly.Module(_));return P_(new WebAssembly.Instance(_,e),_)}async function x_(_,t){if(void 0!==o)return o;const e=v_();("string"==typeof _||"function"==typeof Request&&_ instanceof Request||"function"==typeof URL&&_ instanceof URL)&&(_=fetch(_)),k_(e,t);const{instance:r,module:n}=await h_(await _,e);return P_(r,n)}var n=Object.freeze({__proto__:null,Address:U,Execution:q,ExecutionResponse:$,Field:D,KeyPair:L,Metadata:Z,OfflineQuery:X,PrivateKey:G,PrivateKeyCiphertext:t_,Program:r_,ProgramManager:i_,ProvingKey:a_,RecordCiphertext:c_,RecordPlaintext:w_,Signature:b_,Transaction:u_,VerifyingKey:p_,ViewKey:m_,default:x_,initSync:S_,initThreadPool:C,runRayonThread:K,verifyFunctionExecution:z});const V_="aleo_wasm.wasm";const{initThreadPool:F_,Address:T_,Execution:R_,ExecutionResponse:z_,Field:A_,Metadata:O_,OfflineQuery:j_,Private:K_,PrivateKey:C_,PrivateKeyCiphertext:E_,Program:M_,ProvingKey:B_,RecordCiphertext:U_,RecordPlaintext:I_,ProgramManager:q_,Signature:W_,Transaction:$_,ViewKey:N_,VerifyingKey:D_,verifyFunctionExecution:J_}=await(async(_={})=>{let{importHook:t,serverPath:e,initializeHook:r}=_,i=V_;return null!=e&&(i=e+/[^\/\\]*$/.exec(i)[0]),null!=t&&(i=t(i)),null!=r?await r(x_,i):await x_(i),n})({importHook:()=>new URL(e(6545),e.b)});async function L_(_){null==_&&(_=navigator.hardwareConcurrency),console.info(`Spawning ${_} threads`),await F_(new URL(e(2851),e.b),_)}r()}catch(H_){r(H_)}}),1)}}]); -//# sourceMappingURL=879.bundle.js.map \ No newline at end of file diff --git a/879.bundle.js.map b/879.bundle.js.map deleted file mode 100644 index a478e65a5..000000000 --- a/879.bundle.js.map +++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EACZkJ,qBAAsBR,GACtBgB,QAAS/L,GACTynB,eAAgBC,GAChB9V,WAAYpN,GACZkQ,iBAAkBiT,GAClBvS,gBAAiBhH,GACjBgI,UAAWhT,GACXsT,YAAamK,GACbzJ,aAAcrX,GACd0b,QAAShZ,GACTmlB,QAASvH,GACT6G,SAAUA,GACVjmB,eAAgBF,EAChBF,eAAgBA,EAChBR,wBAAyBd,IAG7B,MAAMsoB,GAAY,iB,qUAGM9L,OAAO+L,EAAM,CAAC,KACtB,IAAI,WAACC,EAAU,WAAEC,EAAU,eAAEC,GAAkBH,EAE3CI,EAAaL,GAiBjB,OAfkB,MAAdG,IACAE,EAAaF,EAAa,YAAY3qB,KAAK6qB,GAAY,IAGzC,MAAdH,IACAG,EAAaH,EAAWG,IAGN,MAAlBD,QACMA,EAAe5H,GAAY6H,SAG3B7H,GAAW6H,GAGdlB,CAAO,E","sources":["webpack://aleo-website/aleo_wasm.js"],"sourcesContent":["function spawnWorker(url, module, memory, address) {\n return new Promise((resolve) => {\n const worker = new Worker(url, {\n type: \"module\",\n });\n\n worker.addEventListener(\"message\", (event) => {\n // This is needed in Node to wait one extra tick, so that way\n // the Worker can fully initialize before we return.\n setTimeout(() => {\n resolve(worker);\n\n // When running in Node, this allows the process to exit\n // even though the Worker is still running.\n if (worker.unref) {\n worker.unref();\n }\n }, 0);\n }, {\n capture: true,\n once: true,\n });\n\n worker.postMessage({\n module,\n memory,\n address,\n });\n });\n }\n\nlet wasm;\n\nconst heap = new Array(128).fill(undefined);\n\nheap.push(undefined, null, true, false);\n\nfunction getObject(idx) { return heap[idx]; }\n\nlet heap_next = heap.length;\n\nfunction dropObject(idx) {\n if (idx < 132) return;\n heap[idx] = heap_next;\n heap_next = idx;\n}\n\nfunction takeObject(idx) {\n const ret = getObject(idx);\n dropObject(idx);\n return ret;\n}\n\nconst cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );\n\nif (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); }\nlet cachedUint8Memory0 = null;\n\nfunction getUint8Memory0() {\n if (cachedUint8Memory0 === null || cachedUint8Memory0.buffer !== wasm.memory.buffer) {\n cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);\n }\n return cachedUint8Memory0;\n}\n\nfunction getStringFromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return cachedTextDecoder.decode(getUint8Memory0().slice(ptr, ptr + len));\n}\n\nfunction addHeapObject(obj) {\n if (heap_next === heap.length) heap.push(heap.length + 1);\n const idx = heap_next;\n heap_next = heap[idx];\n\n heap[idx] = obj;\n return idx;\n}\n\nlet WASM_VECTOR_LEN = 0;\n\nconst cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );\n\nconst encodeString = function (arg, view) {\n const buf = cachedTextEncoder.encode(arg);\n view.set(buf);\n return {\n read: arg.length,\n written: buf.length\n };\n};\n\nfunction passStringToWasm0(arg, malloc, realloc) {\n\n if (realloc === undefined) {\n const buf = cachedTextEncoder.encode(arg);\n const ptr = malloc(buf.length, 1) >>> 0;\n getUint8Memory0().subarray(ptr, ptr + buf.length).set(buf);\n WASM_VECTOR_LEN = buf.length;\n return ptr;\n }\n\n let len = arg.length;\n let ptr = malloc(len, 1) >>> 0;\n\n const mem = getUint8Memory0();\n\n let offset = 0;\n\n for (; offset < len; offset++) {\n const code = arg.charCodeAt(offset);\n if (code > 0x7F) break;\n mem[ptr + offset] = code;\n }\n\n if (offset !== len) {\n if (offset !== 0) {\n arg = arg.slice(offset);\n }\n ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;\n const view = getUint8Memory0().subarray(ptr + offset, ptr + len);\n const ret = encodeString(arg, view);\n\n offset += ret.written;\n ptr = realloc(ptr, len, offset, 1) >>> 0;\n }\n\n WASM_VECTOR_LEN = offset;\n return ptr;\n}\n\nfunction isLikeNone(x) {\n return x === undefined || x === null;\n}\n\nlet cachedInt32Memory0 = null;\n\nfunction getInt32Memory0() {\n if (cachedInt32Memory0 === null || cachedInt32Memory0.buffer !== wasm.memory.buffer) {\n cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);\n }\n return cachedInt32Memory0;\n}\n\nfunction debugString(val) {\n // primitive types\n const type = typeof val;\n if (type == 'number' || type == 'boolean' || val == null) {\n return `${val}`;\n }\n if (type == 'string') {\n return `\"${val}\"`;\n }\n if (type == 'symbol') {\n const description = val.description;\n if (description == null) {\n return 'Symbol';\n } else {\n return `Symbol(${description})`;\n }\n }\n if (type == 'function') {\n const name = val.name;\n if (typeof name == 'string' && name.length > 0) {\n return `Function(${name})`;\n } else {\n return 'Function';\n }\n }\n // objects\n if (Array.isArray(val)) {\n const length = val.length;\n let debug = '[';\n if (length > 0) {\n debug += debugString(val[0]);\n }\n for(let i = 1; i < length; i++) {\n debug += ', ' + debugString(val[i]);\n }\n debug += ']';\n return debug;\n }\n // Test for built-in\n const builtInMatches = /\\[object ([^\\]]+)\\]/.exec(toString.call(val));\n let className;\n if (builtInMatches.length > 1) {\n className = builtInMatches[1];\n } else {\n // Failed to match the standard '[object ClassName]'\n return toString.call(val);\n }\n if (className == 'Object') {\n // we're a user defined class or Object\n // JSON.stringify avoids problems with cycles, and is generally much\n // easier than looping through ownProperties of `val`.\n try {\n return 'Object(' + JSON.stringify(val) + ')';\n } catch (_) {\n return 'Object';\n }\n }\n // errors\n if (val instanceof Error) {\n return `${val.name}: ${val.message}\\n${val.stack}`;\n }\n // TODO we could test for more things here, like `Set`s and `Map`s.\n return className;\n}\n\nconst CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(state => {\n wasm.__wbindgen_export_3.get(state.dtor)(state.a, state.b);\n});\n\nfunction makeMutClosure(arg0, arg1, dtor, f) {\n const state = { a: arg0, b: arg1, cnt: 1, dtor };\n const real = (...args) => {\n // First up with a closure we increment the internal reference\n // count. This ensures that the Rust closure environment won't\n // be deallocated while we're invoking it.\n state.cnt++;\n const a = state.a;\n state.a = 0;\n try {\n return f(a, state.b, ...args);\n } finally {\n if (--state.cnt === 0) {\n wasm.__wbindgen_export_3.get(state.dtor)(a, state.b);\n CLOSURE_DTORS.unregister(state);\n } else {\n state.a = a;\n }\n }\n };\n real.original = state;\n CLOSURE_DTORS.register(real, state, state);\n return real;\n}\nfunction __wbg_adapter_34(arg0, arg1, arg2) {\n wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha51b8a0cd6570266(arg0, arg1, addHeapObject(arg2));\n}\n\nfunction _assertClass(instance, klass) {\n if (!(instance instanceof klass)) {\n throw new Error(`expected instance of ${klass.name}`);\n }\n return instance.ptr;\n}\n\nfunction passArray8ToWasm0(arg, malloc) {\n const ptr = malloc(arg.length * 1, 1) >>> 0;\n getUint8Memory0().set(arg, ptr / 1);\n WASM_VECTOR_LEN = arg.length;\n return ptr;\n}\n/**\n* Verify an execution with a single function and a single transition. Executions with multiple\n* transitions or functions will fail to verify. Also, this does not verify that the state root of\n* the execution is included in the Aleo Network ledger.\n*\n* @param {Execution} execution The function execution to verify\n* @param {VerifyingKey} verifying_key The verifying key for the function\n* @param {Program} program The program that the function execution belongs to\n* @param {String} function_id The name of the function that was executed\n* @returns {boolean} True if the execution is valid, false otherwise\n* @param {Execution} execution\n* @param {VerifyingKey} verifying_key\n* @param {Program} program\n* @param {string} function_id\n* @returns {boolean}\n*/\nfunction verifyFunctionExecution(execution, verifying_key, program, function_id) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(execution, Execution);\n _assertClass(verifying_key, VerifyingKey);\n _assertClass(program, Program);\n const ptr0 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyFunctionExecution(retptr, execution.__wbg_ptr, verifying_key.__wbg_ptr, program.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return r0 !== 0;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n}\n\nlet cachedBigInt64Memory0 = null;\n\nfunction getBigInt64Memory0() {\n if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.buffer !== wasm.memory.buffer) {\n cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);\n }\n return cachedBigInt64Memory0;\n}\n\nfunction getArrayU8FromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);\n}\n/**\n* @param {number} receiver\n*/\nfunction runRayonThread(receiver) {\n wasm.runRayonThread(receiver);\n}\n\n/**\n* @param {URL} url\n* @param {number} num_threads\n* @returns {Promise}\n*/\nfunction initThreadPool(url, num_threads) {\n const ret = wasm.initThreadPool(addHeapObject(url), num_threads);\n return takeObject(ret);\n}\n\nfunction handleError(f, args) {\n try {\n return f.apply(this, args);\n } catch (e) {\n wasm.__wbindgen_exn_store(addHeapObject(e));\n }\n}\nfunction __wbg_adapter_281(arg0, arg1, arg2, arg3) {\n wasm.wasm_bindgen__convert__closures__invoke2_mut__h823ad1ce2c4b384e(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));\n}\n\nconst AddressFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_address_free(ptr >>> 0));\n/**\n* Public address of an Aleo account\n*/\nclass Address {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Address.prototype);\n obj.__wbg_ptr = ptr;\n AddressFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n AddressFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_address_free(ptr);\n }\n /**\n * Derive an Aleo address from a private key\n *\n * @param {PrivateKey} private_key The private key to derive the address from\n * @returns {Address} Address corresponding to the private key\n * @param {PrivateKey} private_key\n * @returns {Address}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.address_from_private_key(private_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Derive an Aleo address from a view key\n *\n * @param {ViewKey} view_key The view key to derive the address from\n * @returns {Address} Address corresponding to the view key\n * @param {ViewKey} view_key\n * @returns {Address}\n */\n static from_view_key(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.address_from_view_key(view_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Create an aleo address object from a string representation of an address\n *\n * @param {string} address String representation of an addressm\n * @returns {Address} Address\n * @param {string} address\n * @returns {Address}\n */\n static from_string(address) {\n const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.address_from_string(ptr0, len0);\n return Address.__wrap(ret);\n }\n /**\n * Get a string representation of an Aleo address object\n *\n * @param {Address} Address\n * @returns {string} String representation of the address\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.address_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Verify a signature for a message signed by the address\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {boolean} Boolean representing whether or not the signature is valid\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n */\n verify(message, signature) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n _assertClass(signature, Signature);\n const ret = wasm.address_verify(this.__wbg_ptr, ptr0, len0, signature.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst ExecutionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_execution_free(ptr >>> 0));\n/**\n* Execution of an Aleo program.\n*/\nclass Execution {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Execution.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_execution_free(ptr);\n }\n /**\n * Returns the string representation of the execution.\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.execution_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates an execution object from a string representation of an execution.\n * @param {string} execution\n * @returns {Execution}\n */\n static fromString(execution) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(execution, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.execution_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Execution.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ExecutionResponseFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_executionresponse_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo function execution response\n*\n* This object is returned by the execution of an Aleo function off-chain. It provides methods for\n* retrieving the outputs of the function execution.\n*/\nclass ExecutionResponse {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ExecutionResponse.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionResponseFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionResponseFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_executionresponse_free(ptr);\n }\n /**\n * Get the outputs of the executed function\n *\n * @returns {Array} Array of strings representing the outputs of the function\n * @returns {Array}\n */\n getOutputs() {\n const ret = wasm.executionresponse_getOutputs(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Returns the execution object if present, null if otherwise.\n *\n * @returns {Execution | undefined} The execution object if present, null if otherwise\n * @returns {Execution | undefined}\n */\n getExecution() {\n const ret = wasm.executionresponse_getExecution(this.__wbg_ptr);\n return ret === 0 ? undefined : Execution.__wrap(ret);\n }\n /**\n * Returns the program keys if present\n * @returns {KeyPair}\n */\n getKeys() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getKeys(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return KeyPair.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the proving_key if the proving key was cached in the Execution response.\n * Note the proving key is removed from the response object after the first call to this\n * function. Subsequent calls will return null.\n *\n * @returns {ProvingKey | undefined} The proving key\n * @returns {ProvingKey | undefined}\n */\n getProvingKey() {\n const ret = wasm.executionresponse_getProvingKey(this.__wbg_ptr);\n return ret === 0 ? undefined : ProvingKey.__wrap(ret);\n }\n /**\n * Returns the verifying_key associated with the program\n *\n * @returns {VerifyingKey} The verifying key\n * @returns {VerifyingKey}\n */\n getVerifyingKey() {\n const ret = wasm.executionresponse_getVerifyingKey(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the function identifier\n * @returns {string}\n */\n getFunctionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getFunctionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the program\n * @returns {Program}\n */\n getProgram() {\n const ret = wasm.executionresponse_getProgram(this.__wbg_ptr);\n return Program.__wrap(ret);\n }\n}\n\nconst FieldFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_field_free(ptr >>> 0));\n/**\n*/\nclass Field {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Field.prototype);\n obj.__wbg_ptr = ptr;\n FieldFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n FieldFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_field_free(ptr);\n }\n /**\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.field_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} field\n * @returns {Field}\n */\n static fromString(field) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(field, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.field_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst KeyPairFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_keypair_free(ptr >>> 0));\n/**\n* Key pair object containing both the function proving and verifying keys\n*/\nclass KeyPair {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(KeyPair.prototype);\n obj.__wbg_ptr = ptr;\n KeyPairFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n KeyPairFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_keypair_free(ptr);\n }\n /**\n * Create new key pair from proving and verifying keys\n *\n * @param {ProvingKey} proving_key Proving key corresponding to a function in an Aleo program\n * @param {VerifyingKey} verifying_key Verifying key corresponding to a function in an Aleo program\n * @returns {KeyPair} Key pair object containing both the function proving and verifying keys\n * @param {ProvingKey} proving_key\n * @param {VerifyingKey} verifying_key\n */\n constructor(proving_key, verifying_key) {\n _assertClass(proving_key, ProvingKey);\n var ptr0 = proving_key.__destroy_into_raw();\n _assertClass(verifying_key, VerifyingKey);\n var ptr1 = verifying_key.__destroy_into_raw();\n const ret = wasm.keypair_new(ptr0, ptr1);\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get the proving key. This method will remove the proving key from the key pair\n *\n * @returns {ProvingKey}\n * @returns {ProvingKey}\n */\n provingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_provingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the verifying key. This method will remove the verifying key from the key pair\n *\n * @returns {VerifyingKey}\n * @returns {VerifyingKey}\n */\n verifyingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst MetadataFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_metadata_free(ptr >>> 0));\n/**\n*/\nclass Metadata {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Metadata.prototype);\n obj.__wbg_ptr = ptr;\n MetadataFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n MetadataFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_metadata_free(ptr);\n }\n /**\n * @returns {string}\n */\n get name() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_name(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set name(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_name(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get locator() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_locator(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set locator(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_locator(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get prover() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_prover(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set prover(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_prover(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifier() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifier(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifier(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifier(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifyingKey() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifyingKey(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifyingKey(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n static baseUrl() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.metadata_baseUrl(retptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @returns {Metadata}\n */\n static bond_public() {\n const ret = wasm.metadata_bond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static bond_validator() {\n const ret = wasm.metadata_bond_validator();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static claim_unbond_public() {\n const ret = wasm.metadata_claim_unbond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_private() {\n const ret = wasm.metadata_fee_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_public() {\n const ret = wasm.metadata_fee_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static inclusion() {\n const ret = wasm.metadata_inclusion();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static join() {\n const ret = wasm.metadata_join();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static set_validator_state() {\n const ret = wasm.metadata_set_validator_state();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static split() {\n const ret = wasm.metadata_split();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private() {\n const ret = wasm.metadata_transfer_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private_to_public() {\n const ret = wasm.metadata_transfer_private_to_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public() {\n const ret = wasm.metadata_transfer_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_as_signer() {\n const ret = wasm.metadata_transfer_public_as_signer();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_to_private() {\n const ret = wasm.metadata_transfer_public_to_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static unbond_public() {\n const ret = wasm.metadata_unbond_public();\n return Metadata.__wrap(ret);\n }\n}\n\nconst OfflineQueryFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_offlinequery_free(ptr >>> 0));\n/**\n* An offline query object used to insert the global state root and state paths needed to create\n* a valid inclusion proof offline.\n*/\nclass OfflineQuery {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(OfflineQuery.prototype);\n obj.__wbg_ptr = ptr;\n OfflineQueryFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n OfflineQueryFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_offlinequery_free(ptr);\n }\n /**\n * Creates a new offline query object. The state root is required to be passed in as a string\n * @param {string} state_root\n */\n constructor(state_root) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(state_root, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_new(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n this.__wbg_ptr = r0 >>> 0;\n return this;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Add a new state path to the offline query object.\n *\n * @param {string} commitment: The commitment corresponding to a record inpout\n * @param {string} state_path: The state path corresponding to the commitment\n * @param {string} commitment\n * @param {string} state_path\n */\n addStatePath(commitment, state_path) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(commitment, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(state_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.offlinequery_addStatePath(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n if (r1) {\n throw takeObject(r0);\n }\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a json string representation of the offline query object\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.offlinequery_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create an offline query object from a json string representation\n * @param {string} s\n * @returns {OfflineQuery}\n */\n static fromString(s) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(s, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return OfflineQuery.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekey_free(ptr >>> 0));\n/**\n* Private key of an Aleo account\n*/\nclass PrivateKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKey.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekey_free(ptr);\n }\n /**\n * Generate a new private key using a cryptographically secure random number generator\n *\n * @returns {PrivateKey}\n */\n constructor() {\n const ret = wasm.privatekey_new();\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get a private key from a series of unchecked bytes\n *\n * @param {Uint8Array} seed Unchecked 32 byte long Uint8Array acting as the seed for the private key\n * @returns {PrivateKey}\n * @param {Uint8Array} seed\n * @returns {PrivateKey}\n */\n static from_seed_unchecked(seed) {\n const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_from_seed_unchecked(ptr0, len0);\n return PrivateKey.__wrap(ret);\n }\n /**\n * Get a private key from a string representation of a private key\n *\n * @param {string} seed String representation of a private key\n * @returns {PrivateKey}\n * @param {string} private_key\n * @returns {PrivateKey}\n */\n static from_string(private_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(private_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_from_string(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the private key. This function should be used very carefully\n * as it exposes the private key plaintext\n *\n * @returns {string} String representation of a private key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the view key corresponding to the private key\n *\n * @returns {ViewKey}\n * @returns {ViewKey}\n */\n to_view_key() {\n const ret = wasm.privatekey_to_view_key(this.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get the address corresponding to the private key\n *\n * @returns {Address}\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.privatekey_to_address(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Sign a message with the private key\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {Signature} Signature generated by signing the message with the address\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n sign(message) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(this.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a new randomly generated private key ciphertext using a secret. The secret is sensitive\n * and will be needed to decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static newEncrypted(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_newEncrypted(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Encrypt an existing private key with a secret. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n toCiphertext(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get private key from a private key ciphertext and secret originally used to encrypt it\n *\n * @param {PrivateKeyCiphertext} ciphertext Ciphertext representation of the private key\n * @param {string} secret Secret originally used to encrypt the private key\n * @returns {PrivateKey} Private key\n * @param {PrivateKeyCiphertext} ciphertext\n * @param {string} secret\n * @returns {PrivateKey}\n */\n static fromPrivateKeyCiphertext(ciphertext, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(ciphertext, PrivateKeyCiphertext);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_fromPrivateKeyCiphertext(retptr, ciphertext.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekeyciphertext_free(ptr >>> 0));\n/**\n* Private Key in ciphertext form\n*/\nclass PrivateKeyCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKeyCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekeyciphertext_free(ptr);\n }\n /**\n * Encrypt a private key using a secret string. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {PrivateKey} private_key Private key to encrypt\n * @param {string} secret Secret to encrypt the private key with\n * @returns {PrivateKeyCiphertext} Private key ciphertext\n * @param {PrivateKey} private_key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static encryptPrivateKey(private_key, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, private_key.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Decrypts a private ciphertext using a secret string. This must be the same secret used to\n * encrypt the private key\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKey} Private key\n * @param {string} secret\n * @returns {PrivateKey}\n */\n decryptToPrivateKey(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_decryptToPrivateKey(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the ciphertext string\n *\n * @returns {string} Ciphertext string\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekeyciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates a PrivateKeyCiphertext from a string\n *\n * @param {string} ciphertext Ciphertext string\n * @returns {PrivateKeyCiphertext} Private key ciphertext\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n */\n static fromString(ciphertext) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ProgramFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_program_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo program\n*/\nclass Program {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Program.prototype);\n obj.__wbg_ptr = ptr;\n ProgramFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_program_free(ptr);\n }\n /**\n * Create a program from a program string\n *\n * @param {string} program Aleo program source code\n * @returns {Program} Program object\n * @param {string} program\n * @returns {Program}\n */\n static fromString(program) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Program.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the program\n *\n * @returns {string} String containing the program source code\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Determine if a function is present in the program\n *\n * @param {string} functionName Name of the function to check for\n * @returns {boolean} True if the program is valid, false otherwise\n * @param {string} function_name\n * @returns {boolean}\n */\n hasFunction(function_name) {\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.program_hasFunction(this.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get javascript array of functions names in the program\n *\n * @returns {Array} Array of all function names present in the program\n *\n * @example\n * const expected_functions = [\n * \"mint\",\n * \"transfer_private\",\n * \"transfer_private_to_public\",\n * \"transfer_public\",\n * \"transfer_public_to_private\",\n * \"join\",\n * \"split\",\n * \"fee\"\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_functions = credits_program.getFunctions();\n * console.log(credits_functions === expected_functions); // Output should be \"true\"\n * @returns {Array}\n */\n getFunctions() {\n const ret = wasm.program_getFunctions(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Get a javascript object representation of the function inputs and types. This can be used\n * to generate a web form to capture user inputs for an execution of a function.\n *\n * @param {string} function_name Name of the function to get inputs for\n * @returns {Array} Array of function inputs\n *\n * @example\n * const expected_inputs = [\n * {\n * type:\"record\",\n * visibility:\"private\",\n * record:\"credits\",\n * members:[\n * {\n * name:\"microcredits\",\n * type:\"u64\",\n * visibility:\"private\"\n * }\n * ],\n * register:\"r0\"\n * },\n * {\n * type:\"address\",\n * visibility:\"private\",\n * register:\"r1\"\n * },\n * {\n * type:\"u64\",\n * visibility:\"private\",\n * register:\"r2\"\n * }\n * ];\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const transfer_function_inputs = credits_program.getFunctionInputs(\"transfer_private\");\n * console.log(transfer_function_inputs === expected_inputs); // Output should be \"true\"\n * @param {string} function_name\n * @returns {Array}\n */\n getFunctionInputs(function_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getFunctionInputs(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a the list of a program's mappings and the names/types of their keys and values.\n *\n * @returns {Array} - An array of objects representing the mappings in the program\n * @example\n * const expected_mappings = [\n * {\n * name: \"account\",\n * key_name: \"owner\",\n * key_type: \"address\",\n * value_name: \"microcredits\",\n * value_type: \"u64\"\n * }\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_mappings = credits_program.getMappings();\n * console.log(credits_mappings === expected_mappings); // Output should be \"true\"\n * @returns {Array}\n */\n getMappings() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_getMappings(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program record and its types\n *\n * @param {string} record_name Name of the record to get members for\n * @returns {Object} Object containing the record name, type, and members\n *\n * @example\n *\n * const expected_record = {\n * type: \"record\",\n * record: \"Credits\",\n * members: [\n * {\n * name: \"owner\",\n * type: \"address\",\n * visibility: \"private\"\n * },\n * {\n * name: \"microcredits\",\n * type: \"u64\",\n * visibility: \"private\"\n * }\n * ];\n * };\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_record = credits_program.getRecordMembers(\"Credits\");\n * console.log(credits_record === expected_record); // Output should be \"true\"\n * @param {string} record_name\n * @returns {object}\n */\n getRecordMembers(record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getRecordMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program struct and its types\n *\n * @param {string} struct_name Name of the struct to get members for\n * @returns {Array} Array containing the struct members\n *\n * @example\n *\n * const STRUCT_PROGRAM = \"program token_issue.aleo;\n *\n * struct token_metadata:\n * network as u32;\n * version as u32;\n *\n * struct token:\n * token_id as u32;\n * metadata as token_metadata;\n *\n * function no_op:\n * input r0 as u64;\n * output r0 as u64;\"\n *\n * const expected_struct_members = [\n * {\n * name: \"token_id\",\n * type: \"u32\",\n * },\n * {\n * name: \"metadata\",\n * type: \"struct\",\n * struct_id: \"token_metadata\",\n * members: [\n * {\n * name: \"network\",\n * type: \"u32\",\n * }\n * {\n * name: \"version\",\n * type: \"u32\",\n * }\n * ]\n * }\n * ];\n *\n * const program = aleo_wasm.Program.fromString(STRUCT_PROGRAM);\n * const struct_members = program.getStructMembers(\"token\");\n * console.log(struct_members === expected_struct_members); // Output should be \"true\"\n * @param {string} struct_name\n * @returns {Array}\n */\n getStructMembers(struct_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(struct_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getStructMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the credits.aleo program\n *\n * @returns {Program} The credits.aleo program\n * @returns {Program}\n */\n static getCreditsProgram() {\n const ret = wasm.program_getCreditsProgram();\n return Program.__wrap(ret);\n }\n /**\n * Get the id of the program\n *\n * @returns {string} The id of the program\n * @returns {string}\n */\n id() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_id(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get a unique address of the program\n *\n * @returns {Address} The address of the program\n * @returns {Address}\n */\n address() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_address(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Address.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determine equality with another program\n *\n * @param {Program} other The other program to compare\n * @returns {boolean} True if the programs are equal, false otherwise\n * @param {Program} other\n * @returns {boolean}\n */\n isEqual(other) {\n _assertClass(other, Program);\n const ret = wasm.program_isEqual(this.__wbg_ptr, other.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get program_imports\n *\n * @returns {Array} The program imports\n *\n * @example\n *\n * const DOUBLE_TEST = \"import multiply_test.aleo;\n *\n * program double_test.aleo;\n *\n * function double_it:\n * input r0 as u32.private;\n * call multiply_test.aleo/multiply 2u32 r0 into r1;\n * output r1 as u32.private;\";\n *\n * const expected_imports = [\n * \"multiply_test.aleo\"\n * ];\n *\n * const program = aleo_wasm.Program.fromString(DOUBLE_TEST_PROGRAM);\n * const imports = program.getImports();\n * console.log(imports === expected_imports); // Output should be \"true\"\n * @returns {Array}\n */\n getImports() {\n const ret = wasm.program_getImports(this.__wbg_ptr);\n return takeObject(ret);\n }\n}\n\nconst ProgramManagerFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_programmanager_free(ptr >>> 0));\n/**\n*/\nclass ProgramManager {\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramManagerFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_programmanager_free(ptr);\n }\n /**\n * Deploy an Aleo program\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being deployed\n * @param imports A javascript object holding the source code of any imported programs in the\n * form \\{\"program_name1\": \"program_source_code\", \"program_name2\": \"program_source_code\", ..\\}.\n * Note that all imported programs must be deployed on chain before the main program in order\n * for the deployment to succeed\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the program deployment in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildDeploymentTransaction(private_key, program, fee_credits, fee_record, url, imports, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n let ptr1 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr1 = fee_record.__destroy_into_raw();\n }\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr3 = fee_proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr4 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildDeploymentTransaction(private_key.__wbg_ptr, ptr0, len0, fee_credits, ptr1, ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the fee for a program deployment\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The source code of the program being deployed\n * @param imports (optional) Provide a list of imports to use for the deployment fee estimation\n * in the form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @returns {u64}\n * @param {string} program\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static estimateDeploymentFee(program, imports) {\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_estimateDeploymentFee(ptr0, len0, isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n /**\n * Estimate the component of the deployment cost which comes from the fee for the program name.\n * Note that this cost does not represent the entire cost of deployment. It is additional to\n * the cost of the size (in bytes) of the deployment.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param name The name of the program to be deployed\n * @returns {u64}\n * @param {string} name\n * @returns {bigint}\n */\n static estimateProgramNameCost(name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateProgramNameCost(retptr, ptr0, len0);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Execute an arbitrary function locally\n *\n * @param {PrivateKey} private_key The private key of the sender\n * @param {string} program The source code of the program being executed\n * @param {string} function The name of the function to execute\n * @param {Array} inputs A javascript array of inputs to the function\n * @param {boolean} prove_execution If true, the execution will be proven and an execution object\n * containing the proof and the encrypted inputs and outputs needed to verify the proof offline\n * will be returned.\n * @param {boolean} cache Cache the proving and verifying keys in the Execution response.\n * If this is set to 'true' the keys synthesized will be stored in the Execution Response\n * and the `ProvingKey` and `VerifyingKey` can be retrieved from the response via the `.getKeys()`\n * method.\n * @param {Object | undefined} imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param {ProvingKey | undefined} proving_key (optional) Provide a verifying key to use for the function execution\n * @param {VerifyingKey | undefined} verifying_key (optional) Provide a verifying key to use for the function execution\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {boolean} prove_execution\n * @param {boolean} cache\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {string | undefined} [url]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static executeFunctionOffline(private_key, program, _function, inputs, prove_execution, cache, imports, proving_key, verifying_key, url, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr2 = proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr3 = verifying_key.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_executeFunctionOffline(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), prove_execution, cache, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr2, ptr3, ptr4, len4, ptr5);\n return takeObject(ret);\n }\n /**\n * Execute Aleo function and create an Aleo execution transaction\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being executed\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * If this is set to 'true' the keys synthesized (or passed in as optional parameters via the\n * `proving_key` and `verifying_key` arguments) will be stored in the ProgramManager's memory\n * and used for subsequent transactions. If this is set to 'false' the proving and verifying\n * keys will be deallocated from memory after the transaction is executed.\n * @param imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the function execution\n * @param verifying_key (optional) Provide a verifying key to use for the function execution\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildExecutionTransaction(private_key, program, _function, inputs, fee_credits, fee_record, url, imports, proving_key, verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr4 = proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr5 = verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildExecutionTransaction(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), fee_credits, ptr2, ptr3, len3, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Estimate Fee for Aleo function execution. Note if \"cache\" is set to true, the proving and\n * verifying keys will be stored in the ProgramManager's memory and used for subsequent\n * program executions.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program to estimate the execution fee for\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the fee estimation in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the fee estimation\n * @param verifying_key (optional) Provide a verifying key to use for the fee estimation\n * @returns {u64} Fee in microcredits\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static estimateExecutionFee(private_key, program, _function, inputs, url, imports, proving_key, verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr3 = proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr4 = verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_estimateExecutionFee(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the finalize fee component for executing a function. This fee is additional to the\n * size of the execution of the program in bytes. If the function does not have a finalize\n * step, then the finalize fee is 0.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The program containing the function to estimate the finalize fee for\n * @param function The function to estimate the finalize fee for\n * @returns {u64} Fee in microcredits\n * @param {string} program\n * @param {string} _function\n * @returns {bigint}\n */\n static estimateFinalizeFee(program, _function) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateFinalizeFee(retptr, ptr0, len0, ptr1, len1);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Join two records together to create a new record with an amount of credits equal to the sum\n * of the credits of the two original records\n *\n * @param private_key The private key of the sender\n * @param record_1 The first record to combine\n * @param record_2 The second record to combine\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param join_proving_key (optional) Provide a proving key to use for the join function\n * @param join_verifying_key (optional) Provide a verifying key to use for the join function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction} Transaction object\n * @param {PrivateKey} private_key\n * @param {RecordPlaintext} record_1\n * @param {RecordPlaintext} record_2\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [join_proving_key]\n * @param {VerifyingKey | undefined} [join_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildJoinTransaction(private_key, record_1, record_2, fee_credits, fee_record, url, join_proving_key, join_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(record_1, RecordPlaintext);\n var ptr0 = record_1.__destroy_into_raw();\n _assertClass(record_2, RecordPlaintext);\n var ptr1 = record_2.__destroy_into_raw();\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(join_proving_key)) {\n _assertClass(join_proving_key, ProvingKey);\n ptr4 = join_proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(join_verifying_key)) {\n _assertClass(join_verifying_key, VerifyingKey);\n ptr5 = join_verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildJoinTransaction(private_key.__wbg_ptr, ptr0, ptr1, fee_credits, ptr2, ptr3, len3, ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Split an Aleo credits record into two separate records. This function does not require a fee.\n *\n * @param private_key The private key of the sender\n * @param split_amount The amount of the credit split. This amount will be subtracted from the\n * value of the record and two new records will be created with the split amount and the remainder\n * @param amount_record The record to split\n * @param url The url of the Aleo network node to send the transaction to\n * @param split_proving_key (optional) Provide a proving key to use for the split function\n * @param split_verifying_key (optional) Provide a verifying key to use for the split function\n * @returns {Transaction} Transaction object\n * @param {PrivateKey} private_key\n * @param {number} split_amount\n * @param {RecordPlaintext} amount_record\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [split_proving_key]\n * @param {VerifyingKey | undefined} [split_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildSplitTransaction(private_key, split_amount, amount_record, url, split_proving_key, split_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(amount_record, RecordPlaintext);\n var ptr0 = amount_record.__destroy_into_raw();\n var ptr1 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(split_proving_key)) {\n _assertClass(split_proving_key, ProvingKey);\n ptr2 = split_proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(split_verifying_key)) {\n _assertClass(split_verifying_key, VerifyingKey);\n ptr3 = split_verifying_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr4 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildSplitTransaction(private_key.__wbg_ptr, split_amount, ptr0, ptr1, len1, ptr2, ptr3, ptr4);\n return takeObject(ret);\n }\n /**\n * Send credits from one Aleo account to another\n *\n * @param private_key The private key of the sender\n * @param amount_credits The amount of credits to send\n * @param recipient The recipient of the transaction\n * @param transfer_type The type of the transfer (options: \"private\", \"public\", \"private_to_public\", \"public_to_private\")\n * @param amount_record The record to fund the amount from\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param transfer_verifying_key (optional) Provide a verifying key to use for the transfer\n * function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction}\n * @param {PrivateKey} private_key\n * @param {number} amount_credits\n * @param {string} recipient\n * @param {string} transfer_type\n * @param {RecordPlaintext | undefined} amount_record\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [transfer_proving_key]\n * @param {VerifyingKey | undefined} [transfer_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildTransferTransaction(private_key, amount_credits, recipient, transfer_type, amount_record, fee_credits, fee_record, url, transfer_proving_key, transfer_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(recipient, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(transfer_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(amount_record)) {\n _assertClass(amount_record, RecordPlaintext);\n ptr2 = amount_record.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr3 = fee_record.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(transfer_proving_key)) {\n _assertClass(transfer_proving_key, ProvingKey);\n ptr5 = transfer_proving_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(transfer_verifying_key)) {\n _assertClass(transfer_verifying_key, VerifyingKey);\n ptr6 = transfer_verifying_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr7 = fee_proving_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr8 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr9 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr9 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildTransferTransaction(private_key.__wbg_ptr, amount_credits, ptr0, len0, ptr1, len1, ptr2, fee_credits, ptr3, ptr4, len4, ptr5, ptr6, ptr7, ptr8, ptr9);\n return takeObject(ret);\n }\n /**\n * Synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code of the program to synthesize keys for\n * @param function_id {string} The function to synthesize keys for\n * @param inputs {Array} The inputs to the function\n * @param imports {Object | undefined} The imports for the program\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} function_id\n * @param {Array} inputs\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static synthesizeKeyPair(private_key, program, function_id, inputs, imports) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_synthesizeKeyPair(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n}\n\nconst ProvingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_provingkey_free(ptr >>> 0));\n/**\n* Proving key for a function within an Aleo program\n*/\nclass ProvingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ProvingKey.prototype);\n obj.__wbg_ptr = ptr;\n ProvingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProvingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_provingkey_free(ptr);\n }\n /**\n * Verify if the proving key is for the bond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_public_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_public function, false if otherwise\n * @returns {boolean}\n */\n isBondPublicProver() {\n const ret = wasm.provingkey_isBondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the bond_validator function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_validator_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_validator function, false if otherwise\n * @returns {boolean}\n */\n isBondValidatorProver() {\n const ret = wasm.provingkey_isBondValidatorProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the claim_unbond function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"claim_unbond_proving_key.bin\");\n * provingKey.isClaimUnbondProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the claim_unbond function, false if otherwise\n * @returns {boolean}\n */\n isClaimUnbondPublicProver() {\n const ret = wasm.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_private_proving_key.bin\");\n * provingKey.isFeePrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_private function, false if otherwise\n * @returns {boolean}\n */\n isFeePrivateProver() {\n const ret = wasm.provingkey_isFeePrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_public_proving_key.bin\");\n * provingKey.isFeePublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_public function, false if otherwise\n * @returns {boolean}\n */\n isFeePublicProver() {\n const ret = wasm.provingkey_isFeePublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the inclusion function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"inclusion_proving_key.bin\");\n * provingKey.isInclusionProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the inclusion function, false if otherwise\n * @returns {boolean}\n */\n isInclusionProver() {\n const ret = wasm.provingkey_isInclusionProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the join function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"join_proving_key.bin\");\n * provingKey.isJoinProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the join function, false if otherwise\n * @returns {boolean}\n */\n isJoinProver() {\n const ret = wasm.provingkey_isJoinProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the set_validator_state function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"set_validator_set_proving_key.bin\");\n * provingKey.isSetValidatorStateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the set_validator_state function, false if otherwise\n * @returns {boolean}\n */\n isSetValidatorStateProver() {\n const ret = wasm.provingkey_isSetValidatorStateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the split function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"split_proving_key.bin\");\n * provingKey.isSplitProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the split function, false if otherwise\n * @returns {boolean}\n */\n isSplitProver() {\n const ret = wasm.provingkey_isSplitProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_proving_key.bin\");\n * provingKey.isTransferPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateProver() {\n const ret = wasm.provingkey_isTransferPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private_to_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_to_public_proving_key.bin\");\n * provingKey.isTransferPrivateToPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private_to_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateToPublicProver() {\n const ret = wasm.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_proving_key.bin\");\n * provingKey.isTransferPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicProver() {\n const ret = wasm.provingkey_isTransferPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_as_signer function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_as_signer_proving_key.bin\");\n * provingKey.isTransferPublicAsSignerProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicAsSignerProver() {\n const ret = wasm.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_to_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_to_private_proving_key.bin\");\n * provingKey.isTransferPublicToPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public_to_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicToPrivateProver() {\n const ret = wasm.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the unbond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"unbond_public.bin\");\n * provingKey.isUnbondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the unbond_public_prover function, false if otherwise\n * @returns {boolean}\n */\n isUnbondPublicProver() {\n const ret = wasm.provingkey_isUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Return the checksum of the proving key\n *\n * @returns {string} Checksum of the proving key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the proving key\n *\n * @returns {ProvingKey} A copy of the proving key\n * @returns {ProvingKey}\n */\n copy() {\n const ret = wasm.provingkey_copy(this.__wbg_ptr);\n return ProvingKey.__wrap(ret);\n }\n /**\n * Construct a new proving key from a byte array\n *\n * @param {Uint8Array} bytes Byte array representation of a proving key\n * @returns {ProvingKey}\n * @param {Uint8Array} bytes\n * @returns {ProvingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a proving key from string\n *\n * @param {string} String representation of the proving key\n * @param {string} string\n * @returns {ProvingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the byte representation of a proving key\n *\n * @returns {Uint8Array} Byte array representation of a proving key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the proving key\n *\n * @returns {string} String representation of the proving key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst RecordCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordciphertext_free(ptr >>> 0));\n/**\n* Encrypted Aleo record\n*/\nclass RecordCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n RecordCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordciphertext_free(ptr);\n }\n /**\n * Create a record ciphertext from a string\n *\n * @param {string} record String representation of a record ciphertext\n * @returns {RecordCiphertext} Record ciphertext\n * @param {string} record\n * @returns {RecordCiphertext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the string reprensentation of the record ciphertext\n *\n * @returns {string} String representation of the record ciphertext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Decrypt the record ciphertext into plaintext using the view key. The record will only\n * decrypt if the record was encrypted by the account corresponding to the view key\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {RecordPlaintext} Record plaintext object\n * @param {ViewKey} view_key\n * @returns {RecordPlaintext}\n */\n decrypt(view_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(view_key, ViewKey);\n wasm.recordciphertext_decrypt(retptr, this.__wbg_ptr, view_key.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determines if the account corresponding to the view key is the owner of the record\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {boolean}\n * @param {ViewKey} view_key\n * @returns {boolean}\n */\n isOwner(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.recordciphertext_isOwner(this.__wbg_ptr, view_key.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst RecordPlaintextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordplaintext_free(ptr >>> 0));\n/**\n* Plaintext representation of an Aleo record\n*/\nclass RecordPlaintext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordPlaintext.prototype);\n obj.__wbg_ptr = ptr;\n RecordPlaintextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordPlaintextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordplaintext_free(ptr);\n }\n /**\n * @param {string} program_id\n * @param {string} record_name\n * @returns {Field}\n */\n commitment(program_id, record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_commitment(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return a record plaintext from a string.\n *\n * @param {string} record String representation of a plaintext representation of an Aleo record\n * @returns {RecordPlaintext} Record plaintext\n * @param {string} record\n * @returns {RecordPlaintext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordplaintext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the record plaintext string\n *\n * @returns {string} String representation of the record plaintext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the amount of microcredits in the record\n *\n * @returns {u64} Amount of microcredits in the record\n * @returns {bigint}\n */\n microcredits() {\n const ret = wasm.recordplaintext_microcredits(this.__wbg_ptr);\n return BigInt.asUintN(64, ret);\n }\n /**\n * Returns the nonce of the record. This can be used to uniquely identify a record.\n *\n * @returns {string} Nonce of the record\n * @returns {string}\n */\n nonce() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_nonce(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Attempt to get the serial number of a record to determine whether or not is has been spent\n *\n * @param {PrivateKey} private_key Private key of the account that owns the record\n * @param {string} program_id Program ID of the program that the record is associated with\n * @param {string} record_name Name of the record\n * @returns {string} Serial number of the record\n * @param {PrivateKey} private_key\n * @param {string} program_id\n * @param {string} record_name\n * @returns {string}\n */\n serialNumberString(private_key, program_id, record_name) {\n let deferred4_0;\n let deferred4_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_serialNumberString(retptr, this.__wbg_ptr, private_key.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr3 = r0;\n var len3 = r1;\n if (r3) {\n ptr3 = 0; len3 = 0;\n throw takeObject(r2);\n }\n deferred4_0 = ptr3;\n deferred4_1 = len3;\n return getStringFromWasm0(ptr3, len3);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred4_0, deferred4_1, 1);\n }\n }\n}\n\nconst SignatureFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_signature_free(ptr >>> 0));\n/**\n* Cryptographic signature of a message signed by an Aleo account\n*/\nclass Signature {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Signature.prototype);\n obj.__wbg_ptr = ptr;\n SignatureFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n SignatureFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_signature_free(ptr);\n }\n /**\n * Sign a message with a private key\n *\n * @param {PrivateKey} private_key The private key to sign the message with\n * @param {Uint8Array} message Byte representation of the message to sign\n * @returns {Signature} Signature of the message\n * @param {PrivateKey} private_key\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n static sign(private_key, message) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(private_key.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Verify a signature of a message with an address\n *\n * @param {Address} address The address to verify the signature with\n * @param {Uint8Array} message Byte representation of the message to verify\n * @returns {boolean} True if the signature is valid, false otherwise\n * @param {Address} address\n * @param {Uint8Array} message\n * @returns {boolean}\n */\n verify(address, message) {\n _assertClass(address, Address);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_verify(this.__wbg_ptr, address.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get a signature from a string representation of a signature\n *\n * @param {string} signature String representation of a signature\n * @returns {Signature} Signature\n * @param {string} signature\n * @returns {Signature}\n */\n static from_string(signature) {\n const ptr0 = passStringToWasm0(signature, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_from_string(ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a string representation of a signature\n *\n * @returns {string} String representation of a signature\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.signature_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst TransactionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_transaction_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo transaction\n*\n* This object is created when generating an on-chain function deployment or execution and is the\n* object that should be submitted to the Aleo Network in order to deploy or execute a function.\n*/\nclass Transaction {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Transaction.prototype);\n obj.__wbg_ptr = ptr;\n TransactionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n TransactionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_transaction_free(ptr);\n }\n /**\n * Create a transaction from a string\n *\n * @param {string} transaction String representation of a transaction\n * @returns {Transaction}\n * @param {string} transaction\n * @returns {Transaction}\n */\n static fromString(transaction) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(transaction, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.transaction_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Transaction.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the transaction as a string. If you want to submit this transaction to the Aleo Network\n * this function will create the string that should be submitted in the `POST` data.\n *\n * @returns {string} String representation of the transaction\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the id of the transaction. This is the merkle root of the transaction's inclusion proof.\n *\n * This value can be used to query the status of the transaction on the Aleo Network to see\n * if it was successful. If successful, the transaction will be included in a block and this\n * value can be used to lookup the transaction data on-chain.\n *\n * @returns {string} Transaction id\n * @returns {string}\n */\n transactionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the type of the transaction (will return \"deploy\" or \"execute\")\n *\n * @returns {string} Transaction type\n * @returns {string}\n */\n transactionType() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionType(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst VerifyingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_verifyingkey_free(ptr >>> 0));\n/**\n* Verifying key for a function within an Aleo program\n*/\nclass VerifyingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(VerifyingKey.prototype);\n obj.__wbg_ptr = ptr;\n VerifyingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n VerifyingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_verifyingkey_free(ptr);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {VerifyingKey}\n */\n static bondPublicVerifier() {\n const ret = wasm.verifyingkey_bondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {VerifyingKey}\n */\n static bondValidatorVerifier() {\n const ret = wasm.verifyingkey_bondValidatorVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the claim_delegator function\n *\n * @returns {VerifyingKey} Verifying key for the claim_unbond_public function\n * @returns {VerifyingKey}\n */\n static claimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_claimUnbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_private function\n *\n * @returns {VerifyingKey} Verifying key for the fee_private function\n * @returns {VerifyingKey}\n */\n static feePrivateVerifier() {\n const ret = wasm.verifyingkey_feePrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_public function\n *\n * @returns {VerifyingKey} Verifying key for the fee_public function\n * @returns {VerifyingKey}\n */\n static feePublicVerifier() {\n const ret = wasm.verifyingkey_feePublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the inclusion function\n *\n * @returns {VerifyingKey} Verifying key for the inclusion function\n * @returns {VerifyingKey}\n */\n static inclusionVerifier() {\n const ret = wasm.verifyingkey_inclusionVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the join function\n *\n * @returns {VerifyingKey} Verifying key for the join function\n * @returns {VerifyingKey}\n */\n static joinVerifier() {\n const ret = wasm.verifyingkey_joinVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the set_validator_state function\n *\n * @returns {VerifyingKey} Verifying key for the set_validator_state function\n * @returns {VerifyingKey}\n */\n static setValidatorStateVerifier() {\n const ret = wasm.verifyingkey_setValidatorStateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the split function\n *\n * @returns {VerifyingKey} Verifying key for the split function\n * @returns {VerifyingKey}\n */\n static splitVerifier() {\n const ret = wasm.verifyingkey_splitVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private function\n * @returns {VerifyingKey}\n */\n static transferPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private_to_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private_to_public function\n * @returns {VerifyingKey}\n */\n static transferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_transferPrivateToPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public function\n * @returns {VerifyingKey}\n */\n static transferPublicVerifier() {\n const ret = wasm.verifyingkey_transferPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_as_signer function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_as_signer function\n * @returns {VerifyingKey}\n */\n static transferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_transferPublicAsSignerVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_to_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_to_private function\n * @returns {VerifyingKey}\n */\n static transferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPublicToPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the unbond_public function\n *\n * @returns {VerifyingKey} Verifying key for the unbond_public function\n * @returns {VerifyingKey}\n */\n static unbondPublicVerifier() {\n const ret = wasm.verifyingkey_unbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {boolean}\n */\n isBondPublicVerifier() {\n const ret = wasm.verifyingkey_isBondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {boolean}\n */\n isBondValidatorVerifier() {\n const ret = wasm.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the claim_delegator function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isClaimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePrivateVerifier() {\n const ret = wasm.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePublicVerifier() {\n const ret = wasm.verifyingkey_isFeePublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the inclusion function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isInclusionVerifier() {\n const ret = wasm.verifyingkey_isInclusionVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the join function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isJoinVerifier() {\n const ret = wasm.verifyingkey_isJoinVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the set_validator_state function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSetValidatorStateVerifier() {\n const ret = wasm.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the split function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSplitVerifier() {\n const ret = wasm.verifyingkey_isSplitVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private_to_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_as_signer function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_to_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the unbond_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get the checksum of the verifying key\n *\n * @returns {string} Checksum of the verifying key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the verifying key\n *\n * @returns {VerifyingKey} A copy of the verifying key\n * @returns {VerifyingKey}\n */\n copy() {\n const ret = wasm.verifyingkey_copy(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Construct a new verifying key from a byte array\n *\n * @param {Uint8Array} bytes Byte representation of a verifying key\n * @returns {VerifyingKey}\n * @param {Uint8Array} bytes\n * @returns {VerifyingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a verifying key from string\n *\n * @param {String} string String representation of a verifying key\n * @returns {VerifyingKey}\n * @param {string} string\n * @returns {VerifyingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a byte array from a verifying key\n *\n * @returns {Uint8Array} Byte representation of a verifying key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the verifying key\n *\n * @returns {String} String representation of the verifying key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst ViewKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_viewkey_free(ptr >>> 0));\n/**\n*/\nclass ViewKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ViewKey.prototype);\n obj.__wbg_ptr = ptr;\n ViewKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ViewKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_viewkey_free(ptr);\n }\n /**\n * Create a new view key from a private key\n *\n * @param {PrivateKey} private_key Private key\n * @returns {ViewKey} View key\n * @param {PrivateKey} private_key\n * @returns {ViewKey}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.privatekey_to_view_key(private_key.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Create a new view key from a string representation of a view key\n *\n * @param {string} view_key String representation of a view key\n * @returns {ViewKey} View key\n * @param {string} view_key\n * @returns {ViewKey}\n */\n static from_string(view_key) {\n const ptr0 = passStringToWasm0(view_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.viewkey_from_string(ptr0, len0);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get a string representation of a view key\n *\n * @returns {string} String representation of a view key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.viewkey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the address corresponding to a view key\n *\n * @returns {Address} Address\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.address_from_view_key(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Decrypt a record ciphertext with a view key\n *\n * @param {string} ciphertext String representation of a record ciphertext\n * @returns {string} String representation of a record plaintext\n * @param {string} ciphertext\n * @returns {string}\n */\n decrypt(ciphertext) {\n let deferred3_0;\n let deferred3_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.viewkey_decrypt(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr2 = r0;\n var len2 = r1;\n if (r3) {\n ptr2 = 0; len2 = 0;\n throw takeObject(r2);\n }\n deferred3_0 = ptr2;\n deferred3_1 = len2;\n return getStringFromWasm0(ptr2, len2);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);\n }\n }\n}\n\nasync function __wbg_load(module, imports) {\n if (typeof Response === 'function' && module instanceof Response) {\n if (typeof WebAssembly.instantiateStreaming === 'function') {\n try {\n return await WebAssembly.instantiateStreaming(module, imports);\n\n } catch (e) {\n if (module.headers.get('Content-Type') != 'application/wasm') {\n console.warn(\"`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n\", e);\n\n } else {\n throw e;\n }\n }\n }\n\n const bytes = await module.arrayBuffer();\n return await WebAssembly.instantiate(bytes, imports);\n\n } else {\n const instance = await WebAssembly.instantiate(module, imports);\n\n if (instance instanceof WebAssembly.Instance) {\n return { instance, module };\n\n } else {\n return instance;\n }\n }\n}\n\nfunction __wbg_get_imports() {\n const imports = {};\n imports.wbg = {};\n imports.wbg.__wbindgen_object_drop_ref = function(arg0) {\n takeObject(arg0);\n };\n imports.wbg.__wbg_new_71801a555ad9f2aa = function() { return handleError(function () {\n const ret = new XMLHttpRequest();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_overrideMimeType_ee9c51919ceb418b = function() { return handleError(function (arg0, arg1, arg2) {\n getObject(arg0).overrideMimeType(getStringFromWasm0(arg1, arg2));\n }, arguments) };\n imports.wbg.__wbg_open_c9eb0cf2c9d95679 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {\n getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), arg5 !== 0);\n }, arguments) };\n imports.wbg.__wbg_send_80d29985093c1ec5 = function() { return handleError(function (arg0) {\n getObject(arg0).send();\n }, arguments) };\n imports.wbg.__wbg_response_7c2e2759084f7279 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).response;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_status_d485fb5a478426fb = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).status;\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_72fb9a18b5ae2624 = function() {\n const ret = new Object();\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_string_new = function(arg0, arg1) {\n const ret = getStringFromWasm0(arg0, arg1);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_1f9b04f170055d33 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_ab6fd82b10560829 = function() { return handleError(function () {\n const ret = new Headers();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_object_clone_ref = function(arg0) {\n const ret = getObject(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_0d76b0581eca6298 = function() { return handleError(function () {\n const ret = new AbortController();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_signal_a61f78a3478fd9bc = function(arg0) {\n const ret = getObject(arg0).signal;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_append_7bfcb4937d1d5e29 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {\n getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));\n }, arguments) };\n imports.wbg.__wbg_instanceof_Response_849eb93e75734b6e = function(arg0) {\n let result;\n try {\n result = getObject(arg0) instanceof Response;\n } catch (_) {\n result = false;\n }\n const ret = result;\n return ret;\n };\n imports.wbg.__wbg_status_61a01141acd3cf74 = function(arg0) {\n const ret = getObject(arg0).status;\n return ret;\n };\n imports.wbg.__wbg_url_5f6dc4009ac5f99d = function(arg0, arg1) {\n const ret = getObject(arg1).url;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_headers_9620bfada380764a = function(arg0) {\n const ret = getObject(arg0).headers;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_iterator_2cee6dadfd956dfa = function() {\n const ret = Symbol.iterator;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_get_e3c254076557e348 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.get(getObject(arg0), getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_function = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'function';\n return ret;\n };\n imports.wbg.__wbg_call_27c0f87801dedf93 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg0).call(getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_object = function(arg0) {\n const val = getObject(arg0);\n const ret = typeof(val) === 'object' && val !== null;\n return ret;\n };\n imports.wbg.__wbg_next_40fc327bfc8770e6 = function(arg0) {\n const ret = getObject(arg0).next;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_next_196c84450b364254 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).next();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_done_298b57d23c0fc80c = function(arg0) {\n const ret = getObject(arg0).done;\n return ret;\n };\n imports.wbg.__wbg_value_d93c65011f51a456 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_abort_2aa7521d5690750e = function(arg0) {\n getObject(arg0).abort();\n };\n imports.wbg.__wbg_stringify_8887fe74e1c50d81 = function() { return handleError(function (arg0) {\n const ret = JSON.stringify(getObject(arg0));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_string_get = function(arg0, arg1) {\n const obj = getObject(arg1);\n const ret = typeof(obj) === 'string' ? obj : undefined;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_log_0159ca40cddf5b15 = function(arg0, arg1) {\n console.log(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {\n const ret = BigInt.asUintN(64, arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_call_b3ca7c6051f9bec1 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_module = function() {\n const ret = __wbg_init.__wbindgen_wasm_module;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_memory = function() {\n const ret = wasm.memory;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a = function(arg0, arg1, arg2, arg3) {\n const ret = spawnWorker(getObject(arg0), getObject(arg1), getObject(arg2), arg3 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_executionresponse_new = function(arg0) {\n const ret = ExecutionResponse.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_keypair_new = function(arg0) {\n const ret = KeyPair.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_transaction_new = function(arg0) {\n const ret = Transaction.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_66ae46612e7f0234 = function(arg0) {\n const ret = new Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_d4638f722068f043 = function(arg0, arg1, arg2) {\n getObject(arg0)[arg1 >>> 0] = takeObject(arg2);\n };\n imports.wbg.__wbindgen_cb_drop = function(arg0) {\n const obj = takeObject(arg0).original;\n if (obj.cnt-- == 1) {\n obj.a = 0;\n return true;\n }\n const ret = false;\n return ret;\n };\n imports.wbg.__wbg_new_16b304a2cfa7ff4a = function() {\n const ret = new Array();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_push_a5b05aedc7234f9f = function(arg0, arg1) {\n const ret = getObject(arg0).push(getObject(arg1));\n return ret;\n };\n imports.wbg.__wbg_arrayBuffer_29931d52c7206b02 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).arrayBuffer();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_new_63b92bc8671ed464 = function(arg0) {\n const ret = new Uint8Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_c20a40f15020d68a = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_new_81740750da40724f = function(arg0, arg1) {\n try {\n var state0 = {a: arg0, b: arg1};\n var cb0 = (arg0, arg1) => {\n const a = state0.a;\n state0.a = 0;\n try {\n return __wbg_adapter_281(a, state0.b, arg0, arg1);\n } finally {\n state0.a = a;\n }\n };\n const ret = new Promise(cb0);\n return addHeapObject(ret);\n } finally {\n state0.a = state0.b = 0;\n }\n };\n imports.wbg.__wbindgen_number_new = function(arg0) {\n const ret = arg0;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_abda76e883ba8a5f = function() {\n const ret = new Error();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_stack_658279fe44541cf6 = function(arg0, arg1) {\n const ret = getObject(arg1).stack;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {\n let deferred0_0;\n let deferred0_1;\n try {\n deferred0_0 = arg0;\n deferred0_1 = arg1;\n console.error(getStringFromWasm0(arg0, arg1));\n } finally {\n wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);\n }\n };\n imports.wbg.__wbg_buffer_12d079cc21e14bdb = function(arg0) {\n const ret = getObject(arg0).buffer;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb = function(arg0, arg1, arg2) {\n const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_randomFillSync_5c9c955aa56b6049 = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).randomFillSync(takeObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_subarray_a1f73cd4b5b42fe1 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_getRandomValues_3aa56aa6edec874c = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).getRandomValues(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_set_a47bac70306a19a7 = function(arg0, arg1, arg2) {\n getObject(arg0).set(getObject(arg1), arg2 >>> 0);\n };\n imports.wbg.__wbg_crypto_1d1f22824a6a080c = function(arg0) {\n const ret = getObject(arg0).crypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_process_4a72847cc503995b = function(arg0) {\n const ret = getObject(arg0).process;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_versions_f686565e586dd935 = function(arg0) {\n const ret = getObject(arg0).versions;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_node_104a2ff8d6ea03a2 = function(arg0) {\n const ret = getObject(arg0).node;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_is_string = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'string';\n return ret;\n };\n imports.wbg.__wbg_require_cca90b1a94a0255b = function() { return handleError(function () {\n const ret = module.require;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_msCrypto_eb05e62b530a1508 = function(arg0) {\n const ret = getObject(arg0).msCrypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_e9b4878cebadb3d3 = function(arg0) {\n const ret = new Uint8Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_cd7af8117672b8b8 = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_get_bd8e338fbd5f5cc8 = function(arg0, arg1) {\n const ret = getObject(arg0)[arg1 >>> 0];\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_self_ce0dbfc45cf2f5be = function() { return handleError(function () {\n const ret = self.self;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_window_c6fb939a7f436783 = function() { return handleError(function () {\n const ret = window.window;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_globalThis_d1e6af4856ba331b = function() { return handleError(function () {\n const ret = globalThis.globalThis;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_global_207b558942527489 = function() { return handleError(function () {\n const ret = global.global;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_undefined = function(arg0) {\n const ret = getObject(arg0) === undefined;\n return ret;\n };\n imports.wbg.__wbg_newnoargs_e258087cd0daa0ea = function(arg0, arg1) {\n const ret = new Function(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_has_0af94d20077affa2 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.has(getObject(arg0), getObject(arg1));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_fetch_bc7c8e27076a5c84 = function(arg0) {\n const ret = fetch(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_fetch_921fad6ef9e883dd = function(arg0, arg1) {\n const ret = getObject(arg0).fetch(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {\n const ret = debugString(getObject(arg1));\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbindgen_throw = function(arg0, arg1) {\n throw new Error(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_rethrow = function(arg0) {\n throw takeObject(arg0);\n };\n imports.wbg.__wbg_then_a73caa9a87991566 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_then_0c86a60e8fcfe9f6 = function(arg0, arg1) {\n const ret = getObject(arg0).then(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_queueMicrotask_481971b0d87f3dd4 = function(arg0) {\n queueMicrotask(getObject(arg0));\n };\n imports.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6 = function(arg0) {\n const ret = getObject(arg0).queueMicrotask;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_resolve_b0083a7967828ec8 = function(arg0) {\n const ret = Promise.resolve(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_5d743fc9058ba01a = function() {\n const ret = Atomics.waitAsync;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_8cccba86b0f574cb = function(arg0) {\n const ret = new Int32Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_46d5c36955b71a79 = function(arg0, arg1, arg2) {\n const ret = Atomics.waitAsync(getObject(arg0), arg1, arg2);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_async_19c0400d97cc72fe = function(arg0) {\n const ret = getObject(arg0).async;\n return ret;\n };\n imports.wbg.__wbg_value_571d60108110e917 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_link_fc1eedd35dc7e0a6 = function(arg0) {\n const ret = \"data:application/javascript,\" + encodeURIComponent(`onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n `);\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_new_d1187ae36d662ef9 = function() { return handleError(function (arg0, arg1) {\n const ret = new Worker(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_setonmessage_503809e5bb51bd33 = function(arg0, arg1) {\n getObject(arg0).onmessage = getObject(arg1);\n };\n imports.wbg.__wbg_of_6a70eed8d41f469c = function(arg0, arg1, arg2) {\n const ret = Array.of(getObject(arg0), getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_postMessage_7380d10e8b8269df = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).postMessage(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_data_3ce7c145ca4fbcdc = function(arg0) {\n const ret = getObject(arg0).data;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_responseText_c67ed2d48db10769 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg1).responseText;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n }, arguments) };\n imports.wbg.__wbindgen_closure_wrapper5975 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 622, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_closure_wrapper6001 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 622, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n\n return imports;\n}\n\nfunction __wbg_init_memory(imports, maybe_memory) {\n imports.wbg.memory = maybe_memory || new WebAssembly.Memory({initial:25,maximum:65536,shared:true});\n}\n\nfunction __wbg_finalize_init(instance, module) {\n wasm = instance.exports;\n __wbg_init.__wbindgen_wasm_module = module;\n cachedBigInt64Memory0 = null;\n cachedInt32Memory0 = null;\n cachedUint8Memory0 = null;\n\n wasm.__wbindgen_start();\n return wasm;\n}\n\nfunction initSync(module, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n const imports = __wbg_get_imports();\n\n __wbg_init_memory(imports, maybe_memory);\n\n if (!(module instanceof WebAssembly.Module)) {\n module = new WebAssembly.Module(module);\n }\n\n const instance = new WebAssembly.Instance(module, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nasync function __wbg_init(input, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n\n const imports = __wbg_get_imports();\n\n if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {\n input = fetch(input);\n }\n\n __wbg_init_memory(imports, maybe_memory);\n\n const { instance, module } = await __wbg_load(await input, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nvar exports = /*#__PURE__*/Object.freeze({\n __proto__: null,\n Address: Address,\n Execution: Execution,\n ExecutionResponse: ExecutionResponse,\n Field: Field,\n KeyPair: KeyPair,\n Metadata: Metadata,\n OfflineQuery: OfflineQuery,\n PrivateKey: PrivateKey,\n PrivateKeyCiphertext: PrivateKeyCiphertext,\n Program: Program,\n ProgramManager: ProgramManager,\n ProvingKey: ProvingKey,\n RecordCiphertext: RecordCiphertext,\n RecordPlaintext: RecordPlaintext,\n Signature: Signature,\n Transaction: Transaction,\n VerifyingKey: VerifyingKey,\n ViewKey: ViewKey,\n default: __wbg_init,\n initSync: initSync,\n initThreadPool: initThreadPool,\n runRayonThread: runRayonThread,\n verifyFunctionExecution: verifyFunctionExecution\n});\n\nconst wasm_path = \"aleo_wasm.wasm\";\n\n \n var Cargo = async (opt = {}) => {\n let {importHook, serverPath, initializeHook} = opt;\n\n let final_path = wasm_path;\n\n if (serverPath != null) {\n final_path = serverPath + /[^\\/\\\\]*$/.exec(final_path)[0];\n }\n\n if (importHook != null) {\n final_path = importHook(final_path);\n }\n\n if (initializeHook != null) {\n await initializeHook(__wbg_init, final_path);\n\n } else {\n await __wbg_init(final_path);\n }\n\n return exports;\n };\n\nexport { Cargo as default };\n//# sourceMappingURL=aleo_wasm.js.map\n"],"names":["spawnWorker","url","module","memory","address","Promise","resolve","worker","Worker","type","addEventListener","event","setTimeout","unref","capture","once","postMessage","wasm","heap","Array","fill","undefined","getObject","idx","push","heap_next","length","dropObject","takeObject","ret","cachedTextDecoder","TextDecoder","ignoreBOM","fatal","decode","Error","cachedUint8Memory0","getUint8Memory0","buffer","Uint8Array","getStringFromWasm0","ptr","len","slice","addHeapObject","obj","WASM_VECTOR_LEN","cachedTextEncoder","TextEncoder","encode","encodeString","arg","view","buf","set","read","written","passStringToWasm0","malloc","realloc","subarray","mem","offset","code","charCodeAt","isLikeNone","x","cachedInt32Memory0","getInt32Memory0","Int32Array","debugString","val","description","name","isArray","debug","i","builtInMatches","exec","toString","call","className","JSON","stringify","_","message","stack","CLOSURE_DTORS","FinalizationRegistry","register","unregister","state","__wbindgen_export_3","get","dtor","a","b","makeMutClosure","arg0","arg1","f","cnt","real","args","original","__wbg_adapter_34","arg2","_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha51b8a0cd6570266","_assertClass","instance","klass","passArray8ToWasm0","verifyFunctionExecution$1","execution","verifying_key","program","function_id","retptr","__wbindgen_add_to_stack_pointer","Execution$1","VerifyingKey$1","Program$1","ptr0","__wbindgen_malloc","__wbindgen_realloc","len0","verifyFunctionExecution","__wbg_ptr","r0","r1","cachedBigInt64Memory0","getBigInt64Memory0","BigInt64Array","getArrayU8FromWasm0","runRayonThread","receiver","initThreadPool$1","num_threads","initThreadPool","handleError","apply","this","e","__wbindgen_exn_store","__wbg_adapter_281","arg3","wasm_bindgen__convert__closures__invoke2_mut__h823ad1ce2c4b384e","AddressFinalization","__wbg_address_free","Address","__wrap","Object","create","prototype","__destroy_into_raw","free","from_private_key","private_key","PrivateKey$1","address_from_private_key","from_view_key","view_key","ViewKey$1","address_from_view_key","from_string","address_from_string","to_string","deferred1_0","deferred1_1","address_to_string","__wbindgen_free","verify","signature","Signature$1","address_verify","ExecutionFinalization","__wbg_execution_free","Execution","execution_toString","fromString","execution_fromString","ExecutionResponseFinalization","__wbg_executionresponse_free","ExecutionResponse","getOutputs","executionresponse_getOutputs","getExecution","executionresponse_getExecution","getKeys","executionresponse_getKeys","KeyPair","getProvingKey","executionresponse_getProvingKey","ProvingKey$1","getVerifyingKey","executionresponse_getVerifyingKey","getFunctionId","executionresponse_getFunctionId","getProgram","executionresponse_getProgram","FieldFinalization","__wbg_field_free","Field","field_toString","field","field_fromString","KeyPairFinalization","__wbg_keypair_free","constructor","proving_key","ptr1","keypair_new","provingKey","keypair_provingKey","verifyingKey","keypair_verifyingKey","MetadataFinalization","__wbg_metadata_free","Metadata","__wbg_get_metadata_name","__wbg_set_metadata_name","locator","__wbg_get_metadata_locator","__wbg_set_metadata_locator","prover","__wbg_get_metadata_prover","__wbg_set_metadata_prover","verifier","__wbg_get_metadata_verifier","__wbg_set_metadata_verifier","__wbg_get_metadata_verifyingKey","__wbg_set_metadata_verifyingKey","baseUrl","metadata_baseUrl","bond_public","metadata_bond_public","bond_validator","metadata_bond_validator","claim_unbond_public","metadata_claim_unbond_public","fee_private","metadata_fee_private","fee_public","metadata_fee_public","inclusion","metadata_inclusion","join","metadata_join","set_validator_state","metadata_set_validator_state","split","metadata_split","transfer_private","metadata_transfer_private","transfer_private_to_public","metadata_transfer_private_to_public","transfer_public","metadata_transfer_public","transfer_public_as_signer","metadata_transfer_public_as_signer","transfer_public_to_private","metadata_transfer_public_to_private","unbond_public","metadata_unbond_public","OfflineQueryFinalization","__wbg_offlinequery_free","OfflineQuery","state_root","offlinequery_new","addStatePath","commitment","state_path","len1","offlinequery_addStatePath","offlinequery_toString","s","offlinequery_fromString","PrivateKeyFinalization","__wbg_privatekey_free","PrivateKey","privatekey_new","from_seed_unchecked","seed","privatekey_from_seed_unchecked","privatekey_from_string","privatekey_to_string","to_view_key","privatekey_to_view_key","to_address","privatekey_to_address","Address$1","sign","privatekey_sign","newEncrypted","secret","privatekey_newEncrypted","PrivateKeyCiphertext$1","toCiphertext","privatekey_toCiphertext","fromPrivateKeyCiphertext","ciphertext","privatekey_fromPrivateKeyCiphertext","PrivateKeyCiphertextFinalization","__wbg_privatekeyciphertext_free","PrivateKeyCiphertext","encryptPrivateKey","decryptToPrivateKey","privatekeyciphertext_decryptToPrivateKey","privatekeyciphertext_toString","privatekeyciphertext_fromString","ProgramFinalization","__wbg_program_free","Program","program_fromString","program_toString","hasFunction","function_name","program_hasFunction","getFunctions","program_getFunctions","getFunctionInputs","program_getFunctionInputs","getMappings","program_getMappings","getRecordMembers","record_name","program_getRecordMembers","getStructMembers","struct_name","program_getStructMembers","getCreditsProgram","program_getCreditsProgram","id","program_id","program_address","isEqual","other","program_isEqual","getImports","program_getImports","ProgramManagerFinalization","__wbg_programmanager_free","buildDeploymentTransaction","fee_credits","fee_record","imports","fee_proving_key","fee_verifying_key","offline_query","RecordPlaintext$1","ptr2","len2","ptr3","ptr4","ptr5","OfflineQuery$1","programmanager_buildDeploymentTransaction","estimateDeploymentFee","programmanager_estimateDeploymentFee","estimateProgramNameCost","programmanager_estimateProgramNameCost","r2","BigInt","asUintN","executeFunctionOffline","_function","inputs","prove_execution","cache","len4","programmanager_executeFunctionOffline","buildExecutionTransaction","len3","ptr6","ptr7","ptr8","programmanager_buildExecutionTransaction","estimateExecutionFee","programmanager_estimateExecutionFee","estimateFinalizeFee","programmanager_estimateFinalizeFee","buildJoinTransaction","record_1","record_2","join_proving_key","join_verifying_key","programmanager_buildJoinTransaction","buildSplitTransaction","split_amount","amount_record","split_proving_key","split_verifying_key","programmanager_buildSplitTransaction","buildTransferTransaction","amount_credits","recipient","transfer_type","transfer_proving_key","transfer_verifying_key","ptr9","programmanager_buildTransferTransaction","synthesizeKeyPair","programmanager_synthesizeKeyPair","ProvingKeyFinalization","__wbg_provingkey_free","ProvingKey","isBondPublicProver","provingkey_isBondPublicProver","isBondValidatorProver","provingkey_isBondValidatorProver","isClaimUnbondPublicProver","provingkey_isClaimUnbondPublicProver","isFeePrivateProver","provingkey_isFeePrivateProver","isFeePublicProver","provingkey_isFeePublicProver","isInclusionProver","provingkey_isInclusionProver","isJoinProver","provingkey_isJoinProver","isSetValidatorStateProver","provingkey_isSetValidatorStateProver","isSplitProver","provingkey_isSplitProver","isTransferPrivateProver","provingkey_isTransferPrivateProver","isTransferPrivateToPublicProver","provingkey_isTransferPrivateToPublicProver","isTransferPublicProver","provingkey_isTransferPublicProver","isTransferPublicAsSignerProver","provingkey_isTransferPublicAsSignerProver","isTransferPublicToPrivateProver","provingkey_isTransferPublicToPrivateProver","isUnbondPublicProver","provingkey_isUnbondPublicProver","checksum","provingkey_checksum","copy","provingkey_copy","fromBytes","bytes","provingkey_fromBytes","string","provingkey_fromString","toBytes","provingkey_toBytes","v1","provingkey_toString","RecordCiphertextFinalization","__wbg_recordciphertext_free","RecordCiphertext","record","recordciphertext_fromString","recordciphertext_toString","decrypt","recordciphertext_decrypt","isOwner","recordciphertext_isOwner","RecordPlaintextFinalization","__wbg_recordplaintext_free","RecordPlaintext","recordplaintext_commitment","Field$1","recordplaintext_fromString","recordplaintext_toString","microcredits","recordplaintext_microcredits","nonce","recordplaintext_nonce","serialNumberString","deferred4_0","deferred4_1","recordplaintext_serialNumberString","r3","SignatureFinalization","__wbg_signature_free","Signature","signature_verify","signature_from_string","signature_to_string","TransactionFinalization","__wbg_transaction_free","Transaction","transaction","transaction_fromString","transaction_toString","transactionId","transaction_transactionId","transactionType","transaction_transactionType","VerifyingKeyFinalization","__wbg_verifyingkey_free","VerifyingKey","bondPublicVerifier","verifyingkey_bondPublicVerifier","bondValidatorVerifier","verifyingkey_bondValidatorVerifier","claimUnbondPublicVerifier","verifyingkey_claimUnbondPublicVerifier","feePrivateVerifier","verifyingkey_feePrivateVerifier","feePublicVerifier","verifyingkey_feePublicVerifier","inclusionVerifier","verifyingkey_inclusionVerifier","joinVerifier","verifyingkey_joinVerifier","setValidatorStateVerifier","verifyingkey_setValidatorStateVerifier","splitVerifier","verifyingkey_splitVerifier","transferPrivateVerifier","verifyingkey_transferPrivateVerifier","transferPrivateToPublicVerifier","verifyingkey_transferPrivateToPublicVerifier","transferPublicVerifier","verifyingkey_transferPublicVerifier","transferPublicAsSignerVerifier","verifyingkey_transferPublicAsSignerVerifier","transferPublicToPrivateVerifier","verifyingkey_transferPublicToPrivateVerifier","unbondPublicVerifier","verifyingkey_unbondPublicVerifier","isBondPublicVerifier","verifyingkey_isBondPublicVerifier","isBondValidatorVerifier","verifyingkey_isBondValidatorVerifier","isClaimUnbondPublicVerifier","verifyingkey_isClaimUnbondPublicVerifier","isFeePrivateVerifier","verifyingkey_isFeePrivateVerifier","isFeePublicVerifier","verifyingkey_isFeePublicVerifier","isInclusionVerifier","verifyingkey_isInclusionVerifier","isJoinVerifier","verifyingkey_isJoinVerifier","isSetValidatorStateVerifier","verifyingkey_isSetValidatorStateVerifier","isSplitVerifier","verifyingkey_isSplitVerifier","isTransferPrivateVerifier","verifyingkey_isTransferPrivateVerifier","isTransferPrivateToPublicVerifier","verifyingkey_isTransferPrivateToPublicVerifier","isTransferPublicVerifier","verifyingkey_isTransferPublicVerifier","isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicAsSignerVerifier","isTransferPublicToPrivateVerifier","verifyingkey_isTransferPublicToPrivateVerifier","isUnbondPublicVerifier","verifyingkey_isUnbondPublicVerifier","verifyingkey_checksum","verifyingkey_copy","verifyingkey_fromBytes","verifyingkey_fromString","verifyingkey_toBytes","verifyingkey_toString","ViewKeyFinalization","__wbg_viewkey_free","ViewKey","viewkey_from_string","viewkey_to_string","deferred3_0","deferred3_1","viewkey_decrypt","async","__wbg_load","Response","WebAssembly","instantiateStreaming","headers","console","warn","arrayBuffer","instantiate","Instance","__wbg_get_imports","wbg","__wbindgen_object_drop_ref","__wbg_new_71801a555ad9f2aa","XMLHttpRequest","arguments","__wbg_overrideMimeType_ee9c51919ceb418b","overrideMimeType","__wbg_open_c9eb0cf2c9d95679","arg4","arg5","open","__wbg_send_80d29985093c1ec5","send","__wbg_response_7c2e2759084f7279","response","__wbg_status_d485fb5a478426fb","status","__wbg_new_72fb9a18b5ae2624","__wbindgen_string_new","__wbg_set_1f9b04f170055d33","Reflect","__wbg_new_ab6fd82b10560829","Headers","__wbindgen_object_clone_ref","__wbg_new_0d76b0581eca6298","AbortController","__wbg_signal_a61f78a3478fd9bc","signal","__wbg_append_7bfcb4937d1d5e29","append","__wbg_instanceof_Response_849eb93e75734b6e","result","__wbg_status_61a01141acd3cf74","__wbg_url_5f6dc4009ac5f99d","__wbg_headers_9620bfada380764a","__wbg_iterator_2cee6dadfd956dfa","Symbol","iterator","__wbg_get_e3c254076557e348","__wbindgen_is_function","__wbg_call_27c0f87801dedf93","__wbindgen_is_object","__wbg_next_40fc327bfc8770e6","next","__wbg_next_196c84450b364254","__wbg_done_298b57d23c0fc80c","done","__wbg_value_d93c65011f51a456","value","__wbg_abort_2aa7521d5690750e","abort","__wbg_stringify_8887fe74e1c50d81","__wbindgen_string_get","__wbg_log_0159ca40cddf5b15","log","__wbindgen_bigint_from_u64","__wbg_call_b3ca7c6051f9bec1","__wbindgen_module","__wbg_init","__wbindgen_wasm_module","__wbindgen_memory","__wbg_spawnWorker_f6acaddb2e29dc4a","__wbg_executionresponse_new","ExecutionResponse$1","__wbg_keypair_new","__wbg_transaction_new","Transaction$1","__wbg_newwithlength_66ae46612e7f0234","__wbg_set_d4638f722068f043","__wbindgen_cb_drop","__wbg_new_16b304a2cfa7ff4a","__wbg_push_a5b05aedc7234f9f","__wbg_arrayBuffer_29931d52c7206b02","__wbg_new_63b92bc8671ed464","__wbg_length_c20a40f15020d68a","__wbg_new_81740750da40724f","state0","cb0","__wbindgen_number_new","__wbg_new_abda76e883ba8a5f","__wbg_stack_658279fe44541cf6","__wbg_error_f851667af71bcfc6","deferred0_0","deferred0_1","error","__wbg_buffer_12d079cc21e14bdb","__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb","__wbg_randomFillSync_5c9c955aa56b6049","randomFillSync","__wbg_subarray_a1f73cd4b5b42fe1","__wbg_getRandomValues_3aa56aa6edec874c","getRandomValues","__wbg_set_a47bac70306a19a7","__wbg_crypto_1d1f22824a6a080c","crypto","__wbg_process_4a72847cc503995b","process","__wbg_versions_f686565e586dd935","versions","__wbg_node_104a2ff8d6ea03a2","node","__wbindgen_is_string","__wbg_require_cca90b1a94a0255b","require","__wbg_msCrypto_eb05e62b530a1508","msCrypto","__wbg_newwithlength_e9b4878cebadb3d3","__wbg_length_cd7af8117672b8b8","__wbg_get_bd8e338fbd5f5cc8","__wbg_self_ce0dbfc45cf2f5be","self","__wbg_window_c6fb939a7f436783","window","__wbg_globalThis_d1e6af4856ba331b","globalThis","__wbg_global_207b558942527489","global","__wbindgen_is_undefined","__wbg_newnoargs_e258087cd0daa0ea","Function","__wbg_has_0af94d20077affa2","has","__wbg_fetch_bc7c8e27076a5c84","fetch","__wbg_fetch_921fad6ef9e883dd","__wbindgen_debug_string","__wbindgen_throw","__wbindgen_rethrow","__wbg_then_a73caa9a87991566","then","__wbg_then_0c86a60e8fcfe9f6","__wbg_queueMicrotask_481971b0d87f3dd4","queueMicrotask","__wbg_queueMicrotask_3cbae2ec6b6cd3d6","__wbg_resolve_b0083a7967828ec8","__wbg_waitAsync_5d743fc9058ba01a","Atomics","waitAsync","__wbg_new_8cccba86b0f574cb","__wbg_waitAsync_46d5c36955b71a79","__wbg_async_19c0400d97cc72fe","__wbg_value_571d60108110e917","__wbindgen_link_fc1eedd35dc7e0a6","encodeURIComponent","__wbg_new_d1187ae36d662ef9","__wbg_setonmessage_503809e5bb51bd33","onmessage","__wbg_of_6a70eed8d41f469c","of","__wbg_postMessage_7380d10e8b8269df","__wbg_data_3ce7c145ca4fbcdc","data","__wbg_newwithstrandinit_3fd6fba4083ff2d0","Request","__wbg_responseText_c67ed2d48db10769","responseText","__wbindgen_closure_wrapper5975","__wbindgen_closure_wrapper6001","__wbg_init_memory","maybe_memory","Memory","initial","maximum","shared","__wbg_finalize_init","exports","__wbindgen_start","initSync","Module","input","URL","freeze","__proto__","Metadata$1","ProgramManager","ProgramManager$1","RecordCiphertext$1","default","wasm_path","opt","importHook","serverPath","initializeHook","final_path"],"sourceRoot":""} \ No newline at end of file diff --git a/907.bundle.js b/907.bundle.js deleted file mode 100644 index 6fadbbe1d..000000000 --- a/907.bundle.js +++ /dev/null @@ -1,3 +0,0 @@ -/*! For license information please see 907.bundle.js.LICENSE.txt */ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[907,495,876],{720:(e,r,t)=>{t.d(r,{p:()=>u});const i=Symbol("Comlink.proxy"),n=Symbol("Comlink.endpoint"),a=Symbol("Comlink.releaseProxy"),o=Symbol("Comlink.finalizer"),s=Symbol("Comlink.thrown"),c=e=>"object"==typeof e&&null!==e||"function"==typeof e,h=new Map([["proxy",{canHandle:e=>c(e)&&e[i],serialize(e){const{port1:r,port2:t}=new MessageChannel;return u(e,r),[t,[t]]},deserialize(e){return e.start(),g(e,[],r);var r}}],["throw",{canHandle:e=>c(e)&&s in e,serialize({value:e}){let r;return r=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[r,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value);throw e.value}}]]);function u(e,r=globalThis,t=["*"]){r.addEventListener("message",(function n(a){if(!a||!a.data)return;if(!function(e,r){for(const t of e){if(r===t||"*"===t)return!0;if(t instanceof RegExp&&t.test(r))return!0}return!1}(t,a.origin))return void console.warn(`Invalid origin '${a.origin}' for comlink proxy`);const{id:c,type:h,path:f}=Object.assign({path:[]},a.data),d=(a.data.argumentList||[]).map(b);let y;try{const r=f.slice(0,-1).reduce(((e,r)=>e[r]),e),t=f.reduce(((e,r)=>e[r]),e);switch(h){case"GET":y=t;break;case"SET":r[f.slice(-1)[0]]=b(a.data.value),y=!0;break;case"APPLY":y=t.apply(r,d);break;case"CONSTRUCT":y=function(e){return Object.assign(e,{[i]:!0})}(new t(...d));break;case"ENDPOINT":{const{port1:r,port2:t}=new MessageChannel;u(e,t),y=function(e,r){return w.set(e,r),e}(r,[r])}break;case"RELEASE":y=void 0;break;default:return}}catch(e){y={value:e,[s]:0}}Promise.resolve(y).catch((e=>({value:e,[s]:0}))).then((t=>{const[i,a]=m(t);r.postMessage(Object.assign(Object.assign({},i),{id:c}),a),"RELEASE"===h&&(r.removeEventListener("message",n),l(r),o in e&&"function"==typeof e[o]&&e[o]())})).catch((e=>{const[t,i]=m({value:new TypeError("Unserializable return value"),[s]:0});r.postMessage(Object.assign(Object.assign({},t),{id:c}),i)}))})),r.start&&r.start()}function l(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function f(e){if(e)throw new Error("Proxy has been released and is not useable")}function d(e){return P(e,{type:"RELEASE"}).then((()=>{l(e)}))}const y=new WeakMap,p="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const r=(y.get(e)||0)-1;y.set(e,r),0===r&&d(e)}));function g(e,r=[],t=function(){}){let i=!1;const o=new Proxy(t,{get(t,n){if(f(i),n===a)return()=>{!function(e){p&&p.unregister(e)}(o),d(e),i=!0};if("then"===n){if(0===r.length)return{then:()=>o};const t=P(e,{type:"GET",path:r.map((e=>e.toString()))}).then(b);return t.then.bind(t)}return g(e,[...r,n])},set(t,n,a){f(i);const[o,s]=m(a);return P(e,{type:"SET",path:[...r,n].map((e=>e.toString())),value:o},s).then(b)},apply(t,a,o){f(i);const s=r[r.length-1];if(s===n)return P(e,{type:"ENDPOINT"}).then(b);if("bind"===s)return g(e,r.slice(0,-1));const[c,h]=v(o);return P(e,{type:"APPLY",path:r.map((e=>e.toString())),argumentList:c},h).then(b)},construct(t,n){f(i);const[a,o]=v(n);return P(e,{type:"CONSTRUCT",path:r.map((e=>e.toString())),argumentList:a},o).then(b)}});return function(e,r){const t=(y.get(r)||0)+1;y.set(r,t),p&&p.register(e,r,e)}(o,e),o}function v(e){const r=e.map(m);return[r.map((e=>e[0])),(t=r.map((e=>e[1])),Array.prototype.concat.apply([],t))];var t}const w=new WeakMap;function m(e){for(const[r,t]of h)if(t.canHandle(e)){const[i,n]=t.serialize(e);return[{type:"HANDLER",name:r,value:i},n]}return[{type:"RAW",value:e},w.get(e)||[]]}function b(e){switch(e.type){case"HANDLER":return h.get(e.name).deserialize(e.value);case"RAW":return e.value}}function P(e,r,t){return new Promise((i=>{const n=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-");e.addEventListener("message",(function r(t){t.data&&t.data.id&&t.data.id===n&&(e.removeEventListener("message",r),i(t.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:n},r),t)}))}},495:(e,r,t)=>{t.a(e,(async(e,i)=>{try{t.d(r,{AleoKeyProvider:()=>u,AleoKeyProviderParams:()=>h,ProgramManager:()=>l});var n=t(877),a=e([n]);n=(a.then?(await a)():a)[0];async function o(e,r){const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not get URL "+e);return t}async function s(e,r){r.method="POST";const t=await fetch(e,r);if(!t.ok)throw new Error(t.status+" could not post URL "+e);return t}class c{host;headers;account;constructor(e,r){this.host=e+"/testnet",r&&r.headers?this.headers=r.headers:this.headers={"X-Aleo-SDK-Version":"0.6.12"}}setAccount(e){this.account=e}getAccount(){return this.account}setHost(e){this.host=e+"/testnet"}async fetchData(e="/"){try{const r=await o(this.host+e,{headers:this.headers});return await r.json()}catch(e){throw new Error("Error fetching data.")}}async findUnspentRecords(e,r,t,i,a,o){if(o=o||[],e<0)throw new Error("Start height must be greater than or equal to 0");const s=new Array;let c,h,u,l,f=0,d=BigInt(0);if(void 0===t){if(void 0===this.account)throw new Error("Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient");u=this.account._privateKey}else try{u=t instanceof n.ZD?t:n.ZD.from_string(t)}catch(e){throw new Error("Error parsing private key provided.")}const y=u.to_view_key();try{const e=await this.getLatestHeight();if("number"!=typeof e)throw new Error("Error fetching latest block height.");l=e}catch(e){throw new Error("Error fetching latest block height.")}if(h="number"==typeof r&&r<=l?r:l,e>h)throw new Error("Start height must be less than or equal to end height.");for(;h>e;){c=h-50,c=BigInt(a))))return s;if(void 0!==i&&i.length>0){let e=0;if(r.microcredits()>i[e]){if(e+=1,s.push(r),"number"==typeof a&&(d+=r.microcredits(),d>=BigInt(a)))return s;if(s.length>=i.length)return s}}}}}catch(e){}}}}}}}catch(e){if(console.warn("Error fetching blocks in range: "+c.toString()+"-"+h.toString()),console.warn("Error: ",e),f+=1,f>10)return console.warn("10 failures fetching records reached. Returning records fetched so far"),s}}return s}async getBlock(e){try{return await this.fetchData("/block/"+e)}catch(e){throw new Error("Error fetching block.")}}async getBlockRange(e,r){try{return await this.fetchData("/blocks?start="+e+"&end="+r)}catch(t){throw new Error("Error fetching blocks between "+e+" and "+r+".")}}async getDeploymentTransactionIDForProgram(e){e instanceof n.BP&&(e=e.toString());try{return(await this.fetchData("/find/transactionID/deployment/"+e)).replace('"',"")}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getDeploymentTransactionForProgram(e){try{const r=await this.getDeploymentTransactionIDForProgram(e);return await this.getTransaction(r)}catch(e){throw new Error("Error fetching deployment transaction for program.")}}async getLatestBlock(){try{return await this.fetchData("/latest/block")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestCommittee(){try{return await this.fetchData("/committee/latest")}catch(e){throw new Error("Error fetching latest block.")}}async getLatestHeight(){try{return await this.fetchData("/latest/height")}catch(e){throw new Error("Error fetching latest height.")}}async getProgram(e){try{return await this.fetchData("/program/"+e)}catch(e){throw new Error("Error fetching program")}}async getProgramObject(e){try{return n.BP.fromString(e)}catch(r){try{return n.BP.fromString(await this.getProgram(e))}catch(r){throw new Error(`${e} is neither a program name or a valid program`)}}}async getProgramImports(e){try{const r={},t=(e instanceof n.BP?e:await this.getProgramObject(e)).getImports();for(let e=0;e0&&!p)try{p=await this.networkClient.getProgramImports(r)}catch(e){throw E(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`)}return await n.Ao.buildExecutionTransaction(v,y,t,o,i,l,this.host,p,f,d,w,m,u)}async execute(e){const r=await this.buildExecutionTransaction(e);return await this.networkClient.submitTransaction(r)}async run(e,r,t,i,a,o,s,c,h,u){let l=h;if(void 0===h&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";if(!s||!c)try{[s,c]=await this.keyProvider.functionKeys(o)}catch(e){console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)}return console.log("Running program offline"),console.log("Proving key: ",s),console.log("Verifying key: ",c),n.Ao.executeFunctionOffline(l,e,r,t,i,!1,a,s,c,this.host,u)}async join(e,r,t,i,a,o,s,c){let h,u,l=s;if(void 0===s&&void 0!==this.account&&(l=this.account.privateKey()),void 0===l)throw"No private key provided and no private key set in the ProgramManager";try{h=i?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),u=await this.keyProvider.joinKeys()}catch(e){throw E(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[f,d]=h,[y,p]=u;try{o=i?await this.getCreditsRecord(t,[],o,a):void 0}catch(e){throw E(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}try{e=e instanceof n.ZF?e:n.ZF.fromString(e),r=r instanceof n.ZF?r:n.ZF.fromString(r)}catch(e){throw E("Records provided are not valid. Please ensure they are valid plaintext records.")}const g=await n.Ao.buildJoinTransaction(l,e,r,t,o,this.host,y,p,f,d,c);return await this.networkClient.submitTransaction(g)}async split(e,r,t,i){let a,o=t;if(void 0===o&&void 0!==this.account&&(o=this.account.privateKey()),void 0===o)throw"No private key provided and no private key set in the ProgramManager";try{a=await this.keyProvider.splitKeys()}catch(e){throw E(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[s,c]=a;try{r=r instanceof n.ZF?r:n.ZF.fromString(r)}catch(e){throw E("Record provided is not valid. Please ensure it is a valid plaintext record.")}const h=await n.Ao.buildSplitTransaction(o,e,r,this.host,s,c,i);return await this.networkClient.submitTransaction(h)}async synthesizeKeys(e,r,t,i){let a,o=i;void 0===o&&(o=void 0!==this.account?this.account.privateKey():new n.ZD);try{a=await this.networkClient.getProgramImports(e);const i=await n.Ao.synthesizeKeyPair(o,e,r,t,a);return[i.provingKey(),i.verifyingKey()]}catch(e){throw E(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`)}}async buildTransferTransaction(e,r,t,i,a,o,s,c,h,u){t=d(t);let l,y,p=h;if(void 0===p&&void 0!==this.account&&(p=this.account.privateKey()),void 0===p)throw"No private key provided and no private key set in the ProgramManager";try{l=a?await this.keyProvider.feePrivateKeys():await this.keyProvider.feePublicKeys(),y=await this.keyProvider.transferKeys(t)}catch(e){throw E(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`)}const[g,v]=l,[w,m]=y;try{const e=[];f(t)?(s=await this.getCreditsRecord(i,[],s,o),e.push(s.nonce())):s=void 0,c=a?await this.getCreditsRecord(i,e,c,o):void 0}catch(e){throw E(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}return await n.Ao.buildTransferTransaction(p,e,r,t,s,i,c,this.host,w,m,g,v,u)}async buildTransferPublicTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async buildTransferPublicAsSignerTransaction(e,r,t,i,n){return this.buildTransferTransaction(e,r,"public",t,!1,void 0,void 0,void 0,i,n)}async transfer(e,r,t,i,n,a,o,s,c,h){const u=await this.buildTransferTransaction(e,r,t,i,n,a,o,s,c,h);return await this.networkClient.submitTransaction(u)}async buildBondPublicTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*i),{programName:o="credits.aleo",functionName:s="bond_public",fee:c=n.fee||.86,privateFee:u=!1,inputs:l=[e,r,t,`${a.toString()}u64`],keySearchParams:f=new h({proverUri:g.bond_public.prover,verifierUri:g.bond_public.verifier,cacheKey:"credits.aleo/bond_public"}),program:d=this.creditsProgram(),...y}=n,p={programName:o,functionName:s,fee:c,privateFee:u,inputs:l,keySearchParams:f,...y};return await this.buildExecutionTransaction(p)}async bondPublic(e,r,t,i,n={}){const a=await this.buildBondPublicTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildBondValidatorTransaction(e,r,t,i,n={}){const a=Math.trunc(1e6*t),o=Math.trunc(i),{programName:s="credits.aleo",functionName:c="bond_validator",fee:u=n.fee||.86,privateFee:l=!1,inputs:f=[e,r,`${a.toString()}u64`,`${o.toString()}u8`],keySearchParams:d=new h({proverUri:g.bond_validator.prover,verifierUri:g.bond_validator.verifier,cacheKey:"credits.aleo/bond_validator"}),program:y=this.creditsProgram(),...p}=n,v={programName:s,functionName:c,fee:u,privateFee:l,inputs:f,keySearchParams:d,...p};return await this.buildExecutionTransaction(v)}async bondValidator(e,r,t,i,n={}){const a=await this.buildBondValidatorTransaction(e,r,t,i,n);return await this.networkClient.submitTransaction(a)}async buildUnbondPublicTransaction(e,r,t={}){const i=Math.trunc(1e6*r),{programName:n="credits.aleo",functionName:a="unbond_public",fee:o=t.fee||1.3,privateFee:s=!1,inputs:c=[e,`${i.toString()}u64`],keySearchParams:u=new h({proverUri:g.unbond_public.prover,verifierUri:g.unbond_public.verifier,cacheKey:"credits.aleo/unbond_public"}),program:l=this.creditsProgram(),...f}=t,d={programName:n,functionName:a,fee:o,privateFee:s,inputs:c,keySearchParams:u,...f};return this.buildExecutionTransaction(d)}async unbondPublic(e,r,t={}){const i=await this.buildUnbondPublicTransaction(e,r,t);return await this.networkClient.submitTransaction(i)}async buildClaimUnbondPublicTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="claim_unbond_public",fee:n=r.fee||2,privateFee:a=!1,inputs:o=[e],keySearchParams:s=new h({proverUri:g.claim_unbond_public.prover,verifierUri:g.claim_unbond_public.verifier,cacheKey:"credits.aleo/claim_unbond_public"}),program:c=this.creditsProgram(),...u}=r,l={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...u};return await this.buildExecutionTransaction(l)}async claimUnbondPublic(e,r={}){const t=await this.buildClaimUnbondPublicTransaction(e,r);return await this.networkClient.submitTransaction(t)}async buildSetValidatorStateTransaction(e,r={}){const{programName:t="credits.aleo",functionName:i="set_validator_state",fee:n=1,privateFee:a=!1,inputs:o=[e.toString()],keySearchParams:s=new h({proverUri:g.set_validator_state.prover,verifierUri:g.set_validator_state.verifier,cacheKey:"credits.aleo/set_validator_state"}),...c}=r,u={programName:t,functionName:i,fee:n,privateFee:a,inputs:o,keySearchParams:s,...c};return await this.execute(u)}async setValidatorState(e,r={}){const t=await this.buildSetValidatorStateTransaction(e,r);return this.networkClient.submitTransaction(t)}verifyExecution(e){try{const r=e.getExecution(),t=e.getFunctionId(),i=e.getProgram(),a=e.getVerifyingKey();return(0,n.Yc)(r,a,i,t)}catch(e){return console.warn("The execution was not found in the response, cannot verify the execution"),!1}}createProgramFromSource(e){return n.BP.fromString(e)}creditsProgram(){return n.BP.getCreditsProgram()}verifyProgram(e){try{return n.BP.fromString(e),!0}catch(e){return!1}}async getCreditsRecord(e,r,t,i){try{return t instanceof n.ZF?t:n.ZF.fromString(t)}catch(t){try{const t=this.recordProvider;return await t.findCreditsRecord(e,!0,r,i)}catch(e){throw E(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`)}}}}function f(e){return v.has(e)}function d(e){return w.has(e)?e:E(`Invalid transfer type '${e}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`)}const y=n.OS.baseUrl();function p(e){const r=n.pF[e.verifyingKey];if(!r)throw new Error("Invalid method name: "+e.verifyingKey);return{name:e.name,locator:e.locator,prover:e.prover,verifier:e.verifier,verifyingKey:r}}const g={bond_public:p(n.OS.bond_public()),bond_validator:p(n.OS.bond_validator()),claim_unbond_public:p(n.OS.claim_unbond_public()),fee_private:p(n.OS.fee_private()),fee_public:p(n.OS.fee_public()),inclusion:p(n.OS.inclusion()),join:p(n.OS.join()),set_validator_state:p(n.OS.set_validator_state()),split:p(n.OS.split()),transfer_private:p(n.OS.transfer_private()),transfer_private_to_public:p(n.OS.transfer_private_to_public()),transfer_public:p(n.OS.transfer_public()),transfer_public_as_signer:p(n.OS.transfer_public_as_signer()),transfer_public_to_private:p(n.OS.transfer_public_to_private()),unbond_public:p(n.OS.unbond_public()),getKey:function(e){return this.hasOwnProperty(e)?this[e]:new Error(`Key "${e}" not found.`)}},v=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic"]),w=new Set(["transfer_private","private","transferPrivate","transfer_private_to_public","privateToPublic","transferPrivateToPublic","transfer_public","transfer_public_as_signer","public","public_as_signer","transferPublic","transferPublicAsSigner","transfer_public_to_private","publicToPrivate","publicAsSigner","transferPublicToPrivate"]),m=new Set(["private","transfer_private","transferPrivate"]),b=new Set(["private_to_public","privateToPublic","transfer_private_to_public","transferPrivateToPublic"]),P=new Set(["public","transfer_public","transferPublic"]),_=new Set(["public_as_signer","transfer_public_as_signer","transferPublicAsSigner"]),k=new Set(["public_to_private","publicToPrivate","transfer_public_to_private","transferPublicToPrivate"]);function E(e){throw console.error(e),e}i()}catch(K){i(K)}}))},341:(e,r,t)=>{t.a(e,(async(e,r)=>{try{var i=t(495),n=t(720),a=t(877),o=e([i,a]);[i,a]=o.then?(await o)():o,await(0,a.Fs)();const s="https://api.explorer.aleo.org/v1",c=new i.AleoKeyProvider,h=new i.ProgramManager(s,c,void 0);c.useCache(!0);let u="";async function l(e,r,t,n,o=!1){console.log("Web worker: Executing function locally...");const s=performance.now();try{const l=h.createProgramFromSource(e);if(l instanceof Error)throw"Error creating program from source";const f=l.id();if(!l.hasFunction(r))throw`Program ${f} does not contain function ${r}`;const d=`${f}:${r}`,y=await h.networkClient.getProgramImports(e);if(y instanceof Error)throw"Error getting program imports";if(u!==e){const i=await h.synthesizeKeys(e,r,t,a.ZD.from_string(n));h.keyProvider.cacheKeys(d,i),u=e}const p=new i.AleoKeyProviderParams({cacheKey:d}),g=await h.run(e,r,t,o,y,p,void 0,void 0,a.ZD.from_string(n));console.log(`Web worker: Local execution completed in ${performance.now()-s} ms`);const v=g.getOutputs(),w=g.getExecution();let m="";const b=c.getKeys(d);if(b instanceof Error)throw"Could not get verifying key";const P=b[1];return w?((0,a.Yc)(w,P,l,"hello"),m=w.toString(),console.log("Execution verified successfully: "+w)):m="",console.log(`Function execution response: ${v}`),{outputs:v,execution:m}}catch(e){return console.error(e),e?e.toString():"Unknown error"}}async function f(){return(new a.ZD).to_string()}const d={run:l,getPrivateKey:f};(0,n.p)(d),r()}catch(y){r(y)}}),1)}}]); -//# sourceMappingURL=907.bundle.js.map \ No newline at end of file diff --git a/907.bundle.js.LICENSE.txt b/907.bundle.js.LICENSE.txt deleted file mode 100644 index 479a8e58b..000000000 --- a/907.bundle.js.LICENSE.txt +++ /dev/null @@ -1,5 +0,0 @@ -/** - * @license - * Copyright 2019 Google LLC - * SPDX-License-Identifier: Apache-2.0 - */ diff --git a/907.bundle.js.map b/907.bundle.js.map deleted file mode 100644 index 7bbe338aa..000000000 --- a/907.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"907.bundle.js","mappings":";sHAKA,MAAMA,EAAcC,OAAO,iBACrBC,EAAiBD,OAAO,oBACxBE,EAAeF,OAAO,wBACtBG,EAAYH,OAAO,qBACnBI,EAAcJ,OAAO,kBACrBK,EAAYC,GAAwB,iBAARA,GAA4B,OAARA,GAAgC,mBAARA,EAgDxEC,EAAmB,IAAIC,IAAI,CAC7B,CAAC,QA7CwB,CACzBC,UAAYH,GAAQD,EAASC,IAAQA,EAAIP,GACzC,SAAAW,CAAUC,GACN,MAAM,MAAEC,EAAK,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AIe,aAAgB9N,MAChB,KAAM,8BAGV,MAAMgO,EAAeF,EAAK,GAiB1B,OAfI3E,IACA2N,EAAAA,EAAAA,IACI3N,EACA6E,EACAzE,EACA,SAEJgP,EAAkBpP,EAAUzE,WAC5BvD,QAAQqR,IAAI,oCAAsCrJ,IAElDoP,EAAkB,GAGtBpX,QAAQqR,IAAI,gCAAgChJ,KAErC,CAAEA,QAASA,EAASL,UAAWoP,EACzC,CAAC,MAAOrV,GAEL,OADA/B,QAAQ+B,MAAMA,GACPA,EAAQA,EAAMwB,WAAa,eACrC,CACL,CAEA0B,eAAeoS,IAEX,OADmB,IAAIlQ,EAAAA,IACLmQ,WACtB,CAEA,MAAMC,EAAY,CAAEjF,MAAK+E,kBACzBhZ,EAAAA,EAAAA,GAAOkZ","sources":["webpack://aleo-website/../node_modules/comlink/dist/esm/comlink.mjs","webpack://aleo-website/../src/utils.ts","webpack://aleo-website/../src/network-client.ts","webpack://aleo-website/../src/function-key-provider.ts","webpack://aleo-website/../src/program-manager.ts","webpack://aleo-website/../src/index.ts","webpack://aleo-website/../src/worker.ts"],"sourcesContent":["/**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\nconst proxyMarker = Symbol(\"Comlink.proxy\");\nconst createEndpoint = Symbol(\"Comlink.endpoint\");\nconst releaseProxy = Symbol(\"Comlink.releaseProxy\");\nconst finalizer = Symbol(\"Comlink.finalizer\");\nconst throwMarker = Symbol(\"Comlink.thrown\");\nconst isObject = (val) => (typeof val === \"object\" && val !== null) || typeof val === \"function\";\n/**\n * Internal transfer handle to handle objects marked to proxy.\n */\nconst proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n};\n/**\n * Internal transfer handler to handle thrown exceptions.\n */\nconst throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n};\n/**\n * Allows customizing the serialization of certain values.\n */\nconst transferHandlers = new Map([\n [\"proxy\", proxyTransferHandler],\n [\"throw\", throwTransferHandler],\n]);\nfunction isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === \"*\") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n}\nfunction expose(obj, ep = globalThis, allowedOrigins = [\"*\"]) {\n ep.addEventListener(\"message\", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin '${ev.origin}' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case \"GET\" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case \"SET\" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case \"APPLY\" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case \"CONSTRUCT\" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case \"ENDPOINT\" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case \"RELEASE\" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === \"RELEASE\" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener(\"message\", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === \"function\") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError(\"Unserializable return value\"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n}\nfunction isMessagePort(endpoint) {\n return endpoint.constructor.name === \"MessagePort\";\n}\nfunction closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n}\nfunction wrap(ep, target) {\n return createProxy(ep, [], target);\n}\nfunction throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error(\"Proxy has been released and is not useable\");\n }\n}\nfunction releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: \"RELEASE\" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n}\nconst proxyCounter = new WeakMap();\nconst proxyFinalizers = \"FinalizationRegistry\" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\nfunction registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n}\nfunction unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n}\nfunction createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === \"then\") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: \"GET\" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: \"SET\" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: \"ENDPOINT\" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === \"bind\") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"APPLY\" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: \"CONSTRUCT\" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n}\nfunction myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n}\nfunction processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n}\nconst transferCache = new WeakMap();\nfunction transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n}\nfunction proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n}\nfunction windowEndpoint(w, context = globalThis, targetOrigin = \"*\") {\n return {\n postMessage: (msg, transferables) => w.postMessage(msg, targetOrigin, transferables),\n addEventListener: context.addEventListener.bind(context),\n removeEventListener: context.removeEventListener.bind(context),\n };\n}\nfunction toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: \"HANDLER\" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: \"RAW\" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n}\nfunction fromWireValue(value) {\n switch (value.type) {\n case \"HANDLER\" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case \"RAW\" /* WireValueType.RAW */:\n return value.value;\n }\n}\nfunction requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener(\"message\", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener(\"message\", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n}\nfunction generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join(\"-\");\n}\n\nexport { createEndpoint, expose, finalizer, proxy, proxyMarker, releaseProxy, transfer, transferHandlers, windowEndpoint, wrap };\n//# sourceMappingURL=comlink.mjs.map\n","export async function get(url: URL | string, options?: RequestInit) {\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not get URL \" + url);\n }\n\n return response;\n}\n\n\nexport async function post(url: URL | string, options: RequestInit) {\n options.method = \"POST\";\n\n const response = await fetch(url, options);\n\n if (!response.ok) {\n throw new Error(response.status + \" could not post URL \" + url);\n }\n\n return response;\n}\n","import { get, post } from \"./utils\";\nimport {\n Account,\n Block,\n RecordCiphertext,\n Program,\n RecordPlaintext,\n PrivateKey,\n Transaction,\n TransactionModel,\n logAndThrow\n} from \"./index\";\n\ntype ProgramImports = { [key: string]: string | Program };\n\ninterface AleoNetworkClientOptions {\n headers?: { [key: string]: string };\n}\n\n/**\n * Client library that encapsulates REST calls to publicly exposed endpoints of Aleo nodes. The methods provided in this\n * allow users to query public information from the Aleo blockchain and submit transactions to the network.\n *\n * @param {string} host\n * @example\n * // Connection to a local node\n * const localNetworkClient = new AleoNetworkClient(\"http://localhost:3030\");\n *\n * // Connection to a public beacon node\n * const publicnetworkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n */\nclass AleoNetworkClient {\n host: string;\n headers: { [key: string]: string };\n account: Account | undefined;\n\n constructor(host: string, options?: AleoNetworkClientOptions) {\n this.host = host + \"/testnet\";\n\n if (options && options.headers) {\n this.headers = options.headers;\n\n } else {\n this.headers = {\n // This is replaced by the actual version by a Rollup plugin\n \"X-Aleo-SDK-Version\": \"%%VERSION%%\",\n };\n }\n }\n\n /**\n * Set an account to use in networkClient calls\n *\n * @param {Account} account\n * @example\n * const account = new Account();\n * networkClient.setAccount(account);\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Return the Aleo account used in the networkClient\n *\n * @example\n * const account = networkClient.getAccount();\n */\n getAccount(): Account | undefined {\n return this.account;\n }\n\n /**\n * Set a new host for the networkClient\n *\n * @param {string} host The address of a node hosting the Aleo API\n * @param host\n */\n setHost(host: string) {\n this.host = host + \"/testnet\";\n }\n\n async fetchData(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(this.host + url, {\n headers: this.headers\n });\n\n return await response.json();\n } catch (error) {\n throw new Error(\"Error fetching data.\");\n }\n }\n\n /**\n * Attempts to find unspent records in the Aleo blockchain for a specified private key\n * @param {number} startHeight - The height at which to start searching for unspent records\n * @param {number} endHeight - The height at which to stop searching for unspent records\n * @param {string | PrivateKey} privateKey - The private key to use to find unspent records\n * @param {number[]} amounts - The amounts (in microcredits) to search for (eg. [100, 200, 3000])\n * @param {number} maxMicrocredits - The maximum number of microcredits to search for\n * @param {string[]} nonces - The nonces of already found records to exclude from the search\n *\n * @example\n * // Find all unspent records\n * const privateKey = \"[PRIVATE_KEY]\";\n * const records = networkClient.findUnspentRecords(0, undefined, privateKey);\n *\n * // Find specific amounts\n * const startHeight = 500000;\n * const amounts = [600000, 1000000];\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, amounts);\n *\n * // Find specific amounts with a maximum number of cumulative microcredits\n * const maxMicrocredits = 100000;\n * const records = networkClient.findUnspentRecords(startHeight, undefined, privateKey, undefined, maxMicrocredits);\n */\n async findUnspentRecords(\n startHeight: number,\n endHeight: number | undefined,\n privateKey: string | PrivateKey | undefined,\n amounts: number[] | undefined,\n maxMicrocredits?: number | undefined,\n nonces?: string[] | undefined,\n ): Promise | Error> {\n nonces = nonces || [];\n // Ensure start height is not negative\n if (startHeight < 0) {\n throw new Error(\"Start height must be greater than or equal to 0\");\n }\n\n // Initialize search parameters\n const records = new Array();\n let start;\n let end;\n let resolvedPrivateKey: PrivateKey;\n let failures = 0;\n let totalRecordValue = BigInt(0);\n let latestHeight: number;\n\n // Ensure a private key is present to find owned records\n if (typeof privateKey === \"undefined\") {\n if (typeof this.account === \"undefined\") {\n throw new Error(\"Private key must be specified in an argument to findOwnedRecords or set in the AleoNetworkClient\");\n } else {\n resolvedPrivateKey = this.account._privateKey;\n }\n } else {\n try {\n resolvedPrivateKey = privateKey instanceof PrivateKey ? privateKey : PrivateKey.from_string(privateKey);\n } catch (error) {\n throw new Error(\"Error parsing private key provided.\");\n }\n }\n const viewKey = resolvedPrivateKey.to_view_key();\n\n // Get the latest height to ensure the range being searched is valid\n try {\n const blockHeight = await this.getLatestHeight();\n if (typeof blockHeight === \"number\") {\n latestHeight = blockHeight;\n } else {\n throw new Error(\"Error fetching latest block height.\");\n }\n } catch (error) {\n throw new Error(\"Error fetching latest block height.\");\n }\n\n // If no end height is specified or is greater than the latest height, set the end height to the latest height\n if (typeof endHeight === \"number\" && endHeight <= latestHeight) {\n end = endHeight\n } else {\n end = latestHeight;\n }\n\n // If the starting is greater than the ending height, return an error\n if (startHeight > end) {\n throw new Error(\"Start height must be less than or equal to end height.\");\n }\n\n // Iterate through blocks in reverse order in chunks of 50\n while (end > startHeight) {\n start = end - 50;\n if (start < startHeight) {\n start = startHeight;\n }\n try {\n // Get 50 blocks (or the difference between the start and end if less than 50)\n const blocks = await this.getBlockRange(start, end);\n end = start;\n if (!(blocks instanceof Error)) {\n // Iterate through blocks to find unspent records\n for (let i = 0; i < blocks.length; i++) {\n const block = blocks[i];\n const transactions = block.transactions;\n if (!(typeof transactions === \"undefined\")) {\n for (let j = 0; j < transactions.length; j++) {\n const confirmedTransaction = transactions[j];\n // Search for unspent records in execute transactions of credits.aleo\n if (confirmedTransaction.type == \"execute\") {\n const transaction = confirmedTransaction.transaction;\n if (transaction.execution && !(typeof transaction.execution.transitions == \"undefined\")) {\n for (let k = 0; k < transaction.execution.transitions.length; k++) {\n const transition = transaction.execution.transitions[k];\n // Only search for unspent records in credits.aleo (for now)\n if (transition.program !== \"credits.aleo\") {\n continue;\n }\n if (!(typeof transition.outputs == \"undefined\")) {\n for (let l = 0; l < transition.outputs.length; l++) {\n const output = transition.outputs[l];\n if (output.type === \"record\") {\n try {\n // Create a wasm record ciphertext object from the found output\n const record = RecordCiphertext.fromString(output.value);\n // Determine if the record is owned by the specified view key\n if (record.isOwner(viewKey)) {\n // Decrypt the record and get the serial number\n const recordPlaintext = record.decrypt(viewKey);\n\n // If the record has already been found, skip it\n const nonce = recordPlaintext.nonce();\n if (nonces.includes(nonce)) {\n continue;\n }\n\n // Otherwise record the nonce that has been found\n const serialNumber = recordPlaintext.serialNumberString(resolvedPrivateKey, \"credits.aleo\", \"credits\");\n // Attempt to see if the serial number is spent\n try {\n await this.getTransitionId(serialNumber);\n } catch (error) {\n // If it's not found, add it to the list of unspent records\n if (!amounts) {\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n }\n // If the user specified a list of amounts, check if the search has found them\n if (!(typeof amounts === \"undefined\") && amounts.length > 0) {\n let amounts_found = 0;\n if (recordPlaintext.microcredits() > amounts[amounts_found]) {\n amounts_found += 1;\n records.push(recordPlaintext);\n // If the user specified a maximum number of microcredits, check if the search has found enough\n if (typeof maxMicrocredits === \"number\") {\n totalRecordValue += recordPlaintext.microcredits();\n // Exit if the search has found the amount specified\n if (totalRecordValue >= BigInt(maxMicrocredits)) {\n return records;\n }\n }\n if (records.length >= amounts.length) {\n return records;\n }\n }\n }\n }\n }\n } catch (error) {\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n }\n } catch (error) {\n // If there is an error fetching blocks, log it and keep searching\n console.warn(\"Error fetching blocks in range: \" + start.toString() + \"-\" + end.toString());\n console.warn(\"Error: \", error);\n failures += 1;\n if (failures > 10) {\n console.warn(\"10 failures fetching records reached. Returning records fetched so far\");\n return records;\n }\n }\n }\n return records;\n }\n\n /**\n * Returns the contents of the block at the specified block height\n *\n * @param {number} height\n * @example\n * const block = networkClient.getBlock(1234);\n */\n async getBlock(height: number): Promise {\n try {\n const block = await this.fetchData(\"/block/\" + height);\n return block;\n } catch (error) {\n throw new Error(\"Error fetching block.\");\n }\n }\n\n /**\n * Returns a range of blocks between the specified block heights\n *\n * @param {number} start\n * @param {number} end\n * @example\n * const blockRange = networkClient.getBlockRange(2050, 2100);\n */\n async getBlockRange(start: number, end: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/blocks?start=\" + start + \"&end=\" + end);\n } catch (error) {\n const errorMessage = \"Error fetching blocks between \" + start + \" and \" + end + \".\"\n throw new Error(errorMessage);\n }\n }\n\n /**\n * Returns the deployment transaction id associated with the specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionIDForProgram(program: Program | string): Promise {\n if (program instanceof Program) {\n program = program.toString();\n }\n try {\n const id = await this.fetchData(\"/find/transactionID/deployment/\" + program);\n return id.replace(\"\\\"\", \"\")\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the deployment transaction associated with a specified program\n *\n * @param {Program | string} program\n * @returns {TransactionModel | Error}\n */\n async getDeploymentTransactionForProgram(program: Program | string): Promise {\n try {\n const transaction_id = await this.getDeploymentTransactionIDForProgram(program);\n return await this.getTransaction(transaction_id);\n } catch (error) {\n throw new Error(\"Error fetching deployment transaction for program.\");\n }\n }\n\n /**\n * Returns the contents of the latest block\n *\n * @example\n * const latestHeight = networkClient.getLatestBlock();\n */\n async getLatestBlock(): Promise {\n try {\n return await this.fetchData(\"/latest/block\") as Block;\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest committee\n *\n * @returns {Promise} A javascript object containing the latest committee\n */\n async getLatestCommittee(): Promise {\n try {\n return await this.fetchData(\"/committee/latest\");\n } catch (error) {\n throw new Error(\"Error fetching latest block.\");\n }\n }\n\n /**\n * Returns the latest block height\n *\n * @example\n * const latestHeight = networkClient.getLatestHeight();\n */\n async getLatestHeight(): Promise {\n try {\n return await this.fetchData(\"/latest/height\");\n } catch (error) {\n throw new Error(\"Error fetching latest height.\");\n }\n }\n\n /**\n * Returns the source code of a program given a program ID\n *\n * @param {string} programId The program ID of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const program = networkClient.getProgram(\"hello_hello.aleo\");\n * const expectedSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * assert.equal(program, expectedSource);\n */\n async getProgram(programId: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId)\n } catch (error) {\n throw new Error(\"Error fetching program\");\n }\n }\n\n /**\n * Returns a program object from a program ID or program source code\n *\n * @param {string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @return {Promise} Source code of the program\n *\n * @example\n * const programID = \"hello_hello.aleo\";\n * const programSource = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n *\n * // Get program object from program ID or program source code\n * const programObjectFromID = await networkClient.getProgramObject(programID);\n * const programObjectFromSource = await networkClient.getProgramObject(programSource);\n *\n * // Both program objects should be equal\n * assert.equal(programObjectFromID.to_string(), programObjectFromSource.to_string());\n */\n async getProgramObject(inputProgram: string): Promise {\n try {\n return Program.fromString(inputProgram);\n } catch (error) {\n try {\n return Program.fromString((await this.getProgram(inputProgram)));\n } catch (error) {\n throw new Error(`${inputProgram} is neither a program name or a valid program`);\n }\n }\n }\n\n /**\n * Returns an object containing the source code of a program and the source code of all programs it imports\n *\n * @param {Program | string} inputProgram The program ID or program source code of a program deployed to the Aleo Network\n * @returns {Promise} Object of the form { \"program_id\": \"program_source\", .. } containing program id & source code for all program imports\n *\n * @example\n * const double_test_source = \"import multiply_test.aleo;\\n\\nprogram double_test.aleo;\\n\\nfunction double_it:\\n input r0 as u32.private;\\n call multiply_test.aleo/multiply 2u32 r0 into r1;\\n output r1 as u32.private;\\n\"\n * const double_test = Program.fromString(double_test_source);\n * const expectedImports = {\n * \"multiply_test.aleo\": \"program multiply_test.aleo;\\n\\nfunction multiply:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n mul r0 r1 into r2;\\n output r2 as u32.private;\\n\"\n * }\n *\n * // Imports can be fetched using the program ID, source code, or program object\n * let programImports = await networkClient.getProgramImports(\"double_test.aleo\");\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program source code\n * programImports = await networkClient.getProgramImports(double_test_source);\n * assert.deepStrictEqual(programImports, expectedImports);\n *\n * // Using the program object\n * programImports = await networkClient.getProgramImports(double_test);\n * assert.deepStrictEqual(programImports, expectedImports);\n */\n async getProgramImports(inputProgram: Program | string): Promise {\n try {\n const imports: ProgramImports = {};\n\n // Get the program object or fail if the program is not valid or does not exist\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n\n // Get the list of programs that the program imports\n const importList = program.getImports();\n\n // Recursively get any imports that the imported programs have in a depth first search order\n for (let i = 0; i < importList.length; i++) {\n const import_id = importList[i];\n if (!imports.hasOwnProperty(import_id)) {\n const programSource = await this.getProgram(import_id);\n const nestedImports = await this.getProgramImports(import_id);\n for (const key in nestedImports) {\n if (!imports.hasOwnProperty(key)) {\n imports[key] = nestedImports[key];\n }\n }\n imports[import_id] = programSource;\n }\n }\n return imports;\n } catch (error) {\n throw logAndThrow(\"Error fetching program imports: \" + error)\n }\n }\n\n /**\n * Get a list of the program names that a program imports\n *\n * @param {Program | string} inputProgram - The program id or program source code to get the imports of\n * @returns {string[]} - The list of program names that the program imports\n *\n * @example\n * const programImportsNames = networkClient.getProgramImports(\"double_test.aleo\");\n * const expectedImportsNames = [\"multiply_test.aleo\"];\n * assert.deepStrictEqual(programImportsNames, expectedImportsNames);\n */\n async getProgramImportNames(inputProgram: Program | string): Promise {\n try {\n const program = inputProgram instanceof Program ? inputProgram : (await this.getProgramObject(inputProgram));\n return program.getImports();\n } catch (error) {\n throw new Error(\"Error fetching program imports with error: \" + error);\n }\n }\n\n /**\n * Returns the names of the mappings of a program\n *\n * @param {string} programId - The program ID to get the mappings of (e.g. \"credits.aleo\")\n * @example\n * const mappings = networkClient.getProgramMappingNames(\"credits.aleo\");\n * const expectedMappings = [\"account\"];\n * assert.deepStrictEqual(mappings, expectedMappings);\n */\n async getProgramMappingNames(programId: string): Promise | Error> {\n try {\n return await this.fetchData>(\"/program/\" + programId + \"/mappings\")\n } catch (error) {\n throw new Error(\"Error fetching program mappings - ensure the program exists on chain before trying again\");\n }\n }\n\n /**\n * Returns the value of a program's mapping for a specific key\n *\n * @param {string} programId - The program ID to get the mapping value of (e.g. \"credits.aleo\")\n * @param {string} mappingName - The name of the mapping to get the value of (e.g. \"account\")\n * @param {string} key - The key of the mapping to get the value of (e.g. \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\")\n * @return {Promise} String representation of the value of the mapping\n *\n * @example\n * // Get public balance of an account\n * const mappingValue = networkClient.getMappingValue(\"credits.aleo\", \"account\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\");\n * const expectedValue = \"0u64\";\n * assert.equal(mappingValue, expectedValue);\n */\n async getProgramMappingValue(programId: string, mappingName: string, key: string): Promise {\n try {\n return await this.fetchData(\"/program/\" + programId + \"/mapping/\" + mappingName + \"/\" + key)\n } catch (error) {\n throw new Error(\"Error fetching mapping value - ensure the mapping exists and the key is correct\");\n }\n }\n\n /**\n * Returns the latest state/merkle root of the Aleo blockchain\n *\n * @example\n * const stateRoot = networkClient.getStateRoot();\n */\n async getStateRoot(): Promise {\n try {\n return await this.fetchData(\"/latest/stateRoot\");\n } catch (error) {\n throw new Error(\"Error fetching Aleo state root\");\n }\n }\n\n /**\n * Returns a transaction by its unique identifier\n *\n * @param {string} id\n * @example\n * const transaction = networkClient.getTransaction(\"at1handz9xjrqeynjrr0xay4pcsgtnczdksz3e584vfsgaz0dh0lyxq43a4wj\");\n */\n async getTransaction(id: string): Promise {\n try {\n return await this.fetchData(\"/transaction/\" + id);\n } catch (error) {\n throw new Error(\"Error fetching transaction.\");\n }\n }\n\n /**\n * Returns the transactions present at the specified block height\n *\n * @param {number} height\n * @example\n * const transactions = networkClient.getTransactions(654);\n */\n async getTransactions(height: number): Promise | Error> {\n try {\n return await this.fetchData>(\"/block/\" + height.toString() + \"/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions.\");\n }\n }\n\n /**\n * Returns the transactions in the memory pool.\n *\n * @example\n * const transactions = networkClient.getTransactionsInMempool();\n */\n async getTransactionsInMempool(): Promise | Error> {\n try {\n return await this.fetchData>(\"/memoryPool/transactions\");\n } catch (error) {\n throw new Error(\"Error fetching transactions from mempool.\");\n }\n }\n\n /**\n * Returns the transition ID of the transition corresponding to the ID of the input or output.\n * @param {string} inputOrOutputID - ID of the input or output.\n *\n * @example\n * const transitionId = networkClient.getTransitionId(\"2429232855236830926144356377868449890830704336664550203176918782554219952323field\");\n */\n async getTransitionId(inputOrOutputID: string): Promise {\n try {\n return await this.fetchData(\"/find/transitionID/\" + inputOrOutputID);\n } catch (error) {\n throw new Error(\"Error fetching transition ID.\");\n }\n }\n\n /**\n * Submit an execute or deployment transaction to the Aleo network\n *\n * @param {Transaction | string} transaction - The transaction to submit to the network\n * @returns {string | Error} - The transaction id of the submitted transaction or the resulting error\n */\n async submitTransaction(transaction: Transaction | string): Promise {\n const transaction_string = transaction instanceof Transaction ? transaction.toString() : transaction;\n try {\n const response = await post(this.host + \"/transaction/broadcast\", {\n body: transaction_string,\n headers: Object.assign({}, this.headers, {\n \"Content-Type\": \"application/json\",\n }),\n });\n\n try {\n return await response.json();\n\n } catch (error) {\n throw new Error(`Error posting transaction. Aleo network response: ${(error as Error).message}`);\n }\n } catch (error) {\n throw new Error(`Error posting transaction: No response received: ${(error as Error).message}`);\n }\n }\n}\n\nexport { AleoNetworkClient, AleoNetworkClientOptions, ProgramImports }\n","import {\n ProvingKey,\n VerifyingKey,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n Key,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PUBLIC_TRANSFER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER\n} from \"./index\";\nimport { get } from \"./utils\";\n\ntype FunctionKeyPair = [ProvingKey, VerifyingKey];\ntype CachedKeyPair = [Uint8Array, Uint8Array];\ntype AleoKeyProviderInitParams = {\n proverUri?: string;\n verifierUri?: string;\n cacheKey?: string;\n};\n\n/**\n * Interface for record search parameters. This allows for arbitrary search parameters to be passed to record provider\n * implementations.\n */\ninterface KeySearchParams {\n [key: string]: any; // This allows for arbitrary keys with any type values\n}\n\n/**\n * AleoKeyProviderParams search parameter for the AleoKeyProvider. It allows for the specification of a proverUri and\n * verifierUri to fetch keys via HTTP from a remote resource as well as a unique cacheKey to store the keys in memory.\n */\nclass AleoKeyProviderParams implements KeySearchParams {\n name: string | undefined;\n proverUri: string | undefined;\n verifierUri: string | undefined;\n cacheKey: string | undefined;\n\n /**\n * Create a new AleoKeyProviderParams object which implements the KeySearchParams interface. Users can optionally\n * specify a url for the proverUri & verifierUri to fetch keys via HTTP from a remote resource as well as a unique\n * cacheKey to store the keys in memory for future use. If no proverUri or verifierUri is specified, a cachekey must\n * be provided.\n *\n * @param { AleoKeyProviderInitParams } params - Optional search parameters\n */\n constructor(params: {proverUri?: string, verifierUri?: string, cacheKey?: string, name?: string}) {\n this.proverUri = params.proverUri;\n this.verifierUri = params.verifierUri;\n this.cacheKey = params.cacheKey;\n this.name = params.name;\n }\n}\n\n/**\n * KeyProvider interface. Enables the retrieval of public proving and verifying keys for Aleo Programs.\n */\ninterface FunctionKeyProvider {\n /**\n * Get bond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_public function\n */\n bondPublicKeys(): Promise;\n\n /**\n * Get bond_validator function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the bond_validator function\n */\n bondValidatorKeys(): Promise;\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair): void;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the unbond_public function\n */\n claimUnbondPublicKeys(): Promise;\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams | undefined} params - Optional search parameters for the key provider\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a search object which implements the KeySearchParams interface\n * class IndexDbSearch implements KeySearchParams {\n * db: string\n * keyId: string\n * constructor(params: {db: string, keyId: string}) {\n * this.db = params.db;\n * this.keyId = params.keyId;\n * }\n * }\n *\n * // Create a new object which implements the KeyProvider interface\n * class IndexDbKeyProvider implements FunctionKeyProvider {\n * async functionKeys(params: KeySearchParams): Promise {\n * return new Promise((resolve, reject) => {\n * const request = indexedDB.open(params.db, 1);\n *\n * request.onupgradeneeded = function(e) {\n * const db = e.target.result;\n * if (!db.objectStoreNames.contains('keys')) {\n * db.createObjectStore('keys', { keyPath: 'id' });\n * }\n * };\n *\n * request.onsuccess = function(e) {\n * const db = e.target.result;\n * const transaction = db.transaction([\"keys\"], \"readonly\");\n * const store = transaction.objectStore(\"keys\");\n * const request = store.get(params.keyId);\n * request.onsuccess = function(e) {\n * if (request.result) {\n * resolve(request.result as FunctionKeyPair);\n * } else {\n * reject(new Error(\"Key not found\"));\n * }\n * };\n * request.onerror = function(e) { reject(new Error(\"Error fetching key\")); };\n * };\n *\n * request.onerror = function(e) { reject(new Error(\"Error opening database\")); };\n * });\n * }\n *\n * // implement the other methods...\n * }\n *\n *\n * const keyProvider = new AleoKeyProvider();\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const searchParams = new IndexDbSearch({db: \"keys\", keyId: \"credits.aleo:transferPrivate\"});\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(searchParams);\n */\n functionKeys(params?: KeySearchParams): Promise;\n\n /**\n * Get fee_private function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePrivateKeys(): Promise;\n\n /**\n * Get fee_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n feePublicKeys(): Promise;\n\n /**\n * Get join function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n joinKeys(): Promise;\n\n /**\n * Get split function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n splitKeys(): Promise;\n\n /**\n * Get keys for a variant of the transfer function from the credits.aleo program\n *\n * @param {string} visibility Visibility of the transfer function (private, public, privateToPublic, publicToPrivate)\n * @returns {Promise} Proving and verifying keys for the specified transfer function\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n transferKeys(visibility: string): Promise;\n\n /**\n * Get unbond_public function keys from the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n unBondPublicKeys(): Promise;\n\n}\n\n\n/**\n * AleoKeyProvider class. Implements the KeyProvider interface. Enables the retrieval of Aleo program proving and\n * verifying keys for the credits.aleo program over http from official Aleo sources and storing and retrieving function\n * keys from a local memory cache.\n */\nclass AleoKeyProvider implements FunctionKeyProvider {\n cache: Map;\n cacheOption: boolean;\n keyUris: string;\n\n async fetchBytes(\n url = \"/\",\n ): Promise {\n try {\n const response = await get(url);\n const data = await response.arrayBuffer();\n return new Uint8Array(data);\n } catch (error) {\n throw new Error(\"Error fetching data.\" + error);\n }\n }\n\n constructor() {\n this.keyUris = KEY_STORE;\n this.cache = new Map();\n this.cacheOption = false;\n }\n\n /**\n * Use local memory to store keys\n *\n * @param {boolean} useCache whether to store keys in local memory\n */\n useCache(useCache: boolean) {\n this.cacheOption = useCache;\n }\n\n /**\n * Clear the key cache\n */\n clearCache() {\n this.cache.clear();\n }\n\n /**\n * Cache a set of keys. This will overwrite any existing keys with the same keyId. The user can check if a keyId\n * exists in the cache using the containsKeys method prior to calling this method if overwriting is not desired.\n *\n * @param {string} keyId access key for the cache\n * @param {FunctionKeyPair} keys keys to cache\n */\n cacheKeys(keyId: string, keys: FunctionKeyPair) {\n const [provingKey, verifyingKey] = keys;\n this.cache.set(keyId, [provingKey.toBytes(), verifyingKey.toBytes()]);\n }\n\n /**\n * Determine if a keyId exists in the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair\n * @returns {boolean} true if the keyId exists in the cache, false otherwise\n */\n containsKeys(keyId: string): boolean {\n return this.cache.has(keyId)\n }\n\n /**\n * Delete a set of keys from the cache\n *\n * @param {string} keyId keyId of a proving and verifying key pair to delete from memory\n * @returns {boolean} true if the keyId exists in the cache and was deleted, false if the key did not exist\n */\n deleteKeys(keyId: string): boolean {\n return this.cache.delete(keyId)\n }\n\n /**\n * Get a set of keys from the cache\n * @param keyId keyId of a proving and verifying key pair\n *\n * @returns {FunctionKeyPair | Error} Proving and verifying keys for the specified program\n */\n getKeys(keyId: string): FunctionKeyPair | Error {\n console.debug(`Checking if key exists in cache. KeyId: ${keyId}`)\n if (this.cache.has(keyId)) {\n const [provingKeyBytes, verifyingKeyBytes] = this.cache.get(keyId);\n return [ProvingKey.fromBytes(provingKeyBytes), VerifyingKey.fromBytes(verifyingKeyBytes)];\n } else {\n return new Error(\"Key not found in cache.\");\n }\n }\n\n /**\n * Get arbitrary function keys from a provider\n *\n * @param {KeySearchParams} params parameters for the key search in form of: {proverUri: string, verifierUri: string, cacheKey: string}\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new object which implements the KeyProvider interface\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually using the key provider\n * const keySearchParams = { \"cacheKey\": \"myProgram:myFunction\" };\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.functionKeys(keySearchParams);\n */\n async functionKeys(params?: KeySearchParams): Promise {\n if (params) {\n let proverUrl;\n let verifierUrl;\n let cacheKey;\n if (\"name\" in params && typeof params[\"name\"] == \"string\") {\n let key = CREDITS_PROGRAM_KEYS.getKey(params[\"name\"]);\n if (!(key instanceof Error)) {\n return this.fetchCreditsKeys(key);\n }\n }\n\n if (\"proverUri\" in params && typeof params[\"proverUri\"] == \"string\") {\n proverUrl = params[\"proverUri\"];\n }\n\n if (\"verifierUri\" in params && typeof params[\"verifierUri\"] == \"string\") {\n verifierUrl = params[\"verifierUri\"];\n }\n\n if (\"cacheKey\" in params && typeof params[\"cacheKey\"] == \"string\") {\n cacheKey = params[\"cacheKey\"];\n }\n\n if (proverUrl && verifierUrl) {\n return await this.fetchRemoteKeys(proverUrl, verifierUrl, cacheKey);\n }\n\n if (cacheKey) {\n return this.getKeys(cacheKey);\n }\n }\n throw Error(\"Invalid parameters provided, must provide either a cacheKey and/or a proverUrl and a verifierUrl\");\n }\n\n /**\n * Returns the proving and verifying keys for a specified program from a specified url.\n *\n * @param {string} verifierUrl Url of the proving key\n * @param {string} proverUrl Url the verifying key\n * @param {string} cacheKey Key to store the keys in the cache\n *\n * @returns {Promise} Proving and verifying keys for the specified program\n *\n * @example\n * // Create a new AleoKeyProvider object\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPrivateProvingKey, transferPrivateVerifyingKey] = await keyProvider.fetchKeys(\n * CREDITS_PROGRAM_KEYS.transfer_private.prover,\n * CREDITS_PROGRAM_KEYS.transfer_private.verifier,\n * );\n */\n async fetchRemoteKeys(proverUrl: string, verifierUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return [ProvingKey.fromBytes(value[0]), VerifyingKey.fromBytes(value[1])];\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n console.debug(\"Fetching verifying keys \" + verifierUrl);\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n this.cache.set(cacheKey, [provingKey.toBytes(), verifyingKey.toBytes()]);\n return [provingKey, verifyingKey];\n }\n }\n else {\n // If cache is disabled, fetch the keys and return them\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl))\n const verifyingKey = (await this.getVerifyingKey(verifierUrl));\n return [provingKey, verifyingKey];\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving and verifying keys from ${proverUrl} and ${verifierUrl}.`);\n }\n }\n\n /***\n * Fetches the proving key from a remote source.\n *\n * @param proverUrl\n * @param cacheKey\n *\n * @returns {Promise} Proving key for the specified program\n */\n async fetchProvingKey(proverUrl: string, cacheKey?: string): Promise {\n try {\n // If cache is enabled, check if the keys have already been fetched and return them if they have\n if (this.cacheOption) {\n if (!cacheKey) {\n cacheKey = proverUrl;\n }\n const value = this.cache.get(cacheKey);\n if (typeof value !== \"undefined\") {\n return ProvingKey.fromBytes(value[0]);\n } else {\n console.debug(\"Fetching proving keys from url \" + proverUrl);\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n }\n else {\n const provingKey = ProvingKey.fromBytes(await this.fetchBytes(proverUrl));\n return provingKey;\n }\n } catch (error) {\n throw new Error(`Error: ${error} fetching fee proving keys from ${proverUrl}`);\n }\n }\n\n async fetchCreditsKeys(key: Key): Promise {\n try {\n if (!this.cache.has(key.locator) || !this.cacheOption) {\n const verifying_key = key.verifyingKey()\n const proving_key = await this.fetchProvingKey(key.prover, key.locator);\n if (this.cacheOption) {\n this.cache.set(CREDITS_PROGRAM_KEYS.bond_public.locator, [proving_key.toBytes(), verifying_key.toBytes()]);\n }\n return [proving_key, verifying_key];\n } else {\n const keyPair = this.cache.get(key.locator);\n return [ProvingKey.fromBytes(keyPair[0]), VerifyingKey.fromBytes(keyPair[1])];\n }\n } catch (error) {\n throw new Error(`Error: fetching credits.aleo keys: ${error}`);\n }\n }\n\n async bondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_public);\n }\n\n bondValidatorKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.bond_validator);\n }\n\n claimUnbondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.claim_unbond_public)\n }\n\n /**\n * Returns the proving and verifying keys for the transfer functions in the credits.aleo program\n * @param {string} visibility Visibility of the transfer function\n * @returns {Promise} Proving and verifying keys for the transfer functions\n *\n * @example\n * // Create a new AleoKeyProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for value transfers\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * programManager.transfer(1, \"aleo166q6ww6688cug7qxwe7nhctjpymydwzy2h7rscfmatqmfwnjvggqcad0at\", \"public\", 0.5);\n *\n * // Keys can also be fetched manually\n * const [transferPublicProvingKey, transferPublicVerifyingKey] = await keyProvider.transferKeys(\"public\");\n */\n async transferKeys(visibility: string): Promise {\n if (PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private);\n } else if (PRIVATE_TO_PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_private_to_public);\n } else if (PUBLIC_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public);\n } else if (PUBLIC_TRANSFER_AS_SIGNER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_as_signer);\n } else if (PUBLIC_TO_PRIVATE_TRANSFER.has(visibility)) {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.transfer_public_to_private);\n } else {\n throw new Error(\"Invalid visibility type\");\n }\n }\n\n /**\n * Returns the proving and verifying keys for the join function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the join function\n */\n async joinKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.join);\n }\n\n /**\n * Returns the proving and verifying keys for the split function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the split function\n * */\n async splitKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.split);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_private function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePrivateKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_private);\n }\n\n /**\n * Returns the proving and verifying keys for the fee_public function in the credits.aleo program\n *\n * @returns {Promise} Proving and verifying keys for the fee function\n */\n async feePublicKeys(): Promise {\n return await this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.fee_public);\n }\n\n /**\n * Gets a verifying key. If the verifying key is for a credits.aleo function, get it from the wasm cache otherwise\n *\n * @returns {Promise} Verifying key for the function\n */\n // attempt to fetch it from the network\n async getVerifyingKey(verifierUri: string): Promise {\n switch (verifierUri) {\n case CREDITS_PROGRAM_KEYS.bond_public.verifier:\n return CREDITS_PROGRAM_KEYS.bond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.bond_validator.verifier:\n return CREDITS_PROGRAM_KEYS.bond_validator.verifyingKey();\n case CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.claim_unbond_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_private.verifier:\n return CREDITS_PROGRAM_KEYS.fee_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.fee_public.verifier:\n return CREDITS_PROGRAM_KEYS.fee_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.inclusion.verifier:\n return CREDITS_PROGRAM_KEYS.inclusion.verifyingKey();\n case CREDITS_PROGRAM_KEYS.join.verifier:\n return CREDITS_PROGRAM_KEYS.join.verifyingKey();\n case CREDITS_PROGRAM_KEYS.set_validator_state.verifier:\n return CREDITS_PROGRAM_KEYS.set_validator_state.verifyingKey();\n case CREDITS_PROGRAM_KEYS.split.verifier:\n return CREDITS_PROGRAM_KEYS.split.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_private_to_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_as_signer.verifyingKey();\n case CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifier:\n return CREDITS_PROGRAM_KEYS.transfer_public_to_private.verifyingKey();\n case CREDITS_PROGRAM_KEYS.unbond_public.verifier:\n return CREDITS_PROGRAM_KEYS.unbond_public.verifyingKey();\n default:\n try {\n /// Try to fetch the verifying key from the network as a string\n const response = await get(verifierUri);\n const text = await response.text();\n return VerifyingKey.fromString(text);\n } catch (e) {\n /// If that fails, try to fetch the verifying key from the network as bytes\n try {\n return VerifyingKey.fromBytes(await this.fetchBytes(verifierUri));\n } catch (inner) {\n return new Error(\"Invalid verifying key. Error: \" + inner);\n }\n }\n }\n }\n\n unBondPublicKeys(): Promise {\n return this.fetchCreditsKeys(CREDITS_PROGRAM_KEYS.unbond_public);\n }\n}\n\nexport {AleoKeyProvider, AleoKeyProviderParams, AleoKeyProviderInitParams, CachedKeyPair, FunctionKeyPair, FunctionKeyProvider, KeySearchParams}\n","import {\n Account,\n AleoKeyProvider,\n AleoNetworkClient,\n ExecutionResponse,\n FunctionKeyProvider,\n FunctionKeyPair,\n OfflineQuery,\n KeySearchParams,\n RecordPlaintext,\n RecordProvider,\n RecordSearchParams,\n PrivateKey,\n Program,\n ProgramImports,\n ProvingKey,\n VerifyingKey,\n Transaction,\n PRIVATE_TRANSFER_TYPES,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n ProgramManagerBase as WasmProgramManager, verifyFunctionExecution, AleoKeyProviderParams, CREDITS_PROGRAM_KEYS,\n} from \"./index\";\nimport {Execution} from \"@provablehq/wasm/dist/crates/aleo_wasm\";\n\n/**\n * Represents the options for executing a transaction in the Aleo network.\n * This interface is used to specify the parameters required for building and submitting an execution transaction.\n *\n * @property {string} programName - The name of the program containing the function to be executed.\n * @property {string} functionName - The name of the function to execute within the program.\n * @property {number} fee - The fee to be paid for the transaction.\n * @property {boolean} privateFee - If true, uses a private record to pay the fee; otherwise, uses the account's public credit balance.\n * @property {string[]} inputs - The inputs to the function being executed.\n * @property {RecordSearchParams} [recordSearchParams] - Optional parameters for searching for a record to pay the execution transaction fee.\n * @property {KeySearchParams} [keySearchParams] - Optional parameters for finding the matching proving & verifying keys for the function.\n * @property {string | RecordPlaintext} [feeRecord] - Optional fee record to use for the transaction.\n * @property {ProvingKey} [provingKey] - Optional proving key to use for the transaction.\n * @property {VerifyingKey} [verifyingKey] - Optional verifying key to use for the transaction.\n * @property {PrivateKey} [privateKey] - Optional private key to use for the transaction.\n * @property {OfflineQuery} [offlineQuery] - Optional offline query if creating transactions in an offline environment.\n * @property {string | Program} [program] - Optional program source code to use for the transaction.\n * @property {ProgramImports} [imports] - Optional programs that the program being executed imports.\n */\ninterface ExecuteOptions {\n programName: string;\n functionName: string;\n fee: number;\n privateFee: boolean;\n inputs: string[];\n recordSearchParams?: RecordSearchParams;\n keySearchParams?: KeySearchParams;\n feeRecord?: string | RecordPlaintext;\n provingKey?: ProvingKey;\n verifyingKey?: VerifyingKey;\n privateKey?: PrivateKey;\n offlineQuery?: OfflineQuery;\n program?: string | Program;\n imports?: ProgramImports;\n}\n\n/**\n * The ProgramManager class is used to execute and deploy programs on the Aleo network and create value transfers.\n */\nclass ProgramManager {\n account: Account | undefined;\n keyProvider: FunctionKeyProvider;\n host: string;\n networkClient: AleoNetworkClient;\n recordProvider: RecordProvider | undefined;\n\n /** Create a new instance of the ProgramManager\n *\n * @param { string | undefined } host A host uri running the official Aleo API\n * @param { FunctionKeyProvider | undefined } keyProvider A key provider that implements {@link FunctionKeyProvider} interface\n * @param { RecordProvider | undefined } recordProvider A record provider that implements {@link RecordProvider} interface\n */\n constructor(host?: string | undefined, keyProvider?: FunctionKeyProvider | undefined, recordProvider?: RecordProvider | undefined) {\n this.host = host ? host : 'https://api.explorer.aleo.org/v1';\n this.networkClient = new AleoNetworkClient(this.host);\n \n this.keyProvider = keyProvider ? keyProvider : new AleoKeyProvider();\n this.recordProvider = recordProvider;\n }\n\n /**\n * Set the account to use for transaction submission to the Aleo network\n *\n * @param {Account} account Account to use for transaction submission\n */\n setAccount(account: Account) {\n this.account = account;\n }\n\n /**\n * Set the key provider that provides the proving and verifying keys for programs\n *\n * @param {FunctionKeyProvider} keyProvider\n */\n setKeyProvider(keyProvider: FunctionKeyProvider) {\n this.keyProvider = keyProvider;\n }\n\n /**\n * Set the host peer to use for transaction submission to the Aleo network\n *\n * @param host {string} Peer url to use for transaction submission\n */\n setHost(host: string) {\n this.host = host;\n this.networkClient.setHost(host);\n }\n\n /**\n * Set the record provider that provides records for transactions\n *\n * @param {RecordProvider} recordProvider\n */\n setRecordProvider(recordProvider: RecordProvider) {\n this.recordProvider = recordProvider;\n }\n\n /**\n * Deploy an Aleo program to the Aleo network\n *\n * @param {string} program Program source code\n * @param {number} fee Fee to pay for the transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for searching for a record to use\n * pay the deployment fee\n * @param {string | RecordPlaintext | undefined} feeRecord Optional Fee record to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @returns {string | Error} The transaction id of the deployed program or a failure message from the network\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for deployments\n * const program = \"program hello_hello.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Define a fee in credits\n * const fee = 1.2;\n *\n * // Deploy the program\n * const tx_id = await programManager.deploy(program, fee);\n *\n * // Verify the transaction was successful\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async deploy(\n program: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n feeRecord?: string | RecordPlaintext,\n privateKey?: PrivateKey,\n ): Promise {\n // Ensure the program is valid and does not exist on the network\n try {\n const programObject = Program.fromString(program);\n let programSource;\n try {\n programSource = await this.networkClient.getProgram(programObject.id());\n } catch (e) {\n // Program does not exist on the network, deployment can proceed\n console.log(`Program ${programObject.id()} does not exist on the network, deploying...`);\n }\n if (typeof programSource == \"string\") {\n throw (`Program ${programObject.id()} already exists on the network, please rename your program`);\n }\n } catch (e) {\n throw logAndThrow(`Error validating program: ${e}`);\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let deploymentPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n deploymentPrivateKey = this.account.privateKey();\n }\n\n if (typeof deploymentPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // Resolve the program imports if they exist\n let imports;\n try {\n imports = await this.networkClient.getProgramImports(program);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n\n // Build a deployment transaction and submit it to the network\n const tx = await WasmProgramManager.buildDeploymentTransaction(deploymentPrivateKey, program, fee, feeRecord, this.host, imports, feeProvingKey, feeVerifyingKey);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.buildExecutionTransaction({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async buildExecutionTransaction(options: ExecuteOptions): Promise {\n // Destructure the options object to access the parameters\n const {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n recordSearchParams,\n keySearchParams,\n privateKey,\n offlineQuery\n } = options;\n\n let feeRecord = options.feeRecord;\n let provingKey = options.provingKey;\n let verifyingKey = options.verifyingKey;\n let program = options.program;\n let imports = options.imports;\n\n // Ensure the function exists on the network\n if (program === undefined) {\n try {\n program = (await this.networkClient.getProgram(programName));\n } catch (e) {\n throw logAndThrow(`Error finding ${programName}. Network response: '${e}'. Please ensure you're connected to a valid Aleo network the program is deployed to the network.`);\n }\n } else if (program instanceof Program) {\n program = program.toString();\n }\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Get the fee proving and verifying keys from the key provider\n let feeKeys;\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Resolve the program imports if they exist\n const numberOfImports = Program.fromString(program).getImports().length;\n if (numberOfImports > 0 && !imports) {\n try {\n imports = await this.networkClient.getProgramImports(programName);\n } catch (e) {\n throw logAndThrow(`Error finding program imports. Network response: '${e}'. Please ensure you're connected to a valid Aleo network and the program is deployed to the network.`);\n }\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildExecutionTransaction(executionPrivateKey, program, functionName, inputs, fee, feeRecord, this.host, imports, provingKey, verifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Builds an execution transaction for submission to the Aleo network.\n *\n * @param {ExecuteOptions} options - The options for the execution transaction.\n * @returns {Promise} - A promise that resolves to the transaction or an error.\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider using official Aleo record, key, and network providers\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n *\n * // Build and execute the transaction\n * const transaction = await programManager.execute({\n * programName: \"hello_hello.aleo\",\n * functionName: \"hello_hello\",\n * fee: 0.020,\n * privateFee: false,\n * inputs: [\"5u32\", \"5u32\"],\n * keySearchParams: { \"cacheKey\": \"hello_hello:hello\" }\n * });\n * const result = await programManager.networkClient.submitTransaction(transaction);\n */\n async execute(options: ExecuteOptions): Promise {\n const tx = await this.buildExecutionTransaction(options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Run an Aleo program in offline mode\n *\n * @param {string} program Program source code containing the function to be executed\n * @param {string} function_name Function name to execute\n * @param {string[]} inputs Inputs to the function\n * @param {number} proveExecution Whether to prove the execution of the function and return an execution transcript\n * that contains the proof.\n * @param {string[] | undefined} imports Optional imports to the program\n * @param {KeySearchParams | undefined} keySearchParams Optional parameters for finding the matching proving &\n * verifying keys for the function\n * @param {ProvingKey | undefined} provingKey Optional proving key to use for the transaction\n * @param {VerifyingKey | undefined} verifyingKey Optional verifying key to use for the transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * import { Account, Program } from '@provablehq/sdk';\n *\n * /// Create the source for the \"helloworld\" program\n * const program = \"program helloworld.aleo;\\n\\nfunction hello:\\n input r0 as u32.public;\\n input r1 as u32.private;\\n add r0 r1 into r2;\\n output r2 as u32.private;\\n\";\n * const programManager = new ProgramManager();\n *\n * /// Create a temporary account for the execution of the program\n * const account = new Account();\n * programManager.setAccount(account);\n *\n * /// Get the response and ensure that the program executed correctly\n * const executionResponse = await programManager.run(program, \"hello\", [\"5u32\", \"5u32\"]);\n * const result = executionResponse.getOutputs();\n * assert(result === [\"10u32\"]);\n */\n async run(\n program: string,\n function_name: string,\n inputs: string[],\n proveExecution: boolean,\n imports?: ProgramImports,\n keySearchParams?: KeySearchParams,\n provingKey?: ProvingKey,\n verifyingKey?: VerifyingKey,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // If the function proving and verifying keys are not provided, attempt to find them using the key provider\n if (!provingKey || !verifyingKey) {\n try {\n [provingKey, verifyingKey] = await this.keyProvider.functionKeys(keySearchParams);\n } catch (e) {\n console.log(`Function keys not found. Key finder response: '${e}'. The function keys will be synthesized`)\n }\n }\n\n // Run the program offline and return the result\n console.log(\"Running program offline\")\n console.log(\"Proving key: \", provingKey);\n console.log(\"Verifying key: \", verifyingKey);\n return WasmProgramManager.executeFunctionOffline(executionPrivateKey, program, function_name, inputs, proveExecution, false, imports, provingKey, verifyingKey, this.host, offlineQuery);\n }\n\n /**\n * Join two credits records into a single credits record\n *\n * @param {RecordPlaintext | string} recordOne First credits record to join\n * @param {RecordPlaintext | string} recordTwo Second credits record to join\n * @param {number} fee Fee in credits pay for the join transaction\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the fee record to use\n * to pay the fee for the join transaction\n * @param {RecordPlaintext | string | undefined} feeRecord Fee record to use for the join transaction\n * @param {PrivateKey | undefined} privateKey Private key to use for the join transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n */\n async join(\n recordOne: RecordPlaintext | string,\n recordTwo: RecordPlaintext | string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams | undefined,\n feeRecord?: RecordPlaintext | string | undefined,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery,\n ): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof privateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let joinKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n joinKeys = await this.keyProvider.joinKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [joinProvingKey, joinVerifyingKey] = joinKeys;\n\n // Get the fee record from the account if it is not provided in the parameters\n try {\n feeRecord = privateFee ? await this.getCreditsRecord(fee, [], feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Validate the records provided are valid plaintext records\n try {\n recordOne = recordOne instanceof RecordPlaintext ? recordOne : RecordPlaintext.fromString(recordOne);\n recordTwo = recordTwo instanceof RecordPlaintext ? recordTwo : RecordPlaintext.fromString(recordTwo);\n } catch (e) {\n throw logAndThrow('Records provided are not valid. Please ensure they are valid plaintext records.')\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildJoinTransaction(executionPrivateKey, recordOne, recordTwo, fee, feeRecord, this.host, joinProvingKey, joinVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Split credits into two new credits records\n *\n * @param {number} splitAmount Amount in microcredits to split from the original credits record\n * @param {RecordPlaintext | string} amountRecord Amount record to use for the split transaction\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the split transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise}\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * const record = \"{ owner: aleo184vuwr5u7u0ha5f5k44067dd2uaqewxx6pe5ltha5pv99wvhfqxqv339h4.private, microcredits: 45000000u64.private, _nonce: 4106205762862305308495708971985748592380064201230396559307556388725936304984group.public}\"\n * const tx_id = await programManager.split(25000000, record);\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async split(splitAmount: number, amountRecord: RecordPlaintext | string, privateKey?: PrivateKey, offlineQuery?: OfflineQuery): Promise {\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the split keys from the key provider\n let splitKeys;\n try {\n splitKeys = await this.keyProvider.splitKeys();\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [splitProvingKey, splitVerifyingKey] = splitKeys;\n\n // Validate the record to be split\n try {\n amountRecord = amountRecord instanceof RecordPlaintext ? amountRecord : RecordPlaintext.fromString(amountRecord);\n } catch (e) {\n throw logAndThrow(\"Record provided is not valid. Please ensure it is a valid plaintext record.\");\n }\n\n // Build an execution transaction and submit it to the network\n const tx = await WasmProgramManager.buildSplitTransaction(executionPrivateKey, splitAmount, amountRecord, this.host, splitProvingKey, splitVerifyingKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Pre-synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code to synthesize keys for\n * @param function_id {string} The function id to synthesize keys for\n * @param inputs {Array} Sample inputs to the function\n * @param privateKey {PrivateKey | undefined} Optional private key to use for the key synthesis\n *\n * @returns {Promise}\n */\n async synthesizeKeys(\n program: string,\n function_id: string,\n inputs: Array,\n privateKey?: PrivateKey,\n ): Promise {\n // Resolve the program imports if they exist\n let imports;\n\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\") {\n if (typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n } else {\n executionPrivateKey = new PrivateKey();\n }\n }\n\n // Attempt to run an offline execution of the program and extract the proving and verifying keys\n try {\n imports = await this.networkClient.getProgramImports(program);\n const keyPair = await WasmProgramManager.synthesizeKeyPair(\n executionPrivateKey,\n program,\n function_id,\n inputs,\n imports\n );\n return [keyPair.provingKey(), keyPair.verifyingKey()];\n } catch (e) {\n throw logAndThrow(`Could not synthesize keys - error ${e}. Please ensure the program is valid and the inputs are correct.`);\n }\n }\n\n /**\n * Build a transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programName = \"hello_hello.aleo\";\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async buildTransferTransaction(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n // Validate the transfer type\n transferType = validateTransferType(transferType);\n\n // Get the private key from the account if it is not provided in the parameters\n let executionPrivateKey = privateKey;\n if (typeof executionPrivateKey === \"undefined\" && typeof this.account !== \"undefined\") {\n executionPrivateKey = this.account.privateKey();\n }\n\n if (typeof executionPrivateKey === \"undefined\") {\n throw(\"No private key provided and no private key set in the ProgramManager\");\n }\n\n // Get the proving and verifying keys from the key provider\n let feeKeys;\n let transferKeys\n try {\n feeKeys = privateFee ? await this.keyProvider.feePrivateKeys() : await this.keyProvider.feePublicKeys();\n transferKeys = await this.keyProvider.transferKeys(transferType);\n } catch (e) {\n throw logAndThrow(`Error finding fee keys. Key finder response: '${e}'. Please ensure your key provider is configured correctly.`);\n }\n const [feeProvingKey, feeVerifyingKey] = feeKeys;\n const [transferProvingKey, transferVerifyingKey] = transferKeys;\n\n // Get the amount and fee record from the account if it is not provided in the parameters\n try {\n // Track the nonces of the records found so no duplicate records are used\n const nonces: string[] = [];\n if (requiresAmountRecord(transferType)) {\n // If the transfer type is private and requires an amount record, get it from the record provider\n amountRecord = await this.getCreditsRecord(fee, [], amountRecord, recordSearchParams);\n nonces.push(amountRecord.nonce());\n } else {\n amountRecord = undefined;\n }\n feeRecord = privateFee ? await this.getCreditsRecord(fee, nonces, feeRecord, recordSearchParams) : undefined;\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n\n // Build an execution transaction and submit it to the network\n return await WasmProgramManager.buildTransferTransaction(executionPrivateKey, amount, recipient, transferType, amountRecord, fee, feeRecord, this.host, transferProvingKey, transferVerifyingKey, feeProvingKey, feeVerifyingKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Build a transfer_public_as_signer transaction to transfer credits to another account for later submission to the Aleo network\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n */\n async buildTransferPublicAsSignerTransaction(\n amount: number,\n recipient: string,\n fee: number,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n return this.buildTransferTransaction(amount, recipient, \"public\", fee, false, undefined, undefined, undefined, privateKey, offlineQuery);\n }\n\n /**\n * Transfer credits to another account\n *\n * @param {number} amount The amount of credits to transfer\n * @param {string} recipient The recipient of the transfer\n * @param {string} transferType The type of transfer to perform - options: 'private', 'privateToPublic', 'public', 'publicToPrivate'\n * @param {number} fee The fee to pay for the transfer\n * @param {boolean} privateFee Use a private record to pay the fee. If false this will use the account's public credit balance\n * @param {RecordSearchParams | undefined} recordSearchParams Optional parameters for finding the amount and fee\n * records for the transfer transaction\n * @param {RecordPlaintext | string} amountRecord Optional amount record to use for the transfer\n * @param {RecordPlaintext | string} feeRecord Optional fee record to use for the transfer\n * @param {PrivateKey | undefined} privateKey Optional private key to use for the transfer transaction\n * @param {OfflineQuery | undefined} offlineQuery Optional offline query if creating transactions in an offline environment\n * @returns {Promise} The transaction id of the transfer transaction\n *\n * @example\n * // Create a new NetworkClient, KeyProvider, and RecordProvider\n * const networkClient = new AleoNetworkClient(\"https://api.explorer.aleo.org/v1\");\n * const keyProvider = new AleoKeyProvider();\n * const recordProvider = new NetworkRecordProvider(account, networkClient);\n *\n * // Initialize a program manager with the key provider to automatically fetch keys for executions\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, recordProvider);\n * await programManager.initialize();\n * const tx_id = await programManager.transfer(1, \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"private\", 0.2)\n * const transaction = await programManager.networkClient.getTransaction(tx_id);\n */\n async transfer(\n amount: number,\n recipient: string,\n transferType: string,\n fee: number,\n privateFee: boolean,\n recordSearchParams?: RecordSearchParams,\n amountRecord?: RecordPlaintext | string,\n feeRecord?: RecordPlaintext | string,\n privateKey?: PrivateKey,\n offlineQuery?: OfflineQuery\n ): Promise {\n const tx = await this.buildTransferTransaction(amount, recipient, transferType, fee, privateFee, recordSearchParams, amountRecord, feeRecord, privateKey, offlineQuery);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build transaction to bond credits to a validator for later submission to the Aleo Network\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction object for later submission\n * const tx = await programManager.buildBondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be later submitted to the network using the network client.\n * const result = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Partial} options - Override default execution options.\n */\n async buildBondPublicTransaction(staker_address: string, validator_address: string, withdrawal_address: string, amount: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_public\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [staker_address, validator_address, withdrawal_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_public.verifier,\n cacheKey: \"credits.aleo/bond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Bond credits to validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", \"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is bonding the credits\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the signer (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 1,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {Options} options Options for the execution\n */\n async bondPublic(staker_address: string, validator_address: string, withdrawal_address:string, amount: number, options: Partial = {}) {\n const tx = await this.buildBondPublicTransaction(staker_address, validator_address, withdrawal_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a bond_validator transaction for later submission to the Aleo Network.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bond validator transaction object for later use.\n * const tx = await programManager.buildBondValidatorTransaction(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n * console.log(tx);\n *\n * // The transaction can later be submitted to the network using the network client.\n * const tx_id = await programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async buildBondValidatorTransaction(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const adjustedCommission = Math.trunc(commission)\n\n const {\n programName = \"credits.aleo\",\n functionName = \"bond_validator\",\n fee = options.fee || 0.86,\n privateFee = false,\n inputs = [validator_address, withdrawal_address, `${scaledAmount.toString()}u64`, `${adjustedCommission.toString()}u8`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.bond_validator.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.bond_validator.verifier,\n cacheKey: \"credits.aleo/bond_validator\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Build transaction to bond a validator.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.bondValidator(\"aleo1rhgdu77hgyqd3xjj8ucu3jj9r2krwz6mnzyd80gncr5fxcwlh5rsvzp9px\", \"aleo1feya8sjy9k2zflvl2dx39pdsq5tju28elnp2ektnn588uu9ghv8s84msv9\", 2000000);\n *\n * @returns string\n * @param {string} validator_address Address of the validator to bond to, if this address is the same as the staker (i.e. the\n * executor of this function), it will attempt to bond the credits as a validator. Bonding as a validator currently\n * requires a minimum of 10,000,000 credits to bond (subject to change). If the address is specified is an existing\n * validator and is different from the address of the executor of this function, it will bond the credits to that\n * validator's staking committee as a delegator. A minimum of 10 credits is required to bond as a delegator.\n * @param {string} withdrawal_address Address to withdraw the staked credits to when unbond_public is called.\n * @param {number} amount The amount of credits to bond\n * @param {number} commission The commission rate for the validator (must be between 0 and 100 - an error will be thrown if it is not)\n * @param {Partial} options - Override default execution options.\n */\n async bondValidator(validator_address: string, withdrawal_address: string, amount: number, commission: number, options: Partial = {}) {\n const tx = await this.buildBondValidatorTransaction(validator_address, withdrawal_address, amount, commission, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to unbond public credits from a validator in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is unbonding the credits.\n * @param {number} amount - The amount of credits to unbond (scaled by 1,000,000).\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management.\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to unbond credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * const tx = await programManager.buildUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 2000000);\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildUnbondPublicTransaction(staker_address: string, amount: number, options: Partial = {}): Promise {\n const scaledAmount = Math.trunc(amount * 1000000);\n\n const {\n programName = \"credits.aleo\",\n functionName = \"unbond_public\",\n fee = options.fee || 1.3,\n privateFee = false,\n inputs = [staker_address, `${scaledAmount.toString()}u64`],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.unbond_public.verifier,\n cacheKey: \"credits.aleo/unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Unbond a specified amount of staked credits.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction and send it to the network\n * const tx_id = await programManager.unbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\", 10);\n *\n * @returns string\n * @param {string} staker_address Address of the staker who is unbonding the credits\n * @param {number} amount Amount of credits to unbond. If the address of the executor of this function is an\n * existing validator, it will subtract this amount of credits from the validator's staked credits. If there are\n * less than 1,000,000 credits staked pool after the unbond, the validator will be removed from the validator set.\n * If the address of the executor of this function is not a validator and has credits bonded as a delegator, it will\n * subtract this amount of credits from the delegator's staked credits. If there are less than 10 credits bonded\n * after the unbond operation, the delegator will be removed from the validator's staking pool.\n * @param {ExecuteOptions} options Options for the execution\n */\n async unbondPublic(staker_address: string, amount: number, options: Partial = {}): Promise {\n const tx = await this.buildUnbondPublicTransaction(staker_address, amount, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a transaction to claim unbonded public credits in the Aleo network.\n *\n * @param {string} staker_address - The address of the staker who is claiming the credits.\n * @param {Partial} options - Override default execution options.\n * @returns {Promise} - A promise that resolves to the transaction or an error message.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to claim unbonded credits.\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n *\n * // Create the claim unbonded transaction object for later use.\n * const tx = await programManager.buildClaimUnbondPublicTransaction(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n * console.log(tx);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n */\n async buildClaimUnbondPublicTransaction(staker_address: string, options: Partial = {}): Promise {\n const {\n programName = \"credits.aleo\",\n functionName = \"claim_unbond_public\",\n fee = options.fee || 2,\n privateFee = false,\n inputs = [staker_address],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.claim_unbond_public.verifier,\n cacheKey: \"credits.aleo/claim_unbond_public\"\n }),\n program = this.creditsProgram(),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.buildExecutionTransaction(executeOptions);\n }\n\n /**\n * Claim unbonded credits. If credits have been unbonded by the account executing this function, this method will\n * claim them and add them to the public balance of the account.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"YourPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.claimUnbondPublic(\"aleo1jx8s4dvjepculny4wfrzwyhs3tlyv65r58ns3g6q2gm2esh7ps8sqy9s5j\");\n *\n * @param {string} staker_address Address of the staker who is claiming the credits\n * @param {ExecuteOptions} options\n * @returns string\n */\n async claimUnbondPublic(staker_address: string, options: Partial = {}): Promise {\n const tx = await this.buildClaimUnbondPublicTransaction(staker_address, options);\n return await this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Build a set_validator_state transaction for later usage.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx = await programManager.buildSetValidatorStateTransaction(true);\n *\n * // The transaction can be submitted later to the network using the network client.\n * programManager.networkClient.submitTransaction(tx);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async buildSetValidatorStateTransaction(validator_state: boolean, options: Partial = {}) {\n const {\n programName = \"credits.aleo\",\n functionName = \"set_validator_state\",\n fee = 1,\n privateFee = false,\n inputs = [validator_state.toString()],\n keySearchParams = new AleoKeyProviderParams({\n proverUri: CREDITS_PROGRAM_KEYS.set_validator_state.prover,\n verifierUri: CREDITS_PROGRAM_KEYS.set_validator_state.verifier,\n cacheKey: \"credits.aleo/set_validator_state\"\n }),\n ...additionalOptions\n } = options;\n\n const executeOptions: ExecuteOptions = {\n programName,\n functionName,\n fee,\n privateFee,\n inputs,\n keySearchParams,\n ...additionalOptions\n };\n\n return await this.execute(executeOptions);\n }\n\n /**\n * Submit a set_validator_state transaction to the Aleo Network.\n *\n * This function allows a validator to set their state to be either opened or closed to new stakers.\n * When the validator is open to new stakers, any staker (including the validator) can bond or unbond from the validator.\n * When the validator is closed to new stakers, existing stakers can still bond or unbond from the validator, but new stakers cannot bond.\n *\n * This function serves two primary purposes:\n * 1. Allow a validator to leave the committee, by closing themselves to stakers and then unbonding all of their stakers.\n * 2. Allow a validator to maintain their % of stake, by closing themselves to allowing more stakers to bond to them.\n *\n * @example\n * // Create a keyProvider to handle key management\n * const keyProvider = new AleoKeyProvider();\n * keyProvider.useCache = true;\n *\n * // Create a new ProgramManager with the key that will be used to bond credits\n * const programManager = new ProgramManager(\"https://api.explorer.aleo.org/v1\", keyProvider, undefined);\n * programManager.setAccount(new Account(\"ValidatorPrivateKey\"));\n *\n * // Create the bonding transaction\n * const tx_id = await programManager.setValidatorState(true);\n *\n * @returns string\n * @param {boolean} validator_state\n * @param {Partial} options - Override default execution options\n */\n async setValidatorState(validator_state: boolean, options: Partial = {}) {\n const tx = await this.buildSetValidatorStateTransaction(validator_state, options);\n return this.networkClient.submitTransaction(tx);\n }\n\n /**\n * Verify a proof of execution from an offline execution\n *\n * @param {executionResponse} executionResponse\n * @returns {boolean} True if the proof is valid, false otherwise\n */\n verifyExecution(executionResponse: ExecutionResponse): boolean {\n try {\n const execution = executionResponse.getExecution();\n const function_id = executionResponse.getFunctionId();\n const program = executionResponse.getProgram();\n const verifyingKey = executionResponse.getVerifyingKey();\n return verifyFunctionExecution(execution, verifyingKey, program, function_id);\n } catch(e) {\n console.warn(\"The execution was not found in the response, cannot verify the execution\");\n return false;\n }\n }\n\n /**\n * Create a program object from a program's source code\n *\n * @param {string} program Program source code\n * @returns {Program | Error} The program object\n */\n createProgramFromSource(program: string): Program | Error {\n return Program.fromString(program);\n }\n\n /**\n * Get the credits program object\n *\n * @returns {Program} The credits program object\n */\n creditsProgram(): Program {\n return Program.getCreditsProgram();\n }\n\n /**\n * Verify a program is valid\n *\n * @param {string} program The program source code\n */\n verifyProgram(program: string): boolean {\n try {\n Program.fromString(program);\n return true;\n } catch (e) {\n return false;\n }\n }\n\n // Internal utility function for getting a credits.aleo record\n async getCreditsRecord(amount: number, nonces: string[], record?: RecordPlaintext | string, params?: RecordSearchParams): Promise {\n try {\n return record instanceof RecordPlaintext ? record : RecordPlaintext.fromString(record);\n } catch (e) {\n try {\n const recordProvider = this.recordProvider;\n return (await recordProvider.findCreditsRecord(amount, true, nonces, params))\n } catch (e) {\n throw logAndThrow(`Error finding fee record. Record finder response: '${e}'. Please ensure you're connected to a valid Aleo network and a record with enough balance exists.`);\n }\n }\n }\n}\n\n// Ensure the transfer type requires an amount record\nfunction requiresAmountRecord(transferType: string): boolean {\n return PRIVATE_TRANSFER_TYPES.has(transferType);\n}\n\n// Validate the transfer type\nfunction validateTransferType(transferType: string): string | Error {\n return VALID_TRANSFER_TYPES.has(transferType) ? transferType :\n logAndThrow(`Invalid transfer type '${transferType}'. Valid transfer types are 'private', 'privateToPublic', 'public', and 'publicToPrivate'.`);\n}\n\nexport { ProgramManager }\n","import {VerifyingKey, Metadata} from \"@provablehq/wasm\";\n\nconst KEY_STORE = Metadata.baseUrl();\n\ninterface Key {\n name: string,\n locator: string,\n prover: string,\n verifier: string,\n verifyingKey: () => VerifyingKey,\n}\n\nfunction convert(metadata: Metadata): Key {\n // This looks up the method name in VerifyingKey\n const verifyingKey = (VerifyingKey as any)[metadata.verifyingKey];\n\n if (!verifyingKey) {\n throw new Error(\"Invalid method name: \" + metadata.verifyingKey);\n }\n\n return {\n name: metadata.name,\n locator: metadata.locator,\n prover: metadata.prover,\n verifier: metadata.verifier,\n verifyingKey,\n };\n}\n\nconst CREDITS_PROGRAM_KEYS = {\n bond_public: convert(Metadata.bond_public()),\n bond_validator: convert(Metadata.bond_validator()),\n claim_unbond_public: convert(Metadata.claim_unbond_public()),\n fee_private: convert(Metadata.fee_private()),\n fee_public: convert(Metadata.fee_public()),\n inclusion: convert(Metadata.inclusion()),\n join: convert(Metadata.join()),\n set_validator_state: convert(Metadata.set_validator_state()),\n split: convert(Metadata.split()),\n transfer_private: convert(Metadata.transfer_private()),\n transfer_private_to_public: convert(Metadata.transfer_private_to_public()),\n transfer_public: convert(Metadata.transfer_public()),\n transfer_public_as_signer: convert(Metadata.transfer_public_as_signer()),\n transfer_public_to_private: convert(Metadata.transfer_public_to_private()),\n unbond_public: convert(Metadata.unbond_public()),\n getKey: function(key: string): Key | Error {\n if (this.hasOwnProperty(key)) {\n return (this as any)[key] as Key;\n } else {\n return new Error(`Key \"${key}\" not found.`);\n }\n }\n};\n\nconst PRIVATE_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n]);\nconst VALID_TRANSFER_TYPES = new Set([\n \"transfer_private\",\n \"private\",\n \"transferPrivate\",\n \"transfer_private_to_public\",\n \"privateToPublic\",\n \"transferPrivateToPublic\",\n \"transfer_public\",\n \"transfer_public_as_signer\",\n \"public\",\n \"public_as_signer\",\n \"transferPublic\",\n \"transferPublicAsSigner\",\n \"transfer_public_to_private\",\n \"publicToPrivate\",\n \"publicAsSigner\",\n \"transferPublicToPrivate\",\n]);\nconst PRIVATE_TRANSFER = new Set([\n \"private\",\n \"transfer_private\",\n \"transferPrivate\",\n]);\nconst PRIVATE_TO_PUBLIC_TRANSFER = new Set([\n \"private_to_public\",\n \"privateToPublic\",\n \"transfer_private_to_public\",\n \"transferPrivateToPublic\",\n]);\nconst PUBLIC_TRANSFER = new Set([\n \"public\",\n \"transfer_public\",\n \"transferPublic\",\n]);\nconst PUBLIC_TRANSFER_AS_SIGNER = new Set([\n \"public_as_signer\",\n \"transfer_public_as_signer\",\n \"transferPublicAsSigner\",\n]);\nconst PUBLIC_TO_PRIVATE_TRANSFER = new Set([\n \"public_to_private\",\n \"publicToPrivate\",\n \"transfer_public_to_private\",\n \"transferPublicToPrivate\",\n]);\n\nfunction logAndThrow(message: string): Error {\n console.error(message);\n throw message;\n}\n\nimport { Account } from \"./account\";\nimport { AleoNetworkClient, ProgramImports } from \"./network-client\";\nimport { Block } from \"./models/block\";\nimport { Execution } from \"./models/execution\";\nimport { Input } from \"./models/input\";\nimport { Output } from \"./models/output\";\nimport { TransactionModel } from \"./models/transactionModel\";\nimport { Transition } from \"./models/transition\";\nimport {\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n CachedKeyPair,\n FunctionKeyPair,\n FunctionKeyProvider,\n KeySearchParams,\n} from \"./function-key-provider\";\nimport {\n OfflineKeyProvider,\n OfflineSearchParams\n} from \"./offline-key-provider\";\nimport {\n BlockHeightSearch,\n NetworkRecordProvider,\n RecordProvider,\n RecordSearchParams,\n} from \"./record-provider\";\n\n// @TODO: This function is no longer needed, remove it.\nasync function initializeWasm() {\n console.warn(\"initializeWasm is deprecated, you no longer need to use it\");\n}\n\nexport { createAleoWorker } from \"./managed-worker\";\n\nexport { ProgramManager } from \"./program-manager\";\n\nexport {\n Address,\n Execution as FunctionExecution,\n ExecutionResponse,\n Field,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProgramManager as ProgramManagerBase,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n Signature,\n Transaction,\n VerifyingKey,\n ViewKey,\n initThreadPool,\n verifyFunctionExecution,\n} from \"@provablehq/wasm\";\n\nexport { initializeWasm };\n\nexport {\n Account,\n AleoKeyProvider,\n AleoKeyProviderParams,\n AleoKeyProviderInitParams,\n AleoNetworkClient,\n Block,\n BlockHeightSearch,\n CachedKeyPair,\n Execution,\n FunctionKeyPair,\n FunctionKeyProvider,\n Input,\n Key,\n KeySearchParams,\n NetworkRecordProvider,\n ProgramImports,\n OfflineKeyProvider,\n OfflineSearchParams,\n Output,\n RecordProvider,\n RecordSearchParams,\n TransactionModel,\n Transition,\n CREDITS_PROGRAM_KEYS,\n KEY_STORE,\n PRIVATE_TRANSFER,\n PRIVATE_TO_PUBLIC_TRANSFER,\n PRIVATE_TRANSFER_TYPES,\n PUBLIC_TRANSFER,\n PUBLIC_TRANSFER_AS_SIGNER,\n PUBLIC_TO_PRIVATE_TRANSFER,\n VALID_TRANSFER_TYPES,\n logAndThrow,\n};\n","import {initThreadPool, ProgramManager, PrivateKey, verifyFunctionExecution, FunctionKeyPair} from \"./index\";\nimport { AleoKeyProvider, AleoKeyProviderParams} from \"./function-key-provider\";\nimport { expose } from \"comlink\";\n\nawait initThreadPool();\n\nconst defaultHost = \"https://api.explorer.aleo.org/v1\";\nconst keyProvider = new AleoKeyProvider();\nconst programManager = new ProgramManager(\n defaultHost,\n keyProvider,\n undefined\n);\n\nkeyProvider.useCache(true);\n\nlet lastLocalProgram: string = \"\";\n\nexport interface WorkerAPI {\n run: (\n localProgram: string,\n aleoFunction: string,\n inputs: string[],\n privateKey: string\n ) => Promise<{ outputs: any; execution: string } | string>;\n\n getPrivateKey: () => Promise;\n}\nasync function run(\n localProgram: string,\n aleoFunction: string,\n inputs: string[],\n privateKey: string,\n proveExecution = false\n) {\n console.log(\"Web worker: Executing function locally...\");\n const startTime = performance.now();\n\n try {\n // Ensure the program is valid and that it contains the function specified\n const program = programManager.createProgramFromSource(localProgram);\n if (program instanceof Error) {\n throw \"Error creating program from source\";\n }\n const program_id = program.id();\n if (!program.hasFunction(aleoFunction)) {\n throw `Program ${program_id} does not contain function ${aleoFunction}`;\n }\n const cacheKey = `${program_id}:${aleoFunction}`;\n\n // Get the program imports\n const imports = await programManager.networkClient.getProgramImports(\n localProgram\n );\n\n if (imports instanceof Error) {\n throw \"Error getting program imports\";\n }\n // Get the proving and verifying keys for the function\n if (lastLocalProgram !== localProgram) {\n const keys = await programManager.synthesizeKeys(\n localProgram,\n aleoFunction,\n inputs,\n PrivateKey.from_string(privateKey)\n );\n programManager.keyProvider.cacheKeys(cacheKey, keys);\n lastLocalProgram = localProgram;\n }\n\n // Pass the cache key to the execute function\n const keyParams = new AleoKeyProviderParams({\n cacheKey: cacheKey,\n });\n\n // Execute the function locally\n const response = await programManager.run(\n localProgram,\n aleoFunction,\n inputs,\n proveExecution,\n imports,\n keyParams,\n undefined,\n undefined,\n PrivateKey.from_string(privateKey),\n );\n\n // Return the outputs to the main thread\n console.log(\n `Web worker: Local execution completed in ${\n performance.now() - startTime\n } ms`\n );\n const outputs = response.getOutputs();\n const execution = response.getExecution();\n let executionString = \"\";\n\n const keys = keyProvider.getKeys(cacheKey);\n\n if (keys instanceof Error) {\n throw \"Could not get verifying key\";\n }\n\n const verifyingKey = keys[1];\n\n if (execution) {\n verifyFunctionExecution(\n execution,\n verifyingKey,\n program,\n \"hello\"\n );\n executionString = execution.toString();\n console.log(\"Execution verified successfully: \" + execution);\n } else {\n executionString = \"\";\n }\n\n console.log(`Function execution response: ${outputs}`);\n\n return { outputs: outputs, execution: executionString };\n } catch (error) {\n console.error(error);\n return error ? error.toString() : \"Unknown error\";\n }\n}\n\nasync function getPrivateKey() {\n const privateKey = new PrivateKey();\n return privateKey.to_string();\n}\n\nconst workerAPI = { run, getPrivateKey };\nexpose(workerAPI);\n"],"names":["proxyMarker","Symbol","createEndpoint","releaseProxy","finalizer","throwMarker","isObject","val","transferHandlers","Map","canHandle","serialize","obj","port1","port2","MessageChannel","expose","deserialize","port","start","createProxy","target","value","serialized","Error","isError","message","name","stack","Object","assign","ep","globalThis","allowedOrigins","addEventListener","callback","ev","data","origin","allowedOrigin","RegExp","test","isAllowedOrigin","console","warn","id","type","path","argumentList","map","fromWireValue","returnValue","parent","slice","reduce","prop","rawValue","apply","proxy","transfers","transferCache","set","transfer","undefined","Promise","resolve","catch","then","wireValue","transferables","toWireValue","postMessage","removeEventListener","closeEndPoint","error","TypeError","endpoint","constructor","isMessagePort","close","throwIfProxyReleased","isReleased","releaseEndpoint","requestResponseMessage","proxyCounter","WeakMap","proxyFinalizers","FinalizationRegistry","newCount","get","isProxyReleased","Proxy","_target","unregister","unregisterProxy","length","r","p","toString","bind","_thisArg","rawArgumentList","last","processArguments","construct","register","registerProxy","processed","v","arr","Array","prototype","concat","handler","serializedValue","msg","fill","Math","floor","random","Number","MAX_SAFE_INTEGER","join","l","async","url","options","response","fetch","ok","status","post","method","AleoNetworkClient","host","headers","account","this","setAccount","getAccount","setHost","fetchData","json","findUnspentRecords","startHeight","endHeight","privateKey","amounts","maxMicrocredits","nonces","records","end","resolvedPrivateKey","latestHeight","failures","totalRecordValue","BigInt","_privateKey","PrivateKey","from_string","viewKey","to_view_key","blockHeight","getLatestHeight","blocks","getBlockRange","i","transactions","j","confirmedTransaction","transaction","execution","transitions","k","transition","program","outputs","output","record","RecordCiphertext","fromString","isOwner","recordPlaintext","decrypt","nonce","includes","serialNumber","serialNumberString","getTransitionId","push","microcredits","amounts_found","getBlock","height","getDeploymentTransactionIDForProgram","Program","replace","getDeploymentTransactionForProgram","transaction_id","getTransaction","getLatestBlock","getLatestCommittee","getProgram","programId","getProgramObject","inputProgram","getProgramImports","imports","importList","getImports","import_id","hasOwnProperty","programSource","nestedImports","key","logAndThrow","getProgramImportNames","getProgramMappingNames","getProgramMappingValue","mappingName","getStateRoot","getTransactions","getTransactionsInMempool","inputOrOutputID","submitTransaction","transaction_string","Transaction","body","AleoKeyProviderParams","proverUri","verifierUri","cacheKey","params","AleoKeyProvider","cache","cacheOption","keyUris","fetchBytes","arrayBuffer","Uint8Array","KEY_STORE","useCache","clearCache","clear","cacheKeys","keyId","keys","provingKey","verifyingKey","toBytes","containsKeys","has","deleteKeys","delete","getKeys","debug","provingKeyBytes","verifyingKeyBytes","ProvingKey","fromBytes","VerifyingKey","functionKeys","proverUrl","verifierUrl","CREDITS_PROGRAM_KEYS","getKey","fetchCreditsKeys","fetchRemoteKeys","getVerifyingKey","fetchProvingKey","locator","keyPair","verifying_key","proving_key","prover","bond_public","bondPublicKeys","bondValidatorKeys","bond_validator","claimUnbondPublicKeys","claim_unbond_public","transferKeys","visibility","PRIVATE_TRANSFER","transfer_private","PRIVATE_TO_PUBLIC_TRANSFER","transfer_private_to_public","PUBLIC_TRANSFER","transfer_public","PUBLIC_TRANSFER_AS_SIGNER","transfer_public_as_signer","PUBLIC_TO_PRIVATE_TRANSFER","transfer_public_to_private","joinKeys","splitKeys","split","feePrivateKeys","fee_private","feePublicKeys","fee_public","verifier","inclusion","set_validator_state","unbond_public","text","e","inner","unBondPublicKeys","ProgramManager","keyProvider","networkClient","recordProvider","setKeyProvider","setRecordProvider","deploy","fee","privateFee","recordSearchParams","feeRecord","programObject","log","feeKeys","deploymentPrivateKey","getCreditsRecord","feeProvingKey","feeVerifyingKey","tx","ProgramManager$1","buildDeploymentTransaction","buildExecutionTransaction","programName","functionName","inputs","keySearchParams","offlineQuery","executionPrivateKey","execute","run","function_name","proveExecution","executeFunctionOffline","recordOne","recordTwo","joinProvingKey","joinVerifyingKey","RecordPlaintext","buildJoinTransaction","splitAmount","amountRecord","splitProvingKey","splitVerifyingKey","buildSplitTransaction","synthesizeKeys","function_id","synthesizeKeyPair","buildTransferTransaction","amount","recipient","transferType","validateTransferType","transferProvingKey","transferVerifyingKey","requiresAmountRecord","buildTransferPublicTransaction","buildTransferPublicAsSignerTransaction","buildBondPublicTransaction","staker_address","validator_address","withdrawal_address","scaledAmount","trunc","creditsProgram","additionalOptions","executeOptions","bondPublic","buildBondValidatorTransaction","commission","adjustedCommission","bondValidator","buildUnbondPublicTransaction","unbondPublic","buildClaimUnbondPublicTransaction","claimUnbondPublic","buildSetValidatorStateTransaction","validator_state","setValidatorState","verifyExecution","executionResponse","getExecution","getFunctionId","verifyFunctionExecution","createProgramFromSource","getCreditsProgram","verifyProgram","findCreditsRecord","PRIVATE_TRANSFER_TYPES","VALID_TRANSFER_TYPES","Metadata","baseUrl","convert","metadata","Set","initThreadPool","defaultHost","programManager","lastLocalProgram","localProgram","aleoFunction","startTime","performance","now","program_id","hasFunction","keyParams","getOutputs","executionString","getPrivateKey","to_string","workerAPI"],"sourceRoot":""} \ No newline at end of file diff --git a/933.bundle.js b/933.bundle.js deleted file mode 100644 index a2b0eb2c1..000000000 --- a/933.bundle.js +++ /dev/null @@ -1,2 +0,0 @@ -(self.webpackChunkaleo_website=self.webpackChunkaleo_website||[]).push([[933],{2583:(_,t,e)=>{_.exports=e.p+"2d6a4d794221941c07b8.js"},5934:(_,t,e)=>{_.exports=e.p+"58342153fc9a001d7976.wasm"},9933:(_,t,e)=>{e.a(_,(async(_,r)=>{try{function n(_,t,e,r){return new Promise((n=>{const i=new Worker(_,{type:"module"});i.addEventListener("message",(_=>{setTimeout((()=>{n(i),i.unref&&i.unref()}),0)}),{capture:!0,once:!0}),i.postMessage({module:t,memory:e,address:r})}))}let K;e.d(t,{$r:()=>B_,CK:()=>j,L:()=>W_,PD:()=>q_,SF:()=>j_,XV:()=>J_,YW:()=>N_,_q:()=>E_,fW:()=>I_,hz:()=>L_,zW:()=>U_});const C=new Array(128).fill(void 0);function i(_){return C[_]}C.push(void 0,null,!0,!1);let E=C.length;function o(_){_<132||(C[_]=E,E=_)}function a(_){const t=i(_);return o(_),t}const M="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&M.decode();let B=null;function s(){return null!==B&&B.buffer===K.memory.buffer||(B=new Uint8Array(K.memory.buffer)),B}function c(_,t){return _>>>=0,M.decode(s().slice(_,_+t))}function g(_){E===C.length&&C.push(C.length+1);const t=E;return E=C[t],C[t]=_,t}let U=0;const I="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}},q=function(_,t){const e=I.encode(_);return t.set(e),{read:_.length,written:e.length}};function w(_,t,e){if(void 0===e){const e=I.encode(_),r=t(e.length,1)>>>0;return s().subarray(r,r+e.length).set(e),U=e.length,r}let r=_.length,n=t(r,1)>>>0;const i=s();let o=0;for(;o127)break;i[n+o]=t}if(o!==r){0!==o&&(_=_.slice(o)),n=e(n,r,r=o+3*_.length,1)>>>0;const t=s().subarray(n+o,n+r);o+=q(_,t).written,n=e(n,r,o,1)>>>0}return U=o,n}function d(_){return null==_}let W=null;function b(){return null!==W&&W.buffer===K.memory.buffer||(W=new Int32Array(K.memory.buffer)),W}function l(_){const t=typeof _;if("number"==t||"boolean"==t||null==_)return`${_}`;if("string"==t)return`"${_}"`;if("symbol"==t){const t=_.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=_.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(_)){const t=_.length;let e="[";t>0&&(e+=l(_[0]));for(let r=1;r1))return toString.call(_);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(_)+")"}catch(_){return"Object"}return _ instanceof Error?`${_.name}: ${_.message}\n${_.stack}`:r}const $="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>{K.__wbindgen_export_3.get(_.dtor)(_.a,_.b)}));function u(_,t,e,r){const n={a:_,b:t,cnt:1,dtor:e},i=(..._)=>{n.cnt++;const t=n.a;n.a=0;try{return r(t,n.b,..._)}finally{0==--n.cnt?(K.__wbindgen_export_3.get(n.dtor)(t,n.b),$.unregister(n)):n.a=t}};return i.original=n,$.register(i,n,n),i}function f(_,t,e){K._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(_,t,g(e))}function p(_,t){if(!(_ instanceof t))throw new Error(`expected instance of ${t.name}`);return _.ptr}function y(_,t){const e=t(1*_.length,1)>>>0;return s().set(_,e/1),U=_.length,e}function m(_,t,e,r){try{const o=K.__wbindgen_add_to_stack_pointer(-16);p(_,H),p(t,S_),p(e,g_);const s=w(r,K.__wbindgen_malloc,K.__wbindgen_realloc),c=U;K.verifyFunctionExecution(o,_.__wbg_ptr,t.__wbg_ptr,e.__wbg_ptr,s,c);var n=b()[o/4+0],i=b()[o/4+1];if(b()[o/4+2])throw a(i);return 0!==n}finally{K.__wbindgen_add_to_stack_pointer(16)}}let N=null;function h(){return null!==N&&N.buffer===K.memory.buffer||(N=new BigInt64Array(K.memory.buffer)),N}function v(_,t){return _>>>=0,s().subarray(_/1,_/1+t)}function k(_){K.runRayonThread(_)}function P(_,t){return a(K.initThreadPool(g(_),t))}function S(_,t){try{return _.apply(this,t)}catch(_){K.__wbindgen_exn_store(g(_))}}function x(_,t,e,r){K.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(_,t,g(e),g(r))}const D="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_address_free(_>>>0)));let J=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,D.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,D.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_address_free(_)}static from_private_key(t){p(t,o_);const e=K.address_from_private_key(t.__wbg_ptr);return _.__wrap(e)}static from_view_key(t){p(t,V_);const e=K.address_from_view_key(t.__wbg_ptr);return _.__wrap(e)}static from_string(t){const e=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),r=U,n=K.address_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.address_to_string(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}verify(_,t){const e=y(_,K.__wbindgen_malloc),r=U;p(t,h_);return 0!==K.address_verify(this.__wbg_ptr,e,r,t.__wbg_ptr)}};const L="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_execution_free(_>>>0)));let H=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,L.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,L.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_execution_free(_)}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.execution_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.execution_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}};const Q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_executionresponse_free(_>>>0)));let X=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,Q.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Q.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_executionresponse_free(_)}getOutputs(){return a(K.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const _=K.executionresponse_getExecution(this.__wbg_ptr);return 0===_?void 0:H.__wrap(_)}getKeys(){try{const e=K.__wbindgen_add_to_stack_pointer(-16);K.executionresponse_getKeys(e,this.__wbg_ptr);var _=b()[e/4+0],t=b()[e/4+1];if(b()[e/4+2])throw a(t);return __.__wrap(_)}finally{K.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const _=K.executionresponse_getProvingKey(this.__wbg_ptr);return 0===_?void 0:l_.__wrap(_)}getVerifyingKey(){const _=K.executionresponse_getVerifyingKey(this.__wbg_ptr);return S_.__wrap(_)}getFunctionId(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.executionresponse_getFunctionId(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}getProgram(){const _=K.executionresponse_getProgram(this.__wbg_ptr);return g_.__wrap(_)}};const Y="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_field_free(_>>>0)));let G=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,Y.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Y.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_field_free(_)}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.field_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.field_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}};const Z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_keypair_free(_>>>0)));class __{static __wrap(_){_>>>=0;const t=Object.create(__.prototype);return t.__wbg_ptr=_,Z.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_keypair_free(_)}constructor(_,t){p(_,l_);var e=_.__destroy_into_raw();p(t,S_);var r=t.__destroy_into_raw();const n=K.keypair_new(e,r);return this.__wbg_ptr=n>>>0,this}provingKey(){try{const e=K.__wbindgen_add_to_stack_pointer(-16);K.keypair_provingKey(e,this.__wbg_ptr);var _=b()[e/4+0],t=b()[e/4+1];if(b()[e/4+2])throw a(t);return l_.__wrap(_)}finally{K.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const e=K.__wbindgen_add_to_stack_pointer(-16);K.keypair_verifyingKey(e,this.__wbg_ptr);var _=b()[e/4+0],t=b()[e/4+1];if(b()[e/4+2])throw a(t);return S_.__wrap(_)}finally{K.__wbindgen_add_to_stack_pointer(16)}}}const t_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_metadata_free(_>>>0)));let e_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,t_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,t_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_metadata_free(_)}get name(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.__wbg_get_metadata_name(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}set name(_){const t=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),e=U;K.__wbg_set_metadata_name(this.__wbg_ptr,t,e)}get locator(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.__wbg_get_metadata_locator(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}set locator(_){const t=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),e=U;K.__wbg_set_metadata_locator(this.__wbg_ptr,t,e)}get prover(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.__wbg_get_metadata_prover(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}set prover(_){const t=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),e=U;K.__wbg_set_metadata_prover(this.__wbg_ptr,t,e)}get verifier(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.__wbg_get_metadata_verifier(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}set verifier(_){const t=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),e=U;K.__wbg_set_metadata_verifier(this.__wbg_ptr,t,e)}get verifyingKey(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.__wbg_get_metadata_verifyingKey(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}set verifyingKey(_){const t=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),e=U;K.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,t,e)}static baseUrl(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.metadata_baseUrl(n);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}static bond_public(){const t=K.metadata_bond_public();return _.__wrap(t)}static bond_validator(){const t=K.metadata_bond_validator();return _.__wrap(t)}static claim_unbond_public(){const t=K.metadata_claim_unbond_public();return _.__wrap(t)}static fee_private(){const t=K.metadata_fee_private();return _.__wrap(t)}static fee_public(){const t=K.metadata_fee_public();return _.__wrap(t)}static inclusion(){const t=K.metadata_inclusion();return _.__wrap(t)}static join(){const t=K.metadata_join();return _.__wrap(t)}static set_validator_state(){const t=K.metadata_set_validator_state();return _.__wrap(t)}static split(){const t=K.metadata_split();return _.__wrap(t)}static transfer_private(){const t=K.metadata_transfer_private();return _.__wrap(t)}static transfer_private_to_public(){const t=K.metadata_transfer_private_to_public();return _.__wrap(t)}static transfer_public(){const t=K.metadata_transfer_public();return _.__wrap(t)}static transfer_public_as_signer(){const t=K.metadata_transfer_public_as_signer();return _.__wrap(t)}static transfer_public_to_private(){const t=K.metadata_transfer_public_to_private();return _.__wrap(t)}static unbond_public(){const t=K.metadata_unbond_public();return _.__wrap(t)}};const r_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_offlinequery_free(_>>>0)));let n_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,r_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,r_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_offlinequery_free(_)}constructor(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U;K.offlinequery_new(r,n,i);var t=b()[r/4+0],e=b()[r/4+1];if(b()[r/4+2])throw a(e);return this.__wbg_ptr=t>>>0,this}finally{K.__wbindgen_add_to_stack_pointer(16)}}addStatePath(_,t){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U,o=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),s=U;K.offlinequery_addStatePath(r,this.__wbg_ptr,n,i,o,s);var e=b()[r/4+0];if(b()[r/4+1])throw a(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.offlinequery_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.offlinequery_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}};const i_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_privatekey_free(_>>>0)));let o_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,i_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,i_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_privatekey_free(_)}constructor(){const _=K.privatekey_new();return this.__wbg_ptr=_>>>0,this}static from_seed_unchecked(t){const e=y(t,K.__wbindgen_malloc),r=U,n=K.privatekey_from_seed_unchecked(e,r);return _.__wrap(n)}static from_string(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.privatekey_from_string(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}to_string(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.privatekey_to_string(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}to_view_key(){const _=K.privatekey_to_view_key(this.__wbg_ptr);return V_.__wrap(_)}to_address(){const _=K.privatekey_to_address(this.__wbg_ptr);return J.__wrap(_)}sign(_){const t=y(_,K.__wbindgen_malloc),e=U,r=K.privatekey_sign(this.__wbg_ptr,t,e);return h_.__wrap(r)}static newEncrypted(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U;K.privatekey_newEncrypted(r,n,i);var t=b()[r/4+0],e=b()[r/4+1];if(b()[r/4+2])throw a(e);return s_.__wrap(t)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U;K.privatekey_toCiphertext(r,this.__wbg_ptr,n,i);var t=b()[r/4+0],e=b()[r/4+1];if(b()[r/4+2])throw a(e);return s_.__wrap(t)}finally{K.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,e){try{const i=K.__wbindgen_add_to_stack_pointer(-16);p(t,s_);const o=w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),s=U;K.privatekey_fromPrivateKeyCiphertext(i,t.__wbg_ptr,o,s);var r=b()[i/4+0],n=b()[i/4+1];if(b()[i/4+2])throw a(n);return _.__wrap(r)}finally{K.__wbindgen_add_to_stack_pointer(16)}}};const a_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_privatekeyciphertext_free(_>>>0)));let s_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,a_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,a_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_privatekeyciphertext_free(_)}static encryptPrivateKey(t,e){try{const i=K.__wbindgen_add_to_stack_pointer(-16);p(t,o_);const o=w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),s=U;K.privatekey_toCiphertext(i,t.__wbg_ptr,o,s);var r=b()[i/4+0],n=b()[i/4+1];if(b()[i/4+2])throw a(n);return _.__wrap(r)}finally{K.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U;K.privatekeyciphertext_decryptToPrivateKey(r,this.__wbg_ptr,n,i);var t=b()[r/4+0],e=b()[r/4+1];if(b()[r/4+2])throw a(e);return o_.__wrap(t)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.privatekeyciphertext_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.privatekeyciphertext_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}};const c_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_program_free(_>>>0)));let g_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,c_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,c_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_program_free(_)}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.program_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.program_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}hasFunction(_){const t=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),e=U;return 0!==K.program_hasFunction(this.__wbg_ptr,t,e)}getFunctions(){return a(K.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U;K.program_getFunctionInputs(r,this.__wbg_ptr,n,i);var t=b()[r/4+0],e=b()[r/4+1];if(b()[r/4+2])throw a(e);return a(t)}finally{K.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const e=K.__wbindgen_add_to_stack_pointer(-16);K.program_getMappings(e,this.__wbg_ptr);var _=b()[e/4+0],t=b()[e/4+1];if(b()[e/4+2])throw a(t);return a(_)}finally{K.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U;K.program_getRecordMembers(r,this.__wbg_ptr,n,i);var t=b()[r/4+0],e=b()[r/4+1];if(b()[r/4+2])throw a(e);return a(t)}finally{K.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U;K.program_getStructMembers(r,this.__wbg_ptr,n,i);var t=b()[r/4+0],e=b()[r/4+1];if(b()[r/4+2])throw a(e);return a(t)}finally{K.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=K.program_getCreditsProgram();return _.__wrap(t)}id(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.program_id(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}address(){try{const e=K.__wbindgen_add_to_stack_pointer(-16);K.program_address(e,this.__wbg_ptr);var _=b()[e/4+0],t=b()[e/4+1];if(b()[e/4+2])throw a(t);return J.__wrap(_)}finally{K.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){p(t,_);return 0!==K.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return a(K.program_getImports(this.__wbg_ptr))}};const w_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_programmanager_free(_>>>0)));let d_=class{__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,w_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_programmanager_free(_)}static buildDeploymentTransaction(_,t,e,r,n,i,o,s,c){p(_,o_);const b=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),l=U;let u=0;d(r)||(p(r,y_),u=r.__destroy_into_raw());var f=d(n)?0:w(n,K.__wbindgen_malloc,K.__wbindgen_realloc),y=U;let m=0;d(o)||(p(o,l_),m=o.__destroy_into_raw());let h=0;d(s)||(p(s,S_),h=s.__destroy_into_raw());let v=0;d(c)||(p(c,n_),v=c.__destroy_into_raw());return a(K.programmanager_buildDeploymentTransaction(_.__wbg_ptr,b,l,e,u,f,y,d(i)?0:g(i),m,h,v))}static estimateDeploymentFee(_,t){const e=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),r=U;return a(K.programmanager_estimateDeploymentFee(e,r,d(t)?0:g(t)))}static estimateProgramNameCost(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16),n=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),i=U;K.programmanager_estimateProgramNameCost(r,n,i);var t=h()[r/8+0],e=b()[r/4+2];if(b()[r/4+3])throw a(e);return BigInt.asUintN(64,t)}finally{K.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(_,t,e,r,n,i,o,s,c,b,l){p(_,o_);const u=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),f=U,y=w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),m=U;let h=0;d(s)||(p(s,l_),h=s.__destroy_into_raw());let v=0;d(c)||(p(c,S_),v=c.__destroy_into_raw());var k=d(b)?0:w(b,K.__wbindgen_malloc,K.__wbindgen_realloc),P=U;let S=0;d(l)||(p(l,n_),S=l.__destroy_into_raw());return a(K.programmanager_executeFunctionOffline(_.__wbg_ptr,u,f,y,m,g(r),n,i,d(o)?0:g(o),h,v,k,P,S))}static buildExecutionTransaction(_,t,e,r,n,i,o,s,c,b,l,u,f){p(_,o_);const y=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),m=U,h=w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),v=U;let k=0;d(i)||(p(i,y_),k=i.__destroy_into_raw());var P=d(o)?0:w(o,K.__wbindgen_malloc,K.__wbindgen_realloc),S=U;let x=0;d(c)||(p(c,l_),x=c.__destroy_into_raw());let V=0;d(b)||(p(b,S_),V=b.__destroy_into_raw());let F=0;d(l)||(p(l,l_),F=l.__destroy_into_raw());let T=0;d(u)||(p(u,S_),T=u.__destroy_into_raw());let R=0;d(f)||(p(f,n_),R=f.__destroy_into_raw());return a(K.programmanager_buildExecutionTransaction(_.__wbg_ptr,y,m,h,v,g(r),n,k,P,S,d(s)?0:g(s),x,V,F,T,R))}static estimateExecutionFee(_,t,e,r,n,i,o,s,c){p(_,o_);const b=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),l=U,u=w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),f=U;var y=d(n)?0:w(n,K.__wbindgen_malloc,K.__wbindgen_realloc),m=U;let h=0;d(o)||(p(o,l_),h=o.__destroy_into_raw());let v=0;d(s)||(p(s,S_),v=s.__destroy_into_raw());let k=0;d(c)||(p(c,n_),k=c.__destroy_into_raw());return a(K.programmanager_estimateExecutionFee(_.__wbg_ptr,b,l,u,f,g(r),y,m,d(i)?0:g(i),h,v,k))}static estimateFinalizeFee(_,t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U,s=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),c=U;K.programmanager_estimateFinalizeFee(n,i,o,s,c);var e=h()[n/8+0],r=b()[n/4+2];if(b()[n/4+3])throw a(r);return BigInt.asUintN(64,e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(_,t,e,r,n,i,o,s,c,g,b){p(_,o_),p(t,y_);var l=t.__destroy_into_raw();p(e,y_);var u=e.__destroy_into_raw();let f=0;d(n)||(p(n,y_),f=n.__destroy_into_raw());var y=d(i)?0:w(i,K.__wbindgen_malloc,K.__wbindgen_realloc),m=U;let h=0;d(o)||(p(o,l_),h=o.__destroy_into_raw());let v=0;d(s)||(p(s,S_),v=s.__destroy_into_raw());let k=0;d(c)||(p(c,l_),k=c.__destroy_into_raw());let P=0;d(g)||(p(g,S_),P=g.__destroy_into_raw());let S=0;d(b)||(p(b,n_),S=b.__destroy_into_raw());return a(K.programmanager_buildJoinTransaction(_.__wbg_ptr,l,u,r,f,y,m,h,v,k,P,S))}static buildSplitTransaction(_,t,e,r,n,i,o){p(_,o_),p(e,y_);var s=e.__destroy_into_raw(),c=d(r)?0:w(r,K.__wbindgen_malloc,K.__wbindgen_realloc),g=U;let b=0;d(n)||(p(n,l_),b=n.__destroy_into_raw());let l=0;d(i)||(p(i,S_),l=i.__destroy_into_raw());let u=0;d(o)||(p(o,n_),u=o.__destroy_into_raw());return a(K.programmanager_buildSplitTransaction(_.__wbg_ptr,t,s,c,g,b,l,u))}static buildTransferTransaction(_,t,e,r,n,i,o,s,c,g,b,l,u){p(_,o_);const f=w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),y=U,m=w(r,K.__wbindgen_malloc,K.__wbindgen_realloc),h=U;let v=0;d(n)||(p(n,y_),v=n.__destroy_into_raw());let k=0;d(o)||(p(o,y_),k=o.__destroy_into_raw());var P=d(s)?0:w(s,K.__wbindgen_malloc,K.__wbindgen_realloc),S=U;let x=0;d(c)||(p(c,l_),x=c.__destroy_into_raw());let V=0;d(g)||(p(g,S_),V=g.__destroy_into_raw());let F=0;d(b)||(p(b,l_),F=b.__destroy_into_raw());let T=0;d(l)||(p(l,S_),T=l.__destroy_into_raw());let R=0;d(u)||(p(u,n_),R=u.__destroy_into_raw());return a(K.programmanager_buildTransferTransaction(_.__wbg_ptr,t,f,y,m,h,v,i,k,P,S,x,V,F,T,R))}static synthesizeKeyPair(_,t,e,r,n){p(_,o_);const i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U,s=w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),c=U;return a(K.programmanager_synthesizeKeyPair(_.__wbg_ptr,i,o,s,c,g(r),d(n)?0:g(n)))}};const b_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_provingkey_free(_>>>0)));let l_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,b_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,b_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_provingkey_free(_)}isBondPublicProver(){return 0!==K.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==K.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==K.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==K.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==K.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==K.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==K.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==K.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==K.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==K.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==K.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==K.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==K.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==K.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==K.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.provingkey_checksum(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}copy(){const t=K.provingkey_copy(this.__wbg_ptr);return _.__wrap(t)}static fromBytes(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=y(t,K.__wbindgen_malloc),o=U;K.provingkey_fromBytes(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.provingkey_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.provingkey_toBytes(n,this.__wbg_ptr);var _=b()[n/4+0],t=b()[n/4+1],e=b()[n/4+2];if(b()[n/4+3])throw a(e);var r=v(_,t).slice();return K.__wbindgen_free(_,1*t,1),r}finally{K.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.provingkey_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}};const u_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_recordciphertext_free(_>>>0)));let f_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,u_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,u_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_recordciphertext_free(_)}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.recordciphertext_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.recordciphertext_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}decrypt(_){try{const r=K.__wbindgen_add_to_stack_pointer(-16);p(_,V_),K.recordciphertext_decrypt(r,this.__wbg_ptr,_.__wbg_ptr);var t=b()[r/4+0],e=b()[r/4+1];if(b()[r/4+2])throw a(e);return y_.__wrap(t)}finally{K.__wbindgen_add_to_stack_pointer(16)}}isOwner(_){p(_,V_);return 0!==K.recordciphertext_isOwner(this.__wbg_ptr,_.__wbg_ptr)}};const p_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_recordplaintext_free(_>>>0)));let y_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,p_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,p_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_recordplaintext_free(_)}commitment(_,t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U,s=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),c=U;K.recordplaintext_commitment(n,this.__wbg_ptr,i,o,s,c);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return G.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.recordplaintext_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.recordplaintext_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}microcredits(){const _=K.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,_)}nonce(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.recordplaintext_nonce(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}serialNumberString(_,t,e){let r,n;try{const u=K.__wbindgen_add_to_stack_pointer(-16);p(_,o_);const f=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),y=U,m=w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),h=U;K.recordplaintext_serialNumberString(u,this.__wbg_ptr,_.__wbg_ptr,f,y,m,h);var i=b()[u/4+0],o=b()[u/4+1],s=b()[u/4+2],g=b()[u/4+3],d=i,l=o;if(g)throw d=0,l=0,a(s);return r=d,n=l,c(d,l)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(r,n,1)}}};const m_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_signature_free(_>>>0)));let h_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,m_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,m_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_signature_free(_)}static sign(t,e){p(t,o_);const r=y(e,K.__wbindgen_malloc),n=U,i=K.privatekey_sign(t.__wbg_ptr,r,n);return _.__wrap(i)}verify(_,t){p(_,J);const e=y(t,K.__wbindgen_malloc),r=U;return 0!==K.signature_verify(this.__wbg_ptr,_.__wbg_ptr,e,r)}static from_string(t){const e=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),r=U,n=K.signature_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.signature_to_string(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}};const v_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_transaction_free(_>>>0)));let k_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,v_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,v_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_transaction_free(_)}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.transaction_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.transaction_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}transactionId(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.transaction_transactionId(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}transactionType(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.transaction_transactionType(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}};const P_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_verifyingkey_free(_>>>0)));let S_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,P_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,P_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_verifyingkey_free(_)}static bondPublicVerifier(){const t=K.verifyingkey_bondPublicVerifier();return _.__wrap(t)}static bondValidatorVerifier(){const t=K.verifyingkey_bondValidatorVerifier();return _.__wrap(t)}static claimUnbondPublicVerifier(){const t=K.verifyingkey_claimUnbondPublicVerifier();return _.__wrap(t)}static feePrivateVerifier(){const t=K.verifyingkey_feePrivateVerifier();return _.__wrap(t)}static feePublicVerifier(){const t=K.verifyingkey_feePublicVerifier();return _.__wrap(t)}static inclusionVerifier(){const t=K.verifyingkey_inclusionVerifier();return _.__wrap(t)}static joinVerifier(){const t=K.verifyingkey_joinVerifier();return _.__wrap(t)}static setValidatorStateVerifier(){const t=K.verifyingkey_setValidatorStateVerifier();return _.__wrap(t)}static splitVerifier(){const t=K.verifyingkey_splitVerifier();return _.__wrap(t)}static transferPrivateVerifier(){const t=K.verifyingkey_transferPrivateVerifier();return _.__wrap(t)}static transferPrivateToPublicVerifier(){const t=K.verifyingkey_transferPrivateToPublicVerifier();return _.__wrap(t)}static transferPublicVerifier(){const t=K.verifyingkey_transferPublicVerifier();return _.__wrap(t)}static transferPublicAsSignerVerifier(){const t=K.verifyingkey_transferPublicAsSignerVerifier();return _.__wrap(t)}static transferPublicToPrivateVerifier(){const t=K.verifyingkey_transferPublicToPrivateVerifier();return _.__wrap(t)}static unbondPublicVerifier(){const t=K.verifyingkey_unbondPublicVerifier();return _.__wrap(t)}isBondPublicVerifier(){return 0!==K.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==K.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==K.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==K.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==K.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==K.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==K.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==K.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==K.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==K.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==K.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==K.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==K.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==K.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==K.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.verifyingkey_checksum(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}copy(){const t=K.verifyingkey_copy(this.__wbg_ptr);return _.__wrap(t)}static fromBytes(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=y(t,K.__wbindgen_malloc),o=U;K.verifyingkey_fromBytes(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const n=K.__wbindgen_add_to_stack_pointer(-16),i=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;K.verifyingkey_fromString(n,i,o);var e=b()[n/4+0],r=b()[n/4+1];if(b()[n/4+2])throw a(r);return _.__wrap(e)}finally{K.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.verifyingkey_toBytes(n,this.__wbg_ptr);var _=b()[n/4+0],t=b()[n/4+1],e=b()[n/4+2];if(b()[n/4+3])throw a(e);var r=v(_,t).slice();return K.__wbindgen_free(_,1*t,1),r}finally{K.__wbindgen_add_to_stack_pointer(16)}}toString(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.verifyingkey_toString(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}};const x_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((_=>K.__wbg_viewkey_free(_>>>0)));let V_=class _{static __wrap(t){t>>>=0;const e=Object.create(_.prototype);return e.__wbg_ptr=t,x_.register(e,e.__wbg_ptr,e),e}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,x_.unregister(this),_}free(){const _=this.__destroy_into_raw();K.__wbg_viewkey_free(_)}static from_private_key(t){p(t,o_);const e=K.privatekey_to_view_key(t.__wbg_ptr);return _.__wrap(e)}static from_string(t){const e=w(t,K.__wbindgen_malloc,K.__wbindgen_realloc),r=U,n=K.viewkey_from_string(e,r);return _.__wrap(n)}to_string(){let _,t;try{const n=K.__wbindgen_add_to_stack_pointer(-16);K.viewkey_to_string(n,this.__wbg_ptr);var e=b()[n/4+0],r=b()[n/4+1];return _=e,t=r,c(e,r)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(_,t,1)}}to_address(){const _=K.address_from_view_key(this.__wbg_ptr);return J.__wrap(_)}decrypt(_){let t,e;try{const d=K.__wbindgen_add_to_stack_pointer(-16),l=w(_,K.__wbindgen_malloc,K.__wbindgen_realloc),u=U;K.viewkey_decrypt(d,this.__wbg_ptr,l,u);var r=b()[d/4+0],n=b()[d/4+1],i=b()[d/4+2],o=b()[d/4+3],s=r,g=n;if(o)throw s=0,g=0,a(i);return t=s,e=g,c(s,g)}finally{K.__wbindgen_add_to_stack_pointer(16),K.__wbindgen_free(t,e,1)}}};async function V(_,t){if("function"==typeof Response&&_ instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(_,t)}catch(t){if("application/wasm"==_.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await _.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(_,t);return e instanceof WebAssembly.Instance?{instance:e,module:_}:e}}function F(){const _={wbg:{}};return _.wbg.__wbindgen_object_drop_ref=function(_){a(_)},_.wbg.__wbg_new_71801a555ad9f2aa=function(){return S((function(){return g(new XMLHttpRequest)}),arguments)},_.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return S((function(_,t,e){i(_).overrideMimeType(c(t,e))}),arguments)},_.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return S((function(_,t,e,r,n,o){i(_).open(c(t,e),c(r,n),0!==o)}),arguments)},_.wbg.__wbg_send_80d29985093c1ec5=function(){return S((function(_){i(_).send()}),arguments)},_.wbg.__wbg_response_7c2e2759084f7279=function(){return S((function(_){return g(i(_).response)}),arguments)},_.wbg.__wbg_status_d485fb5a478426fb=function(){return S((function(_){return i(_).status}),arguments)},_.wbg.__wbg_new_72fb9a18b5ae2624=function(){return g(new Object)},_.wbg.__wbindgen_string_new=function(_,t){return g(c(_,t))},_.wbg.__wbg_set_1f9b04f170055d33=function(){return S((function(_,t,e){return Reflect.set(i(_),i(t),i(e))}),arguments)},_.wbg.__wbg_new_ab6fd82b10560829=function(){return S((function(){return g(new Headers)}),arguments)},_.wbg.__wbindgen_object_clone_ref=function(_){return g(i(_))},_.wbg.__wbg_new_0d76b0581eca6298=function(){return S((function(){return g(new AbortController)}),arguments)},_.wbg.__wbg_signal_a61f78a3478fd9bc=function(_){return g(i(_).signal)},_.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return S((function(_,t,e,r,n){i(_).append(c(t,e),c(r,n))}),arguments)},_.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(_){let t;try{t=i(_)instanceof Response}catch(_){t=!1}return t},_.wbg.__wbg_status_61a01141acd3cf74=function(_){return i(_).status},_.wbg.__wbg_url_5f6dc4009ac5f99d=function(_,t){const e=w(i(t).url,K.__wbindgen_malloc,K.__wbindgen_realloc),r=U;b()[_/4+1]=r,b()[_/4+0]=e},_.wbg.__wbg_headers_9620bfada380764a=function(_){return g(i(_).headers)},_.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return g(Symbol.iterator)},_.wbg.__wbg_get_e3c254076557e348=function(){return S((function(_,t){return g(Reflect.get(i(_),i(t)))}),arguments)},_.wbg.__wbindgen_is_function=function(_){return"function"==typeof i(_)},_.wbg.__wbg_call_27c0f87801dedf93=function(){return S((function(_,t){return g(i(_).call(i(t)))}),arguments)},_.wbg.__wbindgen_is_object=function(_){const t=i(_);return"object"==typeof t&&null!==t},_.wbg.__wbg_next_40fc327bfc8770e6=function(_){return g(i(_).next)},_.wbg.__wbg_next_196c84450b364254=function(){return S((function(_){return g(i(_).next())}),arguments)},_.wbg.__wbg_done_298b57d23c0fc80c=function(_){return i(_).done},_.wbg.__wbg_value_d93c65011f51a456=function(_){return g(i(_).value)},_.wbg.__wbg_abort_2aa7521d5690750e=function(_){i(_).abort()},_.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return S((function(_){return g(JSON.stringify(i(_)))}),arguments)},_.wbg.__wbindgen_string_get=function(_,t){const e=i(t),r="string"==typeof e?e:void 0;var n=d(r)?0:w(r,K.__wbindgen_malloc,K.__wbindgen_realloc),o=U;b()[_/4+1]=o,b()[_/4+0]=n},_.wbg.__wbg_log_0159ca40cddf5b15=function(_,t){console.log(c(_,t))},_.wbg.__wbindgen_bigint_from_u64=function(_){return g(BigInt.asUintN(64,_))},_.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return S((function(_,t,e){return g(i(_).call(i(t),i(e)))}),arguments)},_.wbg.__wbg_transaction_new=function(_){return g(k_.__wrap(_))},_.wbg.__wbg_keypair_new=function(_){return g(__.__wrap(_))},_.wbg.__wbindgen_module=function(){return g(A.__wbindgen_wasm_module)},_.wbg.__wbindgen_memory=function(){return g(K.memory)},_.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a=function(_,t,e,r){return g(n(i(_),i(t),i(e),r>>>0))},_.wbg.__wbg_executionresponse_new=function(_){return g(X.__wrap(_))},_.wbg.__wbg_newwithlength_66ae46612e7f0234=function(_){return g(new Array(_>>>0))},_.wbg.__wbg_set_d4638f722068f043=function(_,t,e){i(_)[t>>>0]=a(e)},_.wbg.__wbindgen_cb_drop=function(_){const t=a(_).original;if(1==t.cnt--)return t.a=0,!0;return!1},_.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return g(new Array)},_.wbg.__wbg_push_a5b05aedc7234f9f=function(_,t){return i(_).push(i(t))},_.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return S((function(_){return g(i(_).arrayBuffer())}),arguments)},_.wbg.__wbg_new_63b92bc8671ed464=function(_){return g(new Uint8Array(i(_)))},_.wbg.__wbg_length_c20a40f15020d68a=function(_){return i(_).length},_.wbg.__wbg_new_81740750da40724f=function(_,t){try{var e={a:_,b:t};const r=new Promise(((_,t)=>{const r=e.a;e.a=0;try{return x(r,e.b,_,t)}finally{e.a=r}}));return g(r)}finally{e.a=e.b=0}},_.wbg.__wbindgen_number_new=function(_){return g(_)},_.wbg.__wbg_new_abda76e883ba8a5f=function(){return g(new Error)},_.wbg.__wbg_stack_658279fe44541cf6=function(_,t){const e=w(i(t).stack,K.__wbindgen_malloc,K.__wbindgen_realloc),r=U;b()[_/4+1]=r,b()[_/4+0]=e},_.wbg.__wbg_error_f851667af71bcfc6=function(_,t){let e,r;try{e=_,r=t,console.error(c(_,t))}finally{K.__wbindgen_free(e,r,1)}},_.wbg.__wbg_buffer_12d079cc21e14bdb=function(_){return g(i(_).buffer)},_.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(_,t,e){return g(new Uint8Array(i(_),t>>>0,e>>>0))},_.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return S((function(_,t){i(_).randomFillSync(a(t))}),arguments)},_.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(_,t,e){return g(i(_).subarray(t>>>0,e>>>0))},_.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return S((function(_,t){i(_).getRandomValues(i(t))}),arguments)},_.wbg.__wbg_set_a47bac70306a19a7=function(_,t,e){i(_).set(i(t),e>>>0)},_.wbg.__wbg_crypto_1d1f22824a6a080c=function(_){return g(i(_).crypto)},_.wbg.__wbg_process_4a72847cc503995b=function(_){return g(i(_).process)},_.wbg.__wbg_versions_f686565e586dd935=function(_){return g(i(_).versions)},_.wbg.__wbg_node_104a2ff8d6ea03a2=function(_){return g(i(_).node)},_.wbg.__wbindgen_is_string=function(_){return"string"==typeof i(_)},_.wbg.__wbg_require_cca90b1a94a0255b=function(){return S((function(){return g(module.require)}),arguments)},_.wbg.__wbg_msCrypto_eb05e62b530a1508=function(_){return g(i(_).msCrypto)},_.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(_){return g(new Uint8Array(_>>>0))},_.wbg.__wbg_length_cd7af8117672b8b8=function(_){return i(_).length},_.wbg.__wbg_get_bd8e338fbd5f5cc8=function(_,t){return g(i(_)[t>>>0])},_.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return S((function(){return g(self.self)}),arguments)},_.wbg.__wbg_window_c6fb939a7f436783=function(){return S((function(){return g(window.window)}),arguments)},_.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return S((function(){return g(globalThis.globalThis)}),arguments)},_.wbg.__wbg_global_207b558942527489=function(){return S((function(){return g(global.global)}),arguments)},_.wbg.__wbindgen_is_undefined=function(_){return void 0===i(_)},_.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(_,t){return g(new Function(c(_,t)))},_.wbg.__wbg_has_0af94d20077affa2=function(){return S((function(_,t){return Reflect.has(i(_),i(t))}),arguments)},_.wbg.__wbg_fetch_bc7c8e27076a5c84=function(_){return g(fetch(i(_)))},_.wbg.__wbg_fetch_921fad6ef9e883dd=function(_,t){return g(i(_).fetch(i(t)))},_.wbg.__wbindgen_debug_string=function(_,t){const e=w(l(i(t)),K.__wbindgen_malloc,K.__wbindgen_realloc),r=U;b()[_/4+1]=r,b()[_/4+0]=e},_.wbg.__wbindgen_throw=function(_,t){throw new Error(c(_,t))},_.wbg.__wbindgen_rethrow=function(_){throw a(_)},_.wbg.__wbg_then_a73caa9a87991566=function(_,t,e){return g(i(_).then(i(t),i(e)))},_.wbg.__wbg_then_0c86a60e8fcfe9f6=function(_,t){return g(i(_).then(i(t)))},_.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(_){queueMicrotask(i(_))},_.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(_){return g(i(_).queueMicrotask)},_.wbg.__wbg_resolve_b0083a7967828ec8=function(_){return g(Promise.resolve(i(_)))},_.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return g(Atomics.waitAsync)},_.wbg.__wbg_new_8cccba86b0f574cb=function(_){return g(new Int32Array(i(_)))},_.wbg.__wbg_waitAsync_46d5c36955b71a79=function(_,t,e){return g(Atomics.waitAsync(i(_),t,e))},_.wbg.__wbg_async_19c0400d97cc72fe=function(_){return i(_).async},_.wbg.__wbg_value_571d60108110e917=function(_){return g(i(_).value)},_.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(_){const t=w("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),K.__wbindgen_malloc,K.__wbindgen_realloc),e=U;b()[_/4+1]=e,b()[_/4+0]=t},_.wbg.__wbg_new_d1187ae36d662ef9=function(){return S((function(_,t){return g(new Worker(c(_,t)))}),arguments)},_.wbg.__wbg_setonmessage_503809e5bb51bd33=function(_,t){i(_).onmessage=i(t)},_.wbg.__wbg_of_6a70eed8d41f469c=function(_,t,e){return g(Array.of(i(_),i(t),i(e)))},_.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return S((function(_,t){i(_).postMessage(i(t))}),arguments)},_.wbg.__wbg_data_3ce7c145ca4fbcdc=function(_){return g(i(_).data)},_.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return S((function(_,t,e){return g(new Request(c(_,t),i(e)))}),arguments)},_.wbg.__wbg_responseText_c67ed2d48db10769=function(){return S((function(_,t){const e=i(t).responseText;var r=d(e)?0:w(e,K.__wbindgen_malloc,K.__wbindgen_realloc),n=U;b()[_/4+1]=n,b()[_/4+0]=r}),arguments)},_.wbg.__wbindgen_closure_wrapper5837=function(_,t,e){return g(u(_,t,538,f))},_.wbg.__wbindgen_closure_wrapper5862=function(_,t,e){return g(u(_,t,538,f))},_}function T(_,t){_.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function R(_,t){return K=_.exports,A.__wbindgen_wasm_module=t,N=null,W=null,B=null,K.__wbindgen_start(),K}function z(_,t){if(void 0!==K)return K;const e=F();T(e,t),_ instanceof WebAssembly.Module||(_=new WebAssembly.Module(_));return R(new WebAssembly.Instance(_,e),_)}async function A(_,t){if(void 0!==K)return K;const e=F();("string"==typeof _||"function"==typeof Request&&_ instanceof Request||"function"==typeof URL&&_ instanceof URL)&&(_=fetch(_)),T(e,t);const{instance:r,module:n}=await V(await _,e);return R(r,n)}var O=Object.freeze({__proto__:null,Address:J,Execution:H,ExecutionResponse:X,Field:G,KeyPair:__,Metadata:e_,OfflineQuery:n_,PrivateKey:o_,PrivateKeyCiphertext:s_,Program:g_,ProgramManager:d_,ProvingKey:l_,RecordCiphertext:f_,RecordPlaintext:y_,Signature:h_,Transaction:k_,VerifyingKey:S_,ViewKey:V_,default:A,initSync:z,initThreadPool:P,runRayonThread:k,verifyFunctionExecution:m});const F_="assets/aleo_wasm.wasm";const{initThreadPool:T_,Address:R_,Execution:z_,ExecutionResponse:A_,Field:O_,Metadata:j_,OfflineQuery:K_,Private:C_,PrivateKey:E_,PrivateKeyCiphertext:M_,Program:B_,ProvingKey:U_,RecordCiphertext:I_,RecordPlaintext:q_,ProgramManager:W_,Signature:$_,Transaction:N_,ViewKey:D_,VerifyingKey:J_,verifyFunctionExecution:L_}=await(async(_={})=>{let{importHook:t,serverPath:e,initializeHook:r}=_,n=F_;return null!=e&&(n=e+/[^\/\\]*$/.exec(n)[0]),null!=t&&(n=t(n)),null!=r?await r(A,n):await A(n),O})({importHook:()=>new URL(e(5934),e.b)});async function j(_){null==_&&(_=navigator.hardwareConcurrency),console.info(`Spawning ${_} threads`),await T_(new URL(e(2583),e.b),_)}r()}catch(H_){r(H_)}}),1)}}]); -//# sourceMappingURL=933.bundle.js.map \ No newline at end of file diff --git a/933.bundle.js.map b/933.bundle.js.map deleted file mode 100644 index 8a1d6d794..000000000 --- a/933.bundle.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"933.bundle.js","mappings":"wOAAA,SAASA,EAAYC,EAAKC,EAAQC,EAAQC,GAClC,OAAO,IAAIC,SAASC,IAChB,MAAMC,EAAS,IAAIC,OAAOP,EAAK,CAC3BQ,KAAM,WAGVF,EAAOG,iBAAiB,WAAYC,IAGhCC,YAAW,KACPN,EAAQC,GAIJA,EAAOM,OACPN,EAAOM,OAC/B,GACmB,EAAE,GACN,CACCC,SAAS,EACTC,MAAM,IAGVR,EAAOS,YAAY,CACfd,SACAC,SACAC,WACF,GAEd,CAEA,IAAIa,E,qHAEJ,MAAMC,EAAO,IAAIC,MAAM,KAAKC,UAAKC,GAIjC,SAASC,EAAUC,GAAO,OAAOL,EAAKK,EAAK,CAF3CL,EAAKM,UAAKH,EAAW,MAAM,GAAM,GAIjC,IAAII,EAAYP,EAAKQ,OAErB,SAASC,EAAWJ,GACZA,EAAM,MACVL,EAAKK,GAAOE,EACZA,EAAYF,EAChB,CAEA,SAASK,EAAWL,GAChB,MAAMM,EAAMP,EAAUC,GAEtB,OADAI,EAAWJ,GACJM,CACX,CAEA,MAAMC,EAA4C,oBAAhBC,YAA8B,IAAIA,YAAY,QAAS,CAAEC,WAAW,EAAMC,OAAO,IAAU,CAAEC,OAAQA,KAAQ,MAAMC,MAAM,4BAA4B,GAE5J,oBAAhBJ,aAA+BD,EAAkBI,SAC5D,IAAIE,EAAqB,KAEzB,SAASC,IAIL,OAH2B,OAAvBD,GAA+BA,EAAmBE,SAAWrB,EAAKd,OAAOm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qBAGxBnM,QAAQoM,KAAM,YAAWH,mBAEnBR,GAAmB,IAAIT,IAAI,aAA+BiB,EACpE,C","sources":["webpack://aleo-website/wasm.js","webpack://aleo-website/../js/index.js"],"sourcesContent":["function spawnWorker(url, module, memory, address) {\n return new Promise((resolve) => {\n const worker = new Worker(url, {\n type: \"module\",\n });\n\n worker.addEventListener(\"message\", (event) => {\n // This is needed in Node to wait one extra tick, so that way\n // the Worker can fully initialize before we return.\n setTimeout(() => {\n resolve(worker);\n\n // When running in Node, this allows the process to exit\n // even though the Worker is still running.\n if (worker.unref) {\n worker.unref();\n }\n }, 0);\n }, {\n capture: true,\n once: true,\n });\n\n worker.postMessage({\n module,\n memory,\n address,\n });\n });\n }\n\nlet wasm;\n\nconst heap = new Array(128).fill(undefined);\n\nheap.push(undefined, null, true, false);\n\nfunction getObject(idx) { return heap[idx]; }\n\nlet heap_next = heap.length;\n\nfunction dropObject(idx) {\n if (idx < 132) return;\n heap[idx] = heap_next;\n heap_next = idx;\n}\n\nfunction takeObject(idx) {\n const ret = getObject(idx);\n dropObject(idx);\n return ret;\n}\n\nconst cachedTextDecoder = (typeof TextDecoder !== 'undefined' ? new TextDecoder('utf-8', { ignoreBOM: true, fatal: true }) : { decode: () => { throw Error('TextDecoder not available') } } );\n\nif (typeof TextDecoder !== 'undefined') { cachedTextDecoder.decode(); }\nlet cachedUint8Memory0 = null;\n\nfunction getUint8Memory0() {\n if (cachedUint8Memory0 === null || cachedUint8Memory0.buffer !== wasm.memory.buffer) {\n cachedUint8Memory0 = new Uint8Array(wasm.memory.buffer);\n }\n return cachedUint8Memory0;\n}\n\nfunction getStringFromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return cachedTextDecoder.decode(getUint8Memory0().slice(ptr, ptr + len));\n}\n\nfunction addHeapObject(obj) {\n if (heap_next === heap.length) heap.push(heap.length + 1);\n const idx = heap_next;\n heap_next = heap[idx];\n\n heap[idx] = obj;\n return idx;\n}\n\nlet WASM_VECTOR_LEN = 0;\n\nconst cachedTextEncoder = (typeof TextEncoder !== 'undefined' ? new TextEncoder('utf-8') : { encode: () => { throw Error('TextEncoder not available') } } );\n\nconst encodeString = function (arg, view) {\n const buf = cachedTextEncoder.encode(arg);\n view.set(buf);\n return {\n read: arg.length,\n written: buf.length\n };\n};\n\nfunction passStringToWasm0(arg, malloc, realloc) {\n\n if (realloc === undefined) {\n const buf = cachedTextEncoder.encode(arg);\n const ptr = malloc(buf.length, 1) >>> 0;\n getUint8Memory0().subarray(ptr, ptr + buf.length).set(buf);\n WASM_VECTOR_LEN = buf.length;\n return ptr;\n }\n\n let len = arg.length;\n let ptr = malloc(len, 1) >>> 0;\n\n const mem = getUint8Memory0();\n\n let offset = 0;\n\n for (; offset < len; offset++) {\n const code = arg.charCodeAt(offset);\n if (code > 0x7F) break;\n mem[ptr + offset] = code;\n }\n\n if (offset !== len) {\n if (offset !== 0) {\n arg = arg.slice(offset);\n }\n ptr = realloc(ptr, len, len = offset + arg.length * 3, 1) >>> 0;\n const view = getUint8Memory0().subarray(ptr + offset, ptr + len);\n const ret = encodeString(arg, view);\n\n offset += ret.written;\n ptr = realloc(ptr, len, offset, 1) >>> 0;\n }\n\n WASM_VECTOR_LEN = offset;\n return ptr;\n}\n\nfunction isLikeNone(x) {\n return x === undefined || x === null;\n}\n\nlet cachedInt32Memory0 = null;\n\nfunction getInt32Memory0() {\n if (cachedInt32Memory0 === null || cachedInt32Memory0.buffer !== wasm.memory.buffer) {\n cachedInt32Memory0 = new Int32Array(wasm.memory.buffer);\n }\n return cachedInt32Memory0;\n}\n\nfunction debugString(val) {\n // primitive types\n const type = typeof val;\n if (type == 'number' || type == 'boolean' || val == null) {\n return `${val}`;\n }\n if (type == 'string') {\n return `\"${val}\"`;\n }\n if (type == 'symbol') {\n const description = val.description;\n if (description == null) {\n return 'Symbol';\n } else {\n return `Symbol(${description})`;\n }\n }\n if (type == 'function') {\n const name = val.name;\n if (typeof name == 'string' && name.length > 0) {\n return `Function(${name})`;\n } else {\n return 'Function';\n }\n }\n // objects\n if (Array.isArray(val)) {\n const length = val.length;\n let debug = '[';\n if (length > 0) {\n debug += debugString(val[0]);\n }\n for(let i = 1; i < length; i++) {\n debug += ', ' + debugString(val[i]);\n }\n debug += ']';\n return debug;\n }\n // Test for built-in\n const builtInMatches = /\\[object ([^\\]]+)\\]/.exec(toString.call(val));\n let className;\n if (builtInMatches.length > 1) {\n className = builtInMatches[1];\n } else {\n // Failed to match the standard '[object ClassName]'\n return toString.call(val);\n }\n if (className == 'Object') {\n // we're a user defined class or Object\n // JSON.stringify avoids problems with cycles, and is generally much\n // easier than looping through ownProperties of `val`.\n try {\n return 'Object(' + JSON.stringify(val) + ')';\n } catch (_) {\n return 'Object';\n }\n }\n // errors\n if (val instanceof Error) {\n return `${val.name}: ${val.message}\\n${val.stack}`;\n }\n // TODO we could test for more things here, like `Set`s and `Map`s.\n return className;\n}\n\nconst CLOSURE_DTORS = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(state => {\n wasm.__wbindgen_export_3.get(state.dtor)(state.a, state.b);\n});\n\nfunction makeMutClosure(arg0, arg1, dtor, f) {\n const state = { a: arg0, b: arg1, cnt: 1, dtor };\n const real = (...args) => {\n // First up with a closure we increment the internal reference\n // count. This ensures that the Rust closure environment won't\n // be deallocated while we're invoking it.\n state.cnt++;\n const a = state.a;\n state.a = 0;\n try {\n return f(a, state.b, ...args);\n } finally {\n if (--state.cnt === 0) {\n wasm.__wbindgen_export_3.get(state.dtor)(a, state.b);\n CLOSURE_DTORS.unregister(state);\n } else {\n state.a = a;\n }\n }\n };\n real.original = state;\n CLOSURE_DTORS.register(real, state, state);\n return real;\n}\nfunction __wbg_adapter_34(arg0, arg1, arg2) {\n wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3(arg0, arg1, addHeapObject(arg2));\n}\n\nfunction _assertClass(instance, klass) {\n if (!(instance instanceof klass)) {\n throw new Error(`expected instance of ${klass.name}`);\n }\n return instance.ptr;\n}\n\nfunction passArray8ToWasm0(arg, malloc) {\n const ptr = malloc(arg.length * 1, 1) >>> 0;\n getUint8Memory0().set(arg, ptr / 1);\n WASM_VECTOR_LEN = arg.length;\n return ptr;\n}\n/**\n* Verify an execution with a single function and a single transition. Executions with multiple\n* transitions or functions will fail to verify. Also, this does not verify that the state root of\n* the execution is included in the Aleo Network ledger.\n*\n* @param {Execution} execution The function execution to verify\n* @param {VerifyingKey} verifying_key The verifying key for the function\n* @param {Program} program The program that the function execution belongs to\n* @param {String} function_id The name of the function that was executed\n* @returns {boolean} True if the execution is valid, false otherwise\n* @param {Execution} execution\n* @param {VerifyingKey} verifying_key\n* @param {Program} program\n* @param {string} function_id\n* @returns {boolean}\n*/\nfunction verifyFunctionExecution(execution, verifying_key, program, function_id) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(execution, Execution);\n _assertClass(verifying_key, VerifyingKey);\n _assertClass(program, Program);\n const ptr0 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyFunctionExecution(retptr, execution.__wbg_ptr, verifying_key.__wbg_ptr, program.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return r0 !== 0;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n}\n\nlet cachedBigInt64Memory0 = null;\n\nfunction getBigInt64Memory0() {\n if (cachedBigInt64Memory0 === null || cachedBigInt64Memory0.buffer !== wasm.memory.buffer) {\n cachedBigInt64Memory0 = new BigInt64Array(wasm.memory.buffer);\n }\n return cachedBigInt64Memory0;\n}\n\nfunction getArrayU8FromWasm0(ptr, len) {\n ptr = ptr >>> 0;\n return getUint8Memory0().subarray(ptr / 1, ptr / 1 + len);\n}\n/**\n* @param {number} receiver\n*/\nfunction runRayonThread(receiver) {\n wasm.runRayonThread(receiver);\n}\n\n/**\n* @param {URL} url\n* @param {number} num_threads\n* @returns {Promise}\n*/\nfunction initThreadPool(url, num_threads) {\n const ret = wasm.initThreadPool(addHeapObject(url), num_threads);\n return takeObject(ret);\n}\n\nfunction handleError(f, args) {\n try {\n return f.apply(this, args);\n } catch (e) {\n wasm.__wbindgen_exn_store(addHeapObject(e));\n }\n}\nfunction __wbg_adapter_281(arg0, arg1, arg2, arg3) {\n wasm.wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));\n}\n\nconst AddressFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_address_free(ptr >>> 0));\n/**\n* Public address of an Aleo account\n*/\nclass Address {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Address.prototype);\n obj.__wbg_ptr = ptr;\n AddressFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n AddressFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_address_free(ptr);\n }\n /**\n * Derive an Aleo address from a private key\n *\n * @param {PrivateKey} private_key The private key to derive the address from\n * @returns {Address} Address corresponding to the private key\n * @param {PrivateKey} private_key\n * @returns {Address}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.address_from_private_key(private_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Derive an Aleo address from a view key\n *\n * @param {ViewKey} view_key The view key to derive the address from\n * @returns {Address} Address corresponding to the view key\n * @param {ViewKey} view_key\n * @returns {Address}\n */\n static from_view_key(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.address_from_view_key(view_key.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Create an aleo address object from a string representation of an address\n *\n * @param {string} address String representation of an addressm\n * @returns {Address} Address\n * @param {string} address\n * @returns {Address}\n */\n static from_string(address) {\n const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.address_from_string(ptr0, len0);\n return Address.__wrap(ret);\n }\n /**\n * Get a string representation of an Aleo address object\n *\n * @param {Address} Address\n * @returns {string} String representation of the address\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.address_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Verify a signature for a message signed by the address\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {boolean} Boolean representing whether or not the signature is valid\n * @param {Uint8Array} message\n * @param {Signature} signature\n * @returns {boolean}\n */\n verify(message, signature) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n _assertClass(signature, Signature);\n const ret = wasm.address_verify(this.__wbg_ptr, ptr0, len0, signature.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst ExecutionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_execution_free(ptr >>> 0));\n/**\n* Execution of an Aleo program.\n*/\nclass Execution {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Execution.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_execution_free(ptr);\n }\n /**\n * Returns the string representation of the execution.\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.execution_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates an execution object from a string representation of an execution.\n * @param {string} execution\n * @returns {Execution}\n */\n static fromString(execution) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(execution, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.execution_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Execution.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ExecutionResponseFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_executionresponse_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo function execution response\n*\n* This object is returned by the execution of an Aleo function off-chain. It provides methods for\n* retrieving the outputs of the function execution.\n*/\nclass ExecutionResponse {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ExecutionResponse.prototype);\n obj.__wbg_ptr = ptr;\n ExecutionResponseFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ExecutionResponseFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_executionresponse_free(ptr);\n }\n /**\n * Get the outputs of the executed function\n *\n * @returns {Array} Array of strings representing the outputs of the function\n * @returns {Array}\n */\n getOutputs() {\n const ret = wasm.executionresponse_getOutputs(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Returns the execution object if present, null if otherwise.\n *\n * @returns {Execution | undefined} The execution object if present, null if otherwise\n * @returns {Execution | undefined}\n */\n getExecution() {\n const ret = wasm.executionresponse_getExecution(this.__wbg_ptr);\n return ret === 0 ? undefined : Execution.__wrap(ret);\n }\n /**\n * Returns the program keys if present\n * @returns {KeyPair}\n */\n getKeys() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getKeys(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return KeyPair.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the proving_key if the proving key was cached in the Execution response.\n * Note the proving key is removed from the response object after the first call to this\n * function. Subsequent calls will return null.\n *\n * @returns {ProvingKey | undefined} The proving key\n * @returns {ProvingKey | undefined}\n */\n getProvingKey() {\n const ret = wasm.executionresponse_getProvingKey(this.__wbg_ptr);\n return ret === 0 ? undefined : ProvingKey.__wrap(ret);\n }\n /**\n * Returns the verifying_key associated with the program\n *\n * @returns {VerifyingKey} The verifying key\n * @returns {VerifyingKey}\n */\n getVerifyingKey() {\n const ret = wasm.executionresponse_getVerifyingKey(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the function identifier\n * @returns {string}\n */\n getFunctionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.executionresponse_getFunctionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the program\n * @returns {Program}\n */\n getProgram() {\n const ret = wasm.executionresponse_getProgram(this.__wbg_ptr);\n return Program.__wrap(ret);\n }\n}\n\nconst FieldFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_field_free(ptr >>> 0));\n/**\n*/\nclass Field {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Field.prototype);\n obj.__wbg_ptr = ptr;\n FieldFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n FieldFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_field_free(ptr);\n }\n /**\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.field_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} field\n * @returns {Field}\n */\n static fromString(field) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(field, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.field_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst KeyPairFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_keypair_free(ptr >>> 0));\n/**\n* Key pair object containing both the function proving and verifying keys\n*/\nclass KeyPair {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(KeyPair.prototype);\n obj.__wbg_ptr = ptr;\n KeyPairFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n KeyPairFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_keypair_free(ptr);\n }\n /**\n * Create new key pair from proving and verifying keys\n *\n * @param {ProvingKey} proving_key Proving key corresponding to a function in an Aleo program\n * @param {VerifyingKey} verifying_key Verifying key corresponding to a function in an Aleo program\n * @returns {KeyPair} Key pair object containing both the function proving and verifying keys\n * @param {ProvingKey} proving_key\n * @param {VerifyingKey} verifying_key\n */\n constructor(proving_key, verifying_key) {\n _assertClass(proving_key, ProvingKey);\n var ptr0 = proving_key.__destroy_into_raw();\n _assertClass(verifying_key, VerifyingKey);\n var ptr1 = verifying_key.__destroy_into_raw();\n const ret = wasm.keypair_new(ptr0, ptr1);\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get the proving key. This method will remove the proving key from the key pair\n *\n * @returns {ProvingKey | Error}\n * @returns {ProvingKey}\n */\n provingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_provingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the verifying key. This method will remove the verifying key from the key pair\n *\n * @returns {VerifyingKey | Error}\n * @returns {VerifyingKey}\n */\n verifyingKey() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.keypair_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst MetadataFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_metadata_free(ptr >>> 0));\n/**\n*/\nclass Metadata {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Metadata.prototype);\n obj.__wbg_ptr = ptr;\n MetadataFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n MetadataFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_metadata_free(ptr);\n }\n /**\n * @returns {string}\n */\n get name() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_name(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set name(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_name(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get locator() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_locator(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set locator(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_locator(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get prover() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_prover(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set prover(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_prover(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifier() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifier(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifier(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifier(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n get verifyingKey() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.__wbg_get_metadata_verifyingKey(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @param {string} arg0\n */\n set verifyingKey(arg0) {\n const ptr0 = passStringToWasm0(arg0, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.__wbg_set_metadata_verifyingKey(this.__wbg_ptr, ptr0, len0);\n }\n /**\n * @returns {string}\n */\n static baseUrl() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.metadata_baseUrl(retptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * @returns {Metadata}\n */\n static bond_public() {\n const ret = wasm.metadata_bond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static bond_validator() {\n const ret = wasm.metadata_bond_validator();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static claim_unbond_public() {\n const ret = wasm.metadata_claim_unbond_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_private() {\n const ret = wasm.metadata_fee_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static fee_public() {\n const ret = wasm.metadata_fee_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static inclusion() {\n const ret = wasm.metadata_inclusion();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static join() {\n const ret = wasm.metadata_join();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static set_validator_state() {\n const ret = wasm.metadata_set_validator_state();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static split() {\n const ret = wasm.metadata_split();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private() {\n const ret = wasm.metadata_transfer_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_private_to_public() {\n const ret = wasm.metadata_transfer_private_to_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public() {\n const ret = wasm.metadata_transfer_public();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_as_signer() {\n const ret = wasm.metadata_transfer_public_as_signer();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static transfer_public_to_private() {\n const ret = wasm.metadata_transfer_public_to_private();\n return Metadata.__wrap(ret);\n }\n /**\n * @returns {Metadata}\n */\n static unbond_public() {\n const ret = wasm.metadata_unbond_public();\n return Metadata.__wrap(ret);\n }\n}\n\nconst OfflineQueryFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_offlinequery_free(ptr >>> 0));\n/**\n* An offline query object used to insert the global state root and state paths needed to create\n* a valid inclusion proof offline.\n*/\nclass OfflineQuery {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(OfflineQuery.prototype);\n obj.__wbg_ptr = ptr;\n OfflineQueryFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n OfflineQueryFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_offlinequery_free(ptr);\n }\n /**\n * Creates a new offline query object. The state root is required to be passed in as a string\n * @param {string} state_root\n */\n constructor(state_root) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(state_root, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_new(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n this.__wbg_ptr = r0 >>> 0;\n return this;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Add a new state path to the offline query object.\n *\n * @param {string} commitment: The commitment corresponding to a record inpout\n * @param {string} state_path: The state path corresponding to the commitment\n * @param {string} commitment\n * @param {string} state_path\n */\n addStatePath(commitment, state_path) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(commitment, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(state_path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.offlinequery_addStatePath(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n if (r1) {\n throw takeObject(r0);\n }\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a json string representation of the offline query object\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.offlinequery_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create an offline query object from a json string representation\n * @param {string} s\n * @returns {OfflineQuery}\n */\n static fromString(s) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(s, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.offlinequery_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return OfflineQuery.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekey_free(ptr >>> 0));\n/**\n* Private key of an Aleo account\n*/\nclass PrivateKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKey.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekey_free(ptr);\n }\n /**\n * Generate a new private key using a cryptographically secure random number generator\n *\n * @returns {PrivateKey}\n */\n constructor() {\n const ret = wasm.privatekey_new();\n this.__wbg_ptr = ret >>> 0;\n return this;\n }\n /**\n * Get a private key from a series of unchecked bytes\n *\n * @param {Uint8Array} seed Unchecked 32 byte long Uint8Array acting as the seed for the private key\n * @returns {PrivateKey}\n * @param {Uint8Array} seed\n * @returns {PrivateKey}\n */\n static from_seed_unchecked(seed) {\n const ptr0 = passArray8ToWasm0(seed, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_from_seed_unchecked(ptr0, len0);\n return PrivateKey.__wrap(ret);\n }\n /**\n * Get a private key from a string representation of a private key\n *\n * @param {string} seed String representation of a private key\n * @returns {PrivateKey}\n * @param {string} private_key\n * @returns {PrivateKey}\n */\n static from_string(private_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(private_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_from_string(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the private key. This function should be used very carefully\n * as it exposes the private key plaintext\n *\n * @returns {string} String representation of a private key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the view key corresponding to the private key\n *\n * @returns {ViewKey}\n * @returns {ViewKey}\n */\n to_view_key() {\n const ret = wasm.privatekey_to_view_key(this.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get the address corresponding to the private key\n *\n * @returns {Address}\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.privatekey_to_address(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Sign a message with the private key\n *\n * @param {Uint8Array} Byte array representing a message signed by the address\n * @returns {Signature} Signature generated by signing the message with the address\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n sign(message) {\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(this.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a new randomly generated private key ciphertext using a secret. The secret is sensitive\n * and will be needed to decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext | Error} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static newEncrypted(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_newEncrypted(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Encrypt an existing private key with a secret. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKeyCiphertext | Error} Ciphertext representation of the private key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n toCiphertext(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get private key from a private key ciphertext and secret originally used to encrypt it\n *\n * @param {PrivateKeyCiphertext} ciphertext Ciphertext representation of the private key\n * @param {string} secret Secret originally used to encrypt the private key\n * @returns {PrivateKey | Error} Private key\n * @param {PrivateKeyCiphertext} ciphertext\n * @param {string} secret\n * @returns {PrivateKey}\n */\n static fromPrivateKeyCiphertext(ciphertext, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(ciphertext, PrivateKeyCiphertext);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_fromPrivateKeyCiphertext(retptr, ciphertext.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst PrivateKeyCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_privatekeyciphertext_free(ptr >>> 0));\n/**\n* Private Key in ciphertext form\n*/\nclass PrivateKeyCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(PrivateKeyCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n PrivateKeyCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n PrivateKeyCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_privatekeyciphertext_free(ptr);\n }\n /**\n * Encrypt a private key using a secret string. The secret is sensitive and will be needed to\n * decrypt the private key later, so it should be stored securely\n *\n * @param {PrivateKey} private_key Private key to encrypt\n * @param {string} secret Secret to encrypt the private key with\n * @returns {PrivateKeyCiphertext | Error} Private key ciphertext\n * @param {PrivateKey} private_key\n * @param {string} secret\n * @returns {PrivateKeyCiphertext}\n */\n static encryptPrivateKey(private_key, secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekey_toCiphertext(retptr, private_key.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Decrypts a private ciphertext using a secret string. This must be the same secret used to\n * encrypt the private key\n *\n * @param {string} secret Secret used to encrypt the private key\n * @returns {PrivateKey | Error} Private key\n * @param {string} secret\n * @returns {PrivateKey}\n */\n decryptToPrivateKey(secret) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(secret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_decryptToPrivateKey(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the ciphertext string\n *\n * @returns {string} Ciphertext string\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.privatekeyciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Creates a PrivateKeyCiphertext from a string\n *\n * @param {string} ciphertext Ciphertext string\n * @returns {PrivateKeyCiphertext | Error} Private key ciphertext\n * @param {string} ciphertext\n * @returns {PrivateKeyCiphertext}\n */\n static fromString(ciphertext) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.privatekeyciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return PrivateKeyCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n}\n\nconst ProgramFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_program_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo program\n*/\nclass Program {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Program.prototype);\n obj.__wbg_ptr = ptr;\n ProgramFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_program_free(ptr);\n }\n /**\n * Create a program from a program string\n *\n * @param {string} program Aleo program source code\n * @returns {Program | Error} Program object\n * @param {string} program\n * @returns {Program}\n */\n static fromString(program) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Program.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the program\n *\n * @returns {string} String containing the program source code\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Determine if a function is present in the program\n *\n * @param {string} functionName Name of the function to check for\n * @returns {boolean} True if the program is valid, false otherwise\n * @param {string} function_name\n * @returns {boolean}\n */\n hasFunction(function_name) {\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.program_hasFunction(this.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get javascript array of functions names in the program\n *\n * @returns {Array} Array of all function names present in the program\n *\n * @example\n * const expected_functions = [\n * \"mint\",\n * \"transfer_private\",\n * \"transfer_private_to_public\",\n * \"transfer_public\",\n * \"transfer_public_to_private\",\n * \"join\",\n * \"split\",\n * \"fee\"\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_functions = credits_program.getFunctions();\n * console.log(credits_functions === expected_functions); // Output should be \"true\"\n * @returns {Array}\n */\n getFunctions() {\n const ret = wasm.program_getFunctions(this.__wbg_ptr);\n return takeObject(ret);\n }\n /**\n * Get a javascript object representation of the function inputs and types. This can be used\n * to generate a web form to capture user inputs for an execution of a function.\n *\n * @param {string} function_name Name of the function to get inputs for\n * @returns {Array | Error} Array of function inputs\n *\n * @example\n * const expected_inputs = [\n * {\n * type:\"record\",\n * visibility:\"private\",\n * record:\"credits\",\n * members:[\n * {\n * name:\"microcredits\",\n * type:\"u64\",\n * visibility:\"private\"\n * }\n * ],\n * register:\"r0\"\n * },\n * {\n * type:\"address\",\n * visibility:\"private\",\n * register:\"r1\"\n * },\n * {\n * type:\"u64\",\n * visibility:\"private\",\n * register:\"r2\"\n * }\n * ];\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const transfer_function_inputs = credits_program.getFunctionInputs(\"transfer_private\");\n * console.log(transfer_function_inputs === expected_inputs); // Output should be \"true\"\n * @param {string} function_name\n * @returns {Array}\n */\n getFunctionInputs(function_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(function_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getFunctionInputs(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a the list of a program's mappings and the names/types of their keys and values.\n *\n * @returns {Array | Error} - An array of objects representing the mappings in the program\n * @example\n * const expected_mappings = [\n * {\n * name: \"account\",\n * key_name: \"owner\",\n * key_type: \"address\",\n * value_name: \"microcredits\",\n * value_type: \"u64\"\n * }\n * ]\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_mappings = credits_program.getMappings();\n * console.log(credits_mappings === expected_mappings); // Output should be \"true\"\n * @returns {Array}\n */\n getMappings() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_getMappings(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program record and its types\n *\n * @param {string} record_name Name of the record to get members for\n * @returns {Object | Error} Object containing the record name, type, and members\n *\n * @example\n *\n * const expected_record = {\n * type: \"record\",\n * record: \"Credits\",\n * members: [\n * {\n * name: \"owner\",\n * type: \"address\",\n * visibility: \"private\"\n * },\n * {\n * name: \"microcredits\",\n * type: \"u64\",\n * visibility: \"private\"\n * }\n * ];\n * };\n *\n * const credits_program = aleo_wasm.Program.getCreditsProgram();\n * const credits_record = credits_program.getRecordMembers(\"Credits\");\n * console.log(credits_record === expected_record); // Output should be \"true\"\n * @param {string} record_name\n * @returns {object}\n */\n getRecordMembers(record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getRecordMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a javascript object representation of a program struct and its types\n *\n * @param {string} struct_name Name of the struct to get members for\n * @returns {Array | Error} Array containing the struct members\n *\n * @example\n *\n * const STRUCT_PROGRAM = \"program token_issue.aleo;\n *\n * struct token_metadata:\n * network as u32;\n * version as u32;\n *\n * struct token:\n * token_id as u32;\n * metadata as token_metadata;\n *\n * function no_op:\n * input r0 as u64;\n * output r0 as u64;\"\n *\n * const expected_struct_members = [\n * {\n * name: \"token_id\",\n * type: \"u32\",\n * },\n * {\n * name: \"metadata\",\n * type: \"struct\",\n * struct_id: \"token_metadata\",\n * members: [\n * {\n * name: \"network\",\n * type: \"u32\",\n * }\n * {\n * name: \"version\",\n * type: \"u32\",\n * }\n * ]\n * }\n * ];\n *\n * const program = aleo_wasm.Program.fromString(STRUCT_PROGRAM);\n * const struct_members = program.getStructMembers(\"token\");\n * console.log(struct_members === expected_struct_members); // Output should be \"true\"\n * @param {string} struct_name\n * @returns {Array}\n */\n getStructMembers(struct_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(struct_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.program_getStructMembers(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return takeObject(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the credits.aleo program\n *\n * @returns {Program} The credits.aleo program\n * @returns {Program}\n */\n static getCreditsProgram() {\n const ret = wasm.program_getCreditsProgram();\n return Program.__wrap(ret);\n }\n /**\n * Get the id of the program\n *\n * @returns {string} The id of the program\n * @returns {string}\n */\n id() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_id(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get a unique address of the program\n *\n * @returns {Address} The address of the program\n * @returns {Address}\n */\n address() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.program_address(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Address.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determine equality with another program\n *\n * @param {Program} other The other program to compare\n * @returns {boolean} True if the programs are equal, false otherwise\n * @param {Program} other\n * @returns {boolean}\n */\n isEqual(other) {\n _assertClass(other, Program);\n const ret = wasm.program_isEqual(this.__wbg_ptr, other.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get program_imports\n *\n * @returns {Array} The program imports\n *\n * @example\n *\n * const DOUBLE_TEST = \"import multiply_test.aleo;\n *\n * program double_test.aleo;\n *\n * function double_it:\n * input r0 as u32.private;\n * call multiply_test.aleo/multiply 2u32 r0 into r1;\n * output r1 as u32.private;\";\n *\n * const expected_imports = [\n * \"multiply_test.aleo\"\n * ];\n *\n * const program = aleo_wasm.Program.fromString(DOUBLE_TEST_PROGRAM);\n * const imports = program.getImports();\n * console.log(imports === expected_imports); // Output should be \"true\"\n * @returns {Array}\n */\n getImports() {\n const ret = wasm.program_getImports(this.__wbg_ptr);\n return takeObject(ret);\n }\n}\n\nconst ProgramManagerFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_programmanager_free(ptr >>> 0));\n/**\n*/\nclass ProgramManager {\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProgramManagerFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_programmanager_free(ptr);\n }\n /**\n * Deploy an Aleo program\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being deployed\n * @param imports A javascript object holding the source code of any imported programs in the\n * form \\{\"program_name1\": \"program_source_code\", \"program_name2\": \"program_source_code\", ..\\}.\n * Note that all imported programs must be deployed on chain before the main program in order\n * for the deployment to succeed\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the program deployment in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildDeploymentTransaction(private_key, program, fee_credits, fee_record, url, imports, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n let ptr1 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr1 = fee_record.__destroy_into_raw();\n }\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr3 = fee_proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr4 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildDeploymentTransaction(private_key.__wbg_ptr, ptr0, len0, fee_credits, ptr1, ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the fee for a program deployment\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The source code of the program being deployed\n * @param imports (optional) Provide a list of imports to use for the deployment fee estimation\n * in the form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @returns {u64 | Error}\n * @param {string} program\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static estimateDeploymentFee(program, imports) {\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_estimateDeploymentFee(ptr0, len0, isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n /**\n * Estimate the component of the deployment cost which comes from the fee for the program name.\n * Note that this cost does not represent the entire cost of deployment. It is additional to\n * the cost of the size (in bytes) of the deployment.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param name The name of the program to be deployed\n * @returns {u64 | Error}\n * @param {string} name\n * @returns {bigint}\n */\n static estimateProgramNameCost(name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateProgramNameCost(retptr, ptr0, len0);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Execute an arbitrary function locally\n *\n * @param {PrivateKey} private_key The private key of the sender\n * @param {string} program The source code of the program being executed\n * @param {string} function The name of the function to execute\n * @param {Array} inputs A javascript array of inputs to the function\n * @param {boolean} prove_execution If true, the execution will be proven and an execution object\n * containing the proof and the encrypted inputs and outputs needed to verify the proof offline\n * will be returned.\n * @param {boolean} cache Cache the proving and verifying keys in the Execution response.\n * If this is set to 'true' the keys synthesized will be stored in the Execution Response\n * and the `ProvingKey` and `VerifyingKey` can be retrieved from the response via the `.getKeys()`\n * method.\n * @param {Object | undefined} imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param {ProvingKey | undefined} proving_key (optional) Provide a verifying key to use for the function execution\n * @param {VerifyingKey | undefined} verifying_key (optional) Provide a verifying key to use for the function execution\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {boolean} prove_execution\n * @param {boolean} cache\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {string | undefined} [url]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static executeFunctionOffline(private_key, program, _function, inputs, prove_execution, cache, imports, proving_key, verifying_key, url, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr2 = proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr3 = verifying_key.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_executeFunctionOffline(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), prove_execution, cache, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr2, ptr3, ptr4, len4, ptr5);\n return takeObject(ret);\n }\n /**\n * Execute Aleo function and create an Aleo execution transaction\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program being executed\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * If this is set to 'true' the keys synthesized (or passed in as optional parameters via the\n * `proving_key` and `verifying_key` arguments) will be stored in the ProgramManager's memory\n * and used for subsequent transactions. If this is set to 'false' the proving and verifying\n * keys will be deallocated from memory after the transaction is executed.\n * @param imports (optional) Provide a list of imports to use for the function execution in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the function execution\n * @param verifying_key (optional) Provide a verifying key to use for the function execution\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildExecutionTransaction(private_key, program, _function, inputs, fee_credits, fee_record, url, imports, proving_key, verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr4 = proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr5 = verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildExecutionTransaction(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), fee_credits, ptr2, ptr3, len3, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Estimate Fee for Aleo function execution. Note if \"cache\" is set to true, the proving and\n * verifying keys will be stored in the ProgramManager's memory and used for subsequent\n * program executions.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param private_key The private key of the sender\n * @param program The source code of the program to estimate the execution fee for\n * @param function The name of the function to execute\n * @param inputs A javascript array of inputs to the function\n * @param url The url of the Aleo network node to send the transaction to\n * @param imports (optional) Provide a list of imports to use for the fee estimation in the\n * form of a javascript object where the keys are a string of the program name and the values\n * are a string representing the program source code \\{ \"hello.aleo\": \"hello.aleo source code\" \\}\n * @param proving_key (optional) Provide a verifying key to use for the fee estimation\n * @param verifying_key (optional) Provide a verifying key to use for the fee estimation\n * @returns {u64 | Error} Fee in microcredits\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} _function\n * @param {Array} inputs\n * @param {string | undefined} [url]\n * @param {object | undefined} [imports]\n * @param {ProvingKey | undefined} [proving_key]\n * @param {VerifyingKey | undefined} [verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static estimateExecutionFee(private_key, program, _function, inputs, url, imports, proving_key, verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n var ptr2 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len2 = WASM_VECTOR_LEN;\n let ptr3 = 0;\n if (!isLikeNone(proving_key)) {\n _assertClass(proving_key, ProvingKey);\n ptr3 = proving_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(verifying_key)) {\n _assertClass(verifying_key, VerifyingKey);\n ptr4 = verifying_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr5 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_estimateExecutionFee(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), ptr2, len2, isLikeNone(imports) ? 0 : addHeapObject(imports), ptr3, ptr4, ptr5);\n return takeObject(ret);\n }\n /**\n * Estimate the finalize fee component for executing a function. This fee is additional to the\n * size of the execution of the program in bytes. If the function does not have a finalize\n * step, then the finalize fee is 0.\n *\n * Disclaimer: Fee estimation is experimental and may not represent a correct estimate on any current or future network\n *\n * @param program The program containing the function to estimate the finalize fee for\n * @param function The function to estimate the finalize fee for\n * @returns {u64 | Error} Fee in microcredits\n * @param {string} program\n * @param {string} _function\n * @returns {bigint}\n */\n static estimateFinalizeFee(program, _function) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(_function, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.programmanager_estimateFinalizeFee(retptr, ptr0, len0, ptr1, len1);\n var r0 = getBigInt64Memory0()[retptr / 8 + 0];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n return BigInt.asUintN(64, r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Join two records together to create a new record with an amount of credits equal to the sum\n * of the credits of the two original records\n *\n * @param private_key The private key of the sender\n * @param record_1 The first record to combine\n * @param record_2 The second record to combine\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param join_proving_key (optional) Provide a proving key to use for the join function\n * @param join_verifying_key (optional) Provide a verifying key to use for the join function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error} Transaction object\n * @param {PrivateKey} private_key\n * @param {RecordPlaintext} record_1\n * @param {RecordPlaintext} record_2\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [join_proving_key]\n * @param {VerifyingKey | undefined} [join_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildJoinTransaction(private_key, record_1, record_2, fee_credits, fee_record, url, join_proving_key, join_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(record_1, RecordPlaintext);\n var ptr0 = record_1.__destroy_into_raw();\n _assertClass(record_2, RecordPlaintext);\n var ptr1 = record_2.__destroy_into_raw();\n let ptr2 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr2 = fee_record.__destroy_into_raw();\n }\n var ptr3 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len3 = WASM_VECTOR_LEN;\n let ptr4 = 0;\n if (!isLikeNone(join_proving_key)) {\n _assertClass(join_proving_key, ProvingKey);\n ptr4 = join_proving_key.__destroy_into_raw();\n }\n let ptr5 = 0;\n if (!isLikeNone(join_verifying_key)) {\n _assertClass(join_verifying_key, VerifyingKey);\n ptr5 = join_verifying_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr6 = fee_proving_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr7 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr8 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildJoinTransaction(private_key.__wbg_ptr, ptr0, ptr1, fee_credits, ptr2, ptr3, len3, ptr4, ptr5, ptr6, ptr7, ptr8);\n return takeObject(ret);\n }\n /**\n * Split an Aleo credits record into two separate records. This function does not require a fee.\n *\n * @param private_key The private key of the sender\n * @param split_amount The amount of the credit split. This amount will be subtracted from the\n * value of the record and two new records will be created with the split amount and the remainder\n * @param amount_record The record to split\n * @param url The url of the Aleo network node to send the transaction to\n * @param split_proving_key (optional) Provide a proving key to use for the split function\n * @param split_verifying_key (optional) Provide a verifying key to use for the split function\n * @returns {Transaction | Error} Transaction object\n * @param {PrivateKey} private_key\n * @param {number} split_amount\n * @param {RecordPlaintext} amount_record\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [split_proving_key]\n * @param {VerifyingKey | undefined} [split_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildSplitTransaction(private_key, split_amount, amount_record, url, split_proving_key, split_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n _assertClass(amount_record, RecordPlaintext);\n var ptr0 = amount_record.__destroy_into_raw();\n var ptr1 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(split_proving_key)) {\n _assertClass(split_proving_key, ProvingKey);\n ptr2 = split_proving_key.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(split_verifying_key)) {\n _assertClass(split_verifying_key, VerifyingKey);\n ptr3 = split_verifying_key.__destroy_into_raw();\n }\n let ptr4 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr4 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildSplitTransaction(private_key.__wbg_ptr, split_amount, ptr0, ptr1, len1, ptr2, ptr3, ptr4);\n return takeObject(ret);\n }\n /**\n * Send credits from one Aleo account to another\n *\n * @param private_key The private key of the sender\n * @param amount_credits The amount of credits to send\n * @param recipient The recipient of the transaction\n * @param transfer_type The type of the transfer (options: \"private\", \"public\", \"private_to_public\", \"public_to_private\")\n * @param amount_record The record to fund the amount from\n * @param fee_credits The amount of credits to pay as a fee\n * @param fee_record The record to spend the fee from\n * @param url The url of the Aleo network node to send the transaction to\n * @param transfer_verifying_key (optional) Provide a verifying key to use for the transfer\n * function\n * @param fee_proving_key (optional) Provide a proving key to use for the fee execution\n * @param fee_verifying_key (optional) Provide a verifying key to use for the fee execution\n * @returns {Transaction | Error}\n * @param {PrivateKey} private_key\n * @param {number} amount_credits\n * @param {string} recipient\n * @param {string} transfer_type\n * @param {RecordPlaintext | undefined} amount_record\n * @param {number} fee_credits\n * @param {RecordPlaintext | undefined} [fee_record]\n * @param {string | undefined} [url]\n * @param {ProvingKey | undefined} [transfer_proving_key]\n * @param {VerifyingKey | undefined} [transfer_verifying_key]\n * @param {ProvingKey | undefined} [fee_proving_key]\n * @param {VerifyingKey | undefined} [fee_verifying_key]\n * @param {OfflineQuery | undefined} [offline_query]\n * @returns {Promise}\n */\n static buildTransferTransaction(private_key, amount_credits, recipient, transfer_type, amount_record, fee_credits, fee_record, url, transfer_proving_key, transfer_verifying_key, fee_proving_key, fee_verifying_key, offline_query) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(recipient, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(transfer_type, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n let ptr2 = 0;\n if (!isLikeNone(amount_record)) {\n _assertClass(amount_record, RecordPlaintext);\n ptr2 = amount_record.__destroy_into_raw();\n }\n let ptr3 = 0;\n if (!isLikeNone(fee_record)) {\n _assertClass(fee_record, RecordPlaintext);\n ptr3 = fee_record.__destroy_into_raw();\n }\n var ptr4 = isLikeNone(url) ? 0 : passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len4 = WASM_VECTOR_LEN;\n let ptr5 = 0;\n if (!isLikeNone(transfer_proving_key)) {\n _assertClass(transfer_proving_key, ProvingKey);\n ptr5 = transfer_proving_key.__destroy_into_raw();\n }\n let ptr6 = 0;\n if (!isLikeNone(transfer_verifying_key)) {\n _assertClass(transfer_verifying_key, VerifyingKey);\n ptr6 = transfer_verifying_key.__destroy_into_raw();\n }\n let ptr7 = 0;\n if (!isLikeNone(fee_proving_key)) {\n _assertClass(fee_proving_key, ProvingKey);\n ptr7 = fee_proving_key.__destroy_into_raw();\n }\n let ptr8 = 0;\n if (!isLikeNone(fee_verifying_key)) {\n _assertClass(fee_verifying_key, VerifyingKey);\n ptr8 = fee_verifying_key.__destroy_into_raw();\n }\n let ptr9 = 0;\n if (!isLikeNone(offline_query)) {\n _assertClass(offline_query, OfflineQuery);\n ptr9 = offline_query.__destroy_into_raw();\n }\n const ret = wasm.programmanager_buildTransferTransaction(private_key.__wbg_ptr, amount_credits, ptr0, len0, ptr1, len1, ptr2, fee_credits, ptr3, ptr4, len4, ptr5, ptr6, ptr7, ptr8, ptr9);\n return takeObject(ret);\n }\n /**\n * Synthesize proving and verifying keys for a program\n *\n * @param program {string} The program source code of the program to synthesize keys for\n * @param function_id {string} The function to synthesize keys for\n * @param inputs {Array} The inputs to the function\n * @param imports {Object | undefined} The imports for the program\n * @param {PrivateKey} private_key\n * @param {string} program\n * @param {string} function_id\n * @param {Array} inputs\n * @param {object | undefined} [imports]\n * @returns {Promise}\n */\n static synthesizeKeyPair(private_key, program, function_id, inputs, imports) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(function_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n const ret = wasm.programmanager_synthesizeKeyPair(private_key.__wbg_ptr, ptr0, len0, ptr1, len1, addHeapObject(inputs), isLikeNone(imports) ? 0 : addHeapObject(imports));\n return takeObject(ret);\n }\n}\n\nconst ProvingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_provingkey_free(ptr >>> 0));\n/**\n* Proving key for a function within an Aleo program\n*/\nclass ProvingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ProvingKey.prototype);\n obj.__wbg_ptr = ptr;\n ProvingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ProvingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_provingkey_free(ptr);\n }\n /**\n * Verify if the proving key is for the bond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_public_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_public function, false if otherwise\n * @returns {boolean}\n */\n isBondPublicProver() {\n const ret = wasm.provingkey_isBondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the bond_validator function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"bond_validator_proving_key.bin\");\n * provingKey.isBondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the bond_validator function, false if otherwise\n * @returns {boolean}\n */\n isBondValidatorProver() {\n const ret = wasm.provingkey_isBondValidatorProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the claim_unbond function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"claim_unbond_proving_key.bin\");\n * provingKey.isClaimUnbondProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the claim_unbond function, false if otherwise\n * @returns {boolean}\n */\n isClaimUnbondPublicProver() {\n const ret = wasm.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_private_proving_key.bin\");\n * provingKey.isFeePrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_private function, false if otherwise\n * @returns {boolean}\n */\n isFeePrivateProver() {\n const ret = wasm.provingkey_isFeePrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the fee_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"fee_public_proving_key.bin\");\n * provingKey.isFeePublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the fee_public function, false if otherwise\n * @returns {boolean}\n */\n isFeePublicProver() {\n const ret = wasm.provingkey_isFeePublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the inclusion function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"inclusion_proving_key.bin\");\n * provingKey.isInclusionProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the inclusion function, false if otherwise\n * @returns {boolean}\n */\n isInclusionProver() {\n const ret = wasm.provingkey_isInclusionProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the join function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"join_proving_key.bin\");\n * provingKey.isJoinProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the join function, false if otherwise\n * @returns {boolean}\n */\n isJoinProver() {\n const ret = wasm.provingkey_isJoinProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the set_validator_state function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"set_validator_set_proving_key.bin\");\n * provingKey.isSetValidatorStateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the set_validator_state function, false if otherwise\n * @returns {boolean}\n */\n isSetValidatorStateProver() {\n const ret = wasm.provingkey_isSetValidatorStateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the split function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"split_proving_key.bin\");\n * provingKey.isSplitProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the split function, false if otherwise\n * @returns {boolean}\n */\n isSplitProver() {\n const ret = wasm.provingkey_isSplitProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_proving_key.bin\");\n * provingKey.isTransferPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateProver() {\n const ret = wasm.provingkey_isTransferPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_private_to_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_private_to_public_proving_key.bin\");\n * provingKey.isTransferPrivateToPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_private_to_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPrivateToPublicProver() {\n const ret = wasm.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_proving_key.bin\");\n * provingKey.isTransferPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicProver() {\n const ret = wasm.provingkey_isTransferPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_as_signer function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_as_signer_proving_key.bin\");\n * provingKey.isTransferPublicAsSignerProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicAsSignerProver() {\n const ret = wasm.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the transfer_public_to_private function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"transfer_public_to_private_proving_key.bin\");\n * provingKey.isTransferPublicToPrivateProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the transfer_public_to_private function, false if otherwise\n * @returns {boolean}\n */\n isTransferPublicToPrivateProver() {\n const ret = wasm.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verify if the proving key is for the unbond_public function\n *\n * @example\n * const provingKey = ProvingKey.fromBytes(\"unbond_public.bin\");\n * provingKey.isUnbondPublicProver() ? console.log(\"Key verified\") : throw new Error(\"Invalid key\");\n *\n * @returns {boolean} returns true if the proving key is for the unbond_public_prover function, false if otherwise\n * @returns {boolean}\n */\n isUnbondPublicProver() {\n const ret = wasm.provingkey_isUnbondPublicProver(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Return the checksum of the proving key\n *\n * @returns {string} Checksum of the proving key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the proving key\n *\n * @returns {ProvingKey} A copy of the proving key\n * @returns {ProvingKey}\n */\n copy() {\n const ret = wasm.provingkey_copy(this.__wbg_ptr);\n return ProvingKey.__wrap(ret);\n }\n /**\n * Construct a new proving key from a byte array\n *\n * @param {Uint8Array} bytes Byte array representation of a proving key\n * @returns {ProvingKey | Error}\n * @param {Uint8Array} bytes\n * @returns {ProvingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a proving key from string\n *\n * @param {string | Error} String representation of the proving key\n * @param {string} string\n * @returns {ProvingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.provingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return ProvingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the byte representation of a proving key\n *\n * @returns {Uint8Array | Error} Byte array representation of a proving key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the proving key\n *\n * @returns {string} String representation of the proving key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.provingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst RecordCiphertextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordciphertext_free(ptr >>> 0));\n/**\n* Encrypted Aleo record\n*/\nclass RecordCiphertext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordCiphertext.prototype);\n obj.__wbg_ptr = ptr;\n RecordCiphertextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordCiphertextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordciphertext_free(ptr);\n }\n /**\n * Create a record ciphertext from a string\n *\n * @param {string} record String representation of a record ciphertext\n * @returns {RecordCiphertext | Error} Record ciphertext\n * @param {string} record\n * @returns {RecordCiphertext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordciphertext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordCiphertext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return the string reprensentation of the record ciphertext\n *\n * @returns {string} String representation of the record ciphertext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordciphertext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Decrypt the record ciphertext into plaintext using the view key. The record will only\n * decrypt if the record was encrypted by the account corresponding to the view key\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {RecordPlaintext | Error} Record plaintext object\n * @param {ViewKey} view_key\n * @returns {RecordPlaintext}\n */\n decrypt(view_key) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(view_key, ViewKey);\n wasm.recordciphertext_decrypt(retptr, this.__wbg_ptr, view_key.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Determines if the account corresponding to the view key is the owner of the record\n *\n * @param {ViewKey} view_key View key used to decrypt the ciphertext\n * @returns {boolean}\n * @param {ViewKey} view_key\n * @returns {boolean}\n */\n isOwner(view_key) {\n _assertClass(view_key, ViewKey);\n const ret = wasm.recordciphertext_isOwner(this.__wbg_ptr, view_key.__wbg_ptr);\n return ret !== 0;\n }\n}\n\nconst RecordPlaintextFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_recordplaintext_free(ptr >>> 0));\n/**\n* Plaintext representation of an Aleo record\n*/\nclass RecordPlaintext {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(RecordPlaintext.prototype);\n obj.__wbg_ptr = ptr;\n RecordPlaintextFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n RecordPlaintextFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_recordplaintext_free(ptr);\n }\n /**\n * @param {string} program_id\n * @param {string} record_name\n * @returns {Field}\n */\n commitment(program_id, record_name) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_commitment(retptr, this.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Field.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Return a record plaintext from a string.\n *\n * @param {string} record String representation of a plaintext representation of an Aleo record\n * @returns {RecordPlaintext | Error} Record plaintext\n * @param {string} record\n * @returns {RecordPlaintext}\n */\n static fromString(record) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(record, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.recordplaintext_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return RecordPlaintext.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Returns the record plaintext string\n *\n * @returns {string} String representation of the record plaintext\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Returns the amount of microcredits in the record\n *\n * @returns {u64} Amount of microcredits in the record\n * @returns {bigint}\n */\n microcredits() {\n const ret = wasm.recordplaintext_microcredits(this.__wbg_ptr);\n return BigInt.asUintN(64, ret);\n }\n /**\n * Returns the nonce of the record. This can be used to uniquely identify a record.\n *\n * @returns {string} Nonce of the record\n * @returns {string}\n */\n nonce() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.recordplaintext_nonce(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Attempt to get the serial number of a record to determine whether or not is has been spent\n *\n * @param {PrivateKey} private_key Private key of the account that owns the record\n * @param {string} program_id Program ID of the program that the record is associated with\n * @param {string} record_name Name of the record\n * @returns {string | Error} Serial number of the record\n * @param {PrivateKey} private_key\n * @param {string} program_id\n * @param {string} record_name\n * @returns {string}\n */\n serialNumberString(private_key, program_id, record_name) {\n let deferred4_0;\n let deferred4_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n _assertClass(private_key, PrivateKey);\n const ptr0 = passStringToWasm0(program_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ptr1 = passStringToWasm0(record_name, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n wasm.recordplaintext_serialNumberString(retptr, this.__wbg_ptr, private_key.__wbg_ptr, ptr0, len0, ptr1, len1);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr3 = r0;\n var len3 = r1;\n if (r3) {\n ptr3 = 0; len3 = 0;\n throw takeObject(r2);\n }\n deferred4_0 = ptr3;\n deferred4_1 = len3;\n return getStringFromWasm0(ptr3, len3);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred4_0, deferred4_1, 1);\n }\n }\n}\n\nconst SignatureFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_signature_free(ptr >>> 0));\n/**\n* Cryptographic signature of a message signed by an Aleo account\n*/\nclass Signature {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Signature.prototype);\n obj.__wbg_ptr = ptr;\n SignatureFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n SignatureFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_signature_free(ptr);\n }\n /**\n * Sign a message with a private key\n *\n * @param {PrivateKey} private_key The private key to sign the message with\n * @param {Uint8Array} message Byte representation of the message to sign\n * @returns {Signature} Signature of the message\n * @param {PrivateKey} private_key\n * @param {Uint8Array} message\n * @returns {Signature}\n */\n static sign(private_key, message) {\n _assertClass(private_key, PrivateKey);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.privatekey_sign(private_key.__wbg_ptr, ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Verify a signature of a message with an address\n *\n * @param {Address} address The address to verify the signature with\n * @param {Uint8Array} message Byte representation of the message to verify\n * @returns {boolean} True if the signature is valid, false otherwise\n * @param {Address} address\n * @param {Uint8Array} message\n * @returns {boolean}\n */\n verify(address, message) {\n _assertClass(address, Address);\n const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_verify(this.__wbg_ptr, address.__wbg_ptr, ptr0, len0);\n return ret !== 0;\n }\n /**\n * Get a signature from a string representation of a signature\n *\n * @param {string} signature String representation of a signature\n * @returns {Signature} Signature\n * @param {string} signature\n * @returns {Signature}\n */\n static from_string(signature) {\n const ptr0 = passStringToWasm0(signature, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.signature_from_string(ptr0, len0);\n return Signature.__wrap(ret);\n }\n /**\n * Get a string representation of a signature\n *\n * @returns {string} String representation of a signature\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.signature_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst TransactionFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_transaction_free(ptr >>> 0));\n/**\n* Webassembly Representation of an Aleo transaction\n*\n* This object is created when generating an on-chain function deployment or execution and is the\n* object that should be submitted to the Aleo Network in order to deploy or execute a function.\n*/\nclass Transaction {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(Transaction.prototype);\n obj.__wbg_ptr = ptr;\n TransactionFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n TransactionFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_transaction_free(ptr);\n }\n /**\n * Create a transaction from a string\n *\n * @param {string} transaction String representation of a transaction\n * @returns {Transaction | Error}\n * @param {string} transaction\n * @returns {Transaction}\n */\n static fromString(transaction) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(transaction, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.transaction_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return Transaction.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get the transaction as a string. If you want to submit this transaction to the Aleo Network\n * this function will create the string that should be submitted in the `POST` data.\n *\n * @returns {string} String representation of the transaction\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the id of the transaction. This is the merkle root of the transaction's inclusion proof.\n *\n * This value can be used to query the status of the transaction on the Aleo Network to see\n * if it was successful. If successful, the transaction will be included in a block and this\n * value can be used to lookup the transaction data on-chain.\n *\n * @returns {string} Transaction id\n * @returns {string}\n */\n transactionId() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionId(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the type of the transaction (will return \"deploy\" or \"execute\")\n *\n * @returns {string} Transaction type\n * @returns {string}\n */\n transactionType() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.transaction_transactionType(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst VerifyingKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_verifyingkey_free(ptr >>> 0));\n/**\n* Verifying key for a function within an Aleo program\n*/\nclass VerifyingKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(VerifyingKey.prototype);\n obj.__wbg_ptr = ptr;\n VerifyingKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n VerifyingKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_verifyingkey_free(ptr);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {VerifyingKey}\n */\n static bondPublicVerifier() {\n const ret = wasm.verifyingkey_bondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {VerifyingKey}\n */\n static bondValidatorVerifier() {\n const ret = wasm.verifyingkey_bondValidatorVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the claim_delegator function\n *\n * @returns {VerifyingKey} Verifying key for the claim_unbond_public function\n * @returns {VerifyingKey}\n */\n static claimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_claimUnbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_private function\n *\n * @returns {VerifyingKey} Verifying key for the fee_private function\n * @returns {VerifyingKey}\n */\n static feePrivateVerifier() {\n const ret = wasm.verifyingkey_feePrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the fee_public function\n *\n * @returns {VerifyingKey} Verifying key for the fee_public function\n * @returns {VerifyingKey}\n */\n static feePublicVerifier() {\n const ret = wasm.verifyingkey_feePublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the inclusion function\n *\n * @returns {VerifyingKey} Verifying key for the inclusion function\n * @returns {VerifyingKey}\n */\n static inclusionVerifier() {\n const ret = wasm.verifyingkey_inclusionVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the join function\n *\n * @returns {VerifyingKey} Verifying key for the join function\n * @returns {VerifyingKey}\n */\n static joinVerifier() {\n const ret = wasm.verifyingkey_joinVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the set_validator_state function\n *\n * @returns {VerifyingKey} Verifying key for the set_validator_state function\n * @returns {VerifyingKey}\n */\n static setValidatorStateVerifier() {\n const ret = wasm.verifyingkey_setValidatorStateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the split function\n *\n * @returns {VerifyingKey} Verifying key for the split function\n * @returns {VerifyingKey}\n */\n static splitVerifier() {\n const ret = wasm.verifyingkey_splitVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private function\n * @returns {VerifyingKey}\n */\n static transferPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_private_to_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_private_to_public function\n * @returns {VerifyingKey}\n */\n static transferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_transferPrivateToPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public function\n * @returns {VerifyingKey}\n */\n static transferPublicVerifier() {\n const ret = wasm.verifyingkey_transferPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_as_signer function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_as_signer function\n * @returns {VerifyingKey}\n */\n static transferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_transferPublicAsSignerVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the transfer_public_to_private function\n *\n * @returns {VerifyingKey} Verifying key for the transfer_public_to_private function\n * @returns {VerifyingKey}\n */\n static transferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_transferPublicToPrivateVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the unbond_public function\n *\n * @returns {VerifyingKey} Verifying key for the unbond_public function\n * @returns {VerifyingKey}\n */\n static unbondPublicVerifier() {\n const ret = wasm.verifyingkey_unbondPublicVerifier();\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Returns the verifying key for the bond_public function\n *\n * @returns {VerifyingKey} Verifying key for the bond_public function\n * @returns {boolean}\n */\n isBondPublicVerifier() {\n const ret = wasm.verifyingkey_isBondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Returns the verifying key for the bond_validator function\n *\n * @returns {VerifyingKey} Verifying key for the bond_validator function\n * @returns {boolean}\n */\n isBondValidatorVerifier() {\n const ret = wasm.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the claim_delegator function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isClaimUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePrivateVerifier() {\n const ret = wasm.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the fee_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isFeePublicVerifier() {\n const ret = wasm.verifyingkey_isFeePublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the inclusion function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isInclusionVerifier() {\n const ret = wasm.verifyingkey_isInclusionVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the join function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isJoinVerifier() {\n const ret = wasm.verifyingkey_isJoinVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the set_validator_state function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSetValidatorStateVerifier() {\n const ret = wasm.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the split function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isSplitVerifier() {\n const ret = wasm.verifyingkey_isSplitVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_private_to_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPrivateToPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_as_signer function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicAsSignerVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the transfer_public_to_private function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isTransferPublicToPrivateVerifier() {\n const ret = wasm.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Verifies the verifying key is for the unbond_public function\n *\n * @returns {bool}\n * @returns {boolean}\n */\n isUnbondPublicVerifier() {\n const ret = wasm.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr);\n return ret !== 0;\n }\n /**\n * Get the checksum of the verifying key\n *\n * @returns {string} Checksum of the verifying key\n * @returns {string}\n */\n checksum() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_checksum(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Create a copy of the verifying key\n *\n * @returns {VerifyingKey} A copy of the verifying key\n * @returns {VerifyingKey}\n */\n copy() {\n const ret = wasm.verifyingkey_copy(this.__wbg_ptr);\n return VerifyingKey.__wrap(ret);\n }\n /**\n * Construct a new verifying key from a byte array\n *\n * @param {Uint8Array} bytes Byte representation of a verifying key\n * @returns {VerifyingKey | Error}\n * @param {Uint8Array} bytes\n * @returns {VerifyingKey}\n */\n static fromBytes(bytes) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passArray8ToWasm0(bytes, wasm.__wbindgen_malloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromBytes(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a verifying key from string\n *\n * @param {String} string String representation of a verifying key\n * @returns {VerifyingKey | Error}\n * @param {string} string\n * @returns {VerifyingKey}\n */\n static fromString(string) {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(string, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.verifyingkey_fromString(retptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n if (r2) {\n throw takeObject(r1);\n }\n return VerifyingKey.__wrap(r0);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Create a byte array from a verifying key\n *\n * @returns {Uint8Array | Error} Byte representation of a verifying key\n * @returns {Uint8Array}\n */\n toBytes() {\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toBytes(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n if (r3) {\n throw takeObject(r2);\n }\n var v1 = getArrayU8FromWasm0(r0, r1).slice();\n wasm.__wbindgen_free(r0, r1 * 1, 1);\n return v1;\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n }\n }\n /**\n * Get a string representation of the verifying key\n *\n * @returns {String} String representation of the verifying key\n * @returns {string}\n */\n toString() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.verifyingkey_toString(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n}\n\nconst ViewKeyFinalization = (typeof FinalizationRegistry === 'undefined')\n ? { register: () => {}, unregister: () => {} }\n : new FinalizationRegistry(ptr => wasm.__wbg_viewkey_free(ptr >>> 0));\n/**\n*/\nclass ViewKey {\n\n static __wrap(ptr) {\n ptr = ptr >>> 0;\n const obj = Object.create(ViewKey.prototype);\n obj.__wbg_ptr = ptr;\n ViewKeyFinalization.register(obj, obj.__wbg_ptr, obj);\n return obj;\n }\n\n __destroy_into_raw() {\n const ptr = this.__wbg_ptr;\n this.__wbg_ptr = 0;\n ViewKeyFinalization.unregister(this);\n return ptr;\n }\n\n free() {\n const ptr = this.__destroy_into_raw();\n wasm.__wbg_viewkey_free(ptr);\n }\n /**\n * Create a new view key from a private key\n *\n * @param {PrivateKey} private_key Private key\n * @returns {ViewKey} View key\n * @param {PrivateKey} private_key\n * @returns {ViewKey}\n */\n static from_private_key(private_key) {\n _assertClass(private_key, PrivateKey);\n const ret = wasm.privatekey_to_view_key(private_key.__wbg_ptr);\n return ViewKey.__wrap(ret);\n }\n /**\n * Create a new view key from a string representation of a view key\n *\n * @param {string} view_key String representation of a view key\n * @returns {ViewKey} View key\n * @param {string} view_key\n * @returns {ViewKey}\n */\n static from_string(view_key) {\n const ptr0 = passStringToWasm0(view_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n const ret = wasm.viewkey_from_string(ptr0, len0);\n return ViewKey.__wrap(ret);\n }\n /**\n * Get a string representation of a view key\n *\n * @returns {string} String representation of a view key\n * @returns {string}\n */\n to_string() {\n let deferred1_0;\n let deferred1_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n wasm.viewkey_to_string(retptr, this.__wbg_ptr);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n deferred1_0 = r0;\n deferred1_1 = r1;\n return getStringFromWasm0(r0, r1);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);\n }\n }\n /**\n * Get the address corresponding to a view key\n *\n * @returns {Address} Address\n * @returns {Address}\n */\n to_address() {\n const ret = wasm.address_from_view_key(this.__wbg_ptr);\n return Address.__wrap(ret);\n }\n /**\n * Decrypt a record ciphertext with a view key\n *\n * @param {string} ciphertext String representation of a record ciphertext\n * @returns {string} String representation of a record plaintext\n * @param {string} ciphertext\n * @returns {string}\n */\n decrypt(ciphertext) {\n let deferred3_0;\n let deferred3_1;\n try {\n const retptr = wasm.__wbindgen_add_to_stack_pointer(-16);\n const ptr0 = passStringToWasm0(ciphertext, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len0 = WASM_VECTOR_LEN;\n wasm.viewkey_decrypt(retptr, this.__wbg_ptr, ptr0, len0);\n var r0 = getInt32Memory0()[retptr / 4 + 0];\n var r1 = getInt32Memory0()[retptr / 4 + 1];\n var r2 = getInt32Memory0()[retptr / 4 + 2];\n var r3 = getInt32Memory0()[retptr / 4 + 3];\n var ptr2 = r0;\n var len2 = r1;\n if (r3) {\n ptr2 = 0; len2 = 0;\n throw takeObject(r2);\n }\n deferred3_0 = ptr2;\n deferred3_1 = len2;\n return getStringFromWasm0(ptr2, len2);\n } finally {\n wasm.__wbindgen_add_to_stack_pointer(16);\n wasm.__wbindgen_free(deferred3_0, deferred3_1, 1);\n }\n }\n}\n\nasync function __wbg_load(module, imports) {\n if (typeof Response === 'function' && module instanceof Response) {\n if (typeof WebAssembly.instantiateStreaming === 'function') {\n try {\n return await WebAssembly.instantiateStreaming(module, imports);\n\n } catch (e) {\n if (module.headers.get('Content-Type') != 'application/wasm') {\n console.warn(\"`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\\n\", e);\n\n } else {\n throw e;\n }\n }\n }\n\n const bytes = await module.arrayBuffer();\n return await WebAssembly.instantiate(bytes, imports);\n\n } else {\n const instance = await WebAssembly.instantiate(module, imports);\n\n if (instance instanceof WebAssembly.Instance) {\n return { instance, module };\n\n } else {\n return instance;\n }\n }\n}\n\nfunction __wbg_get_imports() {\n const imports = {};\n imports.wbg = {};\n imports.wbg.__wbindgen_object_drop_ref = function(arg0) {\n takeObject(arg0);\n };\n imports.wbg.__wbg_new_71801a555ad9f2aa = function() { return handleError(function () {\n const ret = new XMLHttpRequest();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_overrideMimeType_ee9c51919ceb418b = function() { return handleError(function (arg0, arg1, arg2) {\n getObject(arg0).overrideMimeType(getStringFromWasm0(arg1, arg2));\n }, arguments) };\n imports.wbg.__wbg_open_c9eb0cf2c9d95679 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {\n getObject(arg0).open(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4), arg5 !== 0);\n }, arguments) };\n imports.wbg.__wbg_send_80d29985093c1ec5 = function() { return handleError(function (arg0) {\n getObject(arg0).send();\n }, arguments) };\n imports.wbg.__wbg_response_7c2e2759084f7279 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).response;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_status_d485fb5a478426fb = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).status;\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_72fb9a18b5ae2624 = function() {\n const ret = new Object();\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_string_new = function(arg0, arg1) {\n const ret = getStringFromWasm0(arg0, arg1);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_1f9b04f170055d33 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = Reflect.set(getObject(arg0), getObject(arg1), getObject(arg2));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_new_ab6fd82b10560829 = function() { return handleError(function () {\n const ret = new Headers();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_object_clone_ref = function(arg0) {\n const ret = getObject(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_0d76b0581eca6298 = function() { return handleError(function () {\n const ret = new AbortController();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_signal_a61f78a3478fd9bc = function(arg0) {\n const ret = getObject(arg0).signal;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_append_7bfcb4937d1d5e29 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {\n getObject(arg0).append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));\n }, arguments) };\n imports.wbg.__wbg_instanceof_Response_849eb93e75734b6e = function(arg0) {\n let result;\n try {\n result = getObject(arg0) instanceof Response;\n } catch (_) {\n result = false;\n }\n const ret = result;\n return ret;\n };\n imports.wbg.__wbg_status_61a01141acd3cf74 = function(arg0) {\n const ret = getObject(arg0).status;\n return ret;\n };\n imports.wbg.__wbg_url_5f6dc4009ac5f99d = function(arg0, arg1) {\n const ret = getObject(arg1).url;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_headers_9620bfada380764a = function(arg0) {\n const ret = getObject(arg0).headers;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_iterator_2cee6dadfd956dfa = function() {\n const ret = Symbol.iterator;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_get_e3c254076557e348 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.get(getObject(arg0), getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_function = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'function';\n return ret;\n };\n imports.wbg.__wbg_call_27c0f87801dedf93 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg0).call(getObject(arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_object = function(arg0) {\n const val = getObject(arg0);\n const ret = typeof(val) === 'object' && val !== null;\n return ret;\n };\n imports.wbg.__wbg_next_40fc327bfc8770e6 = function(arg0) {\n const ret = getObject(arg0).next;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_next_196c84450b364254 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).next();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_done_298b57d23c0fc80c = function(arg0) {\n const ret = getObject(arg0).done;\n return ret;\n };\n imports.wbg.__wbg_value_d93c65011f51a456 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_abort_2aa7521d5690750e = function(arg0) {\n getObject(arg0).abort();\n };\n imports.wbg.__wbg_stringify_8887fe74e1c50d81 = function() { return handleError(function (arg0) {\n const ret = JSON.stringify(getObject(arg0));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_string_get = function(arg0, arg1) {\n const obj = getObject(arg1);\n const ret = typeof(obj) === 'string' ? obj : undefined;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_log_0159ca40cddf5b15 = function(arg0, arg1) {\n console.log(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {\n const ret = BigInt.asUintN(64, arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_call_b3ca7c6051f9bec1 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_transaction_new = function(arg0) {\n const ret = Transaction.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_keypair_new = function(arg0) {\n const ret = KeyPair.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_module = function() {\n const ret = __wbg_init.__wbindgen_wasm_module;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_memory = function() {\n const ret = wasm.memory;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a = function(arg0, arg1, arg2, arg3) {\n const ret = spawnWorker(getObject(arg0), getObject(arg1), getObject(arg2), arg3 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_executionresponse_new = function(arg0) {\n const ret = ExecutionResponse.__wrap(arg0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_66ae46612e7f0234 = function(arg0) {\n const ret = new Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_set_d4638f722068f043 = function(arg0, arg1, arg2) {\n getObject(arg0)[arg1 >>> 0] = takeObject(arg2);\n };\n imports.wbg.__wbindgen_cb_drop = function(arg0) {\n const obj = takeObject(arg0).original;\n if (obj.cnt-- == 1) {\n obj.a = 0;\n return true;\n }\n const ret = false;\n return ret;\n };\n imports.wbg.__wbg_new_16b304a2cfa7ff4a = function() {\n const ret = new Array();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_push_a5b05aedc7234f9f = function(arg0, arg1) {\n const ret = getObject(arg0).push(getObject(arg1));\n return ret;\n };\n imports.wbg.__wbg_arrayBuffer_29931d52c7206b02 = function() { return handleError(function (arg0) {\n const ret = getObject(arg0).arrayBuffer();\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_new_63b92bc8671ed464 = function(arg0) {\n const ret = new Uint8Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_c20a40f15020d68a = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_new_81740750da40724f = function(arg0, arg1) {\n try {\n var state0 = {a: arg0, b: arg1};\n var cb0 = (arg0, arg1) => {\n const a = state0.a;\n state0.a = 0;\n try {\n return __wbg_adapter_281(a, state0.b, arg0, arg1);\n } finally {\n state0.a = a;\n }\n };\n const ret = new Promise(cb0);\n return addHeapObject(ret);\n } finally {\n state0.a = state0.b = 0;\n }\n };\n imports.wbg.__wbindgen_number_new = function(arg0) {\n const ret = arg0;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_abda76e883ba8a5f = function() {\n const ret = new Error();\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_stack_658279fe44541cf6 = function(arg0, arg1) {\n const ret = getObject(arg1).stack;\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_error_f851667af71bcfc6 = function(arg0, arg1) {\n let deferred0_0;\n let deferred0_1;\n try {\n deferred0_0 = arg0;\n deferred0_1 = arg1;\n console.error(getStringFromWasm0(arg0, arg1));\n } finally {\n wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);\n }\n };\n imports.wbg.__wbg_buffer_12d079cc21e14bdb = function(arg0) {\n const ret = getObject(arg0).buffer;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb = function(arg0, arg1, arg2) {\n const ret = new Uint8Array(getObject(arg0), arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_randomFillSync_5c9c955aa56b6049 = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).randomFillSync(takeObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_subarray_a1f73cd4b5b42fe1 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).subarray(arg1 >>> 0, arg2 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_getRandomValues_3aa56aa6edec874c = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).getRandomValues(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_set_a47bac70306a19a7 = function(arg0, arg1, arg2) {\n getObject(arg0).set(getObject(arg1), arg2 >>> 0);\n };\n imports.wbg.__wbg_crypto_1d1f22824a6a080c = function(arg0) {\n const ret = getObject(arg0).crypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_process_4a72847cc503995b = function(arg0) {\n const ret = getObject(arg0).process;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_versions_f686565e586dd935 = function(arg0) {\n const ret = getObject(arg0).versions;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_node_104a2ff8d6ea03a2 = function(arg0) {\n const ret = getObject(arg0).node;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_is_string = function(arg0) {\n const ret = typeof(getObject(arg0)) === 'string';\n return ret;\n };\n imports.wbg.__wbg_require_cca90b1a94a0255b = function() { return handleError(function () {\n const ret = module.require;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_msCrypto_eb05e62b530a1508 = function(arg0) {\n const ret = getObject(arg0).msCrypto;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithlength_e9b4878cebadb3d3 = function(arg0) {\n const ret = new Uint8Array(arg0 >>> 0);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_length_cd7af8117672b8b8 = function(arg0) {\n const ret = getObject(arg0).length;\n return ret;\n };\n imports.wbg.__wbg_get_bd8e338fbd5f5cc8 = function(arg0, arg1) {\n const ret = getObject(arg0)[arg1 >>> 0];\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_self_ce0dbfc45cf2f5be = function() { return handleError(function () {\n const ret = self.self;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_window_c6fb939a7f436783 = function() { return handleError(function () {\n const ret = window.window;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_globalThis_d1e6af4856ba331b = function() { return handleError(function () {\n const ret = globalThis.globalThis;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_global_207b558942527489 = function() { return handleError(function () {\n const ret = global.global;\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbindgen_is_undefined = function(arg0) {\n const ret = getObject(arg0) === undefined;\n return ret;\n };\n imports.wbg.__wbg_newnoargs_e258087cd0daa0ea = function(arg0, arg1) {\n const ret = new Function(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_has_0af94d20077affa2 = function() { return handleError(function (arg0, arg1) {\n const ret = Reflect.has(getObject(arg0), getObject(arg1));\n return ret;\n }, arguments) };\n imports.wbg.__wbg_fetch_bc7c8e27076a5c84 = function(arg0) {\n const ret = fetch(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_fetch_921fad6ef9e883dd = function(arg0, arg1) {\n const ret = getObject(arg0).fetch(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {\n const ret = debugString(getObject(arg1));\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbindgen_throw = function(arg0, arg1) {\n throw new Error(getStringFromWasm0(arg0, arg1));\n };\n imports.wbg.__wbindgen_rethrow = function(arg0) {\n throw takeObject(arg0);\n };\n imports.wbg.__wbg_then_a73caa9a87991566 = function(arg0, arg1, arg2) {\n const ret = getObject(arg0).then(getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_then_0c86a60e8fcfe9f6 = function(arg0, arg1) {\n const ret = getObject(arg0).then(getObject(arg1));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_queueMicrotask_481971b0d87f3dd4 = function(arg0) {\n queueMicrotask(getObject(arg0));\n };\n imports.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6 = function(arg0) {\n const ret = getObject(arg0).queueMicrotask;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_resolve_b0083a7967828ec8 = function(arg0) {\n const ret = Promise.resolve(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_5d743fc9058ba01a = function() {\n const ret = Atomics.waitAsync;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_new_8cccba86b0f574cb = function(arg0) {\n const ret = new Int32Array(getObject(arg0));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_waitAsync_46d5c36955b71a79 = function(arg0, arg1, arg2) {\n const ret = Atomics.waitAsync(getObject(arg0), arg1, arg2);\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_async_19c0400d97cc72fe = function(arg0) {\n const ret = getObject(arg0).async;\n return ret;\n };\n imports.wbg.__wbg_value_571d60108110e917 = function(arg0) {\n const ret = getObject(arg0).value;\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_link_fc1eedd35dc7e0a6 = function(arg0) {\n const ret = \"data:application/javascript,\" + encodeURIComponent(`onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n `);\n const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n const len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n };\n imports.wbg.__wbg_new_d1187ae36d662ef9 = function() { return handleError(function (arg0, arg1) {\n const ret = new Worker(getStringFromWasm0(arg0, arg1));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_setonmessage_503809e5bb51bd33 = function(arg0, arg1) {\n getObject(arg0).onmessage = getObject(arg1);\n };\n imports.wbg.__wbg_of_6a70eed8d41f469c = function(arg0, arg1, arg2) {\n const ret = Array.of(getObject(arg0), getObject(arg1), getObject(arg2));\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_postMessage_7380d10e8b8269df = function() { return handleError(function (arg0, arg1) {\n getObject(arg0).postMessage(getObject(arg1));\n }, arguments) };\n imports.wbg.__wbg_data_3ce7c145ca4fbcdc = function(arg0) {\n const ret = getObject(arg0).data;\n return addHeapObject(ret);\n };\n imports.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0 = function() { return handleError(function (arg0, arg1, arg2) {\n const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));\n return addHeapObject(ret);\n }, arguments) };\n imports.wbg.__wbg_responseText_c67ed2d48db10769 = function() { return handleError(function (arg0, arg1) {\n const ret = getObject(arg1).responseText;\n var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);\n var len1 = WASM_VECTOR_LEN;\n getInt32Memory0()[arg0 / 4 + 1] = len1;\n getInt32Memory0()[arg0 / 4 + 0] = ptr1;\n }, arguments) };\n imports.wbg.__wbindgen_closure_wrapper5837 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 538, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n imports.wbg.__wbindgen_closure_wrapper5862 = function(arg0, arg1, arg2) {\n const ret = makeMutClosure(arg0, arg1, 538, __wbg_adapter_34);\n return addHeapObject(ret);\n };\n\n return imports;\n}\n\nfunction __wbg_init_memory(imports, maybe_memory) {\n imports.wbg.memory = maybe_memory || new WebAssembly.Memory({initial:25,maximum:65536,shared:true});\n}\n\nfunction __wbg_finalize_init(instance, module) {\n wasm = instance.exports;\n __wbg_init.__wbindgen_wasm_module = module;\n cachedBigInt64Memory0 = null;\n cachedInt32Memory0 = null;\n cachedUint8Memory0 = null;\n\n wasm.__wbindgen_start();\n return wasm;\n}\n\nfunction initSync(module, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n const imports = __wbg_get_imports();\n\n __wbg_init_memory(imports, maybe_memory);\n\n if (!(module instanceof WebAssembly.Module)) {\n module = new WebAssembly.Module(module);\n }\n\n const instance = new WebAssembly.Instance(module, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nasync function __wbg_init(input, maybe_memory) {\n if (wasm !== undefined) return wasm;\n\n\n const imports = __wbg_get_imports();\n\n if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {\n input = fetch(input);\n }\n\n __wbg_init_memory(imports, maybe_memory);\n\n const { instance, module } = await __wbg_load(await input, imports);\n\n return __wbg_finalize_init(instance, module);\n}\n\nvar exports = /*#__PURE__*/Object.freeze({\n __proto__: null,\n Address: Address,\n Execution: Execution,\n ExecutionResponse: ExecutionResponse,\n Field: Field,\n KeyPair: KeyPair,\n Metadata: Metadata,\n OfflineQuery: OfflineQuery,\n PrivateKey: PrivateKey,\n PrivateKeyCiphertext: PrivateKeyCiphertext,\n Program: Program,\n ProgramManager: ProgramManager,\n ProvingKey: ProvingKey,\n RecordCiphertext: RecordCiphertext,\n RecordPlaintext: RecordPlaintext,\n Signature: Signature,\n Transaction: Transaction,\n VerifyingKey: VerifyingKey,\n ViewKey: ViewKey,\n default: __wbg_init,\n initSync: initSync,\n initThreadPool: initThreadPool,\n runRayonThread: runRayonThread,\n verifyFunctionExecution: verifyFunctionExecution\n});\n\nconst wasm_path = \"assets/aleo_wasm.wasm\";\n\n \n var Cargo = async (opt = {}) => {\n let {importHook, serverPath, initializeHook} = opt;\n\n let final_path = wasm_path;\n\n if (serverPath != null) {\n final_path = serverPath + /[^\\/\\\\]*$/.exec(final_path)[0];\n }\n\n if (importHook != null) {\n final_path = importHook(final_path);\n }\n\n if (initializeHook != null) {\n await initializeHook(__wbg_init, final_path);\n\n } else {\n await __wbg_init(final_path);\n }\n\n return exports;\n };\n\nexport { Cargo as default };\n//# sourceMappingURL=wasm.js.map\n","import wasm from \"../dist/wasm.js\";\n\nconst {\n initThreadPool: wasmInitThreadPool,\n Address,\n Execution,\n ExecutionResponse,\n Field,\n Metadata,\n OfflineQuery,\n Private,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n ProgramManager,\n Signature,\n Transaction,\n ViewKey,\n VerifyingKey,\n verifyFunctionExecution,\n} = await wasm({\n importHook: () => {\n return new URL(\"assets/aleo_wasm.wasm\", import.meta.url);\n },\n});\n\nasync function initThreadPool(threads) {\n if (threads == null) {\n threads = navigator.hardwareConcurrency;\n }\n\n console.info(`Spawning ${threads} threads`);\n\n await wasmInitThreadPool(new URL(\"worker.js\", import.meta.url), threads);\n}\n\nexport {\n initThreadPool,\n Address,\n Execution,\n ExecutionResponse,\n Field,\n Metadata,\n OfflineQuery,\n PrivateKey,\n PrivateKeyCiphertext,\n Program,\n ProvingKey,\n RecordCiphertext,\n RecordPlaintext,\n ProgramManager,\n Signature,\n Transaction,\n ViewKey,\n VerifyingKey,\n verifyFunctionExecution,\n};\n"],"names":["spawnWorker","url","module","memory","address","Promise","resolve","worker","Worker","type","addEventListener","event","setTimeout","unref","capture","once","postMessage","wasm","heap","Array","fill","undefined","getObject","idx","push","heap_next","length","dropObject","takeObject","ret","cachedTextDecoder","TextDecoder","ignoreBOM","fatal","decode","Error","cachedUint8Memory0","getUint8Memory0","buffer","Uint8Array","getStringFromWasm0","ptr","len","slice","addHeapObject","obj","WASM_VECTOR_LEN","cachedTextEncoder","TextEncoder","encode","encodeString","arg","view","buf","set","read","written","passStringToWasm0","malloc","realloc","subarray","mem","offset","code","charCodeAt","isLikeNone","x","cachedInt32Memory0","getInt32Memory0","Int32Array","debugString","val","description","name","isArray","debug","i","builtInMatches","exec","toString","call","className","JSON","stringify","_","message","stack","CLOSURE_DTORS","FinalizationRegistry","register","unregister","state","__wbindgen_export_3","get","dtor","a","b","makeMutClosure","arg0","arg1","f","cnt","real","args","original","__wbg_adapter_34","arg2","_dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h467700a9696faab3","_assertClass","instance","klass","passArray8ToWasm0","verifyFunctionExecution$1","execution","verifying_key","program","function_id","retptr","__wbindgen_add_to_stack_pointer","Execution$1","VerifyingKey$1","Program$1","ptr0","__wbindgen_malloc","__wbindgen_realloc","len0","verifyFunctionExecution","__wbg_ptr","r0","r1","cachedBigInt64Memory0","getBigInt64Memory0","BigInt64Array","getArrayU8FromWasm0","runRayonThread","receiver","initThreadPool$1","num_threads","initThreadPool","handleError","apply","this","e","__wbindgen_exn_store","__wbg_adapter_281","arg3","wasm_bindgen__convert__closures__invoke2_mut__h381bef3cd886b4c7","AddressFinalization","__wbg_address_free","Address","__wrap","Object","create","prototype","__destroy_into_raw","free","from_private_key","private_key","PrivateKey$1","address_from_private_key","from_view_key","view_key","ViewKey$1","address_from_view_key","from_string","address_from_string","to_string","deferred1_0","deferred1_1","address_to_string","__wbindgen_free","verify","signature","Signature$1","address_verify","ExecutionFinalization","__wbg_execution_free","Execution","execution_toString","fromString","execution_fromString","ExecutionResponseFinalization","__wbg_executionresponse_free","ExecutionResponse","getOutputs","executionresponse_getOutputs","getExecution","executionresponse_getExecution","getKeys","executionresponse_getKeys","KeyPair","getProvingKey","executionresponse_getProvingKey","ProvingKey$1","getVerifyingKey","executionresponse_getVerifyingKey","getFunctionId","executionresponse_getFunctionId","getProgram","executionresponse_getProgram","FieldFinalization","__wbg_field_free","Field","field_toString","field","field_fromString","KeyPairFinalization","__wbg_keypair_free","constructor","proving_key","ptr1","keypair_new","provingKey","keypair_provingKey","verifyingKey","keypair_verifyingKey","MetadataFinalization","__wbg_metadata_free","Metadata","__wbg_get_metadata_name","__wbg_set_metadata_name","locator","__wbg_get_metadata_locator","__wbg_set_metadata_locator","prover","__wbg_get_metadata_prover","__wbg_set_metadata_prover","verifier","__wbg_get_metadata_verifier","__wbg_set_metadata_verifier","__wbg_get_metadata_verifyingKey","__wbg_set_metadata_verifyingKey","baseUrl","metadata_baseUrl","bond_public","metadata_bond_public","bond_validator","metadata_bond_validator","claim_unbond_public","metadata_claim_unbond_public","fee_private","metadata_fee_private","fee_public","metadata_fee_public","inclusion","metadata_inclusion","join","metadata_join","set_validator_state","metadata_set_validator_state","split","metadata_split","transfer_private","metadata_transfer_private","transfer_private_to_public","metadata_transfer_private_to_public","transfer_public","metadata_transfer_public","transfer_public_as_signer","metadata_transfer_public_as_signer","transfer_public_to_private","metadata_transfer_public_to_private","unbond_public","metadata_unbond_public","OfflineQueryFinalization","__wbg_offlinequery_free","OfflineQuery","state_root","offlinequery_new","addStatePath","commitment","state_path","len1","offlinequery_addStatePath","offlinequery_toString","s","offlinequery_fromString","PrivateKeyFinalization","__wbg_privatekey_free","PrivateKey","privatekey_new","from_seed_unchecked","seed","privatekey_from_seed_unchecked","privatekey_from_string","privatekey_to_string","to_view_key","privatekey_to_view_key","to_address","privatekey_to_address","Address$1","sign","privatekey_sign","newEncrypted","secret","privatekey_newEncrypted","PrivateKeyCiphertext$1","toCiphertext","privatekey_toCiphertext","fromPrivateKeyCiphertext","ciphertext","privatekey_fromPrivateKeyCiphertext","PrivateKeyCiphertextFinalization","__wbg_privatekeyciphertext_free","PrivateKeyCiphertext","encryptPrivateKey","decryptToPrivateKey","privatekeyciphertext_decryptToPrivateKey","privatekeyciphertext_toString","privatekeyciphertext_fromString","ProgramFinalization","__wbg_program_free","Program","program_fromString","program_toString","hasFunction","function_name","program_hasFunction","getFunctions","program_getFunctions","getFunctionInputs","program_getFunctionInputs","getMappings","program_getMappings","getRecordMembers","record_name","program_getRecordMembers","getStructMembers","struct_name","program_getStructMembers","getCreditsProgram","program_getCreditsProgram","id","program_id","program_address","isEqual","other","program_isEqual","getImports","program_getImports","ProgramManagerFinalization","__wbg_programmanager_free","buildDeploymentTransaction","fee_credits","fee_record","imports","fee_proving_key","fee_verifying_key","offline_query","RecordPlaintext$1","ptr2","len2","ptr3","ptr4","ptr5","OfflineQuery$1","programmanager_buildDeploymentTransaction","estimateDeploymentFee","programmanager_estimateDeploymentFee","estimateProgramNameCost","programmanager_estimateProgramNameCost","r2","BigInt","asUintN","executeFunctionOffline","_function","inputs","prove_execution","cache","len4","programmanager_executeFunctionOffline","buildExecutionTransaction","len3","ptr6","ptr7","ptr8","programmanager_buildExecutionTransaction","estimateExecutionFee","programmanager_estimateExecutionFee","estimateFinalizeFee","programmanager_estimateFinalizeFee","buildJoinTransaction","record_1","record_2","join_proving_key","join_verifying_key","programmanager_buildJoinTransaction","buildSplitTransaction","split_amount","amount_record","split_proving_key","split_verifying_key","programmanager_buildSplitTransaction","buildTransferTransaction","amount_credits","recipient","transfer_type","transfer_proving_key","transfer_verifying_key","ptr9","programmanager_buildTransferTransaction","synthesizeKeyPair","programmanager_synthesizeKeyPair","ProvingKeyFinalization","__wbg_provingkey_free","ProvingKey","isBondPublicProver","provingkey_isBondPublicProver","isBondValidatorProver","provingkey_isBondValidatorProver","isClaimUnbondPublicProver","provingkey_isClaimUnbondPublicProver","isFeePrivateProver","provingkey_isFeePrivateProver","isFeePublicProver","provingkey_isFeePublicProver","isInclusionProver","provingkey_isInclusionProver","isJoinProver","provingkey_isJoinProver","isSetValidatorStateProver","provingkey_isSetValidatorStateProver","isSplitProver","provingkey_isSplitProver","isTransferPrivateProver","provingkey_isTransferPrivateProver","isTransferPrivateToPublicProver","provingkey_isTransferPrivateToPublicProver","isTransferPublicProver","provingkey_isTransferPublicProver","isTransferPublicAsSignerProver","provingkey_isTransferPublicAsSignerProver","isTransferPublicToPrivateProver","provingkey_isTransferPublicToPrivateProver","isUnbondPublicProver","provingkey_isUnbondPublicProver","checksum","provingkey_checksum","copy","provingkey_copy","fromBytes","bytes","provingkey_fromBytes","string","provingkey_fromString","toBytes","provingkey_toBytes","v1","provingkey_toString","RecordCiphertextFinalization","__wbg_recordciphertext_free","RecordCiphertext","record","recordciphertext_fromString","recordciphertext_toString","decrypt","recordciphertext_decrypt","isOwner","recordciphertext_isOwner","RecordPlaintextFinalization","__wbg_recordplaintext_free","RecordPlaintext","recordplaintext_commitment","Field$1","recordplaintext_fromString","recordplaintext_toString","microcredits","recordplaintext_microcredits","nonce","recordplaintext_nonce","serialNumberString","deferred4_0","deferred4_1","recordplaintext_serialNumberString","r3","SignatureFinalization","__wbg_signature_free","Signature","signature_verify","signature_from_string","signature_to_string","TransactionFinalization","__wbg_transaction_free","Transaction","transaction","transaction_fromString","transaction_toString","transactionId","transaction_transactionId","transactionType","transaction_transactionType","VerifyingKeyFinalization","__wbg_verifyingkey_free","VerifyingKey","bondPublicVerifier","verifyingkey_bondPublicVerifier","bondValidatorVerifier","verifyingkey_bondValidatorVerifier","claimUnbondPublicVerifier","verifyingkey_claimUnbondPublicVerifier","feePrivateVerifier","verifyingkey_feePrivateVerifier","feePublicVerifier","verifyingkey_feePublicVerifier","inclusionVerifier","verifyingkey_inclusionVerifier","joinVerifier","verifyingkey_joinVerifier","setValidatorStateVerifier","verifyingkey_setValidatorStateVerifier","splitVerifier","verifyingkey_splitVerifier","transferPrivateVerifier","verifyingkey_transferPrivateVerifier","transferPrivateToPublicVerifier","verifyingkey_transferPrivateToPublicVerifier","transferPublicVerifier","verifyingkey_transferPublicVerifier","transferPublicAsSignerVerifier","verifyingkey_transferPublicAsSignerVerifier","transferPublicToPrivateVerifier","verifyingkey_transferPublicToPrivateVerifier","unbondPublicVerifier","verifyingkey_unbondPublicVerifier","isBondPublicVerifier","verifyingkey_isBondPublicVerifier","isBondValidatorVerifier","verifyingkey_isBondValidatorVerifier","isClaimUnbondPublicVerifier","verifyingkey_isClaimUnbondPublicVerifier","isFeePrivateVerifier","verifyingkey_isFeePrivateVerifier","isFeePublicVerifier","verifyingkey_isFeePublicVerifier","isInclusionVerifier","verifyingkey_isInclusionVerifier","isJoinVerifier","verifyingkey_isJoinVerifier","isSetValidatorStateVerifier","verifyingkey_isSetValidatorStateVerifier","isSplitVerifier","verifyingkey_isSplitVerifier","isTransferPrivateVerifier","verifyingkey_isTransferPrivateVerifier","isTransferPrivateToPublicVerifier","verifyingkey_isTransferPrivateToPublicVerifier","isTransferPublicVerifier","verifyingkey_isTransferPublicVerifier","isTransferPublicAsSignerVerifier","verifyingkey_isTransferPublicAsSignerVerifier","isTransferPublicToPrivateVerifier","verifyingkey_isTransferPublicToPrivateVerifier","isUnbondPublicVerifier","verifyingkey_isUnbondPublicVerifier","verifyingkey_checksum","verifyingkey_copy","verifyingkey_fromBytes","verifyingkey_fromString","verifyingkey_toBytes","verifyingkey_toString","ViewKeyFinalization","__wbg_viewkey_free","ViewKey","viewkey_from_string","viewkey_to_string","deferred3_0","deferred3_1","viewkey_decrypt","async","__wbg_load","Response","WebAssembly","instantiateStreaming","headers","console","warn","arrayBuffer","instantiate","Instance","__wbg_get_imports","wbg","__wbindgen_object_drop_ref","__wbg_new_71801a555ad9f2aa","XMLHttpRequest","arguments","__wbg_overrideMimeType_ee9c51919ceb418b","overrideMimeType","__wbg_open_c9eb0cf2c9d95679","arg4","arg5","open","__wbg_send_80d29985093c1ec5","send","__wbg_response_7c2e2759084f7279","response","__wbg_status_d485fb5a478426fb","status","__wbg_new_72fb9a18b5ae2624","__wbindgen_string_new","__wbg_set_1f9b04f170055d33","Reflect","__wbg_new_ab6fd82b10560829","Headers","__wbindgen_object_clone_ref","__wbg_new_0d76b0581eca6298","AbortController","__wbg_signal_a61f78a3478fd9bc","signal","__wbg_append_7bfcb4937d1d5e29","append","__wbg_instanceof_Response_849eb93e75734b6e","result","__wbg_status_61a01141acd3cf74","__wbg_url_5f6dc4009ac5f99d","__wbg_headers_9620bfada380764a","__wbg_iterator_2cee6dadfd956dfa","Symbol","iterator","__wbg_get_e3c254076557e348","__wbindgen_is_function","__wbg_call_27c0f87801dedf93","__wbindgen_is_object","__wbg_next_40fc327bfc8770e6","next","__wbg_next_196c84450b364254","__wbg_done_298b57d23c0fc80c","done","__wbg_value_d93c65011f51a456","value","__wbg_abort_2aa7521d5690750e","abort","__wbg_stringify_8887fe74e1c50d81","__wbindgen_string_get","__wbg_log_0159ca40cddf5b15","log","__wbindgen_bigint_from_u64","__wbg_call_b3ca7c6051f9bec1","__wbg_transaction_new","Transaction$1","__wbg_keypair_new","__wbindgen_module","__wbg_init","__wbindgen_wasm_module","__wbindgen_memory","__wbg_spawnWorker_f6acaddb2e29dc4a","__wbg_executionresponse_new","ExecutionResponse$1","__wbg_newwithlength_66ae46612e7f0234","__wbg_set_d4638f722068f043","__wbindgen_cb_drop","__wbg_new_16b304a2cfa7ff4a","__wbg_push_a5b05aedc7234f9f","__wbg_arrayBuffer_29931d52c7206b02","__wbg_new_63b92bc8671ed464","__wbg_length_c20a40f15020d68a","__wbg_new_81740750da40724f","state0","cb0","__wbindgen_number_new","__wbg_new_abda76e883ba8a5f","__wbg_stack_658279fe44541cf6","__wbg_error_f851667af71bcfc6","deferred0_0","deferred0_1","error","__wbg_buffer_12d079cc21e14bdb","__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb","__wbg_randomFillSync_5c9c955aa56b6049","randomFillSync","__wbg_subarray_a1f73cd4b5b42fe1","__wbg_getRandomValues_3aa56aa6edec874c","getRandomValues","__wbg_set_a47bac70306a19a7","__wbg_crypto_1d1f22824a6a080c","crypto","__wbg_process_4a72847cc503995b","process","__wbg_versions_f686565e586dd935","versions","__wbg_node_104a2ff8d6ea03a2","node","__wbindgen_is_string","__wbg_require_cca90b1a94a0255b","require","__wbg_msCrypto_eb05e62b530a1508","msCrypto","__wbg_newwithlength_e9b4878cebadb3d3","__wbg_length_cd7af8117672b8b8","__wbg_get_bd8e338fbd5f5cc8","__wbg_self_ce0dbfc45cf2f5be","self","__wbg_window_c6fb939a7f436783","window","__wbg_globalThis_d1e6af4856ba331b","globalThis","__wbg_global_207b558942527489","global","__wbindgen_is_undefined","__wbg_newnoargs_e258087cd0daa0ea","Function","__wbg_has_0af94d20077affa2","has","__wbg_fetch_bc7c8e27076a5c84","fetch","__wbg_fetch_921fad6ef9e883dd","__wbindgen_debug_string","__wbindgen_throw","__wbindgen_rethrow","__wbg_then_a73caa9a87991566","then","__wbg_then_0c86a60e8fcfe9f6","__wbg_queueMicrotask_481971b0d87f3dd4","queueMicrotask","__wbg_queueMicrotask_3cbae2ec6b6cd3d6","__wbg_resolve_b0083a7967828ec8","__wbg_waitAsync_5d743fc9058ba01a","Atomics","waitAsync","__wbg_new_8cccba86b0f574cb","__wbg_waitAsync_46d5c36955b71a79","__wbg_async_19c0400d97cc72fe","__wbg_value_571d60108110e917","__wbindgen_link_fc1eedd35dc7e0a6","encodeURIComponent","__wbg_new_d1187ae36d662ef9","__wbg_setonmessage_503809e5bb51bd33","onmessage","__wbg_of_6a70eed8d41f469c","of","__wbg_postMessage_7380d10e8b8269df","__wbg_data_3ce7c145ca4fbcdc","data","__wbg_newwithstrandinit_3fd6fba4083ff2d0","Request","__wbg_responseText_c67ed2d48db10769","responseText","__wbindgen_closure_wrapper5837","__wbindgen_closure_wrapper5862","__wbg_init_memory","maybe_memory","Memory","initial","maximum","shared","__wbg_finalize_init","exports","__wbindgen_start","initSync","Module","input","URL","freeze","__proto__","Metadata$1","ProgramManager","ProgramManager$1","RecordCiphertext$1","default","wasm_path","wasmInitThreadPool","Private","opt","importHook","serverPath","initializeHook","final_path","Cargo","threads","navigator","hardwareConcurrency","info"],"sourceRoot":""} \ No newline at end of file diff --git a/968.bundle.js b/968.bundle.js index c0fe68b2e..1ecacf17f 100644 --- a/968.bundle.js +++ b/968.bundle.js @@ -1,2 +1,2 @@ -(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,879,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={968:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,879,312].map(c.e,c)).then(n);c.x()})(); +(()=>{var r,e,t,o,a,n,p={},i={};function c(r){var e=i[r];if(void 0!==e)return e.exports;var t=i[r]={exports:{}};return p[r].call(t.exports,t,t.exports,c),t.exports}c.m=p,c.x=()=>{var r=c.O(void 0,[357,857,312],(()=>c(4312)));return r=c.O(r)},r="function"==typeof Symbol?Symbol("webpack queues"):"__webpack_queues__",e="function"==typeof Symbol?Symbol("webpack exports"):"__webpack_exports__",t="function"==typeof Symbol?Symbol("webpack error"):"__webpack_error__",o=r=>{r&&r.d<1&&(r.d=1,r.forEach((r=>r.r--)),r.forEach((r=>r.r--?r.r++:r())))},c.a=(a,n,p)=>{var i;p&&((i=[]).d=-1);var c,s,l,f=new Set,u=a.exports,b=new Promise(((r,e)=>{l=e,s=r}));b[e]=u,b[r]=r=>(i&&r(i),f.forEach(r),b.catch((r=>{}))),a.exports=b,n((a=>{var n;c=(a=>a.map((a=>{if(null!==a&&"object"==typeof a){if(a[r])return a;if(a.then){var n=[];n.d=0,a.then((r=>{p[e]=r,o(n)}),(r=>{p[t]=r,o(n)}));var p={};return p[r]=r=>r(n),p}}var i={};return i[r]=r=>{},i[e]=a,i})))(a);var p=()=>c.map((r=>{if(r[t])throw r[t];return r[e]})),s=new Promise((e=>{(n=()=>e(p)).r=0;var t=r=>r!==i&&!f.has(r)&&(f.add(r),r&&!r.d&&(n.r++,r.push(n)));c.map((e=>e[r](t)))}));return n.r?s:p()}),(r=>(r?l(b[t]=r):s(u),o(i)))),i&&i.d<0&&(i.d=0)},a=[],c.O=(r,e,t,o)=>{if(!e){var n=1/0;for(l=0;l=o)&&Object.keys(c.O).every((r=>c.O[r](e[i])))?e.splice(i--,1):(p=!1,o0&&a[l-1][2]>o;l--)a[l]=a[l-1];a[l]=[e,t,o]},c.d=(r,e)=>{for(var t in e)c.o(e,t)&&!c.o(r,t)&&Object.defineProperty(r,t,{enumerable:!0,get:e[t]})},c.f={},c.e=r=>Promise.all(Object.keys(c.f).reduce(((e,t)=>(c.f[t](r,e),e)),[])),c.u=r=>r+".bundle.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(r){if("object"==typeof window)return window}}(),c.o=(r,e)=>Object.prototype.hasOwnProperty.call(r,e),(()=>{var r;c.g.importScripts&&(r=c.g.location+"");var e=c.g.document;if(!r&&e&&(e.currentScript&&"SCRIPT"===e.currentScript.tagName.toUpperCase()&&(r=e.currentScript.src),!r)){var t=e.getElementsByTagName("script");if(t.length)for(var o=t.length-1;o>-1&&(!r||!/^http(s?):/.test(r));)r=t[o--].src}if(!r)throw new Error("Automatic publicPath is not supported in this browser");r=r.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),c.p=r})(),(()=>{c.b=self.location+"";var r={968:1};c.f.i=(e,t)=>{r[e]||importScripts(c.p+c.u(e))};var e=self.webpackChunkaleo_website=self.webpackChunkaleo_website||[],t=e.push.bind(e);e.push=e=>{var[o,a,n]=e;for(var p in a)c.o(a,p)&&(c.m[p]=a[p]);for(n&&n(c);o.length;)r[o.pop()]=1;t(e)}})(),n=c.x,c.x=()=>Promise.all([357,857,312].map(c.e,c)).then(n);c.x()})(); //# sourceMappingURL=968.bundle.js.map \ No newline at end of file diff --git a/968.bundle.js.map b/968.bundle.js.map index 46ef2999e..7f5a28652 100644 --- a/968.bundle.js.map +++ b/968.bundle.js.map @@ -1 +1 @@ -{"version":3,"file":"968.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,I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ded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,879,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,879,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t968: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file +{"version":3,"file":"968.bundle.js","mappings":"UAAIA,EACAC,EACAC,EACAC,ECHAC,ECAAC,E,KCCAC,EAA2B,CAAC,EAGhC,SAASC,EAAoBC,GAE5B,IAAIC,EAAeH,EAAyBE,GAC5C,QAAqBE,IAAjBD,EACH,OAAOA,EAAaE,QAGrB,IAAIC,EAASN,EAAyBE,GAAY,CAGjDG,QAAS,CAAC,GAOX,OAHAE,EAAoBL,GAAUM,KAAKF,EAAOD,QAASC,EAAQA,EAAOD,QAASJ,GAGpEK,EAAOD,OACf,CAGAJ,E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AAUL,EAASM,qBAAqB,UAC5C,GAAGD,EAAQnC,OAEV,IADA,IAAID,EAAIoC,EAAQnC,OAAS,EAClBD,GAAK,KAAO4B,IAAc,aAAaU,KAAKV,KAAaA,EAAYQ,EAAQpC,KAAKmC,GAE3F,CAID,IAAKP,EAAW,MAAM,IAAIW,MAAM,yDAChCX,EAAYA,EAAUY,QAAQ,OAAQ,IAAIA,QAAQ,QAAS,IAAIA,QAAQ,YAAa,KACpF1F,EAAoB2F,EAAIb,C,WClBxB9E,EAAoB4F,EAAIC,KAAKb,SAAW,GAIxC,IAAIc,EAAkB,CACrB,IAAK,GAgBN9F,EAAoBgE,EAAEd,EAAI,CAACe,EAASG,KAE/B0B,EAAgB7B,IAElBc,cAAc/E,EAAoB2F,EAAI3F,EAAoBqE,EAAEJ,GAE9D,EAGD,IAAI8B,EAAqBF,KAA+B,yBAAIA,KAA+B,0BAAK,GAC5FG,EAA6BD,EAAmBpD,KAAKsD,KAAKF,GAC9DA,EAAmBpD,KAvBCuD,IACnB,IAAKpD,EAAUqD,EAAaC,GAAWF,EACvC,IAAI,IAAIjG,KAAYkG,EAChBnG,EAAoB4D,EAAEuC,EAAalG,KACrCD,EAAoBQ,EAAEP,GAAYkG,EAAYlG,IAIhD,IADGmG,GAASA,EAAQpG,GACd8C,EAASK,QACd2C,EAAgBhD,EAASuD,OAAS,EACnCL,EAA2BE,EAAK,C,KRnB7BpG,EAAOE,EAAoBS,EAC/BT,EAAoBS,EAAI,IAChBkB,QAAQuC,IAAI,CAAC,IAAI,IAAI,KAAKnC,IAAI/B,EAAoBmC,EAAGnC,IAAsBiC,KAAKnC,GSD9DE,EAAoBS,G","sources":["webpack://aleo-website/webpack/runtime/async module","webpack://aleo-website/webpack/runtime/chunk loaded","webpack://aleo-website/webpack/runtime/startup chunk dependencies","webpack://aleo-website/webpack/bootstrap","webpack://aleo-website/webpack/runtime/define property getters","webpack://aleo-website/webpack/runtime/ensure chunk","webpack://aleo-website/webpack/runtime/get javascript chunk filename","webpack://aleo-website/webpack/runtime/global","webpack://aleo-website/webpack/runtime/hasOwnProperty shorthand","webpack://aleo-website/webpack/runtime/publicPath","webpack://aleo-website/webpack/runtime/importScripts chunk loading","webpack://aleo-website/webpack/startup"],"sourcesContent":["var webpackQueues = typeof Symbol === \"function\" ? Symbol(\"webpack queues\") : \"__webpack_queues__\";\nvar webpackExports = typeof Symbol === \"function\" ? Symbol(\"webpack exports\") : \"__webpack_exports__\";\nvar webpackError = typeof Symbol === \"function\" ? Symbol(\"webpack error\") : \"__webpack_error__\";\nvar resolveQueue = (queue) => {\n\tif(queue && queue.d < 1) {\n\t\tqueue.d = 1;\n\t\tqueue.forEach((fn) => (fn.r--));\n\t\tqueue.forEach((fn) => (fn.r-- ? fn.r++ : fn()));\n\t}\n}\nvar wrapDeps = (deps) => (deps.map((dep) => {\n\tif(dep !== null && typeof dep === \"object\") {\n\t\tif(dep[webpackQueues]) return dep;\n\t\tif(dep.then) {\n\t\t\tvar queue = [];\n\t\t\tqueue.d = 0;\n\t\t\tdep.then((r) => {\n\t\t\t\tobj[webpackExports] = r;\n\t\t\t\tresolveQueue(queue);\n\t\t\t}, (e) => {\n\t\t\t\tobj[webpackError] = e;\n\t\t\t\tresolveQueue(queue);\n\t\t\t});\n\t\t\tvar obj = {};\n\t\t\tobj[webpackQueues] = (fn) => (fn(queue));\n\t\t\treturn obj;\n\t\t}\n\t}\n\tvar ret = {};\n\tret[webpackQueues] = x => {};\n\tret[webpackExports] = dep;\n\treturn ret;\n}));\n__webpack_require__.a = (module, body, hasAwait) => {\n\tvar queue;\n\thasAwait && ((queue = []).d = -1);\n\tvar depQueues = new Set();\n\tvar exports = module.exports;\n\tvar currentDeps;\n\tvar outerResolve;\n\tvar reject;\n\tvar promise = new Promise((resolve, rej) => {\n\t\treject = rej;\n\t\touterResolve = resolve;\n\t});\n\tpromise[webpackExports] = exports;\n\tpromise[webpackQueues] = (fn) => (queue && fn(queue), depQueues.forEach(fn), promise[\"catch\"](x => {}));\n\tmodule.exports = promise;\n\tbody((deps) => {\n\t\tcurrentDeps = wrapDeps(deps);\n\t\tvar fn;\n\t\tvar getResult = () => (currentDeps.map((d) => {\n\t\t\tif(d[webpackError]) throw d[webpackError];\n\t\t\treturn d[webpackExports];\n\t\t}))\n\t\tvar promise = new Promise((resolve) => {\n\t\t\tfn = () => (resolve(getResult));\n\t\t\tfn.r = 0;\n\t\t\tvar fnQueue = (q) => (q !== queue && !depQueues.has(q) && (depQueues.add(q), q && !q.d && (fn.r++, q.push(fn))));\n\t\t\tcurrentDeps.map((dep) => (dep[webpackQueues](fnQueue)));\n\t\t});\n\t\treturn fn.r ? promise : getResult();\n\t}, (err) => ((err ? reject(promise[webpackError] = err) : outerResolve(exports)), resolveQueue(queue)));\n\tqueue && queue.d < 0 && (queue.d = 0);\n};","var deferred = [];\n__webpack_require__.O = (result, chunkIds, fn, priority) => {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar [chunkIds, fn, priority] = deferred[i];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every((key) => (__webpack_require__.O[key](chunkIds[j])))) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([357,857,312].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [357,857,312], () => (__webpack_require__(4312)))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","// define getter functions for harmony exports\n__webpack_require__.d = (exports, definition) => {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".bundle.js\";\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","var scriptUrl;\nif (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + \"\";\nvar document = __webpack_require__.g.document;\nif (!scriptUrl && document) {\n\tif (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')\n\t\tscriptUrl = document.currentScript.src;\n\tif (!scriptUrl) {\n\t\tvar scripts = document.getElementsByTagName(\"script\");\n\t\tif(scripts.length) {\n\t\t\tvar i = scripts.length - 1;\n\t\t\twhile (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;\n\t\t}\n\t}\n}\n// When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration\n// or pass an empty string (\"\") and set the __webpack_public_path__ variable from your code to use your own logic.\nif (!scriptUrl) throw new Error(\"Automatic publicPath is not supported in this browser\");\nscriptUrl = scriptUrl.replace(/#.*$/, \"\").replace(/\\?.*$/, \"\").replace(/\\/[^\\/]+$/, \"/\");\n__webpack_require__.p = scriptUrl;","__webpack_require__.b = self.location + \"\";\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t968: 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunkaleo_website\"] = self[\"webpackChunkaleo_website\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n"],"names":["webpackQueues","webpackExports","webpackError","resolveQueue","deferred","next","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","undefined","exports","module","__webpack_modules__","call","m","x","__webpack_exports__","O","Symbol","queue","d","forEach","fn","r","a","body","hasAwait","currentDeps","outerResolve","reject","depQueues","Set","promise","Promise","resolve","rej","deps","map","dep","then","obj","e","ret","wrapDeps","getResult","fnQueue","q","has","add","push","err","result","chunkIds","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","definition","o","defineProperty","enumerable","get","f","chunkId","all","reduce","promises","u","g","globalThis","this","Function","window","prop","prototype","hasOwnProperty","scriptUrl","importScripts","location","document","currentScript","tagName","toUpperCase","src","scripts","getElementsByTagName","test","Error","replace","p","b","self","installedChunks","chunkLoadingGlobal","parentChunkLoadingFunction","bind","data","moreModules","runtime","pop"],"sourceRoot":""} \ No newline at end of file diff --git a/ed5d9d6957e80846ebe2.js b/ed5d9d6957e80846ebe2.js deleted file mode 100644 index e47e3eae1..000000000 --- a/ed5d9d6957e80846ebe2.js +++ /dev/null @@ -1 +0,0 @@ -let _;const t=new Array(128).fill(void 0);function e(_){return t[_]}t.push(void 0,null,!0,!1);let r=t.length;function n(_){const n=e(_);return function(_){_<132||(t[_]=r,r=_)}(_),n}const i="undefined"!=typeof TextDecoder?new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}):{decode:()=>{throw Error("TextDecoder not available")}};"undefined"!=typeof TextDecoder&&i.decode();let o=null;function a(){return null!==o&&o.buffer===_.memory.buffer||(o=new Uint8Array(_.memory.buffer)),o}function s(_,t){return _>>>=0,i.decode(a().slice(_,_+t))}function c(_){r===t.length&&t.push(t.length+1);const e=r;return r=t[e],t[e]=_,e}let g=0;const w="undefined"!=typeof TextEncoder?new TextEncoder("utf-8"):{encode:()=>{throw Error("TextEncoder not available")}};function d(_,t,e){if(void 0===e){const e=w.encode(_),r=t(e.length,1)>>>0;return a().subarray(r,r+e.length).set(e),g=e.length,r}let r=_.length,n=t(r,1)>>>0;const i=a();let o=0;for(;o127)break;i[n+o]=t}if(o!==r){0!==o&&(_=_.slice(o)),n=e(n,r,r=o+3*_.length,1)>>>0;const t=function(_,t){const e=w.encode(_);return t.set(e),{read:_.length,written:e.length}}(_,a().subarray(n+o,n+r));o+=t.written,n=e(n,r,o,1)>>>0}return g=o,n}function b(_){return null==_}let l=null;function u(){return null!==l&&l.buffer===_.memory.buffer||(l=new Int32Array(_.memory.buffer)),l}function f(_){const t=typeof _;if("number"==t||"boolean"==t||null==_)return`${_}`;if("string"==t)return`"${_}"`;if("symbol"==t){const t=_.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=_.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(_)){const t=_.length;let e="[";t>0&&(e+=f(_[0]));for(let r=1;r1))return toString.call(_);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(_)+")"}catch(_){return"Object"}return _ instanceof Error?`${_.name}: ${_.message}\n${_.stack}`:r}const p="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>{_.__wbindgen_export_3.get(t.dtor)(t.a,t.b)}));function y(t,e,r,n){const i={a:t,b:e,cnt:1,dtor:r},o=(...t)=>{i.cnt++;const e=i.a;i.a=0;try{return n(e,i.b,...t)}finally{0==--i.cnt?(_.__wbindgen_export_3.get(i.dtor)(e,i.b),p.unregister(i)):i.a=e}};return o.original=i,p.register(o,i,i),o}function m(t,e,r){_._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__ha51b8a0cd6570266(t,e,c(r))}function h(_,t){if(!(_ instanceof t))throw new Error(`expected instance of ${t.name}`);return _.ptr}function v(_,t){const e=t(1*_.length,1)>>>0;return a().set(_,e/1),g=_.length,e}let k=null;function P(){return null!==k&&k.buffer===_.memory.buffer||(k=new BigInt64Array(_.memory.buffer)),k}function S(_,t){return _>>>=0,a().subarray(_/1,_/1+t)}function V(t,e){try{return t.apply(this,e)}catch(t){_.__wbindgen_exn_store(c(t))}}const x="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_address_free(t>>>0)));class F{static __wrap(_){_>>>=0;const t=Object.create(F.prototype);return t.__wbg_ptr=_,x.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,x.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_address_free(t)}static from_private_key(t){h(t,q);const e=_.address_from_private_key(t.__wbg_ptr);return F.__wrap(e)}static from_view_key(t){h(t,o_);const e=_.address_from_view_key(t.__wbg_ptr);return F.__wrap(e)}static from_string(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.address_from_string(e,r);return F.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.address_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}verify(t,e){const r=v(t,_.__wbindgen_malloc),n=g;h(e,__);return 0!==_.address_verify(this.__wbg_ptr,r,n,e.__wbg_ptr)}}const T="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_execution_free(t>>>0)));class R{static __wrap(_){_>>>=0;const t=Object.create(R.prototype);return t.__wbg_ptr=_,T.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,T.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_execution_free(t)}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.execution_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.execution_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return R.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_executionresponse_free(t>>>0)));class A{static __wrap(_){_>>>=0;const t=Object.create(A.prototype);return t.__wbg_ptr=_,z.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,z.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_executionresponse_free(t)}getOutputs(){return n(_.executionresponse_getOutputs(this.__wbg_ptr))}getExecution(){const t=_.executionresponse_getExecution(this.__wbg_ptr);return 0===t?void 0:R.__wrap(t)}getKeys(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.executionresponse_getKeys(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return M.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getProvingKey(){const t=_.executionresponse_getProvingKey(this.__wbg_ptr);return 0===t?void 0:L.__wrap(t)}getVerifyingKey(){const t=_.executionresponse_getVerifyingKey(this.__wbg_ptr);return n_.__wrap(t)}getFunctionId(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.executionresponse_getFunctionId(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}getProgram(){const t=_.executionresponse_getProgram(this.__wbg_ptr);return D.__wrap(t)}}const O="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_field_free(t>>>0)));class j{static __wrap(_){_>>>=0;const t=Object.create(j.prototype);return t.__wbg_ptr=_,O.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,O.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_field_free(t)}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.field_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.field_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return j.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const K="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_keypair_free(t>>>0)));class M{static __wrap(_){_>>>=0;const t=Object.create(M.prototype);return t.__wbg_ptr=_,K.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,K.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_keypair_free(t)}constructor(t,e){h(t,L);var r=t.__destroy_into_raw();h(e,n_);var n=e.__destroy_into_raw();const i=_.keypair_new(r,n);return this.__wbg_ptr=i>>>0,this}provingKey(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.keypair_provingKey(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return L.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}verifyingKey(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.keypair_verifyingKey(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return n_.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const E="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_metadata_free(t>>>0)));class B{static __wrap(_){_>>>=0;const t=Object.create(B.prototype);return t.__wbg_ptr=_,E.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,E.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_metadata_free(t)}get name(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_name(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set name(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_name(this.__wbg_ptr,e,r)}get locator(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_locator(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set locator(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_locator(this.__wbg_ptr,e,r)}get prover(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_prover(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set prover(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_prover(this.__wbg_ptr,e,r)}get verifier(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_verifier(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set verifier(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_verifier(this.__wbg_ptr,e,r)}get verifyingKey(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.__wbg_get_metadata_verifyingKey(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}set verifyingKey(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;_.__wbg_set_metadata_verifyingKey(this.__wbg_ptr,e,r)}static baseUrl(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.metadata_baseUrl(i);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static bond_public(){const t=_.metadata_bond_public();return B.__wrap(t)}static bond_validator(){const t=_.metadata_bond_validator();return B.__wrap(t)}static claim_unbond_public(){const t=_.metadata_claim_unbond_public();return B.__wrap(t)}static fee_private(){const t=_.metadata_fee_private();return B.__wrap(t)}static fee_public(){const t=_.metadata_fee_public();return B.__wrap(t)}static inclusion(){const t=_.metadata_inclusion();return B.__wrap(t)}static join(){const t=_.metadata_join();return B.__wrap(t)}static set_validator_state(){const t=_.metadata_set_validator_state();return B.__wrap(t)}static split(){const t=_.metadata_split();return B.__wrap(t)}static transfer_private(){const t=_.metadata_transfer_private();return B.__wrap(t)}static transfer_private_to_public(){const t=_.metadata_transfer_private_to_public();return B.__wrap(t)}static transfer_public(){const t=_.metadata_transfer_public();return B.__wrap(t)}static transfer_public_as_signer(){const t=_.metadata_transfer_public_as_signer();return B.__wrap(t)}static transfer_public_to_private(){const t=_.metadata_transfer_public_to_private();return B.__wrap(t)}static unbond_public(){const t=_.metadata_unbond_public();return B.__wrap(t)}}const I="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_offlinequery_free(t>>>0)));class U{static __wrap(_){_>>>=0;const t=Object.create(U.prototype);return t.__wbg_ptr=_,I.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,I.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_offlinequery_free(t)}constructor(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.offlinequery_new(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return this.__wbg_ptr=e>>>0,this}finally{_.__wbindgen_add_to_stack_pointer(16)}}addStatePath(t,e){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g,s=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),c=g;_.offlinequery_addStatePath(i,this.__wbg_ptr,o,a,s,c);var r=u()[i/4+0];if(u()[i/4+1])throw n(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.offlinequery_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.offlinequery_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return U.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const C="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_privatekey_free(t>>>0)));class q{static __wrap(_){_>>>=0;const t=Object.create(q.prototype);return t.__wbg_ptr=_,C.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,C.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_privatekey_free(t)}constructor(){const t=_.privatekey_new();return this.__wbg_ptr=t>>>0,this}static from_seed_unchecked(t){const e=v(t,_.__wbindgen_malloc),r=g,n=_.privatekey_from_seed_unchecked(e,r);return q.__wrap(n)}static from_string(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_from_string(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return q.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.privatekey_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}to_view_key(){const t=_.privatekey_to_view_key(this.__wbg_ptr);return o_.__wrap(t)}to_address(){const t=_.privatekey_to_address(this.__wbg_ptr);return F.__wrap(t)}sign(t){const e=v(t,_.__wbindgen_malloc),r=g,n=_.privatekey_sign(this.__wbg_ptr,e,r);return __.__wrap(n)}static newEncrypted(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_newEncrypted(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return N.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toCiphertext(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekey_toCiphertext(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return N.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromPrivateKeyCiphertext(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16);h(t,N);const a=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g;_.privatekey_fromPrivateKeyCiphertext(o,t.__wbg_ptr,a,s);var r=u()[o/4+0],i=u()[o/4+1];if(u()[o/4+2])throw n(i);return q.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const W="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_privatekeyciphertext_free(t>>>0)));class N{static __wrap(_){_>>>=0;const t=Object.create(N.prototype);return t.__wbg_ptr=_,W.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,W.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_privatekeyciphertext_free(t)}static encryptPrivateKey(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16);h(t,q);const a=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g;_.privatekey_toCiphertext(o,t.__wbg_ptr,a,s);var r=u()[o/4+0],i=u()[o/4+1];if(u()[o/4+2])throw n(i);return N.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}decryptToPrivateKey(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekeyciphertext_decryptToPrivateKey(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return q.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.privatekeyciphertext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.privatekeyciphertext_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return N.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}}const $="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_program_free(t>>>0)));class D{static __wrap(_){_>>>=0;const t=Object.create(D.prototype);return t.__wbg_ptr=_,$.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,$.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_program_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return D.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.program_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}hasFunction(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;return 0!==_.program_hasFunction(this.__wbg_ptr,e,r)}getFunctions(){return n(_.program_getFunctions(this.__wbg_ptr))}getFunctionInputs(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getFunctionInputs(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getMappings(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.program_getMappings(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return n(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getRecordMembers(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getRecordMembers(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}getStructMembers(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.program_getStructMembers(i,this.__wbg_ptr,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static getCreditsProgram(){const t=_.program_getCreditsProgram();return D.__wrap(t)}id(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.program_id(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}address(){try{const r=_.__wbindgen_add_to_stack_pointer(-16);_.program_address(r,this.__wbg_ptr);var t=u()[r/4+0],e=u()[r/4+1];if(u()[r/4+2])throw n(e);return F.__wrap(t)}finally{_.__wbindgen_add_to_stack_pointer(16)}}isEqual(t){h(t,D);return 0!==_.program_isEqual(this.__wbg_ptr,t.__wbg_ptr)}getImports(){return n(_.program_getImports(this.__wbg_ptr))}}const J="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_programmanager_free(t>>>0)));const H="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_provingkey_free(t>>>0)));class L{static __wrap(_){_>>>=0;const t=Object.create(L.prototype);return t.__wbg_ptr=_,H.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,H.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_provingkey_free(t)}isBondPublicProver(){return 0!==_.provingkey_isBondPublicProver(this.__wbg_ptr)}isBondValidatorProver(){return 0!==_.provingkey_isBondValidatorProver(this.__wbg_ptr)}isClaimUnbondPublicProver(){return 0!==_.provingkey_isClaimUnbondPublicProver(this.__wbg_ptr)}isFeePrivateProver(){return 0!==_.provingkey_isFeePrivateProver(this.__wbg_ptr)}isFeePublicProver(){return 0!==_.provingkey_isFeePublicProver(this.__wbg_ptr)}isInclusionProver(){return 0!==_.provingkey_isInclusionProver(this.__wbg_ptr)}isJoinProver(){return 0!==_.provingkey_isJoinProver(this.__wbg_ptr)}isSetValidatorStateProver(){return 0!==_.provingkey_isSetValidatorStateProver(this.__wbg_ptr)}isSplitProver(){return 0!==_.provingkey_isSplitProver(this.__wbg_ptr)}isTransferPrivateProver(){return 0!==_.provingkey_isTransferPrivateProver(this.__wbg_ptr)}isTransferPrivateToPublicProver(){return 0!==_.provingkey_isTransferPrivateToPublicProver(this.__wbg_ptr)}isTransferPublicProver(){return 0!==_.provingkey_isTransferPublicProver(this.__wbg_ptr)}isTransferPublicAsSignerProver(){return 0!==_.provingkey_isTransferPublicAsSignerProver(this.__wbg_ptr)}isTransferPublicToPrivateProver(){return 0!==_.provingkey_isTransferPublicToPrivateProver(this.__wbg_ptr)}isUnbondPublicProver(){return 0!==_.provingkey_isUnbondPublicProver(this.__wbg_ptr)}checksum(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_checksum(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}copy(){const t=_.provingkey_copy(this.__wbg_ptr);return L.__wrap(t)}static fromBytes(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=v(t,_.__wbindgen_malloc),a=g;_.provingkey_fromBytes(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return L.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.provingkey_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return L.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const o=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_toBytes(o,this.__wbg_ptr);var t=u()[o/4+0],e=u()[o/4+1],r=u()[o/4+2];if(u()[o/4+3])throw n(r);var i=S(t,e).slice();return _.__wbindgen_free(t,1*e,1),i}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.provingkey_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const Q="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_recordciphertext_free(t>>>0)));class X{static __wrap(_){_>>>=0;const t=Object.create(X.prototype);return t.__wbg_ptr=_,Q.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Q.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_recordciphertext_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.recordciphertext_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return X.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordciphertext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}decrypt(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16);h(t,o_),_.recordciphertext_decrypt(i,this.__wbg_ptr,t.__wbg_ptr);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return Y.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}isOwner(t){h(t,o_);return 0!==_.recordciphertext_isOwner(this.__wbg_ptr,t.__wbg_ptr)}}const G="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_recordplaintext_free(t>>>0)));class Y{static __wrap(_){_>>>=0;const t=Object.create(Y.prototype);return t.__wbg_ptr=_,G.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,G.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_recordplaintext_free(t)}commitment(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16),a=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,c=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.recordplaintext_commitment(o,this.__wbg_ptr,a,s,c,w);var r=u()[o/4+0],i=u()[o/4+1];if(u()[o/4+2])throw n(i);return j.__wrap(r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.recordplaintext_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return Y.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordplaintext_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}microcredits(){const t=_.recordplaintext_microcredits(this.__wbg_ptr);return BigInt.asUintN(64,t)}nonce(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.recordplaintext_nonce(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}serialNumberString(t,e,r){let i,o;try{const p=_.__wbindgen_add_to_stack_pointer(-16);h(t,q);const y=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g,v=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),k=g;_.recordplaintext_serialNumberString(p,this.__wbg_ptr,t.__wbg_ptr,y,m,v,k);var a=u()[p/4+0],c=u()[p/4+1],w=u()[p/4+2],b=u()[p/4+3],l=a,f=c;if(b)throw l=0,f=0,n(w);return i=l,o=f,s(l,f)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(i,o,1)}}}const Z="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_signature_free(t>>>0)));class __{static __wrap(_){_>>>=0;const t=Object.create(__.prototype);return t.__wbg_ptr=_,Z.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,Z.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_signature_free(t)}static sign(t,e){h(t,q);const r=v(e,_.__wbindgen_malloc),n=g,i=_.privatekey_sign(t.__wbg_ptr,r,n);return __.__wrap(i)}verify(t,e){h(t,F);const r=v(e,_.__wbindgen_malloc),n=g;return 0!==_.signature_verify(this.__wbg_ptr,t.__wbg_ptr,r,n)}static from_string(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.signature_from_string(e,r);return __.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.signature_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const t_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_transaction_free(t>>>0)));class e_{static __wrap(_){_>>>=0;const t=Object.create(e_.prototype);return t.__wbg_ptr=_,t_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,t_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_transaction_free(t)}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.transaction_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return e_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}transactionId(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_transactionId(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}transactionType(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.transaction_transactionType(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const r_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_verifyingkey_free(t>>>0)));class n_{static __wrap(_){_>>>=0;const t=Object.create(n_.prototype);return t.__wbg_ptr=_,r_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,r_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_verifyingkey_free(t)}static bondPublicVerifier(){const t=_.verifyingkey_bondPublicVerifier();return n_.__wrap(t)}static bondValidatorVerifier(){const t=_.verifyingkey_bondValidatorVerifier();return n_.__wrap(t)}static claimUnbondPublicVerifier(){const t=_.verifyingkey_claimUnbondPublicVerifier();return n_.__wrap(t)}static feePrivateVerifier(){const t=_.verifyingkey_feePrivateVerifier();return n_.__wrap(t)}static feePublicVerifier(){const t=_.verifyingkey_feePublicVerifier();return n_.__wrap(t)}static inclusionVerifier(){const t=_.verifyingkey_inclusionVerifier();return n_.__wrap(t)}static joinVerifier(){const t=_.verifyingkey_joinVerifier();return n_.__wrap(t)}static setValidatorStateVerifier(){const t=_.verifyingkey_setValidatorStateVerifier();return n_.__wrap(t)}static splitVerifier(){const t=_.verifyingkey_splitVerifier();return n_.__wrap(t)}static transferPrivateVerifier(){const t=_.verifyingkey_transferPrivateVerifier();return n_.__wrap(t)}static transferPrivateToPublicVerifier(){const t=_.verifyingkey_transferPrivateToPublicVerifier();return n_.__wrap(t)}static transferPublicVerifier(){const t=_.verifyingkey_transferPublicVerifier();return n_.__wrap(t)}static transferPublicAsSignerVerifier(){const t=_.verifyingkey_transferPublicAsSignerVerifier();return n_.__wrap(t)}static transferPublicToPrivateVerifier(){const t=_.verifyingkey_transferPublicToPrivateVerifier();return n_.__wrap(t)}static unbondPublicVerifier(){const t=_.verifyingkey_unbondPublicVerifier();return n_.__wrap(t)}isBondPublicVerifier(){return 0!==_.verifyingkey_isBondPublicVerifier(this.__wbg_ptr)}isBondValidatorVerifier(){return 0!==_.verifyingkey_isBondValidatorVerifier(this.__wbg_ptr)}isClaimUnbondPublicVerifier(){return 0!==_.verifyingkey_isClaimUnbondPublicVerifier(this.__wbg_ptr)}isFeePrivateVerifier(){return 0!==_.verifyingkey_isFeePrivateVerifier(this.__wbg_ptr)}isFeePublicVerifier(){return 0!==_.verifyingkey_isFeePublicVerifier(this.__wbg_ptr)}isInclusionVerifier(){return 0!==_.verifyingkey_isInclusionVerifier(this.__wbg_ptr)}isJoinVerifier(){return 0!==_.verifyingkey_isJoinVerifier(this.__wbg_ptr)}isSetValidatorStateVerifier(){return 0!==_.verifyingkey_isSetValidatorStateVerifier(this.__wbg_ptr)}isSplitVerifier(){return 0!==_.verifyingkey_isSplitVerifier(this.__wbg_ptr)}isTransferPrivateVerifier(){return 0!==_.verifyingkey_isTransferPrivateVerifier(this.__wbg_ptr)}isTransferPrivateToPublicVerifier(){return 0!==_.verifyingkey_isTransferPrivateToPublicVerifier(this.__wbg_ptr)}isTransferPublicVerifier(){return 0!==_.verifyingkey_isTransferPublicVerifier(this.__wbg_ptr)}isTransferPublicAsSignerVerifier(){return 0!==_.verifyingkey_isTransferPublicAsSignerVerifier(this.__wbg_ptr)}isTransferPublicToPrivateVerifier(){return 0!==_.verifyingkey_isTransferPublicToPrivateVerifier(this.__wbg_ptr)}isUnbondPublicVerifier(){return 0!==_.verifyingkey_isUnbondPublicVerifier(this.__wbg_ptr)}checksum(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_checksum(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}copy(){const t=_.verifyingkey_copy(this.__wbg_ptr);return n_.__wrap(t)}static fromBytes(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=v(t,_.__wbindgen_malloc),a=g;_.verifyingkey_fromBytes(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static fromString(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.verifyingkey_fromString(i,o,a);var e=u()[i/4+0],r=u()[i/4+1];if(u()[i/4+2])throw n(r);return n_.__wrap(e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}toBytes(){try{const o=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_toBytes(o,this.__wbg_ptr);var t=u()[o/4+0],e=u()[o/4+1],r=u()[o/4+2];if(u()[o/4+3])throw n(r);var i=S(t,e).slice();return _.__wbindgen_free(t,1*e,1),i}finally{_.__wbindgen_add_to_stack_pointer(16)}}toString(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.verifyingkey_toString(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}}const i_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((t=>_.__wbg_viewkey_free(t>>>0)));class o_{static __wrap(_){_>>>=0;const t=Object.create(o_.prototype);return t.__wbg_ptr=_,i_.register(t,t.__wbg_ptr,t),t}__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,i_.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_viewkey_free(t)}static from_private_key(t){h(t,q);const e=_.privatekey_to_view_key(t.__wbg_ptr);return o_.__wrap(e)}static from_string(t){const e=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),r=g,n=_.viewkey_from_string(e,r);return o_.__wrap(n)}to_string(){let t,e;try{const i=_.__wbindgen_add_to_stack_pointer(-16);_.viewkey_to_string(i,this.__wbg_ptr);var r=u()[i/4+0],n=u()[i/4+1];return t=r,e=n,s(r,n)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(t,e,1)}}to_address(){const t=_.address_from_view_key(this.__wbg_ptr);return F.__wrap(t)}decrypt(t){let e,r;try{const l=_.__wbindgen_add_to_stack_pointer(-16),f=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),p=g;_.viewkey_decrypt(l,this.__wbg_ptr,f,p);var i=u()[l/4+0],o=u()[l/4+1],a=u()[l/4+2],c=u()[l/4+3],w=i,b=o;if(c)throw w=0,b=0,n(a);return e=w,r=b,s(w,b)}finally{_.__wbindgen_add_to_stack_pointer(16),_.__wbindgen_free(e,r,1)}}}function a_(){const t={wbg:{}};return t.wbg.__wbindgen_object_drop_ref=function(_){n(_)},t.wbg.__wbg_new_71801a555ad9f2aa=function(){return V((function(){return c(new XMLHttpRequest)}),arguments)},t.wbg.__wbg_overrideMimeType_ee9c51919ceb418b=function(){return V((function(_,t,r){e(_).overrideMimeType(s(t,r))}),arguments)},t.wbg.__wbg_open_c9eb0cf2c9d95679=function(){return V((function(_,t,r,n,i,o){e(_).open(s(t,r),s(n,i),0!==o)}),arguments)},t.wbg.__wbg_send_80d29985093c1ec5=function(){return V((function(_){e(_).send()}),arguments)},t.wbg.__wbg_response_7c2e2759084f7279=function(){return V((function(_){return c(e(_).response)}),arguments)},t.wbg.__wbg_status_d485fb5a478426fb=function(){return V((function(_){return e(_).status}),arguments)},t.wbg.__wbg_new_72fb9a18b5ae2624=function(){return c(new Object)},t.wbg.__wbindgen_string_new=function(_,t){return c(s(_,t))},t.wbg.__wbg_set_1f9b04f170055d33=function(){return V((function(_,t,r){return Reflect.set(e(_),e(t),e(r))}),arguments)},t.wbg.__wbg_new_ab6fd82b10560829=function(){return V((function(){return c(new Headers)}),arguments)},t.wbg.__wbindgen_object_clone_ref=function(_){return c(e(_))},t.wbg.__wbg_new_0d76b0581eca6298=function(){return V((function(){return c(new AbortController)}),arguments)},t.wbg.__wbg_signal_a61f78a3478fd9bc=function(_){return c(e(_).signal)},t.wbg.__wbg_append_7bfcb4937d1d5e29=function(){return V((function(_,t,r,n,i){e(_).append(s(t,r),s(n,i))}),arguments)},t.wbg.__wbg_instanceof_Response_849eb93e75734b6e=function(_){let t;try{t=e(_)instanceof Response}catch(_){t=!1}return t},t.wbg.__wbg_status_61a01141acd3cf74=function(_){return e(_).status},t.wbg.__wbg_url_5f6dc4009ac5f99d=function(t,r){const n=d(e(r).url,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;u()[t/4+1]=i,u()[t/4+0]=n},t.wbg.__wbg_headers_9620bfada380764a=function(_){return c(e(_).headers)},t.wbg.__wbg_iterator_2cee6dadfd956dfa=function(){return c(Symbol.iterator)},t.wbg.__wbg_get_e3c254076557e348=function(){return V((function(_,t){return c(Reflect.get(e(_),e(t)))}),arguments)},t.wbg.__wbindgen_is_function=function(_){return"function"==typeof e(_)},t.wbg.__wbg_call_27c0f87801dedf93=function(){return V((function(_,t){return c(e(_).call(e(t)))}),arguments)},t.wbg.__wbindgen_is_object=function(_){const t=e(_);return"object"==typeof t&&null!==t},t.wbg.__wbg_next_40fc327bfc8770e6=function(_){return c(e(_).next)},t.wbg.__wbg_next_196c84450b364254=function(){return V((function(_){return c(e(_).next())}),arguments)},t.wbg.__wbg_done_298b57d23c0fc80c=function(_){return e(_).done},t.wbg.__wbg_value_d93c65011f51a456=function(_){return c(e(_).value)},t.wbg.__wbg_abort_2aa7521d5690750e=function(_){e(_).abort()},t.wbg.__wbg_stringify_8887fe74e1c50d81=function(){return V((function(_){return c(JSON.stringify(e(_)))}),arguments)},t.wbg.__wbindgen_string_get=function(t,r){const n=e(r),i="string"==typeof n?n:void 0;var o=b(i)?0:d(i,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;u()[t/4+1]=a,u()[t/4+0]=o},t.wbg.__wbg_log_0159ca40cddf5b15=function(_,t){console.log(s(_,t))},t.wbg.__wbindgen_bigint_from_u64=function(_){return c(BigInt.asUintN(64,_))},t.wbg.__wbg_call_b3ca7c6051f9bec1=function(){return V((function(_,t,r){return c(e(_).call(e(t),e(r)))}),arguments)},t.wbg.__wbindgen_module=function(){return c(g_.__wbindgen_wasm_module)},t.wbg.__wbindgen_memory=function(){return c(_.memory)},t.wbg.__wbg_spawnWorker_f6acaddb2e29dc4a=function(_,t,r,n){return c(function(_,t,e,r){return new Promise((n=>{const i=new Worker(_,{type:"module"});i.addEventListener("message",(_=>{setTimeout((()=>{n(i),i.unref&&i.unref()}),0)}),{capture:!0,once:!0}),i.postMessage({module:t,memory:e,address:r})}))}(e(_),e(t),e(r),n>>>0))},t.wbg.__wbg_executionresponse_new=function(_){return c(A.__wrap(_))},t.wbg.__wbg_keypair_new=function(_){return c(M.__wrap(_))},t.wbg.__wbg_transaction_new=function(_){return c(e_.__wrap(_))},t.wbg.__wbg_newwithlength_66ae46612e7f0234=function(_){return c(new Array(_>>>0))},t.wbg.__wbg_set_d4638f722068f043=function(_,t,r){e(_)[t>>>0]=n(r)},t.wbg.__wbindgen_cb_drop=function(_){const t=n(_).original;if(1==t.cnt--)return t.a=0,!0;return!1},t.wbg.__wbg_new_16b304a2cfa7ff4a=function(){return c(new Array)},t.wbg.__wbg_push_a5b05aedc7234f9f=function(_,t){return e(_).push(e(t))},t.wbg.__wbg_arrayBuffer_29931d52c7206b02=function(){return V((function(_){return c(e(_).arrayBuffer())}),arguments)},t.wbg.__wbg_new_63b92bc8671ed464=function(_){return c(new Uint8Array(e(_)))},t.wbg.__wbg_length_c20a40f15020d68a=function(_){return e(_).length},t.wbg.__wbg_new_81740750da40724f=function(t,e){try{var r={a:t,b:e};const n=new Promise(((t,e)=>{const n=r.a;r.a=0;try{return function(t,e,r,n){_.wasm_bindgen__convert__closures__invoke2_mut__h823ad1ce2c4b384e(t,e,c(r),c(n))}(n,r.b,t,e)}finally{r.a=n}}));return c(n)}finally{r.a=r.b=0}},t.wbg.__wbindgen_number_new=function(_){return c(_)},t.wbg.__wbg_new_abda76e883ba8a5f=function(){return c(new Error)},t.wbg.__wbg_stack_658279fe44541cf6=function(t,r){const n=d(e(r).stack,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;u()[t/4+1]=i,u()[t/4+0]=n},t.wbg.__wbg_error_f851667af71bcfc6=function(t,e){let r,n;try{r=t,n=e,console.error(s(t,e))}finally{_.__wbindgen_free(r,n,1)}},t.wbg.__wbg_buffer_12d079cc21e14bdb=function(_){return c(e(_).buffer)},t.wbg.__wbg_newwithbyteoffsetandlength_aa4a17c33a06e5cb=function(_,t,r){return c(new Uint8Array(e(_),t>>>0,r>>>0))},t.wbg.__wbg_randomFillSync_5c9c955aa56b6049=function(){return V((function(_,t){e(_).randomFillSync(n(t))}),arguments)},t.wbg.__wbg_subarray_a1f73cd4b5b42fe1=function(_,t,r){return c(e(_).subarray(t>>>0,r>>>0))},t.wbg.__wbg_getRandomValues_3aa56aa6edec874c=function(){return V((function(_,t){e(_).getRandomValues(e(t))}),arguments)},t.wbg.__wbg_set_a47bac70306a19a7=function(_,t,r){e(_).set(e(t),r>>>0)},t.wbg.__wbg_crypto_1d1f22824a6a080c=function(_){return c(e(_).crypto)},t.wbg.__wbg_process_4a72847cc503995b=function(_){return c(e(_).process)},t.wbg.__wbg_versions_f686565e586dd935=function(_){return c(e(_).versions)},t.wbg.__wbg_node_104a2ff8d6ea03a2=function(_){return c(e(_).node)},t.wbg.__wbindgen_is_string=function(_){return"string"==typeof e(_)},t.wbg.__wbg_require_cca90b1a94a0255b=function(){return V((function(){return c(module.require)}),arguments)},t.wbg.__wbg_msCrypto_eb05e62b530a1508=function(_){return c(e(_).msCrypto)},t.wbg.__wbg_newwithlength_e9b4878cebadb3d3=function(_){return c(new Uint8Array(_>>>0))},t.wbg.__wbg_length_cd7af8117672b8b8=function(_){return e(_).length},t.wbg.__wbg_get_bd8e338fbd5f5cc8=function(_,t){return c(e(_)[t>>>0])},t.wbg.__wbg_self_ce0dbfc45cf2f5be=function(){return V((function(){return c(self.self)}),arguments)},t.wbg.__wbg_window_c6fb939a7f436783=function(){return V((function(){return c(window.window)}),arguments)},t.wbg.__wbg_globalThis_d1e6af4856ba331b=function(){return V((function(){return c(globalThis.globalThis)}),arguments)},t.wbg.__wbg_global_207b558942527489=function(){return V((function(){return c(global.global)}),arguments)},t.wbg.__wbindgen_is_undefined=function(_){return void 0===e(_)},t.wbg.__wbg_newnoargs_e258087cd0daa0ea=function(_,t){return c(new Function(s(_,t)))},t.wbg.__wbg_has_0af94d20077affa2=function(){return V((function(_,t){return Reflect.has(e(_),e(t))}),arguments)},t.wbg.__wbg_fetch_bc7c8e27076a5c84=function(_){return c(fetch(e(_)))},t.wbg.__wbg_fetch_921fad6ef9e883dd=function(_,t){return c(e(_).fetch(e(t)))},t.wbg.__wbindgen_debug_string=function(t,r){const n=d(f(e(r)),_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;u()[t/4+1]=i,u()[t/4+0]=n},t.wbg.__wbindgen_throw=function(_,t){throw new Error(s(_,t))},t.wbg.__wbindgen_rethrow=function(_){throw n(_)},t.wbg.__wbg_then_a73caa9a87991566=function(_,t,r){return c(e(_).then(e(t),e(r)))},t.wbg.__wbg_then_0c86a60e8fcfe9f6=function(_,t){return c(e(_).then(e(t)))},t.wbg.__wbg_queueMicrotask_481971b0d87f3dd4=function(_){queueMicrotask(e(_))},t.wbg.__wbg_queueMicrotask_3cbae2ec6b6cd3d6=function(_){return c(e(_).queueMicrotask)},t.wbg.__wbg_resolve_b0083a7967828ec8=function(_){return c(Promise.resolve(e(_)))},t.wbg.__wbg_waitAsync_5d743fc9058ba01a=function(){return c(Atomics.waitAsync)},t.wbg.__wbg_new_8cccba86b0f574cb=function(_){return c(new Int32Array(e(_)))},t.wbg.__wbg_waitAsync_46d5c36955b71a79=function(_,t,r){return c(Atomics.waitAsync(e(_),t,r))},t.wbg.__wbg_async_19c0400d97cc72fe=function(_){return e(_).async},t.wbg.__wbg_value_571d60108110e917=function(_){return c(e(_).value)},t.wbg.__wbindgen_link_fc1eedd35dc7e0a6=function(t){const e=d("data:application/javascript,"+encodeURIComponent("onmessage = function (ev) {\n let [ia, index, value] = ev.data;\n ia = new Int32Array(ia.buffer);\n let result = Atomics.wait(ia, index, value);\n postMessage(result);\n };\n "),_.__wbindgen_malloc,_.__wbindgen_realloc),r=g;u()[t/4+1]=r,u()[t/4+0]=e},t.wbg.__wbg_new_d1187ae36d662ef9=function(){return V((function(_,t){return c(new Worker(s(_,t)))}),arguments)},t.wbg.__wbg_setonmessage_503809e5bb51bd33=function(_,t){e(_).onmessage=e(t)},t.wbg.__wbg_of_6a70eed8d41f469c=function(_,t,r){return c(Array.of(e(_),e(t),e(r)))},t.wbg.__wbg_postMessage_7380d10e8b8269df=function(){return V((function(_,t){e(_).postMessage(e(t))}),arguments)},t.wbg.__wbg_data_3ce7c145ca4fbcdc=function(_){return c(e(_).data)},t.wbg.__wbg_newwithstrandinit_3fd6fba4083ff2d0=function(){return V((function(_,t,r){return c(new Request(s(_,t),e(r)))}),arguments)},t.wbg.__wbg_responseText_c67ed2d48db10769=function(){return V((function(t,r){const n=e(r).responseText;var i=b(n)?0:d(n,_.__wbindgen_malloc,_.__wbindgen_realloc),o=g;u()[t/4+1]=o,u()[t/4+0]=i}),arguments)},t.wbg.__wbindgen_closure_wrapper5975=function(_,t,e){return c(y(_,t,622,m))},t.wbg.__wbindgen_closure_wrapper6001=function(_,t,e){return c(y(_,t,622,m))},t}function s_(_,t){_.wbg.memory=t||new WebAssembly.Memory({initial:25,maximum:65536,shared:!0})}function c_(t,e){return _=t.exports,g_.__wbindgen_wasm_module=e,k=null,l=null,o=null,_.__wbindgen_start(),_}async function g_(t,e){if(void 0!==_)return _;const r=a_();("string"==typeof t||"function"==typeof Request&&t instanceof Request||"function"==typeof URL&&t instanceof URL)&&(t=fetch(t)),s_(r,e);const{instance:n,module:i}=await async function(_,t){if("function"==typeof Response&&_ instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(_,t)}catch(t){if("application/wasm"==_.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await _.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(_,t);return e instanceof WebAssembly.Instance?{instance:e,module:_}:e}}(await t,r);return c_(n,i)}var w_=Object.freeze({__proto__:null,Address:F,Execution:R,ExecutionResponse:A,Field:j,KeyPair:M,Metadata:B,OfflineQuery:U,PrivateKey:q,PrivateKeyCiphertext:N,Program:D,ProgramManager:class{__destroy_into_raw(){const _=this.__wbg_ptr;return this.__wbg_ptr=0,J.unregister(this),_}free(){const t=this.__destroy_into_raw();_.__wbg_programmanager_free(t)}static buildDeploymentTransaction(t,e,r,i,o,a,s,w,l){h(t,q);const u=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),f=g;let p=0;b(i)||(h(i,Y),p=i.__destroy_into_raw());var y=b(o)?0:d(o,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g;let v=0;b(s)||(h(s,L),v=s.__destroy_into_raw());let k=0;b(w)||(h(w,n_),k=w.__destroy_into_raw());let P=0;b(l)||(h(l,U),P=l.__destroy_into_raw());return n(_.programmanager_buildDeploymentTransaction(t.__wbg_ptr,u,f,r,p,y,m,b(a)?0:c(a),v,k,P))}static estimateDeploymentFee(t,e){const r=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),i=g;return n(_.programmanager_estimateDeploymentFee(r,i,b(e)?0:c(e)))}static estimateProgramNameCost(t){try{const i=_.__wbindgen_add_to_stack_pointer(-16),o=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),a=g;_.programmanager_estimateProgramNameCost(i,o,a);var e=P()[i/8+0],r=u()[i/4+2];if(u()[i/4+3])throw n(r);return BigInt.asUintN(64,e)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static executeFunctionOffline(t,e,r,i,o,a,s,w,l,u,f){h(t,q);const p=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),y=g,m=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),v=g;let k=0;b(w)||(h(w,L),k=w.__destroy_into_raw());let P=0;b(l)||(h(l,n_),P=l.__destroy_into_raw());var S=b(u)?0:d(u,_.__wbindgen_malloc,_.__wbindgen_realloc),V=g;let x=0;b(f)||(h(f,U),x=f.__destroy_into_raw());return n(_.programmanager_executeFunctionOffline(t.__wbg_ptr,p,y,m,v,c(i),o,a,b(s)?0:c(s),k,P,S,V,x))}static buildExecutionTransaction(t,e,r,i,o,a,s,w,l,u,f,p,y){h(t,q);const m=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),v=g,k=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),P=g;let S=0;b(a)||(h(a,Y),S=a.__destroy_into_raw());var V=b(s)?0:d(s,_.__wbindgen_malloc,_.__wbindgen_realloc),x=g;let F=0;b(l)||(h(l,L),F=l.__destroy_into_raw());let T=0;b(u)||(h(u,n_),T=u.__destroy_into_raw());let R=0;b(f)||(h(f,L),R=f.__destroy_into_raw());let z=0;b(p)||(h(p,n_),z=p.__destroy_into_raw());let A=0;b(y)||(h(y,U),A=y.__destroy_into_raw());return n(_.programmanager_buildExecutionTransaction(t.__wbg_ptr,m,v,k,P,c(i),o,S,V,x,b(w)?0:c(w),F,T,R,z,A))}static estimateExecutionFee(t,e,r,i,o,a,s,w,l){h(t,q);const u=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),f=g,p=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),y=g;var m=b(o)?0:d(o,_.__wbindgen_malloc,_.__wbindgen_realloc),v=g;let k=0;b(s)||(h(s,L),k=s.__destroy_into_raw());let P=0;b(w)||(h(w,n_),P=w.__destroy_into_raw());let S=0;b(l)||(h(l,U),S=l.__destroy_into_raw());return n(_.programmanager_estimateExecutionFee(t.__wbg_ptr,u,f,p,y,c(i),m,v,b(a)?0:c(a),k,P,S))}static estimateFinalizeFee(t,e){try{const o=_.__wbindgen_add_to_stack_pointer(-16),a=d(t,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,c=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.programmanager_estimateFinalizeFee(o,a,s,c,w);var r=P()[o/8+0],i=u()[o/4+2];if(u()[o/4+3])throw n(i);return BigInt.asUintN(64,r)}finally{_.__wbindgen_add_to_stack_pointer(16)}}static buildJoinTransaction(t,e,r,i,o,a,s,c,w,l,u){h(t,q),h(e,Y);var f=e.__destroy_into_raw();h(r,Y);var p=r.__destroy_into_raw();let y=0;b(o)||(h(o,Y),y=o.__destroy_into_raw());var m=b(a)?0:d(a,_.__wbindgen_malloc,_.__wbindgen_realloc),v=g;let k=0;b(s)||(h(s,L),k=s.__destroy_into_raw());let P=0;b(c)||(h(c,n_),P=c.__destroy_into_raw());let S=0;b(w)||(h(w,L),S=w.__destroy_into_raw());let V=0;b(l)||(h(l,n_),V=l.__destroy_into_raw());let x=0;b(u)||(h(u,U),x=u.__destroy_into_raw());return n(_.programmanager_buildJoinTransaction(t.__wbg_ptr,f,p,i,y,m,v,k,P,S,V,x))}static buildSplitTransaction(t,e,r,i,o,a,s){h(t,q),h(r,Y);var c=r.__destroy_into_raw(),w=b(i)?0:d(i,_.__wbindgen_malloc,_.__wbindgen_realloc),l=g;let u=0;b(o)||(h(o,L),u=o.__destroy_into_raw());let f=0;b(a)||(h(a,n_),f=a.__destroy_into_raw());let p=0;b(s)||(h(s,U),p=s.__destroy_into_raw());return n(_.programmanager_buildSplitTransaction(t.__wbg_ptr,e,c,w,l,u,f,p))}static buildTransferTransaction(t,e,r,i,o,a,s,c,w,l,u,f,p){h(t,q);const y=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),m=g,v=d(i,_.__wbindgen_malloc,_.__wbindgen_realloc),k=g;let P=0;b(o)||(h(o,Y),P=o.__destroy_into_raw());let S=0;b(s)||(h(s,Y),S=s.__destroy_into_raw());var V=b(c)?0:d(c,_.__wbindgen_malloc,_.__wbindgen_realloc),x=g;let F=0;b(w)||(h(w,L),F=w.__destroy_into_raw());let T=0;b(l)||(h(l,n_),T=l.__destroy_into_raw());let R=0;b(u)||(h(u,L),R=u.__destroy_into_raw());let z=0;b(f)||(h(f,n_),z=f.__destroy_into_raw());let A=0;b(p)||(h(p,U),A=p.__destroy_into_raw());return n(_.programmanager_buildTransferTransaction(t.__wbg_ptr,e,y,m,v,k,P,a,S,V,x,F,T,R,z,A))}static synthesizeKeyPair(t,e,r,i,o){h(t,q);const a=d(e,_.__wbindgen_malloc,_.__wbindgen_realloc),s=g,w=d(r,_.__wbindgen_malloc,_.__wbindgen_realloc),l=g;return n(_.programmanager_synthesizeKeyPair(t.__wbg_ptr,a,s,w,l,c(i),b(o)?0:c(o)))}},ProvingKey:L,RecordCiphertext:X,RecordPlaintext:Y,Signature:__,Transaction:e_,VerifyingKey:n_,ViewKey:o_,default:g_,initSync:function(t,e){if(void 0!==_)return _;const r=a_();return s_(r,e),t instanceof WebAssembly.Module||(t=new WebAssembly.Module(t)),c_(new WebAssembly.Instance(t,r),t)},initThreadPool:function(t,e){return n(_.initThreadPool(c(t),e))},runRayonThread:function(t){_.runRayonThread(t)},verifyFunctionExecution:function(t,e,r,i){try{const s=_.__wbindgen_add_to_stack_pointer(-16);h(t,R),h(e,n_),h(r,D);const c=d(i,_.__wbindgen_malloc,_.__wbindgen_realloc),w=g;_.verifyFunctionExecution(s,t.__wbg_ptr,e.__wbg_ptr,r.__wbg_ptr,c,w);var o=u()[s/4+0],a=u()[s/4+1];if(u()[s/4+2])throw n(a);return 0!==o}finally{_.__wbindgen_add_to_stack_pointer(16)}}});await async function(_){const[t,{module:e,memory:r,address:n}]=await Promise.all([_,new Promise((_=>{addEventListener("message",(t=>{_(t.data)}),{capture:!0,once:!0})}))]),i=await t({initializeHook:(_,t)=>_(e,r)});postMessage(null),i.runRayonThread(n),close()}((async(_={})=>{let{importHook:t,serverPath:e,initializeHook:r}=_,n="aleo_wasm.wasm";return null!=e&&(n=e+/[^\/\\]*$/.exec(n)[0]),null!=t&&(n=t(n)),null!=r?await r(g_,n):await g_(n),w_})); \ No newline at end of file diff --git a/index.bundle.js b/index.bundle.js index a3ce32b7f..a2c6e10e5 100644 --- a/index.bundle.js +++ b/index.bundle.js @@ -1,3 +1,3 @@ /*! For license information please see index.bundle.js.LICENSE.txt */ -(()=>{var e,t,n,r,o,i,a,l,s={8384:(e,t,n)=>{var r=n(3977),o={"text/plain":"Text","text/html":"Url",default:"Text"};e.exports=function(e,t){var n,i,a,l,s,c,u=!1;t||(t={}),n=t.debug||!1;try{if(a=r(),l=document.createRange(),s=document.getSelection(),(c=document.createElement("span")).textContent=e,c.ariaHidden="true",c.style.all="unset",c.style.position="fixed",c.style.top=0,c.style.clip="rect(0, 0, 0, 0)",c.style.whiteSpace="pre",c.style.webkitUserSelect="text",c.style.MozUserSelect="text",c.style.msUserSelect="text",c.style.userSelect="text",c.addEventListener("copy",(function(r){if(r.stopPropagation(),t.format)if(r.preventDefault(),void 0===r.clipboardData){n&&console.warn("unable to use e.clipboardData"),n&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var i=o[t.format]||o.default;window.clipboardData.setData(i,e)}else r.clipboardData.clearData(),r.clipboardData.setData(t.format,e);t.onCopy&&(r.preventDefault(),t.onCopy(r.clipboardData))})),document.body.appendChild(c),l.selectNodeContents(c),s.addRange(l),!document.execCommand("copy"))throw new Error("copy command was unsuccessful");u=!0}catch(r){n&&console.error("unable to copy using execCommand: ",r),n&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),u=!0}catch(r){n&&console.error("unable to copy using clipboardData: ",r),n&&console.error("falling back to prompt"),i=function(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}("message"in t?t.message:"Copy to clipboard: #{key}, Enter"),window.prompt(i,e)}}finally{s&&("function"==typeof s.removeRange?s.removeRange(l):s.removeAllRanges()),c&&document.body.removeChild(c),a()}return u}},8959:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,i){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(r)for(var l=0;l0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=i),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),t.push(u))}},t}},7238:e=>{e.exports=function(e,t){return t||(t={}),e?(e=String(e.__esModule?e.default:e),/^['"].*['"]$/.test(e)&&(e=e.slice(1,-1)),t.hash&&(e+=t.hash),/["'() \t\n]|(%20)/.test(e)||t.needQuotes?'"'.concat(e.replace(/"/g,'\\"').replace(/\n/g,"\\n"),'"'):e):e}},9849:e=>{e.exports=function(e){var t=e[1],n=e[3];if(!n)return t;if("function"==typeof btoa){var r=btoa(unescape(encodeURIComponent(JSON.stringify(n)))),o="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(r),i="/*# ".concat(o," */");return[t].concat([i]).join("\n")}return[t].join("\n")}},6858:(e,t,n)=>{var r=n(9030).Symbol;e.exports=r},7199:e=>{e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n{e.exports=function(e,t,n,r){var o=-1,i=null==e?0:e.length;for(r&&i&&(n=e[++o]);++o{e.exports=function(e){return e.split("")}},4546:e=>{var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;e.exports=function(e){return e.match(t)||[]}},731:(e,t,n)=>{var r=n(6858),o=n(5310),i=n(2357),a=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?o(e):i(e)}},1235:e=>{e.exports=function(e){return function(t){return null==e?void 0:e[t]}}},1221:e=>{e.exports=function(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(n=n>o?o:n)<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var i=Array(o);++r{var r=n(6858),o=n(7199),i=n(7630),a=n(5771),l=r?r.prototype:void 0,s=l?l.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(i(t))return o(t,e)+"";if(a(t))return s?s.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}},4011:(e,t,n)=>{var r=n(1221);e.exports=function(e,t,n){var o=e.length;return n=void 0===n?o:n,!t&&n>=o?e:r(e,t,n)}},8238:(e,t,n)=>{var r=n(4011),o=n(9537),i=n(5781),a=n(5315);e.exports=function(e){return function(t){t=a(t);var n=o(t)?i(t):void 0,l=n?n[0]:t.charAt(0),s=n?r(n,1).join(""):t.slice(1);return l[e]()+s}}},4208:(e,t,n)=>{var r=n(6963),o=n(1249),i=n(9938),a=RegExp("['’]","g");e.exports=function(e){return function(t){return r(i(o(t).replace(a,"")),e,"")}}},6984:(e,t,n)=>{var r=n(1235)({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae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ports=r},5310:(e,t,n)=>{var r=n(6858),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,l=r?r.toStringTag:void 0;e.exports=function(e){var t=i.call(e,l),n=e[l];try{e[l]=void 0;var r=!0}catch(e){}var o=a.call(e);return r&&(t?e[l]=n:delete e[l]),o}},9537:e=>{var t=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");e.exports=function(e){return t.test(e)}},3757:e=>{var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;e.exports=function(e){return t.test(e)}},2357:e=>{var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},9030:(e,t,n)=>{var r=n(1567),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();e.exports=i},5781:(e,t,n)=>{var r=n(9581),o=n(9537),i=n(4005);e.exports=function(e){return o(e)?i(e):r(e)}},4005:e=>{var t="\\ud800-\\udfff",n="["+t+"]",r="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",o="\\ud83c[\\udffb-\\udfff]",i="[^"+t+"]",a="(?:\\ud83c[\\udde6-\\uddff]){2}",l="[\\ud800-\\udbff][\\udc00-\\udfff]",s="(?:"+r+"|"+o+")"+"?",c="[\\ufe0e\\ufe0f]?",u=c+s+("(?:\\u200d(?:"+[i,a,l].join("|")+")"+c+s+")*"),d="(?:"+[i+r+"?",r,a,l,n].join("|")+")",f=RegExp(o+"(?="+o+")|"+d+u,"g");e.exports=function(e){return e.match(f)||[]}},4074:e=>{var t="\\ud800-\\udfff",n="\\u2700-\\u27bf",r="a-z\\xdf-\\xf6\\xf8-\\xff",o="A-Z\\xc0-\\xd6\\xd8-\\xde",i="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",a="["+i+"]",l="\\d+",s="["+n+"]",c="["+r+"]",u="[^"+t+i+l+n+r+o+"]",d="(?:\\ud83c[\\udde6-\\uddff]){2}",f="[\\ud800-\\udbff][\\udc00-\\udfff]",h="["+o+"]",p="(?:"+c+"|"+u+")",m="(?:"+h+"|"+u+")",g="(?:['’](?:d|ll|m|re|s|t|ve))?",v="(?:['’](?:D|LL|M|RE|S|T|VE))?",y="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",b="[\\ufe0e\\ufe0f]?",w=b+y+("(?:\\u200d(?:"+["[^"+t+"]",d,f].join("|")+")"+b+y+")*"),x="(?:"+[s,d,f].join("|")+")"+w,S=RegExp([h+"?"+c+"+"+g+"(?="+[a,h,"$"].join("|")+")",m+"+"+v+"(?="+[a,h+p,"$"].join("|")+")",h+"?"+p+"+"+g,h+"+"+v,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",l,x].join("|"),"g");e.exports=function(e){return e.match(S)||[]}},7781:(e,t,n)=>{var r=n(8653),o=n(4208)((function(e,t,n){return t=t.toLowerCase(),e+(n?r(t):t)}));e.exports=o},8653:(e,t,n)=>{var r=n(5315),o=n(6981);e.exports=function(e){return o(r(e).toLowerCase())}},1249:(e,t,n)=>{var r=n(6984),o=n(5315),i=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,a=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");e.exports=function(e){return(e=o(e))&&e.replace(i,r).replace(a,"")}},7630:e=>{var t=Array.isArray;e.exports=t},5659:e=>{e.exports=function(e){return null!=e&&"object"==typeof e}},5771:(e,t,n)=>{var r=n(731),o=n(5659);e.exports=function(e){return"symbol"==typeof e||o(e)&&"[object Symbol]"==r(e)}},5315:(e,t,n)=>{var r=n(347);e.exports=function(e){return null==e?"":r(e)}},6981:(e,t,n)=>{var r=n(8238)("toUpperCase");e.exports=r},9938:(e,t,n)=>{var r=n(4546),o=n(3757),i=n(5315),a=n(4074);e.exports=function(e,t,n){return e=i(e),void 0===(t=n?void 0:t)?o(e)?a(e):r(e):e.match(t)||[]}},7226:(e,t)=>{var n,r=Symbol.for("react.element"),o=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),l=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),c=Symbol.for("react.context"),u=Symbol.for("react.server_context"),d=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),h=Symbol.for("react.suspense_list"),p=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),g=Symbol.for("react.offscreen");function v(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case i:case l:case a:case f:case h:return e;default:switch(e=e&&e.$$typeof){case u:case c:case d:case m:case p:case s:return e;default:return t}}case o:return t}}}n=Symbol.for("react.module.reference"),t.ForwardRef=d,t.isFragment=function(e){return v(e)===i},t.isMemo=function(e){return v(e)===p}},6182:(e,t,n)=>{e.exports=n(7226)},3136:(e,t,n)=>{var r=n(3297),o=n(8471);function i(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n