MCPcopy Index your code
hub / github.com/google/adk-python / get_tracking_headers

Function get_tracking_headers

src/google/adk/utils/_google_client_headers.py:20–31  ·  view source on GitHub ↗

Returns a dictionary of HTTP headers for tracking API requests. These headers are used to identify HTTP calls made by ADK towards Vertex AI LLM APIs.

()

Source from the content-addressed store, hash-verified

18
19
20def get_tracking_headers() -> dict[str, str]:
21 """Returns a dictionary of HTTP headers for tracking API requests.
22
23 These headers are used to identify HTTP calls made by ADK towards
24 Vertex AI LLM APIs.
25 """
26 labels = get_client_labels()
27 header_value = " ".join(labels)
28 return {
29 "x-goog-api-client": header_value,
30 "user-agent": header_value,
31 }
32
33
34def merge_tracking_headers(headers: dict[str, str] | None) -> dict[str, str]:

Calls 2

get_client_labelsFunction · 0.85
joinMethod · 0.45