Skip to content
This repository was archived by the owner on Oct 11, 2023. It is now read-only.

Commit 11c4dd5

Browse files
dominicbettshathind-ms
authored andcommitted
Add Postman files used in docs tutorial (#242)
* Add Postman files used in docs tutorial
1 parent f3fbc22 commit 11c4dd5

File tree

2 files changed

+396
-0
lines changed

2 files changed

+396
-0
lines changed
Lines changed: 378 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,378 @@
1+
{
2+
"info": {
3+
"_postman_id": "7c0d1715-9f1e-4b0f-838e-9c494ed23325",
4+
"name": "Azure IoT Device Simulation solution accelerator",
5+
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
6+
},
7+
"item": [
8+
{
9+
"_postman_id": "1b0e63c6-1aaf-4e27-9f01-451509039c5d",
10+
"name": "Get current simulation",
11+
"event": [
12+
{
13+
"listen": "test",
14+
"script": {
15+
"id": "b9995e40-f3d4-46ef-a59c-faa55762e969",
16+
"type": "text/javascript",
17+
"exec": [
18+
"var jsonData = JSON.parse(responseBody);",
19+
"postman.setEnvironmentVariable(\"ETag\", jsonData.ETag.replace(/\"/g, \"\\\\\\\"\"));"
20+
]
21+
}
22+
}
23+
],
24+
"request": {
25+
"method": "GET",
26+
"header": [],
27+
"body": {
28+
"mode": "raw",
29+
"raw": "{\r\n \"Etag\": \"8602d62c271760\",\r\n \"Enabled\": false\r\n}"
30+
},
31+
"url": {
32+
"raw": "http://127.0.0.1:9003/v1/simulations/1",
33+
"protocol": "http",
34+
"host": [
35+
"127",
36+
"0",
37+
"0",
38+
"1"
39+
],
40+
"port": "9003",
41+
"path": [
42+
"v1",
43+
"simulations",
44+
"1"
45+
]
46+
}
47+
},
48+
"response": []
49+
},
50+
{
51+
"_postman_id": "a10c6736-5bb1-47cf-a839-442d52820b99",
52+
"name": "Create default simulation",
53+
"event": [
54+
{
55+
"listen": "test",
56+
"script": {
57+
"id": "133696de-be66-4cd2-bbc5-0c2740770b8d",
58+
"type": "text/javascript",
59+
"exec": [
60+
"var jsonData = JSON.parse(responseBody);",
61+
"postman.setEnvironmentVariable(\"ETag\", jsonData.ETag.replace(/\"/g, \"\\\\\\\"\"));"
62+
]
63+
}
64+
}
65+
],
66+
"request": {
67+
"auth": {
68+
"type": "noauth"
69+
},
70+
"method": "POST",
71+
"header": [
72+
{
73+
"key": "Content-Type",
74+
"value": "application/json; charset=utf-8"
75+
}
76+
],
77+
"body": {
78+
"mode": "raw",
79+
"raw": ""
80+
},
81+
"url": {
82+
"raw": "http://127.0.0.1:9003/v1/simulations?template=default",
83+
"protocol": "http",
84+
"host": [
85+
"127",
86+
"0",
87+
"0",
88+
"1"
89+
],
90+
"port": "9003",
91+
"path": [
92+
"v1",
93+
"simulations"
94+
],
95+
"query": [
96+
{
97+
"key": "template",
98+
"value": "default"
99+
}
100+
]
101+
}
102+
},
103+
"response": []
104+
},
105+
{
106+
"_postman_id": "c222aaa5-6af9-4e02-b0f7-8fd747a8feb1",
107+
"name": "Get status",
108+
"request": {
109+
"method": "GET",
110+
"header": [],
111+
"body": {
112+
"mode": "raw",
113+
"raw": ""
114+
},
115+
"url": {
116+
"raw": "http://127.0.0.1:9003/v1/status",
117+
"protocol": "http",
118+
"host": [
119+
"127",
120+
"0",
121+
"0",
122+
"1"
123+
],
124+
"port": "9003",
125+
"path": [
126+
"v1",
127+
"status"
128+
]
129+
}
130+
},
131+
"response": []
132+
},
133+
{
134+
"_postman_id": "a606a1d3-c275-433d-b49c-cc5512b82db8",
135+
"name": "Get list of device models",
136+
"request": {
137+
"method": "GET",
138+
"header": [],
139+
"body": {
140+
"mode": "raw",
141+
"raw": ""
142+
},
143+
"url": {
144+
"raw": "http://127.0.0.1:9003/v1/devicemodels",
145+
"protocol": "http",
146+
"host": [
147+
"127",
148+
"0",
149+
"0",
150+
"1"
151+
],
152+
"port": "9003",
153+
"path": [
154+
"v1",
155+
"devicemodels"
156+
]
157+
}
158+
},
159+
"response": []
160+
},
161+
{
162+
"_postman_id": "c559fcf5-7e80-4774-ae22-e0940eae198d",
163+
"name": "Start simulation",
164+
"event": [
165+
{
166+
"listen": "test",
167+
"script": {
168+
"id": "5439883d-103c-4aa0-8973-f09a10eb2bd1",
169+
"type": "text/javascript",
170+
"exec": [
171+
"var jsonData = JSON.parse(responseBody);",
172+
"postman.setEnvironmentVariable(\"ETag\", jsonData.ETag.replace(/\"/g, \"\\\\\\\"\"));"
173+
]
174+
}
175+
}
176+
],
177+
"request": {
178+
"method": "PATCH",
179+
"header": [
180+
{
181+
"key": "Content-Type",
182+
"value": "application/json"
183+
}
184+
],
185+
"body": {
186+
"mode": "raw",
187+
"raw": "{\r\n \"Etag\": \"{{ETag}}\",\r\n \"Enabled\": true\r\n}"
188+
},
189+
"url": {
190+
"raw": "http://127.0.0.1:9003/v1/simulations/1",
191+
"protocol": "http",
192+
"host": [
193+
"127",
194+
"0",
195+
"0",
196+
"1"
197+
],
198+
"port": "9003",
199+
"path": [
200+
"v1",
201+
"simulations",
202+
"1"
203+
]
204+
}
205+
},
206+
"response": []
207+
},
208+
{
209+
"_postman_id": "1279dd9e-b5e0-416b-81a4-1df8683c21fd",
210+
"name": "Stop simulation",
211+
"event": [
212+
{
213+
"listen": "test",
214+
"script": {
215+
"id": "01cfbca0-fb42-43b9-a1b9-28c347f40dd8",
216+
"type": "text/javascript",
217+
"exec": [
218+
"var jsonData = JSON.parse(responseBody);",
219+
"postman.setEnvironmentVariable(\"ETag\", jsonData.ETag.replace(/\"/g, \"\\\\\\\"\"));"
220+
]
221+
}
222+
}
223+
],
224+
"request": {
225+
"method": "PATCH",
226+
"header": [
227+
{
228+
"key": "Content-Type",
229+
"value": "application/json; charset=utf-8"
230+
}
231+
],
232+
"body": {
233+
"mode": "raw",
234+
"raw": "{\r\n \"Etag\": \"{{ETag}}\",\r\n \"Enabled\": false\r\n}"
235+
},
236+
"url": {
237+
"raw": "http://127.0.0.1:9003/v1/simulations/1",
238+
"protocol": "http",
239+
"host": [
240+
"127",
241+
"0",
242+
"0",
243+
"1"
244+
],
245+
"port": "9003",
246+
"path": [
247+
"v1",
248+
"simulations",
249+
"1"
250+
]
251+
}
252+
},
253+
"response": []
254+
},
255+
{
256+
"_postman_id": "44319140-d78e-49f5-b9f8-498be94f3279",
257+
"name": "Create lightbulb simulation",
258+
"event": [
259+
{
260+
"listen": "test",
261+
"script": {
262+
"id": "de6d0728-92ba-422f-adbc-f26faca67a0f",
263+
"type": "text/javascript",
264+
"exec": [
265+
"var jsonData = JSON.parse(responseBody);",
266+
"postman.setEnvironmentVariable(\"ETag\", jsonData.ETag.replace(/\"/g, \"\\\\\\\"\"));"
267+
]
268+
}
269+
}
270+
],
271+
"request": {
272+
"auth": {
273+
"type": "noauth"
274+
},
275+
"method": "PUT",
276+
"header": [
277+
{
278+
"key": "Content-Type",
279+
"value": "application/json; charset=utf-8"
280+
}
281+
],
282+
"body": {
283+
"mode": "raw",
284+
"raw": "{\r\n \"ETag\": \"{{ETag}}\",\r\n \"Enabled\": true,\r\n \"DeviceModels\": [\r\n {\r\n \"Id\": \"lightbulb-01\",\r\n \"Count\": 2\r\n }\r\n ]\r\n}"
285+
},
286+
"url": {
287+
"raw": "http://127.0.0.1:9003/v1/simulations/1",
288+
"protocol": "http",
289+
"host": [
290+
"127",
291+
"0",
292+
"0",
293+
"1"
294+
],
295+
"port": "9003",
296+
"path": [
297+
"v1",
298+
"simulations",
299+
"1"
300+
]
301+
}
302+
},
303+
"response": []
304+
},
305+
{
306+
"_postman_id": "b25414fb-9f8e-4b8f-abd3-110948a9e78d",
307+
"name": "Create modified chiller simulation",
308+
"event": [
309+
{
310+
"listen": "test",
311+
"script": {
312+
"id": "de6d0728-92ba-422f-adbc-f26faca67a0f",
313+
"type": "text/javascript",
314+
"exec": [
315+
"var jsonData = JSON.parse(responseBody);",
316+
"postman.setEnvironmentVariable(\"ETag\", jsonData.ETag.replace(/\"/g, \"\\\\\\\"\"));"
317+
]
318+
}
319+
}
320+
],
321+
"request": {
322+
"auth": {
323+
"type": "noauth"
324+
},
325+
"method": "PUT",
326+
"header": [
327+
{
328+
"key": "Content-Type",
329+
"value": "application/json; charset=utf-8"
330+
}
331+
],
332+
"body": {
333+
"mode": "raw",
334+
"raw": "{\r\n \"ETag\": \"{{ETag}}\",\r\n \"Enabled\": true,\r\n \"DeviceModels\": [\r\n {\r\n \"Id\": \"chiller-01\",\r\n \"Count\": 4\r\n }\r\n ]\r\n}"
335+
},
336+
"url": {
337+
"raw": "http://127.0.0.1:9003/v1/simulations/1",
338+
"protocol": "http",
339+
"host": [
340+
"127",
341+
"0",
342+
"0",
343+
"1"
344+
],
345+
"port": "9003",
346+
"path": [
347+
"v1",
348+
"simulations",
349+
"1"
350+
]
351+
}
352+
},
353+
"response": []
354+
}
355+
],
356+
"event": [
357+
{
358+
"listen": "prerequest",
359+
"script": {
360+
"id": "ae772bbd-29f7-4685-931d-210de7c37ae6",
361+
"type": "text/javascript",
362+
"exec": [
363+
""
364+
]
365+
}
366+
},
367+
{
368+
"listen": "test",
369+
"script": {
370+
"id": "a1d8c733-fca5-4c4b-ad2a-753cd2564057",
371+
"type": "text/javascript",
372+
"exec": [
373+
""
374+
]
375+
}
376+
}
377+
]
378+
}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"id": "42d4611f-a74d-4241-a777-c382871d665d",
3+
"name": "Azure IoT Device Simulation solution accelerator",
4+
"values": [
5+
{
6+
"description": {
7+
"content": "",
8+
"type": "text/plain"
9+
},
10+
"value": "",
11+
"key": "ETag",
12+
"enabled": true
13+
}
14+
],
15+
"_postman_variable_scope": "environment",
16+
"_postman_exported_at": "2018-08-08T13:59:32.743Z",
17+
"_postman_exported_using": "Postman/6.2.3"
18+
}

0 commit comments

Comments
 (0)