@crossmint/wallets-sdk 0.9.3 → 0.9.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/client.cjs +1 -1
- package/dist/api/client.js +1 -1
- package/dist/api/gen/index.cjs +1 -1
- package/dist/api/gen/index.d.cts +2 -2
- package/dist/api/gen/index.d.ts +2 -2
- package/dist/api/gen/index.js +1 -1
- package/dist/api/gen/sdk.gen.cjs +1 -1
- package/dist/api/gen/sdk.gen.d.cts +74 -56
- package/dist/api/gen/sdk.gen.d.ts +74 -56
- package/dist/api/gen/sdk.gen.js +1 -1
- package/dist/api/gen/types.gen.d.cts +1029 -133
- package/dist/api/gen/types.gen.d.ts +1029 -133
- package/dist/api/index.cjs +1 -1
- package/dist/api/index.js +1 -1
- package/dist/{chunk-RLVUBGGT.js → chunk-4AVSHGKT.js} +1 -1
- package/dist/{chunk-HGPOPQVQ.cjs → chunk-5JSU3LZH.cjs} +1 -1
- package/dist/{chunk-HHOICEVA.cjs → chunk-6BHU3GBS.cjs} +1 -1
- package/dist/chunk-BHAZGEWK.js +1 -0
- package/dist/{chunk-MMN2ZPO3.cjs → chunk-C6UVNXU5.cjs} +1 -1
- package/dist/{chunk-VZSBSKN7.js → chunk-CQ4XLGLX.js} +1 -1
- package/dist/chunk-DEV3BSLE.js +1 -0
- package/dist/{chunk-3KY6O3QA.cjs → chunk-DHXTAZWS.cjs} +1 -1
- package/dist/{chunk-5QSZ3SEY.cjs → chunk-GAYU7KUH.cjs} +1 -1
- package/dist/{chunk-O6OF5PNG.js → chunk-GGDVM72A.js} +1 -1
- package/dist/chunk-HTEW2JRC.cjs +1 -0
- package/dist/{chunk-BJPO4AK3.cjs → chunk-KQ4EMVOP.cjs} +1 -1
- package/dist/{chunk-UYICQGCV.js → chunk-N7YUUBKV.js} +1 -1
- package/dist/{chunk-325453ZI.js → chunk-Q2EXQLIK.js} +1 -1
- package/dist/chunk-Q3WOEBKN.js +1 -0
- package/dist/{chunk-5JDBEBXJ.cjs → chunk-RIBMRBAF.cjs} +1 -1
- package/dist/{chunk-P2ZP35HN.js → chunk-RVVJFXV3.js} +1 -1
- package/dist/{chunk-RRUTZFK5.cjs → chunk-W44GS6MY.cjs} +1 -1
- package/dist/{chunk-M52IN4NA.cjs → chunk-WFNK46AR.cjs} +1 -1
- package/dist/chunk-WGDN5N3M.cjs +1 -0
- package/dist/{chunk-3I7BC7IV.js → chunk-WTH3C76N.js} +1 -1
- package/dist/{chunk-XVMDY7RY.js → chunk-XII5BD46.js} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/sdk.cjs +1 -1
- package/dist/sdk.js +1 -1
- package/dist/signers/email/email-signer-api-client.cjs +1 -1
- package/dist/signers/email/email-signer-api-client.js +1 -1
- package/dist/signers/email/email.cjs +1 -1
- package/dist/signers/email/email.js +1 -1
- package/dist/signers/email/index.cjs +1 -1
- package/dist/signers/email/index.js +1 -1
- package/dist/signers/index.cjs +1 -1
- package/dist/signers/index.js +1 -1
- package/dist/utils/constants.cjs +1 -1
- package/dist/utils/constants.js +1 -1
- package/dist/wallets/evm.cjs +1 -1
- package/dist/wallets/evm.js +1 -1
- package/dist/wallets/solana.cjs +1 -1
- package/dist/wallets/solana.js +1 -1
- package/dist/wallets/wallet-factory.cjs +1 -1
- package/dist/wallets/wallet-factory.js +1 -1
- package/dist/wallets/wallet.cjs +1 -1
- package/dist/wallets/wallet.js +1 -1
- package/package.json +4 -4
- package/dist/chunk-BFZBDN6N.cjs +0 -1
- package/dist/chunk-EEXASLEV.js +0 -1
- package/dist/chunk-GEPC4YIP.js +0 -1
- package/dist/chunk-LSYXTSVL.js +0 -1
- package/dist/chunk-WDPPBPYX.cjs +0 -1
package/dist/api/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});require('../chunk-6HXIZLEQ.cjs');var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});require('../chunk-6HXIZLEQ.cjs');var _chunkC6UVNXU5cjs = require('../chunk-C6UVNXU5.cjs');require('../chunk-DHXTAZWS.cjs');require('../chunk-CT2UGJEL.cjs');require('../chunk-ECAM5KTH.cjs');require('../chunk-XALFCQKD.cjs');exports.ApiClient = _chunkC6UVNXU5cjs.a;
|
package/dist/api/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import"../chunk-5IFDVB4Y.js";import{a}from"../chunk-
|
|
1
|
+
import"../chunk-5IFDVB4Y.js";import{a}from"../chunk-RVVJFXV3.js";import"../chunk-DEV3BSLE.js";import"../chunk-7ENJXL4H.js";import"../chunk-KBJA7JDT.js";import"../chunk-BW7YYVZE.js";export{a as ApiClient};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as i,c as s}from"./chunk-
|
|
1
|
+
import{b as i,c as s}from"./chunk-DEV3BSLE.js";import{a as n}from"./chunk-7ENJXL4H.js";import{f as t}from"./chunk-BW7YYVZE.js";import{APIKeyUsageOrigin as p,CrossmintApiClient as d}from"@crossmint/common-sdk-base";var a=class extends d{constructor(e){super(e,{internalConfig:{sdkMetadata:{name:s,version:i}}});this.apiPrefix="api/v1/signers"}pregenerateSigner(e){return t(this,null,function*(){let r=yield this.post(`${this.apiPrefix}/derive-public-key`,{body:JSON.stringify({authId:`email:${e}`,keyType:"ed25519"}),headers:this.headers});if(!r.ok){let o=yield r.text();throw new Error(`Failed to fetch public key: ${r.status} ${o}`)}return yield r.json()})}get isServerSide(){return this.parsedAPIKey.usageOrigin===p.SERVER}get environment(){if(!this.parsedAPIKey.isValid)throw new n("Invalid API key");return this.parsedAPIKey.environment}get headers(){return{"Content-Type":"application/json"}}};export{a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkWFNK46ARcjs = require('./chunk-WFNK46AR.cjs');var _chunkDYRSQN7Xcjs = require('./chunk-DYRSQN7X.cjs');var _chunkNVJN7LPYcjs = require('./chunk-NVJN7LPY.cjs');var _chunkTWQ6DA3Ycjs = require('./chunk-TWQ6DA3Y.cjs');var _chunkYO6BJ2DIcjs = require('./chunk-YO6BJ2DI.cjs');var _chunkYAORQK6Rcjs = require('./chunk-YAORQK6R.cjs');function w(r,e){switch(e.type){case"email":return new (0, _chunkWFNK46ARcjs.a)(e);case"api-key":return r==="solana"?new (0, _chunkNVJN7LPYcjs.a)(e):new (0, _chunkYO6BJ2DIcjs.a)(e);case"external-wallet":return r==="solana"?new (0, _chunkTWQ6DA3Ycjs.a)(e):new (0, _chunkYAORQK6Rcjs.a)(e);case"passkey":return new (0, _chunkDYRSQN7Xcjs.a)(e)}}exports.a = w;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkWGDN5N3Mcjs = require('./chunk-WGDN5N3M.cjs');var _chunk5JSU3LZHcjs = require('./chunk-5JSU3LZH.cjs');var _chunkWFNK46ARcjs = require('./chunk-WFNK46AR.cjs');var _chunkNELBLSAVcjs = require('./chunk-NELBLSAV.cjs');var _chunkCT2UGJELcjs = require('./chunk-CT2UGJEL.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var _ox = require('ox');var f=class{constructor(e){this.apiClient=e}getOrCreateWallet(e){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){if(this.apiClient.isServerSide)throw new (0, _chunkCT2UGJELcjs.f)("getOrCreateWallet is not supported on server side");let t=yield this.apiClient.getWallet(`me:${e.chain==="solana"?"solana-smart-wallet":"evm-smart-wallet"}`);return t&&!("error"in t)?(yield this.validateWalletConfig(t,e),this.createWalletInstance(t,e)):this.createWallet(e)})}getWallet(e,t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){if(!this.apiClient.isServerSide)throw new (0, _chunkCT2UGJELcjs.f)("getWallet is not supported on client side, use getOrCreateWallet instead");let i=yield this.apiClient.getWallet(e);if("error"in i)throw new (0, _chunkCT2UGJELcjs.d)(JSON.stringify(i));return this.createWalletInstance(i,t)})}createWallet(e){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var a,n,o,l,p;yield(o=(n=(a=e.options)==null?void 0:a.experimental_callbacks)==null?void 0:n.onWalletCreationStart)==null?void 0:o.call(n);let t;e.chain==="solana"?t={type:"solana-smart-wallet",config:{adminSigner:yield this.configureSigner(e.chain,e.signer)},linkedUser:(l=e.owner)!=null?l:void 0}:t={type:"evm-smart-wallet",config:{adminSigner:yield this.configureSigner(e.chain,e.signer)},linkedUser:(p=e.owner)!=null?p:void 0};let i=yield this.apiClient.createWallet(t);if("error"in i)throw new (0, _chunkCT2UGJELcjs.f)(JSON.stringify(i));return this.createWalletInstance(i,e)})}createWalletInstance(e,t){let i=this.toInternalSignerConfig(e,t.signer);return new (0, _chunkWGDN5N3Mcjs.a)({chain:t.chain,address:e.address,signer:_chunk5JSU3LZHcjs.a.call(void 0, t.chain,i),options:t.options},this.apiClient)}toInternalSignerConfig(e,t){var i,a;if(t==null)throw new (0, _chunkCT2UGJELcjs.f)("Signer is required to create a wallet");switch(t.type){case"api-key":{let n;switch(e.type){case"solana-smart-wallet":n=e.config.adminSigner.address;break;case"evm-smart-wallet":e.config.adminSigner.type==="evm-fireblocks-custodial"&&(n=e.config.adminSigner.address);break}if(n==null)throw new (0, _chunkCT2UGJELcjs.f)("Wallet signer 'api-key' has no address");return{type:"api-key",address:n}}case"external-wallet":return t;case"passkey":if(e.type==="evm-smart-wallet"&&e.config.adminSigner.type==="evm-passkey")return{type:"passkey",id:e.config.adminSigner.id,name:e.config.adminSigner.name,onCreatePasskey:t.onCreatePasskey,onSignWithPasskey:t.onSignWithPasskey};throw new (0, _chunkCT2UGJELcjs.f)("Passkey signer is not supported for this wallet type");case"email":{if(e.type!=="solana-smart-wallet"||e.config.adminSigner.type!=="solana-keypair")throw new (0, _chunkCT2UGJELcjs.f)("Wallet signer 'email' has no address");let n=e.config.adminSigner.address;return{type:"email",email:(a=t.email)!=null?a:(i=this.apiClient.crossmint.experimental_customAuth)==null?void 0:i.email,signerAddress:n,crossmint:this.apiClient.crossmint,onAuthRequired:t.onAuthRequired,_handshakeParent:t._handshakeParent}}default:throw new Error("Invalid signer type")}}configureSigner(e,t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var i;if((t==null?void 0:t.type)==="passkey"){let a=(i=t.name)!=null?i:`Crossmint Wallet ${Date.now()}`,n=t.onCreatePasskey?yield t.onCreatePasskey(a):yield _ox.WebAuthnP256.createCredential({name:a});return{type:"evm-passkey",id:n.id,name:a,publicKey:{x:n.publicKey.x.toString(),y:n.publicKey.y.toString()}}}return yield this.toExternalSignerConfig(e,t)})}toExternalSignerConfig(e,t,i){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var a,n;if(!t||t.type==="api-key")return{type:e==="solana"?"solana-fireblocks-custodial":"evm-fireblocks-custodial"};if(t.type==="external-wallet")return{type:e==="solana"?"solana-keypair":"evm-keypair",address:t.address};if(t.type==="passkey"&&i!=null){if((i==null?void 0:i.type)!=="evm-smart-wallet"||i.config.adminSigner.type!=="evm-passkey")throw new (0, _chunkCT2UGJELcjs.f)("Passkey signer is not supported for this wallet type");return{type:"evm-passkey",id:i.config.adminSigner.id,name:i.config.adminSigner.name,publicKey:{x:i.config.adminSigner.publicKey.x,y:i.config.adminSigner.publicKey.y}}}if(t.type==="email"){let o=(n=t.email)!=null?n:(a=this.apiClient.crossmint.experimental_customAuth)==null?void 0:a.email;if(o==null)throw new Error("Email is required to create a wallet with email signer");if(e!=="solana")throw new Error("Email signer is only supported for Solana wallets");return{type:"solana-keypair",address:yield _chunkWFNK46ARcjs.a.pregenerateSigner(o,this.apiClient.crossmint)}}throw new Error("Invalid signer type")})}validateWalletConfig(e,t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){if(t.owner!=null&&e.linkedUser!=null&&t.owner!==e.linkedUser)throw new (0, _chunkCT2UGJELcjs.f)("Wallet owner does not match existing wallet's linked user");if(e.type!=="solana-smart-wallet"&&e.type!=="evm-smart-wallet")return;let i=yield this.toExternalSignerConfig(t.chain,t.signer,e),a=e.config.adminSigner;if(i&&a){if(i.type!==a.type)throw new (0, _chunkCT2UGJELcjs.f)("The wallet signer type provided in the wallet config does not match the existing wallet's adminSigner type");_chunkNELBLSAVcjs.a.call(void 0, i,a)}})}};exports.a = f;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{d as S}from"./chunk-DEV3BSLE.js";import{c as N,d as E,i as v,m as $,p as T,q as x,r as C,s as O,t as W,u as F,v as P,w as _}from"./chunk-7ENJXL4H.js";import{a as f,b as L,c as l,d as m,e as y,f as p}from"./chunk-BW7YYVZE.js";import{isValidAddress as M}from"@crossmint/common-sdk-base";var w,o,I=class{constructor({chain:t,address:i,owner:r,signer:s,options:n},e){m(this,w);m(this,o);y(this,o,e),this.chain=t,this.address=i,this.owner=r,this.signer=s,y(this,w,n)}static getApiClient(t){return t.apiClient}static getOptions(t){return t.options}get apiClient(){return l(this,o)}get options(){return l(this,w)}balances(t,i){return p(this,null,function*(){let r=yield l(this,o).getBalance(this.address,{chains:i!=null?i:[this.chain],tokens:t});if("error"in r)throw new Error(`Failed to get balances for wallet: ${JSON.stringify(r.error)}`);return r})}unstable_nfts(t){return p(this,null,function*(){return yield l(this,o).unstable_getNfts(L(f({},t),{chain:this.chain,address:this.address}))})}unstable_transactions(){return p(this,null,function*(){return yield l(this,o).getTransactions(this.walletLocator)})}experimental_activity(){return p(this,null,function*(){let t=yield this.apiClient.experimental_activity(this.walletLocator,{chain:this.chain});if("error"in t)throw new Error(`Failed to get activity: ${JSON.stringify(t.error)}`);return t})}send(t,i,r){return p(this,null,function*(){let s=k(t),n=U(i,this.chain),e={recipient:s,amount:r},c=yield l(this,o).send(this.walletLocator,n,e);if("message"in c)throw new x(`Failed to send token: ${JSON.stringify(c.message)}`);return yield this.approveAndWait(c.id)})}addDelegatedSigner(i){return p(this,arguments,function*({signer:t}){var s,n;let r=yield l(this,o).registerSigner(this.walletLocator,{signer:t,chain:this.chain==="solana"?void 0:this.chain});if("error"in r)throw new Error(`Failed to register signer: ${JSON.stringify(r.error)}`);if("transaction"in r){let e=r.transaction.id;yield this.approveAndWait(e)}else{let e=(s=r.chains)==null?void 0:s[this.chain];if((e==null?void 0:e.status)==="awaiting-approval"){let c=((n=e.approvals)==null?void 0:n.pending)||[];yield this.approveSignature(c,e.id),yield this.waitForSignature(e.id);return}if((e==null?void 0:e.status)==="pending"){yield this.waitForSignature(e.id);return}}})}delegatedSigners(){return p(this,null,function*(){var i,r,s;let t=yield l(this,o).getWallet(this.walletLocator);if("error"in t)throw new E(JSON.stringify(t));if(t.type!=="solana-smart-wallet"&&t.type!=="evm-smart-wallet")throw new N(`Wallet type ${t.type} not supported`);return(s=(r=(i=t==null?void 0:t.config)==null?void 0:i.delegatedSigners)==null?void 0:r.map(n=>{let e=n.locator.indexOf(":");return{signer:`external-wallet:${e>=0?n.locator.slice(e+1):n.locator}`}}))!=null?s:[]})}get walletLocator(){return l(this,o).isServerSide?this.address:`me:${this.isSolanaWallet?"solana-smart-wallet":"evm-smart-wallet"}`}get isSolanaWallet(){return this.chain==="solana"}approveAndWait(t,i){return p(this,null,function*(){return yield this.approveTransaction(t,i),yield this.sleep(1e3),yield this.waitForTransaction(t)})}approveTransaction(t,i){return p(this,null,function*(){var g,h,u,b;let r=yield l(this,o).getTransaction(this.walletLocator,t);if(r.error)throw new C(JSON.stringify(r));if(yield(u=(h=(g=l(this,w))==null?void 0:g.experimental_callbacks)==null?void 0:h.onTransactionStart)==null?void 0:u.call(h),this.signer.type==="api-key")return r;let s=(b=r.approvals)==null?void 0:b.pending;if(s==null)return r;let n=[...i!=null?i:[],this.signer],e=yield Promise.all(s.map(d=>{let A=n.find(D=>D.locator()===d.signer);if(A==null)throw new v(`Signer ${d.signer} not found in pending approvals`);let J=r.walletType==="solana-smart-wallet"?r.onChain.transaction:d.message;return A.signTransaction(J)})),c=yield l(this,o).approveTransaction(this.walletLocator,r.id,{approvals:e.map(d=>f({signer:this.signer.locator()},d))});if(c.error)throw new _(JSON.stringify(c));return c})}approveSignature(t,i){return p(this,null,function*(){if(this.isSolanaWallet)throw new Error("Approving signatures is only supported for EVM smart wallets");let r=t.find(n=>n.signer===this.signer.locator());if(!r)throw new v(`Signer ${this.signer.locator()} not found in pending approvals`);let s=yield this.signer.signMessage(r.message);return yield l(this,o).approveSignature(this.walletLocator,i,{approvals:[f({signer:this.signer.locator()},s)]}),s})}waitForSignature(t){return p(this,null,function*(){let i=null;do if(yield new Promise(r=>setTimeout(r,S)),i=yield l(this,o).getSignature(this.walletLocator,t),"error"in i)throw new T(JSON.stringify(i));while(i===null||i.status==="pending");if(i.status==="failed")throw new $("Signature signing failed");if(!i.outputSignature)throw new T("Signature not available");return i.outputSignature})}waitForTransaction(e){return p(this,arguments,function*(t,i=6e4,{backoffMultiplier:r=1.1,maxBackoffMs:s=2e3,initialBackoffMs:n=S}={}){let c=Date.now(),g;do{if(Date.now()-c>i)throw new O("Transaction confirmation timeout");if(g=yield l(this,o).getTransaction(this.walletLocator,t),g.error)throw new C(JSON.stringify(g));yield this.sleep(n),n=Math.min(n*r,s)}while(g.status==="pending");if(g.status==="failed")throw new W(`Transaction sending failed: ${JSON.stringify(g.error)}`);if(g.status==="awaiting-approval")throw new F("Transaction is awaiting approval. Please submit required approvals before waiting for completion.");let h=g.onChain.txId;if(h==null)throw new P("Transaction hash not found on transaction response");return h})}sleep(t){return p(this,null,function*(){return new Promise(i=>setTimeout(i,t))})}};w=new WeakMap,o=new WeakMap;function k(a){if(typeof a=="string")return a;if("email"in a)return`email:${a.email}`;if("x"in a)return`x:${a.x}`;if("twitter"in a)return`twitter:${a.twitter}`;if("phone"in a)return`phoneNumber:${a.phone}`;if("userId"in a)return`userId:${a.userId}`;throw new Error("Invalid recipient locator")}function U(a,t){return M(a)?`${t}:${a}`:`${t}:${a.toLowerCase()}`}export{I as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkDHXTAZWScjs = require('./chunk-DHXTAZWS.cjs');var _chunkCT2UGJELcjs = require('./chunk-CT2UGJEL.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var _commonsdkbase = require('@crossmint/common-sdk-base');var p=class extends _commonsdkbase.CrossmintApiClient{constructor(e){super(e,{internalConfig:{sdkMetadata:{name:_chunkDHXTAZWScjs.c,version:_chunkDHXTAZWScjs.b}}});this.apiPrefix="api/2022-06-09/wallets"}createWallet(e){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let s=this.isServerSide?`${this.apiPrefix}`:`${this.apiPrefix}/me`;return(yield this.post(s,{body:JSON.stringify(e),headers:this.headers})).json()})}getWallet(e){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}`,{headers:this.headers})).json()})}createTransaction(e,s){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/transactions`,{body:JSON.stringify(s),headers:this.headers})).json()})}approveTransaction(e,s,t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/transactions/${s}/approvals`,{body:JSON.stringify(t),headers:this.headers})).json()})}getTransaction(e,s){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}/transactions/${s}`,{headers:this.headers})).json()})}createSignature(e,s){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/signatures`,{body:JSON.stringify(s),headers:this.headers})).json()})}approveSignature(e,s,t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/signatures/${s}/approvals`,{body:JSON.stringify(t),headers:this.headers})).json()})}getSignature(e,s){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}/signatures/${s}`,{headers:this.headers})).json()})}getTransactions(e){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}/transactions`,{headers:this.headers})).json()})}unstable_getNfts(e){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let s=new URLSearchParams;s.append("page",e.page.toString()),s.append("perPage",e.perPage.toString());let t=`${e.chain}:${e.address}`;return(yield this.get(`${this.apiPrefix}/${t}/nfts?${s.toString()}`,{headers:this.headers})).json()})}experimental_activity(e,s){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let t=new URLSearchParams;return t.append("chain",s.chain.toString()),(yield this.get(`${this.apiPrefix}/${e}/activity?${t.toString()}`,{headers:this.headers})).json()})}getBalance(e,s){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let t=new URLSearchParams;return t.append("tokenLocators",s.tokens.join(",")),t.append("chains",s.chains.join(",")),(yield this.get(`api/unstable/wallets/${e}/balances?${t.toString()}`,{headers:this.headers})).json()})}registerSigner(e,s){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/signers`,{body:JSON.stringify(s),headers:this.headers})).json()})}getSigner(e,s){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}/signers/${s}`,{headers:this.headers})).json()})}send(e,s,t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return(yield this.post(`api/unstable/wallets/${e}/tokens/${s}/transfers`,{body:JSON.stringify(t),headers:this.headers})).json()})}get isServerSide(){return this.parsedAPIKey.usageOrigin===_commonsdkbase.APIKeyUsageOrigin.SERVER}get environment(){if(!this.parsedAPIKey.isValid)throw new (0, _chunkCT2UGJELcjs.a)("Invalid API key");return this.parsedAPIKey.environment}get headers(){return{"Content-Type":"application/json"}}};exports.a = p;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as s}from"./chunk-
|
|
1
|
+
import{a as s}from"./chunk-BHAZGEWK.js";import{k as p,o as c,q as f}from"./chunk-7ENJXL4H.js";import{a as w}from"./chunk-BJDS5BJG.js";import{f as r}from"./chunk-BW7YYVZE.js";import{createPublicClient as S,http as E}from"viem";var C=class v extends s{constructor(t){super({chain:t.chain,address:t.address,owner:t.owner,signer:t.signer,options:s.getOptions(t)},s.getApiClient(t))}static from(t){return new v(t)}sendTransaction(t){return r(this,null,function*(){var i;let a=yield this.apiClient.createTransaction(this.walletLocator,{params:{signer:this.signer.locator(),chain:this.chain,calls:[{to:t.to,value:t.value?t.value.toString():"0",data:(i=t.data)!=null?i:"0x"}]}});if("error"in a)throw new f(JSON.stringify(a));return yield this.approveAndWait(a.id)})}signMessage(t){return r(this,null,function*(){var n;let a=yield this.apiClient.createSignature(this.walletLocator,{type:"evm-message",params:{message:t,signer:this.signer.locator(),chain:this.chain}});if("error"in a)throw new c(JSON.stringify(a));let i=a.id,o=((n=a.approvals)==null?void 0:n.pending)||[];return yield this.approveSignature(o,i),yield this.waitForSignature(i)})}createTypedDataSignature(t){return r(this,null,function*(){var u;let{domain:a,message:i,primaryType:o,types:n,chain:d}=t;if(!a||!i||!n||!d)throw new p("Invalid typed data");let{name:g,version:h,chainId:y,verifyingContract:m,salt:D}=a;if(!g||!h||!y||!m)throw new p("Invalid typed data domain");let e=yield this.apiClient.createSignature(this.walletLocator,{type:"evm-typed-data",params:{typedData:{domain:{name:g,version:h,chainId:Number(y),verifyingContract:m,salt:D},message:i,primaryType:o,types:n},signer:this.signer.locator(),chain:d,isSmartWalletSignature:!1}});if("error"in e)throw new c(JSON.stringify(e));let l=e.id,T=((u=e.approvals)==null?void 0:u.pending)||[];return yield this.approveSignature(T,l),yield this.waitForSignature(l)})}getViemClient(t){var a;return S({transport:(a=t==null?void 0:t.transport)!=null?a:E(),chain:w(this.chain)})}};export{C as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var s="@crossmint/wallets-sdk",t="0.9.4";var c="WALLETS_SDK",r=t,d=s,a=500;export{c as a,r as b,d as c,a as d};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var s="@crossmint/wallets-sdk",t="0.9.
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var s="@crossmint/wallets-sdk",t="0.9.4";var p="WALLETS_SDK",c= exports.b =t,r= exports.c =s,d= exports.d =500;exports.a = p; exports.b = c; exports.c = r; exports.d = d;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkWGDN5N3Mcjs = require('./chunk-WGDN5N3M.cjs');var _chunkCT2UGJELcjs = require('./chunk-CT2UGJEL.cjs');var _chunk6VJEBYPNcjs = require('./chunk-6VJEBYPN.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var _viem = require('viem');var C=class v extends _chunkWGDN5N3Mcjs.a{constructor(t){super({chain:t.chain,address:t.address,owner:t.owner,signer:t.signer,options:_chunkWGDN5N3Mcjs.a.getOptions(t)},_chunkWGDN5N3Mcjs.a.getApiClient(t))}static from(t){return new v(t)}sendTransaction(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var i;let a=yield this.apiClient.createTransaction(this.walletLocator,{params:{signer:this.signer.locator(),chain:this.chain,calls:[{to:t.to,value:t.value?t.value.toString():"0",data:(i=t.data)!=null?i:"0x"}]}});if("error"in a)throw new (0, _chunkCT2UGJELcjs.q)(JSON.stringify(a));return yield this.approveAndWait(a.id)})}signMessage(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var n;let a=yield this.apiClient.createSignature(this.walletLocator,{type:"evm-message",params:{message:t,signer:this.signer.locator(),chain:this.chain}});if("error"in a)throw new (0, _chunkCT2UGJELcjs.o)(JSON.stringify(a));let i=a.id,o=((n=a.approvals)==null?void 0:n.pending)||[];return yield this.approveSignature(o,i),yield this.waitForSignature(i)})}createTypedDataSignature(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var u;let{domain:a,message:i,primaryType:o,types:n,chain:d}=t;if(!a||!i||!n||!d)throw new (0, _chunkCT2UGJELcjs.k)("Invalid typed data");let{name:g,version:h,chainId:y,verifyingContract:m,salt:D}=a;if(!g||!h||!y||!m)throw new (0, _chunkCT2UGJELcjs.k)("Invalid typed data domain");let e=yield this.apiClient.createSignature(this.walletLocator,{type:"evm-typed-data",params:{typedData:{domain:{name:g,version:h,chainId:Number(y),verifyingContract:m,salt:D},message:i,primaryType:o,types:n},signer:this.signer.locator(),chain:d,isSmartWalletSignature:!1}});if("error"in e)throw new (0, _chunkCT2UGJELcjs.o)(JSON.stringify(e));let l=e.id,T=((u=e.approvals)==null?void 0:u.pending)||[];return yield this.approveSignature(T,l),yield this.waitForSignature(l)})}getViemClient(t){var a;return _viem.createPublicClient.call(void 0, {transport:(a=t==null?void 0:t.transport)!=null?a:_viem.http.call(void 0, ),chain:_chunk6VJEBYPNcjs.a.call(void 0, this.chain)})}};exports.a = C;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as l}from"./chunk-
|
|
1
|
+
import{a as l}from"./chunk-N7YUUBKV.js";import{a}from"./chunk-RVVJFXV3.js";import{f as e}from"./chunk-BW7YYVZE.js";import{createCrossmint as C}from"@crossmint/common-sdk-base";var i=class o{constructor(t){let r=new a(t);this.walletFactory=new l(r)}static from(t){return new o(t)}getOrCreateWallet(t){return e(this,null,function*(){return yield this.walletFactory.getOrCreateWallet(t)})}getWallet(t,r){return e(this,null,function*(){return yield this.walletFactory.getWallet(t,r)})}createWallet(t){return e(this,null,function*(){return yield this.walletFactory.createWallet(t)})}};export{C as a,i as b};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkSTYSP6KLcjs = require('./chunk-STYSP6KL.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var s=e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/transactions/{transactionId}/approvals"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},i= exports.b =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/transactions/{transactionId}"},e))},C= exports.c =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/transactions"},e))},p= exports.d =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/transactions"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},W= exports.e =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/signers/{signer}"},e))},c= exports.f =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/signers"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},u= exports.g =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/signatures/{signatureId}/approvals"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},V= exports.h =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/signatures/{signatureId}"},e))},w= exports.i =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/signatures"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},T= exports.j =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}/activity"},e))},h= exports.k =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me{walletType}"},e))},g= exports.l =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/me"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},E= exports.m =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/transactions/{transactionId}/approvals"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},S= exports.n =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/transactions/{transactionId}"},e))},O= exports.o =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/transactions"},e))},d= exports.p =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/transactions"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},G= exports.q =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/signers/{signer}"},e))},D= exports.r =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/signers"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},M= exports.s =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/signatures/{signatureId}/approvals"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},R= exports.t =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/signatures/{signatureId}"},e))},b= exports.u =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/signatures"},e))},v= exports.v =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/signatures"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},x= exports.w =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{identifier}/nfts"},e))},y= exports.x =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/balances"},e))},A= exports.y =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/balances"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},m= exports.z =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}/activity"},e))},f= exports.A =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets/{walletLocator}"},e))},L= exports.B =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/v1-alpha2/wallets"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},B= exports.C =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/unstable/wallets/me{walletType}/tokens/{tokenLocator}/transfers"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},F= exports.D =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/unstable/wallets/{walletLocator}/tokens/{tokenLocator}/transfers"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},k= exports.E =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/unstable/wallets/{walletLocator}/balances"},e))},q= exports.F =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/transactions/{transactionId}/approvals"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},j= exports.G =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/transactions/{transactionId}"},e))},I= exports.H =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/transactions"},e))},U= exports.I =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/transactions"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},_= exports.J =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/signers/{signer}"},e))},z= exports.K =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/signers"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},H= exports.L =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/signatures/{signatureId}/approvals"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},J= exports.M =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/signatures/{signatureId}"},e))},K= exports.N =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/signatures"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},N= exports.O =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}/activity"},e))},P= exports.P =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me{walletType}"},e))},Q= exports.Q =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/me"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},X= exports.R =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/transactions/{transactionId}/approvals"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},Y= exports.S =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/transactions/{transactionId}"},e))},Z= exports.T =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/transactions"},e))},$= exports.U =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/transactions"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},ee= exports.V =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/signers/{signer}"},e))},re= exports.W =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/signers"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},te= exports.X =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/signatures/{signatureId}/approvals"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},le= exports.Y =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/signatures/{signatureId}"},e))},oe= exports.Z =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/signatures"},e))},ae= exports._ =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/signatures"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))},ne= exports.$ =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}/activity"},e))},se= exports.aa =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).get(_chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets/{walletLocator}"},e))},ie= exports.ba =e=>{var r;return((r=e.client)!=null?r:_chunkSTYSP6KLcjs.a).post(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {url:"/2022-06-09/wallets"},e),{headers:_chunkXALFCQKDcjs.a.call(void 0, {"Content-Type":"application/json"},e.headers)}))};exports.a = s; exports.b = i; exports.c = C; exports.d = p; exports.e = W; exports.f = c; exports.g = u; exports.h = V; exports.i = w; exports.j = T; exports.k = h; exports.l = g; exports.m = E; exports.n = S; exports.o = O; exports.p = d; exports.q = G; exports.r = D; exports.s = M; exports.t = R; exports.u = b; exports.v = v; exports.w = x; exports.x = y; exports.y = A; exports.z = m; exports.A = f; exports.B = L; exports.C = B; exports.D = F; exports.E = k; exports.F = q; exports.G = j; exports.H = I; exports.I = U; exports.J = _; exports.K = z; exports.L = H; exports.M = J; exports.N = K; exports.O = N; exports.P = P; exports.Q = Q; exports.R = X; exports.S = Y; exports.T = Z; exports.U = $; exports.V = ee; exports.W = re; exports.X = te; exports.Y = le; exports.Z = oe; exports._ = ae; exports.$ = ne; exports.aa = se; exports.ba = ie;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunk6BHU3GBScjs = require('./chunk-6BHU3GBS.cjs');var _chunkC6UVNXU5cjs = require('./chunk-C6UVNXU5.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var _commonsdkbase = require('@crossmint/common-sdk-base');var i=class o{constructor(t){let r=new (0, _chunkC6UVNXU5cjs.a)(t);this.walletFactory=new (0, _chunk6BHU3GBScjs.a)(r)}static from(t){return new o(t)}getOrCreateWallet(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return yield this.walletFactory.getOrCreateWallet(t)})}getWallet(t,r){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return yield this.walletFactory.getWallet(t,r)})}createWallet(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return yield this.walletFactory.createWallet(t)})}};exports.a = _commonsdkbase.createCrossmint; exports.b = i;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as d}from"./chunk-
|
|
1
|
+
import{a as d}from"./chunk-BHAZGEWK.js";import{a as y}from"./chunk-Q2EXQLIK.js";import{a as m}from"./chunk-XII5BD46.js";import{a as C}from"./chunk-NBXRBYNJ.js";import{d as c,f as r}from"./chunk-7ENJXL4H.js";import{f as s}from"./chunk-BW7YYVZE.js";import{WebAuthnP256 as h}from"ox";var f=class{constructor(e){this.apiClient=e}getOrCreateWallet(e){return s(this,null,function*(){if(this.apiClient.isServerSide)throw new r("getOrCreateWallet is not supported on server side");let t=yield this.apiClient.getWallet(`me:${e.chain==="solana"?"solana-smart-wallet":"evm-smart-wallet"}`);return t&&!("error"in t)?(yield this.validateWalletConfig(t,e),this.createWalletInstance(t,e)):this.createWallet(e)})}getWallet(e,t){return s(this,null,function*(){if(!this.apiClient.isServerSide)throw new r("getWallet is not supported on client side, use getOrCreateWallet instead");let i=yield this.apiClient.getWallet(e);if("error"in i)throw new c(JSON.stringify(i));return this.createWalletInstance(i,t)})}createWallet(e){return s(this,null,function*(){var a,n,o,l,p;yield(o=(n=(a=e.options)==null?void 0:a.experimental_callbacks)==null?void 0:n.onWalletCreationStart)==null?void 0:o.call(n);let t;e.chain==="solana"?t={type:"solana-smart-wallet",config:{adminSigner:yield this.configureSigner(e.chain,e.signer)},linkedUser:(l=e.owner)!=null?l:void 0}:t={type:"evm-smart-wallet",config:{adminSigner:yield this.configureSigner(e.chain,e.signer)},linkedUser:(p=e.owner)!=null?p:void 0};let i=yield this.apiClient.createWallet(t);if("error"in i)throw new r(JSON.stringify(i));return this.createWalletInstance(i,e)})}createWalletInstance(e,t){let i=this.toInternalSignerConfig(e,t.signer);return new d({chain:t.chain,address:e.address,signer:y(t.chain,i),options:t.options},this.apiClient)}toInternalSignerConfig(e,t){var i,a;if(t==null)throw new r("Signer is required to create a wallet");switch(t.type){case"api-key":{let n;switch(e.type){case"solana-smart-wallet":n=e.config.adminSigner.address;break;case"evm-smart-wallet":e.config.adminSigner.type==="evm-fireblocks-custodial"&&(n=e.config.adminSigner.address);break}if(n==null)throw new r("Wallet signer 'api-key' has no address");return{type:"api-key",address:n}}case"external-wallet":return t;case"passkey":if(e.type==="evm-smart-wallet"&&e.config.adminSigner.type==="evm-passkey")return{type:"passkey",id:e.config.adminSigner.id,name:e.config.adminSigner.name,onCreatePasskey:t.onCreatePasskey,onSignWithPasskey:t.onSignWithPasskey};throw new r("Passkey signer is not supported for this wallet type");case"email":{if(e.type!=="solana-smart-wallet"||e.config.adminSigner.type!=="solana-keypair")throw new r("Wallet signer 'email' has no address");let n=e.config.adminSigner.address;return{type:"email",email:(a=t.email)!=null?a:(i=this.apiClient.crossmint.experimental_customAuth)==null?void 0:i.email,signerAddress:n,crossmint:this.apiClient.crossmint,onAuthRequired:t.onAuthRequired,_handshakeParent:t._handshakeParent}}default:throw new Error("Invalid signer type")}}configureSigner(e,t){return s(this,null,function*(){var i;if((t==null?void 0:t.type)==="passkey"){let a=(i=t.name)!=null?i:`Crossmint Wallet ${Date.now()}`,n=t.onCreatePasskey?yield t.onCreatePasskey(a):yield h.createCredential({name:a});return{type:"evm-passkey",id:n.id,name:a,publicKey:{x:n.publicKey.x.toString(),y:n.publicKey.y.toString()}}}return yield this.toExternalSignerConfig(e,t)})}toExternalSignerConfig(e,t,i){return s(this,null,function*(){var a,n;if(!t||t.type==="api-key")return{type:e==="solana"?"solana-fireblocks-custodial":"evm-fireblocks-custodial"};if(t.type==="external-wallet")return{type:e==="solana"?"solana-keypair":"evm-keypair",address:t.address};if(t.type==="passkey"&&i!=null){if((i==null?void 0:i.type)!=="evm-smart-wallet"||i.config.adminSigner.type!=="evm-passkey")throw new r("Passkey signer is not supported for this wallet type");return{type:"evm-passkey",id:i.config.adminSigner.id,name:i.config.adminSigner.name,publicKey:{x:i.config.adminSigner.publicKey.x,y:i.config.adminSigner.publicKey.y}}}if(t.type==="email"){let o=(n=t.email)!=null?n:(a=this.apiClient.crossmint.experimental_customAuth)==null?void 0:a.email;if(o==null)throw new Error("Email is required to create a wallet with email signer");if(e!=="solana")throw new Error("Email signer is only supported for Solana wallets");return{type:"solana-keypair",address:yield m.pregenerateSigner(o,this.apiClient.crossmint)}}throw new Error("Invalid signer type")})}validateWalletConfig(e,t){return s(this,null,function*(){if(t.owner!=null&&e.linkedUser!=null&&t.owner!==e.linkedUser)throw new r("Wallet owner does not match existing wallet's linked user");if(e.type!=="solana-smart-wallet"&&e.type!=="evm-smart-wallet")return;let i=yield this.toExternalSignerConfig(t.chain,t.signer,e),a=e.config.adminSigner;if(i&&a){if(i.type!==a.type)throw new r("The wallet signer type provided in the wallet config does not match the existing wallet's adminSigner type");C(i,a)}})}};export{f as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as n}from"./chunk-
|
|
1
|
+
import{a as n}from"./chunk-XII5BD46.js";import{a as i}from"./chunk-OV4CFQ36.js";import{a as o}from"./chunk-77QBSFHG.js";import{a}from"./chunk-LFYI7K4T.js";import{a as l}from"./chunk-2KK65AC6.js";import{a as t}from"./chunk-R7KEBAQ2.js";function f(r,e){switch(e.type){case"email":return new n(e);case"api-key":return r==="solana"?new o(e):new l(e);case"external-wallet":return r==="solana"?new a(e):new t(e);case"passkey":return new i(e)}}export{f as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as l}from"./chunk-5M7IRODB.js";import{a as t,b as o}from"./chunk-BW7YYVZE.js";var i=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/me{walletType}/transactions/{transactionId}/approvals"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},C=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/me{walletType}/transactions/{transactionId}"},e))},p=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/me{walletType}/transactions"},e))},W=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/me{walletType}/transactions"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},c=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/me{walletType}/signers/{signer}"},e))},u=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/me{walletType}/signers"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},V=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/me{walletType}/signatures/{signatureId}/approvals"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},w=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/me{walletType}/signatures/{signatureId}"},e))},T=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/me{walletType}/signatures"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},h=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/me{walletType}/activity"},e))},g=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/me{walletType}"},e))},E=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/me"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},S=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/{walletLocator}/transactions/{transactionId}/approvals"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},O=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/{walletLocator}/transactions/{transactionId}"},e))},d=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/{walletLocator}/transactions"},e))},G=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/{walletLocator}/transactions"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},D=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/{walletLocator}/signers/{signer}"},e))},M=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/{walletLocator}/signers"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},R=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/{walletLocator}/signatures/{signatureId}/approvals"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},b=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/{walletLocator}/signatures/{signatureId}"},e))},v=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/{walletLocator}/signatures"},e))},x=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/{walletLocator}/signatures"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},y=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/{identifier}/nfts"},e))},A=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/{walletLocator}/balances"},e))},m=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets/{walletLocator}/balances"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},f=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/{walletLocator}/activity"},e))},L=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/v1-alpha2/wallets/{walletLocator}"},e))},B=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/v1-alpha2/wallets"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},F=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/unstable/wallets/me{walletType}/tokens/{tokenLocator}/transfers"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},k=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/unstable/wallets/{walletLocator}/tokens/{tokenLocator}/transfers"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},q=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/unstable/wallets/{walletLocator}/balances"},e))},j=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/me{walletType}/transactions/{transactionId}/approvals"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},I=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/me{walletType}/transactions/{transactionId}"},e))},U=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/me{walletType}/transactions"},e))},_=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/me{walletType}/transactions"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},z=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/me{walletType}/signers/{signer}"},e))},H=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/me{walletType}/signers"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},J=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/me{walletType}/signatures/{signatureId}/approvals"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},K=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/me{walletType}/signatures/{signatureId}"},e))},N=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/me{walletType}/signatures"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},P=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/me{walletType}/activity"},e))},Q=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/me{walletType}"},e))},X=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/me"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},Y=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/{walletLocator}/transactions/{transactionId}/approvals"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},Z=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/{walletLocator}/transactions/{transactionId}"},e))},$=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/{walletLocator}/transactions"},e))},ee=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/{walletLocator}/transactions"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},re=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/{walletLocator}/signers/{signer}"},e))},te=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/{walletLocator}/signers"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},le=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/{walletLocator}/signatures/{signatureId}/approvals"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},oe=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/{walletLocator}/signatures/{signatureId}"},e))},ae=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/{walletLocator}/signatures"},e))},ne=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets/{walletLocator}/signatures"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))},se=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/{walletLocator}/activity"},e))},ie=e=>{var r;return((r=e.client)!=null?r:l).get(t({url:"/2022-06-09/wallets/{walletLocator}"},e))},Ce=e=>{var r;return((r=e.client)!=null?r:l).post(o(t({url:"/2022-06-09/wallets"},e),{headers:t({"Content-Type":"application/json"},e.headers)}))};export{i as a,C as b,p as c,W as d,c as e,u as f,V as g,w as h,T as i,h as j,g as k,E as l,S as m,O as n,d as o,G as p,D as q,M as r,R as s,b as t,v as u,x as v,y as w,A as x,m as y,f as z,L as A,B,F as C,k as D,q as E,j as F,I as G,U as H,_ as I,z as J,H as K,J as L,K as M,N,P as O,Q as P,X as Q,Y as R,Z as S,$ as T,ee as U,re as V,te as W,le as X,oe as Y,ae as Z,ne as _,se as $,ie as aa,Ce as ba};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var _chunkWGDN5N3Mcjs = require('./chunk-WGDN5N3M.cjs');var _chunkTWQ6DA3Ycjs = require('./chunk-TWQ6DA3Y.cjs');var _chunkCT2UGJELcjs = require('./chunk-CT2UGJEL.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var _bs58 = require('bs58'); var _bs582 = _interopRequireDefault(_bs58);var p=class m extends _chunkWGDN5N3Mcjs.a{constructor(r){super({chain:r.chain,address:r.address,owner:r.owner,signer:r.signer},_chunkWGDN5N3Mcjs.a.getApiClient(r))}static from(r){return new m(r)}sendTransaction(x){return _chunkXALFCQKDcjs.f.call(void 0, this,arguments,function*({transaction:r,additionalSigners:n}){let l={transaction:_bs582.default.encode(r.serialize())},a=yield this.apiClient.createTransaction(this.walletLocator,{params:l});if(a.error)throw new (0, _chunkCT2UGJELcjs.q)(JSON.stringify(a));let h=n==null?void 0:n.map(o=>new (0, _chunkTWQ6DA3Ycjs.a)({type:"external-wallet",address:o.publicKey.toString(),onSignTransaction:e=>(e.sign([o]),Promise.resolve(e))}));return yield this.approveAndWait(a.id,h)})}};exports.a = p;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as n,c as i}from"./chunk-
|
|
1
|
+
import{b as n,c as i}from"./chunk-DEV3BSLE.js";import{a as o}from"./chunk-7ENJXL4H.js";import{f as r}from"./chunk-BW7YYVZE.js";import{APIKeyUsageOrigin as c,CrossmintApiClient as h}from"@crossmint/common-sdk-base";var p=class extends h{constructor(e){super(e,{internalConfig:{sdkMetadata:{name:i,version:n}}});this.apiPrefix="api/2022-06-09/wallets"}createWallet(e){return r(this,null,function*(){let s=this.isServerSide?`${this.apiPrefix}`:`${this.apiPrefix}/me`;return(yield this.post(s,{body:JSON.stringify(e),headers:this.headers})).json()})}getWallet(e){return r(this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}`,{headers:this.headers})).json()})}createTransaction(e,s){return r(this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/transactions`,{body:JSON.stringify(s),headers:this.headers})).json()})}approveTransaction(e,s,t){return r(this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/transactions/${s}/approvals`,{body:JSON.stringify(t),headers:this.headers})).json()})}getTransaction(e,s){return r(this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}/transactions/${s}`,{headers:this.headers})).json()})}createSignature(e,s){return r(this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/signatures`,{body:JSON.stringify(s),headers:this.headers})).json()})}approveSignature(e,s,t){return r(this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/signatures/${s}/approvals`,{body:JSON.stringify(t),headers:this.headers})).json()})}getSignature(e,s){return r(this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}/signatures/${s}`,{headers:this.headers})).json()})}getTransactions(e){return r(this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}/transactions`,{headers:this.headers})).json()})}unstable_getNfts(e){return r(this,null,function*(){let s=new URLSearchParams;s.append("page",e.page.toString()),s.append("perPage",e.perPage.toString());let t=`${e.chain}:${e.address}`;return(yield this.get(`${this.apiPrefix}/${t}/nfts?${s.toString()}`,{headers:this.headers})).json()})}experimental_activity(e,s){return r(this,null,function*(){let t=new URLSearchParams;return t.append("chain",s.chain.toString()),(yield this.get(`${this.apiPrefix}/${e}/activity?${t.toString()}`,{headers:this.headers})).json()})}getBalance(e,s){return r(this,null,function*(){let t=new URLSearchParams;return t.append("tokenLocators",s.tokens.join(",")),t.append("chains",s.chains.join(",")),(yield this.get(`api/unstable/wallets/${e}/balances?${t.toString()}`,{headers:this.headers})).json()})}registerSigner(e,s){return r(this,null,function*(){return(yield this.post(`${this.apiPrefix}/${e}/signers`,{body:JSON.stringify(s),headers:this.headers})).json()})}getSigner(e,s){return r(this,null,function*(){return(yield this.get(`${this.apiPrefix}/${e}/signers/${s}`,{headers:this.headers})).json()})}send(e,s,t){return r(this,null,function*(){return(yield this.post(`api/unstable/wallets/${e}/tokens/${s}/transfers`,{body:JSON.stringify(t),headers:this.headers})).json()})}get isServerSide(){return this.parsedAPIKey.usageOrigin===c.SERVER}get environment(){if(!this.parsedAPIKey.isValid)throw new o("Invalid API key");return this.parsedAPIKey.environment}get headers(){return{"Content-Type":"application/json"}}};export{p as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkDHXTAZWScjs = require('./chunk-DHXTAZWS.cjs');var _chunkCT2UGJELcjs = require('./chunk-CT2UGJEL.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var _commonsdkbase = require('@crossmint/common-sdk-base');var a=class extends _commonsdkbase.CrossmintApiClient{constructor(e){super(e,{internalConfig:{sdkMetadata:{name:_chunkDHXTAZWScjs.c,version:_chunkDHXTAZWScjs.b}}});this.apiPrefix="api/v1/signers"}pregenerateSigner(e){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let r=yield this.post(`${this.apiPrefix}/derive-public-key`,{body:JSON.stringify({authId:`email:${e}`,keyType:"ed25519"}),headers:this.headers});if(!r.ok){let o=yield r.text();throw new Error(`Failed to fetch public key: ${r.status} ${o}`)}return yield r.json()})}get isServerSide(){return this.parsedAPIKey.usageOrigin===_commonsdkbase.APIKeyUsageOrigin.SERVER}get environment(){if(!this.parsedAPIKey.isValid)throw new (0, _chunkCT2UGJELcjs.a)("Invalid API key");return this.parsedAPIKey.environment}get headers(){return{"Content-Type":"application/json"}}};exports.a = a;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var _chunk3ZKXOCI7cjs = require('./chunk-3ZKXOCI7.cjs');var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }var _chunk3ZKXOCI7cjs = require('./chunk-3ZKXOCI7.cjs');var _chunkW44GS6MYcjs = require('./chunk-W44GS6MY.cjs');var _chunkZSWIQU3Ucjs = require('./chunk-ZSWIQU3U.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var _web3js = require('@solana/web3.js');var _bs58 = require('bs58'); var _bs582 = _interopRequireDefault(_bs58);var _commonsdkbase = require('@crossmint/common-sdk-base');var p=class{constructor(t){this.config=t;this.type="email";this._needsAuth=!0;this._authPromise=null;this.initialize()}locator(){return`solana-keypair:${this.config.signerAddress}`}initialize(){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){if(this.config._handshakeParent==null){let t=_commonsdkbase.validateAPIKey.call(void 0, this.config.crossmint.apiKey);if(!t.isValid)throw new Error("Invalid API key");let n=new (0, _chunk3ZKXOCI7cjs.a)({environment:t.environment});this.config._handshakeParent=yield n.initialize()}})}signMessage(){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return yield Promise.reject(new Error("signMessage method not implemented for email signer"))})}signTransaction(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var a,r;yield this.handleAuthRequired();let n=_bs582.default.decode(t),s=_web3js.VersionedTransaction.deserialize(n).message.serialize(),e=yield(r=this.config._handshakeParent)==null?void 0:r.sendAction({event:"request:sign",responseEvent:"response:sign",data:{authData:{jwt:(a=this.config.crossmint.jwt)!=null?a:"",apiKey:this.config.crossmint.apiKey},data:{keyType:"ed25519",bytes:_bs582.default.encode(s),encoding:"base58"}},options:c});if((e==null?void 0:e.status)==="error")throw new Error(e.error);if((e==null?void 0:e.signature)==null)throw new Error("Failed to sign transaction");return{signature:e.signature.bytes}})}handleAuthRequired(){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var e,a;if(this.config._handshakeParent==null)throw new Error("Handshake parent not initialized");let t=yield(a=this.config._handshakeParent)==null?void 0:a.sendAction({event:"request:get-status",responseEvent:"response:get-status",data:{authData:{jwt:(e=this.config.crossmint.jwt)!=null?e:"",apiKey:this.config.crossmint.apiKey}},options:c});if((t==null?void 0:t.status)!=="success")throw new Error(t==null?void 0:t.error);if(t.signerStatus==="ready"){this._needsAuth=!1;return}let{promise:n,resolve:i,reject:s}=this.createAuthPromise();if(this._authPromise={promise:n,resolve:i,reject:s},this.config.onAuthRequired)try{yield this.config.onAuthRequired(this._needsAuth,()=>this.sendEmailWithOtp(),r=>this.verifyOtp(r),()=>s(new _chunkZSWIQU3Ucjs.a))}catch(r){s(r)}try{yield n}catch(r){throw r}})}createAuthPromise(){let t,n;return{promise:new Promise((s,e)=>{t=s,n=e}),resolve:t,reject:n}}sendEmailWithOtp(){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var s,e;if(this.config._handshakeParent==null)throw new Error("Handshake parent not initialized");let t=this.config._handshakeParent,n=`email:${this.config.email}`,i=yield t.sendAction({event:"request:start-onboarding",responseEvent:"response:start-onboarding",data:{authData:{jwt:(s=this.config.crossmint.jwt)!=null?s:"",apiKey:this.config.crossmint.apiKey},data:{authId:n}},options:c});if((i==null?void 0:i.status)==="success"&&i.signerStatus==="ready"){this._needsAuth=!1;return}(i==null?void 0:i.status)==="error"&&(console.error("[sendEmailWithOtp] Failed to send OTP:",i),(e=this._authPromise)==null||e.reject(new Error(i.error||"Failed to initiate OTP process.")))})}verifyOtp(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var i,s,e,a;if(this.config._handshakeParent==null)throw new Error("Handshake parent not initialized");let n=this.config._handshakeParent;try{let r=yield n.sendAction({event:"request:complete-onboarding",responseEvent:"response:complete-onboarding",data:{authData:{jwt:(i=this.config.crossmint.jwt)!=null?i:"",apiKey:this.config.crossmint.apiKey},data:{onboardingAuthentication:{encryptedOtp:t}}},options:c});if((r==null?void 0:r.status)==="success"){console.log("[verifyOtp] OTP validation successful"),this._needsAuth=!1,(s=this._authPromise)==null||s.resolve();return}console.error("[verifyOtp] Failed to validate OTP:",r),this._needsAuth=!0;let g=(r==null?void 0:r.status)==="error"?r.error:"Failed to validate encrypted OTP";(e=this._authPromise)==null||e.reject(new Error(g))}catch(r){throw console.error("[verifyOtp] Error sending OTP validation request:",r),this._needsAuth=!0,(a=this._authPromise)==null||a.reject(r),r}})}static pregenerateSigner(t,n){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var i;if(t==null||((i=n.experimental_customAuth)==null?void 0:i.email)==null)throw new Error("Email is required to pregenerate a signer");try{let e=(yield new (0, _chunkW44GS6MYcjs.a)(n).pregenerateSigner(t!=null?t:n.experimental_customAuth.email)).publicKey;if(e==null)throw new Error("No public key found");if(e.encoding!=="base58"||e.keyType!=="ed25519"||e.bytes==null)throw new Error("Not supported. Expected public key to be in base58 encoding and ed25519 key type. Got: "+JSON.stringify(e));return e.bytes}catch(s){throw console.error("[EmailSigner] Failed to pregenerate signer:",s),s}})}},c={timeoutMs:1e4,intervalMs:5e3};exports.a = p;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkDHXTAZWScjs = require('./chunk-DHXTAZWS.cjs');var _chunkCT2UGJELcjs = require('./chunk-CT2UGJEL.cjs');var _chunkXALFCQKDcjs = require('./chunk-XALFCQKD.cjs');var _commonsdkbase = require('@crossmint/common-sdk-base');var w,o,I= exports.a =class{constructor({chain:t,address:i,owner:r,signer:s,options:n},e){_chunkXALFCQKDcjs.d.call(void 0, this,w);_chunkXALFCQKDcjs.d.call(void 0, this,o);_chunkXALFCQKDcjs.e.call(void 0, this,o,e),this.chain=t,this.address=i,this.owner=r,this.signer=s,_chunkXALFCQKDcjs.e.call(void 0, this,w,n)}static getApiClient(t){return t.apiClient}static getOptions(t){return t.options}get apiClient(){return _chunkXALFCQKDcjs.c.call(void 0, this,o)}get options(){return _chunkXALFCQKDcjs.c.call(void 0, this,w)}balances(t,i){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let r=yield _chunkXALFCQKDcjs.c.call(void 0, this,o).getBalance(this.address,{chains:i!=null?i:[this.chain],tokens:t});if("error"in r)throw new Error(`Failed to get balances for wallet: ${JSON.stringify(r.error)}`);return r})}unstable_nfts(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return yield _chunkXALFCQKDcjs.c.call(void 0, this,o).unstable_getNfts(_chunkXALFCQKDcjs.b.call(void 0, _chunkXALFCQKDcjs.a.call(void 0, {},t),{chain:this.chain,address:this.address}))})}unstable_transactions(){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return yield _chunkXALFCQKDcjs.c.call(void 0, this,o).getTransactions(this.walletLocator)})}experimental_activity(){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let t=yield this.apiClient.experimental_activity(this.walletLocator,{chain:this.chain});if("error"in t)throw new Error(`Failed to get activity: ${JSON.stringify(t.error)}`);return t})}send(t,i,r){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let s=k(t),n=U(i,this.chain),e={recipient:s,amount:r},c=yield _chunkXALFCQKDcjs.c.call(void 0, this,o).send(this.walletLocator,n,e);if("message"in c)throw new (0, _chunkCT2UGJELcjs.q)(`Failed to send token: ${JSON.stringify(c.message)}`);return yield this.approveAndWait(c.id)})}addDelegatedSigner(i){return _chunkXALFCQKDcjs.f.call(void 0, this,arguments,function*({signer:t}){var s,n;let r=yield _chunkXALFCQKDcjs.c.call(void 0, this,o).registerSigner(this.walletLocator,{signer:t,chain:this.chain==="solana"?void 0:this.chain});if("error"in r)throw new Error(`Failed to register signer: ${JSON.stringify(r.error)}`);if("transaction"in r){let e=r.transaction.id;yield this.approveAndWait(e)}else{let e=(s=r.chains)==null?void 0:s[this.chain];if((e==null?void 0:e.status)==="awaiting-approval"){let c=((n=e.approvals)==null?void 0:n.pending)||[];yield this.approveSignature(c,e.id),yield this.waitForSignature(e.id);return}if((e==null?void 0:e.status)==="pending"){yield this.waitForSignature(e.id);return}}})}delegatedSigners(){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var i,r,s;let t=yield _chunkXALFCQKDcjs.c.call(void 0, this,o).getWallet(this.walletLocator);if("error"in t)throw new (0, _chunkCT2UGJELcjs.d)(JSON.stringify(t));if(t.type!=="solana-smart-wallet"&&t.type!=="evm-smart-wallet")throw new (0, _chunkCT2UGJELcjs.c)(`Wallet type ${t.type} not supported`);return(s=(r=(i=t==null?void 0:t.config)==null?void 0:i.delegatedSigners)==null?void 0:r.map(n=>{let e=n.locator.indexOf(":");return{signer:`external-wallet:${e>=0?n.locator.slice(e+1):n.locator}`}}))!=null?s:[]})}get walletLocator(){return _chunkXALFCQKDcjs.c.call(void 0, this,o).isServerSide?this.address:`me:${this.isSolanaWallet?"solana-smart-wallet":"evm-smart-wallet"}`}get isSolanaWallet(){return this.chain==="solana"}approveAndWait(t,i){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return yield this.approveTransaction(t,i),yield this.sleep(1e3),yield this.waitForTransaction(t)})}approveTransaction(t,i){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){var g,h,u,b;let r=yield _chunkXALFCQKDcjs.c.call(void 0, this,o).getTransaction(this.walletLocator,t);if(r.error)throw new (0, _chunkCT2UGJELcjs.r)(JSON.stringify(r));if(yield(u=(h=(g=_chunkXALFCQKDcjs.c.call(void 0, this,w))==null?void 0:g.experimental_callbacks)==null?void 0:h.onTransactionStart)==null?void 0:u.call(h),this.signer.type==="api-key")return r;let s=(b=r.approvals)==null?void 0:b.pending;if(s==null)return r;let n=[...i!=null?i:[],this.signer],e=yield Promise.all(s.map(d=>{let A=n.find(D=>D.locator()===d.signer);if(A==null)throw new (0, _chunkCT2UGJELcjs.i)(`Signer ${d.signer} not found in pending approvals`);let J=r.walletType==="solana-smart-wallet"?r.onChain.transaction:d.message;return A.signTransaction(J)})),c=yield _chunkXALFCQKDcjs.c.call(void 0, this,o).approveTransaction(this.walletLocator,r.id,{approvals:e.map(d=>_chunkXALFCQKDcjs.a.call(void 0, {signer:this.signer.locator()},d))});if(c.error)throw new (0, _chunkCT2UGJELcjs.w)(JSON.stringify(c));return c})}approveSignature(t,i){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){if(this.isSolanaWallet)throw new Error("Approving signatures is only supported for EVM smart wallets");let r=t.find(n=>n.signer===this.signer.locator());if(!r)throw new (0, _chunkCT2UGJELcjs.i)(`Signer ${this.signer.locator()} not found in pending approvals`);let s=yield this.signer.signMessage(r.message);return yield _chunkXALFCQKDcjs.c.call(void 0, this,o).approveSignature(this.walletLocator,i,{approvals:[_chunkXALFCQKDcjs.a.call(void 0, {signer:this.signer.locator()},s)]}),s})}waitForSignature(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){let i=null;do if(yield new Promise(r=>setTimeout(r,_chunkDHXTAZWScjs.d)),i=yield _chunkXALFCQKDcjs.c.call(void 0, this,o).getSignature(this.walletLocator,t),"error"in i)throw new (0, _chunkCT2UGJELcjs.p)(JSON.stringify(i));while(i===null||i.status==="pending");if(i.status==="failed")throw new (0, _chunkCT2UGJELcjs.m)("Signature signing failed");if(!i.outputSignature)throw new (0, _chunkCT2UGJELcjs.p)("Signature not available");return i.outputSignature})}waitForTransaction(e){return _chunkXALFCQKDcjs.f.call(void 0, this,arguments,function*(t,i=6e4,{backoffMultiplier:r=1.1,maxBackoffMs:s=2e3,initialBackoffMs:n=_chunkDHXTAZWScjs.d}={}){let c=Date.now(),g;do{if(Date.now()-c>i)throw new (0, _chunkCT2UGJELcjs.s)("Transaction confirmation timeout");if(g=yield _chunkXALFCQKDcjs.c.call(void 0, this,o).getTransaction(this.walletLocator,t),g.error)throw new (0, _chunkCT2UGJELcjs.r)(JSON.stringify(g));yield this.sleep(n),n=Math.min(n*r,s)}while(g.status==="pending");if(g.status==="failed")throw new (0, _chunkCT2UGJELcjs.t)(`Transaction sending failed: ${JSON.stringify(g.error)}`);if(g.status==="awaiting-approval")throw new (0, _chunkCT2UGJELcjs.u)("Transaction is awaiting approval. Please submit required approvals before waiting for completion.");let h=g.onChain.txId;if(h==null)throw new (0, _chunkCT2UGJELcjs.v)("Transaction hash not found on transaction response");return h})}sleep(t){return _chunkXALFCQKDcjs.f.call(void 0, this,null,function*(){return new Promise(i=>setTimeout(i,t))})}};w=new WeakMap,o=new WeakMap;function k(a){if(typeof a=="string")return a;if("email"in a)return`email:${a.email}`;if("x"in a)return`x:${a.x}`;if("twitter"in a)return`twitter:${a.twitter}`;if("phone"in a)return`phoneNumber:${a.phone}`;if("userId"in a)return`userId:${a.userId}`;throw new Error("Invalid recipient locator")}function U(a,t){return _commonsdkbase.isValidAddress.call(void 0, a)?`${t}:${a}`:`${t}:${a.toLowerCase()}`}exports.a = I;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as t}from"./chunk-
|
|
1
|
+
import{a as t}from"./chunk-BHAZGEWK.js";import{a as c}from"./chunk-LFYI7K4T.js";import{q as s}from"./chunk-7ENJXL4H.js";import{f as i}from"./chunk-BW7YYVZE.js";import f from"bs58";var p=class m extends t{constructor(r){super({chain:r.chain,address:r.address,owner:r.owner,signer:r.signer},t.getApiClient(r))}static from(r){return new m(r)}sendTransaction(W){return i(this,arguments,function*({transaction:r,additionalSigners:n}){let l={transaction:f.encode(r.serialize())},a=yield this.apiClient.createTransaction(this.walletLocator,{params:l});if(a.error)throw new s(JSON.stringify(a));let h=n==null?void 0:n.map(o=>new c({type:"external-wallet",address:o.publicKey.toString(),onSignTransaction:e=>(e.sign([o]),Promise.resolve(e))}));return yield this.approveAndWait(a.id,h)})}};export{p as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as l}from"./chunk-U34BYZY2.js";import{a as d}from"./chunk-
|
|
1
|
+
import{a as l}from"./chunk-U34BYZY2.js";import{a as d}from"./chunk-4AVSHGKT.js";import{a as h}from"./chunk-M4ELAV7U.js";import{f as o}from"./chunk-BW7YYVZE.js";import{VersionedTransaction as m}from"@solana/web3.js";import u from"bs58";import{validateAPIKey as f}from"@crossmint/common-sdk-base";var p=class{constructor(t){this.config=t;this.type="email";this._needsAuth=!0;this._authPromise=null;this.initialize()}locator(){return`solana-keypair:${this.config.signerAddress}`}initialize(){return o(this,null,function*(){if(this.config._handshakeParent==null){let t=f(this.config.crossmint.apiKey);if(!t.isValid)throw new Error("Invalid API key");let n=new l({environment:t.environment});this.config._handshakeParent=yield n.initialize()}})}signMessage(){return o(this,null,function*(){return yield Promise.reject(new Error("signMessage method not implemented for email signer"))})}signTransaction(t){return o(this,null,function*(){var a,r;yield this.handleAuthRequired();let n=u.decode(t),s=m.deserialize(n).message.serialize(),e=yield(r=this.config._handshakeParent)==null?void 0:r.sendAction({event:"request:sign",responseEvent:"response:sign",data:{authData:{jwt:(a=this.config.crossmint.jwt)!=null?a:"",apiKey:this.config.crossmint.apiKey},data:{keyType:"ed25519",bytes:u.encode(s),encoding:"base58"}},options:c});if((e==null?void 0:e.status)==="error")throw new Error(e.error);if((e==null?void 0:e.signature)==null)throw new Error("Failed to sign transaction");return{signature:e.signature.bytes}})}handleAuthRequired(){return o(this,null,function*(){var e,a;if(this.config._handshakeParent==null)throw new Error("Handshake parent not initialized");let t=yield(a=this.config._handshakeParent)==null?void 0:a.sendAction({event:"request:get-status",responseEvent:"response:get-status",data:{authData:{jwt:(e=this.config.crossmint.jwt)!=null?e:"",apiKey:this.config.crossmint.apiKey}},options:c});if((t==null?void 0:t.status)!=="success")throw new Error(t==null?void 0:t.error);if(t.signerStatus==="ready"){this._needsAuth=!1;return}let{promise:n,resolve:i,reject:s}=this.createAuthPromise();if(this._authPromise={promise:n,resolve:i,reject:s},this.config.onAuthRequired)try{yield this.config.onAuthRequired(this._needsAuth,()=>this.sendEmailWithOtp(),r=>this.verifyOtp(r),()=>s(new h))}catch(r){s(r)}try{yield n}catch(r){throw r}})}createAuthPromise(){let t,n;return{promise:new Promise((s,e)=>{t=s,n=e}),resolve:t,reject:n}}sendEmailWithOtp(){return o(this,null,function*(){var s,e;if(this.config._handshakeParent==null)throw new Error("Handshake parent not initialized");let t=this.config._handshakeParent,n=`email:${this.config.email}`,i=yield t.sendAction({event:"request:start-onboarding",responseEvent:"response:start-onboarding",data:{authData:{jwt:(s=this.config.crossmint.jwt)!=null?s:"",apiKey:this.config.crossmint.apiKey},data:{authId:n}},options:c});if((i==null?void 0:i.status)==="success"&&i.signerStatus==="ready"){this._needsAuth=!1;return}(i==null?void 0:i.status)==="error"&&(console.error("[sendEmailWithOtp] Failed to send OTP:",i),(e=this._authPromise)==null||e.reject(new Error(i.error||"Failed to initiate OTP process.")))})}verifyOtp(t){return o(this,null,function*(){var i,s,e,a;if(this.config._handshakeParent==null)throw new Error("Handshake parent not initialized");let n=this.config._handshakeParent;try{let r=yield n.sendAction({event:"request:complete-onboarding",responseEvent:"response:complete-onboarding",data:{authData:{jwt:(i=this.config.crossmint.jwt)!=null?i:"",apiKey:this.config.crossmint.apiKey},data:{onboardingAuthentication:{encryptedOtp:t}}},options:c});if((r==null?void 0:r.status)==="success"){console.log("[verifyOtp] OTP validation successful"),this._needsAuth=!1,(s=this._authPromise)==null||s.resolve();return}console.error("[verifyOtp] Failed to validate OTP:",r),this._needsAuth=!0;let g=(r==null?void 0:r.status)==="error"?r.error:"Failed to validate encrypted OTP";(e=this._authPromise)==null||e.reject(new Error(g))}catch(r){throw console.error("[verifyOtp] Error sending OTP validation request:",r),this._needsAuth=!0,(a=this._authPromise)==null||a.reject(r),r}})}static pregenerateSigner(t,n){return o(this,null,function*(){var i;if(t==null||((i=n.experimental_customAuth)==null?void 0:i.email)==null)throw new Error("Email is required to pregenerate a signer");try{let e=(yield new d(n).pregenerateSigner(t!=null?t:n.experimental_customAuth.email)).publicKey;if(e==null)throw new Error("No public key found");if(e.encoding!=="base58"||e.keyType!=="ed25519"||e.bytes==null)throw new Error("Not supported. Expected public key to be in base58 encoding and ed25519 key type. Got: "+JSON.stringify(e));return e.bytes}catch(s){throw console.error("[EmailSigner] Failed to pregenerate signer:",s),s}})}},c={timeoutMs:1e4,intervalMs:5e3};export{p as a};
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkGAYU7KUHcjs = require('./chunk-GAYU7KUH.cjs');var _chunkRIBMRBAFcjs = require('./chunk-RIBMRBAF.cjs');require('./chunk-MHKWLGN5.cjs');var _chunkKQ4EMVOPcjs = require('./chunk-KQ4EMVOP.cjs');var _chunk6BHU3GBScjs = require('./chunk-6BHU3GBS.cjs');var _chunkWGDN5N3Mcjs = require('./chunk-WGDN5N3M.cjs');require('./chunk-5JSU3LZH.cjs');require('./chunk-W5TFNIA7.cjs');require('./chunk-WFNK46AR.cjs');require('./chunk-3ZKXOCI7.cjs');require('./chunk-W44GS6MY.cjs');require('./chunk-DYRSQN7X.cjs');require('./chunk-NVJN7LPY.cjs');require('./chunk-TWQ6DA3Y.cjs');var _chunkZSWIQU3Ucjs = require('./chunk-ZSWIQU3U.cjs');require('./chunk-NELBLSAV.cjs');require('./chunk-6HXIZLEQ.cjs');require('./chunk-C6UVNXU5.cjs');require('./chunk-DHXTAZWS.cjs');var _chunkCT2UGJELcjs = require('./chunk-CT2UGJEL.cjs');require('./chunk-ECAM5KTH.cjs');var _chunk6VJEBYPNcjs = require('./chunk-6VJEBYPN.cjs');require('./chunk-IR5WN6FQ.cjs');require('./chunk-GEY574TH.cjs');require('./chunk-YO6BJ2DI.cjs');require('./chunk-YAORQK6R.cjs');require('./chunk-XALFCQKD.cjs');exports.AuthRejectedError = _chunkZSWIQU3Ucjs.a; exports.CrossmintWallets = _chunkKQ4EMVOPcjs.b; exports.EVMWallet = _chunkGAYU7KUHcjs.a; exports.InvalidApiKeyError = _chunkCT2UGJELcjs.a; exports.InvalidEnvironmentError = _chunkCT2UGJELcjs.b; exports.InvalidMessageFormatError = _chunkCT2UGJELcjs.j; exports.InvalidSignerError = _chunkCT2UGJELcjs.i; exports.InvalidTypedDataError = _chunkCT2UGJELcjs.k; exports.InvalidWalletConfigError = _chunkCT2UGJELcjs.e; exports.MessageSigningNotSupportedError = _chunkCT2UGJELcjs.n; exports.PendingApprovalsError = _chunkCT2UGJELcjs.x; exports.SignatureNotAvailableError = _chunkCT2UGJELcjs.p; exports.SignatureNotCreatedError = _chunkCT2UGJELcjs.o; exports.SignatureNotFoundError = _chunkCT2UGJELcjs.l; exports.SignerTypeMismatchError = _chunkCT2UGJELcjs.h; exports.SigningFailedError = _chunkCT2UGJELcjs.m; exports.SolanaWallet = _chunkRIBMRBAFcjs.a; exports.TransactionAwaitingApprovalError = _chunkCT2UGJELcjs.u; exports.TransactionConfirmationTimeoutError = _chunkCT2UGJELcjs.s; exports.TransactionFailedError = _chunkCT2UGJELcjs.w; exports.TransactionHashNotFoundError = _chunkCT2UGJELcjs.v; exports.TransactionNotAvailableError = _chunkCT2UGJELcjs.r; exports.TransactionNotCreatedError = _chunkCT2UGJELcjs.q; exports.TransactionSendingFailedError = _chunkCT2UGJELcjs.t; exports.Wallet = _chunkWGDN5N3Mcjs.a; exports.WalletCreationError = _chunkCT2UGJELcjs.f; exports.WalletFactory = _chunk6BHU3GBScjs.a; exports.WalletNotAvailableError = _chunkCT2UGJELcjs.d; exports.WalletTypeMismatchError = _chunkCT2UGJELcjs.g; exports.WalletTypeNotSupportedError = _chunkCT2UGJELcjs.c; exports.createCrossmint = _chunkKQ4EMVOPcjs.a; exports.toViemChain = _chunk6VJEBYPNcjs.a;
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as F}from"./chunk-
|
|
1
|
+
import{a as F}from"./chunk-CQ4XLGLX.js";import{a as D}from"./chunk-WTH3C76N.js";import"./chunk-PJUVPRKB.js";import{a as B,b as C}from"./chunk-GGDVM72A.js";import{a as A}from"./chunk-N7YUUBKV.js";import{a as y}from"./chunk-BHAZGEWK.js";import"./chunk-Q2EXQLIK.js";import"./chunk-3W44OI5M.js";import"./chunk-XII5BD46.js";import"./chunk-U34BYZY2.js";import"./chunk-4AVSHGKT.js";import"./chunk-OV4CFQ36.js";import"./chunk-77QBSFHG.js";import"./chunk-LFYI7K4T.js";import{a as z}from"./chunk-M4ELAV7U.js";import"./chunk-NBXRBYNJ.js";import"./chunk-5IFDVB4Y.js";import"./chunk-RVVJFXV3.js";import"./chunk-DEV3BSLE.js";import{a as o,b as r,c as e,d as f,e as m,f as p,g as t,h as x,i as a,j as b,k as c,l as d,m as g,n as h,o as i,p as j,q as k,r as l,s as n,t as q,u as s,v as u,w as v,x as w}from"./chunk-7ENJXL4H.js";import"./chunk-KBJA7JDT.js";import{a as E}from"./chunk-BJDS5BJG.js";import"./chunk-KKQBZXFE.js";import"./chunk-S3DYQVRD.js";import"./chunk-2KK65AC6.js";import"./chunk-R7KEBAQ2.js";import"./chunk-BW7YYVZE.js";export{z as AuthRejectedError,C as CrossmintWallets,F as EVMWallet,o as InvalidApiKeyError,r as InvalidEnvironmentError,b as InvalidMessageFormatError,a as InvalidSignerError,c as InvalidTypedDataError,m as InvalidWalletConfigError,h as MessageSigningNotSupportedError,w as PendingApprovalsError,j as SignatureNotAvailableError,i as SignatureNotCreatedError,d as SignatureNotFoundError,x as SignerTypeMismatchError,g as SigningFailedError,D as SolanaWallet,s as TransactionAwaitingApprovalError,n as TransactionConfirmationTimeoutError,v as TransactionFailedError,u as TransactionHashNotFoundError,l as TransactionNotAvailableError,k as TransactionNotCreatedError,q as TransactionSendingFailedError,y as Wallet,p as WalletCreationError,A as WalletFactory,f as WalletNotAvailableError,t as WalletTypeMismatchError,e as WalletTypeNotSupportedError,B as createCrossmint,E as toViemChain};
|
package/dist/sdk.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkKQ4EMVOPcjs = require('./chunk-KQ4EMVOP.cjs');require('./chunk-6BHU3GBS.cjs');require('./chunk-WGDN5N3M.cjs');require('./chunk-5JSU3LZH.cjs');require('./chunk-W5TFNIA7.cjs');require('./chunk-WFNK46AR.cjs');require('./chunk-3ZKXOCI7.cjs');require('./chunk-W44GS6MY.cjs');require('./chunk-DYRSQN7X.cjs');require('./chunk-NVJN7LPY.cjs');require('./chunk-TWQ6DA3Y.cjs');require('./chunk-ZSWIQU3U.cjs');require('./chunk-NELBLSAV.cjs');require('./chunk-6HXIZLEQ.cjs');require('./chunk-C6UVNXU5.cjs');require('./chunk-DHXTAZWS.cjs');require('./chunk-CT2UGJEL.cjs');require('./chunk-ECAM5KTH.cjs');require('./chunk-YO6BJ2DI.cjs');require('./chunk-YAORQK6R.cjs');require('./chunk-XALFCQKD.cjs');exports.CrossmintWallets = _chunkKQ4EMVOPcjs.b; exports.createCrossmint = _chunkKQ4EMVOPcjs.a;
|
package/dist/sdk.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"./chunk-
|
|
1
|
+
import{a,b}from"./chunk-GGDVM72A.js";import"./chunk-N7YUUBKV.js";import"./chunk-BHAZGEWK.js";import"./chunk-Q2EXQLIK.js";import"./chunk-3W44OI5M.js";import"./chunk-XII5BD46.js";import"./chunk-U34BYZY2.js";import"./chunk-4AVSHGKT.js";import"./chunk-OV4CFQ36.js";import"./chunk-77QBSFHG.js";import"./chunk-LFYI7K4T.js";import"./chunk-M4ELAV7U.js";import"./chunk-NBXRBYNJ.js";import"./chunk-5IFDVB4Y.js";import"./chunk-RVVJFXV3.js";import"./chunk-DEV3BSLE.js";import"./chunk-7ENJXL4H.js";import"./chunk-KBJA7JDT.js";import"./chunk-2KK65AC6.js";import"./chunk-R7KEBAQ2.js";import"./chunk-BW7YYVZE.js";export{b as CrossmintWallets,a as createCrossmint};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkW44GS6MYcjs = require('../../chunk-W44GS6MY.cjs');require('../../chunk-DHXTAZWS.cjs');require('../../chunk-CT2UGJEL.cjs');require('../../chunk-XALFCQKD.cjs');exports.EmailSignerApiClient = _chunkW44GS6MYcjs.a;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-4AVSHGKT.js";import"../../chunk-DEV3BSLE.js";import"../../chunk-7ENJXL4H.js";import"../../chunk-BW7YYVZE.js";export{a as EmailSignerApiClient};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkWFNK46ARcjs = require('../../chunk-WFNK46AR.cjs');require('../../chunk-3ZKXOCI7.cjs');require('../../chunk-W44GS6MY.cjs');require('../../chunk-ZSWIQU3U.cjs');require('../../chunk-DHXTAZWS.cjs');require('../../chunk-CT2UGJEL.cjs');require('../../chunk-XALFCQKD.cjs');exports.EmailSigner = _chunkWFNK46ARcjs.a;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../../chunk-
|
|
1
|
+
import{a}from"../../chunk-XII5BD46.js";import"../../chunk-U34BYZY2.js";import"../../chunk-4AVSHGKT.js";import"../../chunk-M4ELAV7U.js";import"../../chunk-DEV3BSLE.js";import"../../chunk-7ENJXL4H.js";import"../../chunk-BW7YYVZE.js";export{a as EmailSigner};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});require('../../chunk-W5TFNIA7.cjs');var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});require('../../chunk-W5TFNIA7.cjs');var _chunkWFNK46ARcjs = require('../../chunk-WFNK46AR.cjs');require('../../chunk-3ZKXOCI7.cjs');require('../../chunk-W44GS6MY.cjs');require('../../chunk-ZSWIQU3U.cjs');require('../../chunk-DHXTAZWS.cjs');require('../../chunk-CT2UGJEL.cjs');require('../../chunk-XALFCQKD.cjs');exports.EmailSigner = _chunkWFNK46ARcjs.a;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"../../chunk-3W44OI5M.js";import{a}from"../../chunk-
|
|
1
|
+
import"../../chunk-3W44OI5M.js";import{a}from"../../chunk-XII5BD46.js";import"../../chunk-U34BYZY2.js";import"../../chunk-4AVSHGKT.js";import"../../chunk-M4ELAV7U.js";import"../../chunk-DEV3BSLE.js";import"../../chunk-7ENJXL4H.js";import"../../chunk-BW7YYVZE.js";export{a as EmailSigner};
|
package/dist/signers/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunk5JSU3LZHcjs = require('../chunk-5JSU3LZH.cjs');require('../chunk-W5TFNIA7.cjs');require('../chunk-WFNK46AR.cjs');require('../chunk-3ZKXOCI7.cjs');require('../chunk-W44GS6MY.cjs');require('../chunk-DYRSQN7X.cjs');require('../chunk-NVJN7LPY.cjs');require('../chunk-TWQ6DA3Y.cjs');require('../chunk-ZSWIQU3U.cjs');require('../chunk-DHXTAZWS.cjs');require('../chunk-CT2UGJEL.cjs');require('../chunk-YO6BJ2DI.cjs');require('../chunk-YAORQK6R.cjs');require('../chunk-XALFCQKD.cjs');exports.assembleSigner = _chunk5JSU3LZHcjs.a;
|
package/dist/signers/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../chunk-
|
|
1
|
+
import{a}from"../chunk-Q2EXQLIK.js";import"../chunk-3W44OI5M.js";import"../chunk-XII5BD46.js";import"../chunk-U34BYZY2.js";import"../chunk-4AVSHGKT.js";import"../chunk-OV4CFQ36.js";import"../chunk-77QBSFHG.js";import"../chunk-LFYI7K4T.js";import"../chunk-M4ELAV7U.js";import"../chunk-DEV3BSLE.js";import"../chunk-7ENJXL4H.js";import"../chunk-2KK65AC6.js";import"../chunk-R7KEBAQ2.js";import"../chunk-BW7YYVZE.js";export{a as assembleSigner};
|
package/dist/utils/constants.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkDHXTAZWScjs = require('../chunk-DHXTAZWS.cjs');require('../chunk-XALFCQKD.cjs');exports.SDK_NAME = _chunkDHXTAZWScjs.c; exports.SDK_VERSION = _chunkDHXTAZWScjs.b; exports.STATUS_POLLING_INTERVAL_MS = _chunkDHXTAZWScjs.d; exports.WALLETS_SERVICE = _chunkDHXTAZWScjs.a;
|
package/dist/utils/constants.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b,c,d}from"../chunk-
|
|
1
|
+
import{a,b,c,d}from"../chunk-DEV3BSLE.js";import"../chunk-BW7YYVZE.js";export{c as SDK_NAME,b as SDK_VERSION,d as STATUS_POLLING_INTERVAL_MS,a as WALLETS_SERVICE};
|
package/dist/wallets/evm.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkGAYU7KUHcjs = require('../chunk-GAYU7KUH.cjs');require('../chunk-WGDN5N3M.cjs');require('../chunk-DHXTAZWS.cjs');require('../chunk-CT2UGJEL.cjs');require('../chunk-6VJEBYPN.cjs');require('../chunk-IR5WN6FQ.cjs');require('../chunk-GEY574TH.cjs');require('../chunk-XALFCQKD.cjs');exports.EVMWallet = _chunkGAYU7KUHcjs.a;
|
package/dist/wallets/evm.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../chunk-
|
|
1
|
+
import{a}from"../chunk-CQ4XLGLX.js";import"../chunk-BHAZGEWK.js";import"../chunk-DEV3BSLE.js";import"../chunk-7ENJXL4H.js";import"../chunk-BJDS5BJG.js";import"../chunk-KKQBZXFE.js";import"../chunk-S3DYQVRD.js";import"../chunk-BW7YYVZE.js";export{a as EVMWallet};
|
package/dist/wallets/solana.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkRIBMRBAFcjs = require('../chunk-RIBMRBAF.cjs');require('../chunk-WGDN5N3M.cjs');require('../chunk-TWQ6DA3Y.cjs');require('../chunk-DHXTAZWS.cjs');require('../chunk-CT2UGJEL.cjs');require('../chunk-XALFCQKD.cjs');exports.SolanaWallet = _chunkRIBMRBAFcjs.a;
|
package/dist/wallets/solana.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../chunk-
|
|
1
|
+
import{a}from"../chunk-WTH3C76N.js";import"../chunk-BHAZGEWK.js";import"../chunk-LFYI7K4T.js";import"../chunk-DEV3BSLE.js";import"../chunk-7ENJXL4H.js";import"../chunk-BW7YYVZE.js";export{a as SolanaWallet};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunk6BHU3GBScjs = require('../chunk-6BHU3GBS.cjs');require('../chunk-WGDN5N3M.cjs');require('../chunk-5JSU3LZH.cjs');require('../chunk-W5TFNIA7.cjs');require('../chunk-WFNK46AR.cjs');require('../chunk-3ZKXOCI7.cjs');require('../chunk-W44GS6MY.cjs');require('../chunk-DYRSQN7X.cjs');require('../chunk-NVJN7LPY.cjs');require('../chunk-TWQ6DA3Y.cjs');require('../chunk-ZSWIQU3U.cjs');require('../chunk-NELBLSAV.cjs');require('../chunk-DHXTAZWS.cjs');require('../chunk-CT2UGJEL.cjs');require('../chunk-YO6BJ2DI.cjs');require('../chunk-YAORQK6R.cjs');require('../chunk-XALFCQKD.cjs');exports.WalletFactory = _chunk6BHU3GBScjs.a;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../chunk-
|
|
1
|
+
import{a}from"../chunk-N7YUUBKV.js";import"../chunk-BHAZGEWK.js";import"../chunk-Q2EXQLIK.js";import"../chunk-3W44OI5M.js";import"../chunk-XII5BD46.js";import"../chunk-U34BYZY2.js";import"../chunk-4AVSHGKT.js";import"../chunk-OV4CFQ36.js";import"../chunk-77QBSFHG.js";import"../chunk-LFYI7K4T.js";import"../chunk-M4ELAV7U.js";import"../chunk-NBXRBYNJ.js";import"../chunk-DEV3BSLE.js";import"../chunk-7ENJXL4H.js";import"../chunk-2KK65AC6.js";import"../chunk-R7KEBAQ2.js";import"../chunk-BW7YYVZE.js";export{a as WalletFactory};
|
package/dist/wallets/wallet.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});var _chunkWGDN5N3Mcjs = require('../chunk-WGDN5N3M.cjs');require('../chunk-DHXTAZWS.cjs');require('../chunk-CT2UGJEL.cjs');require('../chunk-XALFCQKD.cjs');exports.Wallet = _chunkWGDN5N3Mcjs.a;
|
package/dist/wallets/wallet.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"../chunk-
|
|
1
|
+
import{a}from"../chunk-BHAZGEWK.js";import"../chunk-DEV3BSLE.js";import"../chunk-7ENJXL4H.js";import"../chunk-BW7YYVZE.js";export{a as Wallet};
|