Update esphome/components/web_server_base/web_server_base.h

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
J. Nick Koston
2026-03-12 10:15:58 -10:00
committed by GitHub
parent b20a2a12a8
commit 2f4d7eae05
@@ -122,6 +122,13 @@ class WebServerBase {
#endif
void add_handler(AsyncWebHandler *handler);
/**
* WARNING: Registers a handler that bypasses the USE_WEBSERVER_AUTH middleware.
*
* This should only be used for endpoints that are intentionally unauthenticated
* (for example, captive portal or very limited-status endpoints). For normal
* endpoints that should respect web server authentication, use add_handler().
*/
void add_handler_without_auth(AsyncWebHandler *handler);
void set_port(uint16_t port) { port_ = port; }