https://github.com/windler/etf-dash
Stock (etf) portfolio dashboard and api
https://github.com/windler/etf-dash
Last synced: 3 months ago
JSON representation
Stock (etf) portfolio dashboard and api
- Host: GitHub
- URL: https://github.com/windler/etf-dash
- Owner: windler
- License: mit
- Created: 2018-09-08T12:24:35.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-09-08T12:53:45.000Z (almost 8 years ago)
- Last Synced: 2025-03-13T21:26:15.819Z (over 1 year ago)
- Language: HTML
- Size: 255 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
[](https://goreportcard.com/report/github.com/windler/etf-dash) [](https://codebeat.co/projects/github-com-windler-etf-dash-master)
# etf-dash
Stock api and dashboard for stock (etf) simulations. Its main purpose was to get a idea how an etf portfolio will progress over time and visualize compounded interest.
# Installation
```bash
go get -u github.com/windler/etf-dash
```
# Usage
`etf-dash` bases on [alphavantage-api](https://www.alphavantage.co/). Therefore, you need an api key. If no key is provided the `demo` key is used. After obtaining a key, start the api server via (assuming etf-dash is in your `$PATH`)
```bash
etf-dash -apiKey="YOUR_API_KEY"
```
This will start a webserver listening on `:1234`.
#Dashboard
You can access a dashboard via `localhost:1234`.


# JSON-api
Via `localhoist:1234/getData` you can access the JSON-api.
The request payload follows the following structs:
```go
type GetDataRequest struct {
Savings []stockdata.MonthlySaving `json:"savings"`
Allowance float64 `json:"allowance"`
TransactionCostPercentage float64 `json:"transactionCostPercentage"`
From string `json:"from"`
To string `json:"to"`
}
```
```go
type MonthlySaving struct {
Symbol string `json:"symbol"`
InitialAmount float64 `json:"initialAmount"`
Saving float64 `json:"monthlySavings"`
}
```
# Data
Tax calculation are based on german tax law (2018). There is no guarantee that any of the calculated data is correct.