Skip to content

Commit

Permalink
readme: add guides for the write to db feature
Browse files Browse the repository at this point in the history
Signed-off-by: Gunwant Jain <[email protected]>
  • Loading branch information
wantguns committed Oct 15, 2023
1 parent 44ad5b3 commit e634265
Showing 1 changed file with 34 additions and 6 deletions.
40 changes: 34 additions & 6 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Unfold is an unofficial [Fold Money](https://fold.money) CLI client, which
covers the bare minimum API routes to fetch your transactions for a given
period.
period and even write them to a sqlite database.

Fold's API is not publically available, I had to MITM their app to write this
tool, and so **there might be unforeseen consequences for your Fold account if
Expand All @@ -24,14 +24,42 @@ automatically logged out on your Phone's app**
$ unfold login
```

2. Then you can fetch your transactions in plaintext using:
```bash
$ unfold transactions -h
```
2. Then you can fetch your transactions:

a. In plaintext:
```bash
$ unfold transactions
```

b. In plaintext and also write to a db:
```bash
# Write to a local file called `db.sqlite` by default
$ unfold transactions -s 2023-09-20 --db
```

c. For a complete glossary of available options:
```
$ unfold transactions -h
Prints the transactions from all of your accounts (default period: 1 month)

Usage:
unfold transactions [flags]

Flags:
-d, --db Save the results in a sqlite db
-D, --db-path string Sets path for the database (default "db.sqlite")
-h, --help help for transactions
-s, --since string fetch transactions since in this format: YYYY-MM-DD (default "2023-09-15")
-t, --till string fetch transactions till in this format: YYYY-MM-DD (default "2023-10-16")

Global Flags:
--config string config file (default is $HOME/.config/unfold/config.yaml)
-v, --debug Enable debug mode
```

There are a few more subcommands which Unfold provides and uses internally. You
can get a list by:
```bash
```
$ unfold
An unofficial cli client for fold.money

Expand Down

0 comments on commit e634265

Please sign in to comment.