Currencies: Convert an amount
fx_convertCurrencyConvert an amount
amount of from in to at the official rate on date (default: latest). TCMB is used when it publishes both currencies (TRY included), else ECB (EUR included). With TCMB, rateType picks the rate each currency is valued at in TRY: mid (default, the forex buying/selling midpoint), buying or selling. Use to convert an amount between currencies at the official rate, e.g. 100 USD in TRY or 50 EUR in USD.
GET /v1/fx/conversions on Currencies (SBX-FX). Costs 1 credit per call.
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": {
"from": "<from>",
"to": "<to>"
},
"name": "fx_convertCurrency"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | ISO 4217 code. | |
| date | No | YYYY-MM-DD. Default: the latest bulletin. | |
| from | Yes | ISO 4217 code. | |
| amount | No | Default 1. | |
| source | No | Force `tcmb` or `ecb`. | |
| rateType | No | TCMB only: `mid`, `buying` or `selling`. | mid |