@account-kit/smart-contracts 4.8.0 → 4.10.0

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.
Files changed (43) hide show
  1. package/dist/esm/src/light-account/clients/alchemyClient.js +6 -12
  2. package/dist/esm/src/light-account/clients/alchemyClient.js.map +1 -1
  3. package/dist/esm/src/light-account/clients/client.d.ts +9 -4
  4. package/dist/esm/src/light-account/clients/client.js +26 -1
  5. package/dist/esm/src/light-account/clients/client.js.map +1 -1
  6. package/dist/esm/src/light-account/clients/multiOwnerAlchemyClient.js +6 -11
  7. package/dist/esm/src/light-account/clients/multiOwnerAlchemyClient.js.map +1 -1
  8. package/dist/esm/src/light-account/clients/multiOwnerLightAccount.d.ts +10 -4
  9. package/dist/esm/src/light-account/clients/multiOwnerLightAccount.js +27 -3
  10. package/dist/esm/src/light-account/clients/multiOwnerLightAccount.js.map +1 -1
  11. package/dist/esm/src/ma-v2/client/client.d.ts +10 -3
  12. package/dist/esm/src/ma-v2/client/client.js +18 -1
  13. package/dist/esm/src/ma-v2/client/client.js.map +1 -1
  14. package/dist/esm/src/msca/client/alchemyClient.js +4 -17
  15. package/dist/esm/src/msca/client/alchemyClient.js.map +1 -1
  16. package/dist/esm/src/msca/client/client.d.ts +14 -5
  17. package/dist/esm/src/msca/client/client.js +62 -0
  18. package/dist/esm/src/msca/client/client.js.map +1 -1
  19. package/dist/esm/src/msca/client/multiSigAlchemyClient.d.ts +4 -2
  20. package/dist/esm/src/msca/client/multiSigAlchemyClient.js +5 -19
  21. package/dist/esm/src/msca/client/multiSigAlchemyClient.js.map +1 -1
  22. package/dist/types/src/light-account/clients/alchemyClient.d.ts.map +1 -1
  23. package/dist/types/src/light-account/clients/client.d.ts +9 -4
  24. package/dist/types/src/light-account/clients/client.d.ts.map +1 -1
  25. package/dist/types/src/light-account/clients/multiOwnerAlchemyClient.d.ts.map +1 -1
  26. package/dist/types/src/light-account/clients/multiOwnerLightAccount.d.ts +10 -4
  27. package/dist/types/src/light-account/clients/multiOwnerLightAccount.d.ts.map +1 -1
  28. package/dist/types/src/ma-v2/client/client.d.ts +10 -3
  29. package/dist/types/src/ma-v2/client/client.d.ts.map +1 -1
  30. package/dist/types/src/msca/client/alchemyClient.d.ts.map +1 -1
  31. package/dist/types/src/msca/client/client.d.ts +14 -5
  32. package/dist/types/src/msca/client/client.d.ts.map +1 -1
  33. package/dist/types/src/msca/client/multiSigAlchemyClient.d.ts +4 -2
  34. package/dist/types/src/msca/client/multiSigAlchemyClient.d.ts.map +1 -1
  35. package/package.json +6 -5
  36. package/src/light-account/clients/alchemyClient.ts +5 -14
  37. package/src/light-account/clients/client.ts +52 -6
  38. package/src/light-account/clients/multiOwnerAlchemyClient.ts +5 -13
  39. package/src/light-account/clients/multiOwnerLightAccount.ts +64 -8
  40. package/src/ma-v2/client/client.ts +53 -7
  41. package/src/msca/client/alchemyClient.ts +3 -22
  42. package/src/msca/client/client.ts +157 -13
  43. package/src/msca/client/multiSigAlchemyClient.ts +6 -29
