Python library for getting Mutual Funds data in India
MFLib is a library for getting publically available Mutual Funds data in India. It can be used in various types of projects which requires getting live quotes for a given mutual fund scheme or build large data sets for further data analytics.
- Getting last updated quotes for Mutual fund scheme using scheme codes.
- Return data in Dataframe, json and dictionary formats.
- Getting quotes for all the schemes available with AMFI.
- Helper APIs to check whether a given Scheme code is correct.
- Getting all historical NAVs for a schemes.
- Getting list of all schemes with there Scheme codes.
- Get daily scheme performance.
-
Clone the repository and set up a virtual environment:
git clone <your-repo-url> cd MFLib python3 -m venv venv source venv/bin/activate pip install -r requirements.txt
-
Run or debug in VS Code:
- Open the folder in VS Code.
- Press
F5or use the Run/Debug panel to start debugging. - Ensure the Python interpreter is set to your virtual environment (
venv).
-
Run tests (if available):
python -m unittest discover tests
-
Install build tools:
pip install build
-
Build the package:
python -m build
This will create
dist/with.tar.gzand.whlfiles.
-
Install Twine:
pip install twine
-
Upload to PyPI:
twine upload dist/*You will be prompted for your PyPI credentials.