MethodFi / method-node

Node.js library for the Method API
MIT License
4 stars 4 forks source link

Incomplete Typings for Delinquency Data #50

Closed obiknows closed 7 months ago

obiknows commented 7 months ago

Hey Method Team,

Love the SDK. It's a great product. So far I've had no complaints when using it in Typescript because the typings are very in-depth and excellent. However, I noticed that there were some missing types as it relates to delinquency data, which is making find past due loans very difficult for me.

For Example:

When looking for delinquency period data with credit cards, I get the following output in Typescript.

Typescript gives error when trying to log delinquency data IAccountLiabilityCreditCard
Screenshot 2024-01-26 at 23 29 25

However, when I log the entire IAccountLiabilityCreditCard object into the console, the data is in fact present, it is just not typed. (see below)

I believe this is the case for credit_cards, student_loans, auto_loans, mortages, and potentially more data objects

Logging IAccountLiabilityCreditCard
Screenshot 2024-01-26 at 23 29 47
Output (Delinquency data is clearly being passed)
Screenshot 2024-01-26 at 23 30 18

I am using the most current version of method-node -> method-node@0.3.24

ossiggy commented 7 months ago

Thanks for flagging this. Fixed in version 0.3.25.

obiknows commented 7 months ago

Thank you, works perfectly