@@ -1 +1 @@
1
- {"version":3,"file":"client.js","sourceRoot":"","sources":["../../../../../src/msca/client/client.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACxB,yBAAyB,GAI1B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAoD,MAAM,MAAM,CAAC;AAExE,OAAO,EACL,mBAAmB,GAEpB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,8BAA8B,GAG/B,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACL,4BAA4B,GAG7B,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,oBAAoB,GAErB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EACL,uBAAuB,GAExB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACL,qBAAqB,GAGtB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,2BAA2B,EAAE,MAAM,mCAAmC,CAAC;AAsChF;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,CAAC,KAAK,UAAU,oCAAoC,CAAC,EACzD,SAAS,EACT,KAAK,EACL,GAAG,MAAM,EACkC;IAC3C,MAAM,cAAc,GAAG,MAAM,8BAA8B,CAAC;QAC1D,GAAG,MAAM;QACT,SAAS;QACT,KAAK;KACN,CAAC,CAAC;IAEH,OAAO,wBAAwB,CAAC;QAC9B,GAAG,MAAM;QACT,SAAS;QACT,KAAK;QACL,OAAO,EAAE,cAAc;KACxB,CAAC;SACC,MAAM,CAAC,oBAAoB,CAAC;SAC5B,MAAM,CAAC,uBAAuB,CAAC;SAC/B,MAAM,CAAC,mBAAmB,CAAC,CAAC;AACjC,CAAC;AAoBD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,CAAC,KAAK,UAAU,kCAAkC,CAAC,EACvD,SAAS,EACT,KAAK,EACL,GAAG,MAAM,EACgC;IAUzC,MAAM,cAAc,GAAG,MAAM,4BAA4B,CAAC;QACxD,GAAG,MAAM;QACT,SAAS;QACT,KAAK;KACN,CAAC,CAAC;IAEH,MAAM,MAAM,GAAG,wBAAwB,CAAC;QACtC,GAAG,MAAM;QACT,SAAS;QACT,KAAK;QACL,OAAO,EAAE,cAAc;QACvB,iBAAiB,EAAE,2BAA2B;KAC/C,CAAC;SACC,MAAM,CAAC,yBAAyB,CAAC;SACjC,MAAM,CAAC,oBAAoB,CAAC;SAC5B,MAAM,CAAC,qBAAqB,CAAC;SAC7B,MAAM,CAAC,mBAAmB,CAAC,CAAC;IAE/B,OAAO,MAAM,CAAC;AAChB,CAAC","sourcesContent":["import {\n createSmartAccountClient,\n smartAccountClientActions,\n type SmartAccountClient,\n type SmartAccountClientRpcSchema,\n type SmartAccountSigner,\n} from \"@aa-sdk/core\";\nimport { type Chain, type CustomTransport, type Transport } from \"viem\";\nimport type { CreateLightAccountClientParams } from \"../../light-account/clients/client.js\";\nimport {\n accountLoupeActions,\n type AccountLoupeActions,\n} from \"../account-loupe/decorator.js\";\nimport {\n createMultiOwnerModularAccount,\n type CreateMultiOwnerModularAccountParams,\n type MultiOwnerModularAccount,\n} from \"../account/multiOwnerAccount.js\";\nimport {\n createMultisigModularAccount,\n type CreateMultisigModularAccountParams,\n type MultisigModularAccount,\n} from \"../account/multisigAccount.js\";\nimport {\n pluginManagerActions,\n type PluginManagerActions,\n} from \"../plugin-manager/decorator.js\";\nimport {\n multiOwnerPluginActions,\n type MultiOwnerPluginActions,\n} from \"../plugins/multi-owner/index.js\";\nimport {\n multisigPluginActions,\n type MultisigPluginActions,\n type MultisigUserOperationContext,\n} from \"../plugins/multisig/index.js\";\nimport { multisigSignatureMiddleware } from \"../plugins/multisig/middleware.js\";\n\nexport type CreateMultiOwnerModularAccountClientParams<\n TTransport extends Transport = Transport,\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n> = Omit<\n CreateMultiOwnerModularAccountParams<TTransport, TSigner>,\n \"transport\" | \"chain\"\n> &\n Omit<CreateLightAccountClientParams<TTransport, TChain, TSigner>, \"account\">;\n\nexport type CreateMultisigModularAccountClientParams<\n TTransport extends Transport = Transport,\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n> = Omit<\n CreateMultisigModularAccountParams<TTransport, TSigner>,\n \"transport\" | \"chain\"\n> &\n Omit<CreateLightAccountClientParams<TTransport, TChain, TSigner>, \"account\">;\n\nexport function createMultiOwnerModularAccountClient<\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n>(\n args: CreateMultiOwnerModularAccountClientParams<Transport, TChain, TSigner>\n): Promise<\n SmartAccountClient<\n CustomTransport,\n Chain,\n MultiOwnerModularAccount<TSigner>,\n MultiOwnerPluginActions<MultiOwnerModularAccount<TSigner>> &\n PluginManagerActions<MultiOwnerModularAccount<TSigner>> &\n AccountLoupeActions<MultiOwnerModularAccount<TSigner>>\n >\n>;\n\n/**\n * Creates a multi-owner modular account client with the provided parameters including account, transport, chain, and additional client configuration. This function uses a modular account and extends it with various plugin actions.\n *\n * @example\n * ```ts\n * import { createMultiOwnerModularAccountClient } from \"@account-kit/smart-contracts\";\n * import { LocalAccountSigner } from \"@aa-sdk/core\";\n * import { sepolia } from \"viem/chains\";\n * import { http } from \"viem\";\n * import { generatePrivateKey } from \"viem/accounts\";\n *\n * const accountClient = await createMultiOwnerModularAccountClient({\n * chain: sepolia,\n * transport: http(\"RPC_URL\"),\n * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey())\n * });\n * ```\n *\n * @param {CreateMultiOwnerModularAccountClientParams} config The parameters for creating the multi-owner modular account client\n * @returns {Promise<SmartAccountClient>} A promise that resolves to a `SmartAccountClient` instance with extended plugin actions\n */\nexport async function createMultiOwnerModularAccountClient({\n transport,\n chain,\n ...params\n}: CreateMultiOwnerModularAccountClientParams): Promise<SmartAccountClient> {\n const modularAccount = await createMultiOwnerModularAccount({\n ...params,\n transport,\n chain,\n });\n\n return createSmartAccountClient({\n ...params,\n transport,\n chain,\n account: modularAccount,\n })\n .extend(pluginManagerActions)\n .extend(multiOwnerPluginActions)\n .extend(accountLoupeActions);\n}\n\nexport function createMultisigModularAccountClient<\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n>(\n args: CreateMultisigModularAccountClientParams<Transport, TChain, TSigner>\n): Promise<\n SmartAccountClient<\n CustomTransport,\n Chain,\n MultisigModularAccount<TSigner>,\n MultisigPluginActions<MultisigModularAccount<TSigner>> &\n PluginManagerActions<MultisigModularAccount<TSigner>> &\n AccountLoupeActions<MultisigModularAccount<TSigner>>,\n SmartAccountClientRpcSchema,\n MultisigUserOperationContext\n >\n>;\n\n/**\n * Creates a multisig modular account client using the provided parameters including account details, transport, chain, and additional client configuration. This function constructs the multisig modular account and extends it with various actions to create a comprehensive client.\n *\n * @example\n * ```ts\n * import { createMultisigModularAccountClient } from \"@account-kit/smart-contracts\";\n * import { LocalAccountSigner } from \"@aa-sdk/core\";\n * import { sepolia } from \"viem/chains\";\n * import { http } from \"viem\"\n * import { generatePrivateKey } from \"viem/accounts\";\n *\n * const accountClient = await createMultisigModularAccountClient({\n * chain: sepolia,\n * transport: http(\"RPC_URL\"),\n * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey()),\n * owners: [], // other owners on the account\n * threshold: 2, // 2 of N signatures\n * });\n * ```\n *\n * @param {CreateMultisigModularAccountClientParams} config the parameters for configuring the multisig modular account client\n * @returns {Promise<SmartAccountClient<Transport, Chain, MultisigModularAccount<SmartAccountSigner>, {}, SmartAccountClientRpcSchema, MultisigUserOperationContext>>} a promise that resolves to a `SmartAccountClient` object extended with the multisig modular account and additional actions\n */\nexport async function createMultisigModularAccountClient({\n transport,\n chain,\n ...params\n}: CreateMultisigModularAccountClientParams): Promise<\n SmartAccountClient<\n Transport,\n Chain,\n MultisigModularAccount<SmartAccountSigner>,\n {},\n SmartAccountClientRpcSchema,\n MultisigUserOperationContext\n >\n> {\n const modularAccount = await createMultisigModularAccount({\n ...params,\n transport,\n chain,\n });\n\n const client = createSmartAccountClient({\n ...params,\n transport,\n chain,\n account: modularAccount,\n signUserOperation: multisigSignatureMiddleware,\n })\n .extend(smartAccountClientActions)\n .extend(pluginManagerActions)\n .extend(multisigPluginActions)\n .extend(accountLoupeActions);\n\n return client;\n}\n"]}
1
+ {"version":3,"file":"client.js","sourceRoot":"","sources":["../../../../../src/msca/client/client.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACxB,yBAAyB,GAK1B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAoD,MAAM,MAAM,CAAC;AAExE,OAAO,EACL,mBAAmB,GAEpB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,8BAA8B,GAG/B,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACL,4BAA4B,GAG7B,MAAM,+BAA+B,CAAC;AACvC,OAAO,EACL,oBAAoB,GAErB,MAAM,gCAAgC,CAAC;AACxC,OAAO,EACL,u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S;QACT,KAAK;KACN,CAAC,CAAC;IACH,IAAI,kBAAkB,CAAC,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC;QACzC,4IAA4I;QAC5I,yFAAyF;QACzF,IAAI,MAAM,GAAuC;YAC/C,GAAG,MAAM;YACT,KAAK;YACL,SAAS;SACV,CAAC;QACF,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,CAAC;QAExB,OAAO,+BAA+B,CAAC;YACrC,GAAG,MAAM;YACT,OAAO,EAAE,cAAc;YACvB,IAAI;YACJ,iBAAiB,EAAE,2BAA2B;SAC/C,CAAC;aACC,MAAM,CAAC,yBAAyB,CAAC;aACjC,MAAM,CAAC,qBAAqB,CAAC;aAC7B,MAAM,CAAC,oBAAoB,CAAC;aAC5B,MAAM,CAAC,mBAAmB,CAAC,CAAC;IACjC,CAAC;IAED,MAAM,MAAM,GAAG,wBAAwB,CAAC;QACtC,GAAG,MAAM;QACT,SAAS;QACT,KAAK;QACL,OAAO,EAAE,cAAc;QACvB,iBAAiB,EAAE,2BAA2B;KAC/C,CAAC;SACC,MAAM,CAAC,yBAAyB,CAAC;SACjC,MAAM,CAAC,oBAAoB,CAAC;SAC5B,MAAM,CAAC,qBAAqB,CAAC;SAC7B,MAAM,CAAC,mBAAmB,CAAC,CAAC;IAE/B,OAAO,MAAM,CAAC;AAChB,CAAC","sourcesContent":["import {\n createSmartAccountClient,\n smartAccountClientActions,\n type NotType,\n type SmartAccountClient,\n type SmartAccountClientRpcSchema,\n type SmartAccountSigner,\n} from \"@aa-sdk/core\";\nimport { type Chain, type CustomTransport, type Transport } from \"viem\";\nimport type { CreateLightAccountClientParams } from \"../../light-account/clients/client.js\";\nimport {\n accountLoupeActions,\n type AccountLoupeActions,\n} from \"../account-loupe/decorator.js\";\nimport {\n createMultiOwnerModularAccount,\n type CreateMultiOwnerModularAccountParams,\n type MultiOwnerModularAccount,\n} from \"../account/multiOwnerAccount.js\";\nimport {\n createMultisigModularAccount,\n type CreateMultisigModularAccountParams,\n type MultisigModularAccount,\n} from \"../account/multisigAccount.js\";\nimport {\n pluginManagerActions,\n type PluginManagerActions,\n} from \"../plugin-manager/decorator.js\";\nimport {\n multiOwnerPluginActions,\n type MultiOwnerPluginActions,\n} from \"../plugins/multi-owner/index.js\";\nimport {\n multisigPluginActions,\n type MultisigPluginActions,\n type MultisigUserOperationContext,\n} from \"../plugins/multisig/index.js\";\nimport { multisigSignatureMiddleware } from \"../plugins/multisig/middleware.js\";\nimport type { AlchemyModularAccountClientConfig } from \"./alchemyClient.js\";\nimport {\n createAlchemySmartAccountClient,\n isAlchemyTransport,\n type AlchemySmartAccountClient,\n type AlchemyTransport,\n} from \"@account-kit/infra\";\nimport type { AlchemyMultisigAccountClientConfig } from \"./multiSigAlchemyClient.js\";\n\nexport type CreateMultiOwnerModularAccountClientWithoutAlchemyParams<\n TTransport extends Transport = Transport,\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n> = Omit<\n CreateMultiOwnerModularAccountParams<TTransport, TSigner>,\n \"transport\" | \"chain\"\n> &\n Omit<CreateLightAccountClientParams<TTransport, TChain, TSigner>, \"account\">;\nexport type CreateMultiOwnerModularAccountClientParams<\n TTransport extends Transport = Transport,\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n> =\n | CreateMultiOwnerModularAccountClientWithoutAlchemyParams<\n TTransport,\n TChain,\n TSigner\n >\n | AlchemyModularAccountClientConfig<TSigner>;\n\nexport type CreateMultisigModularAccountClientWithoutAlchemyParams<\n TTransport extends Transport = Transport,\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n> = Omit<\n CreateMultisigModularAccountParams<TTransport, TSigner>,\n \"transport\" | \"chain\"\n> &\n Omit<CreateLightAccountClientParams<TTransport, TChain, TSigner>, \"account\">;\n\nexport type CreateMultisigModularAccountClientParams<\n TTransport extends Transport = Transport,\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n> =\n | CreateMultisigModularAccountClientWithoutAlchemyParams<\n TTransport,\n TChain,\n TSigner\n >\n | AlchemyMultisigAccountClientConfig<TSigner>;\n\nexport function createMultiOwnerModularAccountClient<\n TSigner extends SmartAccountSigner = SmartAccountSigner\n>(\n params: AlchemyModularAccountClientConfig<TSigner> & {\n transport: AlchemyTransport;\n }\n): Promise<\n AlchemySmartAccountClient<\n Chain | undefined,\n MultiOwnerModularAccount<TSigner>,\n MultiOwnerPluginActions<MultiOwnerModularAccount<TSigner>> &\n PluginManagerActions<MultiOwnerModularAccount<TSigner>> &\n AccountLoupeActions<MultiOwnerModularAccount<TSigner>>\n >\n>;\n\nexport function createMultiOwnerModularAccountClient<\n TTransport extends Transport = Transport,\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n>(\n args: CreateMultiOwnerModularAccountClientParams<\n TTransport,\n TChain,\n TSigner\n > &\n NotType<TTransport, AlchemyTransport>\n): Promise<\n SmartAccountClient<\n CustomTransport,\n Chain,\n MultiOwnerModularAccount<TSigner>,\n MultiOwnerPluginActions<MultiOwnerModularAccount<TSigner>> &\n PluginManagerActions<MultiOwnerModularAccount<TSigner>> &\n AccountLoupeActions<MultiOwnerModularAccount<TSigner>>\n >\n>;\n\n/**\n * Creates a multi-owner modular account client with the provided parameters including account, transport, chain, and additional client configuration. This function uses a modular account and extends it with various plugin actions.\n *\n * @example\n * ```ts\n * import { createMultiOwnerModularAccountClient } from \"@account-kit/smart-contracts\";\n * import { LocalAccountSigner } from \"@aa-sdk/core\";\n * import { sepolia } from \"viem/chains\";\n * import { http } from \"viem\";\n * import { generatePrivateKey } from \"viem/accounts\";\n *\n * const accountClient = await createMultiOwnerModularAccountClient({\n * chain: sepolia,\n * transport: http(\"RPC_URL\"),\n * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey())\n * });\n * ```\n * @example\n * ```ts\n * import { createMultiOwnerModularAccountClient } from \"@account-kit/smart-contracts\";\n * import { sepolia, alchemy } from \"@account-kit/infra\";\n * import { LocalAccountSigner } from \"@aa-sdk/core\";\n * import { generatePrivateKey } from \"viem\"\n *\n * const alchemyAccountClient = await createMultiOwnerModularAccountClient({\n * transport: alchemy({ apiKey: \"your-api-key\" }),\n * chain: sepolia,\n * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey())\n * });\n * ```\n *\n * @param {CreateMultiOwnerModularAccountClientParams} config The parameters for creating the multi-owner modular account client\n * @returns {Promise<SmartAccountClient>} A promise that resolves to a `SmartAccountClient` instance with extended plugin actions\n */\nexport async function createMultiOwnerModularAccountClient({\n transport,\n chain,\n ...params\n}: CreateMultiOwnerModularAccountClientParams): Promise<\n SmartAccountClient | AlchemySmartAccountClient\n> {\n const modularAccount = await createMultiOwnerModularAccount({\n ...params,\n transport,\n chain,\n });\n if (isAlchemyTransport(transport, chain)) {\n const { opts } = params;\n\n return createAlchemySmartAccountClient({\n ...params,\n account: modularAccount,\n transport,\n chain,\n opts,\n })\n .extend(multiOwnerPluginActions)\n .extend(pluginManagerActions)\n .extend(accountLoupeActions);\n }\n\n return createSmartAccountClient({\n ...params,\n transport,\n chain,\n account: modularAccount,\n })\n .extend(pluginManagerActions)\n .extend(multiOwnerPluginActions)\n .extend(accountLoupeActions);\n}\n\nexport function createMultisigModularAccountClient<\n TSigner extends SmartAccountSigner = SmartAccountSigner\n>(\n params: AlchemyMultisigAccountClientConfig<TSigner>\n): Promise<\n AlchemySmartAccountClient<\n Chain | undefined,\n MultisigModularAccount<TSigner>,\n MultisigPluginActions<MultisigModularAccount<TSigner>> &\n PluginManagerActions<MultisigModularAccount<TSigner>> &\n AccountLoupeActions<MultisigModularAccount<TSigner>>,\n MultisigUserOperationContext\n >\n>;\n\nexport function createMultisigModularAccountClient<\n TTransport extends Transport = Transport,\n TChain extends Chain | undefined = Chain | undefined,\n TSigner extends SmartAccountSigner = SmartAccountSigner\n>(\n args: CreateMultisigModularAccountClientParams<TTransport, TChain, TSigner> &\n NotType<TTransport, AlchemyTransport>\n): Promise<\n SmartAccountClient<\n CustomTransport,\n Chain,\n MultisigModularAccount<TSigner>,\n MultisigPluginActions<MultisigModularAccount<TSigner>> &\n PluginManagerActions<MultisigModularAccount<TSigner>> &\n AccountLoupeActions<MultisigModularAccount<TSigner>>,\n SmartAccountClientRpcSchema,\n MultisigUserOperationContext\n >\n>;\n\n/**\n * Creates a multisig modular account client using the provided parameters including account details, transport, chain, and additional client configuration. This function constructs the multisig modular account and extends it with various actions to create a comprehensive client.\n *\n * @example\n * ```ts\n * import { createMultisigModularAccountClient } from \"@account-kit/smart-contracts\";\n * import { LocalAccountSigner } from \"@aa-sdk/core\";\n * import { sepolia } from \"viem/chains\";\n * import { http } from \"viem\"\n * import { generatePrivateKey } from \"viem/accounts\";\n *\n * const accountClient = await createMultisigModularAccountClient({\n * chain: sepolia,\n * transport: http(\"RPC_URL\"),\n * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey()),\n * owners: [], // other owners on the account\n * threshold: 2, // 2 of N signatures\n * });\n * ```\n * @example\n * ```ts\n * import { createMultisigModularAccountClient } from \"@account-kit/smart-contracts\";\n * import { sepolia } from \"@account-kit/infra\";\n * import { LocalAccountSigner } from \"@aa-sdk/core\";\n * import { generatePrivateKey } from \"viem\"\n *\n * const alchemyAccountClient = await createMultisigModularAccountClient({\n * transport: alchemy({ apiKey: \"your-api-key\" }),\n * chain: sepolia,\n * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey()),\n * owners: [...], // other owners on the account\n * threshold: 2, // 2 of N signatures\n * });\n * ```\n *\n * @param {CreateMultisigModularAccountClientParams} config the parameters for configuring the multisig modular account client\n * @returns {Promise<SmartAccountClient<Transport, Chain, MultisigModularAccount<SmartAccountSigner>, {}, SmartAccountClientRpcSchema, MultisigUserOperationContext>>} a promise that resolves to a `SmartAccountClient` object extended with the multisig modular account and additional actions\n */\nexport async function createMultisigModularAccountClient({\n transport,\n chain,\n ...params\n}: CreateMultisigModularAccountClientParams): Promise<\n | SmartAccountClient<\n Transport,\n Chain,\n MultisigModularAccount<SmartAccountSigner>,\n {},\n SmartAccountClientRpcSchema,\n MultisigUserOperationContext\n >\n | AlchemySmartAccountClient<\n Chain | undefined,\n MultisigModularAccount<SmartAccountSigner>,\n MultisigPluginActions<MultisigModularAccount<SmartAccountSigner>> &\n PluginManagerActions<MultisigModularAccount<SmartAccountSigner>> &\n AccountLoupeActions<MultisigModularAccount<SmartAccountSigner>>,\n MultisigUserOperationContext\n >\n> {\n const modularAccount = await createMultisigModularAccount({\n ...params,\n transport,\n chain,\n });\n if (isAlchemyTransport(transport, chain)) {\n // Need to fit the type into this since the previous multiSigAlchemyClient had it at this point, but without an Value as Type should be safe\n // And the createAlchemySmartAccountClient signUserOperation could not infer without this\n let config: AlchemyMultisigAccountClientConfig = {\n ...params,\n chain,\n transport,\n };\n const { opts } = config;\n\n return createAlchemySmartAccountClient({\n ...config,\n account: modularAccount,\n opts,\n signUserOperation: multisigSignatureMiddleware,\n })\n .extend(smartAccountClientActions)\n .extend(multisigPluginActions)\n .extend(pluginManagerActions)\n .extend(accountLoupeActions);\n }\n\n const client = createSmartAccountClient({\n ...params,\n transport,\n chain,\n account: modularAccount,\n signUserOperation: multisigSignatureMiddleware,\n })\n .extend(smartAccountClientActions)\n .extend(pluginManagerActions)\n .extend(multisigPluginActions)\n .extend(accountLoupeActions);\n\n return client;\n}\n"]}
@@ -1,6 +1,8 @@
1
1
  import { type SmartAccountSigner } from "@aa-sdk/core";
2
- import { type AlchemySmartAccountClient, type AlchemySmartAccountClientConfig } from "@account-kit/infra";
2
+ import { type AlchemySmartAccountClient, type AlchemySmartAccountClientConfig, type AlchemyTransport } from "@account-kit/infra";
3
3
  import { type AccountLoupeActions, type CreateMultisigModularAccountParams, type LightAccount, type MultisigModularAccount, type MultisigPluginActions, type MultisigUserOperationContext, type PluginManagerActions } from "@account-kit/smart-contracts";
4
4
  import { type Chain, type HttpTransport } from "viem";
5
- export type AlchemyMultisigAccountClientConfig<TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateMultisigModularAccountParams<HttpTransport, TSigner>, "transport"> & Omit<AlchemySmartAccountClientConfig<Chain, LightAccount<TSigner>, MultisigUserOperationContext>, "account">;
5
+ export type AlchemyMultisigAccountClientConfig<TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateMultisigModularAccountParams<HttpTransport, TSigner>, "transport"> & Omit<AlchemySmartAccountClientConfig<Chain, LightAccount<TSigner>, MultisigUserOperationContext>, "account"> & {
6
+ transport: AlchemyTransport;
7
+ };
6
8
  export declare function createMultisigAccountAlchemyClient<TSigner extends SmartAccountSigner = SmartAccountSigner>(params: AlchemyMultisigAccountClientConfig<TSigner>): Promise<AlchemySmartAccountClient<Chain | undefined, MultisigModularAccount<TSigner>, MultisigPluginActions<MultisigModularAccount<TSigner>> & PluginManagerActions<MultisigModularAccount<TSigner>> & AccountLoupeActions<MultisigModularAccount<TSigner>>, MultisigUserOperationContext>>;
@@ -1,6 +1,6 @@
1
- import { smartAccountClientActions, } from "@aa-sdk/core";
2
- import { createAlchemySmartAccountClient, } from "@account-kit/infra";
3
- import { accountLoupeActions, createMultisigModularAccount, multisigPluginActions, multisigSignatureMiddleware, pluginManagerActions, } from "@account-kit/smart-contracts";
1
+ import {} from "@aa-sdk/core";
2
+ import {} from "@account-kit/infra";
3
+ import { createMultisigModularAccountClient, } from "@account-kit/smart-contracts";
4
4
  import {} from "viem";
5
5
  /**
6
6
  * Creates an Alchemy client for a multisig account using the provided configuration.
@@ -21,25 +21,11 @@ import {} from "viem";
21
21
  * });
22
22
  * ```
23
23
  *
24
+ * @deprecated Use createModularAccountClient instead of this function, we are switching based on the transport
24
25
  * @param {AlchemyMultisigAccountClientConfig} config The configuration for the Alchemy multisig account client
25
26
  * @returns {Promise<AlchemySmartAccountClient<Transport, Chain | undefined, MultisigModularAccount<SmartAccountSigner>, MultisigPluginActions<MultisigModularAccount<SmartAccountSigner>> & PluginManagerActions<MultisigModularAccount<SmartAccountSigner>> & AccountLoupeActions<MultisigModularAccount<SmartAccountSigner>>, MultisigUserOperationContext>>} A promise that resolves to an Alchemy Smart Account Client for multisig accounts with extended functionalities.
26
27
  */
27
28
  export async function createMultisigAccountAlchemyClient(config) {
28
- const { transport, opts, chain } = config;
29
- const account = await createMultisigModularAccount({
30
- ...config,
31
- transport,
32
- chain,
33
- });
34
- return createAlchemySmartAccountClient({
35
- ...config,
36
- account,
37
- opts,
38
- signUserOperation: multisigSignatureMiddleware,
39
- })
40
- .extend(smartAccountClientActions)
41
- .extend(multisigPluginActions)
42
- .extend(pluginManagerActions)
43
- .extend(accountLoupeActions);
29
+ return createMultisigModularAccountClient(config);
44
30
  }
45
31
  //# sourceMappingURL=multiSigAlchemyClient.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"multiSigAlchemyClient.js","sourceRoot":"","sources":["../../../../../src/msca/client/multiSigAlchemyClient.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,yBAAyB,GAE1B,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,+BAA+B,GAGhC,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,mBAAmB,EACnB,4BAA4B,EAC5B,qBAAqB,EACrB,2BAA2B,EAC3B,oBAAoB,GAQrB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAkC,MAAM,MAAM,CAAC;AAkCtD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,CAAC,KAAK,UAAU,kCAAkC,CACtD,MAA0C;IAW1C,MAAM,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,MAAM,CAAC;IAE1C,MAAM,OAAO,GAAG,MAAM,4BAA4B,CAAC;QACjD,GAAG,MAAM;QACT,SAAS;QACT,KAAK;KACN,CAAC,CAAC;IAEH,OAAO,+BAA+B,CAAC;QACrC,GAAG,MAAM;QACT,OAAO;QACP,IAAI;QACJ,iBAAiB,EAAE,2BAA2B;KAC/C,CAAC;SACC,MAAM,CAAC,yBAAyB,CAAC;SACjC,MAAM,CAAC,qBAAqB,CAAC;SAC7B,MAAM,CAAC,oBAAoB,CAAC;SAC5B,MAAM,CAAC,mBAAmB,CAAC,CAAC;AACjC,CAAC","sourcesContent":["import {\n smartAccountClientActions,\n type SmartAccountSigner,\n} from \"@aa-sdk/core\";\nimport {\n createAlchemySmartAccountClient,\n type AlchemySmartAccountClient,\n type AlchemySmartAccountClientConfig,\n} from \"@account-kit/infra\";\nimport {\n accountLoupeActions,\n createMultisigModularAccount,\n multisigPluginActions,\n multisigSignatureMiddleware,\n pluginManagerActions,\n type AccountLoupeActions,\n type CreateMultisigModularAccountParams,\n type LightAccount,\n type MultisigModularAccount,\n type MultisigPluginActions,\n type MultisigUserOperationContext,\n type PluginManagerActions,\n} from \"@account-kit/smart-contracts\";\nimport { type Chain, type HttpTransport } from \"viem\";\n\n// todo: this file seems somewhat duplicated with ./modularAccountClient.ts, but that file has some multi-owner specific fields. Is there a way to refactor these two to de-dupe?\n\nexport type AlchemyMultisigAccountClientConfig<\n TSigner extends SmartAccountSigner = SmartAccountSigner\n> = Omit<\n CreateMultisigModularAccountParams<HttpTransport, TSigner>,\n \"transport\"\n> &\n Omit<\n AlchemySmartAccountClientConfig<\n Chain,\n LightAccount<TSigner>,\n MultisigUserOperationContext\n >,\n \"account\"\n >;\n\nexport function createMultisigAccountAlchemyClient<\n TSigner extends SmartAccountSigner = SmartAccountSigner\n>(\n params: AlchemyMultisigAccountClientConfig<TSigner>\n): Promise<\n AlchemySmartAccountClient<\n Chain | undefined,\n MultisigModularAccount<TSigner>,\n MultisigPluginActions<MultisigModularAccount<TSigner>> &\n PluginManagerActions<MultisigModularAccount<TSigner>> &\n AccountLoupeActions<MultisigModularAccount<TSigner>>,\n MultisigUserOperationContext\n >\n>;\n\n/**\n * Creates an Alchemy client for a multisig account using the provided configuration.\n *\n * @example\n * ```ts\n * import { createMultisigAccountAlchemyClient } from \"@account-kit/smart-contracts\";\n * import { sepolia } from \"@account-kit/infra\";\n * import { LocalAccountSigner } from \"@aa-sdk/core\";\n * import { generatePrivateKey } from \"viem\"\n *\n * const alchemyAccountClient = await createMultisigAccountAlchemyClient({\n * transport: alchemy({ apiKey: \"your-api-key\" }),\n * chain: sepolia,\n * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey()),\n * owners: [...], // other owners on the account\n * threshold: 2, // 2 of N signatures\n * });\n * ```\n *\n * @param {AlchemyMultisigAccountClientConfig} config The configuration for the Alchemy multisig account client\n * @returns {Promise<AlchemySmartAccountClient<Transport, Chain | undefined, MultisigModularAccount<SmartAccountSigner>, MultisigPluginActions<MultisigModularAccount<SmartAccountSigner>> & PluginManagerActions<MultisigModularAccount<SmartAccountSigner>> & AccountLoupeActions<MultisigModularAccount<SmartAccountSigner>>, MultisigUserOperationContext>>} A promise that resolves to an Alchemy Smart Account Client for multisig accounts with extended functionalities.\n */\nexport async function createMultisigAccountAlchemyClient(\n config: AlchemyMultisigAccountClientConfig\n): Promise<\n AlchemySmartAccountClient<\n Chain | undefined,\n MultisigModularAccount<SmartAccountSigner>,\n MultisigPluginActions<MultisigModularAccount<SmartAccountSigner>> &\n PluginManagerActions<MultisigModularAccount<SmartAccountSigner>> &\n AccountLoupeActions<MultisigModularAccount<SmartAccountSigner>>,\n MultisigUserOperationContext\n >\n> {\n const { transport, opts, chain } = config;\n\n const account = await createMultisigModularAccount({\n ...config,\n transport,\n chain,\n });\n\n return createAlchemySmartAccountClient({\n ...config,\n account,\n opts,\n signUserOperation: multisigSignatureMiddleware,\n })\n .extend(smartAccountClientActions)\n .extend(multisigPluginActions)\n .extend(pluginManagerActions)\n .extend(accountLoupeActions);\n}\n"]}
1
+ {"version":3,"file":"multiSigAlchemyClient.js","sourceRoot":"","sources":["../../../../../src/msca/client/multiSigAlchemyClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAA2B,MAAM,cAAc,CAAC;AACvD,OAAO,EAIN,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EACL,kCAAkC,GAQnC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAkC,MAAM,MAAM,CAAC;AAkCtD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,CAAC,KAAK,UAAU,kCAAkC,CACtD,MAA0C;IAW1C,OAAO,kCAAkC,CAAC,MAAM,CAAC,CAAC;AACpD,CAAC","sourcesContent":["import { type SmartAccountSigner } from \"@aa-sdk/core\";\nimport {\n type AlchemySmartAccountClient,\n type AlchemySmartAccountClientConfig,\n type AlchemyTransport,\n} from \"@account-kit/infra\";\nimport {\n createMultisigModularAccountClient,\n type AccountLoupeActions,\n type CreateMultisigModularAccountParams,\n type LightAccount,\n type MultisigModularAccount,\n type MultisigPluginActions,\n type MultisigUserOperationContext,\n type PluginManagerActions,\n} from \"@account-kit/smart-contracts\";\nimport { type Chain, type HttpTransport } from \"viem\";\n\n// todo: this file seems somewhat duplicated with ./modularAccountClient.ts, but that file has some multi-owner specific fields. Is there a way to refactor these two to de-dupe?\n\nexport type AlchemyMultisigAccountClientConfig<\n TSigner extends SmartAccountSigner = SmartAccountSigner\n> = Omit<\n CreateMultisigModularAccountParams<HttpTransport, TSigner>,\n \"transport\"\n> &\n Omit<\n AlchemySmartAccountClientConfig<\n Chain,\n LightAccount<TSigner>,\n MultisigUserOperationContext\n >,\n \"account\"\n > & { transport: AlchemyTransport };\n\nexport function createMultisigAccountAlchemyClient<\n TSigner extends SmartAccountSigner = SmartAccountSigner\n>(\n params: AlchemyMultisigAccountClientConfig<TSigner>\n): Promise<\n AlchemySmartAccountClient<\n Chain | undefined,\n MultisigModularAccount<TSigner>,\n MultisigPluginActions<MultisigModularAccount<TSigner>> &\n PluginManagerActions<MultisigModularAccount<TSigner>> &\n AccountLoupeActions<MultisigModularAccount<TSigner>>,\n MultisigUserOperationContext\n >\n>;\n\n/**\n * Creates an Alchemy client for a multisig account using the provided configuration.\n *\n * @example\n * ```ts\n * import { createMultisigAccountAlchemyClient } from \"@account-kit/smart-contracts\";\n * import { sepolia } from \"@account-kit/infra\";\n * import { LocalAccountSigner } from \"@aa-sdk/core\";\n * import { generatePrivateKey } from \"viem\"\n *\n * const alchemyAccountClient = await createMultisigAccountAlchemyClient({\n * transport: alchemy({ apiKey: \"your-api-key\" }),\n * chain: sepolia,\n * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey()),\n * owners: [...], // other owners on the account\n * threshold: 2, // 2 of N signatures\n * });\n * ```\n *\n * @deprecated Use createModularAccountClient instead of this function, we are switching based on the transport\n * @param {AlchemyMultisigAccountClientConfig} config The configuration for the Alchemy multisig account client\n * @returns {Promise<AlchemySmartAccountClient<Transport, Chain | undefined, MultisigModularAccount<SmartAccountSigner>, MultisigPluginActions<MultisigModularAccount<SmartAccountSigner>> & PluginManagerActions<MultisigModularAccount<SmartAccountSigner>> & AccountLoupeActions<MultisigModularAccount<SmartAccountSigner>>, MultisigUserOperationContext>>} A promise that resolves to an Alchemy Smart Account Client for multisig accounts with extended functionalities.\n */\nexport async function createMultisigAccountAlchemyClient(\n config: AlchemyMultisigAccountClientConfig\n): Promise<\n AlchemySmartAccountClient<\n Chain | undefined,\n MultisigModularAccount<SmartAccountSigner>,\n MultisigPluginActions<MultisigModularAccount<SmartAccountSigner>> &\n PluginManagerActions<MultisigModularAccount<SmartAccountSigner>> &\n AccountLoupeActions<MultisigModularAccount<SmartAccountSigner>>,\n MultisigUserOperationContext\n >\n> {\n return createMultisigModularAccountClient(config);\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"alchemyClient.d.ts","sourceRoot":"","sources":["../../../../../src/light-account/clients/alchemyClient.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,EAEL,KAAK,yBAAyB,EAC9B,KAAK,+BAA+B,EACrC,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAGL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EACjB,KAAK,yBAAyB,EAC/B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,MAAM,CAAC;AAElC,MAAM,MAAM,+BAA+B,CACzC,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,IAAI,CAAC,wBAAwB,CAAC,aAAa,EAAE,OAAO,CAAC,EAAE,WAAW,CAAC,GACrE,IAAI,CACF,+BAA+B,CAAC,KAAK,EAAE,YAAY,CAAC,OAAO,CAAC,CAAC,EAC7D,SAAS,CACV,CAAC;AAEJ,wBAAsB,+BAA+B,CACnD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,MAAM,EAAE,+BAA+B,CAAC,OAAO,CAAC,GAC/C,OAAO,CACR,yBAAyB,CACvB,KAAK,GAAG,SAAS,EACjB,YAAY,CAAC,OAAO,CAAC,EACrB,yBAAyB,CAAC,OAAO,CAAC,CACnC,CACF,CAAC"}
1
+ {"version":3,"file":"alchemyClient.d.ts","sourceRoot":"","sources":["../../../../../src/light-account/clients/alchemyClient.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,EACL,KAAK,yBAAyB,EAC9B,KAAK,+BAA+B,EACrC,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAEL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EACjB,KAAK,yBAAyB,EAC/B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,MAAM,CAAC;AAElC,MAAM,MAAM,+BAA+B,CACzC,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,IAAI,CAAC,wBAAwB,CAAC,aAAa,EAAE,OAAO,CAAC,EAAE,WAAW,CAAC,GACrE,IAAI,CACF,+BAA+B,CAAC,KAAK,EAAE,YAAY,CAAC,OAAO,CAAC,CAAC,EAC7D,SAAS,CACV,CAAC;AAEJ,wBAAsB,+BAA+B,CACnD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,MAAM,EAAE,+BAA+B,CAAC,OAAO,CAAC,GAC/C,OAAO,CACR,yBAAyB,CACvB,KAAK,GAAG,SAAS,EACjB,YAAY,CAAC,OAAO,CAAC,EACrB,yBAAyB,CAAC,OAAO,CAAC,CACnC,CACF,CAAC"}
@@ -1,10 +1,15 @@
1
- import { type SmartAccountClient, type SmartAccountClientActions, type SmartAccountClientConfig, type SmartAccountSigner, type SmartContractAccount } from "@aa-sdk/core";
1
+ import { type NotType, type SmartAccountClient, type SmartAccountClientActions, type SmartAccountClientConfig, type SmartAccountSigner, type SmartContractAccount } from "@aa-sdk/core";
2
2
  import { type Chain, type CustomTransport, type Transport } from "viem";
3
- import { type CreateLightAccountParams, type LightAccount } from "../accounts/account.js";
3
+ import { type CreateLightAccountParams, type LightAccount } from "@account-kit/smart-contracts";
4
4
  import { type LightAccountClientActions } from "../decorators/lightAccount.js";
5
- export type CreateLightAccountClientParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = {
5
+ import { type AlchemySmartAccountClient, type AlchemyTransport } from "@account-kit/infra";
6
+ import { type AlchemyLightAccountClientConfig } from "./alchemyClient.js";
7
+ export type CreateLightAccountClientParams<TTransport extends Transport | AlchemyTransport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = {
6
8
  transport: CreateLightAccountParams<TTransport, TSigner>["transport"];
7
9
  chain: CreateLightAccountParams<TTransport, TSigner>["chain"];
8
10
  } & Omit<CreateLightAccountParams<TTransport, TSigner>, "transport" | "chain"> & Omit<SmartAccountClientConfig<TTransport, TChain>, "transport" | "account" | "chain">;
9
- export declare function createLightAccountClient<TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateLightAccountClientParams<Transport, TChain, TSigner>): Promise<SmartAccountClient<CustomTransport, Chain, LightAccount<TSigner>, SmartAccountClientActions<Chain, SmartContractAccount> & LightAccountClientActions<TSigner, LightAccount<TSigner>>>>;
11
+ export declare function createLightAccountClient<TSigner extends SmartAccountSigner = SmartAccountSigner>(params: AlchemyLightAccountClientConfig<TSigner> & {
12
+ transport: AlchemyTransport;
13
+ }): Promise<AlchemySmartAccountClient<Chain | undefined, LightAccount<TSigner>, LightAccountClientActions<TSigner>>>;
14
+ export declare function createLightAccountClient<TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner, TTransport extends Transport = Transport>(args: CreateLightAccountClientParams<TTransport, TChain, TSigner> & NotType<TTransport, AlchemyTransport>): Promise<SmartAccountClient<CustomTransport, TChain, LightAccount<TSigner>, SmartAccountClientActions<Chain, SmartContractAccount> & LightAccountClientActions<TSigner, LightAccount<TSigner>>>>;
10
15
  //# sourceMappingURL=client.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../src/light-account/clients/client.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EAC1B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,eAAe,EAAE,KAAK,SAAS,EAAE,MAAM,MAAM,CAAC;AACxE,OAAO,EAEL,KAAK,wBAAwB,EAC7B,KAAK,YAAY,EAClB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAEL,KAAK,yBAAyB,EAC/B,MAAM,+BAA+B,CAAC;AAEvC,MAAM,MAAM,8BAA8B,CACxC,UAAU,SAAS,SAAS,GAAG,SAAS,EACxC,MAAM,SAAS,KAAK,GAAG,SAAS,GAAG,KAAK,GAAG,SAAS,EACpD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD;IACF,SAAS,EAAE,wBAAwB,CAAC,U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B,CAChB,eAAe,EACf,MAAM,EACN,YAAY,CAAC,OAAO,CAAC,EACrB,yBAAyB,CAAC,KAAK,EAAE,oBAAoB,CAAC,GACpD,yBAAyB,CAAC,OAAO,EAAE,YAAY,CAAC,OAAO,CAAC,CAAC,CAC5D,CACF,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"multiOwnerAlchemyClient.d.ts","sourceRoot":"","sources":["../../../../../src/light-account/clients/multiOwnerAlchemyClient.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,EAEL,KAAK,yBAAyB,EAC9B,KAAK,+BAA+B,EACrC,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAGL,KAAK,kCAAkC,EACvC,KAAK,sBAAsB,EAC3B,KAAK,mCAAmC,EACzC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,MAAM,CAAC;AAElC,MAAM,MAAM,yCAAyC,CACnD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,IAAI,CACN,kCAAkC,CAAC,aAAa,EAAE,OAAO,CAAC,EAC1D,WAAW,GAAG,MAAM,CACrB,GACC,IAAI,CACF,+BAA+B,CAAC,KAAK,EAAE,sBAAsB,CAAC,OAAO,CAAC,CAAC,EACvE,SAAS,CACV,CAAC;AAEJ,wBAAsB,yCAAyC,CAC7D,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,MAAM,EAAE,yCAAyC,CAAC,OAAO,CAAC,GACzD,OAAO,CACR,yBAAyB,CACvB,KAAK,GAAG,SAAS,EACjB,sBAAsB,CAAC,OAAO,CAAC,EAC/B,mCAAmC,CAAC,OAAO,CAAC,CAC7C,CACF,CAAC"}
1
+ {"version":3,"file":"multiOwnerAlchemyClient.d.ts","sourceRoot":"","sources":["../../../../../src/light-account/clients/multiOwnerAlchemyClient.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AACtE,OAAO,EACL,KAAK,yBAAyB,EAC9B,KAAK,+BAA+B,EACrC,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAEL,KAAK,kCAAkC,EACvC,KAAK,sBAAsB,EAC3B,KAAK,mCAAmC,EACzC,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,MAAM,CAAC;AAElC,MAAM,MAAM,yCAAyC,CACnD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,IAAI,CACN,kCAAkC,CAAC,aAAa,EAAE,OAAO,CAAC,EAC1D,WAAW,GAAG,MAAM,CACrB,GACC,IAAI,CACF,+BAA+B,CAAC,KAAK,EAAE,sBAAsB,CAAC,OAAO,CAAC,CAAC,EACvE,SAAS,CACV,CAAC;AAEJ,wBAAsB,yCAAyC,CAC7D,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,MAAM,EAAE,yCAAyC,CAAC,OAAO,CAAC,GACzD,OAAO,CACR,yBAAyB,CACvB,KAAK,GAAG,SAAS,EACjB,sBAAsB,CAAC,OAAO,CAAC,EAC/B,mCAAmC,CAAC,OAAO,CAAC,CAC7C,CACF,CAAC"}
@@ -1,10 +1,16 @@
1
- import { type SmartAccountClient, type SmartAccountClientActions, type SmartAccountClientConfig, type SmartAccountSigner, type SmartContractAccount } from "@aa-sdk/core";
1
+ import { type NotType, type SmartAccountClient, type SmartAccountClientActions, type SmartAccountClientConfig, type SmartAccountSigner, type SmartContractAccount } from "@aa-sdk/core";
2
2
  import { type Chain, type CustomTransport, type Transport } from "viem";
3
- import { type CreateMultiOwnerLightAccountParams, type MultiOwnerLightAccount } from "../accounts/multiOwner.js";
4
- import { type MultiOwnerLightAccountClientActions } from "../decorators/multiOwnerLightAccount.js";
3
+ import { type CreateMultiOwnerLightAccountParams, type MultiOwnerLightAccount, type MultiOwnerLightAccountClientActions, type AlchemyMultiOwnerLightAccountClientConfig } from "@account-kit/smart-contracts";
4
+ import { type AlchemySmartAccountClient, type AlchemyTransport } from "@account-kit/infra";
5
5
  export type CreateMultiOwnerLightAccountClientParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = {
6
6
  transport: CreateMultiOwnerLightAccountParams<TTransport, TSigner>["transport"];
7
7
  chain: CreateMultiOwnerLightAccountParams<TTransport, TSigner>["chain"];
8
8
  } & Omit<CreateMultiOwnerLightAccountParams<TTransport, TSigner>, "transport" | "chain"> & Omit<SmartAccountClientConfig<TTransport, TChain>, "transport" | "account" | "chain">;
9
- export declare function createMultiOwnerLightAccountClient<TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateMultiOwnerLightAccountClientParams<Transport, TChain, TSigner>): Promise<SmartAccountClient<CustomTransport, Chain, MultiOwnerLightAccount<TSigner>, SmartAccountClientActions<Chain, SmartContractAccount> & MultiOwnerLightAccountClientActions<TSigner, MultiOwnerLightAccount<TSigner>>>>;
9
+ export type CreateMultiOwnerLightAccountClientDynamicTransportParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = (AlchemyMultiOwnerLightAccountClientConfig<TSigner> & {
10
+ transport: AlchemyTransport;
11
+ }) | CreateMultiOwnerLightAccountClientParams<TTransport, TChain, TSigner>;
12
+ export declare function createMultiOwnerLightAccountClient<TSigner extends SmartAccountSigner = SmartAccountSigner>(params: AlchemyMultiOwnerLightAccountClientConfig<TSigner> & {
13
+ transport: AlchemyTransport;
14
+ }): Promise<AlchemySmartAccountClient<Chain | undefined, MultiOwnerLightAccount<TSigner>, MultiOwnerLightAccountClientActions<TSigner>>>;
15
+ export declare function createMultiOwnerLightAccountClient<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateMultiOwnerLightAccountClientParams<TTransport, TChain, TSigner> & NotType<TTransport, AlchemyTransport>): Promise<SmartAccountClient<CustomTransport, Chain, MultiOwnerLightAccount<TSigner>, SmartAccountClientActions<Chain, SmartContractAccount> & MultiOwnerLightAccountClientActions<TSigner, MultiOwnerLightAccount<TSigner>>>>;
10
16
  //# sourceMappingURL=multiOwnerLightAccount.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"multiOwnerLightAccount.d.ts","sourceRoot":"","sources":["../../../../../src/light-account/clients/multiOwnerLightAccount.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EAC1B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,eAAe,EAAE,KAAK,SAAS,EAAE,MAAM,MAAM,CAAC;AACxE,OAAO,EAEL,KAAK,kCAAkC,EACvC,KAAK,sBAAsB,EAC5B,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAEL,KAAK,mCAAmC,EACzC,MAAM,yCAAyC,CAAC;AAEjD,MAAM,MAAM,wCAAwC,CAClD,UAAU,SAAS,SAAS,GAAG,SAAS,EACxC,MAAM,SAAS,KAAK,GAAG,SAAS,GAAG,KAAK,GAAG,SAAS,EACpD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD;IACF,SAAS,EAAE,kCAAkC,CAC3C,UAAU,EACV,OAAO,CACR,CAAC,WAAW,CAAC,CAAC;IACf,KAAK,EAAE,kCAAkC,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC,OAAO,CAAC,CAAC;CACzE,GAAG,IAAI,CACN,kCAAkC,CAAC,UAAU,EAAE,OAAO,CAAC,EACvD,WAAW,GAAG,OAAO,CACtB,GACC,IAAI,CACF,wBAAwB,CAAC,UAAU,EAAE,MAAM,CAAC,EAC5C,WAAW,GAAG,SAAS,GAAG,OAAO,CAClC,CAAC;AAEJ,wBAAgB,kCAAkC,CAChD,MAAM,SAAS,KAAK,GAAG,SAAS,GAAG,KAAK,GAAG,SAAS,EACpD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,IAAI,EAAE,wCAAwC,CAAC,SAAS,EAAE,MAAM,EAAE,OAAO,CAAC,GACzE,OAAO,CACR,kBAAkB,CAChB,eAAe,EACf,KAAK,EACL,sBAAsB,CAAC,OAAO,CAAC,EAC/B,yBAAyB,CAAC,KAAK,EAAE,oBAAoB,CAAC,GACpD,mCAAmC,CACjC,OAAO,EACP,sBAAsB,CAAC,OAAO,CAAC,CAChC,CACJ,CACF,CAAC"}
1
+ {"version":3,"file":"multiOwnerLightAccount.d.ts","sourceRoot":"","sources":["../../../../../src/light-account/clients/multiOwnerLightAccount.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,OAAO,EACZ,KAAK,kBAAkB,EACvB,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EAC1B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,eAAe,EAAE,KAAK,SAAS,EAAE,MAAM,MAAM,CAAC;AACxE,OAAO,EAGL,KAAK,kCAAkC,EACvC,KAAK,sBAAsB,EAC3B,KAAK,mCAAmC,EACxC,KAAK,yCAAyC,EAC/C,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAGL,KAAK,yBAAyB,EAC9B,KAAK,gBAAgB,EACtB,MAAM,oBAAoB,CAAC;AAE5B,MAAM,MAAM,wCAAwC,CAClD,UAAU,SAAS,SAAS,GAAG,SAAS,EACxC,MAAM,SAAS,KAAK,GAAG,SAAS,GAAG,KAAK,GAAG,SAAS,EACpD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD;IACF,SAAS,EAAE,kCAAkC,CAC3C,UAAU,EACV,OAAO,CACR,CAAC,WAAW,CAAC,CAAC;IACf,KAAK,EAAE,k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CAAC,KAAK,EAAE,oBAAoB,CAAC,GACpD,mCAAmC,CACjC,OAAO,EACP,sBAAsB,CAAC,OAAO,CAAC,CAChC,CACJ,CACF,CAAC"}
@@ -1,7 +1,14 @@
1
- import { type SmartAccountClient, type SmartAccountSigner, type SmartAccountClientConfig } from "@aa-sdk/core";
1
+ import { type SmartAccountClient, type SmartAccountSigner, type SmartAccountClientConfig, type NotType } from "@aa-sdk/core";
2
2
  import { type Chain, type Transport } from "viem";
3
3
  import { type CreateSMAV2AccountParams, type MAV2Account } from "../account/semiModularAccountV2.js";
4
- export type SMAV2AccountClient<TSigner extends SmartAccountSigner = SmartAccountSigner> = SmartAccountClient<Transport, Chain, MAV2Account<TSigner>>;
4
+ import { type AlchemySmartAccountClientConfig, type AlchemyTransport } from "@account-kit/infra";
5
+ import type { LightAccount } from "../../light-account/accounts/account.js";
6
+ export type SMAV2AccountClient<TSigner extends SmartAccountSigner = SmartAccountSigner, TChain extends Chain = Chain, TTransport extends Transport | AlchemyTransport = Transport> = SmartAccountClient<TTransport, TChain, MAV2Account<TSigner>>;
5
7
  export type CreateSMAV2AccountClientParams<TTransport extends Transport = Transport, TChain extends Chain = Chain, TSigner extends SmartAccountSigner = SmartAccountSigner> = CreateSMAV2AccountParams<TTransport, TSigner> & Omit<SmartAccountClientConfig<TTransport, TChain>, "transport" | "account" | "chain">;
6
- export declare function createSMAV2AccountClient<TChain extends Chain = Chain, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateSMAV2AccountClientParams<Transport, TChain, TSigner>): Promise<SMAV2AccountClient<TSigner>>;
8
+ export type CreateSMAV2AlchemyAccountClientParams<TTransport extends Transport = Transport, TChain extends Chain = Chain, TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateSMAV2AccountClientParams<TTransport, TChain, TSigner>, "transport"> & Omit<AlchemySmartAccountClientConfig<TChain, LightAccount<TSigner>>, "account"> & {
9
+ paymasterAndData?: never;
10
+ dummyPaymasterAndData?: never;
11
+ };
12
+ export declare function createSMAV2AccountClient<TChain extends Chain = Chain, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateSMAV2AlchemyAccountClientParams<AlchemyTransport, TChain, TSigner>): Promise<SMAV2AccountClient<TSigner, TChain, AlchemyTransport>>;
13
+ export declare function createSMAV2AccountClient<TTransport extends Transport = Transport, TChain extends Chain = Chain, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateSMAV2AccountClientParams<TTransport, TChain, TSigner> & NotType<TTransport, AlchemyTransport>): Promise<SMAV2AccountClient<TSigner, TChain>>;
7
14
  //# sourceMappingURL=client.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../src/ma-v2/client/client.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,wBAAwB,EAC9B,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,SAAS,EAAE,MAAM,MAAM,CAAC;AAElD,OAAO,EAEL,KAAK,wBAAwB,EAC7B,KAAK,WAAW,EACjB,MAAM,oCAAoC,CAAC;AAE5C,MAAM,MAAM,kBAAkB,CAC5B,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,kBAAkB,CAAC,SAAS,EAAE,KAAK,EAAE,WAAW,CAAC,OAAO,CAAC,CAAC,CAAC;AAE/D,MAAM,MAAM,8BAA8B,CACxC,UAAU,SAAS,SAAS,GAAG,SAAS,EACxC,MAAM,SAAS,KAAK,GAAG,KAAK,EAC5B,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,wBAAwB,CAAC,UAAU,EAAE,OAAO,CAAC,GAC/C,IAAI,CACF,wBAAwB,CAAC,UAAU,EAAE,MAAM,CAAC,EAC5C,WAAW,GAAG,SAAS,GAAG,OAAO,CAClC,CAAC;AAEJ,wBAAgB,wBAAwB,CACtC,MAAM,SAAS,KAAK,GAAG,KAAK,EAC5B,OAA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E,MAAM,MAAM,CAAC;AAEtD,MAAM,MAAM,iCAAiC,CAC3C,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,IAAI,CACN,oCAAoC,CAAC,aAAa,EAAE,OAAO,CAAC,EAC5D,WAAW,CACZ,GACC,IAAI,CACF,+BAA+B,CAAC,KAAK,EAAE,YAAY,CAAC,OAAO,CAAC,CAAC,EAC7D,SAAS,CACV,CAAC;AAEJ,wBAAgB,iCAAiC,CAC/C,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,MAAM,EAAE,iCAAiC,CAAC,OAAO,CAAC,GACjD,OAAO,CACR,yBAAyB,CACvB,KAAK,GAAG,SAAS,EACjB,wBAAwB,CAAC,OAAO,CAAC,EACjC,uBAAuB,CAAC,wBAAwB,CAAC,OAAO,CAAC,CAAC,GACxD,oBAAoB,CAAC,wBAAwB,CAAC,OAAO,CAAC,CAAC,GACvD,mBAAmB,CAAC,wBAAwB,CAAC,OAAO,CAAC,CAAC,CACzD,CACF,CAAC"}
@@ -1,4 +1,4 @@
1
- import { type SmartAccountClient, type SmartAccountClientRpcSchema, type SmartAccountSigner } from "@aa-sdk/core";
1
+ import { type NotType, type SmartAccountClient, type SmartAccountClientRpcSchema, type SmartAccountSigner } from "@aa-sdk/core";
2
2
  import { type Chain, type CustomTransport, type Transport } from "viem";
3
3
  import type { CreateLightAccountClientParams } from "../../light-account/clients/client.js";
4
4
  import { type AccountLoupeActions } from "../account-loupe/decorator.js";
@@ -7,8 +7,17 @@ import { type CreateMultisigModularAccountParams, type MultisigModularAccount }
7
7
  import { type PluginManagerActions } from "../plugin-manager/decorator.js";
8
8
  import { type MultiOwnerPluginActions } from "../plugins/multi-owner/index.js";
9
9
  import { type MultisigPluginActions, type MultisigUserOperationContext } from "../plugins/multisig/index.js";
10
- export type CreateMultiOwnerModularAccountClientParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateMultiOwnerModularAccountParams<TTransport, TSigner>, "transport" | "chain"> & Omit<CreateLightAccountClientParams<TTransport, TChain, TSigner>, "account">;
11
- export type CreateMultisigModularAccountClientParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateMultisigModularAccountParams<TTransport, TSigner>, "transport" | "chain"> & Omit<CreateLightAccountClientParams<TTransport, TChain, TSigner>, "account">;
12
- export declare function createMultiOwnerModularAccountClient<TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateMultiOwnerModularAccountClientParams<Transport, TChain, TSigner>): Promise<SmartAccountClient<CustomTransport, Chain, MultiOwnerModularAccount<TSigner>, MultiOwnerPluginActions<MultiOwnerModularAccount<TSigner>> & PluginManagerActions<MultiOwnerModularAccount<TSigner>> & AccountLoupeActions<MultiOwnerModularAccount<TSigner>>>>;
13
- export declare function createMultisigModularAccountClient<TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateMultisigModularAccountClientParams<Transport, TChain, TSigner>): Promise<SmartAccountClient<CustomTransport, Chain, MultisigModularAccount<TSigner>, MultisigPluginActions<MultisigModularAccount<TSigner>> & PluginManagerActions<MultisigModularAccount<TSigner>> & AccountLoupeActions<MultisigModularAccount<TSigner>>, SmartAccountClientRpcSchema, MultisigUserOperationContext>>;
10
+ import type { AlchemyModularAccountClientConfig } from "./alchemyClient.js";
11
+ import { type AlchemySmartAccountClient, type AlchemyTransport } from "@account-kit/infra";
12
+ import type { AlchemyMultisigAccountClientConfig } from "./multiSigAlchemyClient.js";
13
+ export type CreateMultiOwnerModularAccountClientWithoutAlchemyParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateMultiOwnerModularAccountParams<TTransport, TSigner>, "transport" | "chain"> & Omit<CreateLightAccountClientParams<TTransport, TChain, TSigner>, "account">;
14
+ export type CreateMultiOwnerModularAccountClientParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = CreateMultiOwnerModularAccountClientWithoutAlchemyParams<TTransport, TChain, TSigner> | AlchemyModularAccountClientConfig<TSigner>;
15
+ export type CreateMultisigModularAccountClientWithoutAlchemyParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateMultisigModularAccountParams<TTransport, TSigner>, "transport" | "chain"> & Omit<CreateLightAccountClientParams<TTransport, TChain, TSigner>, "account">;
16
+ export type CreateMultisigModularAccountClientParams<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner> = CreateMultisigModularAccountClientWithoutAlchemyParams<TTransport, TChain, TSigner> | AlchemyMultisigAccountClientConfig<TSigner>;
17
+ export declare function createMultiOwnerModularAccountClient<TSigner extends SmartAccountSigner = SmartAccountSigner>(params: AlchemyModularAccountClientConfig<TSigner> & {
18
+ transport: AlchemyTransport;
19
+ }): Promise<AlchemySmartAccountClient<Chain | undefined, MultiOwnerModularAccount<TSigner>, MultiOwnerPluginActions<MultiOwnerModularAccount<TSigner>> & PluginManagerActions<MultiOwnerModularAccount<TSigner>> & AccountLoupeActions<MultiOwnerModularAccount<TSigner>>>>;
20
+ export declare function createMultiOwnerModularAccountClient<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateMultiOwnerModularAccountClientParams<TTransport, TChain, TSigner> & NotType<TTransport, AlchemyTransport>): Promise<SmartAccountClient<CustomTransport, Chain, MultiOwnerModularAccount<TSigner>, MultiOwnerPluginActions<MultiOwnerModularAccount<TSigner>> & PluginManagerActions<MultiOwnerModularAccount<TSigner>> & AccountLoupeActions<MultiOwnerModularAccount<TSigner>>>>;
21
+ export declare function createMultisigModularAccountClient<TSigner extends SmartAccountSigner = SmartAccountSigner>(params: AlchemyMultisigAccountClientConfig<TSigner>): Promise<AlchemySmartAccountClient<Chain | undefined, MultisigModularAccount<TSigner>, MultisigPluginActions<MultisigModularAccount<TSigner>> & PluginManagerActions<MultisigModularAccount<TSigner>> & AccountLoupeActions<MultisigModularAccount<TSigner>>, MultisigUserOperationContext>>;
22
+ export declare function createMultisigModularAccountClient<TTransport extends Transport = Transport, TChain extends Chain | undefined = Chain | undefined, TSigner extends SmartAccountSigner = SmartAccountSigner>(args: CreateMultisigModularAccountClientParams<TTransport, TChain, TSigner> & NotType<TTransport, AlchemyTransport>): Promise<SmartAccountClient<CustomTransport, Chain, MultisigModularAccount<TSigner>, MultisigPluginActions<MultisigModularAccount<TSigner>> & PluginManagerActions<MultisigModularAccount<TSigner>> & AccountLoupeActions<MultisigModularAccount<TSigner>>, SmartAccountClientRpcSchema, MultisigUserOperationContext>>;
14
23
  //# sourceMappingURL=client.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../src/msca/client/client.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,kBAAkB,EACvB,KAAK,2BAA2B,EAChC,KAAK,kBAAkB,EACxB,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,eAAe,EAAE,KAAK,SAAS,EAAE,MAAM,MAAM,CAAC;AACxE,OAAO,KAAK,EAAE,8BAA8B,EAAE,MAAM,uCAAuC,CAAC;AAC5F,OAAO,EAEL,KAAK,mBAAmB,EACzB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAEL,KAAK,oCAAoC,EACzC,KAAK,wBAAwB,EAC9B,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAEL,KAAK,kCAAkC,EACvC,KAAK,sBAAsB,EAC5B,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAEL,KAAK,oBAAoB,EAC1B,MAAM,gCAAgC,CAAC;AACxC,OAAO,EAEL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kC,CAAC,OAAO,CAAC,GAClD,OAAO,CACR,yBAAyB,CACvB,KAAK,GAAG,SAAS,EACjB,sBAAsB,CAAC,OAAO,CAAC,EAC/B,qBAAqB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,GACpD,oBAAoB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,GACrD,mBAAmB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,EACtD,4BAA4B,CAC7B,CACF,CAAC;AAEF,wBAAgB,kCAAkC,CAChD,UAAU,SAAS,SAAS,GAAG,SAAS,EACxC,MAAM,SAAS,KAAK,GAAG,SAAS,GAAG,KAAK,GAAG,SAAS,EACpD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,IAAI,EAAE,wCAAwC,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,CAAC,GACzE,OAAO,CAAC,UAAU,EAAE,gBAAgB,CAAC,GACtC,OAAO,CACR,kBAAkB,CAChB,eAAe,EACf,KAAK,EACL,sBAAsB,CAAC,OAAO,CAAC,EAC/B,qBAAqB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,GACpD,oBAAoB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,GACrD,mBAAmB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,EACtD,2BAA2B,EAC3B,4BAA4B,CAC7B,CACF,CAAC"}
