PHP code example of kbrabrand / silex-swagger-ui

1. Go to this page and download the library: Download kbrabrand/silex-swagger-ui library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

kbrabrand / silex-swagger-ui example snippets


// Set up swagger ui service for viewing the swagger docs
$app->register(new SwaggerUI\Silex\Provider\SwaggerUIServiceProvider(), array(
    'swaggerui.path'       => '/v1/swagger',
    'swaggerui.apiDocPath' => '/v1/docs'
));