Versions in this module Expand all Collapse all v0 v0.17.2 Mar 6, 2026 Changes in this version + const ApiProblemSchema + func AddPredefinedController(builder *DocumentBuilder, ctrl *server.PredefinedController, ...) + func AddResourceController(builder *DocumentBuilder, ctrl *server.ResourceController, ...) + func GetPatchBodySchema(patches []store.Patch) []byte + type Components struct + Responses map[string]SchemaItem + Schemas map[string]SchemaItem + type Document struct + Components *Components + Info *Info + Openapi string + Paths map[string]*PathItem + Servers []Server + Tags []Tag + func NewDocument() *Document + func (d *Document) Write(path string) error + type DocumentBuilder struct + func NewDocumentBuilder() *DocumentBuilder + func (b *DocumentBuilder) AddNewPath(path string) *PathItemBuilder + func (b *DocumentBuilder) AddPath(path string, pathItem *PathItem) *DocumentBuilder + func (b *DocumentBuilder) AddResponse(statusCode string, schemaItem SchemaItem) *DocumentBuilder + func (b *DocumentBuilder) AddSchemaBytes(name string, schemaBytes []byte) (*DocumentBuilder, error) + func (b *DocumentBuilder) AddSchemaBytesOrDie(name string, schemaBytes []byte) *DocumentBuilder + func (b *DocumentBuilder) AddSchemaItem(name string, schemaItem SchemaItem) *DocumentBuilder + func (b *DocumentBuilder) AddServer(url, description string) *DocumentBuilder + func (b *DocumentBuilder) Build() *Document + func (b *DocumentBuilder) BuildBytes() ([]byte, error) + func (b *DocumentBuilder) NewInfo(title, description, version string) *DocumentBuilder + func (b *DocumentBuilder) SetOpenapiVersion(version string) *DocumentBuilder + type Info struct + Description string + Title string + Version string + type MediaType struct + Schema *SchemaItem + type OpenAPIController struct + Document *Document + func NewOpenAPIController(doc *Document) *OpenAPIController + func (r *OpenAPIController) GetOpenAPI(c *fiber.Ctx) error + func (r *OpenAPIController) Register(router fiber.Router, opts server.ControllerOpts) + type Operation struct + Description string + OperationId string + Parameters []*Parameter + RequestBody *RequestBody + Responses map[string]*Response + Summary string + Tags []string + type OperationBuilder struct + func NewOperationBuilder() *OperationBuilder + func (b *OperationBuilder) AddParameter(parameter *Parameter) *OperationBuilder + func (b *OperationBuilder) AddTags(tags ...string) *OperationBuilder + func (b *OperationBuilder) Build() *Operation + func (b *OperationBuilder) SetCustomRequestBody(contentType string, SchemaItem SchemaItem) *OperationBuilder + func (b *OperationBuilder) SetCustomResponse(statusCode, contentType string, SchemaItem SchemaItem) *OperationBuilder + func (b *OperationBuilder) SetDescription(description string) *OperationBuilder + func (b *OperationBuilder) SetJsonRequestBody(SchemaItem SchemaItem) *OperationBuilder + func (b *OperationBuilder) SetJsonRequestBodyBytes(SchemaItemBytes []byte) *OperationBuilder + func (b *OperationBuilder) SetJsonResponse(statusCode string, SchemaItem SchemaItem) *OperationBuilder + func (b *OperationBuilder) SetJsonResponseBytes(statusCode string, SchemaItemBytes []byte) *OperationBuilder + func (b *OperationBuilder) SetMeta(summary, operationId string) *OperationBuilder + type Parameter struct + Description string + In string + Name string + Required bool + Schema *SchemaItem + func GetFilterParameters(filters []store.Filter) []*Parameter + type ParameterBuilder struct + func NewParameterBuilder() *ParameterBuilder + func (b *ParameterBuilder) Build() *Parameter + func (b *ParameterBuilder) SetDescription(description string) *ParameterBuilder + func (b *ParameterBuilder) SetIn(in string) *ParameterBuilder + func (b *ParameterBuilder) SetName(name string) *ParameterBuilder + func (b *ParameterBuilder) SetRequired(required bool) *ParameterBuilder + func (b *ParameterBuilder) SetSchema(SchemaItem SchemaItem) *ParameterBuilder + type PathItem struct + Delete *Operation + Get *Operation + Patch *Operation + Post *Operation + Put *Operation + type PathItemBuilder struct + func NewPathItemBuilder() *PathItemBuilder + func (b *PathItemBuilder) Build() *PathItem + func (b *PathItemBuilder) SetOperation(method string, operation *Operation) *PathItemBuilder + type RequestBody struct + Content map[string]*MediaType + type Response struct + Content map[string]*MediaType + Description string + type Responses map[string]*Response + type SchemaItem map[string]any + func NewArrayOfSchemaItemWithRef(ref SchemaItem) SchemaItem + func NewSchemaItemResponseRef(statusCode string) (string, SchemaItem) + func NewSchemaItemSchemaRef(name string) SchemaItem + func NewSchemaItemType(schemaType string) SchemaItem + func (s SchemaItem) AddAttribute(name string, value any) SchemaItem + type Server struct + Description string + Url string + type Tag struct + Name string