with_user_agent(
headers: 'dict[str, Any] | None' = None,
) -> 'dict[str, Any]'| Name | Type | Description |
|---|---|---|
headers | 'dict[str, Any] | None' | Default: NoneExisting header dict. Not mutated; a shallow copy is returned. |
Return headers with our UA prepended to any existing User-Agent.
When headers is None and telemetry is enabled, a new dict is
returned containing only the User-Agent entry. When telemetry is
disabled the input is returned unchanged (or an empty dict for
None input).