jameskokoska / Cashew

💸 An app created to help users manage a budget and purchases
https://cashewapp.web.app/
GNU General Public License v3.0
1.62k stars 224 forks source link

[Feature Request/Discussion] App Links for automatically adding transactions to Cashew #127

Closed HenryWu01 closed 7 months ago

HenryWu01 commented 8 months ago

Thanks you for developing such an nice budget management application. I would like to request an API for adding bills, enabling “Cashew” to bypass the need for in-app support for automatic bill recording. Third-party applications can take on the responsibility of implementing methods to extract bill information from payment apps, either through reading program data or OCR, and subsequently calling the “Cashew” API to add the extracted information to the bills. This approach would facilitate “automated” bill recording.

I believe the most suitable method for this purpose would be to implement a URI scheme. Since this feature is exclusively for adding records, there are no significant concerns regarding data leakage. “Cashew” can enhance security and control by implementing measures such as “API keys”, “rate limiting”, and an “application allow list” to thwart any potential malicious software or behaviors.

A popular app in China named “钱迹” (Qianji) already offers a feature like this.

Below is a sample URI scheme:

cashew://addbill?type=0&amount=123.4&account=Account&category=Category&subcategory=Subcategory&time=2023-10-29T00:00:00Z&remark=Sample
Name Description
type Type of transaction (e.g., expense, income, transfer, etc.)
amount Transaction amount
account Account book
category Transaction category
subcategory Transaction subcategory
time Transaction time
remark Transaction remark
jameskokoska commented 8 months ago

Somewhat duplicate of https://github.com/jameskokoska/Cashew/issues/99

Since Cashew is a server less application and all data is stored on device, there is no API connection that can be created. Cashew does not connect to any application specific server for getting user data and therefore cannot receive requests.

HenryWu01 commented 8 months ago

I'm sorry I did not clearly explain this feature. This feature propose an URI scheme that allows third-party applications to add bill into Cashew. It's not about editing or exporting, just inserting bills using URI Scheme

jameskokoska commented 8 months ago

As I mentioned, Cashew does not have any backend server to connect to. It's a server-less application.

Edit: After looking into it more, it seems like a server-less solution is possible with deep linking (not app linking). I can look into adding this in the future, however I'm going to keep this issue closed as I have no immediate plans as of now. I find this is a really niche feature.

HenryWu01 commented 8 months ago

Thank you for considering this feature. Yes, it is possible with the serverless app through deep-linking (URI scheme). That's what I am saying about the feature. Provice some kind of URI scheme or deep linking so other application can call it to add bill into Cashew. Sorry for the unclear description of the feature

jameskokoska commented 7 months ago

Added in 5.2.3+328 Documentation here: https://github.com/jameskokoska/Cashew/tree/main?tab=readme-ov-file#app-links

HenryWu01 commented 6 months ago

Added in 5.2.3+328 Documentation here: https://github.com/jameskokoska/Cashew/tree/main?tab=readme-ov-file#app-links

Thank you so much! With this feature implemented, Cashew can be so powerful to use. Thank you for taking consideration of this feature and implementing it!

ngocanhtve commented 6 months ago

Added in 5.2.3+328 Documentation here: https://github.com/jameskokoska/Cashew/tree/main?tab=readme-ov-file#app-links

Thank you so much! With this feature implemented, Cashew can be so powerful to use. Thank you for taking consideration of this feature and implementing it!

How to use this feature?

jameskokoska commented 6 months ago

Added in 5.2.3+328 Documentation here: https://github.com/jameskokoska/Cashew/tree/main?tab=readme-ov-file#app-links

Thank you so much! With this feature implemented, Cashew can be so powerful to use. Thank you for taking consideration of this feature and implementing it!

How to use this feature?

The documentation has some examples of its usage! Please see the README

ngocanhtve commented 6 months ago

The documentation has some examples

Read it but don't understand how it works. Can't imagine how it would work. Can @HenryWu01 illustrate?

tiniwings commented 3 months ago

The documentation has some examples

Read it but don't understand how it works. Can't imagine how it would work. Can @HenryWu01 illustrate?

Hi, I am using this applink feature with Tasker integration to automate my credit card transactions.

Below are some sreps at high level, implementation is more customized based on individual usage.

  1. In Tasker you can read the incoming sms notification from bank/credit card and split the information into multiple parts like Amount, Category..
  2. In Tasker there is an option to trigger custom URL with specified app.
  3. Using the split information we create the custom Cashew applink with amount, category information and trigger that link from Tasker whenever we receive transaction sms/notification.
  4. The URL will automatically opens cashew app creates a transaction.

I would like to use this opportunity to thank @HenryWu01 and @jameskokoska for this feature, as this is the biggest reason I have moved to Cashew app for budgeting. 🙏

jameskokoska commented 3 months ago

@tiniwings I'm glad you made good use out of this feature :)

Similar to Tasker, a free alternative - Automate (https://play.google.com/store/apps/details?id=com.llamalab.automate) can do a similar workflow. Here's a proof of concept flow for those interested: Screenshot_20240609_100634_Automate.png

HappyBear-btc commented 3 months ago

so are you considering opening TG group?

jameskokoska commented 3 months ago

so are you considering opening TG group?

Please see https://github.com/jameskokoska/Cashew/issues/154

HappyBear-btc commented 3 months ago

right. thanks.

jameskokoska commented 2 months ago

Just thought I would throw this in here for fun. Linking Cashew's App Link API with Google Gemini AI has a lot of potential!

https://github.com/jameskokoska/Cashew/assets/50821962/c66581c5-482c-49da-8eb3-ce1175778753

Akv2021 commented 2 months ago

@jameskokoska Didn't get the part how you're proposing to use Google Gemini AI above. Also, Would you mind sharing the automator script which can act as a reference since the current documentation doesn't talk about any sample script which extracts the data from incoming message & posts to cashew URI.

RoshanJ20 commented 1 month ago

@Akv2021 @jameskokoska So, i tried making a flow for this feature on Automate. I can link it up here. The app package can be changed according to your required banking app. You may also need to change the regex pattern (I used https://regex101.com/ ). I have also defaulted to Shopping coz why not. Have Fun!

Download here:https://drive.google.com/file/d/1aPjvzjKtXM-ng0p1j_4x5KCyjsxSqdVi/view?usp=sharing

MaazAhmad360 commented 1 month ago

@jameskokoska can we get an App Link for transfer between accounts? Apart from that really love the already added app links!

pietroMonta42 commented 4 days ago

I really like the app, can you implement a multiple account feature where i can have multiple google accounts and i can change between them with a tap Thaks