-
Notifications
You must be signed in to change notification settings - Fork 1
/
uji.cfg
261 lines (261 loc) · 10.6 KB
/
uji.cfg
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
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
---
host: http://localhost:3000
---
method: POST
path: /users.json
body: "{\"fbid\":\"\", \"secretkey\":\"abcdefg\", \"email\":\"\"}"
status: 200
response: "{\"id\":1, \"membertime\":null, \"bucks\":200, \"fbid\":\"\", \"email\":\"\", \"secretkey\":\"abcdefg\"}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /users/1.json
body: "{\"fbid\":\"67890\", \"bucks\":2000, \"fb_name\":\"test_name\"}"
status: 200
response: "{\"id\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /users/1/updatemember
body: "{\"receipt\":1}"
status: 200
response: "{\"membertime\":\"2100-01-01T00:00:00Z\"}"
---
method: GET
path: /posts/beacons
headers: "{user-id: 1, Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
status: 200
response: "[]"
---
method: POST
path: /users.json
body: "{\"fbid\":\"12345\", \"fb_name\":\"test_name2\", \"secretkey\":\"abcdefg\", \"email\":\"\", \"fb_friends\":\"67890|45678\"}"
status: 200
response: "{\"id\":2, \"membertime\":null, \"bucks\":200, \"fbid\":\"12345\", \"email\":\"\", \"secretkey\":\"abcdefg\"}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /users/2.json
body: "{\"fbid\":\"67890\"}"
status: 422
response: "{\"errors\":\"FacebookID already associated with different user\"}"
---
method: PUT
path: /users/2.json
body: "{\"bucks\":3000}"
status: 200
response: "{\"id\":2}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: GET
path: /users/1/user_leaderboards.json
status: 200
response: "[[{\"lbtype\":1,\"lbvalue\":2000,\"weekof\":\"1999-12-27\", \"fbid\":\"67890\", \"fb_name\":\"test_name\", \"membertime\":\"2100-01-01T00:00:00Z\"}],[{\"lbtype\":1,\"lbvalue\":3000,\"weekof\":\"1999-12-27\",\"fbid\":\"12345\", \"fb_name\":\"test_name2\", \"membertime\":null}]]"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: GET
path: /users/facebook
status: 404
response: "{\"errors\":\"Could not find matching user for facebookid\"}"
headers: "{Facebook-Id: 45678}"
---
method: GET
path: /users/facebook
status: 200
response: "{\"id\":1, \"membertime\":\"2100-01-01T00:00:00Z\", \"bucks\":2000, \"fbid\":\"67890\", \"secretkey\":\"abcdefg\", \"email\":\"\", \"secretkey\":\"abcdefg\"}"
headers: "{Facebook-Id: 67890}"
---
method: POST
path: /item_infos.json
body: "{\"price\":1, \"supplymax\":100, \"supplyrate\":1, \"multiplier\":1, \"tier\":1,\"img\":\"default\", \"disabled\":false}"
status: 200
response: "{\"id\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: POST
path: /item_infos/1/item_locs
body: "{\"locale\":\"en\", \"localized_name\":\"en_name\", \"localized_desc\":\"en_desc\"}"
status: 200
response: "{\"id\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: GET
path: /item_infos/tier
status: 200
response: "[{\"id\":1, \"multiplier\":1, \"price\":1, \"supplymax\":100, \"supplyrate\":1, \"locale\":\"en\", \"localized_desc\":\"en_desc\", \"localized_name\":\"en_name\", \"tier\":1, \"img\":\"default\", \"disabled\":false}]"
headers: "{Item-Tier: 1}"
---
method: GET
path: /item_infos/1.json
status: 200
response: "{\"id\":1, \"multiplier\":1, \"price\":1, \"supplymax\":100, \"supplyrate\":1, \"locale\":\"en\", \"localized_desc\":\"en_desc\", \"localized_name\":\"en_name\", \"tier\":1, \"img\":\"default\", \"disabled\":false}"
---
method: POST
path: /posts.json
body: "{\"user_id\":2}"
status: 422
response: "{\"errors\":\"Exception occurred\"}"
---
method: POST
path: /posts.json
body: "{\"user_id\":1, \"item_info_id\":2}"
status: 422
response: "{\"errors\":\"Exception occurred\"}"
---
method: POST
path: /posts.json
body: "{\"user_id\":1, \"longitude\":\"-122.406417\", \"latitude\":\"37.785834\", \"item_info_id\":1}"
status: 200
response: "{\"id\":1, \"img\":\"default\", \"supply\":100, \"supplymaxlevel\":1, \"supplyratelevel\":1, \"beacontime\":null}"
---
method: GET
path: /posts.json
headers: "{user-id: 1}"
status: 200
response: "[{\"id\":1, \"img\":\"default\", \"item_info_id\":1, \"latitude\":37.785834, \"longitude\":-122.406417, \"name\":\"\", \"supply\":100, \"supplymaxlevel\":1, \"supplyratelevel\":1, \"user_id\":1, \"beacontime\":null}]"
---
method: PUT
path: /posts/1.json
body: "{\"beacontime\":\"test\"}"
status: 200
response: "{\"id\":1, \"supply\":100, \"supplymaxlevel\":1, \"supplyratelevel\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /posts/1.json
body: "{\"beacontime\":\"test\"}"
status: 403
response: "{\"errors\":\"Beacon already exist on another post\"}"
---
method: PUT
path: /posts/1.json
body: "{\"supply\":-50}"
status: 200
response: "{\"id\":1, \"supply\":50, \"supplymaxlevel\":1, \"supplyratelevel\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /posts/1.json
body: "{\"supply\":-100}"
status: 200
response: "{\"id\":1, \"supply\":0, \"supplymaxlevel\":1, \"supplyratelevel\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: GET
path: /users/1/sales.json
status: 200
response: "[{\"post_id\":1, \"user_id\":1, \"amount\":2, \"fbid\":null}, {\"post_id\":1, \"user_id\":1, \"amount\":2, \"fbid\":null}]"
---
method: PUT
path: /posts/1.json
body: "{\"supply\":100}"
status: 200
response: "{\"id\":1, \"supply\":100, \"supplymaxlevel\":1, \"supplyratelevel\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: GET
path: /posts/beacons
headers: "{user-id: 2, Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
status: 200
response: "[{\"id\":1, \"img\":\"default\", \"item_info_id\":1, \"latitude\":37.785834, \"longitude\":-122.406417, \"name\":\"\", \"supply\":100, \"supplymaxlevel\":1, \"supplyratelevel\":1, \"user_id\":1, \"fbid\":\"67890\"}]"
---
method: POST
path: /flyer_infos.json
body: "{\"capacity\":1, \"speed\":1, \"stormresist\":1, \"multiplier\":1, \"tier\":1, \"price\":100, \"load_time\":10, \"topimg\":\"default\", \"sideimg\":\"default\", \"disabled\":false}"
status: 200
response: "{\"id\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /flyer_infos/1.json
body: "{\"capacity\":2}"
status: 403
response: "{\"errors\":\"Data incorrect\"}"
---
method: POST
path: /flyer_infos/1/flyer_locs
body: "{\"locale\":\"en\", \"localized_name\":\"en_itemname\", \"localized_desc\":\"en_itemdesc\"}"
status: 200
response: "{\"id\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: GET
path: /flyer_infos.json
status: 200
response: "[{\"id\":1, \"tier\":1, \"price\":100, \"multiplier\":1, \"capacity\":1, \"load_time\":10, \"speed\":1, \"stormresist\":1, \"topimg\":\"default\", \"sideimg\":\"default\", \"locale\":\"en\", \"localized_desc\":\"en_itemdesc\", \"localized_name\":\"en_itemname\", \"disabled\":false}]"
---
method: GET
path: /flyer_infos/1.json
status: 200
response: "{\"id\":1, \"tier\":1, \"price\":100, \"multiplier\":1, \"capacity\":1, \"load_time\":10, \"speed\":1, \"stormresist\":1, \"topimg\":\"default\", \"sideimg\":\"default\", \"locale\":\"en\", \"localized_desc\":\"en_itemdesc\", \"localized_name\":\"en_itemname\", \"disabled\":false}"
---
method: POST
path: /users/1/user_flyers
body: "{\"flyer_info_id\":1}"
status: 200
response: "{\"id\":1}"
headers: "{Init-Post-Id: 1}"
---
method: GET
path: /users/1/user_flyers
status: 200
response: "[{\"id\":1, \"flyer_info_id\":1, \"item_info_id\":null, \"num_items\":0, \"cost_basis\":0.0, \"meterstraveled\":0.0, \"colorindex\":null, \"level\":null, \"flyer_paths\":[{\"id\":1, \"latitude1\":null, \"latitude2\":null, \"longitude1\":null, \"longitude2\":null, \"post1\":1, \"post2\":1, \"stormed\":0, \"storms\":0, \"item_info_id\":null, \"num_items\":0, \"price\":0, \"done\":true}]}]"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: POST
path: /users/1/user_flyers/1/flyer_paths
body: "{\"post1\":1, \"longitude2\":100.1234, \"latitude2\":100.5678, \"storms\":0, \"stormed\":0, \"created_at\":\"2050-01-01T01:01:01+00:00\", \"item_info_id\":1, \"num_items\":5, \"price\":10}"
status: 200
response: "{\"id\":2}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /users/1/user_flyers/1/flyer_paths/2
body: "{\"done\":false}"
status: 200
response: "{\"id\":2}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: GET
path: /users/1/user_flyers/1/flyer_paths
status: 200
response: "[{\"done\":true, \"id\":1, \"latitude1\":null, \"latitude2\":null, \"longitude1\":null, \"longitude2\":null, \"post1\":1, \"post2\":1, \"stormed\":0, \"storms\":0, \"item_info_id\":null, \"num_items\":0, \"price\":0}, {\"done\":false, \"id\":2, \"post1\":1, \"longitude2\":100.1234, \"latitude2\":100.5678, \"post2\":null, \"longitude1\":null, \"latitude1\":null, \"storms\":0, \"stormed\":0, \"item_info_id\":1, \"num_items\":5, \"price\":10}]"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /users/1/user_flyers/1
body: "{\"item_info_id\":\"1\", \"num_items\":\"5\", \"cost_basis\":\"10.0\", \"meterstraveled\":100.0, \"flyer_path\":{\"item_info_id\":5, \"num_items\":50, \"price\":100}}"
status: 200
response: "{\"id\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /users/1/user_flyers/1
body: "{\"colorindex\":\"1\"}"
status: 200
response: "{\"id\":1}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"
---
method: PUT
path: /users/1/user_flyers/1/flyer_paths/setdone
body: "{\"post1\":1, \"post2\":2, \"longitude2\":100.1234, \"latitude2\":100.5678}"
status: 403
response: "{\"errors\":\"Parameters do not match latest flight path\"}"
---
method: PUT
path: /users/1/user_flyers/1/flyer_paths/setdone
body: "{\"post1\":1, \"longitude2\":100.1234, \"latitude2\":100.5678}"
status: 200
response: "{\"id\":2}"
---
method: PUT
path: /users/1/user_flyers/1/flyer_paths/setdone
body: "{\"post1\":1, \"longitude2\":100.1234, \"latitude2\":100.5678}"
status: 200
response: "{\"id\":2}"
---
method: GET
path: /users/1/user_flyers/1
status: 200
response: "{\"id\":1, \"flyer_info_id\":1, \"item_info_id\":1, \"num_items\":5, \"cost_basis\":10.0, \"meterstraveled\":100.0, \"colorindex\":1, \"level\":null, \"flyer_paths\":[{\"id\":2, \"latitude1\":null, \"longitude1\":null, \"longitude2\":100.1234, \"latitude2\":100.5678, \"post1\":1, \"post2\":null, \"stormed\":0, \"storms\":0, \"item_info_id\":5, \"num_items\":50, \"price\":100, \"done\":true}]}"
headers: "{Validation-Key: 4788f50c-24fd-47d4-acf4-39933603995a}"