Releases: masitings/geni-api
Releases · masitings/geni-api
Release list
v2.0.1
Documentation & Maintenance
- Clarified documentation wording to emphasize standard OpenAPI docblock conventions and seamless migration from other generators.
- Added official trademark disclaimers in README and documentation.
- Linked full documentation references directly to geni.masiting.dev.
- Removed internal test dependency
dedoc/scrambleto keep development dependencies clean and completely self-contained. - Expanded Model Context Protocol (MCP) documentation detailing real-world autonomous AI workflows and execution safety.
v2.0.0
Added
-
Support for Spatie Laravel Query Builder (
spatie/laravel-query-builder):- Statically analyzes
QueryBuilder::for(...)method chains on GET operations to generate OpenAPI query parameters without booting the application. - Generates
filter[field]query parameters with database column types automatically resolved from migration schemas; supportsAllowedFilter::exact,partial,scope,beginsWithStrict,endsWithStrict, andtrashed(with enum['with', 'only']). - Generates a unified
sortparameter with expanded ascending and descending enums and default sort values fromallowedSortsanddefaultSort. - Generates
includeparameter forallowedIncludes,fields[resource]parameters forallowedFields, andappendparameter forallowedAppends. - Emits non-fatal
InferenceDiagnosticentries for dynamic or non-literal arguments while gracefully parsing remaining parameters.
- Statically analyzes
-
Support for Spatie Laravel Data (
spatie/laravel-data):- Statically infers request body schemas from controller action parameters type-hinting classes extending
Spatie\LaravelData\Data. - Statically infers response schemas from return expressions returning
DataClass::from(...),DataClass::collect(...),new DataClass(...), or declaring aDataClassreturn type-hint. - Recursively resolves nested Data classes and collection types with proper component schema referencing (
$ref). - Statically maps Spatie validation attributes (
#[Required],#[Min],#[Max],#[Email],#[Url],#[Regex], etc.) to JSON Schema constraints. - Supports
Optionaland nullable properties by omitting them from therequiredschema array.
- Statically infers request body schemas from controller action parameters type-hinting classes extending
-
Support for Laravel Actions (
lorisleiva/laravel-actions):- Automatic detection and routing resolution for single-action route definitions (
Route::get('/path', SomeAction::class)), prioritizingasController()overhandle(). - Static validation rules extraction from Action
rules()method andActionRequestparameters into the OpenAPI request body schema. - Automatic
403 Forbiddenresponse documentation when an Action defines a non-trivialauthorize()method. - Human-readable operation summary derivation from Action class names (e.g.
CreateUserAction-> "Create user") when no explicit summary annotation is present.
- Automatic detection and routing resolution for single-action route definitions (
Changed (BREAKING)
- Permanent sidebar promo banner: The sidebar promo card is no longer configurable and cannot be disabled or customized. It is now a permanent advertisement banner linking to
masitings/geni-apirendered unconditionally in every documentation portal instance. Theconfig('geni.promo')configuration block has been removed fromconfig/geni.php. Any host applications specifyingconfig('geni.promo.*')will have those settings silently ignored. This breaking change requires a major version bump.
v1.0.1
Fixed
geni:export/geni:check--pathresolution: both commands always ran the given path throughbase_path()even when it was already absolute, silently doubling/mangling the destination (e.g. writing intovendor/orchestra/testbench-core/laravel/...when run under Testbench instead of the intended path). Now mirrorsgeni:mcp's existing guard: an absolute path (or one that already exists) is used as-is.InferenceDiagnosticembedded absolute filesystem paths (e.g. a developer's home directory) into the OpenAPI document'sx-geni-unresolvedextension. Since these paths are baked into the generated document, a spec produced on one machine would never match the same spec regenerated on another (including CI), makinggeni:checkreport false drift for content that hadn't actually changed. Diagnostic file paths are now relativized against the current working directory before being serialized.geni:checkcompared the generated and committed OpenAPI documents with strict===on decoded PHP arrays, which is order-sensitive for JSON objects. Comparison now recursively sorts object keys (canonicalizes) before comparing while preserving list-array order, which is semantically significant, so key-emission order alone can no longer produce a false positive.
v1.0.0
Added
- Multi-document routing and interactive API version switcher dropdown in Blade docs UI:
GeniServiceProviderregisters dedicated versioned routes for each entry inconfig('geni.apis')(e.g./docs/api/v1,/docs/api/v1.json,/docs/api/v1/mcp).RouteDiscoverer::discover($apiName)andBuildsInfoOptions::buildInfoOptions($apiName)scope discovery and OpenAPI metadata per named version.blade-docs.blade.phprenders an interactive version switcher dropdown in the sidebar header when> 1APIs are configured, switching specifications in-place and updating browser history viahistory.pushState().- Single-document setups (
config('geni.apis') => []) retain standard zero-overhead behavior without dropdowns (100% backward compatible).
- Optional sidebar promo card (
config('geni.promo')): disabled by default, lets a host app render a small branded banner (icon, title, subtitle, link) in the docs sidebar. Content-neutral — no branding shipped in the package itself.
Fixed
- Mobile nav drawer and mobile "Try It" slide-over were missing several desktop-only sidebar features (API version switcher, endpoint search, promo card, footer credit, and full auth/param/body request form) — both surfaces now share the same partials as desktop so mobile has full parity.
- Response body and response example panels now use a fixed dark background instead of one that blended into their dark-mode container.
- Response status badges and the version switcher dropdown no longer overflow on narrow screens or with many entries.
- DocsFormAuth middleware now returns 401 JSON (instead of an HTML redirect) for unauthenticated requests to versioned API JSON spec paths (
docs/api/{name}.json) configured viageni.apis. - Version switcher dropdown now displays the configured
titleas-is instead of appending a(v{version})suffix.