Skip to main content

Command line interface for Alpha Vantage APIs (WIP)

Command line interface to get stock data from the Alpha Vantage API

Alpha Vantage offers an API for financial data and other popular finance indicators. This library provides a series of commands that you can use to query the API from your terminal in an easy way.

Getting started

Get an alpha vantage free api key. Visit http://www.alphavantage.co/support/#api-key

Install alpha-vantage-cli:

pip install alpha-vantage-cli

Set your api key:

av set-key

Try it out:

av stock quote ibm

Usage examples

av --help

Output:

Usage: av [OPTIONS] COMMAND [ARGS]...

  Unofficial Alpha Vantage command line interaface.

  Get stocks data from the command line.

Options:
  --version  Show the version and exit.
  --help     Show this message and exit.

Commands:
  crypto   Manages the Cryptocurrences APIs (Not yet implemented)
  data     Manages the Fundamental Data APIs (Not yet implemented)
  econ     Manages the Economic Indicators APIs (Not yet implemented)
  forex    Manages the Forex APIs (Not yet implemented)
  intel    Manages the Alpha Intelligence APIs (Not yet implemented)
  set-key  Set your API key so that you can send requests to Alpha...
  stock    Manages the Core Stocks APIs
  tech     Manages the Technical Indicators APIs (Not yet implemented)

Get quote for stock

av stock quote aapl

Sample output:

{'Global Quote': {'01. symbol': 'AAPL', '02. open': '151.2100', '03. high': '151.3500', '04. low': '148.3700', '05. price': '150.7000', '06. volume': '162278841', '07. latest trading day': '2022-09-16', '08. previous close': '152.3700', '09. change': '-1.6700', '10. change percent': '-1.0960%'}}

Download monthly data as CSV

av stock monthly ibm --datatype=csv > ibm.csv

Release files for alpha-vantage-cli 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for alpha-vantage-cli 0.1.2
File Size Uploaded
alpha-vantage-cli-0.1.2.tar.gz 5.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for alpha-vantage-cli 0.1.2
File Interpreter ABI Platform
alpha_vantage_cli-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 12.0 kB

Release files / alpha-vantage-cli-0.1.2.tar.gz

Download URL alpha-vantage-cli-0.1.2.tar.gz
Size 5.7 kB
Tags Source
SHA-256 checksum
How to use checksums
0ca9b649878bac4f8cefc13207497d6fbcbfb5eddcf3ba29011c0db858f9dc5c
BLAKE2b-256 checksum
How to use checksums
936b00a12dc1d21c737113fabc00fe59f7258252858dc57d6630b6874c84e115
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.2.0 CPython/3.10.0 Darwin/21.4.0

Release files / alpha_vantage_cli-0.1.2-py3-none-any.whl

Download URL alpha_vantage_cli-0.1.2-py3-none-any.whl
Size 6.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fd16cc479db92554289c13648c0836565d4c24b6d67306fd696faf16a3378da4
BLAKE2b-256 checksum
How to use checksums
6c506df29a1b77d730320cc1eb80c88d43660fd637d2fa66a72b8c7af0072fd6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.2.0 CPython/3.10.0 Darwin/21.4.0

Release history Release notifications | RSS feed

This release

0.1.2 This release

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page