@0xsquid/sdk
Advanced tools
Comparing version 2.1.0 to 2.2.0
"use strict"; | ||
var __importDefault = (this && this.__importDefault) || function (mod) { | ||
return (mod && mod.__esModule) ? mod : { "default": mod }; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
@@ -10,5 +7,3 @@ exports.EvmHandler = void 0; | ||
const utils_1 = require("./utils"); | ||
const erc20_json_1 = __importDefault(require("../../abi/erc20.json")); | ||
const ethersAdapter = new EthersAdapter_1.EthersAdapter(); | ||
const erc20Interface = ethersAdapter.interface(erc20_json_1.default); | ||
class EvmHandler extends utils_1.Utils { | ||
@@ -15,0 +10,0 @@ async executeRoute({ data, params }) { |
@@ -1,3 +0,3 @@ | ||
import { RouteRequest } from "@0xsquid/squid-types"; | ||
import { Config, RouteData, GetStatus, ExecuteRoute, TransactionResponses } from "./types"; | ||
import { RouteRequest, RouteResponse } from "@0xsquid/squid-types"; | ||
import { Config, GetStatus, ExecuteRoute, TransactionResponses } from "./types"; | ||
import { TokensChains } from "./TokensChains"; | ||
@@ -16,7 +16,7 @@ export declare class Squid extends TokensChains { | ||
getRoute(params: RouteRequest): Promise<{ | ||
route: RouteData; | ||
route: RouteResponse; | ||
}>; | ||
executeRoute(data: ExecuteRoute): Promise<TransactionResponses>; | ||
isRouteApproved({ route, sender }: { | ||
route: RouteData; | ||
route: RouteResponse["route"]; | ||
sender: string; | ||
@@ -23,0 +23,0 @@ }): Promise<{ |
@@ -116,3 +116,3 @@ "use strict"; | ||
this.validateTransactionRequest(data.route); | ||
const params = this.populateRouteParams(data.route.params); | ||
const params = this.populateRouteParams(data.route.params, data.signer); | ||
switch (params.fromChain.chainType) { | ||
@@ -119,0 +119,0 @@ case squid_types_1.ChainType.EVM: |
@@ -1,2 +0,2 @@ | ||
import { ChainData, Token, SquidData, RouteRequest, Estimate } from "@0xsquid/squid-types"; | ||
import { ChainData, Token, RouteRequest, RouteResponse } from "@0xsquid/squid-types"; | ||
import { DeliverTxResponse, SigningStargateClient } from "@cosmjs/stargate"; | ||
@@ -15,7 +15,2 @@ import { EvmWallet, TransactionResponse, RpcProvider, Contract, GasData } from "./ethers"; | ||
}; | ||
export type RouteData = { | ||
estimate: Estimate; | ||
transactionRequest: SquidData; | ||
params: RouteRequest; | ||
}; | ||
export type OverrideParams = GasData; | ||
@@ -28,3 +23,3 @@ export type ExecutionSettings = { | ||
signer: EvmWallet | CosmosSigner; | ||
route: RouteData; | ||
route: RouteResponse["route"]; | ||
executionSettings?: ExecutionSettings; | ||
@@ -31,0 +26,0 @@ overrides?: OverrideParams; |
{ | ||
"name": "@0xsquid/sdk", | ||
"version": "2.1.0", | ||
"version": "2.2.0", | ||
"description": "🛠 An SDK for building applications on top of 0xsquid", | ||
@@ -5,0 +5,0 @@ "repository": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
0
52237
969