alt3 / cakephp-swagger

Swagger plugin for documenting your CakePHP APIs
MIT License
64 stars 17 forks source link

Add swagger-php generated basePath #6

Closed bravo-kernel closed 8 years ago

bravo-kernel commented 8 years ago

DocsController should generate the three fields used by Swagger-UI to generate and show the Base Url:

        basePath="/v0",
        host="your.api.local",
        schemes={"http", "https"},

NEVER specify these fields in the source code annotations as this will break deploying your app to environments using no/different basePath.

Update: Only schemes should be configurable, basePath and host can be fetched realtime.

More information: