MCPcopy Create free account
hub / github.com/apify/crawlee-python / get_query_params

Function get_query_params

tests/unit/server.py:48–57  ·  view source on GitHub ↗

Extract and parse query parameters from the request.

(query_string: bytes)

Source from the content-addressed store, hash-verified

46
47
48def get_query_params(query_string: bytes) -> dict[str, str]:
49 """Extract and parse query parameters from the request."""
50 args = parse_qs(query_string.decode(), keep_blank_values=True)
51 result_args = {}
52
53 for key, values in args.items():
54 if values:
55 result_args[key] = values[0]
56
57 return result_args
58
59
60def get_cookies_from_headers(headers: dict[str, Any]) -> dict[str, str]:

Callers 6

set_cookiesFunction · 0.85
post_echoFunction · 0.85
redirect_to_urlFunction · 0.85
get_echoFunction · 0.85
echo_contentFunction · 0.85
slow_responseFunction · 0.85

Calls 1

itemsMethod · 0.80

Tested by

no test coverage detected