Skip to main content

another unofficial api for some financial visualization website

Project description

another unofficial api for finviz.com

python3120 poetry pypi

installation

$ python -m pip install -U finavis

getting a quote

import typing as ty

from finavis import get_quote
from finavis.library import Quote

quote: Quote = get_quote(ticker="AAPL")

# accessing to attributes: type help(quote) for more
print(f"Ticker: {quote.ticker}, price: {quote.price}, w/ EPS {quote.eps_ttm}")

# extract attributes to dictionary
data: ty.Dict[str, str] = quote.to_dict()

getting a screener w/ objects

from finavis import Screener
from finavis.library import ExchangeChoices, IndexChoices, OrderChoices

screener: Screener = Screener(
    exchange=ExchangeChoices.NASDAQ,
    index=IndexChoices.SP500,
    order_by=OrderChoices.CHANGE_ASC,
)

for index, overview in enumerate(screener()):
    print(f"Ticker: {overview.ticker}, price: {overview.price} - change: {overview.change}")

disclaimer

using this library to acquire data from some website is against their "terms of service" and robots.txt; use it responsibly and at your own risk, this library was built purely for educational purposes.

important information

any quote data displayed on the finviz.com website is delayed by 15 minutes for nasdaq and 20 minutes for nyse/amex; this api should NOT be used for real-time trading, it's primary purpose for research in educational purposes.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

finavis-0.0.13.tar.gz (10.6 kB view details)

Uploaded Source

Built Distribution

finavis-0.0.13-py3-none-any.whl (12.0 kB view details)

Uploaded Python 3

File details

Details for the file finavis-0.0.13.tar.gz.

File metadata

  • Download URL: finavis-0.0.13.tar.gz
  • Upload date:
  • Size: 10.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.2 CPython/3.12.1 Darwin/22.6.0

File hashes

Hashes for finavis-0.0.13.tar.gz
Algorithm Hash digest
SHA256 eca931eb7615314371c51b5b94eb71572a59135e7934b06c59f164fe0a9ed02d
MD5 d22a7d3ec8e9ee21df21c4084c67791d
BLAKE2b-256 3cd79bac8bda0db84143d461ea6195e59c14cf9f9a75229a6cb7d94fd7963dc0

See more details on using hashes here.

File details

Details for the file finavis-0.0.13-py3-none-any.whl.

File metadata

  • Download URL: finavis-0.0.13-py3-none-any.whl
  • Upload date:
  • Size: 12.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.2 CPython/3.12.1 Darwin/22.6.0

File hashes

Hashes for finavis-0.0.13-py3-none-any.whl
Algorithm Hash digest
SHA256 5845a5fae0c077655b2280959d96016f8b9fe8b05e70edd2c950171cca8d9a69
MD5 82825f3ae47c072859cd944de08a9950
BLAKE2b-256 6930b84a3859ee68dcc7f76298aaec953c286646659cf581570da6cdc6f09b4e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page