import{r as e,t}from"./axios-Yyz76XvX.js";import{ta as n}from"./endpoints-BWeG8ngA.js";async function r(r){let i={headers:{Accept:`application/json`,"Content-Type":`application/json`}};try{let a=(await t.get(e+n,i)).data.conversion_rates[r.toUpperCase()];if(!a)throw Error(`Moneda no soportada`);return a}catch(e){throw console.error(`Error al obtener la tasa de cambio:`,e),e}}export{r as t};