From b0c2abd5a7db06f41526cc745bdb88c913afa30d Mon Sep 17 00:00:00 2001 From: Romain 'Maz' BILLOIR Date: Sat, 31 Jan 2026 11:01:11 +0100 Subject: [PATCH] Update security.md with Swagger UI instructions Added instructions for using Swagger UI with API authentication. --- laravel/security.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/laravel/security.md b/laravel/security.md index 388252420fb..a29cae1734d 100644 --- a/laravel/security.md +++ b/laravel/security.md @@ -101,3 +101,22 @@ return [ ], ]; ``` + +If you plan to use Swagger UI to test your API through the browser, also uncomment the `swagger_ui.apiKeys` config to display the Authorization form in Swagger UI: +```php + [ + // .... + 'apiKeys' => [ + 'api' => [ + 'name' => 'Authorization', + 'type' => 'header', + ], + ], + ] +]; +``` +image