refs #734 Adds nelmio api doc configuration

ticket-769
Luis Gerardo Romero Garcia 2024-09-13 18:07:26 +02:00
parent 0908888fce
commit 62bd4c1300
2 changed files with 21 additions and 0 deletions

View File

@ -0,0 +1,9 @@
nelmio_api_doc:
documentation:
info:
title: My App
description: This is an awesome app!
version: 1.0.0
areas: # to filter documented areas
path_patterns:
- ^/oggit # Accepts routes under /api except /api/doc

View File

@ -0,0 +1,12 @@
# Expose your documentation as JSON swagger compliant
app.swagger:
path: /api/doc.json
methods: GET
defaults: { _controller: nelmio_api_doc.controller.swagger }
## Requires the Asset component and the Twig bundle
## $ composer require twig asset
#app.swagger_ui:
# path: /api/doc
# methods: GET
# defaults: { _controller: nelmio_api_doc.controller.swagger_ui }