StatsD Wire Protocol
The StatsD wire protocol is a UTF-8, line-oriented, UDP-by-default packet format used to push application metrics from clients to a StatsD daemon. Each line takes the form `bucket:value|type[|@sample_rate]`, where `type` is one of `c` (counter), `g` (gauge, with optional `+`/`-` for delta), `ms` (timer), `h` (histogram), `s` (set), or `m` (meter, in some dialects). Multiple metrics may share a packet when separated by `\n`. The protocol is connectionless on UDP (port 8125) and connection-oriented on TCP, where each metric MUST be terminated by `\n`. The wire format is the canonical contract between StatsD, its tag-aware dialects (DogStatsD, InfluxDB, SignalFx), and the wider ecosystem of clients and servers.
Documentation
Specifications
SDKs
Schemas & Data
JSONSchema
https://raw.githubusercontent.com/api-evangelist/statsd/refs/heads/main/json-schema/statsd-metric-line-schema.json
JSONSchema
https://raw.githubusercontent.com/api-evangelist/statsd/refs/heads/main/json-schema/statsd-metric-instance-schema.json
JSONStructure
https://raw.githubusercontent.com/api-evangelist/statsd/refs/heads/main/json-structure/statsd-metric-instance-structure.json