Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
convert 端点使用实时汇率在货币之间转换特定金额——适用于金融计算和支付处理。
convert
cURL
curl --request GET \ --url https://exchange-rates.cleariflow.com/v1/convert/
import requests url = "https://exchange-rates.cleariflow.com/v1/convert/" response = requests.get(url) print(response.text)
const options = {method: 'GET'}; fetch('https://exchange-rates.cleariflow.com/v1/convert/', options) .then(res => res.json()) .then(res => console.log(res)) .catch(err => console.error(err));
<?php $curl = curl_init(); curl_setopt_array($curl, [ CURLOPT_URL => "https://exchange-rates.cleariflow.com/v1/convert/", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; }
package main import ( "fmt" "net/http" "io" ) func main() { url := "https://exchange-rates.cleariflow.com/v1/convert/" req, _ := http.NewRequest("GET", url, nil) res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body)) }
HttpResponse<String> response = Unirest.get("https://exchange-rates.cleariflow.com/v1/convert/") .asString();
require 'uri' require 'net/http' url = URI("https://exchange-rates.cleariflow.com/v1/convert/") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) response = http.request(request) puts response.read_body
{ "base": "EUR", "target": "USD", "date": "2025-08-21", "base_amount": 1, "converted_amount": 1.160968, "exchange_rate": 1.160968, "last_updated": 1755806612 }
https://exchange-rates.cleariflow.com/v1/convert/
curl 'https://exchange-rates.cleariflow.com/v1/convert/?api_key=YOUR_API_KEY&base=EUR&target=USD'
Your unique API key for authentication
The base currency used to get the latest exchange rate(s) for. Uses the ISO 4217 currency standard
The target currency to convert to. Only one currency is allowed for conversion.
The amount of the base currency you would like to convert to the target currency
The historical date you'd like to get rates from, in the format of YYYY-MM-DD. If not specified, the latest available rates will be used.
Successful response
The base currency used to get the exchange rates
"EUR"
The target currency that the base_amount was converted into
"USD"
The date the currencies were pulled from, per the successful request
"2024-01-01"
The amount of the base currency from the request
1
The amount of the target currency that the base_amount has been converted into
0.85
The exchange rate used to convert the base_amount from the base currency to the target currency
The Unix timestamp of when the returned data was last updated
1704067200