converter

package
v0.0.0-...-35773e5 Latest Latest
Warning

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

Go to latest
Published: Jun 13, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Convert

func Convert(inputFile, outputFile string) error

Types

type Components30

type Components30 struct {
	SecuritySchemes map[string]SecurityScheme `json:"securitySchemes"`
	Schemas         map[string]Schema30       `json:"schemas"`
}

type Components31

type Components31 struct {
	SecuritySchemes map[string]SecurityScheme `json:"securitySchemes"`
	Schemas         map[string]Schema31       `json:"schemas"`
}

type Info

type Info struct {
	Title   string `json:"title"`
	Version string `json:"version"`
}

type OpenAPI30

type OpenAPI30 struct {
	Openapi    string                 `json:"openapi"`
	Info       Info                   `json:"info"`
	Components Components30           `json:"components"`
	Paths      map[string]interface{} `json:"paths"`
}

type OpenAPI31

type OpenAPI31 struct {
	Openapi    string                 `json:"openapi"`
	Info       Info                   `json:"info"`
	Components Components31           `json:"components"`
	Paths      map[string]interface{} `json:"paths"`
}

type Property30

type Property30 struct {
	Type                 string                `json:"type,omitempty"`
	Format               string                `json:"format,omitempty"`
	Enum                 []string              `json:"enum,omitempty"`
	Properties           map[string]Property30 `json:"properties,omitempty"`
	Items                *Property30           `json:"items,omitempty"`
	AdditionalProperties *bool                 `json:"additionalProperties,omitempty"`
	AnyOf                []*Property30         `json:"anyOf,omitempty"`
}

type Property31

type Property31 struct {
	Type                 *string               `json:"type,omitempty"`
	Format               string                `json:"format,omitempty"`
	Enum                 []interface{}         `json:"enum,omitempty"`
	Properties           map[string]Property31 `json:"properties,omitempty"`
	Items                *Property31           `json:"items,omitempty"`
	AdditionalProperties *bool                 `json:"additionalProperties,omitempty"`
	OneOf                []*Property31         `json:"oneOf,omitempty"`
	AnyOf                []*Property31         `json:"anyOf,omitempty"`
	AllOf                []*Property31         `json:"allOf,omitempty"`
}

type Schema30

type Schema30 struct {
	Type                 string                `json:"type,omitempty"`
	Properties           map[string]Property30 `json:"properties,omitempty"`
	Items                *Schema30             `json:"items,omitempty"`
	AdditionalProperties *bool                 `json:"additionalProperties,omitempty"`
	Enum                 []string              `json:"enum,omitempty"`
	Required             []string              `json:"required,omitempty"`
	AnyOf                []*Schema30           `json:"anyOf,omitempty"`
	Format               string                `json:"format,omitempty"`
	Title                string                `json:"title,omitempty"`
}

type Schema31

type Schema31 struct {
	Type                 *string               `json:"type,omitempty"`
	Properties           map[string]Property31 `json:"properties,omitempty"`
	Items                *Schema31             `json:"items,omitempty"`
	AdditionalProperties *bool                 `json:"additionalProperties,omitempty"`
	Enum                 []interface{}         `json:"enum,omitempty"`
	Required             []string              `json:"required,omitempty"`
	OneOf                []*Schema31           `json:"oneOf,omitempty"`
	AnyOf                []*Schema31           `json:"anyOf,omitempty"`
	AllOf                []*Schema31           `json:"allOf,omitempty"`
	Format               string                `json:"format,omitempty"`
	Title                string                `json:"title,omitempty"`
}

type SecurityScheme

type SecurityScheme struct {
	Type string `json:"type"`
	Name string `json:"name"`
	In   string `json:"in"`
}

Jump to

Keyboard shortcuts

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