categorygen

command
v0.0.0-...-e970762 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 7, 2026 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Command categorygen derives the authoritative category lookups from openapi.yaml. Every schema that pins both a `type` const and a `category` const contributes an event-type entry, and every operation contributes an entry from its `x-telemetry-category`. openapi.yaml is the single source of truth; this generator just surfaces it to Go.

The api_call event reports the handler name oapi-codegen generated, not the spec's operationId, so operation entries are keyed by that name. The names are read out of the generated ServerInterface rather than derived from the operationId: each of its methods documents the route it serves, which joins to the spec on method and path with nothing assumed about how oapi-codegen spells a name. Run this after oapi-codegen, which `make oapi-generate` does.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL