Skip to content

Accurate Free Stock Market, Forex and Crypto, ... data from the AlphaVantage API

License

Notifications You must be signed in to change notification settings

tariqdaouda/pyAlphaVantage

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pyAlphaVantage

A mighty small (thanks to a bit of Black_Magic) python package for all AlphaVantage financial API. Retrieve both historical and current financial data for stocks, forex and crypto, ... plus some nice metrics.

Step 1

Install it however you want (git clone / pip)

Step 2 use it

import pyAlphaVantageAPI.AlphaVantageAPI as AVA

api = AVA.AlphaVantage(api_key=<your api key>)
#make a call with arguments as definied in AlphaVantage documentation
data = api.TIME_SERIES_DAILY_ADJUSTED(symbol=SYMBOL, datatype="csv", outputsize="full")

TIME_SERIES_DAILY_ADJUSTED can be replaced by any function in the documentation as long as it is part of the API and defined in api.functions_defs.

Adding a function to definitions can be done using

api.add_function_definitions(function_name, argument_list)

To know all functions available

api.get_available_functions()

To know the arguments of an available function

api.get_function_arguments(function_name)

That's it

Cheers,

T.