9572222ae2aedc74b3fa15d2c7883cccb291e809
[netconf.git] / restconf / restconf-openapi / src / test / resources / yang-document / controller-string-from-regex.json
1 {
2   "openapi": "3.0.3",
3   "info": {
4     "version": "1.0.0",
5     "title": "strings-from-regex",
6     "description": "We are providing full API for configurational data which can be edited (by POST, PUT, PATCH and DELETE).\nFor operational data we only provide GET API.\n\nFor majority of request you can see only config data in examples. That’s because we can show only one example\nper request. The exception when you can see operational data in example is when data are representing\noperational (config false) container with no config data in it."
7   },
8   "servers": [
9     {
10       "url": "http://localhost:8181/"
11     }
12   ],
13   "paths": {
14     "/rests/data": {
15       "post": {
16         "tags": [
17           "Controller strings-from-regex"
18         ],
19         "parameters": [],
20         "requestBody": {
21           "description": "test",
22           "content": {
23             "application/json": {
24               "schema": {
25                 "properties": {
26                   "test": {
27                     "$ref": "#/components/schemas/strings-from-regex_test",
28                     "type": "object"
29                   }
30                 }
31               }
32             },
33             "application/xml": {
34               "schema": {
35                 "$ref": "#/components/schemas/strings-from-regex_test"
36               }
37             }
38           }
39         },
40         "responses": {
41           "201": {
42             "description": "Created"
43           }
44         },
45         "description": "\n\nNote:\nIn example payload, you can see only the first data node child of the resource to be created, following the\nguidelines of RFC 8040, which allows us to create only one resource in POST request.\n",
46         "summary": "POST - Controller - strings-from-regex - strings-from-regex"
47       }
48     },
49     "/rests/data/strings-from-regex:test": {
50       "get": {
51         "tags": [
52           "Controller strings-from-regex"
53         ],
54         "parameters": [
55           {
56             "name": "content",
57             "in": "query",
58             "required": false,
59             "schema": {
60               "enum": [
61                 "config",
62                 "nonconfig",
63                 "all"
64               ],
65               "type": "string"
66             }
67           }
68         ],
69         "responses": {
70           "200": {
71             "description": "200",
72             "content": {
73               "application/json": {
74                 "schema": {
75                   "properties": {
76                     "test": {
77                       "$ref": "#/components/schemas/strings-from-regex_test",
78                       "type": "object"
79                     }
80                   }
81                 }
82               },
83               "application/xml": {
84                 "schema": {
85                   "$ref": "#/components/schemas/strings-from-regex_test"
86                 }
87               }
88             }
89           }
90         },
91         "description": "",
92         "summary": "GET - Controller - strings-from-regex - test"
93       },
94       "put": {
95         "tags": [
96           "Controller strings-from-regex"
97         ],
98         "parameters": [],
99         "requestBody": {
100           "description": "test",
101           "content": {
102             "application/json": {
103               "schema": {
104                 "properties": {
105                   "strings-from-regex:test": {
106                     "$ref": "#/components/schemas/strings-from-regex_test",
107                     "type": "object"
108                   }
109                 }
110               }
111             },
112             "application/xml": {
113               "schema": {
114                 "$ref": "#/components/schemas/strings-from-regex_test"
115               }
116             }
117           }
118         },
119         "responses": {
120           "204": {
121             "description": "Updated"
122           },
123           "201": {
124             "description": "Created"
125           }
126         },
127         "description": "",
128         "summary": "PUT - strings-from-regex - Controller - test"
129       },
130       "delete": {
131         "tags": [
132           "Controller strings-from-regex"
133         ],
134         "parameters": [],
135         "responses": {
136           "204": {
137             "description": "Deleted"
138           }
139         },
140         "description": "",
141         "summary": "DELETE - Controller - strings-from-regex - test"
142       },
143       "patch": {
144         "tags": [
145           "Controller strings-from-regex"
146         ],
147         "parameters": [],
148         "requestBody": {
149           "description": "test",
150           "content": {
151             "application/yang-data+xml": {
152               "schema": {
153                 "$ref": "#/components/schemas/strings-from-regex_test"
154               }
155             },
156             "application/yang-data+json": {
157               "schema": {
158                 "properties": {
159                   "strings-from-regex:test": {
160                     "$ref": "#/components/schemas/strings-from-regex_test",
161                     "type": "object"
162                   }
163                 }
164               }
165             }
166           }
167         },
168         "responses": {
169           "200": {
170             "description": "OK"
171           },
172           "204": {
173             "description": "Updated"
174           }
175         },
176         "description": "",
177         "summary": "PATCH - strings-from-regex - Controller - test"
178       }
179     }
180   },
181   "components": {
182     "schemas": {
183       "strings-from-regex_test": {
184         "properties": {
185           "login-date-time": {
186             "description": "",
187             "type": "string",
188             "example": "0000-00-00T00:00:00Z",
189             "minLength": 0,
190             "maxLength": 2147483647
191           },
192           "mac-address": {
193             "description": "",
194             "type": "string",
195             "example": "00:00:00:00:00:00",
196             "minLength": 0,
197             "maxLength": 2147483647
198           },
199           "ipv4-address": {
200             "description": "",
201             "type": "string",
202             "example": "0.0.0.0",
203             "minLength": 0,
204             "maxLength": 2147483647
205           }
206         },
207         "xml": {
208           "name": "test",
209           "namespace": "urn:ietf:params:xml:ns:yang:strings:regex"
210         },
211         "description": "",
212         "title": "strings-from-regex_test",
213         "type": "object"
214       }
215     },
216     "securitySchemes": {
217       "basicAuth": {
218         "scheme": "basic",
219         "type": "http"
220       }
221     }
222   },
223   "security": [
224     {
225       "basicAuth": []
226     }
227   ]
228 }