3232import java .util .stream .Stream ;
3333
3434
35+ @ SpringBootApplication
36+ public class CodeFirstApplication {
37+ public static void main (String [] args ) {
38+ SpringApplication .run (CodeFirstApplication .class , args );
39+ }
40+ }
41+
3542@ RequestMapping ("/api/todos" )
3643@ Tag (name = "Todo API" , description = "euismod in pellentesque massa placerat duis ultricies lacus sed turpis" )
3744@ SecurityRequirement (name = "api" )
@@ -67,13 +74,6 @@ interface UnsecuredApi {
6774 String unsecured ();
6875}
6976
70- @ SpringBootApplication
71- public class CodeFirstApplication {
72- public static void main (String [] args ) {
73- SpringApplication .run (CodeFirstApplication .class , args );
74- }
75- }
76-
7777@ OpenAPIDefinition (
7878 info = @ Info (
7979 title = "Code-First Approach (reflectoring.io)" ,
@@ -85,7 +85,7 @@ public static void main(String[] args) {
8585 license = @ License (name = "MIT Licence" , url = "https://github.com/thombergs/code-examples/blob/master/LICENSE" )),
8686 servers = @ Server (url = "http://localhost:8080" )
8787)
88- @ SecurityScheme (scheme = "basic" , type = SecuritySchemeType .HTTP , name = "api" , in = SecuritySchemeIn .HEADER )
88+ @ SecurityScheme (name = "api" , scheme = "basic" , type = SecuritySchemeType .HTTP , in = SecuritySchemeIn .HEADER )
8989class OpenAPIConfiguration {
9090}
9191
0 commit comments