fix: make the badge look like badge

This commit is contained in:
Jet 2026-03-23 22:45:49 -07:00
parent 87d3fee588
commit 2374e3cd60
No known key found for this signature in database
2 changed files with 38 additions and 10 deletions

View file

@ -11,11 +11,24 @@ If the Pi stops responding to polls (configurable threshold, default 3 misses),
| Method | Path | Auth | Description |
|--------|------|------|-------------|
| `GET` | `/status` | — | Current door status (`status`, `since`, `last_checked`) |
| `GET` | `/badge.svg` | — | Live README badge with Noisebridge logo |
| `POST` | `/webhook` | Bearer | Inbound webhook from the Pi |
| `GET` | `/health` | — | Health check |
`since` is the Pi-reported time when the current state began. `last_checked` is when the cache most recently attempted a poll.
## Badge
`/badge.svg` serves a classic shields.io-style SVG badge with the Noisebridge logo and the current cache status (`open`, `closed`, or `offline`).
Use it in a GitHub README like this:
```md
[![Space status](https://your-cache-domain.example.com/badge.svg)](https://your-cache-domain.example.com/status)
```
That keeps the badge clickable and sends readers to the live `/status` endpoint.
## Configuration
NixOS options under `services.noisebell-cache`: