Skip to main content

IPendleData

imports IPendleRouter, IPendleYieldToken, IPendlePausingManager, IPendleMarket

Source: IPendleData.sol


REFERENCE

Events

ForgeFactoryValiditySet

Emitted when validity of a forge-factory pair is updated.


event ForgeFactoryValiditySet(
bytes32 forgeId,
bytes32 marketFactoryId,
bool valid
);
ParameterTypeDescription
forgeIdbytes32Forge ID in bytes.
marketFactoryIdbytes32Market factory ID in bytes.
validaddressFlag setting whether the Forge factory is valid or not.

Signature: 0x9153d773f9bc4eb73e257d5a608cd7be93c422bed8aec9121f9bf9ab9a18b46f


TreasurySet

Emitted when Treasury address has been set.


event TreasurySet(address treasury);
ParameterTypeDescription
treasuryaddressThe treasury address.

Signature: 0x3c864541ef71378c6229510ed90f376565ee42d9c5e0904a984a9e863e6db44f


LockParamsSet

Emitted when LockParams is set.


event LockParamsSet(uint256 lockNumerator, uint256 lockDenominator);
ParameterTypeDescription
lockNumeratoruint256Numerator of lock param.
lockDenominatoruint256Denominator of lock param.

Signature: 0xa598b4dbf59d90f6b4cad0a1397a48801765d3b3e2bbb144cb8fca53d0737a02


ExpiryDivisorSet

Emitted when ExpiryDivisor is set.


event ExpiryDivisorSet(uint256 expiryDivisor);
ParameterTypeDescription
expiryDivisoruint256Expiry divisor value.

Signature: 0x90c17e2890a3d0c88fdb2b6383e9bf7f1a7b7c925325e2c810fb998c4f44ec06


ForgeFeeSet

Emitted when forge fee is set.


event ForgeFeeSet(uint256 forgeFee);
ParameterTypeDescription
forgeFeeuint256Forge fee value.

Signature: 0x2ef1bce60d7bbfae6c837d0b8e2a628c96ba39aaa79bd1aecfc972313843b7b7


InterestUpdateRateDeltaForMarketSet

Emitted when interestUpdateRateDeltaForMarket is set.


event InterestUpdateRateDeltaForMarketSet(uint256 interestUpdateRateDeltaForMarket);
ParameterTypeDescription
interestUpdateRateDeltaForMarketuint256Interest update rate delta for market value.

Signature: 0x65ec3e0128626032a413924458fc6b81e4c8c20bfcecd79df9a7822829929fff


MarketFeesSet

Emitted when market fees are set.


event MarketFeesSet(uint256 swapFee, uint256 protocolSwapFee);
ParameterTypeDescription
swapFeeuint256Market swap fee percentage.
protocolSwapFeeuint256Protocol swap fee percentage.

Signature: 0xdc40a2ee81b25d18d01c581d3094089420126c71715b91c435d672a506aea7bb


CurveShiftBlockDeltaSet

Emitted when the curve shift block delta is set.


event CurveShiftBlockDeltaSet(uint256 blockDelta);
ParameterTypeDescription
blockDeltauint256Block delta value for curve shifting.

Signature: 0x2e6187d5d52493f2d476b10975d0cce536900209dc8448ee5701ac80bc4c30dc


NewMarketFactory

Emitted when a new market factory is added.


event NewMarketFactory(bytes32 indexed marketFactoryId, address indexed marketFactoryAddress);
ParameterTypeDescription
marketFactoryIdbytes32The market factory ID in bytes.
marketFactoryAddressaddressThe market factory address.

Signature: 0x1a525a612420d955b2801652ec888e9764e1ae41da65cc2561596d4618ccb539


ForgeAdded

Emitted when a new market factory is added.


event ForgeAdded(bytes32 indexed forgeId, address indexed forgeAddress);
ParameterTypeDescription
forgeIdbytes32The forge ID in bytes.
forgeAddressaddressThe forge address.

Signature: 0x69055c715401f521099c448934ded38665f743c00f6c38849feef24404adc8e5


General Functions

router

Gets a reference to the PendleRouter contract.


function router() external view returns (IPendleRouter);

Returns:
IPendleRouter — Returns the router contract reference.


pausingManager

Gets a reference to the PendlePausingManager contract.


function pausingManager() external view returns (IPendlePausingManager);

Returns:
IPendlePausingManager — Returns the pausing manager contract reference.


treasury

Gets a reference to the treasury contract.


function treasury() external view returns (address);

Returns:
Treasury contract address.


getPendleYieldTokens

Gets the Pendle yield tokens given a forge ID, underlying yield token, and expiry.


function getPendleYieldTokens(
bytes32 forgeId,
address underlyingYieldToken,
uint256 expiry
) external view returns (IPendleYieldToken ot, IPendleYieldToken xyt);
ParameterTypeDescription
forgeIdbytes32The forge ID in bytes.
underlyingYieldTokenaddressThe address of the underlying yield token.
expiryuint256The expiry of the yield contract in epoch time.

Returns:
ot — Returns the OT contract reference.
xyt — Returns the YT contract reference.


getForgeAddress

