GET
/
v0
/
pendle
/
quote
from compass_api_sdk import CompassAPI, models


with CompassAPI(
    api_key_auth="<YOUR_API_KEY_HERE>",
) as compass_api:

    res = compass_api.pendle.quote(chain=models.PendleQuoteChain.ARBITRUM_MAINNET, market_address="0x46d62a8dede1bf2d0de04f2ed863245cbba5e538", amount="82.33", token_type=models.TokenType.PT, trade_type=models.TradeType.BUY)

    # Handle response
    print(res)
{
  "quote": "<string>"
}

Authorizations

x-api-key
string
header
required

Your Compass API Key. Get your key here.

Query Parameters

chain
enum<string>
default:arbitrum:mainnet
required

The chain to use.

Available options:
base:mainnet,
ethereum:mainnet,
arbitrum:mainnet
block
integer | null

Optional block number (defaults to latest).

market_address
string
default:0x46d62a8dede1bf2d0de04f2ed863245cbba5e538
required

The market address of the desired position.

amount
default:100
required

The quantity to trade.

token_type
enum<string>
default:PT
required

Specifies the token to quote (PT, YT, or LP)

Available options:
PT,
YT,
LP
trade_type
enum<string>
default:BUY
required

Specifies the trade direction (BUY or SELL)

Available options:
BUY,
SELL

Response

200
application/json

Successful Response

The response is of type object.