@@ -20,26 +20,27 @@ Welcome to the generated API reference.
2020
2121<!-- END_INFO -->
2222
23- #general
23+ #Group A
2424<!-- START_264ee15c728df32e7ca6eedce5e42dcb -->
2525## Example title.
26-
26+
2727This will be the long description.
2828It can also be multiple lines long.
2929
3030> Example request:
3131
3232``` bash
3333curl -X GET -G " http://localhost/api/withDescription" \
34- -H " Accept: application/json" \
3534 -H " Authorization: customAuthToken" \
36- -H " Custom-Header: NotSoCustom"
35+ -H " Custom-Header: NotSoCustom"
3736```
3837
3938``` javascript
40- const url = new URL (" http://localhost/api/users " );
39+ const url = new URL (" http://localhost/api/withDescription " );
4140
4241let headers = {
42+ " Authorization" : " customAuthToken" ,
43+ " Custom-Header" : " NotSoCustom" ,
4344 " Accept" : " application/json" ,
4445 " Content-Type" : " application/json" ,
4546}
@@ -52,7 +53,8 @@ fetch(url, {
5253 .then (json => console .log (json));
5354```
5455
55- > Example response:
56+
57+ > Example response (200):
5658
5759``` json
5860null
6668
6769<!-- START_9cedd363be06f5512f9e844b100fcc9d -->
6870## api/withResponseTag
69-
7071> Example request:
7172
7273``` bash
7374curl -X GET -G " http://localhost/api/withResponseTag" \
74- -H " Accept: application/json" \
7575 -H " Authorization: customAuthToken" \
76- -H " Custom-Header: NotSoCustom"
76+ -H " Custom-Header: NotSoCustom"
7777```
7878
7979``` javascript
80- var settings = {
81- " async" : true ,
82- " crossDomain" : true ,
83- " url" : " http://localhost/api/withResponseTag" ,
84- " method" : " GET" ,
85- " headers" : {
86- " accept" : " application/json" ,
87- " Authorization" : " customAuthToken" ,
88- " Custom-Header" : " NotSoCustom" ,
89- }
80+ const url = new URL (" http://localhost/api/withResponseTag" );
81+
82+ let headers = {
83+ " Authorization" : " customAuthToken" ,
84+ " Custom-Header" : " NotSoCustom" ,
85+ " Accept" : " application/json" ,
86+ " Content-Type" : " application/json" ,
9087}
9188
92- $ .ajax (settings).done (function (response ) {
93- console .log (response);
94- });
89+ fetch (url, {
90+ method: " GET" ,
91+ headers: headers,
92+ })
93+ .then (response => response .json ())
94+ .then (json => console .log (json));
9595```
9696
97- > Example response:
97+
98+ > Example response (200):
9899
99100``` json
100101{
@@ -114,49 +115,61 @@ $.ajax(settings).done(function (response) {
114115
115116<!-- START_a25cb3b490fa579d7d77b386bbb7ec03 -->
116117## api/withBodyParameters
117-
118118> Example request:
119119
120120``` bash
121121curl -X GET -G " http://localhost/api/withBodyParameters" \
122- -H " Accept: application/json" \
123122 -H " Authorization: customAuthToken" \
124- -H " Custom-Header: NotSoCustom" \
125- -d " user_id" =20 \
126- -d " room_id" =6DZyNcBgezdjdAIs \
127- -d " forever" = \
128- -d " another_one" =2153.4 \
129- -d " yet_another_param" ={} \
130- -d " even_more_param" =[]
123+ -H " Custom-Header: NotSoCustom" \
124+ -H " Content-Type: application/json" \
125+ -d ' {"user_id":9,"room_id":"consequatur","forever":false,"another_one":11613.31890586,"yet_another_param":{},"even_more_param":[],"book":{"name":"consequatur","author_id":17,"pages_count":17},"ids":[17],"users":[{"first_name":"John","last_name":"Doe"}]}'
126+
131127```
132128
133129``` javascript
134- var settings = {
135- " async" : true ,
136- " crossDomain" : true ,
137- " url" : " http://localhost/api/withBodyParameters" ,
138- " method" : " GET" ,
139- " data" : {
140- " user_id" : 20 ,
141- " room_id" : " 6DZyNcBgezdjdAIs" ,
142- " forever" : false ,
143- " another_one" : 2153.4 ,
144- " yet_another_param" : " {}" ,
145- " even_more_param" : " []"
130+ const url = new URL (" http://localhost/api/withBodyParameters" );
131+
132+ let headers = {
133+ " Authorization" : " customAuthToken" ,
134+ " Custom-Header" : " NotSoCustom" ,
135+ " Content-Type" : " application/json" ,
136+ " Accept" : " application/json" ,
137+ }
138+
139+ let body = {
140+ " user_id" : 9 ,
141+ " room_id" : " consequatur" ,
142+ " forever" : false ,
143+ " another_one" : 11613.31890586 ,
144+ " yet_another_param" : {},
145+ " even_more_param" : [],
146+ " book" : {
147+ " name" : " consequatur" ,
148+ " author_id" : 17 ,
149+ " pages_count" : 17
146150 },
147- " headers" : {
148- " accept" : " application/json" ,
149- " Authorization" : " customAuthToken" ,
150- " Custom-Header" : " NotSoCustom" ,
151- }
151+ " ids" : [
152+ 17
153+ ],
154+ " users" : [
155+ {
156+ " first_name" : " John" ,
157+ " last_name" : " Doe"
158+ }
159+ ]
152160}
153161
154- $ .ajax (settings).done (function (response ) {
155- console .log (response);
156- });
162+ fetch (url, {
163+ method: " GET" ,
164+ headers: headers,
165+ body: body
166+ })
167+ .then (response => response .json ())
168+ .then (json => console .log (json));
157169```
158170
159- > Example response:
171+
172+ > Example response (200):
160173
161174``` json
162175null
165178### HTTP Request
166179` GET api/withBodyParameters `
167180
168- #### Parameters
181+ #### Body Parameters
169182
170183Parameter | Type | Status | Description
171184--------- | ------- | ------- | ------- | -----------
@@ -175,49 +188,46 @@ Parameter | Type | Status | Description
175188 another_one | number | optional | Just need something here.
176189 yet_another_param | object | required |
177190 even_more_param | array | optional |
191+ book.name | string | optional |
192+ book.author_id | integer | optional |
193+ book[ pages_count] | integer | optional |
194+ ids.* | integer | optional |
195+ users.* .first_name | string | optional | The first name of the user.
196+ users.* .last_name | string | optional | The last name of the user.
178197
179198<!-- END_a25cb3b490fa579d7d77b386bbb7ec03 -->
180199
181200<!-- START_5c08cc4d72b6e5830f6814c64086e197 -->
182201## api/withAuthTag
183- <small style="
184- padding: 1px 9px 2px;
185- font-weight: bold;
186- white-space: nowrap;
187- color: #ffffff;
188- -webkit-border-radius: 9px;
189- -moz-border-radius: 9px;
190- border-radius: 9px;
191- background-color: #3a87ad;">Requires authentication</small >
192-
202+ <br ><small style =" padding : 1px 9px 2px ;font-weight : bold ;white-space : nowrap ;color : #ffffff ;-webkit-border-radius : 9px ;-moz-border-radius : 9px ;border-radius : 9px ;background-color : #3a87ad ;" >Requires authentication</small >
193203> Example request:
194204
195205``` bash
196206curl -X GET -G " http://localhost/api/withAuthTag" \
197- -H " Accept: application/json" \
198207 -H " Authorization: customAuthToken" \
199- -H " Custom-Header: NotSoCustom"
208+ -H " Custom-Header: NotSoCustom"
200209```
201210
202211``` javascript
203- var settings = {
204- " async" : true ,
205- " crossDomain" : true ,
206- " url" : " http://localhost/api/withAuthTag" ,
207- " method" : " GET" ,
208- " headers" : {
209- " accept" : " application/json" ,
210- " Authorization" : " customAuthToken" ,
211- " Custom-Header" : " NotSoCustom" ,
212- }
212+ const url = new URL (" http://localhost/api/withAuthTag" );
213+
214+ let headers = {
215+ " Authorization" : " customAuthToken" ,
216+ " Custom-Header" : " NotSoCustom" ,
217+ " Accept" : " application/json" ,
218+ " Content-Type" : " application/json" ,
213219}
214220
215- $ .ajax (settings).done (function (response ) {
216- console .log (response);
217- });
221+ fetch (url, {
222+ method: " GET" ,
223+ headers: headers,
224+ })
225+ .then (response => response .json ())
226+ .then (json => console .log (json));
218227```
219228
220- > Example response:
229+
230+ > Example response (200):
221231
222232``` json
223233null
0 commit comments