NAV
Net Asset Value data — latest NAVs, historical ranges, high/low, comparisons, and the full NAV flat-file download.
Data dictionary: NAV field reference →
amfipy.nav.NAVClient
Sync client for NAV data.
latest(mf_id='all', fund_type='', as_df=False)
Fetch latest NAV for all (or one) AMC.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
mf_id
|
str | int
|
"all" or numeric AMC ID (e.g. 62 for 360 ONE). |
'all'
|
fund_type
|
str
|
""=All | "Open Ended" | "Close Ended" | "Interval Fund" |
''
|
as_df
|
bool
|
Return polars DataFrame (requires |
False
|
Returns:
| Type | Description |
|---|---|
Any
|
|
latest_by_category(mf_id='all', fund_type='')
Fetch latest NAV grouped by category.
schemes(mf_id)
Return all schemes for a given AMC (by numeric ID).
Returns list of {"nav_id": "154043", "nav_name": "Scheme Name", "MF_ID": "85"}.
Use nav_id as sd_id in history calls.
all_navs_for_date(date, as_df=False)
All scheme NAVs as of a specific date.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
date
|
str
|
"YYYY-MM-DD" (e.g. "2026-03-31"). |
required |
as_df
|
bool
|
Return polars DataFrame. |
False
|
Returns:
| Type | Description |
|---|---|
Any
|
List of AMC groups, each with |
history(sd_id, from_date, to_date, as_df=False)
Historical NAV for a scheme over a date range.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
sd_id
|
int | str
|
Scheme ID ( |
required |
from_date
|
str
|
"YYYY-MM-DD" |
required |
to_date
|
str
|
"YYYY-MM-DD" |
required |
as_df
|
bool
|
Return polars DataFrame. |
False
|
Returns:
| Type | Description |
|---|---|
Any
|
Dict with |
high_low(sd_id, from_date, to_date, period_type='Month', nav_type='Both', as_df=False)
High/Low NAV for a scheme over a period.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
sd_id
|
int | str
|
Scheme ID. |
required |
from_date
|
str
|
"YYYY-MM-DD" |
required |
to_date
|
str
|
"YYYY-MM-DD" |
required |
period_type
|
str
|
"Month" | "Annual" |
'Month'
|
nav_type
|
str
|
"high" | "Low" | "Both" |
'Both'
|
as_df
|
bool
|
Return polars DataFrame. |
False
|
Returns:
| Type | Description |
|---|---|
Any
|
Dict with |
compare(sd_id, date1, date2, as_df=False)
Compare NAV of a scheme on two dates.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
sd_id
|
int | str
|
Scheme ID. |
required |
date1
|
str
|
"YYYY-MM-DD" (from_date) |
required |
date2
|
str
|
"YYYY-MM-DD" (to_date) |
required |
as_df
|
bool
|
Return polars DataFrame. |
False
|
Returns:
| Type | Description |
|---|---|
Any
|
Dict with |
download_file(date)
Download the full NAV flat file for a date from AMFI portal.
Returns raw bytes of the plain-text NAV file (same as the classic NAVAll.txt).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
date
|
str
|
"DD-Mon-YYYY" e.g. "31-Mar-2026". |
required |
Example::
data = client.download_file("31-Mar-2026")
Path("navs.txt").write_bytes(data)
fetch_range(sd_id, months, as_df=False)
Fetch historical NAV for a scheme across multiple date ranges.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
sd_id
|
int | str
|
Scheme ID. |
required |
months
|
list[tuple[str, str]]
|
List of |
required |
as_df
|
bool
|
Return polars DataFrames. |
False
|
Returns list in same order as months.