Purchase
Endpoints pertaining to requesting for quotes for options, viewing user options positions and options purchase history
Base API path: https://api.stryke.xyz/clamm/purchase
Options Quote
The /quote
endpoint is designed to return the estimated cost of purchasing an option for a given market This endpoint is useful for users who want to understand the pricing details before making a purchase. It provides both the estimated cost and the relevant token information. Note: Due to high volatility in certain markets the cost of the options may be slightly stale
Chain ID of the network
Address of the option market
GET /clamm/purchase/quote HTTP/1.1
Host: api.stryke.xyz
Accept: */*
Get cost of purchasing an option
{
"token": {
"address": "text",
"decimals": "text",
"symbol": "text"
},
"premium": "text",
"fees": "text"
}
Options Positions
The /positions
endpoint retrieves information about a user's current options positions of a given market. It provides an overview of the options positions held by a user including details about the type of option, quantity, strike price, expiration, size etc.
Chain ID of the network
Address of the option market
Address of the user
Pagination parameter for first (Similar to Qraphql)
Pagination parameter for skip (Similar to Qraphql)
GET /clamm/purchase/positions HTTP/1.1
Host: api.stryke.xyz
Accept: */*
List of options positions
[
{
"size": "text",
"premium": "text",
"strike": 1,
"type": "call",
"token": {
"address": "text",
"decimals": "text",
"symbol": "text"
},
"meta": {
"tokenId": "text",
"expiry": 1,
"handlers": [
{
"name": "text",
"deprecated": true,
"handler": {},
"pool": {}
}
],
"liquidities": [
"text"
]
}
}
]
Purchase history
The /history
endpoint retrieves options purchases by a user for a given market.
Chain ID of the network
Address of the option market
Address of the user
Pagination parameter for first (Similar to Qraphql)
Pagination parameter for skip (Similar to Qraphql)
GET /clamm/purchase/history HTTP/1.1
Host: api.stryke.xyz
Accept: */*
History of options purchases by an address
[
{
"txHash": {},
"timestamp": 1,
"strike": 1,
"size": "text",
"ttl": 1,
"type": "call",
"premium": "text",
"token": {
"address": "text",
"decimals": "text",
"symbol": "text"
}
}
]
Last updated
Was this helpful?