Openapi.Phoenix (Openapi v0.1.0)

Copy Markdown View Source

Summary

Functions

Register an OpenAPI spec and its routes with the application.

Register swagger-ui to a given path.

Functions

openapi(path, options \\ [])

(macro)

Register an OpenAPI spec and its routes with the application.

Options:

  • handler: Default handler of the routes can be overwritten with x-handler
  • strict (Default true): Validates routes at compile time.
  • server: The server/namespace for this spec. Auto-detected from router module if not provided.

swagger_docs(path, options \\ [])

(macro)

Register swagger-ui to a given path.