nat.utils.telemetry.payload#
Wire envelope construction for telemetry payloads.
Privacy: every potentially identifying field in the envelope is hardcoded to
"undefined". The only fields populated from runtime data are the version
string, CPU architecture, and the events themselves.
Classes#
In-memory wrapper around an event awaiting flush. |
Functions#
|
|
|
Build a wire envelope for a batch of queued events. |
Module Contents#
- class QueuedEvent#
In-memory wrapper around an event awaiting flush.
- timestamp: datetime.datetime#
- _iso_timestamp(dt: datetime.datetime | None = None) str#
- build_payload(
- events: list[QueuedEvent],
- *,
- source_client_version: str,
- session_id: str = 'undefined',
Build a wire envelope for a batch of queued events.
All identity-bearing fields are hardcoded to
"undefined"; do not change them without a privacy review. Only the events themselves and the harmless metadata (version, CPU arch) carry runtime information.