Skip to content

Commit f9e6e3e

Browse files
committed
Min
1 parent 6abe84f commit f9e6e3e

File tree

3 files changed

+35
-50
lines changed

3 files changed

+35
-50
lines changed

composer.json

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "byjg/rest-reference-architecture",
3-
"description": "ByJG's Reference Architecture project for RESTFul services in PHP{ with docker and database integrated",
3+
"description": "ByJG's Reference Architecture project for RESTFul services in PHP with docker and database integrated",
44
"minimum-stability": "dev",
55
"prefer-stable": true,
66
"license": "MIT",
@@ -9,18 +9,18 @@
99
"ext-json": "*",
1010
"ext-openssl": "*",
1111
"ext-curl": "*",
12-
"byjg/config": "4.9.x-dev",
13-
"byjg/anydataset-db": "4.9.x-dev",
14-
"byjg/micro-orm": "4.9.x-dev",
15-
"byjg/authuser": "4.9.x-dev",
16-
"byjg/mailwrapper": "4.9.*",
17-
"byjg/restserver": "4.9.x-dev",
12+
"byjg/config": "^4.9",
13+
"byjg/anydataset-db": "^4.9",
14+
"byjg/micro-orm": "^4.9",
15+
"byjg/authuser": "^4.9",
16+
"byjg/mailwrapper": "^4.9",
17+
"byjg/restserver": "^4.9",
1818
"zircote/swagger-php": "^4.6.1",
19-
"byjg/swagger-test": "4.9.*",
20-
"byjg/migration": "4.9.x-dev",
21-
"byjg/php-daemonize": "4.9.*",
22-
"byjg/shortid": "4.9.*",
23-
"byjg/jinja-php": "4.9.*"
19+
"byjg/swagger-test": "^4.9",
20+
"byjg/migration": "^4.9",
21+
"byjg/php-daemonize": "^4.9",
22+
"byjg/shortid": "^4.9",
23+
"byjg/jinja-php": "^4.9"
2424
},
2525
"require-dev": {
2626
"phpunit/phpunit": "5.7.*|7.4.*|^9.5"

public/docs/openapi.json

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,6 @@
1212
},
1313
"version": "1.0.0"
1414
},
15-
"servers": [
16-
{
17-
"url": "http://localhost:8080",
18-
"description": "Local Development server"
19-
}
20-
],
2115
"paths": {
2216
"/dummyhex/{id}": {
2317
"get": {
@@ -960,8 +954,7 @@
960954
"admin": {
961955
"type": "string",
962956
"format": "string"
963-
},
964-
"uuid": {}
957+
}
965958
},
966959
"type": "object",
967960
"xml": {

src/OpenApiSpec.php

Lines changed: 22 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -4,48 +4,40 @@
44
use OpenApi\Attributes as OA;
55

66
#[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/',
2111
)]
12+
#[OA\Contact(email: 'someone@example.com')]
13+
#[OA\License(name: 'Proprietary')]
2214
#[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'
2517
)]
2618
#[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'
3123
)]
3224
#[OA\Schema(
33-
schema: "error",
34-
required: ["error"],
25+
schema: 'error',
26+
required: ['error'],
3527
properties: [
3628
new OA\Property(
37-
property: "error",
38-
required: ["type", "message", "file", "line"],
29+
property: 'error',
30+
required: ['type', 'message', 'file', 'line'],
3931
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')
4436
],
45-
type: "object"
37+
type: 'object'
4638
)
4739
],
48-
type: "object"
40+
type: 'object'
4941
)]
5042
class OpenApiSpec
5143
{

0 commit comments

Comments
 (0)