@@ -1,7 +1,9 @@
1
1
  import { type SmartAccountSigner } from "@aa-sdk/core";
2
- import { type AlchemySmartAccountClient, type AlchemySmartAccountClientConfig } from "@account-kit/infra";
2
+ import { type AlchemySmartAccountClient, type AlchemySmartAccountClientConfig, type AlchemyTransport } from "@account-kit/infra";
3
3
  import { type AccountLoupeActions, type CreateMultisigModularAccountParams, type LightAccount, type MultisigModularAccount, type MultisigPluginActions, type MultisigUserOperationContext, type PluginManagerActions } from "@account-kit/smart-contracts";
4
4
  import { type Chain, type HttpTransport } from "viem";
5
- export type AlchemyMultisigAccountClientConfig<TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateMultisigModularAccountParams<HttpTransport, TSigner>, "transport"> & Omit<AlchemySmartAccountClientConfig<Chain, LightAccount<TSigner>, MultisigUserOperationContext>, "account">;
5
+ export type AlchemyMultisigAccountClientConfig<TSigner extends SmartAccountSigner = SmartAccountSigner> = Omit<CreateMultisigModularAccountParams<HttpTransport, TSigner>, "transport"> & Omit<AlchemySmartAccountClientConfig<Chain, LightAccount<TSigner>, MultisigUserOperationContext>, "account"> & {
6
+ transport: AlchemyTransport;
7
+ };
6
8
  export declare function createMultisigAccountAlchemyClient<TSigner extends SmartAccountSigner = SmartAccountSigner>(params: AlchemyMultisigAccountClientConfig<TSigner>): Promise<AlchemySmartAccountClient<Chain | undefined, MultisigModularAccount<TSigner>, MultisigPluginActions<MultisigModularAccount<TSigner>> & PluginManagerActions<MultisigModularAccount<TSigner>> & AccountLoupeActions<MultisigModularAccount<TSigner>>, MultisigUserOperationContext>>;
