final class OpenApiGenerator (View source)

Projects the canonical endpoint registry and runtime configuration into an OpenAPI 3.1 document.

Methods

__construct(ApiEndpointRegistry $endpoints, ApiConfig $apiConfig, AppConfig $appConfig, FrameworkInfo $frameworkInfo)

Binds document generation to endpoint metadata, server configuration and framework identity.

array

Generates a fresh document for the endpoints currently held by the registry.

array

Details

__construct

__construct(ApiEndpointRegistry $endpoints, ApiConfig $apiConfig, AppConfig $appConfig, FrameworkInfo $frameworkInfo)

Binds document generation to endpoint metadata, server configuration and framework identity.

Parameters

ApiEndpointRegistry $endpoints
ApiConfig $apiConfig
AppConfig $appConfig
FrameworkInfo $frameworkInfo

generate

array generate()

Generates a fresh document for the endpoints currently held by the registry.

Return Value

array