UNPKG

@orionprotocol/contracts

Version:
51 lines (50 loc) 5.37 kB
/// <reference types="node" /> import type BN from "bn.js"; import type { ContractOptions } from "web3-eth-contract"; import type { EventLog } from "web3-core"; import type { EventEmitter } from "events"; import type { Callback, PayableTransactionObject, NonPayableTransactionObject, BlockType, BaseContract } from "./types"; export interface EventOptions { filter?: object; fromBlock?: BlockType; topics?: string[]; } export interface SwapExecutor extends BaseContract { constructor(jsonInterface: any[], address?: string, options?: ContractOptions): SwapExecutor; clone(): SwapExecutor; methods: { AlgebraSwapCallback(amount0Delta: number | string | BN, amount1Delta: number | string | BN, data: string | number[]): NonPayableTransactionObject<void>; curveSwapMetaAmountIn(pool: string, assetOut: string, i: number | string | BN, j: number | string | BN, amountIn: number | string | BN, amountOut: number | string | BN, to: string): NonPayableTransactionObject<void>; curveSwapStableAmountIn(pool: string, assetOut: string, i: number | string | BN, j: number | string | BN, to: string, amountIn: number | string | BN): NonPayableTransactionObject<void>; curveSwapStableAmountOut(registry: string, pool: string, assetIn: string, assetOut: string, i: number | string | BN, j: number | string | BN, fee: number | string | BN, amountOut: number | string | BN, maxSpendAmount: number | string | BN, to: string): NonPayableTransactionObject<void>; func_70LYiww(arg0: string, calls: (string | number[])[]): PayableTransactionObject<void>; orionV3SingleSwapTo(pool: number | string | BN, recipient: string, amount: number | string | BN): PayableTransactionObject<string>; orionV3Swap(pools: (number | string | BN)[], amount: number | string | BN): PayableTransactionObject<string>; orionV3SwapCallback(amount0Delta: number | string | BN, amount1Delta: number | string | BN, data: string | number[]): NonPayableTransactionObject<void>; orionV3SwapTo(pools: (number | string | BN)[], recipient: string, amount: number | string | BN): PayableTransactionObject<string>; orionV3SwapToWithPermit(recipient: string, srcToken: string, amount: number | string | BN, minReturn: number | string | BN, pools: (number | string | BN)[], permit: string | number[]): NonPayableTransactionObject<string>; pancakeV3SwapCallback(amount0Delta: number | string | BN, amount1Delta: number | string | BN, data: string | number[]): NonPayableTransactionObject<void>; patchCallWithArbitraryCall(desc: string | number[], skipMaskAndOffset: number | string | BN, patchTarget: string, patchData: string | number[]): NonPayableTransactionObject<void>; patchCallWithTokenBalance(desc: string | number[], skipMaskAndOffset: number | string | BN, token: string, ratio: number | string | BN): NonPayableTransactionObject<void>; swapAeroMulti(pools: string[], direct: boolean[], amountIn: number | string | BN, finalTo: string): NonPayableTransactionObject<void>; patchCallsWithArbitraryCall(calls: (string | number[])[], skipMasksAndOffsets: (number | string | BN)[], patchTarget: string, patchData: string | number[]): NonPayableTransactionObject<void>; patchCallsWithTokenBalance(calls: (string | number[])[], skipMasksAndOffsets: (number | string | BN)[], token: string, ratio: number | string | BN): NonPayableTransactionObject<void>; payFeeToMatcher(to: string, token: string, feeAmount: number | string | BN): PayableTransactionObject<void>; safeApprove(token: string, spender: string, amount: number | string | BN): NonPayableTransactionObject<void>; safeTransfer(token: string, target: string, amount: number | string | BN): NonPayableTransactionObject<void>; swapBrokenUniV2(pair: string, fromToken: string, toToken: string, feeDest: number | string | BN): NonPayableTransactionObject<void>; swapBrokenUniV2Scaled(pair: string, fromToken: string, toToken: string, feeDest: number | string | BN): NonPayableTransactionObject<void>; swapCallback(amount0Delta: number | string | BN, amount1Delta: number | string | BN, data: string | number[]): NonPayableTransactionObject<void>; swapUniV2(pair: string, fromToken: string, toToken: string, feeDest: number | string | BN): NonPayableTransactionObject<void>; swapUniV2Scaled(pair: string, fromToken: string, toToken: string, feeDest: number | string | BN): NonPayableTransactionObject<void>; uniswapV3SingleSwapTo(pool: number | string | BN, recipient: string, amount: number | string | BN): PayableTransactionObject<string>; uniswapV3Swap(pools: (number | string | BN)[], amount: number | string | BN): PayableTransactionObject<string>; uniswapV3SwapCallback(amount0Delta: number | string | BN, amount1Delta: number | string | BN, data: string | number[]): NonPayableTransactionObject<void>; uniswapV3SwapTo(pools: (number | string | BN)[], recipient: string, amount: number | string | BN): PayableTransactionObject<string>; unwrapAndTransfer(to: string, amount: number | string | BN): NonPayableTransactionObject<void>; wrapAndTransfer(to: string): PayableTransactionObject<void>; }; events: { allEvents(options?: EventOptions, cb?: Callback<EventLog>): EventEmitter; }; }