7
9
  //# sourceMappingURL=multiSigAlchemyClient.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"multiSigAlchemyClient.d.ts","sourceRoot":"","sources":["../../../../../src/msca/client/multiSigAlchemyClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,kBAAkB,EACxB,MAAM,cAAc,CAAC;AACtB,OAAO,EAEL,KAAK,yBAAyB,EAC9B,KAAK,+BAA+B,EACrC,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAML,KAAK,mBAAmB,EACxB,KAAK,kCAAkC,EACvC,KAAK,YAAY,EACjB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,4BAA4B,EACjC,KAAK,oBAAoB,EAC1B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,aAAa,EAAE,MAAM,MAAM,CAAC;AAItD,MAAM,MAAM,kCAAkC,CAC5C,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,IAAI,CACN,kCAAkC,CAAC,aAAa,EAAE,OAAO,CAAC,EAC1D,WAAW,CACZ,GACC,IAAI,CACF,+BAA+B,CAC7B,KAAK,EACL,YAAY,CAAC,OAAO,CAAC,EACrB,4BAA4B,CAC7B,EACD,SAAS,CACV,CAAC;AAEJ,wBAAgB,kCAAkC,CAChD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,MAAM,EAAE,kCAAkC,CAAC,OAAO,CAAC,GAClD,OAAO,CACR,yBAAyB,CACvB,KAAK,GAAG,SAAS,EACjB,sBAAsB,CAAC,OAAO,CAAC,EAC/B,qBAAqB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,GACpD,oBAAoB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,GACrD,mBAAmB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,EACtD,4BAA4B,CAC7B,CACF,CAAC"}
