Skip to main content

IWstETH

Git Source

Inherits: IERC20

Title: IWstETH

Minimal interface for Lido's wstETH.

Functions

getStETHByWstETH

Returns the amount of stETH for a given amount of wstETH.

function getStETHByWstETH(uint256 wstETHAmount) external view returns (uint256);

Parameters

NameTypeDescription
wstETHAmountuint256The amount of wstETH.

Returns

NameTypeDescription
<none>uint256The equivalent amount of stETH.

getWstETHByStETH

Returns the amount of wstETH for a given amount of stETH.

function getWstETHByStETH(uint256 stETHAmount) external view returns (uint256);

Parameters

NameTypeDescription
stETHAmountuint256The amount of stETH.

Returns

NameTypeDescription
<none>uint256The equivalent amount of wstETH.

wrap

Wraps stETH to wstETH.

function wrap(uint256 stETHAmount) external returns (uint256 wstETHAmount);

unwrap

Unwraps wstETH to stETH.

function unwrap(uint256 wstETHAmount) external returns (uint256 stETHAmount);