Finance...Exchange(3)

πŸ’Έ Finance::Quote::CurrencyRates::OpenExchange β€” like, the whole page (Finance...Exchange(3))

Okay bestie, buckle up πŸ’– this is the manual page for Finance::Quote::CurrencyRates::OpenExchange, and yes the header on the real thing reads Finance...Exchange(3) β€” that's just how it's filed, don't come for me πŸŽ€


✨ NAME ✨

Finance::Quote::CurrencyRates::OpenExchange β€” it goes and gets you currency rates from https://openexchangerates.org πŸ’… no cap, that's literally the whole job.


🌸 SYNOPSIS 🌸

Here's the vibe, copy-paste energy:

use Finance::Quote;

$q = Finance::Quote->new(currency_rates =>
       {order => ['OpenExchange'], openexchange => {API_KEY => ...}}
     );

$value = $q->currency('18.99 EUR', 'USD');

That's it. That's the whole ritual πŸ•―οΈβœ¨


πŸ¦‹ DESCRIPTION πŸ¦‹

So this module pulls currency rates straight from https://openexchangerates.org and hands them over to Finance::Quote so it can convert the first argument into the equivalent value in the currency you name in the second argument. Math? Handled. Slay πŸ’…

Also, important: this module caches the currency rates for the lifetime of the quoter object β€” unless you drop cache => 0 into the openexchange options hash. Then it doesn't. Your call, bestie 🫢


🧚 Currency Module Selection 🧚

You don't have to pick it in the constructor, either β€” the Finance::Quote currency method can be selected by setting the environment variable FQ_CURRENCY. Iconic behaviour honestly πŸ‘‘

export FQ_CURRENCY=OpenExchange

πŸ”‘ API_KEY πŸ”‘

https://openexchangerates.org makes you register and get yourself an API key β€” no key, no rates, sorry 😭 Their free plan gives you 1000 queries per month, which is lowkey generous, highkey keep an eye on it.

You can set that key two ways:

  • By setting the environment variable OPENEXCHANGE_API_KEY 🌈
  • By providing an openexchange hash inside the currency_rates hash you pass to Finance::Quote->new, exactly like in the example up top πŸ’–

πŸ“œ Terms & Conditions πŸ“œ

Using https://openexchangerates.org means you're also agreeing to whatever terms & conditions that site has. Not my rules, not my problem, just passing the message along πŸ™ˆ

Finance::Quote is released under the GNU General Public License, version 2, which explicitly carries a "No Warranty" clause. Read it, know it, love it πŸ’€


fr fr, that's the whole page β€” nothing skipped, nothing guessed, just the facts with better energy 🌸

That's a wrap, bestie πŸŽ€ this page is from perl v5.32.1, dated 2026-10-26, and it's filed as Finance...Exchange(3) in your friendly neighbourhood User Contributed Perl Documentation. Go convert some currencies, you absolute main character πŸ‘‘πŸ’œ

πŸ“¦ where this page comes from