Bug: cannot filter by mutual fund name on tradebook

Please see that we cannot filter a mutual fund by its name.

Using ISIN also doesn’t work even though I do have trades done

@ShubhS9 @Neelesh

Hi @foobar will check this out and get back shortly.

were you able to redo the issue?

This seems to be scheme specific and are not able to reproduce this, please let me know if you are still facing this?

This is because your code doesn’t handle spaces. or urlencoded characters.

https://console.zerodha.com/api/reports/tradebook?segment=MF&from_date=2024-10-20&to_date=2024-11-19&page=1&tradingsymbol=mid%20cap&sort_by=trade_date&sort_desc=false

{"status":"error","message":"Invalid `tradingsymbol`.","data":"mid cap","error_type":"InputException"}

HTTP 400 error.

The scheme names can contain spaces, hyphens, colon, plus and more.

-https://coin.zerodha.com/mf/fund/INF209KB19H2/aditya-birla-sun-life-crisil-ibx-6040-sdlaaa-psu-apr-2027-index-fund-dire-direct-growth

@Neelesh requesting acknowledgement here

Hi @foobar we are checking this one.

As of now, this search tool is not built to handle random keywords. According to the screenshot, you’re searching for “mid-cap,” but to get results, for now you must enter the initials of the fund’s name. For example, if the tradebook contains funds like Zerodha Mid Cap Fund, PPFAS Flexi Cap Fund, and Quant Mid Cap Fund, you would need to search using terms like Zerodha, PPFAS, Quant, and similar identifiers. We are in the process of improving the search functionality, but it will take some time to implement these updates.

The API can handle words in the middle: mid works. cap works. But not mid cap.

Maybe it’s a payload validation error. The input validator is not allowing spaces. Try allowing spaces at least if not other characters that a scheme name can contain. The inner code might work with that!

To allow searching by ISIN code can be taken up later as an improvement.

1 Like

@Neelesh I found a hack: _ using undescore works. mid_cap returns this. edelweiss_mid works but not edelweiss_cap