@joai/warps-adapter-evm 1.3.1 → 1.4.1

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/index.mjs CHANGED
@@ -1811,6 +1811,12 @@ var WarpEvmExecutor = class {
1811
1811
  return nativeValue;
1812
1812
  });
1813
1813
  }
1814
+ async createDeployTransaction() {
1815
+ throw new Error("WarpEvmExecutor: Contract deployment not supported");
1816
+ }
1817
+ async createUpgradeTransaction() {
1818
+ throw new Error("WarpEvmExecutor: Contract upgrade not supported");
1819
+ }
1814
1820
  };
1815
1821
 
1816
1822
  // src/WarpEvmExplorer.ts
@@ -1936,10 +1942,7 @@ var WarpEvmExplorer = class {
1936
1942
  import {
1937
1943
  getProviderConfig as getProviderConfig4
1938
1944
  } from "@joai/warps";
1939
- import { toClientEvmSigner } from "@x402/evm";
1940
- import { registerExactEvmScheme } from "@x402/evm/exact/client";
1941
1945
  import { ethers as ethers7 } from "ethers";
1942
- import { createPublicClient, http } from "viem";
1943
1946
  import { privateKeyToAccount } from "viem/accounts";
1944
1947
  var WarpEvmWallet = class {
1945
1948
  constructor(config, chain) {
@@ -2046,26 +2049,14 @@ var WarpEvmWallet = class {
2046
2049
  getPublicKey() {
2047
2050
  return this.cachedPublicKey;
2048
2051
  }
2049
- async registerX402Handlers(client) {
2052
+ async getMppAccount() {
2050
2053
  if (!this.walletProvider) throw new Error("No wallet provider available");
2051
2054
  const provider = this.walletProvider;
2052
2055
  const getInstance = provider.getWalletInstance;
2053
- if (typeof getInstance !== "function") throw new Error("Wallet provider does not have getWalletInstance method");
2056
+ if (typeof getInstance !== "function") throw new Error("Wallet provider does not support getMppAccount");
2054
2057
  const wallet = getInstance();
2055
- if (!wallet || !wallet.privateKey) throw new Error("Wallet instance does not have private key");
2056
- const signer = toClientEvmSigner(
2057
- privateKeyToAccount(wallet.privateKey),
2058
- createPublicClient({
2059
- transport: http(getProviderConfig4(this.config, this.chain.name, this.config.env, this.chain.defaultApiUrl).url)
2060
- })
2061
- );
2062
- const handlers = {};
2063
- for (const chainId of SupportedEvmChainIds) {
2064
- handlers[`eip155:${chainId}`] = () => {
2065
- registerExactEvmScheme(client, { signer });
2066
- };
2067
- }
2068
- return handlers;
2058
+ if (!wallet?.privateKey) throw new Error("Wallet instance does not have a private key");
2059
+ return privateKeyToAccount(wallet.privateKey);
2069
2060
  }
2070
2061
  createProvider() {
2071
2062
  const wallet = this.config.user?.wallets?.[this.chain.name];