Add README
This commit is contained in:
parent
04457b8912
commit
874c984c6d
48
README.md
Normal file
48
README.md
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
# lndhub.go stats
|
||||||
|
|
||||||
|
A collection of [Deno][1] scripts for exporting anonymized statistics from
|
||||||
|
[lndhub.go][2] databases.
|
||||||
|
|
||||||
|
## Requirements
|
||||||
|
|
||||||
|
* [Deno](https://docs.deno.com/runtime/getting_started/installation/) (>= 2.3)
|
||||||
|
|
||||||
|
## Configuration
|
||||||
|
|
||||||
|
Copy `.env.example` to `.env` and edit the values. Or use system environment
|
||||||
|
variables instead.
|
||||||
|
|
||||||
|
* `BATCH_SIZE` controls how many parallel connections to your database are established
|
||||||
|
* `MAX_INVOICES` will skip users with extreme amounts of transactions (above this threshold)
|
||||||
|
|
||||||
|
## Generate anonymization key
|
||||||
|
|
||||||
|
Generate a random key so you can use it as `ANONYMIZATION_KEY`:
|
||||||
|
|
||||||
|
### Usage
|
||||||
|
|
||||||
|
deno run generate-key.ts
|
||||||
|
|
||||||
|
## Generate daily stats per user
|
||||||
|
|
||||||
|
This will generate daily statistics per user, exported to `daily-stats.csv`:
|
||||||
|
|
||||||
|
* Anonymized user ID
|
||||||
|
* Date
|
||||||
|
* Balance Start of Day
|
||||||
|
* Balance End of Day
|
||||||
|
* Balance Max Day
|
||||||
|
* Balance Min Day
|
||||||
|
* Total Flow Out
|
||||||
|
* Total Flow In
|
||||||
|
|
||||||
|
### Usage
|
||||||
|
|
||||||
|
deno run -A generate-stats.ts
|
||||||
|
|
||||||
|
## Contact
|
||||||
|
|
||||||
|
E-Mail, Chat, Social: raucao@kosmos.org
|
||||||
|
|
||||||
|
[1]: https://deno.com
|
||||||
|
[2]: https://github.com/getAlby/lndhub.go
|
Loading…
x
Reference in New Issue
Block a user