uce/site/doc/pages/ws_scope.txt
2026-06-16 12:21:31 +00:00

19 lines
645 B
Plaintext

:sig
String ws_scope()
:params
return value : scope identifier of the current WebSocket endpoint
:see
>websocket
:content
Returns the runtime's scope identifier for the current WebSocket endpoint.
This is the same default scope used by `ws_send()`, `ws_connections()`, and `ws_connection_count()` when no explicit scope is supplied.
In the current runtime implementation this scope is the page's internal endpoint identifier, typically the absolute `SCRIPT_FILENAME` of the `.uce` file that accepted the WebSocket upgrade.
:example
print("ws_scope is resource-bound; configure the service or connection, then call it in request code.\n");