1
+ {"version":3,"file":"multiSigAlchemyClient.d.ts","sourceRoot":"","sources":["../../../../../src/msca/client/multiSigAlchemyClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,kBAAkB,EAAE,MAAM,cAAc,CAAC;AACvD,OAAO,EACL,KAAK,yBAAyB,EAC9B,KAAK,+BAA+B,EACpC,KAAK,gBAAgB,EACtB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAEL,KAAK,mBAAmB,EACxB,KAAK,kCAAkC,EACvC,KAAK,YAAY,EACjB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,4BAA4B,EACjC,KAAK,oBAAoB,EAC1B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,KAAK,KAAK,EAAE,KAAK,aAAa,EAAE,MAAM,MAAM,CAAC;AAItD,MAAM,MAAM,kCAAkC,CAC5C,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,IACrD,IAAI,CACN,kCAAkC,CAAC,aAAa,EAAE,OAAO,CAAC,EAC1D,WAAW,CACZ,GACC,IAAI,CACF,+BAA+B,CAC7B,KAAK,EACL,YAAY,CAAC,OAAO,CAAC,EACrB,4BAA4B,CAC7B,EACD,SAAS,CACV,GAAG;IAAE,SAAS,EAAE,gBAAgB,CAAA;CAAE,CAAC;AAEtC,wBAAgB,kCAAkC,CAChD,OAAO,SAAS,kBAAkB,GAAG,kBAAkB,EAEvD,MAAM,EAAE,kCAAkC,CAAC,OAAO,CAAC,GAClD,OAAO,CACR,yBAAyB,CACvB,KAAK,GAAG,SAAS,EACjB,sBAAsB,CAAC,OAAO,CAAC,EAC/B,qBAAqB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,GACpD,oBAAoB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,GACrD,mBAAmB,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,EACtD,4BAA4B,CAC7B,CACF,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@account-kit/smart-contracts",
3
- "version": "4.8.0",
3
+ "version": "4.10.0",
4
4
  "description": "aa-sdk compatible interfaces for Alchemy Smart Accounts",
5
5
  "author": "Alchemy",
6
6
  "license": "MIT",
@@ -19,6 +19,7 @@
19
19
  "!vitest.config.ts",
20
20
  "!.env",
21
21
  "!src/**/*.test.ts",
22
+ "!src/**/*.test-d.ts",
22
23
  "!src/__tests__/**/*"
23
24
  ],
24
25
  "exports": {
@@ -51,7 +52,7 @@
51
52
  "test:run": "vitest run"
52
53
  },
53
54
  "devDependencies": {
54
- "@account-kit/plugingen": "^4.8.0",
55
+ "@account-kit/plugingen": "^4.10.0",
55
56
  "change-case": "^5.1.2",
56
57
  "dedent": "^1.5.1",
57
58
  "dotenv": "^16.3.1",
@@ -71,10 +72,10 @@
71
72
  "url": "https://github.com/alchemyplatform/aa-sdk/issues"
72
73
  },
73
74
  "homepage": "https://github.com/alchemyplatform/aa-sdk#readme",
74
- "gitHead": "06d9deda91e24f7c654bbf2e5713644fd39f6a85",
75
+ "gitHead": "8acd2d8e45410bfb2d7e4447d3a130e23e605cd4",
75
76
  "dependencies": {
76
- "@aa-sdk/core": "^4.8.0",
77
- "@account-kit/infra": "^4.8.0"
77
+ "@aa-sdk/core": "^4.10.0",
78
+ "@account-kit/infra": "^4.10.0"
78
79
  },
79
80
  "peerDependencies": {
80
81
  "viem": "^2.20.0"
@@ -1,12 +1,10 @@
1
1
  import type { HttpTransport, SmartAccountSigner } from "@aa-sdk/core";
2
2
  import {
3
- createAlchemySmartAccountClient,
4
3
  type AlchemySmartAccountClient,
5
4
  type AlchemySmartAccountClientConfig,
6
5
  } from "@account-kit/infra";
7
6
  import {
8
- createLightAccount,
9
- lightAccountClientActions,
7
+ createLightAccountClient,
10
8
  type CreateLightAccountParams,
11
9
  type LightAccount,
12
10
  type LightAccountClientActions,
@@ -49,7 +47,7 @@ export async function createLightAccountAlchemyClient<
49
47
  * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey())
50
48
  * });
