GO-JSONSCHEMA(1)

NAME
go-jsonschema - Generates Go code from JSON Schema files

DESCRIPTION
Generates Go code from JSON Schema files.

  Usage:

    go-jsonschema FILE ... [flags]

  Flags:

--capitalization strings
    Specify a preferred Go capitalization for a string. For example, by default a field named 'id' becomes 'Id'. With --capitalization ID, it will be generated as 'ID'.

--disable-custom-types-for-maps
    Do not generate custom types when generating maps

--disable-omitempty
    disable the addition of omitempty tag values

--disable-omitzero
    disable the addition of omitzero tag values

--disable-readonly-validation
    Do not include validation of readonly fields

-e, --extra-imports
    Allow extra imports (non standard library)

-h, --help
    help for go-jsonschema

--min-sized-ints
    Uses sized int and uint values based on the min and max values for the field

--minimal-names
    Uses the shortest possible names

--only-models
    Generate only models (no unmarshal methods, no validation)

-o, --output string
    File to write (- for standard output) (default "-")

-p, --package string
    Default name of package to declare Go files under, unless overridden with --schema-package

--resolve-extension strings
    Add a file extension that is used to resolve schema names, e.g. {"$ref": "./foo"} will also look for foo.json if --resolve-extension json is provided.

--schema-output strings
    File to write (- for standard output) a specific schema ID to; must be in the format URI=FILENAME.

--schema-package strings
    Name of package to declare Go files for a specific schema ID under; must be in the format URI=PACKAGE.

--schema-root-type strings
    Override name to use for the root type of a specific schema ID; must be in the format URI=TYPE. By default, it is derived from the file name.

-t, --struct-name-from-title
    Use the schema title as the generated struct name

--tags strings
    Specify which struct tags to generate. Defaults are json, yaml, mapstructure (default [json,yaml,mapstructure])

-v, --verbose
    Verbose output

--yaml-extension strings
    Add a file extension that should be recognized as YAML. Default are .yml, .yaml. (default [.yml,.yaml])