/mftool-java

Mutual Fund Realtime & Historic Library in Java. Java version of mftool python library

Primary LanguageJava

MFtool Java

Java library for getting realtime and historic Mutual Funds data in India

Build Status MIT Licence

Introduction

mftool-java is a library for getting Mutual Funds data in India in Java applications. It can be used in various types of projects which requires getting live quotes for a given scheme.

Note: This library requires internet connection to fetch Mutual Fund data.

Features

  • Fetch list of all the mutual fund schemes with their scheme-codes.
  • Match keyword with names of mutual fund list. (useful in auto-suggestion in searches).
  • Fetch historic NAV for the fund.
  • Fetch current NAV.
  • Fetch NAV for specific date.
  • Fetch Fund Details for fund.
  • Returns data in Java Objects.

Documentation

Maven
<dependency>
  <groupId>com.webencyclop.core</groupId>
  <artifactId>mftool-java</artifactId>
  <version>1.0.0</version>
</dependency>
Graddle
implementation 'com.webencyclop.core:mftool-java:1.0.0'

How to use in Java code:

// Return the List of mutual funds which matches keyword "Axis"
MFTool mfTool = new MFTool();
List<SchemeNameCodePair> list = mfTool.matchingScheme("Axis");

// Retuns List of all the mutual fund list in India
MFTool tool = new MFTool();
List<SchemeNameCodePair> list = tool.allSchemes();

// Retuns the Mutual Fund details - Axis fund: 120503
MFTool tool = new MFTool();
SchemeDetails details = tool.schemeDetails("120503");

// Returns hisoric NAV data - Axis fund: 120503
MFTool tool = new MFTool();
List<Data> list = tool.historicNavForScheme("120503");

// Returns current NAV for mutual fund
MFTool tool = new MFTool();
BigDecimal nav = tool.getCurrentNav("120503");

// Returns NAV for specific date
MFTool tool = new MFTool();
BigDecimal nav = tool.getNavFor("120503", LocalDate.parse("2021-07-13"));