Documentation
¶
Overview ¶
Package schema provides JSON Schema generation for CLI output types
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PrintCommandSchema ¶
PrintCommandSchema outputs schema with command metadata
Types ¶
type CommandSchema ¶
type CommandSchema struct {
Command string `json:"command"`
Description string `json:"description"`
Output *JSONSchema `json:"output"`
}
CommandSchema holds schema information for a CLI command
type JSONSchema ¶
type JSONSchema struct {
Schema string `json:"$schema,omitempty"`
Type string `json:"type,omitempty"`
Description string `json:"description,omitempty"`
Properties map[string]*JSONSchema `json:"properties,omitempty"`
Items *JSONSchema `json:"items,omitempty"`
Required []string `json:"required,omitempty"`
Enum []string `json:"enum,omitempty"`
Format string `json:"format,omitempty"`
Nullable bool `json:"nullable,omitempty"`
}
JSONSchema represents a JSON Schema document
Click to show internal directories.
Click to hide internal directories.