-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathInfo.php
More file actions
139 lines (124 loc) · 4.27 KB
/
Info.php
File metadata and controls
139 lines (124 loc) · 4.27 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
<?php
namespace Zerotoprod\DataModelOpenapi30;
use Zerotoprod\DataModel\Describe;
use Zerotoprod\DataModelOpenapi30\Helpers\DataModel;
/**
* The object provides metadata about the API. The metadata _MAY_
* be used by the clients if needed, and _MAY_ be presented in
* editing or documentation generation tools for convenience.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#info-object
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
class Info
{
use DataModel;
/**
* The title of the API.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @see $title
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
public const title = 'title';
/**
* The title of the API.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
#[Describe(['required'])]
public string $title;
/**
* A description of the API.
*
* [CommonMark] syntax _MAY_ be used for rich text representation.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @see https://spec.commonmark.org/
* @see $description
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
public const description = 'description';
/**
* A description of the API.
*
* [CommonMark] syntax _MAY_ be used for rich text representation.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @see https://spec.commonmark.org
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
#[Describe(['nullable' => true])]
public ?string $description;
/**
* A URL for the Terms of Service for the API.
* This _MUST_ be in the form of a URL.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @see $termsOfService
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
public const termsOfService = 'termsOfService';
/**
* A URL for the Terms of Service for the API.
* This _MUST_ be in the form of a URL.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
#[Describe(['nullable'])]
public ?string $termsOfService;
/**
* **REQUIRED**. The version of the OpenAPI Document (which is distinct from the
* OpenAPI Specification version or the version of the API being described
* or the version of the OpenAPI Description).
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @see $version
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
public const version = 'version';
/**
* **REQUIRED**. The version of the OpenAPI Document (which is distinct from the
* OpenAPI Specification version or the version of the API being described
* or the version of the OpenAPI Description).
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
#[Describe(['required'])]
public string $version;
/**
* The contact information for the exposed API.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @see $contact
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
public const contact = 'contact';
/**
* The contact information for the exposed API.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
#[Describe(['nullable'])]
public ?Contact $contact;
/**
* The license information for the exposed API.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @see $licence
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
public const licence = 'licence';
/**
* The license information for the exposed API.
*
* @see https://spec.openapis.org/oas/v3.0.4.html#fixed-fields-0
* @link https://github.com/zero-to-prod/data-model-openapi30
*/
#[Describe(['nullable'])]
public ?License $license;
}