Financial data analysis and market API connector for invertironline
finargy
is a Python package that provides tools for financial data analysis and API integration with the InvertirOnline trading platform. It allows you to fetch market data, manage portfolios, and analyze investments.
- Clone the repository:
git clone https://github.com/your-username/finargy.git
cd finargy
- Create and activate virtual environment
- Linux:
python3 -m venv .venv
source .venv/bin/activate
- Windows:
python -m venv .venv
.venv\Scripts\activate
- Install requirements and finargy package from source:
pip install -r requirements.txt
pip install -e .
Remove the -e
flag if you don't want to install the package in editable mode.
- Create a new file named
.env
in the root directory of the project. - Add the following environment variables to the
.env
file:
USER=your_username
PASSWORD=your_password
from finargy.api.client import InvertirOnlineAPI
# Initialize client
client = InvertirOnlineAPI()
from finargy.api.market_data.symbol_data import get_symbol_history
import datetime
# Get historical data for a symbol
data = get_symbol_history(
client,
symbol="AAPL",
date_start=datetime.datetime(2024, 1, 1),
date_end=datetime.datetime.now()
)