Alphavantage quotes working through F::Q, not through Gnucash

David Reiser dbreiser at icloud.com
Sun Nov 12 09:43:36 EST 2017


If gnucash is even letting you punch the “Get Quotes” button, it thinks both perl and finance-quote are installed correctly.

If the environment file you edited is
/Applications/Gnucash.app/Contents/Resources/etc/gnucash/environment
then it looks to me like you only need the 

 ALPHAVANTAGE_API_KEY=################

form of the command instead of  ‘export ALPHAVANTAGE_API_KEY=################’

And you have relaunched gnucash since editing the environment file? Environment files only get automatically read once per process lifetime.

If you want to try manually, open the terminal app and type [copy and paste works as long as you leave out the leading $]:

$export ALPHAVANTAGE_API_KEY=zzz
$/Applications/Gnucash.app/Contents/Resources/bin/gnc-fq-dump alphavantage TGT
Finance::Quote fields Gnucash uses:
    symbol: TGT                  <=== required
      date: 11/10/2017           <=== recommended
  currency: USD                  <=== required
      last: 61.4000              <=\       
       nav:                      <=== one of these
     price:                      <=/        
  timezone:                      <=== optional


the ‘$’ is displayed by the Terminal app, not something you type.
Note that your API key is now available for as long as this particular terminal window is open, you don’t have to reenter it to try other ticker symbols

Using the Up Arrow on the keyboard at a ‘$’ prompt reenters the last command (without executing) so you can just edit the ticker symbol without having to retype the whole command.
--
Dave Reiser
dbreiser at icloud.com





> On Nov 12, 2017, at 9:10 AM, Les <lelliott5 at gmail.com> wrote:
> 
> I added Alphavantage API key to the end of /Applications/Gnucash.app/Contents/Resources/Environment, which is where I was informed it needed to be.  Is this no correct?
> 
> As for command line, I have tried running changing directories to /Applications/Gnucash.app .
> 
> 



More information about the gnucash-user mailing list