import "github.com/egdaemon/eg/runtime/wasi/egmetrics"
func Record(ctx context.Context, name string, m any) error
Records a metric payload for the given name. the name field is an opaque string identifying the metric. the payload must be consistent with field name -> types. the prefix 'eg.' is reserved for system use. e.g.) ✓ Record(ctx, "example.metric.1", m) e.g.) x Record(ctx, "eg.example.metric.1", m) metrics will be encoded as follows: