Free, Open Source, Self-Hosted WhatsApp API Gateway
TypeScript apibotgatewayself-hostedwhatsappwhatsapp-apiwhatsapp-automationwhatsapp-botwhatsapp-gatewaywhatsapp-gateway-apiwhatsapp-webwhatsapp-web-api
docs(session): warn that a NODE_URL path is now kept
Yudhi Armyndharis3ce693959160
diff --git a/.env.example b/.env.exampleindex 63e09ac20..e498958e3 100644--- a/.env.example+++ b/.env.example@@ -536,7 +536,10 @@ WEBHOOK_SSRF_PROTECT=true# NODE_URL= # where THIS node answers HTTP for its peers, e.g.# http://10.0.0.5:2785 — set on EVERY node to enable# forwarding of session requests to the owning node;- # empty disables forwarding (single-node default)+ # empty disables forwarding (single-node default). A+ # path is kept and put in front of every forwarded+ # /api/... path, so give one only for a reverse-proxy+ # prefix: a value ending in /api forwards to /api/api/...# SESSION_PROXY_TIMEOUT_MS=60000 # ceiling for one forwarded request# MEDIA_CONVERSION_ENABLED=false # default falsediff --git a/docs/13-horizontal-scaling.md b/docs/13-horizontal-scaling.mdindex 2b5cab589..18db2edf3 100644--- a/docs/13-horizontal-scaling.md+++ b/docs/13-horizontal-scaling.md@@ -60,6 +60,12 @@> which is exactly how a takeover begins. Without `NODE_URL` the whole path is inert and> single-node deployments pay nothing.>+> A path on `NODE_URL` is kept (0.23.7 and later) and put in front of the forwarded request's own+> path, which already starts with `/api`. Give one only when the node is reached through a reverse+> proxy under that prefix (`NODE_URL=https://gw.example.com/node-a`); a node reached directly takes+> none. A `NODE_URL` ending in `/api` forwards to `/api/api/...`, and every routed request answers+> `404`.+>> **List and stats routes answer from the node that received them.** `GET /api/sessions` and> `GET /api/sessions/stats/overview` name no session, so they are never forwarded. `lastError`,> `restriction`, the stats `active` count and `memoryUsage` are that node's own view, not the owner's: