Generates documentation for your REST API from annotations
Find a file
Mantis Development b3c53beead
Add dump command to print out swagger JSON. (#1537) (#1540)
* Add dump command to print out swagger JSON.

Command outputs to stdout, so can be redirected to a file.
Pretty prints output by default.
--no-pretty can be passed to remove whitespace from json output if it does not need to be human readable

* Update for styleci corrections

* Fix CS and add type hint

* REbase + Updates to documentation of dump command.

* Remove defaultName - config file specifies this
Add return value to dump command

* Update for OA3

* Add a test case

* update command name

* Fix the tests

Co-authored-by: Guilhem Niot <egetick@gmail.com>
Co-authored-by: Guilhem Niot <guilhem.niot@gmail.com>
2020-05-31 11:39:50 +02:00
Annotation OpenApi 3 Support (#1623) 2020-05-28 13:19:11 +02:00
Command Add dump command to print out swagger JSON. (#1537) (#1540) 2020-05-31 11:39:50 +02:00
Controller OpenApi 3 Support (#1623) 2020-05-28 13:19:11 +02:00
DependencyInjection Fix #1628 : annotations construction is context dependant (#1632) 2020-05-29 21:52:06 +02:00
Describer Fix #1628 : annotations construction is context dependant (#1632) 2020-05-29 21:52:06 +02:00
Form/Extension Allow Symfony 5 2019-11-29 13:59:27 +01:00
Model OpenApi 3 Support (#1623) 2020-05-28 13:19:11 +02:00
ModelDescriber Fix User Warning: Multiple definitions for @OA\\Property()->title (#1630) 2020-05-31 10:30:13 +02:00
OpenApiPhp Fix undefined property $this->mediaType (#1633) 2020-05-29 18:53:58 +02:00
PropertyDescriber Fix undefined function in OA\Schema (#1629) 2020-05-28 19:19:43 +02:00
Resources Add dump command to print out swagger JSON. (#1537) (#1540) 2020-05-31 11:39:50 +02:00
RouteDescriber Fix access to api->components in RouteMetadataDescriber (#1635) 2020-05-30 18:24:51 +02:00
Routing Added name_patterns filter option (#1504) 2019-04-16 17:22:50 +02:00
Tests Add dump command to print out swagger JSON. (#1537) (#1540) 2020-05-31 11:39:50 +02:00
Util Merge pull request #1556 from maxhelias/reflection-method 2019-11-21 18:18:16 +01:00
.gitignore Fix build travis 2019-11-20 12:15:00 +01:00
.php_cs.dist Fix build travis 2019-11-20 12:15:00 +01:00
.styleci.yml Add areas support (#1169) 2018-01-05 13:08:02 +01:00
.travis.yml OpenApi 3 Support (#1623) 2020-05-28 13:19:11 +02:00
ApiDocGenerator.php OpenApi 3 Support (#1623) 2020-05-28 13:19:11 +02:00
CHANGELOG.md Merge branch 'v3' 2020-05-30 18:23:49 +02:00
composer.json Update dev version 2020-05-31 11:35:13 +02:00
CONTRIBUTING.md Added name_patterns filter option (#1504) 2019-04-16 17:22:50 +02:00
LICENSE Change the vendor to "Nelmio" 2016-12-29 12:09:26 +01:00
NelmioApiDocBundle.php Add areas support (#1169) 2018-01-05 13:08:02 +01:00
phpunit Update PHPUnit to 6.5 and allow newer version of PHPUnit Bridge 2018-05-28 13:58:42 +02:00
phpunit.xml.dist Allow Symfony 5 2019-11-29 13:59:27 +01:00
README.md OpenApi 3 Support (#1623) 2020-05-28 13:19:11 +02:00
update-js.sh Include map files 2017-06-22 21:22:10 +02:00
UPGRADE-3.0.md Add exceptions in the upgrading command to warn about the requirement to run it on 2.x (#1501) 2019-04-11 20:54:16 +02:00
UPGRADE-4.0.md OpenApi 3 Support (#1623) 2020-05-28 13:19:11 +02:00

NelmioApiDocBundle

Build
Status Total Downloads Latest Stable
Version

The NelmioApiDocBundle bundle allows you to generate a decent documentation for your APIs.

Migrate from 3.x to 4.0

To migrate from 3.x to 4.0, follow our guide.

Version 4.0 brings OpenAPI 3.0 support. If you want to stick to Swagger 2.0, you should use the version 3 of this bundle.

Migrate from 2.x to 3.0

To migrate from 2.x to 3.0, follow our guide.

Installation

Open a command console, enter your project directory and execute the following command to download the latest version of this bundle:

composer require nelmio/api-doc-bundle

Documentation

Read the documentation on symfony.com

Contributing

See CONTRIBUTING file.

Running the Tests

Install the Composer dependencies:

git clone https://github.com/nelmio/NelmioApiDocBundle.git
cd NelmioApiDocBundle
composer update

Then run the test suite:

./phpunit

License

This bundle is released under the MIT license.