Crawl the public data from Tefas.
Project description
Tefas Crawler
Crawl public fund information from Tefas with ease.
Installation
pip install tefas-crawler
Usage
Import the Crawler
object and create an instance of it.
from tefas import Crawler
crawler = Crawler()
API
fetch(date="YYYY-MM-DD")
Get all funds for a given day.
data = crawler.fetch(date="2020-11-20")
This should return all fund information for the given day as a list of dictionaries like this:
[
{
'Tarih': '20.11.2020',
'FonKodu': 'AAK',
'Fon Adı': 'ATA PORTFÖY ÇOKLU VARLIK DEĞİŞKEN FON',
'Fiyat': '41,302235',
'TedavüldekiPaySayısı': '1.898.223,00',
'KişiSayısı': '422',
'Fon Toplam Değer': '78.400.851,68'},
'Banka Bonosu (%)': '0,00',
...
},
...
]
Data Schema
As of today, we support the following data schema from Tefas:
Column | Description | Type |
---|---|---|
Tarih | Date | string |
FonKodu | Short code of the fund | string |
Fon Adı | Full name of the fund | string |
Fiyat | Price of the fund | string |
TedavüldekiPaySayısı | Number of shares | string |
KişiSayısı | Number of participants | string |
Fon Toplam Değer | Total value | string |
To-do
API
Below API is planned but not implemented yet.
fetch(date="2020-11-20", fund="AAK")
A single fund's inormation for a given day.fetch(start_date="2020-11-19", end_date="2020-11-20")
All fund information for a given date range.fetch(start_date="2020-11-19", end_date="2020-11-20", fund="AAK")
A single fund's information for a given date range.
Data Schema
- Map each field to an appropriate data type instead of string.
- Add the "distribution" pane.
License
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
tefas-crawler-0.2.1.tar.gz
(4.9 kB
view hashes)
Built Distribution
Close
Hashes for tefas_crawler-0.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b060ee31689d630c4e2b21ef446c2761022e5a05902daf6fda8707821b9f29cd |
|
MD5 | cdff46c32b47feedf726e08d139ee5cc |
|
BLAKE2b-256 | 1eeab3ca902433b60dc581509f0e3534de2504592b015f754062d5f4e82cf730 |