|
4 | 4 | use OpenApi\Attributes as OA;
|
5 | 5 |
|
6 | 6 | #[OA\Info(
|
7 |
| - version: "1.0.0", |
8 |
| - description: "Information about the API", |
9 |
| - title: "API Title", |
10 |
| - termsOfService: "http://localhost:8080/terms/", |
11 |
| - contact: new OA\Contact( |
12 |
| - email: "someone@example.com" |
13 |
| - ), |
14 |
| - license: new OA\License( |
15 |
| - name: "Proprietary" |
16 |
| - ) |
17 |
| -)] |
18 |
| -#[OA\Server( |
19 |
| - url: "http://localhost:8080", |
20 |
| - description: "Local Development server" |
| 7 | + version: '1.0.0', |
| 8 | + description: 'Information about the API', |
| 9 | + title: 'API Title', |
| 10 | + termsOfService: 'http://localhost:8080/terms/', |
21 | 11 | )]
|
| 12 | +#[OA\Contact(email: 'someone@example.com')] |
| 13 | +#[OA\License(name: 'Proprietary')] |
22 | 14 | #[OA\ExternalDocumentation(
|
23 |
| - description: "Find out more about Swagger", |
24 |
| - url: "http://localhost:8080/docs" |
| 15 | + description: 'Find out more about Swagger', |
| 16 | + url: 'http://localhost:8080/docs' |
25 | 17 | )]
|
26 | 18 | #[OA\SecurityScheme(
|
27 |
| - securityScheme: "jwt-token", |
28 |
| - type: "apiKey", |
29 |
| - name: "Authorization", |
30 |
| - in: "header" |
| 19 | + securityScheme: 'jwt-token', |
| 20 | + type: 'apiKey', |
| 21 | + name: 'Authorization', |
| 22 | + in: 'header' |
31 | 23 | )]
|
32 | 24 | #[OA\Schema(
|
33 |
| - schema: "error", |
34 |
| - required: ["error"], |
| 25 | + schema: 'error', |
| 26 | + required: ['error'], |
35 | 27 | properties: [
|
36 | 28 | new OA\Property(
|
37 |
| - property: "error", |
38 |
| - required: ["type", "message", "file", "line"], |
| 29 | + property: 'error', |
| 30 | + required: ['type', 'message', 'file', 'line'], |
39 | 31 | properties: [
|
40 |
| - new OA\Property(property: "type", description: "A class de Exceção", type: "string"), |
41 |
| - new OA\Property(property: "message", description: "A mensagem de erro", type: "string"), |
42 |
| - new OA\Property(property: "file", description: "O arquivo que gerou o erro", type: "string"), |
43 |
| - new OA\Property(property: "line", description: "A linha do erro", type: "integer") |
| 32 | + new OA\Property(property: 'type', description: 'A class de Exceção', type: 'string'), |
| 33 | + new OA\Property(property: 'message', description: 'A mensagem de erro', type: 'string'), |
| 34 | + new OA\Property(property: 'file', description: 'O arquivo que gerou o erro', type: 'string'), |
| 35 | + new OA\Property(property: 'line', description: 'A linha do erro', type: 'integer') |
44 | 36 | ],
|
45 |
| - type: "object" |
| 37 | + type: 'object' |
46 | 38 | )
|
47 | 39 | ],
|
48 |
| - type: "object" |
| 40 | + type: 'object' |
49 | 41 | )]
|
50 | 42 | class OpenApiSpec
|
51 | 43 | {
|
|
0 commit comments