openapi

package
v0.0.0-...-9358009 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package openapi builds the Huma API with every domain registered, over whatever infrastructure it is handed, so `gonext openapi` can produce the document with no database and no environment. Nothing in a running server imports it.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Spec

type Spec struct {
	API huma.API
}

Spec is what Initialize returns: the API with every registration applied. It mirrors main's App but carries only what producing the document needs.

func Initialize

func Initialize(cfg config.Config, logger *slog.Logger, db *bun.DB) (*Spec, error)

Initialize builds the same Huma API InitializeApp builds, over a fixed config and a *bun.DB that never dials — registration only constructs repositories. Run `gonext generate` after editing the provider list below.

func NewSpec

NewSpec assembles Spec. Its marker parameters aren't read; depending on them is what forces wire to run every registration before Initialize returns.

Jump to

Keyboard shortcuts

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