Documentation
¶
Overview ¶
Package schemas derives JSON Schema fragments from Go types via reflection.
Index ¶
- func ApplyFieldOverrides(schema map[string]interface{}, overrides map[string]FieldMeta) []string
- func FromType(t reflect.Type) json.RawMessage
- func ResolvePointer(schema map[string]interface{}, path string) []map[string]interface{}
- func WrapV2Envelope(body json.RawMessage) json.RawMessage
- type FieldMeta
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyFieldOverrides ¶
ApplyFieldOverrides mutates schema in place; returns unresolved pointer paths (orphans).
func FromType ¶
func FromType(t reflect.Type) json.RawMessage
FromType derives a JSON Schema for t (cached per reflect.Type).
func ResolvePointer ¶
ResolvePointer extends RFC 6901 with `/*` for array items; tolerates structural mismatches.
func WrapV2Envelope ¶
func WrapV2Envelope(body json.RawMessage) json.RawMessage
WrapV2Envelope splices body into the `event` property; passes body through unchanged on parse fail.
Types ¶
Click to show internal directories.
Click to hide internal directories.