aboutsummaryrefslogtreecommitdiff
path: root/config.example.yaml
diff options
context:
space:
mode:
authorFuwn <[email protected]>2026-01-20 17:30:15 -0800
committerFuwn <[email protected]>2026-01-20 17:30:15 -0800
commit8b0f24948b3bfb68bf0eb284a5a984f55c9693d4 (patch)
tree23d60be9cb58f41f2c3c1f794567617818576328 /config.example.yaml
parentfeat: Add dockerx command for multi-platform builds (diff)
downloadkaze-8b0f24948b3bfb68bf0eb284a5a984f55c9693d4.tar.xz
kaze-8b0f24948b3bfb68bf0eb284a5a984f55c9693d4.zip
feat: Add POST /api/reload endpoint for config reload
- Add /api/reload endpoint that triggers configuration reload - Always requires API key authentication (even if api.access is public) - Returns error if no API keys are configured - Update config.example.yaml with new endpoint and {group}/{name} format docs
Diffstat (limited to 'config.example.yaml')
-rw-r--r--config.example.yaml19
1 files changed, 14 insertions, 5 deletions
diff --git a/config.example.yaml b/config.example.yaml
index 91d17e9..1aa725a 100644
--- a/config.example.yaml
+++ b/config.example.yaml
@@ -370,18 +370,27 @@ incidents:
# GET /api/health - Simple health check (always public)
# Returns: {"status": "ok"}
# GET /api/status - All monitors status JSON
-# GET /api/monitor/{name} - Single monitor status JSON
-# GET /api/history/{name} - Monitor history (supports ?mode=ping|minute|hour|day&count=N)
+# GET /api/monitor/{group}/{name}
+# - Single monitor status JSON
+# GET /api/history/{group}/{name}
+# - Monitor history (supports ?mode=ping|minute|hour|day&count=N)
# GET /api/page - Full page data (monitors + history + status) in one request
# Note: Always public when refresh_mode is "api"
# GET /api/summary - Lightweight status overview (counts + overall status, no history)
-# GET /api/uptime/{name} - Historical uptime stats for a monitor
+# GET /api/uptime/{group}/{name}
+# - Historical uptime stats for a monitor
# Supports ?period=1h|24h|7d|30d|90d (default: 24h)
# GET /api/incidents - List incidents from config
# Supports ?filter=all|active|resolved|scheduled (default: all)
-# GET /api/badge/{name}.svg - SVG status badge (always public, shields.io style)
+# GET /api/badge/{group}/{name}.svg
+# - SVG status badge (always public, shields.io style)
# Supports: ?label=custom&style=flat|plastic&type=status|uptime
-# Example: ![Status](https://status.example.com/api/badge/Website.svg)
+# Example: ![Status](https://status.example.com/api/badge/Services/Website.svg)
+# POST /api/reload - Reload configuration (always requires API key)
+# Returns: {"status": "ok", "message": "Configuration reloaded successfully"}
+#
+# Note: Monitor endpoints use {group}/{name} path format. URL-encode slashes in names.
+# Example: /api/monitor/Services/API or /api/monitor/A%2FB%20Tests/Variant%20A
#
# Authentication (when access is "authenticated"):
# - Header: X-API-Key: your-secret-key