Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Openapi Bundle

Openapi Bundle Laravel Package

nijens/openapi-bundle

A Symfony bundle for generating OpenAPI documentation from your API using annotations or attributes, with configurable spec generation and Swagger UI integration to help you document and explore endpoints quickly.

View on GitHub
Deep Wiki
Context7

Helps you create a REST API from your OpenAPI specification.

Frequently asked questions about Openapi Bundle
Is nijens/openapi-bundle a Laravel package?
No. nijens/openapi-bundle is a Symfony bundle, not a Laravel package, and its configuration and request lifecycle hooks follow Symfony conventions. There is no Laravel adapter in the release notes, and bridging Symfony's Request into Laravel's middleware and FormRequest validation pipeline is not a small task. For Laravel APIs, prefer Laravel-native documentation tooling and consume the OpenAPI contract rather than installing this bundle.
How do I install and configure nijens/openapi-bundle in a Symfony application?
Install it with Composer using composer require nijens/openapi-bundle, then enable the bundle in your Symfony bundle configuration and point it at your OpenAPI spec or documentation settings. The bundle integrates through Symfony's bundle and configuration system and serves the generated specification endpoint. For the 3.1.0 upgrade, run composer update and execute regression tests against existing endpoints.
Which PHP and Symfony versions does nijens/openapi-bundle 3.1.0 support?
The 3.1.0 release notes do not state the supported PHP and Symfony version ranges, and Symfony 7.x coverage is not confirmed there. Check the package's composer.json constraints and published CI matrix before planning an upgrade. Treat the compatibility matrix as an open item until verified.
How does nijens/openapi-bundle generate OpenAPI documentation?
It uses a code-first workflow: you describe API endpoints with annotations or attributes, and the bundle builds a machine-readable OpenAPI 3 specification close to your code. It serves that specification through an endpoint and keeps API docs versioned alongside the application. The resulting spec works with standard OpenAPI tooling and client generators.
What changed in nijens/openapi-bundle 3.1.0?
Version 3.1.0 is an additive minor release from 3.0.3. It adds header parameter validation and parameter deserialization into typed deserialization objects for path, query, and header parameters. There are no removals or deprecations noted, so the upgrade is low risk with endpoint regression tests.
Is header validation in nijens/openapi-bundle risky in production?
Yes, header validation is the highest operational risk in 3.1.0. Enterprise traffic often carries Content-Type, Accept, Authorization, X-Forwarded-* and tracing headers that specs may declare too strictly or that proxies mutate. Enforcing header validation on day one can cause 4xx storms that look like client bugs, so roll it out gradually and monitor failures.
How does parameter deserialization into objects work in nijens/openapi-bundle?
The 3.1.0 feature hydrates path, query, and header parameters into typed objects instead of passing scalars. Adoption is opt-in per parameter, so existing controllers can keep their signatures while you migrate incrementally. Watch for type coercion, missing fields, nested objects, and oneOf/anyOf or nullable enum handling, because failures may surface as 500s unless error handling is configured.
Where does nijens/openapi-bundle load the OpenAPI spec from, and is it cached?
The release notes do not specify whether the spec comes from a local file, a remote URL, or multiple specs, or whether it is parsed once and cached versus per request. Confirm this in the bundle configuration and source before relying on it in production. Caching behaviour matters for latency and for how quickly spec changes take effect.
What is the failure contract when nijens/openapi-bundle rejects a request?
The notes do not pin down the exception type, HTTP status, or error body format, including whether it follows RFC 7807. Ask whether the failure response is overridable so it matches your API's existing error contract. Also confirm whether validation covers request bodies and responses, which affects contract testing.
What are alternatives to nijens/openapi-bundle, and is it actively maintained?
For Symfony, NelmioApiDocBundle is the common alternative; for Laravel, look at Scramble or Scribe and leave this bundle to Symfony services. nijens/openapi-bundle is effectively single-maintainer, so plan a fork contingency even though the blast radius for a validation library is contained. Confirm supported versions, CI coverage, and maintenance activity before adopting it.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
3mdikram/worldmoneywords
snowsoft/config
itmosoft/laravel-subscriptions
larva/laravel-ai-qwen
diephp/sequences
users-au/socialite-provider
twidpay/twid-logger
mrnewport/laravel-plaid
mrnewport/laravel-repo
mrnewport/laravel-docsign
mrnewport/laravel-stow
mrnewport/laravel-flow
mrnewport/laravel-priceable
mrnewport/laravel-nestedterms
fredmeng/laravel-apidoc-generator
itstructure/laravel-multilingual-tools
pdustdar/elasticsearch
markupai/php-sdk
rlacerda83/lumem-microservice-shipment
uni-method/symfony-lib