Best laravel framework open-source packages.

Laravel OpenAPI Swagger Documentation Example

Laravel documentation example with OpenAPI (ex. Swagger)
Updated 2 months ago

Laravel API Documentation with OpenAPI

This is a repository for the tutorial: Laravel API Documentation with OpenAPI/Swagger

Base API structure and adminpanel was created with our Laravel generator QuickAdminPanel.


Screenshots

Laravel OpenAPI 01

Laravel OpenAPI 02


How to use

  • Clone the repository with git clone
  • Copy .env.example file to .env and edit database credentials there
  • Run composer install
  • Run php artisan key:generate
  • Run php artisan migrate --seed (it has some seeded data for your testing)
  • That's it: launch the URL /api/documentation
  • Follow the tutorial and regenerate documentation with php artisan l5-swagger:generate command
  • You can login to adminpanel by going go /login URL and login with credentials admin@admin.com - password

License

Basically, feel free to use and re-use any way you want.


More from our LaravelDaily Team