websockets.utils ================ .. py:module:: websockets.utils Functions --------- .. autoapisummary:: websockets.utils.param_from_path Module Contents --------------- .. py:function:: param_from_path(name: str, path: str) -> str Retrieve any query parameter from a path. Raises ValueError if path is not a valid URL path or if it does not contain exactly one query parameter named `name`. Multiple parameters with that name are not supported and will result in ValueError, as it hints to a misconfiguration. Example:: >>> param_from_path("schema", "/?schema=onegov_town6-meggen") 'onegov_town6-meggen'