getPrice
Retrieve the current price for any Stellar asset pair using SDEX orderbook data or recent trades. Specify base and counter assets to get the latest market rate.
Instructions
Get the current price for a Stellar asset pair from SDEX orderbook or recent trades
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"baseAsset": "<baseAsset>",
"counterAsset": "<counterAsset>"
},
"name": "getPrice"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| baseAsset | Yes | Base asset: "XLM" or "CODE:ISSUER" (e.g. "USDC:GA5Z...") | |
| counterAsset | Yes | Counter asset: "XLM" or "CODE:ISSUER" (e.g. "USDC:GA5Z...") |