← Fjármál og gjaldmiðlar

Umbreyta gjaldmiðli

GET /convert

Umbreyttu a specific monetary amount from one currency to another með latest gengi. Styður an optional margin parameter for adding business markup (t.d. 2% fee on top of the market rate), and an optional date parameter for historical conversions. Skilar converted amount, the rate used, and query details. Fullkomið fyrir e-commerce checkout flows, invoicing kerfi, and travel budfáðu verkfæri.

Breytur

from nauðsynlegt

Source currency

to nauðsynlegt

Target currency

amount nauðsynlegt

Amount to convert

margin valfrjálst

Business markup percentage

date valfrjálst

Historical date (YYYY-MM-DD)

Dæmi um fyrirspurnir

Grunnnotkun
curl "https://nordapi.ee/api/v1/convert?from=USD&to=EUR&amount=100"
Convert USD to Euro
curl "https://nordapi.ee/api/v1/convert?from=USD&to=EUR&amount=100"
Convert with 2.5% business markup
curl "https://nordapi.ee/api/v1/convert?from=USD&to=EUR&amount=100&margin=2.5"
Historical conversion on a specific date
curl "https://nordapi.ee/api/v1/convert?from=GBP&to=NOK&amount=500&date=2026-01-15"
Large amount JPY to NOK
curl "https://nordapi.ee/api/v1/convert?from=JPY&to=NOK&amount=1000000"

Lifandi svar

{
  "query": {
    "amount": 100.0,
    "from": "USD",
    "to": "EUR"
  },
  "rate": 0.86767896,
  "result": 86.767896,
  "success": true
}

Dæmi um svar

{"success":true,"query":{"from":"USD","to":"EUR","amount":100.0},"result":86.54,"rate":0.8654}