Skip to main content

aza_api

Api to fetch data from Avanza website.

Package use chromedriver in order to render the Javascript from the page.

Idea for the user: Incorporate this package in a webapp with a REST api. The data may then be fetched fully in Google slides.

Requirements

Installation

Pip

pip install aza_api  # Installing
pip install aza_api -U  # Upgrading already installed package

Conda

conda install -c aza_api

Usage

The get_aza_fundamentals method returns a pandas row. Thus, it is easy to just append multiple stocks (tickers) to create a convenient dataframe.

from aza_api.aza_api import get_aza_fundamentals
df = get_aza_fundamentals("CAST.ST")  # Castellum

print(df.T)

>>>

                               0
kortnamn                 CAST.ST
dividend_yield            0.0284
antal_aktier       84012900000.0
pe_ratio                    8.29
eps                         29.3
market_cap         84012900000.0
dividend/earnings            NaN
ncavps                       0.0
net_cash_ps                  0.0
price_book                     0
latest                     244.6

Development

While in root of this project.

pip install -e .

This will install the package in editable mode.

Testing

pytest tests/ -s

Push project to Pip (PyPi) and Conda

PyPi

https://medium.com/@joel.barmettler/how-to-upload-your-python-package-to-pypi-65edc5fe9c56

Run in root

python setup.py sdist
twine upload dist/*

Metadata

Release files for aza-api 0.0.13

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

Source distribution (sdist)

Source distribution for aza-api 0.0.13
File Size Uploaded
aza_api-0.0.13.tar.gz 7.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for aza-api 0.0.13
File Interpreter ABI Platform
aza_api-0.0.13-py3-none-any.whl Python 3 none any Details

Total release size: 16.0 kB

Release files / aza_api-0.0.13.tar.gz

Download URL aza_api-0.0.13.tar.gz
Size 7.6 kB
Tags Source
SHA-256 checksum
How to use checksums
6c3d047270997717950deff1dd342c2e4ebf1b92678b300c3663d46ae7edc713
BLAKE2b-256 checksum
How to use checksums
f24be1e4f7deec7b0aef9a2a4fd38a30ca57ca7fbf7ca1b80d705c5304ad060d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.10.4

Release files / aza_api-0.0.13-py3-none-any.whl

Download URL aza_api-0.0.13-py3-none-any.whl
Size 8.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
46a80244dbd38b847078cdb8ae31825e846e0be9f53fd60556ead755421804a4
BLAKE2b-256 checksum
How to use checksums
a041d29d45a48f26498209ccd20c5a8bc83924804acd2421d21eccb3be4576b9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.0 CPython/3.10.4

Release history Release notifications | RSS feed

This release

0.0.13 This release

2 release files

0.0.10

2 release files

0.0.9

1 release file

0.0.8

1 release file

0.0.7

1 release file

0.0.6

1 release file

0.0.5

1 release file

0.0.4

1 release file

0.0.3

1 release file

0.0.2

1 release file

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