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.
StatsD Wire Protocol is one of 3 APIs that StatsD publishes on the APIs.io network, described by an AsyncAPI event-driven specification.
This API exposes 3 JSON Schema definitions.
Tagged areas include Counters, Gauges, Histograms, Line Protocol, and Meters. The published artifact set on APIs.io includes API documentation, a GitHub repository, an AsyncAPI specification, a JSON-LD context, and 3 JSON Schemas.