Simple and efficient library for tracking BIST (Borsa Istanbul) stocks with real-time data and search capabilities.
- 🔍 Smart Search: Search stocks by symbol or company name
- 💰 Real-time Data: Get current stock prices and changes
- 📊 Rich Display: Colored output for price changes
- 📈 Market Data: Track volume and price movements
- 🇹🇷 BIST Focus: Specialized for Turkish stock market
# Using pip
pip install financelib
# From source
git clone https://github.com/yourusername/financelib.git
cd financelib
pip install -e .
from financelib import Stock
# Search for a stock
results = Stock.search_stocks("THYAO", return_data=True)
print(results)
# Display stock information with colors
Stock.display_stock_info("THYAO.IS")
# Search by company name
Stock.search_stocks("Garanti")
# Search by symbol
Stock.search_stocks("SASA")
# Get all available stocks
all_stocks = Stock.get_all_stocks()
The library provides beautiful colored output in the terminal:
Stock.display_stock_info("THYAO.IS")
Output example:
THYAO.IS - 14:30:25
Price: 172.45 TRY
Change: ▲ 2.45 (1.44%)
Volume: 24,532,100
Currently supports major BIST stocks including:
- Türk Hava Yolları (THYAO)
- Garanti BBVA (GARAN)
- ASELSAN (ASELS)
- SASA Polyester (SASA)
- Koç Holding (KCHOL)
- And many more...
No additional configuration needed. The library works out of the box with default settings.
# Run all tests
python -m unittest discover tests
# Run specific test
python -m unittest tests.test_stock
- Python 3.7 or higher
- Dependencies:
- yfinance >= 0.2.36
- pandas >= 1.5.0
- requests >= 2.31.0
Contributions are welcome! Here's how you can help:
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature
) - Commit your changes (
git commit -m 'Add some AmazingFeature'
) - Push to the branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Data provided by Yahoo Finance
- Inspired by various financial libraries
- Thanks to all contributors
Your Name - @yigitgumus_
Project Link: https://github.com/yigitgumus/financelib
Made with ❤️ for BIST traders and developers