poptart 0.0.3 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/version.rb +1 -1
- data/spec/requests/answering_survey_questions_spec.rb +2 -2
- data/spec/vcr/answering/survey_questions_answers_a_survey_question.yml +3674 -719
- data/spec/vcr/answering/survey_questions_creates_and_returns_a_random_question_survey.yml +106 -77
- data/spec/vcr/answering/survey_questions_creates_and_returns_an_empty_survey.yml +34 -35
- data/spec/vcr/answering/survey_questions_finds_survey_question_for_id.yml +104 -78
- data/spec/vcr/poptart/root/returns_survey_links.yml +5 -5
- data/spec/vcr/user/management_creates_a_user.yml +20 -20
- data/spec/vcr/user/management_returns_a_user.yml +40 -40
- metadata +2 -14
- data/spec/vcr/poptart/user/answers_a_survey_question.yml +0 -1580
- data/spec/vcr/poptart/user/creates_a_user.yml +0 -135
- data/spec/vcr/poptart/user/creates_and_returns_a_random_question_survey.yml +0 -341
- data/spec/vcr/poptart/user/creates_and_returns_an_empty_survey.yml +0 -272
- data/spec/vcr/poptart/user/finds_survey_question_for_id.yml +0 -327
- data/spec/vcr/poptart/user/returns_a_user.yml +0 -267
@@ -1,1580 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: http://localhost:3000/api/surveys?random=true
|
6
|
-
body:
|
7
|
-
encoding: UTF-8
|
8
|
-
string: '{"survey":{"user_id":222}}'
|
9
|
-
headers:
|
10
|
-
User-Agent:
|
11
|
-
- Faraday v0.9.0
|
12
|
-
Content-Type:
|
13
|
-
- application/json
|
14
|
-
Api-Token:
|
15
|
-
- testing
|
16
|
-
Accept-Encoding:
|
17
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
18
|
-
Accept:
|
19
|
-
- "*/*"
|
20
|
-
response:
|
21
|
-
status:
|
22
|
-
code: 201
|
23
|
-
message: 'Created '
|
24
|
-
headers:
|
25
|
-
X-Frame-Options:
|
26
|
-
- SAMEORIGIN
|
27
|
-
X-Xss-Protection:
|
28
|
-
- 1; mode=block
|
29
|
-
X-Content-Type-Options:
|
30
|
-
- nosniff
|
31
|
-
X-Ua-Compatible:
|
32
|
-
- chrome=1
|
33
|
-
Content-Type:
|
34
|
-
- application/json; charset=utf-8
|
35
|
-
Etag:
|
36
|
-
- '"26f7416a56e6688d16f7f200223cfeb4"'
|
37
|
-
Cache-Control:
|
38
|
-
- max-age=0, private, must-revalidate
|
39
|
-
X-Request-Id:
|
40
|
-
- 5278ae56-7e87-45a1-a248-6d97592d3588
|
41
|
-
X-Runtime:
|
42
|
-
- '0.061987'
|
43
|
-
Server:
|
44
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
45
|
-
Date:
|
46
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
47
|
-
Content-Length:
|
48
|
-
- '3876'
|
49
|
-
Connection:
|
50
|
-
- Keep-Alive
|
51
|
-
body:
|
52
|
-
encoding: UTF-8
|
53
|
-
string: |-
|
54
|
-
{
|
55
|
-
"id": 166,
|
56
|
-
"user_id": 222,
|
57
|
-
"survey_questions": [
|
58
|
-
{
|
59
|
-
"id": 557,
|
60
|
-
"text": "When did you last check Facebook?",
|
61
|
-
"type": "multiple",
|
62
|
-
"responses": [
|
63
|
-
"Right now",
|
64
|
-
"In the last 5 minutes",
|
65
|
-
"In the last 15 minutes",
|
66
|
-
"In the last 30 minutes",
|
67
|
-
"In the last hour",
|
68
|
-
"1-2 hours ago",
|
69
|
-
"3-5 hours ago",
|
70
|
-
"6-12 hours ago",
|
71
|
-
"24 hours ago",
|
72
|
-
"Don't use facebook"
|
73
|
-
],
|
74
|
-
"freeform": false,
|
75
|
-
"_links": {
|
76
|
-
"self": {
|
77
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/557"
|
78
|
-
},
|
79
|
-
"survey": {
|
80
|
-
"href": "http://localhost:3000/api/surveys/166"
|
81
|
-
},
|
82
|
-
"create": {
|
83
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
84
|
-
},
|
85
|
-
"submit": {
|
86
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/557"
|
87
|
-
}
|
88
|
-
}
|
89
|
-
},
|
90
|
-
{
|
91
|
-
"id": 558,
|
92
|
-
"text": "What time did you wake up this morning?",
|
93
|
-
"type": "time",
|
94
|
-
"freeform": false,
|
95
|
-
"_links": {
|
96
|
-
"self": {
|
97
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/558"
|
98
|
-
},
|
99
|
-
"survey": {
|
100
|
-
"href": "http://localhost:3000/api/surveys/166"
|
101
|
-
},
|
102
|
-
"create": {
|
103
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
104
|
-
},
|
105
|
-
"submit": {
|
106
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/558"
|
107
|
-
}
|
108
|
-
}
|
109
|
-
},
|
110
|
-
{
|
111
|
-
"id": 559,
|
112
|
-
"text": "Are you judging or evaluating what you are doing right now (i.e. at the moment just before you were notified?)",
|
113
|
-
"type": "multiple",
|
114
|
-
"responses": [
|
115
|
-
"f",
|
116
|
-
"Yes - Negatively",
|
117
|
-
"Yes - Neutrally",
|
118
|
-
"Yes - Positively"
|
119
|
-
],
|
120
|
-
"freeform": false,
|
121
|
-
"_links": {
|
122
|
-
"self": {
|
123
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/559"
|
124
|
-
},
|
125
|
-
"survey": {
|
126
|
-
"href": "http://localhost:3000/api/surveys/166"
|
127
|
-
},
|
128
|
-
"create": {
|
129
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
130
|
-
},
|
131
|
-
"submit": {
|
132
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/559"
|
133
|
-
}
|
134
|
-
}
|
135
|
-
},
|
136
|
-
{
|
137
|
-
"id": 560,
|
138
|
-
"text": "To what extent do you expect good things to happen in the future?",
|
139
|
-
"type": "range",
|
140
|
-
"responses": [
|
141
|
-
"0",
|
142
|
-
"10"
|
143
|
-
],
|
144
|
-
"freeform": false,
|
145
|
-
"_links": {
|
146
|
-
"self": {
|
147
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/560"
|
148
|
-
},
|
149
|
-
"survey": {
|
150
|
-
"href": "http://localhost:3000/api/surveys/166"
|
151
|
-
},
|
152
|
-
"create": {
|
153
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
154
|
-
},
|
155
|
-
"submit": {
|
156
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/560"
|
157
|
-
}
|
158
|
-
}
|
159
|
-
},
|
160
|
-
{
|
161
|
-
"id": 561,
|
162
|
-
"text": "Where are you?",
|
163
|
-
"type": "multiple",
|
164
|
-
"responses": [
|
165
|
-
"At Home",
|
166
|
-
"At Work",
|
167
|
-
"In a car",
|
168
|
-
"Other"
|
169
|
-
],
|
170
|
-
"freeform": true,
|
171
|
-
"_links": {
|
172
|
-
"self": {
|
173
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/561"
|
174
|
-
},
|
175
|
-
"survey": {
|
176
|
-
"href": "http://localhost:3000/api/surveys/166"
|
177
|
-
},
|
178
|
-
"create": {
|
179
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
180
|
-
},
|
181
|
-
"submit": {
|
182
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/561"
|
183
|
-
}
|
184
|
-
}
|
185
|
-
}
|
186
|
-
],
|
187
|
-
"_links": {
|
188
|
-
"self": {
|
189
|
-
"href": "http://localhost:3000/api/surveys/166"
|
190
|
-
},
|
191
|
-
"submit": {
|
192
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
193
|
-
},
|
194
|
-
"next": {
|
195
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/557"
|
196
|
-
}
|
197
|
-
}
|
198
|
-
}
|
199
|
-
http_version:
|
200
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
201
|
-
- request:
|
202
|
-
method: put
|
203
|
-
uri: http://localhost:3000/api/surveys/166/survey_questions/557
|
204
|
-
body:
|
205
|
-
encoding: UTF-8
|
206
|
-
string: '{"id":557,"survey_question":{"answer":"foo"}}'
|
207
|
-
headers:
|
208
|
-
User-Agent:
|
209
|
-
- Faraday v0.9.0
|
210
|
-
Content-Type:
|
211
|
-
- application/json
|
212
|
-
Api-Token:
|
213
|
-
- testing
|
214
|
-
Accept-Encoding:
|
215
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
216
|
-
Accept:
|
217
|
-
- "*/*"
|
218
|
-
response:
|
219
|
-
status:
|
220
|
-
code: 204
|
221
|
-
message: 'No Content '
|
222
|
-
headers:
|
223
|
-
X-Frame-Options:
|
224
|
-
- SAMEORIGIN
|
225
|
-
X-Xss-Protection:
|
226
|
-
- 1; mode=block
|
227
|
-
X-Content-Type-Options:
|
228
|
-
- nosniff
|
229
|
-
X-Ua-Compatible:
|
230
|
-
- chrome=1
|
231
|
-
Cache-Control:
|
232
|
-
- no-cache
|
233
|
-
X-Request-Id:
|
234
|
-
- 1f50f944-d1cb-4904-932f-f2d2092a470b
|
235
|
-
X-Runtime:
|
236
|
-
- '0.009957'
|
237
|
-
Server:
|
238
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
239
|
-
Date:
|
240
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
241
|
-
Connection:
|
242
|
-
- Keep-Alive
|
243
|
-
body:
|
244
|
-
encoding: UTF-8
|
245
|
-
string: ''
|
246
|
-
http_version:
|
247
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
248
|
-
- request:
|
249
|
-
method: get
|
250
|
-
uri: http://localhost:3000/api/surveys/166
|
251
|
-
body:
|
252
|
-
encoding: US-ASCII
|
253
|
-
string: ''
|
254
|
-
headers:
|
255
|
-
User-Agent:
|
256
|
-
- Faraday v0.9.0
|
257
|
-
Content-Type:
|
258
|
-
- application/json
|
259
|
-
Api-Token:
|
260
|
-
- testing
|
261
|
-
Accept-Encoding:
|
262
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
263
|
-
Accept:
|
264
|
-
- "*/*"
|
265
|
-
response:
|
266
|
-
status:
|
267
|
-
code: 200
|
268
|
-
message: 'OK '
|
269
|
-
headers:
|
270
|
-
X-Frame-Options:
|
271
|
-
- SAMEORIGIN
|
272
|
-
X-Xss-Protection:
|
273
|
-
- 1; mode=block
|
274
|
-
X-Content-Type-Options:
|
275
|
-
- nosniff
|
276
|
-
X-Ua-Compatible:
|
277
|
-
- chrome=1
|
278
|
-
Content-Type:
|
279
|
-
- application/json; charset=utf-8
|
280
|
-
Etag:
|
281
|
-
- '"1635572f8f59bea16de995a6d1913371"'
|
282
|
-
Cache-Control:
|
283
|
-
- max-age=0, private, must-revalidate
|
284
|
-
X-Request-Id:
|
285
|
-
- ac1a0ca6-77ba-46f5-8552-ed4cbc8dab0f
|
286
|
-
X-Runtime:
|
287
|
-
- '0.053401'
|
288
|
-
Server:
|
289
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
290
|
-
Date:
|
291
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
292
|
-
Content-Length:
|
293
|
-
- '3899'
|
294
|
-
Connection:
|
295
|
-
- Keep-Alive
|
296
|
-
body:
|
297
|
-
encoding: UTF-8
|
298
|
-
string: |-
|
299
|
-
{
|
300
|
-
"id": 166,
|
301
|
-
"user_id": 222,
|
302
|
-
"survey_questions": [
|
303
|
-
{
|
304
|
-
"id": 558,
|
305
|
-
"text": "What time did you wake up this morning?",
|
306
|
-
"type": "time",
|
307
|
-
"freeform": false,
|
308
|
-
"_links": {
|
309
|
-
"self": {
|
310
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/558"
|
311
|
-
},
|
312
|
-
"survey": {
|
313
|
-
"href": "http://localhost:3000/api/surveys/166"
|
314
|
-
},
|
315
|
-
"create": {
|
316
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
317
|
-
},
|
318
|
-
"submit": {
|
319
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/558"
|
320
|
-
}
|
321
|
-
}
|
322
|
-
},
|
323
|
-
{
|
324
|
-
"id": 559,
|
325
|
-
"text": "Are you judging or evaluating what you are doing right now (i.e. at the moment just before you were notified?)",
|
326
|
-
"type": "multiple",
|
327
|
-
"responses": [
|
328
|
-
"f",
|
329
|
-
"Yes - Negatively",
|
330
|
-
"Yes - Neutrally",
|
331
|
-
"Yes - Positively"
|
332
|
-
],
|
333
|
-
"freeform": false,
|
334
|
-
"_links": {
|
335
|
-
"self": {
|
336
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/559"
|
337
|
-
},
|
338
|
-
"survey": {
|
339
|
-
"href": "http://localhost:3000/api/surveys/166"
|
340
|
-
},
|
341
|
-
"create": {
|
342
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
343
|
-
},
|
344
|
-
"submit": {
|
345
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/559"
|
346
|
-
}
|
347
|
-
}
|
348
|
-
},
|
349
|
-
{
|
350
|
-
"id": 560,
|
351
|
-
"text": "To what extent do you expect good things to happen in the future?",
|
352
|
-
"type": "range",
|
353
|
-
"responses": [
|
354
|
-
"0",
|
355
|
-
"10"
|
356
|
-
],
|
357
|
-
"freeform": false,
|
358
|
-
"_links": {
|
359
|
-
"self": {
|
360
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/560"
|
361
|
-
},
|
362
|
-
"survey": {
|
363
|
-
"href": "http://localhost:3000/api/surveys/166"
|
364
|
-
},
|
365
|
-
"create": {
|
366
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
367
|
-
},
|
368
|
-
"submit": {
|
369
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/560"
|
370
|
-
}
|
371
|
-
}
|
372
|
-
},
|
373
|
-
{
|
374
|
-
"id": 561,
|
375
|
-
"text": "Where are you?",
|
376
|
-
"type": "multiple",
|
377
|
-
"responses": [
|
378
|
-
"At Home",
|
379
|
-
"At Work",
|
380
|
-
"In a car",
|
381
|
-
"Other"
|
382
|
-
],
|
383
|
-
"freeform": true,
|
384
|
-
"_links": {
|
385
|
-
"self": {
|
386
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/561"
|
387
|
-
},
|
388
|
-
"survey": {
|
389
|
-
"href": "http://localhost:3000/api/surveys/166"
|
390
|
-
},
|
391
|
-
"create": {
|
392
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
393
|
-
},
|
394
|
-
"submit": {
|
395
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/561"
|
396
|
-
}
|
397
|
-
}
|
398
|
-
},
|
399
|
-
{
|
400
|
-
"id": 557,
|
401
|
-
"text": "When did you last check Facebook?",
|
402
|
-
"type": "multiple",
|
403
|
-
"responses": [
|
404
|
-
"Right now",
|
405
|
-
"In the last 5 minutes",
|
406
|
-
"In the last 15 minutes",
|
407
|
-
"In the last 30 minutes",
|
408
|
-
"In the last hour",
|
409
|
-
"1-2 hours ago",
|
410
|
-
"3-5 hours ago",
|
411
|
-
"6-12 hours ago",
|
412
|
-
"24 hours ago",
|
413
|
-
"Don't use facebook"
|
414
|
-
],
|
415
|
-
"answer": "foo",
|
416
|
-
"freeform": false,
|
417
|
-
"_links": {
|
418
|
-
"self": {
|
419
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/557"
|
420
|
-
},
|
421
|
-
"survey": {
|
422
|
-
"href": "http://localhost:3000/api/surveys/166"
|
423
|
-
},
|
424
|
-
"create": {
|
425
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
426
|
-
},
|
427
|
-
"submit": {
|
428
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/557"
|
429
|
-
}
|
430
|
-
}
|
431
|
-
}
|
432
|
-
],
|
433
|
-
"_links": {
|
434
|
-
"self": {
|
435
|
-
"href": "http://localhost:3000/api/surveys/166"
|
436
|
-
},
|
437
|
-
"submit": {
|
438
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions"
|
439
|
-
},
|
440
|
-
"next": {
|
441
|
-
"href": "http://localhost:3000/api/surveys/166/survey_questions/558"
|
442
|
-
}
|
443
|
-
}
|
444
|
-
}
|
445
|
-
http_version:
|
446
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
447
|
-
- request:
|
448
|
-
method: get
|
449
|
-
uri: http://localhost:3000/
|
450
|
-
body:
|
451
|
-
encoding: US-ASCII
|
452
|
-
string: ''
|
453
|
-
headers:
|
454
|
-
User-Agent:
|
455
|
-
- Faraday v0.9.0
|
456
|
-
Content-Type:
|
457
|
-
- application/json
|
458
|
-
Api-Token:
|
459
|
-
- testing
|
460
|
-
Accept-Encoding:
|
461
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
462
|
-
Accept:
|
463
|
-
- "*/*"
|
464
|
-
response:
|
465
|
-
status:
|
466
|
-
code: 200
|
467
|
-
message: 'OK '
|
468
|
-
headers:
|
469
|
-
X-Frame-Options:
|
470
|
-
- SAMEORIGIN
|
471
|
-
X-Xss-Protection:
|
472
|
-
- 1; mode=block
|
473
|
-
X-Content-Type-Options:
|
474
|
-
- nosniff
|
475
|
-
X-Ua-Compatible:
|
476
|
-
- chrome=1
|
477
|
-
Content-Type:
|
478
|
-
- application/json; charset=utf-8
|
479
|
-
Etag:
|
480
|
-
- '"a723ac88b99a06c255a3384c2d01f4fb"'
|
481
|
-
Cache-Control:
|
482
|
-
- max-age=0, private, must-revalidate
|
483
|
-
X-Request-Id:
|
484
|
-
- fd01ad71-1481-4bcc-a373-389f3893d888
|
485
|
-
X-Runtime:
|
486
|
-
- '0.006612'
|
487
|
-
Server:
|
488
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
489
|
-
Date:
|
490
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
491
|
-
Content-Length:
|
492
|
-
- '305'
|
493
|
-
Connection:
|
494
|
-
- Keep-Alive
|
495
|
-
body:
|
496
|
-
encoding: UTF-8
|
497
|
-
string: |-
|
498
|
-
{
|
499
|
-
"_links": {
|
500
|
-
"self": {
|
501
|
-
"href": "http://localhost:3000/api"
|
502
|
-
},
|
503
|
-
"surveys": {
|
504
|
-
"href": "http://localhost:3000/api/surveys"
|
505
|
-
},
|
506
|
-
"users": {
|
507
|
-
"href": "http://localhost:3000/api/users"
|
508
|
-
},
|
509
|
-
"questions": {
|
510
|
-
"href": "http://localhost:3000/api/questions"
|
511
|
-
}
|
512
|
-
}
|
513
|
-
}
|
514
|
-
http_version:
|
515
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
516
|
-
- request:
|
517
|
-
method: get
|
518
|
-
uri: http://localhost:3000/api/questions
|
519
|
-
body:
|
520
|
-
encoding: US-ASCII
|
521
|
-
string: ''
|
522
|
-
headers:
|
523
|
-
User-Agent:
|
524
|
-
- Faraday v0.9.0
|
525
|
-
Content-Type:
|
526
|
-
- application/json
|
527
|
-
Api-Token:
|
528
|
-
- testing
|
529
|
-
Accept-Encoding:
|
530
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
531
|
-
Accept:
|
532
|
-
- "*/*"
|
533
|
-
response:
|
534
|
-
status:
|
535
|
-
code: 200
|
536
|
-
message: 'OK '
|
537
|
-
headers:
|
538
|
-
X-Frame-Options:
|
539
|
-
- SAMEORIGIN
|
540
|
-
X-Xss-Protection:
|
541
|
-
- 1; mode=block
|
542
|
-
X-Content-Type-Options:
|
543
|
-
- nosniff
|
544
|
-
X-Ua-Compatible:
|
545
|
-
- chrome=1
|
546
|
-
Content-Type:
|
547
|
-
- application/json; charset=utf-8
|
548
|
-
Etag:
|
549
|
-
- '"431a273abcc40a3bb311bbe267ebed26"'
|
550
|
-
Cache-Control:
|
551
|
-
- max-age=0, private, must-revalidate
|
552
|
-
X-Request-Id:
|
553
|
-
- ab5016b9-ea66-4117-b4e0-a31659844168
|
554
|
-
X-Runtime:
|
555
|
-
- '0.011913'
|
556
|
-
Server:
|
557
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
558
|
-
Date:
|
559
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
560
|
-
Content-Length:
|
561
|
-
- '10868'
|
562
|
-
Connection:
|
563
|
-
- Keep-Alive
|
564
|
-
body:
|
565
|
-
encoding: UTF-8
|
566
|
-
string: |-
|
567
|
-
[
|
568
|
-
{
|
569
|
-
"id": 1,
|
570
|
-
"text": "How hungry or full are you right now?",
|
571
|
-
"created_at": "2014-05-20T01:42:05.049Z",
|
572
|
-
"updated_at": "2014-05-20T01:42:05.054Z",
|
573
|
-
"responses": [
|
574
|
-
"Very hungry",
|
575
|
-
"Somewhat hungry",
|
576
|
-
"Neither full nor hungry",
|
577
|
-
"Somewhat full",
|
578
|
-
"Very full"
|
579
|
-
],
|
580
|
-
"question_type": "multiple",
|
581
|
-
"freeform": false
|
582
|
-
},
|
583
|
-
{
|
584
|
-
"id": 2,
|
585
|
-
"text": "What time did you wake up this morning?",
|
586
|
-
"created_at": "2014-05-20T01:42:05.057Z",
|
587
|
-
"updated_at": "2014-05-20T01:42:05.057Z",
|
588
|
-
"responses": null,
|
589
|
-
"question_type": "time",
|
590
|
-
"freeform": false
|
591
|
-
},
|
592
|
-
{
|
593
|
-
"id": 3,
|
594
|
-
"text": "What time did you got to sleep last night?",
|
595
|
-
"created_at": "2014-05-20T01:42:05.059Z",
|
596
|
-
"updated_at": "2014-05-20T01:42:05.059Z",
|
597
|
-
"responses": null,
|
598
|
-
"question_type": "time",
|
599
|
-
"freeform": false
|
600
|
-
},
|
601
|
-
{
|
602
|
-
"id": 4,
|
603
|
-
"text": "Are you judging or evaluating yourself right now (i.e. at the moment just before you were notified)?",
|
604
|
-
"created_at": "2014-05-20T01:42:05.060Z",
|
605
|
-
"updated_at": "2014-05-20T01:42:05.062Z",
|
606
|
-
"responses": [
|
607
|
-
"f",
|
608
|
-
"Yes - Negatively",
|
609
|
-
"Yes - Neutrally",
|
610
|
-
"Yes - Positively"
|
611
|
-
],
|
612
|
-
"question_type": "multiple",
|
613
|
-
"freeform": false
|
614
|
-
},
|
615
|
-
{
|
616
|
-
"id": 5,
|
617
|
-
"text": "How well did you sleep last night?",
|
618
|
-
"created_at": "2014-05-20T01:42:05.064Z",
|
619
|
-
"updated_at": "2014-05-20T01:42:05.065Z",
|
620
|
-
"responses": [
|
621
|
-
"0",
|
622
|
-
"10"
|
623
|
-
],
|
624
|
-
"question_type": "range",
|
625
|
-
"freeform": false
|
626
|
-
},
|
627
|
-
{
|
628
|
-
"id": 6,
|
629
|
-
"text": "To what extent are you engrossed in what you are doing?",
|
630
|
-
"created_at": "2014-05-20T01:42:05.067Z",
|
631
|
-
"updated_at": "2014-05-20T01:42:05.068Z",
|
632
|
-
"responses": [
|
633
|
-
"0",
|
634
|
-
"10"
|
635
|
-
],
|
636
|
-
"question_type": "range",
|
637
|
-
"freeform": false
|
638
|
-
},
|
639
|
-
{
|
640
|
-
"id": 7,
|
641
|
-
"text": "To what extent do you feel accepted by the person/people you are interacting with?",
|
642
|
-
"created_at": "2014-05-20T01:42:05.070Z",
|
643
|
-
"updated_at": "2014-05-20T01:42:05.071Z",
|
644
|
-
"responses": [
|
645
|
-
"0",
|
646
|
-
"10"
|
647
|
-
],
|
648
|
-
"question_type": "range",
|
649
|
-
"freeform": false
|
650
|
-
},
|
651
|
-
{
|
652
|
-
"id": 8,
|
653
|
-
"text": "Are you judging or evaluating what you are doing right now (i.e. at the moment just before you were notified?)",
|
654
|
-
"created_at": "2014-05-20T01:42:05.073Z",
|
655
|
-
"updated_at": "2014-05-20T01:42:05.074Z",
|
656
|
-
"responses": [
|
657
|
-
"f",
|
658
|
-
"Yes - Negatively",
|
659
|
-
"Yes - Neutrally",
|
660
|
-
"Yes - Positively"
|
661
|
-
],
|
662
|
-
"question_type": "multiple",
|
663
|
-
"freeform": false
|
664
|
-
},
|
665
|
-
{
|
666
|
-
"id": 9,
|
667
|
-
"text": "In the past 24 hours, have you engaged in sexual activity with another person?",
|
668
|
-
"created_at": "2014-05-20T01:42:05.076Z",
|
669
|
-
"updated_at": "2014-05-20T01:42:05.078Z",
|
670
|
-
"responses": [
|
671
|
-
"t",
|
672
|
-
"f"
|
673
|
-
],
|
674
|
-
"question_type": "boolean",
|
675
|
-
"freeform": false
|
676
|
-
},
|
677
|
-
{
|
678
|
-
"id": 10,
|
679
|
-
"text": "Imagine you were given $10 to divide between yourself and a stranger to whom you would remain anonymous. How much would you give to the stranger?",
|
680
|
-
"created_at": "2014-05-20T01:42:05.080Z",
|
681
|
-
"updated_at": "2014-05-20T01:42:05.082Z",
|
682
|
-
"responses": [
|
683
|
-
[
|
684
|
-
"0",
|
685
|
-
"1",
|
686
|
-
"2",
|
687
|
-
"3",
|
688
|
-
"4",
|
689
|
-
"5",
|
690
|
-
"6",
|
691
|
-
"7",
|
692
|
-
"8",
|
693
|
-
"9",
|
694
|
-
"10"
|
695
|
-
]
|
696
|
-
],
|
697
|
-
"question_type": "multiple",
|
698
|
-
"freeform": false
|
699
|
-
},
|
700
|
-
{
|
701
|
-
"id": 11,
|
702
|
-
"text": "Have you surprised someone with a gift (including small gifts) in the last week?",
|
703
|
-
"created_at": "2014-05-20T01:42:05.085Z",
|
704
|
-
"updated_at": "2014-05-20T01:42:05.086Z",
|
705
|
-
"responses": [
|
706
|
-
"t",
|
707
|
-
"f"
|
708
|
-
],
|
709
|
-
"question_type": "boolean",
|
710
|
-
"freeform": false
|
711
|
-
},
|
712
|
-
{
|
713
|
-
"id": 12,
|
714
|
-
"text": "In general, how is your health?",
|
715
|
-
"created_at": "2014-05-20T01:42:05.089Z",
|
716
|
-
"updated_at": "2014-05-20T01:42:05.090Z",
|
717
|
-
"responses": [
|
718
|
-
"Excellent",
|
719
|
-
"Very Good",
|
720
|
-
"Good",
|
721
|
-
"Fair",
|
722
|
-
"Poor"
|
723
|
-
],
|
724
|
-
"question_type": "multiple",
|
725
|
-
"freeform": false
|
726
|
-
},
|
727
|
-
{
|
728
|
-
"id": 13,
|
729
|
-
"text": "Where would you place yourself on this ladder?\nThink of a ladder representing where people stand in your country.\nAt the top of the ladder are the people who are the best off - those who have the most money, the most education and the most respected jobs. At the bottom are the people who are the worst off - who have the least money, least education, and the least respected jobs or no job. The higher up you are on the ladder, the closer you are to the people at the very top; the lower you are the closer you are to people at the very bottom.",
|
730
|
-
"created_at": "2014-05-20T01:42:05.092Z",
|
731
|
-
"updated_at": "2014-05-20T01:42:05.093Z",
|
732
|
-
"responses": [
|
733
|
-
"0",
|
734
|
-
"10"
|
735
|
-
],
|
736
|
-
"question_type": "range",
|
737
|
-
"freeform": false
|
738
|
-
},
|
739
|
-
{
|
740
|
-
"id": 14,
|
741
|
-
"text": "To what extent is what you're doing interesting?",
|
742
|
-
"created_at": "2014-05-20T01:42:05.095Z",
|
743
|
-
"updated_at": "2014-05-20T01:42:05.096Z",
|
744
|
-
"responses": [
|
745
|
-
"0",
|
746
|
-
"10"
|
747
|
-
],
|
748
|
-
"question_type": "range",
|
749
|
-
"freeform": false
|
750
|
-
},
|
751
|
-
{
|
752
|
-
"id": 15,
|
753
|
-
"text": "On average, how many hours do you work each week?",
|
754
|
-
"created_at": "2014-05-20T01:42:05.098Z",
|
755
|
-
"updated_at": "2014-05-20T01:42:05.100Z",
|
756
|
-
"responses": [
|
757
|
-
"Less than 5",
|
758
|
-
"5-10",
|
759
|
-
"10-20",
|
760
|
-
"20-30",
|
761
|
-
"30-40",
|
762
|
-
"40-50",
|
763
|
-
"50-60",
|
764
|
-
"60-70",
|
765
|
-
"More than 70"
|
766
|
-
],
|
767
|
-
"question_type": "multiple",
|
768
|
-
"freeform": false
|
769
|
-
},
|
770
|
-
{
|
771
|
-
"id": 16,
|
772
|
-
"text": "How do you feel right now?",
|
773
|
-
"created_at": "2014-05-20T01:42:05.102Z",
|
774
|
-
"updated_at": "2014-05-20T01:42:05.103Z",
|
775
|
-
"responses": [
|
776
|
-
"0",
|
777
|
-
"10"
|
778
|
-
],
|
779
|
-
"question_type": "range",
|
780
|
-
"freeform": false
|
781
|
-
},
|
782
|
-
{
|
783
|
-
"id": 17,
|
784
|
-
"text": "To what extent do you expect good things to happen in the future?",
|
785
|
-
"created_at": "2014-05-20T01:42:05.105Z",
|
786
|
-
"updated_at": "2014-05-20T01:42:05.106Z",
|
787
|
-
"responses": [
|
788
|
-
"0",
|
789
|
-
"10"
|
790
|
-
],
|
791
|
-
"question_type": "range",
|
792
|
-
"freeform": false
|
793
|
-
},
|
794
|
-
{
|
795
|
-
"id": 18,
|
796
|
-
"text": "Have you taken any over-the-counter pain medication in the past 24 hours?",
|
797
|
-
"created_at": "2014-05-20T01:42:05.108Z",
|
798
|
-
"updated_at": "2014-05-20T01:42:05.109Z",
|
799
|
-
"responses": [
|
800
|
-
"t",
|
801
|
-
"f"
|
802
|
-
],
|
803
|
-
"question_type": "boolean",
|
804
|
-
"freeform": false
|
805
|
-
},
|
806
|
-
{
|
807
|
-
"id": 19,
|
808
|
-
"text": "To what extent have you procrastinated so far today?",
|
809
|
-
"created_at": "2014-05-20T01:42:05.111Z",
|
810
|
-
"updated_at": "2014-05-20T01:42:05.113Z",
|
811
|
-
"responses": [
|
812
|
-
"0",
|
813
|
-
"10"
|
814
|
-
],
|
815
|
-
"question_type": "range",
|
816
|
-
"freeform": false
|
817
|
-
},
|
818
|
-
{
|
819
|
-
"id": 20,
|
820
|
-
"text": "To what extent are you being productive?",
|
821
|
-
"created_at": "2014-05-20T01:42:05.115Z",
|
822
|
-
"updated_at": "2014-05-20T01:42:05.116Z",
|
823
|
-
"responses": [
|
824
|
-
"0",
|
825
|
-
"10"
|
826
|
-
],
|
827
|
-
"question_type": "range",
|
828
|
-
"freeform": false
|
829
|
-
},
|
830
|
-
{
|
831
|
-
"id": 21,
|
832
|
-
"text": "Who are you talking or interacting with?",
|
833
|
-
"created_at": "2014-05-20T01:42:05.117Z",
|
834
|
-
"updated_at": "2014-05-20T01:42:05.119Z",
|
835
|
-
"responses": [
|
836
|
-
"Spouse/partner/significant other",
|
837
|
-
"Children",
|
838
|
-
"Parents",
|
839
|
-
"Other relatives",
|
840
|
-
"Friends",
|
841
|
-
"Acquaintances",
|
842
|
-
"Strangers",
|
843
|
-
"Co-workers",
|
844
|
-
"Customers/students",
|
845
|
-
"Boss"
|
846
|
-
],
|
847
|
-
"question_type": "multiple",
|
848
|
-
"freeform": true
|
849
|
-
},
|
850
|
-
{
|
851
|
-
"id": 22,
|
852
|
-
"text": "To what extent do you feel accepted by the person/people you are interacting with?",
|
853
|
-
"created_at": "2014-05-20T01:42:05.120Z",
|
854
|
-
"updated_at": "2014-05-20T01:42:05.122Z",
|
855
|
-
"responses": [
|
856
|
-
"0",
|
857
|
-
"10"
|
858
|
-
],
|
859
|
-
"question_type": "range",
|
860
|
-
"freeform": false
|
861
|
-
},
|
862
|
-
{
|
863
|
-
"id": 23,
|
864
|
-
"text": "Are you alone?",
|
865
|
-
"created_at": "2014-05-20T01:42:05.124Z",
|
866
|
-
"updated_at": "2014-05-20T01:42:05.125Z",
|
867
|
-
"responses": [
|
868
|
-
"t",
|
869
|
-
"f"
|
870
|
-
],
|
871
|
-
"question_type": "boolean",
|
872
|
-
"freeform": false
|
873
|
-
},
|
874
|
-
{
|
875
|
-
"id": 24,
|
876
|
-
"text": "Do you want to do what you're doing?",
|
877
|
-
"created_at": "2014-05-20T01:42:05.127Z",
|
878
|
-
"updated_at": "2014-05-20T01:42:05.128Z",
|
879
|
-
"responses": [
|
880
|
-
"t",
|
881
|
-
"f"
|
882
|
-
],
|
883
|
-
"question_type": "boolean",
|
884
|
-
"freeform": false
|
885
|
-
},
|
886
|
-
{
|
887
|
-
"id": 25,
|
888
|
-
"text": "Are you talking or interacting with anyone?",
|
889
|
-
"created_at": "2014-05-20T01:42:05.130Z",
|
890
|
-
"updated_at": "2014-05-20T01:42:05.132Z",
|
891
|
-
"responses": [
|
892
|
-
"t",
|
893
|
-
"f"
|
894
|
-
],
|
895
|
-
"question_type": "boolean",
|
896
|
-
"freeform": false
|
897
|
-
},
|
898
|
-
{
|
899
|
-
"id": 26,
|
900
|
-
"text": "Where are you?",
|
901
|
-
"created_at": "2014-05-20T01:42:05.134Z",
|
902
|
-
"updated_at": "2014-05-20T01:42:05.136Z",
|
903
|
-
"responses": [
|
904
|
-
"At Home",
|
905
|
-
"At Work",
|
906
|
-
"In a car",
|
907
|
-
"Other"
|
908
|
-
],
|
909
|
-
"question_type": "multiple",
|
910
|
-
"freeform": true
|
911
|
-
},
|
912
|
-
{
|
913
|
-
"id": 27,
|
914
|
-
"text": "How many people are you talking or interacting with?",
|
915
|
-
"created_at": "2014-05-20T01:42:05.137Z",
|
916
|
-
"updated_at": "2014-05-20T01:42:05.139Z",
|
917
|
-
"responses": [
|
918
|
-
"At Home",
|
919
|
-
"At Work",
|
920
|
-
"In a car"
|
921
|
-
],
|
922
|
-
"question_type": "multiple",
|
923
|
-
"freeform": false
|
924
|
-
},
|
925
|
-
{
|
926
|
-
"id": 28,
|
927
|
-
"text": "Do you have to do what you're doing?",
|
928
|
-
"created_at": "2014-05-20T01:42:05.141Z",
|
929
|
-
"updated_at": "2014-05-20T01:42:05.142Z",
|
930
|
-
"responses": [
|
931
|
-
"t",
|
932
|
-
"f"
|
933
|
-
],
|
934
|
-
"question_type": "boolean",
|
935
|
-
"freeform": false
|
936
|
-
},
|
937
|
-
{
|
938
|
-
"id": 29,
|
939
|
-
"text": "To what extent are you focused on what you are doing?",
|
940
|
-
"created_at": "2014-05-20T01:42:05.144Z",
|
941
|
-
"updated_at": "2014-05-20T01:42:05.146Z",
|
942
|
-
"responses": [
|
943
|
-
"0",
|
944
|
-
"10"
|
945
|
-
],
|
946
|
-
"question_type": "range",
|
947
|
-
"freeform": false
|
948
|
-
},
|
949
|
-
{
|
950
|
-
"id": 30,
|
951
|
-
"text": "When did you last check Facebook?",
|
952
|
-
"created_at": "2014-05-20T01:42:05.148Z",
|
953
|
-
"updated_at": "2014-05-20T01:42:05.150Z",
|
954
|
-
"responses": [
|
955
|
-
"Right now",
|
956
|
-
"In the last 5 minutes",
|
957
|
-
"In the last 15 minutes",
|
958
|
-
"In the last 30 minutes",
|
959
|
-
"In the last hour",
|
960
|
-
"1-2 hours ago",
|
961
|
-
"3-5 hours ago",
|
962
|
-
"6-12 hours ago",
|
963
|
-
"24 hours ago",
|
964
|
-
"Don't use facebook"
|
965
|
-
],
|
966
|
-
"question_type": "multiple",
|
967
|
-
"freeform": false
|
968
|
-
},
|
969
|
-
{
|
970
|
-
"id": 31,
|
971
|
-
"text": "Beyond any work you've already done today, how many additional hours do you expect to work today?",
|
972
|
-
"created_at": "2014-05-20T01:42:05.152Z",
|
973
|
-
"updated_at": "2014-05-20T01:42:05.153Z",
|
974
|
-
"responses": [
|
975
|
-
"0 (none)",
|
976
|
-
"Less than 1 hour",
|
977
|
-
"1-2 hours",
|
978
|
-
"2-3 hours",
|
979
|
-
"3-4 hours",
|
980
|
-
"4-5 hours",
|
981
|
-
"5-6 hours"
|
982
|
-
],
|
983
|
-
"question_type": "multiple",
|
984
|
-
"freeform": false
|
985
|
-
},
|
986
|
-
{
|
987
|
-
"id": 32,
|
988
|
-
"text": "If you could, and it had no negative consequences, would you jump forward in time 24 hours?",
|
989
|
-
"created_at": "2014-05-20T01:42:05.155Z",
|
990
|
-
"updated_at": "2014-05-20T01:42:05.156Z",
|
991
|
-
"responses": [
|
992
|
-
"t",
|
993
|
-
"f"
|
994
|
-
],
|
995
|
-
"question_type": "boolean",
|
996
|
-
"freeform": false
|
997
|
-
}
|
998
|
-
]
|
999
|
-
http_version:
|
1000
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1001
|
-
- request:
|
1002
|
-
method: get
|
1003
|
-
uri: http://localhost:3000/
|
1004
|
-
body:
|
1005
|
-
encoding: US-ASCII
|
1006
|
-
string: ''
|
1007
|
-
headers:
|
1008
|
-
User-Agent:
|
1009
|
-
- Faraday v0.9.0
|
1010
|
-
Content-Type:
|
1011
|
-
- application/json
|
1012
|
-
Api-Token:
|
1013
|
-
- testing
|
1014
|
-
Accept-Encoding:
|
1015
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
1016
|
-
Accept:
|
1017
|
-
- "*/*"
|
1018
|
-
response:
|
1019
|
-
status:
|
1020
|
-
code: 200
|
1021
|
-
message: 'OK '
|
1022
|
-
headers:
|
1023
|
-
X-Frame-Options:
|
1024
|
-
- SAMEORIGIN
|
1025
|
-
X-Xss-Protection:
|
1026
|
-
- 1; mode=block
|
1027
|
-
X-Content-Type-Options:
|
1028
|
-
- nosniff
|
1029
|
-
X-Ua-Compatible:
|
1030
|
-
- chrome=1
|
1031
|
-
Content-Type:
|
1032
|
-
- application/json; charset=utf-8
|
1033
|
-
Etag:
|
1034
|
-
- '"a723ac88b99a06c255a3384c2d01f4fb"'
|
1035
|
-
Cache-Control:
|
1036
|
-
- max-age=0, private, must-revalidate
|
1037
|
-
X-Request-Id:
|
1038
|
-
- 37b33d70-93d6-49bb-882a-14dddc980c78
|
1039
|
-
X-Runtime:
|
1040
|
-
- '0.007748'
|
1041
|
-
Server:
|
1042
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
1043
|
-
Date:
|
1044
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
1045
|
-
Content-Length:
|
1046
|
-
- '305'
|
1047
|
-
Connection:
|
1048
|
-
- Keep-Alive
|
1049
|
-
body:
|
1050
|
-
encoding: UTF-8
|
1051
|
-
string: |-
|
1052
|
-
{
|
1053
|
-
"_links": {
|
1054
|
-
"self": {
|
1055
|
-
"href": "http://localhost:3000/api"
|
1056
|
-
},
|
1057
|
-
"surveys": {
|
1058
|
-
"href": "http://localhost:3000/api/surveys"
|
1059
|
-
},
|
1060
|
-
"users": {
|
1061
|
-
"href": "http://localhost:3000/api/users"
|
1062
|
-
},
|
1063
|
-
"questions": {
|
1064
|
-
"href": "http://localhost:3000/api/questions"
|
1065
|
-
}
|
1066
|
-
}
|
1067
|
-
}
|
1068
|
-
http_version:
|
1069
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1070
|
-
- request:
|
1071
|
-
method: post
|
1072
|
-
uri: http://localhost:3000/api/users
|
1073
|
-
body:
|
1074
|
-
encoding: UTF-8
|
1075
|
-
string: '{"user":{"external_user_id":42}}'
|
1076
|
-
headers:
|
1077
|
-
User-Agent:
|
1078
|
-
- Faraday v0.9.0
|
1079
|
-
Content-Type:
|
1080
|
-
- application/json
|
1081
|
-
Api-Token:
|
1082
|
-
- testing
|
1083
|
-
Accept-Encoding:
|
1084
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
1085
|
-
Accept:
|
1086
|
-
- "*/*"
|
1087
|
-
response:
|
1088
|
-
status:
|
1089
|
-
code: 201
|
1090
|
-
message: 'Created '
|
1091
|
-
headers:
|
1092
|
-
X-Frame-Options:
|
1093
|
-
- SAMEORIGIN
|
1094
|
-
X-Xss-Protection:
|
1095
|
-
- 1; mode=block
|
1096
|
-
X-Content-Type-Options:
|
1097
|
-
- nosniff
|
1098
|
-
X-Ua-Compatible:
|
1099
|
-
- chrome=1
|
1100
|
-
Content-Type:
|
1101
|
-
- application/json; charset=utf-8
|
1102
|
-
Etag:
|
1103
|
-
- '"8d5110908a01da06973e28cf8a74a410"'
|
1104
|
-
Cache-Control:
|
1105
|
-
- max-age=0, private, must-revalidate
|
1106
|
-
X-Request-Id:
|
1107
|
-
- 23477ba6-6a1a-4e89-8847-a60103ff7a48
|
1108
|
-
X-Runtime:
|
1109
|
-
- '0.009234'
|
1110
|
-
Server:
|
1111
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
1112
|
-
Date:
|
1113
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
1114
|
-
Content-Length:
|
1115
|
-
- '275'
|
1116
|
-
Connection:
|
1117
|
-
- Keep-Alive
|
1118
|
-
body:
|
1119
|
-
encoding: UTF-8
|
1120
|
-
string: |-
|
1121
|
-
{
|
1122
|
-
"id": 223,
|
1123
|
-
"external_user_id": 42,
|
1124
|
-
"token": "18719e066be2c3fed7aaff620736e9971b44fe9ae7972fc6dbb07dc76a5eb14d8ea12b1a123120c726824eea390588af5b6f1255ee7ab5eed99faeb05f4a6e1b",
|
1125
|
-
"_links": {
|
1126
|
-
"self": {
|
1127
|
-
"href": "http://localhost:3000/api/users/223"
|
1128
|
-
}
|
1129
|
-
}
|
1130
|
-
}
|
1131
|
-
http_version:
|
1132
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1133
|
-
- request:
|
1134
|
-
method: get
|
1135
|
-
uri: http://localhost:3000/
|
1136
|
-
body:
|
1137
|
-
encoding: US-ASCII
|
1138
|
-
string: ''
|
1139
|
-
headers:
|
1140
|
-
User-Agent:
|
1141
|
-
- Faraday v0.9.0
|
1142
|
-
Content-Type:
|
1143
|
-
- application/json
|
1144
|
-
Api-Token:
|
1145
|
-
- testing
|
1146
|
-
Accept-Encoding:
|
1147
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
1148
|
-
Accept:
|
1149
|
-
- "*/*"
|
1150
|
-
response:
|
1151
|
-
status:
|
1152
|
-
code: 200
|
1153
|
-
message: 'OK '
|
1154
|
-
headers:
|
1155
|
-
X-Frame-Options:
|
1156
|
-
- SAMEORIGIN
|
1157
|
-
X-Xss-Protection:
|
1158
|
-
- 1; mode=block
|
1159
|
-
X-Content-Type-Options:
|
1160
|
-
- nosniff
|
1161
|
-
X-Ua-Compatible:
|
1162
|
-
- chrome=1
|
1163
|
-
Content-Type:
|
1164
|
-
- application/json; charset=utf-8
|
1165
|
-
Etag:
|
1166
|
-
- '"a723ac88b99a06c255a3384c2d01f4fb"'
|
1167
|
-
Cache-Control:
|
1168
|
-
- max-age=0, private, must-revalidate
|
1169
|
-
X-Request-Id:
|
1170
|
-
- 1d5fc5bc-921f-4d5c-a012-9702b0709b4d
|
1171
|
-
X-Runtime:
|
1172
|
-
- '0.007975'
|
1173
|
-
Server:
|
1174
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
1175
|
-
Date:
|
1176
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
1177
|
-
Content-Length:
|
1178
|
-
- '305'
|
1179
|
-
Connection:
|
1180
|
-
- Keep-Alive
|
1181
|
-
body:
|
1182
|
-
encoding: UTF-8
|
1183
|
-
string: |-
|
1184
|
-
{
|
1185
|
-
"_links": {
|
1186
|
-
"self": {
|
1187
|
-
"href": "http://localhost:3000/api"
|
1188
|
-
},
|
1189
|
-
"surveys": {
|
1190
|
-
"href": "http://localhost:3000/api/surveys"
|
1191
|
-
},
|
1192
|
-
"users": {
|
1193
|
-
"href": "http://localhost:3000/api/users"
|
1194
|
-
},
|
1195
|
-
"questions": {
|
1196
|
-
"href": "http://localhost:3000/api/questions"
|
1197
|
-
}
|
1198
|
-
}
|
1199
|
-
}
|
1200
|
-
http_version:
|
1201
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1202
|
-
- request:
|
1203
|
-
method: post
|
1204
|
-
uri: http://localhost:3000/api/surveys
|
1205
|
-
body:
|
1206
|
-
encoding: UTF-8
|
1207
|
-
string: '{"survey":{"user_id":223}}'
|
1208
|
-
headers:
|
1209
|
-
User-Agent:
|
1210
|
-
- Faraday v0.9.0
|
1211
|
-
Content-Type:
|
1212
|
-
- application/json
|
1213
|
-
Api-Token:
|
1214
|
-
- testing
|
1215
|
-
Accept-Encoding:
|
1216
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
1217
|
-
Accept:
|
1218
|
-
- "*/*"
|
1219
|
-
response:
|
1220
|
-
status:
|
1221
|
-
code: 201
|
1222
|
-
message: 'Created '
|
1223
|
-
headers:
|
1224
|
-
X-Frame-Options:
|
1225
|
-
- SAMEORIGIN
|
1226
|
-
X-Xss-Protection:
|
1227
|
-
- 1; mode=block
|
1228
|
-
X-Content-Type-Options:
|
1229
|
-
- nosniff
|
1230
|
-
X-Ua-Compatible:
|
1231
|
-
- chrome=1
|
1232
|
-
Content-Type:
|
1233
|
-
- application/json; charset=utf-8
|
1234
|
-
Etag:
|
1235
|
-
- '"34deaa0587cec22509be91bf42460372"'
|
1236
|
-
Cache-Control:
|
1237
|
-
- max-age=0, private, must-revalidate
|
1238
|
-
X-Request-Id:
|
1239
|
-
- 3b10a28f-b58f-4b6c-ad48-279da8896e02
|
1240
|
-
X-Runtime:
|
1241
|
-
- '0.012164'
|
1242
|
-
Server:
|
1243
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
1244
|
-
Date:
|
1245
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
1246
|
-
Content-Length:
|
1247
|
-
- '250'
|
1248
|
-
Connection:
|
1249
|
-
- Keep-Alive
|
1250
|
-
body:
|
1251
|
-
encoding: UTF-8
|
1252
|
-
string: |-
|
1253
|
-
{
|
1254
|
-
"id": 167,
|
1255
|
-
"user_id": 223,
|
1256
|
-
"survey_questions": [
|
1257
|
-
|
1258
|
-
],
|
1259
|
-
"_links": {
|
1260
|
-
"self": {
|
1261
|
-
"href": "http://localhost:3000/api/surveys/167"
|
1262
|
-
},
|
1263
|
-
"submit": {
|
1264
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions"
|
1265
|
-
}
|
1266
|
-
}
|
1267
|
-
}
|
1268
|
-
http_version:
|
1269
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1270
|
-
- request:
|
1271
|
-
method: post
|
1272
|
-
uri: http://localhost:3000/api/surveys/167/survey_questions
|
1273
|
-
body:
|
1274
|
-
encoding: UTF-8
|
1275
|
-
string: '{"survey_question":{"question_id":9}}'
|
1276
|
-
headers:
|
1277
|
-
User-Agent:
|
1278
|
-
- Faraday v0.9.0
|
1279
|
-
Content-Type:
|
1280
|
-
- application/json
|
1281
|
-
Api-Token:
|
1282
|
-
- testing
|
1283
|
-
Accept-Encoding:
|
1284
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
1285
|
-
Accept:
|
1286
|
-
- "*/*"
|
1287
|
-
response:
|
1288
|
-
status:
|
1289
|
-
code: 201
|
1290
|
-
message: 'Created '
|
1291
|
-
headers:
|
1292
|
-
X-Frame-Options:
|
1293
|
-
- SAMEORIGIN
|
1294
|
-
X-Xss-Protection:
|
1295
|
-
- 1; mode=block
|
1296
|
-
X-Content-Type-Options:
|
1297
|
-
- nosniff
|
1298
|
-
X-Ua-Compatible:
|
1299
|
-
- chrome=1
|
1300
|
-
Content-Type:
|
1301
|
-
- application/json; charset=utf-8
|
1302
|
-
Etag:
|
1303
|
-
- '"81b7911b48d89ff93403eee19a5c8861"'
|
1304
|
-
Cache-Control:
|
1305
|
-
- max-age=0, private, must-revalidate
|
1306
|
-
X-Request-Id:
|
1307
|
-
- b99b4788-af86-4460-8d3e-f7d69ee7bbdd
|
1308
|
-
X-Runtime:
|
1309
|
-
- '0.017687'
|
1310
|
-
Server:
|
1311
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
1312
|
-
Date:
|
1313
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
1314
|
-
Content-Length:
|
1315
|
-
- '571'
|
1316
|
-
Connection:
|
1317
|
-
- Keep-Alive
|
1318
|
-
body:
|
1319
|
-
encoding: UTF-8
|
1320
|
-
string: |-
|
1321
|
-
{
|
1322
|
-
"id": 562,
|
1323
|
-
"text": "In the past 24 hours, have you engaged in sexual activity with another person?",
|
1324
|
-
"type": "boolean",
|
1325
|
-
"responses": [
|
1326
|
-
"t",
|
1327
|
-
"f"
|
1328
|
-
],
|
1329
|
-
"freeform": false,
|
1330
|
-
"_links": {
|
1331
|
-
"self": {
|
1332
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions/562"
|
1333
|
-
},
|
1334
|
-
"survey": {
|
1335
|
-
"href": "http://localhost:3000/api/surveys/167"
|
1336
|
-
},
|
1337
|
-
"create": {
|
1338
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions"
|
1339
|
-
},
|
1340
|
-
"submit": {
|
1341
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions/562"
|
1342
|
-
}
|
1343
|
-
}
|
1344
|
-
}
|
1345
|
-
http_version:
|
1346
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1347
|
-
- request:
|
1348
|
-
method: get
|
1349
|
-
uri: http://localhost:3000/api/surveys/167
|
1350
|
-
body:
|
1351
|
-
encoding: US-ASCII
|
1352
|
-
string: ''
|
1353
|
-
headers:
|
1354
|
-
User-Agent:
|
1355
|
-
- Faraday v0.9.0
|
1356
|
-
Content-Type:
|
1357
|
-
- application/json
|
1358
|
-
Api-Token:
|
1359
|
-
- testing
|
1360
|
-
Accept-Encoding:
|
1361
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
1362
|
-
Accept:
|
1363
|
-
- "*/*"
|
1364
|
-
response:
|
1365
|
-
status:
|
1366
|
-
code: 200
|
1367
|
-
message: 'OK '
|
1368
|
-
headers:
|
1369
|
-
X-Frame-Options:
|
1370
|
-
- SAMEORIGIN
|
1371
|
-
X-Xss-Protection:
|
1372
|
-
- 1; mode=block
|
1373
|
-
X-Content-Type-Options:
|
1374
|
-
- nosniff
|
1375
|
-
X-Ua-Compatible:
|
1376
|
-
- chrome=1
|
1377
|
-
Content-Type:
|
1378
|
-
- application/json; charset=utf-8
|
1379
|
-
Etag:
|
1380
|
-
- '"d4c2a40e5564a0d9aec43b10b101766b"'
|
1381
|
-
Cache-Control:
|
1382
|
-
- max-age=0, private, must-revalidate
|
1383
|
-
X-Request-Id:
|
1384
|
-
- b29e84e3-021f-4af7-a541-4b6ea1483219
|
1385
|
-
X-Runtime:
|
1386
|
-
- '0.022556'
|
1387
|
-
Server:
|
1388
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
1389
|
-
Date:
|
1390
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
1391
|
-
Content-Length:
|
1392
|
-
- '1013'
|
1393
|
-
Connection:
|
1394
|
-
- Keep-Alive
|
1395
|
-
body:
|
1396
|
-
encoding: UTF-8
|
1397
|
-
string: |-
|
1398
|
-
{
|
1399
|
-
"id": 167,
|
1400
|
-
"user_id": 223,
|
1401
|
-
"survey_questions": [
|
1402
|
-
{
|
1403
|
-
"id": 562,
|
1404
|
-
"text": "In the past 24 hours, have you engaged in sexual activity with another person?",
|
1405
|
-
"type": "boolean",
|
1406
|
-
"responses": [
|
1407
|
-
"t",
|
1408
|
-
"f"
|
1409
|
-
],
|
1410
|
-
"freeform": false,
|
1411
|
-
"_links": {
|
1412
|
-
"self": {
|
1413
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions/562"
|
1414
|
-
},
|
1415
|
-
"survey": {
|
1416
|
-
"href": "http://localhost:3000/api/surveys/167"
|
1417
|
-
},
|
1418
|
-
"create": {
|
1419
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions"
|
1420
|
-
},
|
1421
|
-
"submit": {
|
1422
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions/562"
|
1423
|
-
}
|
1424
|
-
}
|
1425
|
-
}
|
1426
|
-
],
|
1427
|
-
"_links": {
|
1428
|
-
"self": {
|
1429
|
-
"href": "http://localhost:3000/api/surveys/167"
|
1430
|
-
},
|
1431
|
-
"submit": {
|
1432
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions"
|
1433
|
-
},
|
1434
|
-
"next": {
|
1435
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions/562"
|
1436
|
-
}
|
1437
|
-
}
|
1438
|
-
}
|
1439
|
-
http_version:
|
1440
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1441
|
-
- request:
|
1442
|
-
method: put
|
1443
|
-
uri: http://localhost:3000/api/surveys/167/survey_questions/562
|
1444
|
-
body:
|
1445
|
-
encoding: UTF-8
|
1446
|
-
string: '{"id":562,"survey_question":{"answer":"true"}}'
|
1447
|
-
headers:
|
1448
|
-
User-Agent:
|
1449
|
-
- Faraday v0.9.0
|
1450
|
-
Content-Type:
|
1451
|
-
- application/json
|
1452
|
-
Api-Token:
|
1453
|
-
- testing
|
1454
|
-
Accept-Encoding:
|
1455
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
1456
|
-
Accept:
|
1457
|
-
- "*/*"
|
1458
|
-
response:
|
1459
|
-
status:
|
1460
|
-
code: 204
|
1461
|
-
message: 'No Content '
|
1462
|
-
headers:
|
1463
|
-
X-Frame-Options:
|
1464
|
-
- SAMEORIGIN
|
1465
|
-
X-Xss-Protection:
|
1466
|
-
- 1; mode=block
|
1467
|
-
X-Content-Type-Options:
|
1468
|
-
- nosniff
|
1469
|
-
X-Ua-Compatible:
|
1470
|
-
- chrome=1
|
1471
|
-
Cache-Control:
|
1472
|
-
- no-cache
|
1473
|
-
X-Request-Id:
|
1474
|
-
- 41565aee-c7e6-4744-82e6-f99b4248c327
|
1475
|
-
X-Runtime:
|
1476
|
-
- '0.009471'
|
1477
|
-
Server:
|
1478
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
1479
|
-
Date:
|
1480
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
1481
|
-
Connection:
|
1482
|
-
- Keep-Alive
|
1483
|
-
body:
|
1484
|
-
encoding: UTF-8
|
1485
|
-
string: ''
|
1486
|
-
http_version:
|
1487
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1488
|
-
- request:
|
1489
|
-
method: get
|
1490
|
-
uri: http://localhost:3000/api/surveys/167
|
1491
|
-
body:
|
1492
|
-
encoding: US-ASCII
|
1493
|
-
string: ''
|
1494
|
-
headers:
|
1495
|
-
User-Agent:
|
1496
|
-
- Faraday v0.9.0
|
1497
|
-
Content-Type:
|
1498
|
-
- application/json
|
1499
|
-
Api-Token:
|
1500
|
-
- testing
|
1501
|
-
Accept-Encoding:
|
1502
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
1503
|
-
Accept:
|
1504
|
-
- "*/*"
|
1505
|
-
response:
|
1506
|
-
status:
|
1507
|
-
code: 200
|
1508
|
-
message: 'OK '
|
1509
|
-
headers:
|
1510
|
-
X-Frame-Options:
|
1511
|
-
- SAMEORIGIN
|
1512
|
-
X-Xss-Protection:
|
1513
|
-
- 1; mode=block
|
1514
|
-
X-Content-Type-Options:
|
1515
|
-
- nosniff
|
1516
|
-
X-Ua-Compatible:
|
1517
|
-
- chrome=1
|
1518
|
-
Content-Type:
|
1519
|
-
- application/json; charset=utf-8
|
1520
|
-
Etag:
|
1521
|
-
- '"2d1d372409aaedd850435db263fdbd10"'
|
1522
|
-
Cache-Control:
|
1523
|
-
- max-age=0, private, must-revalidate
|
1524
|
-
X-Request-Id:
|
1525
|
-
- 78379415-e81f-4547-9cc4-a28046cb8322
|
1526
|
-
X-Runtime:
|
1527
|
-
- '0.019397'
|
1528
|
-
Server:
|
1529
|
-
- WEBrick/1.3.1 (Ruby/2.1.1/2014-02-24)
|
1530
|
-
Date:
|
1531
|
-
- Sun, 25 May 2014 18:41:15 GMT
|
1532
|
-
Content-Length:
|
1533
|
-
- '941'
|
1534
|
-
Connection:
|
1535
|
-
- Keep-Alive
|
1536
|
-
body:
|
1537
|
-
encoding: UTF-8
|
1538
|
-
string: |-
|
1539
|
-
{
|
1540
|
-
"id": 167,
|
1541
|
-
"user_id": 223,
|
1542
|
-
"survey_questions": [
|
1543
|
-
{
|
1544
|
-
"id": 562,
|
1545
|
-
"text": "In the past 24 hours, have you engaged in sexual activity with another person?",
|
1546
|
-
"type": "boolean",
|
1547
|
-
"responses": [
|
1548
|
-
"t",
|
1549
|
-
"f"
|
1550
|
-
],
|
1551
|
-
"answer": "true",
|
1552
|
-
"freeform": false,
|
1553
|
-
"_links": {
|
1554
|
-
"self": {
|
1555
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions/562"
|
1556
|
-
},
|
1557
|
-
"survey": {
|
1558
|
-
"href": "http://localhost:3000/api/surveys/167"
|
1559
|
-
},
|
1560
|
-
"create": {
|
1561
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions"
|
1562
|
-
},
|
1563
|
-
"submit": {
|
1564
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions/562"
|
1565
|
-
}
|
1566
|
-
}
|
1567
|
-
}
|
1568
|
-
],
|
1569
|
-
"_links": {
|
1570
|
-
"self": {
|
1571
|
-
"href": "http://localhost:3000/api/surveys/167"
|
1572
|
-
},
|
1573
|
-
"submit": {
|
1574
|
-
"href": "http://localhost:3000/api/surveys/167/survey_questions"
|
1575
|
-
}
|
1576
|
-
}
|
1577
|
-
}
|
1578
|
-
http_version:
|
1579
|
-
recorded_at: Sun, 25 May 2014 18:41:15 GMT
|
1580
|
-
recorded_with: VCR 2.6.0
|