|
11 | 11 | 'routes' => [
|
12 | 12 | /*
|
13 | 13 | * Route for accessing api documentation interface
|
14 |
| - */ |
| 14 | + */ |
15 | 15 | 'api' => 'api/documentation',
|
16 | 16 | ],
|
17 | 17 | 'paths' => [
|
18 | 18 | /*
|
19 | 19 | * Edit to include full URL in ui for assets
|
20 |
| - */ |
| 20 | + */ |
21 | 21 | 'use_absolute_path' => env('L5_SWAGGER_USE_ABSOLUTE_PATH', true),
|
22 | 22 |
|
23 | 23 | /*
|
24 | 24 | * File name of the generated json documentation file
|
25 |
| - */ |
| 25 | + */ |
26 | 26 | 'docs_json' => 'api-docs.json',
|
27 | 27 |
|
28 | 28 | /*
|
29 | 29 | * File name of the generated YAML documentation file
|
30 |
| - */ |
| 30 | + */ |
31 | 31 | 'docs_yaml' => 'api-docs.yaml',
|
32 | 32 |
|
33 | 33 | /*
|
34 |
| - * Set this to `json` or `yaml` to determine which documentation file to use in UI |
35 |
| - */ |
| 34 | + * Set this to `json` or `yaml` to determine which documentation file to use in UI |
| 35 | + */ |
36 | 36 | 'format_to_use_for_docs' => env('L5_FORMAT_TO_USE_FOR_DOCS', 'json'),
|
37 | 37 |
|
38 | 38 | /*
|
39 | 39 | * Absolute paths to directory containing the swagger annotations are stored.
|
40 |
| - */ |
| 40 | + */ |
41 | 41 | 'annotations' => [
|
42 | 42 | base_path('app'),
|
43 | 43 | ],
|
44 |
| - |
45 | 44 | ],
|
46 | 45 | ],
|
47 | 46 | ],
|
48 | 47 | 'defaults' => [
|
49 | 48 | 'routes' => [
|
50 | 49 | /*
|
51 | 50 | * Route for accessing parsed swagger annotations.
|
52 |
| - */ |
| 51 | + */ |
53 | 52 | 'docs' => 'docs',
|
54 | 53 |
|
55 | 54 | /*
|
56 | 55 | * Route for Oauth2 authentication callback.
|
57 |
| - */ |
| 56 | + */ |
58 | 57 | 'oauth2_callback' => 'api/oauth2-callback',
|
59 | 58 |
|
60 | 59 | /*
|
61 | 60 | * Middleware allows to prevent unexpected access to API documentation
|
62 |
| - */ |
| 61 | + */ |
63 | 62 | 'middleware' => [
|
64 | 63 | 'api' => [],
|
65 | 64 | 'asset' => [],
|
|
69 | 68 |
|
70 | 69 | /*
|
71 | 70 | * Route Group options
|
72 |
| - */ |
| 71 | + */ |
73 | 72 | 'group_options' => [],
|
74 | 73 | ],
|
75 | 74 |
|
76 | 75 | 'paths' => [
|
77 | 76 | /*
|
78 | 77 | * Absolute path to location where parsed annotations will be stored
|
79 |
| - */ |
| 78 | + */ |
80 | 79 | 'docs' => storage_path('api-docs'),
|
81 | 80 |
|
82 | 81 | /*
|
83 | 82 | * Absolute path to directory where to export views
|
84 |
| - */ |
| 83 | + */ |
85 | 84 | 'views' => base_path('resources/views/vendor/l5-swagger'),
|
86 | 85 |
|
87 | 86 | /*
|
88 | 87 | * Edit to set the api's base path
|
89 |
| - */ |
| 88 | + */ |
90 | 89 | 'base' => env('L5_SWAGGER_BASE_PATH', null),
|
91 | 90 |
|
92 | 91 | /*
|
93 | 92 | * Edit to set path where swagger ui assets should be stored
|
94 |
| - */ |
| 93 | + */ |
95 | 94 | 'swagger_ui_assets_path' => env('L5_SWAGGER_UI_ASSETS_PATH', 'vendor/swagger-api/swagger-ui/dist/'),
|
96 | 95 |
|
97 | 96 | /*
|
98 | 97 | * Absolute path to directories that should be excluded from scanning
|
99 | 98 | * @deprecated Please use `scanOptions.exclude`
|
100 | 99 | * `scanOptions.exclude` overwrites this
|
101 |
| - */ |
| 100 | + */ |
102 | 101 | 'excludes' => [],
|
103 | 102 | ],
|
104 | 103 |
|
|
138 | 137 | * Absolute path to directories that should be excluded from scanning
|
139 | 138 | * @note This option overwrites `paths.excludes`
|
140 | 139 | * @see \OpenApi\scan
|
141 |
| - */ |
| 140 | + */ |
142 | 141 | 'exclude' => [],
|
143 | 142 |
|
144 | 143 | /*
|
|
155 | 154 | 'securitySchemes' => [
|
156 | 155 | /*
|
157 | 156 | * Examples of Security schemes
|
158 |
| - */ |
| 157 | + */ |
159 | 158 | /*
|
160 | 159 | 'api_key_security_example' => [ // Unique name of security
|
161 | 160 | 'type' => 'apiKey', // The type of the security scheme. Valid values are "basic", "apiKey" or "oauth2".
|
|
202 | 201 | 'security' => [
|
203 | 202 | /*
|
204 | 203 | * Examples of Securities
|
205 |
| - */ |
| 204 | + */ |
206 | 205 | [
|
207 | 206 | /*
|
208 | 207 | 'oauth2_security_example' => [
|
|
219 | 218 | /*
|
220 | 219 | * Set this to `true` in development mode so that docs would be regenerated on each request
|
221 | 220 | * Set this to `false` to disable swagger generation on production
|
222 |
| - */ |
| 221 | + */ |
223 | 222 | 'generate_always' => env('L5_SWAGGER_GENERATE_ALWAYS', false),
|
224 | 223 |
|
225 | 224 | /*
|
226 | 225 | * Set this to `true` to generate a copy of documentation in yaml format
|
227 |
| - */ |
| 226 | + */ |
228 | 227 | 'generate_yaml_copy' => env('L5_SWAGGER_GENERATE_YAML_COPY', false),
|
229 | 228 |
|
230 | 229 | /*
|
231 | 230 | * Edit to trust the proxy's ip address - needed for AWS Load Balancer
|
232 | 231 | * string[]
|
233 |
| - */ |
| 232 | + */ |
234 | 233 | 'proxy' => false,
|
235 | 234 |
|
236 | 235 | /*
|
237 | 236 | * Configs plugin allows to fetch external configs instead of passing them to SwaggerUIBundle.
|
238 | 237 | * See more at: https://github.com/swagger-api/swagger-ui#configs-plugin
|
239 |
| - */ |
| 238 | + */ |
240 | 239 | 'additional_config_url' => null,
|
241 | 240 |
|
242 | 241 | /*
|
243 | 242 | * Apply a sort to the operation list of each API. It can be 'alpha' (sort by paths alphanumerically),
|
244 | 243 | * 'method' (sort by HTTP method).
|
245 | 244 | * Default is the order returned by the server unchanged.
|
246 |
| - */ |
| 245 | + */ |
247 | 246 | 'operations_sort' => env('L5_SWAGGER_OPERATIONS_SORT', null),
|
248 | 247 |
|
249 | 248 | /*
|
250 | 249 | * Pass the validatorUrl parameter to SwaggerUi init on the JS side.
|
251 | 250 | * A null value here disables validation.
|
252 |
| - */ |
| 251 | + */ |
253 | 252 | 'validator_url' => null,
|
254 | 253 |
|
255 | 254 | /*
|
256 | 255 | * Swagger UI configuration parameters
|
257 |
| - */ |
| 256 | + */ |
258 | 257 | 'ui' => [
|
259 | 258 | 'display' => [
|
260 | 259 | /*
|
|
284 | 283 |
|
285 | 284 | 'oauth2' => [
|
286 | 285 | /*
|
287 |
| - * If set to true, adds PKCE to AuthorizationCodeGrant flow |
288 |
| - */ |
| 286 | + * If set to true, adds PKCE to AuthorizationCodeGrant flow |
| 287 | + */ |
289 | 288 | 'use_pkce_with_authorization_code_grant' => false,
|
290 | 289 | ],
|
291 | 290 | ],
|
|
0 commit comments