Naar de inhoud
GET /v1/convert

Convert an amount between USD and COP at the latest TRM

Probeer het live

10 gratis calls per dag — geen registratie, geen API-key. Loopt via de oanor-gateway.

Aangepaste headers (optioneel)
api.oanor.com/colombiatrm-api

Het werkt. Haal een API-key op en gebruik hem in je project.

Verkrijg een API-sleutel

Codefragmenten

curl "https://api.oanor.com/colombiatrm-api/v1/convert" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/colombiatrm-api/v1/convert", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/colombiatrm-api/v1/convert");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
    "https://api.oanor.com/colombiatrm-api/v1/convert",
    headers={"x-oanor-key": "oanor_test_..."}
)

Voorbeeldrespons

Een echte respons van dit endpoint, vastgelegd bij de laatste health check.

{
    "data": {
        "to": "COP",
        "date": "2026-06-10",
        "from": "USD",
        "rate": 3581.46,
        "amount": 100,
        "result": 358146,
        "source": "Banco de la República (Colombia TRM)",
        "cop_per_usd": 3581.46
    },
    "meta": {
        "timestamp": "2026-06-10T22:58:00.910Z",
        "request_id": "d7169636-8ee7-4223-a7d9-fc66d42cfe01"
    },
    "status": "ok",
    "message": "Conversion completed successfully",
    "success": true
}