README and API doc

This commit is contained in:
aceberg 2025-07-27 02:19:17 +07:00
parent f6977e290b
commit d314297fa2
3 changed files with 16 additions and 6 deletions

View file

@ -3,14 +3,14 @@ All notable changes to this project will be documented in this file.
## [v2.1.3] - 2025-07-26
### Fixed
- Memory leak bug [#149](https://github.com/aceberg/WatchYourLAN/pull/149)
- Duplicated devices bug [##187](https://github.com/aceberg/WatchYourLAN/pull/#187) [##198](https://github.com/aceberg/WatchYourLAN/pull/#198)
- Memory leak bug [#149](https://github.com/aceberg/WatchYourLAN/issues/149)
- Duplicated devices bug [#187](https://github.com/aceberg/WatchYourLAN/issues/187) [#198](https://github.com/aceberg/WatchYourLAN/issues/198)
### Changed
- **DEPRECATED:** `HIST_IN_DB` config option. Now history is always stored in `DB`
- Upd to `go 1.24.5`
- Moved `DB` handling to `GORM`
- Moved to maintained `Shoutrrr`: [github.com/nicholas-fedor/shoutrrr](github.com/nicholas-fedor/shoutrrr) ([#197](https://github.com/aceberg/WatchYourLAN/pull/197))
- Moved to maintained `Shoutrrr`: [github.com/nicholas-fedor/shoutrrr](https://github.com/nicholas-fedor/shoutrrr) ([#197](https://github.com/aceberg/WatchYourLAN/issues/197))
## [v2.1.2] - 2025-03-30
### Fixed

View file

@ -93,7 +93,7 @@ Configuration can be done through config file, GUI or environment variables. Var
| THEME | Any theme name from https://bootswatch.com in lowcase or [additional](https://github.com/aceberg/aceberg-bootswatch-fork) | sand |
| COLOR | Background color: light or dark | dark |
| NODEPATH | Path to local node modules | |
| SHOUTRRR_URL | WatchYourLAN uses [Shoutrrr](https://github.com/containrrr/shoutrrr) to send notifications. It is already integrated, just needs a correct URL. Examples for Discord, Email, Gotify, Matrix, Ntfy, Pushover, Slack, Telegram, Generic Webhook and etc are [here](https://containrrr.dev/shoutrrr/v0.8/services/gotify/) | |
| SHOUTRRR_URL | WatchYourLAN uses [Shoutrrr](https://github.com/nicholas-fedor/shoutrrr) to send notifications. It is already integrated, just needs a correct URL. Examples for Discord, Email, Gotify, Matrix, Ntfy, Pushover, Slack, Telegram, Generic Webhook and etc are [here](https://nicholas-fedor.github.io/shoutrrr/) | |
### Scan settings
| Variable | Description | Default |

View file

@ -6,9 +6,19 @@ Returns all hosts in `json`.
```http
GET /api/history/*mac
GET /api/history
```
Returns all History. If `mac` is not empty, returns only history of a device with this `mac`.
Returns all History. Not recommended, the output can be a lot.
```http
GET /api/history/:mac/:date
```
Returns only history of a device with this `mac` filtered by `date`. `date` format can be anything from `2` to `2025-07` to `2025-07-26`.
```http
GET /api/history/:mac?num=20
```
Returns only last 20 lines of history of a device with this `mac`.
```http