Gets the Forge address given a forge ID.


function getForgeAddress(bytes32 forgeId) external view returns (address forgeAddress);
ParameterTypeDescription
forgeIdbytes32The forge ID in bytes.

Returns:
forgeAddress — Returns the address of the forge.


isValidXYT

Checks if the underlying asset has a valid corresponding YT.


function isValidXYT(
bytes32 forgeId,
address underlyingAsset,
uint256 expiry
) external view returns (bool);
ParameterTypeDescription
forgeIdbytes32The forge ID in bytes.
underlyingAssetaddressThe address of the underlying asset.
expiryuint256The expiry of the yield contract in epoch time.

Returns:
true if the underlying asset has a valid YT, otherwise false.


isValidOT

Checks if the underlying asset has a valid corresponding OT.


function isValidOT(
bytes32 forgeId,
address underlyingAsset,
uint256 expiry
) external view returns (bool);
ParameterTypeDescription
forgeIdbytes32The forge ID in bytes.
underlyingAssetaddressThe address of the underlying asset.
expiryuint256The expiry of the yield contract in epoch time.

Returns:
true if the underlying asset has a valid OT, otherwise false.


validForgeFactoryPair

Checks if the Forge and Market Factory are a canonical pair in the network.


 function validForgeFactoryPair(bytes32 forgeId, bytes32 marketFactoryId)
external
view
returns (bool);
ParameterTypeDescription
forgeIdbytes32The forge ID in bytes.
marketFactoryIdbytes32The market factory ID in bytes.

Returns:
true if the pair is valid, otherwise false.


otTokens

Gets a reference to a specific OT.


function otTokens(
bytes32 forgeId,
address underlyingYieldToken,
uint256 expiry
) external view returns (IPendleYieldToken ot);
ParameterTypeDescription
forgeIdbytes32The forge ID in bytes.
underlyingYieldTokenaddressThe address of the underlying yield token.
expiryuint256The expiry of the yield contract in epoch time.

Returns:
ot - Returns the OT contract reference.


xytTokens

Gets a reference to a specific YT.


function xytTokens(
bytes32 forgeId,
address underlyingYieldToken,
uint256 expiry
) external view returns (IPendleYieldToken ot);
ParameterTypeDescription
forgeIdbytes32The forge ID in bytes.
underlyingYieldTokenaddressThe address of the underlying yield token.
expiryuint256The expiry of the yield contract in epoch time.

Returns:
yt - Returns the YT contract reference.


isMarket

Des


function isMarket(address addr) external view returns (bool result);
ParameterTypeDescription
addraddressAddress to check if Market.

Returns:
des


isXyt

Des


function isXyt(address _ddr) external view returns (bool result);
ParameterTypeDescription
addraddressAddress to check if YT.

Returns:
des


allMarketsLength

Returns the number of markets currently existing.


function allMarketsLength() external view returns (uint256);

Returns:
Market length


forgeFee

Returns the current forge fee when tokenizing yield bearing tokens.


function forgeFee() external view returns (uint256);

Returns:
Forge fee


interestUpdateRateDeltaForMarket

Returns the update rate delta for updateparamL.


function interestUpdateRateDeltaForMarket() external view returns (unt256);

Returns:
Update rate delta


expiryDivisor

Des


function expiryDivisor() external view returns (uint256);

Returns:
Des


lockNumerator

Des


function lockNumerator() external view returns (uint256);

Returns:
Des


lockDenominator

Des


function lockDenominator() external view returns (uint256);

Returns:
Des


swapFee

Returns the swap fee when trading in the market.


function swapFee() external view returns (uint256);

Returns:
Swap fee


protocolSwapFee

Returns the protocol swap fee when trading in the market.


function protocolSwapFee() external view returns (uint256);

Returns:
Protocol swap fee


curveShiftBlockDelta

Returns the number of delta blocks before executing a curve shift.


function curveShiftBlockDelta() external view returns (uint256);

Returns:
Curve shift delta blocks


getMarketByIndex

Returns the market address by passing its uint index.


function getMarketByIndex(uint256 index) external view returns (address market);

Returns:
The market address.


getMarket

Gets a market given a YT and an ERC20 token.


function getMarket(
bytes32 marketFactoryId,
address xyt,
address token
) external view returns (address market);
ParameterTypeDescription
marketFactoryIdbytes32The market factory ID in bytes.
xytaddressThe address of the YT in the market.
tokenaddressThe address of the token in the market.

Returns:
The market address.


getMarketFactoryAddress

Gets a market factory address given the identifier.


function getMarketFactoryAddress(bytes32 marketFactoryId)
external
view
returns (address marketFactoryAddress);
ParameterTypeDescription
marketFactoryIdbytes32The market factory ID in bytes.

Returns:
The market factory address.


getMarketFromKey

Gets a market factory address given the params.


function getMarketFromKey(
address xyt,
address token,
bytes32 marketFactoryId
) external view returns (address market);
ParameterTypeDescription
xytaddressThe address of the YT in the market.
tokenaddressThe address of the token in the market.
marketFactoryIdbytes32The market factory ID in bytes.

Returns:
The market address.