-
-
Notifications
You must be signed in to change notification settings - Fork 413
Open
Description
- L5-Swagger Version: 8.5
- PHP Version 8.3
- OS: N.A.
Description:
OpenApi 3.x, swagger-php and swagger-ui support multiple servers / base URLs to be defined.
However, l5-swagger.php config file will not accept an array - or anything else for that matter - to have multiple servers end up in the servers array in the open-api-docs.json.
I've tried in l5-swagger.php:
/*
* Edit to set the api's base path
*/
'base' => env('L5_SWAGGER_BASE_PATH', [
['url' => env('API_URL')],
['url' => env('APP_URL')],
]),
/*
* Edit to set the api's base path
*/
'base' => env('L5_SWAGGER_BASE_PATH', [
env('API_URL'),
env('APP_URL'),
]),
Both do not result in the proper structure:
"servers": [
{
"url": [
"http://localhost/api",
"http://localhost"
]
}
],
"servers": [
{
"url": [
{
"url": "http://localhost/api"
},
{
"url": "http://localhost"
}
]
}
],
Could support for this be added? It is quite useful.
Or this there another way to hook into the open-api-docs.json generation to add it manually in the meantime?
Metadata
Metadata
Assignees
Labels
No labels
