oaisp/info

The top-level metadata for the emitted OpenAPI document.

Types

OpenAPI document metadata: the API’s title and version, an optional description, and the server URLs it is served from.

Build the common case with info and spread to override the rest:

Info(..info("Todo API", "1.0.0"), description: Some("Manage todos"))
pub type Info {
  Info(
    title: String,
    version: String,
    description: option.Option(String),
    servers: List(String),
  )
}

Constructors

  • Info(
      title: String,
      version: String,
      description: option.Option(String),
      servers: List(String),
    )

Values

pub fn info(title title: String, version version: String) -> Info

An Info with no description and no servers. Spread it to set those fields.

Search Document