spatie/laravel-openapi-cli
Turn any OpenAPI spec into dedicated Laravel artisan commands with typed options for path params, query params, and request bodies. Add auth, caching, retries, and error handling, or pair with Laravel Zero to build standalone CLI tools.
A response body that could not be pretty-printed used to get a Response is not JSON (content-type: ..., status: ...) line, a blank line, a trailing newline, and a pass through Symfony's output formatter. All of that landed in the file when the output was redirected, so an endpoint returning a file could not be saved:
php artisan api:download-report > report.pdf # was corrupt, now valid
The body is now written raw: no notice, no added newline, no formatting. Any <...> sequence in binary data survives instead of being read as a style tag.
The one remaining notice is for an HTML body you have not asked to see, which prints no body at all. Its wording changed to HTML response (status: 500, content-length: 1234). Use --output-html to see it.
If you relied on the old notice appearing in output, that is the breaking bit; everything else is unchanged.
Full Changelog: https://github.com/spatie/laravel-openapi-cli/compare/1.4.0...1.4.1
AuthenticationException that auth() and retryOn() closures can throw to abort a command with a friendly message (and optional hint) before a request is sentFull Changelog: https://github.com/spatie/laravel-openapi-cli/compare/1.3.1...1.4.0
Full Changelog: https://github.com/spatie/laravel-openapi-cli/compare/1.3.0...1.3.1
retryOn() hook to re-issue a request after a >= 400 response (e.g. refresh an expired OAuth token on 401 and retry once)Full Changelog: https://github.com/spatie/laravel-openapi-cli/compare/1.2.0...1.3.0
Full Changelog: https://github.com/spatie/laravel-openapi-cli/compare/1.1.0...1.2.0
Full Changelog: https://github.com/spatie/laravel-openapi-cli/compare/1.0.2...1.1.0
Full Changelog: https://github.com/spatie/laravel-openapi-cli/compare/1.0.0...1.0.1
Full Changelog: https://github.com/spatie/laravel-openapi-cli/commits/0.0.1
How can I help you explore Laravel packages today?