Currency Converter
Convert an amount between currencies at European Central Bank rates. Returns the converted amount and the rate.
Pay by wallet (x402)
currency-convert Example
Input
{
"to": "EUR",
"from": "USD",
"amount": 100
} Answer
{
"to": "EUR",
"date": "2026-03-06",
"from": "USD",
"rate": 0.864977,
"amount": 100,
"converted_amount": 86.5
} Inputs
| Field | Type | Required | What it is |
|---|---|---|---|
to | string | Yes | Target currency (ISO 4217) |
from | string | Yes | Source currency (ISO 4217) |
amount | number | Yes | Amount to convert |
Output fields
How reliably each field appears in a successful answer.
| Field | Type | Appears |
|---|---|---|
to | string | Always (present in every successful answer) |
date | string | Always (present in every successful answer) |
from | string | Always (present in every successful answer) |
rate | number | Always (present in every successful answer) |
amount | number | Always (present in every successful answer) |
converted_amount | number | Always (present in every successful answer) |
How to call it
The same tool through each route. MCP clients reach it through Strale’s server at https://api.strale.io/mcp; the call below is what the agent sends.
# Needs an API key. max_price_cents caps what this call may cost.
curl -X POST https://api.strale.io/v1/do \
-H "Authorization: Bearer $STRALE_API_KEY" \
-H 'Content-Type: application/json' \
-d '{
"capability_slug": "currency-convert",
"inputs": {
"to": "EUR",
"from": "USD",
"amount": 100
},
"max_price_cents": 2
}' {
"tool": "strale_execute",
"arguments": {
"slug": "currency-convert",
"inputs": {
"to": "EUR",
"from": "USD",
"amount": 100
},
"max_price_cents": 2
}
} import { Strale } from "straleio";
const strale = new Strale({ apiKey: process.env.STRALE_API_KEY! });
const result = await strale.do({
capability_slug: "currency-convert",
inputs: {
"to": "EUR",
"from": "USD",
"amount": 100
},
max_price_cents: 2,
}); import os
from straleio import Strale, DoRequest
strale = Strale(api_key=os.environ["STRALE_API_KEY"])
result = strale.do(DoRequest(
capability_slug="currency-convert",
inputs={
"to": "EUR",
"from": "USD",
"amount": 100,
},
max_price_cents=2,
)) # No account. The first request answers 402 with the price in USDC;
# an x402 client pays it from your wallet and repeats the request.
curl -i 'https://api.strale.io/x402/v2/currency-convert?to=EUR&from=USD&amount=100' Limitations
Bank rates include spreads and fees
Uses mid-market exchange rates — actual conversion rates from banks and payment processors include spread and fees
What to do instead: Apply your payment processor's typical markup (0.5-3%) to the converted amount for realistic cost estimates
Bundled checks that include it
Related tools
- Exchange Rate €0.02
- Stock Quote €0.05