51
49
  * ```
52
- *
50
+ * @deprecated Use createLightAccountClient instead now, it should switch depending on the transport
53
51
  * @param {AlchemyLightAccountClientConfig} config The configuration for setting up the Alchemy Light Account Client
54
52
  * @returns {Promise<AlchemySmartAccountClient>} A promise that resolves to an `AlchemySmartAccountClient` object containing the created client
55
53
  */
@@ -59,17 +57,10 @@ export async function createLightAccountAlchemyClient({
59
57
  chain,
60
58
  ...config
61
59
  }: AlchemyLightAccountClientConfig): Promise<AlchemySmartAccountClient> {
62
- const account = await createLightAccount({
63
- ...config,
60
+ return createLightAccountClient({
61
+ opts,
64
62
  transport,
65
63
  chain,
66
- });
67
-
68
- return createAlchemySmartAccountClient({
69
64
  ...config,
70
- transport,
71
- chain,
72
- account,
73
- opts,
74
- }).extend(lightAccountClientActions);
65
+ });
75
66
  }
@@ -1,5 +1,6 @@
1
1
  import {
2
2
  createSmartAccountClient,
3
+ type NotType,
3
4
  type SmartAccountClient,
4
5
  type SmartAccountClientActions,
5
6
  type SmartAccountClientConfig,
@@ -11,14 +12,21 @@ import {
11
12
  createLightAccount,
12
13
  type CreateLightAccountParams,
13
14
  type LightAccount,
14
- } from "../accounts/account.js";
15
+ } from "@account-kit/smart-contracts";
15
16
  import {
16
17
  lightAccountClientActions,
17
18
  type LightAccountClientActions,
18
19
  } from "../decorators/lightAccount.js";
20
+ import {
21
+ isAlchemyTransport,
22
+ createAlchemySmartAccountClient,
23
+ type AlchemySmartAccountClient,
24
+ type AlchemyTransport,
25
+ } from "@account-kit/infra";
26
+ import { type AlchemyLightAccountClientConfig } from "./alchemyClient.js";
19
27
 
20
28
  export type CreateLightAccountClientParams<
21
- TTransport extends Transport = Transport,
29
+ TTransport extends Transport | AlchemyTransport = Transport,
22
30
  TChain extends Chain | undefined = Chain | undefined,
23
31
  TSigner extends SmartAccountSigner = SmartAccountSigner
24
32
  > = {
@@ -31,14 +39,29 @@ export type CreateLightAccountClientParams<
31
39
  >;
32
40
 
33
41
  export function createLightAccountClient<
34
- TChain extends Chain | undefined = Chain | undefined,
35
42
  TSigner extends SmartAccountSigner = SmartAccountSigner
36
43
  >(
37
- args: CreateLightAccountClientParams<Transport, TChain, TSigner>
44
+ params: AlchemyLightAccountClientConfig<TSigner> & {
45
+ transport: AlchemyTransport;
46
+ }
47
+ ): Promise<
48
+ AlchemySmartAccountClient<
49
+ Chain | undefined,
50
+ LightAccount<TSigner>,
51
+ LightAccountClientActions<TSigner>
52
+ >
53
+ >;
54
+ export function createLightAccountClient<
55
+ TChain extends Chain | undefined = Chain | undefined,
56
+ TSigner extends SmartAccountSigner = SmartAccountSigner,
57
+ TTransport extends Transport = Transport
58
+ >(
59
+ args: CreateLightAccountClientParams<TTransport, TChain, TSigner> &
60
+ NotType<TTransport, AlchemyTransport>
38
61
  ): Promise<
39
62
  SmartAccountClient<
40
63
  CustomTransport,
41
- Chain,
64
+ TChain,
42
65
  LightAccount<TSigner>,
43
66
  SmartAccountClientActions<Chain, SmartContractAccount> &
44
67
  LightAccountClientActions<TSigner, LightAccount<TSigner>>
@@ -48,6 +71,8 @@ export function createLightAccountClient<
48
71
  /**
49
72
  * Creates a light account client using the provided parameters, including account information, transport mechanism, blockchain chain, and additional client configurations. This function first creates a light account and then uses it to create a smart account client, extending it with light account client actions.
50
73
  *
74
+ * Also, we modified the return type to be the light account alchemy client if the transport is alchemy.
75
+ *
51
76
  * @example
52
77
  * ```ts
