Official Python SDK for the StockFit API: SEC EDGAR financials, filings, fund and ETF data, ownership, insider transactions, and earnings.
Project description
stockfit-api
Official Python SDK for the StockFit API: SEC EDGAR financials, filings, fund and ETF data, ownership, insider transactions, and earnings.
Fully typed, generated from the StockFit OpenAPI spec. Sync and async, built on httpx.
Install
pip install stockfit-api
Requires Python 3.9+.
Usage
from stockfit_api import AuthenticatedClient
from stockfit_api.api.company import company_details
from stockfit_api.api.financials import income_statement
from stockfit_api.models import IncomeStatementPeriod
client = AuthenticatedClient(base_url="https://api.stockfit.io/v1", token="fl_...")
profile = company_details.sync(client=client, symbol="AAPL")
print(profile.name)
income = income_statement.sync(client=client, symbol="AAPL", period=IncomeStatementPeriod.ANNUAL)
print(income)
Endpoint functions are grouped by area under stockfit_api.api.* (e.g. company, financials, etfmf, sec_filings, ownership, earnings, price). Query parameters are plain keyword arguments. Parameters with a fixed set of values (like period) are typed enums in stockfit_api.models (e.g. IncomeStatementPeriod.ANNUAL).
Async
Every endpoint also exposes an async variant:
profile = await company_details.asyncio(client=client, symbol="AAPL")
Authentication
Get an API token from your StockFit developer account. AuthenticatedClient sends it as a Bearer token automatically.
License
MIT, Copyright Second Dot LLC. Use of the StockFit API itself is governed by the StockFit terms of service and your subscription.
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file stockfit_api-0.3.0.tar.gz.
File metadata
- Download URL: stockfit_api-0.3.0.tar.gz
- Upload date:
- Size: 362.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d320b4c6559cb633b47fcdb72ea44c3304537721f91817c0e10b5e618afab531
|
|
| MD5 |
4091cda3073876e157b3c4e13539a61e
|
|
| BLAKE2b-256 |
0530a437061635ab0e19f2136b62a6dac8fbb152daf9356257fe5d7e61095458
|
File details
Details for the file stockfit_api-0.3.0-py3-none-any.whl.
File metadata
- Download URL: stockfit_api-0.3.0-py3-none-any.whl
- Upload date:
- Size: 639.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
542df05b240aa419ffca084e66a797d4132af0ec2e8cea25fc111d83eb696f3e
|
|
| MD5 |
a0724ec6450febd6aaf0b0789d28a9e9
|
|
| BLAKE2b-256 |
b96efdbaa90a84ad091325003c527e8e59eb5653be68eba96aeece2bc098af3e
|