@joai/warps-adapter-evm 1.2.1 → 1.3.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.d.cts CHANGED
@@ -203,6 +203,7 @@ declare class WarpEvmDataLoader implements AdapterWarpDataLoader {
203
203
  getAccountAssets(address: string): Promise<WarpChainAsset[]>;
204
204
  getAsset(identifier: string): Promise<WarpChainAsset | null>;
205
205
  getAction(identifier: string, awaitCompleted?: boolean): Promise<WarpChainAction | null>;
206
+ getAccountNfts(address: string, options?: WarpDataLoaderOptions): Promise<WarpChainAsset[]>;
206
207
  getAccountActions(address: string, options?: WarpDataLoaderOptions): Promise<WarpChainAction[]>;
207
208
  private getERC20TokenBalances;
208
209
  private getTokenBalance;
@@ -255,9 +256,8 @@ declare class WarpEvmOutput implements AdapterWarpOutput {
255
256
  private readonly chain;
256
257
  private readonly serializer;
257
258
  private readonly provider;
258
- private readonly cache;
259
259
  constructor(config: WarpClientConfig, chain: WarpChainInfo);
260
- getActionExecution(warp: Warp, actionIndex: WarpActionIndex, tx: WarpAdapterGenericRemoteTransaction): Promise<WarpActionExecutionResult>;
260
+ getActionExecution(warp: Warp, actionIndex: WarpActionIndex, tx: WarpAdapterGenericRemoteTransaction, injectedInputs?: ResolvedInput[]): Promise<WarpActionExecutionResult>;
261
261
  private createFailedExecution;
262
262
  private handleWarpChainAction;
263
263
  private handleTransactionReceipt;
package/dist/index.d.ts CHANGED
@@ -203,6 +203,7 @@ declare class WarpEvmDataLoader implements AdapterWarpDataLoader {
203
203
  getAccountAssets(address: string): Promise<WarpChainAsset[]>;
204
204
  getAsset(identifier: string): Promise<WarpChainAsset | null>;
205
205
  getAction(identifier: string, awaitCompleted?: boolean): Promise<WarpChainAction | null>;
206
+ getAccountNfts(address: string, options?: WarpDataLoaderOptions): Promise<WarpChainAsset[]>;
206
207
  getAccountActions(address: string, options?: WarpDataLoaderOptions): Promise<WarpChainAction[]>;
207
208
  private getERC20TokenBalances;
208
209
  private getTokenBalance;
@@ -255,9 +256,8 @@ declare class WarpEvmOutput implements AdapterWarpOutput {
255
256
  private readonly chain;
256
257
  private readonly serializer;
257
258
  private readonly provider;
258
- private readonly cache;
259
259
  constructor(config: WarpClientConfig, chain: WarpChainInfo);
260
- getActionExecution(warp: Warp, actionIndex: WarpActionIndex, tx: WarpAdapterGenericRemoteTransaction): Promise<WarpActionExecutionResult>;
260
+ getActionExecution(warp: Warp, actionIndex: WarpActionIndex, tx: WarpAdapterGenericRemoteTransaction, injectedInputs?: ResolvedInput[]): Promise<WarpActionExecutionResult>;
261
261
  private createFailedExecution;
262
262
  private handleWarpChainAction;
263
263
  private handleTransactionReceipt;
package/dist/index.js CHANGED
@@ -1044,6 +1044,9 @@ var _WarpEvmDataLoader = class _WarpEvmDataLoader {
1044
1044
  return null;
1045
1045
  }
1046
1046
  }
1047
+ async getAccountNfts(address, options) {
1048
+ return [];
1049
+ }
1047
1050
  async getAccountActions(address, options) {
1048
1051
  return [];
1049
1052
  }
@@ -1423,10 +1426,9 @@ var WarpEvmOutput = class {
1423
1426
  const providerConfig = (0, import_warps18.getProviderConfig)(this.config, this.chain.name, this.config.env, this.chain.defaultApiUrl);
1424
1427
  const network = new import_ethers5.ethers.Network(this.chain.name, parseInt(this.chain.chainId));
1425
1428
  this.provider = new import_ethers5.ethers.JsonRpcProvider(providerConfig.url, network);
1426
- this.cache = new import_warps18.WarpCache(config.env, config.cache);
1427
1429
  }
1428
- async getActionExecution(warp, actionIndex, tx) {
1429
- const inputs = await this.cache.get(import_warps18.WarpCacheKey.WarpExecutable(this.config.env, warp.meta?.hash || "", actionIndex)) ?? [];
1430
+ async getActionExecution(warp, actionIndex, tx, injectedInputs) {
1431
+ const inputs = injectedInputs ?? [];
1430
1432
  const resolvedInputs = (0, import_warps18.extractResolvedInputValues)(inputs);
1431
1433
  if (!tx) {
1432
1434
  return this.createFailedExecution(warp, actionIndex, resolvedInputs);
@@ -2316,7 +2318,7 @@ var NativeTokenEth = {
2316
2318
  var EthereumAdapter = createEvmAdapter(import_warps24.WarpChainName.Ethereum, {
2317
2319
  mainnet: {
2318
2320
  name: import_warps24.WarpChainName.Ethereum,
2319
- displayName: "Ethereum Mainnet",
2321
+ displayName: "Ethereum",
2320
2322
  chainId: "1",
2321
2323
  blockTime: 12e3,
2322
2324
  addressHrp: "0x",
@@ -2431,7 +2433,7 @@ var NativeTokenStt = {
2431
2433
  var SomniaAdapter = createEvmAdapter(import_warps26.WarpChainName.Somnia, {
2432
2434
  mainnet: {
2433
2435
  name: import_warps26.WarpChainName.Somnia,
2434
- displayName: "Somnia Mainnet",
2436
+ displayName: "Somnia",
2435
2437
  chainId: "5031",
2436
2438
  blockTime: 100,
2437
2439
  addressHrp: "0x",