53
78
  * import { createLightAccountClient } from "@account-kit/smart-contracts";
@@ -61,13 +86,26 @@ export function createLightAccountClient<
61
86
  * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey())
62
87
  * });
63
88
  * ```
89
+ * @example
90
+ * ```ts
91
+ * import { createLightAccountClient } from "@account-kit/smart-contracts";
92
+ * import { sepolia, alchemy } from "@account-kit/infra";
93
+ * import { LocalAccountSigner } from "@aa-sdk/core";
94
+ * import { generatePrivateKey } from "viem"
95
+ *
96
+ * const lightAlchemyAccountClient = await createLightAccountClient({
97
+ * transport: alchemy({ apiKey: "your-api-key" }),
98
+ * chain: sepolia,
99
+ * signer: LocalAccountSigner.privateKeyToAccountSigner(generatePrivateKey())
100
+ * });
101
+ * ```
64
102
  *
65
103
  * @param {CreateLightAccountClientParams} params The parameters for creating a light account client
66
104
  * @returns {Promise<SmartAccountClient>} A promise that resolves to a `SmartAccountClient` object containing the created account information and methods
67
105
  */
68
106
  export async function createLightAccountClient(
69
107
  params: CreateLightAccountClientParams
70
- ): Promise<SmartAccountClient> {
108
+ ): Promise<SmartAccountClient | AlchemySmartAccountClient> {
71
109
  const { transport, chain } = params;
72
110
 
73
111
  const lightAccount = await createLightAccount({
@@ -75,6 +113,14 @@ export async function createLightAccountClient(
75
113
  transport,
76
114
  chain,
77
115
  });
116
+ if (isAlchemyTransport(transport, chain)) {
117
+ return createAlchemySmartAccountClient({
118
+ ...params,
119
+ transport,
120
+ chain,
121
+ account: lightAccount,
122
+ }).extend(lightAccountClientActions);
123
+ }
78
124
 
79
125
  return createSmartAccountClient({
80
126
  ...params,
@@ -1,12 +1,10 @@
1
1
  import type { HttpTransport, SmartAccountSigner } from "@aa-sdk/core";
2
2
  import {
3
- createAlchemySmartAccountClient,
4
3
  type AlchemySmartAccountClient,
5
4
  type AlchemySmartAccountClientConfig,
6
5
  } from "@account-kit/infra";
7
6
  import {
8
- createMultiOwnerLightAccount,
9
- multiOwnerLightAccountClientActions,
7
+ createMultiOwnerLightAccountClient,
10
8
  type CreateMultiOwnerLightAccountParams,
11
9
  type MultiOwnerLightAccount,
12
10
  type MultiOwnerLightAccountClientActions,
@@ -55,6 +53,7 @@ export async function createMultiOwnerLightAccountAlchemyClient<
55
53
  * });
56
54
  * ```
57
55
  *
56
+ * @deprecated Use createMultiOwnerLightAccountAlchemyClient instead now, it should switch depending on the transport
58
57
  * @param {AlchemyMultiOwnerLightAccountClientConfig} config The configuration for creating the Alchemy client
59
58
  * @returns {Promise<AlchemySmartAccountClient>} A promise that resolves to an `AlchemySmartAccountClient` object containing the created account information and methods
60
59
  */
@@ -64,17 +63,10 @@ export async function createMultiOwnerLightAccountAlchemyClient({
64
63
  chain,
65
64
  ...config
66
65
  }: AlchemyMultiOwnerLightAccountClientConfig): Promise<AlchemySmartAccountClient> {
67
- const account = await createMultiOwnerLightAccount({
68
- ...config,
66
+ return createMultiOwnerLightAccountClient({
67
+ opts,
69
68
  transport,
70
69
  chain,
71
- });
72
-
73
- return createAlchemySmartAccountClient({
74
70
  ...config,
75
- transport,
76
- chain,
77
- account,
78
- opts,
79
- }).extend(multiOwnerLightAccountClientActions);
71
+ });
80
72
  }