evx-sdk
Version:
The Evx SDK is a developer toolkit designed to simplify interaction with the Evx decentralized liquidity protocol. It provides an abstraction layer over the smart contracts, allowing developers to easily build applications, integrate liquidity pools, fetc
35 lines (34 loc) • 1.03 kB
TypeScript
/**
* @notice Gets comprehensive gas price information from network
* @return Object with gas prices in wei
*/
export declare function getNetworkGasPrices(): Promise<{
legacy: bigint;
maxFeePerGas: bigint;
maxPriorityFeePerGas: bigint;
current: bigint;
minimum: bigint;
maximum: bigint;
}>;
/**
* @notice Gets the current network gas price in wei
* @return The current gas price in wei
*/
export declare function getCurrentNetworkGasPrice(): Promise<bigint>;
/**
* @notice Converts gas estimate to ETH cost with different gas price scenarios
* @param gasEstimateInUnits The gas estimate from contract (in gas units)
* @return Object with costs in ETH for different gas price scenarios
*/
export declare function convertGasEstimateToEthCost(gasEstimateInUnits: bigint): Promise<{
current: number;
minimum: number;
maximum: number;
legacy: number;
gasPricesInWei: {
current: string;
minimum: string;
maximum: string;
legacy: string;
};
}>;