Finance...aVantage(3)

πŸ’– Finance::Quote::CurrencyRates::AlphaVantage πŸ’–

okay bestie, welcome to the Finance...aVantage(3) page from User Contributed Perl Documentation β€” it's giving "currency rates, but make it Perl." ✨

🌸 NAME 🌸

Finance::Quote::CurrencyRates::AlphaVantage β€” Obtain currency rates from https://www.alphavantage.co 🌈

✨ SYNOPSIS ✨

           use Finance::Quote;

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

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

πŸ¦‹ DESCRIPTION πŸ¦‹

This module fetches currency rates from https://www.alphavantage.co and provides data to Finance::Quote to convert the first argument to the equivalent value in the currency indicated by the second argument. πŸ’Έ

It is literally the default currency conversion module for a Finance::Quote object. Main character energy, no cap. πŸ‘‘

πŸ”‘ API_KEY πŸ”‘

https://www.alphavantage.co requires users to register and obtain an API key, which is also called a token. 🎟️

You can set that API key in either of these two ways:

  • by providing a alphavantage hash inside the currency_rates hash to Finance::Quote->new, exactly like the example above, or
  • by setting the environment variable ALPHAVANTAGE_API_KEY.

πŸ“œ Terms & Conditions πŸ“œ

Use of https://www.alphavantage.co is governed by any terms & conditions of that site. Read them, bestie β€” it's the rules. 🫢

⚠️ Finance::Quote is released under the GNU General Public License, version 2, which explicitly carries a "No Warranty" clause.

that's the whole vibe πŸ’… β€” signed off with perl v5.32.1, dated 2026-10-26. mwah πŸ“

πŸ“¦ where this page comes from