Sand AISand AI MAGI-2MAGI-2 agora está na SandBase: vídeo em 1080p com áudio nativoExperimente agora

XE Convert Currency

Docs da API
https://api.sandbase.ai/v1/api/xe/convert-currency

Convert a specific amount from source to target currency. Returns the same structure as get_live_exchange_rate with the specified amount applied to the mid-market rate.

Preço
$0.03USD / chamada
Método
POST
Resposta
JSON
Parâmetros
3 obrigatórios · 0 opcionais

Playground

Entrada
Target currency code (e.g. USD, JPY). Supports all codes returned by get_currency_symbols.
Source currency code (e.g. EUR, GBP). Supports all codes returned by get_currency_symbols.
Amount to convert
SaídaPronto

Sua saída aparecerá aqui

Preencha as entradas e clique em Executar.

README da API

XE Convert Currency API

Convert a specific amount from source to target currency. Returns the same structure as get_live_exchange_rate with the specified amount applied to the mid-market rate.

Request

curl -X POST "https://api.sandbase.ai/v1/run" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "xe/convert-currency", "to": "USD", "from": "EUR", "amount": 100.0}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
amountnumberYesAmount to convert
fromstringYesSource currency code (e.g. EUR, GBP). Supports all codes returned by get_currency_symbols.
tostringYesTarget currency code (e.g. USD, JPY). Supports all codes returned by get_currency_symbols.

Pricing

Flat $0.03 per call. Failed calls are not charged.

Explorar mais

APIs relacionadas

Todas as APIs
APIPreçoResposta
XE$0.03 por chamadaJSON
XE$0.06 por chamadaJSON
XE$0.03 por chamadaJSON
XE$0.03 por chamadaJSON
XE$0.03 por chamadaJSON
XE$0.03 por chamadaJSON

Perguntas

FAQ

Como eu uso a API XE Convert Currency?

Envie uma solicitação POST para https://api.sandbase.ai/v1/api/xe/convert-currency com sua chave de API da SandBase no cabeçalho Authorization (Bearer) e os parâmetros no corpo JSON. Você também pode testar no Playground desta página sem escrever código.

Quanto custa a API XE Convert Currency?

$0.03 por chamada, cobrado do seu saldo SandBase. Você paga apenas pelas chamadas que fizer; não há assinatura.

Quais parâmetros a API XE Convert Currency aceita?

Obrigatórios: to (string), from (string) e amount (number). A tabela de Parâmetros e o Playground nesta página listam todos os campos.

O que a API XE Convert Currency retorna?

Uma resposta JSON retornada na mesma solicitação HTTP (síncrona).

Preciso de uma conta de desenvolvedor XE ou de uma chave de API?

Não. XE Convert Currency funciona via SandBase, então uma única chave de API da SandBase cobre este endpoint e todas as outras APIs e modelos do catálogo. Você não precisa solicitar acesso à API do XE separadamente.