add server settings api

This commit is contained in:
Nystik
2026-06-06 13:04:34 +02:00
parent 938a698795
commit b43d12f702
6 changed files with 141 additions and 2 deletions

View File

@@ -19,6 +19,9 @@ const DEFAULTS = {
const KEYS = Object.keys(DEFAULTS);
// Hard ceiling for request bodies.
const MAX_BODY_BACKSTOP = 500 * 1024 * 1024;
function parseList(raw) {
return raw
.split(",")
@@ -88,4 +91,4 @@ function update(partial) {
return getAll();
}
module.exports = { DEFAULTS, KEYS, getAll, get, update };
module.exports = { DEFAULTS, KEYS, MAX_BODY_BACKSTOP, getAll, get, update };