get_rate
Pack: exchange · Endpoint: https://gateway.pipeworx.io/exchange/mcp
Get the current exchange rate between two currencies (e.g., USD, EUR). Returns the rate value and timestamp.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
from | string | yes | Source currency code (e.g., USD, EUR, GBP) |
to | string | yes | Target currency code (e.g., EUR, JPY, CHF) |
Example call
Arguments
{
"from": "USD",
"to": "EUR"
}
curl
curl -X POST https://gateway.pipeworx.io/exchange/mcp \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"get_rate","arguments":{"from":"USD","to":"EUR"}}}'
TypeScript (@pipeworx/sdk)
import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();
const result = await pipeworx.call('get_rate', {
"from": "USD",
"to": "EUR"
});
More examples
{
"from": "GBP",
"to": "JPY"
}
Response shape
Always returns: from, to, rate, date
| Field | Type | Description |
|---|---|---|
from | string | Source currency code (uppercase) |
to | string | Target currency code (uppercase) |
rate | number | Current exchange rate |
date | string | Date of the rate (ISO format) |
Full JSON Schema
{
"type": "object",
"properties": {
"from": {
"type": "string",
"description": "Source currency code (uppercase)"
},
"to": {
"type": "string",
"description": "Target currency code (uppercase)"
},
"rate": {
"type": "number",
"description": "Current exchange rate"
},
"date": {
"type": "string",
"description": "Date of the rate (ISO format)"
}
},
"required": [
"from",
"to",
"rate",
"date"
]
}
Connect
Add this to your MCP client config, or use one-click install buttons:
{
"mcpServers": {
"exchange": {
"url": "https://gateway.pipeworx.io/exchange/mcp"
}
}
}
See Getting Started for client-specific install steps.