xxxxxxxxxx
composer require "darkaonline/l5-swagger"
xxxxxxxxxx
php artisan vendor:publish --provider "L5Swagger\L5SwaggerServiceProvider"
xxxxxxxxxx
// Helpful environment variables
L5_SWAGGER_GENERATE_ALWAYS=true
L5_SWAGGER_CONST_HOST=https://example.com
xxxxxxxxxx
// Full Example
/**
* @OA\Get(
* path="/projects",
* operationId="getProjectsList",
* tags={"Projects"},
* summary="Get list of projects",
* description="Returns list of projects",
* @OA\Response(
* response=200,
* description="Successful operation",
* @OA\JsonContent(ref="#/components/schemas/ProjectResource")
* ),
* @OA\Response(
* response=401,
* description="Unauthenticated",
* ),
* @OA\Response(
* response=403,
* description="Forbidden"
* )
* )
*/