poptart 0.0.4 → 0.0.5

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.
@@ -0,0 +1,1792 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://localhost:3000/api/surveys/8/survey_questions
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"survey_question":{"question_id":1}}'
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
+ - '"47cee763923d5661715a63831aea25c1"'
37
+ Cache-Control:
38
+ - max-age=0, private, must-revalidate
39
+ X-Request-Id:
40
+ - eefb2152-bb9b-4241-83f4-09c6004d62dd
41
+ X-Runtime:
42
+ - '0.019126'
43
+ Server:
44
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
45
+ Date:
46
+ - Mon, 08 Sep 2014 12:20:36 GMT
47
+ Content-Length:
48
+ - '181'
49
+ Connection:
50
+ - Keep-Alive
51
+ body:
52
+ encoding: UTF-8
53
+ string: |-
54
+ {
55
+ "id": 37,
56
+ "survey_id": 8,
57
+ "question_id": 1,
58
+ "order_index": null,
59
+ "answer": null,
60
+ "created_at": "2014-09-08T12:20:36.565Z",
61
+ "updated_at": "2014-09-08T12:20:36.565Z"
62
+ }
63
+ http_version:
64
+ recorded_at: Mon, 08 Sep 2014 12:20:36 GMT
65
+ - request:
66
+ method: get
67
+ uri: http://localhost:3000/api/surveys/8
68
+ body:
69
+ encoding: US-ASCII
70
+ string: ''
71
+ headers:
72
+ User-Agent:
73
+ - Faraday v0.9.0
74
+ Content-Type:
75
+ - application/json
76
+ Api-Token:
77
+ - testing
78
+ Accept-Encoding:
79
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
80
+ Accept:
81
+ - "*/*"
82
+ response:
83
+ status:
84
+ code: 200
85
+ message: 'OK '
86
+ headers:
87
+ X-Frame-Options:
88
+ - SAMEORIGIN
89
+ X-Xss-Protection:
90
+ - 1; mode=block
91
+ X-Content-Type-Options:
92
+ - nosniff
93
+ X-Ua-Compatible:
94
+ - chrome=1
95
+ Content-Type:
96
+ - application/json; charset=utf-8
97
+ Etag:
98
+ - '"18963c13657f6b4b35d2f718fca18771"'
99
+ Cache-Control:
100
+ - max-age=0, private, must-revalidate
101
+ X-Request-Id:
102
+ - 33923acb-016d-401b-870e-8b08007b2d10
103
+ X-Runtime:
104
+ - '0.014559'
105
+ Server:
106
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
107
+ Date:
108
+ - Mon, 08 Sep 2014 12:20:36 GMT
109
+ Content-Length:
110
+ - '985'
111
+ Connection:
112
+ - Keep-Alive
113
+ body:
114
+ encoding: UTF-8
115
+ string: |-
116
+ {
117
+ "id": 8,
118
+ "user_id": 2,
119
+ "_links": {
120
+ "self": {
121
+ "href": "http://localhost:3000/api/surveys/8"
122
+ },
123
+ "submit": {
124
+ "href": "http://localhost:3000/api/surveys/8/survey_questions"
125
+ }
126
+ },
127
+ "survey_questions": [
128
+ {
129
+ "id": 37,
130
+ "text": "How hungry or full are you right now?",
131
+ "type": "multiple",
132
+ "responses": [
133
+ "Very hungry",
134
+ "Somewhat hungry",
135
+ "Neither full nor hungry",
136
+ "Somewhat full",
137
+ "Very full"
138
+ ],
139
+ "answer": null,
140
+ "freeform": false,
141
+ "_links": {
142
+ "self": {
143
+ "href": "http://localhost:3000/api/surveys/8/survey_questions/37"
144
+ },
145
+ "survey": {
146
+ "href": "http://localhost:3000/api/surveys/8"
147
+ },
148
+ "create": {
149
+ "href": "http://localhost:3000/api/surveys/8/survey_questions"
150
+ },
151
+ "submit": {
152
+ "href": "http://localhost:3000/api/surveys/8/survey_questions/37"
153
+ }
154
+ }
155
+ }
156
+ ]
157
+ }
158
+ http_version:
159
+ recorded_at: Mon, 08 Sep 2014 12:20:36 GMT
160
+ - request:
161
+ method: post
162
+ uri: http://localhost:3000/api/surveys/9/survey_questions
163
+ body:
164
+ encoding: UTF-8
165
+ string: '{"survey_question":{"question_id":1}}'
166
+ headers:
167
+ User-Agent:
168
+ - Faraday v0.9.0
169
+ Content-Type:
170
+ - application/json
171
+ Api-Token:
172
+ - testing
173
+ Accept-Encoding:
174
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
175
+ Accept:
176
+ - "*/*"
177
+ response:
178
+ status:
179
+ code: 201
180
+ message: 'Created '
181
+ headers:
182
+ X-Frame-Options:
183
+ - SAMEORIGIN
184
+ X-Xss-Protection:
185
+ - 1; mode=block
186
+ X-Content-Type-Options:
187
+ - nosniff
188
+ X-Ua-Compatible:
189
+ - chrome=1
190
+ Content-Type:
191
+ - application/json; charset=utf-8
192
+ Etag:
193
+ - '"527bb910d5a32934ddbeda8fa8cf560b"'
194
+ Cache-Control:
195
+ - max-age=0, private, must-revalidate
196
+ X-Request-Id:
197
+ - 33b9ea34-a751-4251-83b8-d61adc871a1a
198
+ X-Runtime:
199
+ - '0.008805'
200
+ Server:
201
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
202
+ Date:
203
+ - Mon, 08 Sep 2014 12:22:34 GMT
204
+ Content-Length:
205
+ - '181'
206
+ Connection:
207
+ - Keep-Alive
208
+ body:
209
+ encoding: UTF-8
210
+ string: |-
211
+ {
212
+ "id": 38,
213
+ "survey_id": 9,
214
+ "question_id": 1,
215
+ "order_index": null,
216
+ "answer": null,
217
+ "created_at": "2014-09-08T12:22:34.927Z",
218
+ "updated_at": "2014-09-08T12:22:34.927Z"
219
+ }
220
+ http_version:
221
+ recorded_at: Mon, 08 Sep 2014 12:22:34 GMT
222
+ - request:
223
+ method: get
224
+ uri: http://localhost:3000/api/surveys/9
225
+ body:
226
+ encoding: US-ASCII
227
+ string: ''
228
+ headers:
229
+ User-Agent:
230
+ - Faraday v0.9.0
231
+ Content-Type:
232
+ - application/json
233
+ Api-Token:
234
+ - testing
235
+ Accept-Encoding:
236
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
237
+ Accept:
238
+ - "*/*"
239
+ response:
240
+ status:
241
+ code: 200
242
+ message: 'OK '
243
+ headers:
244
+ X-Frame-Options:
245
+ - SAMEORIGIN
246
+ X-Xss-Protection:
247
+ - 1; mode=block
248
+ X-Content-Type-Options:
249
+ - nosniff
250
+ X-Ua-Compatible:
251
+ - chrome=1
252
+ Content-Type:
253
+ - application/json; charset=utf-8
254
+ Etag:
255
+ - '"c9490902af6a8318e4dc7cea3cc919ae"'
256
+ Cache-Control:
257
+ - max-age=0, private, must-revalidate
258
+ X-Request-Id:
259
+ - ae88a786-8d42-4d1a-957a-385174d577a8
260
+ X-Runtime:
261
+ - '0.012090'
262
+ Server:
263
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
264
+ Date:
265
+ - Mon, 08 Sep 2014 12:22:34 GMT
266
+ Content-Length:
267
+ - '985'
268
+ Connection:
269
+ - Keep-Alive
270
+ body:
271
+ encoding: UTF-8
272
+ string: |-
273
+ {
274
+ "id": 9,
275
+ "user_id": 3,
276
+ "_links": {
277
+ "self": {
278
+ "href": "http://localhost:3000/api/surveys/9"
279
+ },
280
+ "submit": {
281
+ "href": "http://localhost:3000/api/surveys/9/survey_questions"
282
+ }
283
+ },
284
+ "survey_questions": [
285
+ {
286
+ "id": 38,
287
+ "text": "How hungry or full are you right now?",
288
+ "type": "multiple",
289
+ "responses": [
290
+ "Very hungry",
291
+ "Somewhat hungry",
292
+ "Neither full nor hungry",
293
+ "Somewhat full",
294
+ "Very full"
295
+ ],
296
+ "answer": null,
297
+ "freeform": false,
298
+ "_links": {
299
+ "self": {
300
+ "href": "http://localhost:3000/api/surveys/9/survey_questions/38"
301
+ },
302
+ "survey": {
303
+ "href": "http://localhost:3000/api/surveys/9"
304
+ },
305
+ "create": {
306
+ "href": "http://localhost:3000/api/surveys/9/survey_questions"
307
+ },
308
+ "submit": {
309
+ "href": "http://localhost:3000/api/surveys/9/survey_questions/38"
310
+ }
311
+ }
312
+ }
313
+ ]
314
+ }
315
+ http_version:
316
+ recorded_at: Mon, 08 Sep 2014 12:22:34 GMT
317
+ - request:
318
+ method: post
319
+ uri: http://localhost:3000/api/surveys/17/survey_questions
320
+ body:
321
+ encoding: UTF-8
322
+ string: '{"survey_question":{"question_id":25}}'
323
+ headers:
324
+ User-Agent:
325
+ - Faraday v0.9.0
326
+ Content-Type:
327
+ - application/json
328
+ Api-Token:
329
+ - testing
330
+ Accept-Encoding:
331
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
332
+ Accept:
333
+ - "*/*"
334
+ response:
335
+ status:
336
+ code: 201
337
+ message: 'Created '
338
+ headers:
339
+ X-Frame-Options:
340
+ - SAMEORIGIN
341
+ X-Xss-Protection:
342
+ - 1; mode=block
343
+ X-Content-Type-Options:
344
+ - nosniff
345
+ X-Ua-Compatible:
346
+ - chrome=1
347
+ Content-Type:
348
+ - application/json; charset=utf-8
349
+ Etag:
350
+ - '"006fdfd6fd4aea8962f873fa8c214307"'
351
+ Cache-Control:
352
+ - max-age=0, private, must-revalidate
353
+ X-Request-Id:
354
+ - a3acd6ea-4d35-4b65-be4c-e716be113511
355
+ X-Runtime:
356
+ - '0.014871'
357
+ Server:
358
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
359
+ Date:
360
+ - Mon, 08 Sep 2014 12:29:08 GMT
361
+ Content-Length:
362
+ - '183'
363
+ Connection:
364
+ - Keep-Alive
365
+ body:
366
+ encoding: UTF-8
367
+ string: |-
368
+ {
369
+ "id": 39,
370
+ "survey_id": 17,
371
+ "question_id": 25,
372
+ "order_index": null,
373
+ "answer": null,
374
+ "created_at": "2014-09-08T12:29:08.541Z",
375
+ "updated_at": "2014-09-08T12:29:08.541Z"
376
+ }
377
+ http_version:
378
+ recorded_at: Mon, 08 Sep 2014 12:29:08 GMT
379
+ - request:
380
+ method: get
381
+ uri: http://localhost:3000/api/surveys/17
382
+ body:
383
+ encoding: US-ASCII
384
+ string: ''
385
+ headers:
386
+ User-Agent:
387
+ - Faraday v0.9.0
388
+ Content-Type:
389
+ - application/json
390
+ Api-Token:
391
+ - testing
392
+ Accept-Encoding:
393
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
394
+ Accept:
395
+ - "*/*"
396
+ response:
397
+ status:
398
+ code: 200
399
+ message: 'OK '
400
+ headers:
401
+ X-Frame-Options:
402
+ - SAMEORIGIN
403
+ X-Xss-Protection:
404
+ - 1; mode=block
405
+ X-Content-Type-Options:
406
+ - nosniff
407
+ X-Ua-Compatible:
408
+ - chrome=1
409
+ Content-Type:
410
+ - application/json; charset=utf-8
411
+ Etag:
412
+ - '"bd9f6a0dc380e6d42691122c07aea718"'
413
+ Cache-Control:
414
+ - max-age=0, private, must-revalidate
415
+ X-Request-Id:
416
+ - 31990064-d19e-46d9-976f-e206b20b7f92
417
+ X-Runtime:
418
+ - '0.013594'
419
+ Server:
420
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
421
+ Date:
422
+ - Mon, 08 Sep 2014 12:29:08 GMT
423
+ Content-Length:
424
+ - '913'
425
+ Connection:
426
+ - Keep-Alive
427
+ body:
428
+ encoding: UTF-8
429
+ string: |-
430
+ {
431
+ "id": 17,
432
+ "user_id": 11,
433
+ "_links": {
434
+ "self": {
435
+ "href": "http://localhost:3000/api/surveys/17"
436
+ },
437
+ "submit": {
438
+ "href": "http://localhost:3000/api/surveys/17/survey_questions"
439
+ }
440
+ },
441
+ "survey_questions": [
442
+ {
443
+ "id": 39,
444
+ "text": "Where are you?",
445
+ "type": "multiple",
446
+ "responses": [
447
+ "At Home",
448
+ "At Work",
449
+ "In a car",
450
+ "Other"
451
+ ],
452
+ "answer": null,
453
+ "freeform": true,
454
+ "_links": {
455
+ "self": {
456
+ "href": "http://localhost:3000/api/surveys/17/survey_questions/39"
457
+ },
458
+ "survey": {
459
+ "href": "http://localhost:3000/api/surveys/17"
460
+ },
461
+ "create": {
462
+ "href": "http://localhost:3000/api/surveys/17/survey_questions"
463
+ },
464
+ "submit": {
465
+ "href": "http://localhost:3000/api/surveys/17/survey_questions/39"
466
+ }
467
+ }
468
+ }
469
+ ]
470
+ }
471
+ http_version:
472
+ recorded_at: Mon, 08 Sep 2014 12:29:08 GMT
473
+ - request:
474
+ method: post
475
+ uri: http://localhost:3000/api/surveys/18/survey_questions
476
+ body:
477
+ encoding: UTF-8
478
+ string: '{"survey_question":{"question_id":25}}'
479
+ headers:
480
+ User-Agent:
481
+ - Faraday v0.9.0
482
+ Content-Type:
483
+ - application/json
484
+ Api-Token:
485
+ - testing
486
+ Accept-Encoding:
487
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
488
+ Accept:
489
+ - "*/*"
490
+ response:
491
+ status:
492
+ code: 201
493
+ message: 'Created '
494
+ headers:
495
+ X-Frame-Options:
496
+ - SAMEORIGIN
497
+ X-Xss-Protection:
498
+ - 1; mode=block
499
+ X-Content-Type-Options:
500
+ - nosniff
501
+ X-Ua-Compatible:
502
+ - chrome=1
503
+ Content-Type:
504
+ - application/json; charset=utf-8
505
+ Etag:
506
+ - '"91171d5a7286a96541eb858de8cecbd6"'
507
+ Cache-Control:
508
+ - max-age=0, private, must-revalidate
509
+ X-Request-Id:
510
+ - e007c580-26b2-41f7-90e3-d82a8597fbc0
511
+ X-Runtime:
512
+ - '0.008435'
513
+ Server:
514
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
515
+ Date:
516
+ - Mon, 08 Sep 2014 12:29:23 GMT
517
+ Content-Length:
518
+ - '183'
519
+ Connection:
520
+ - Keep-Alive
521
+ body:
522
+ encoding: UTF-8
523
+ string: |-
524
+ {
525
+ "id": 40,
526
+ "survey_id": 18,
527
+ "question_id": 25,
528
+ "order_index": null,
529
+ "answer": null,
530
+ "created_at": "2014-09-08T12:29:23.443Z",
531
+ "updated_at": "2014-09-08T12:29:23.443Z"
532
+ }
533
+ http_version:
534
+ recorded_at: Mon, 08 Sep 2014 12:29:23 GMT
535
+ - request:
536
+ method: get
537
+ uri: http://localhost:3000/api/surveys/18
538
+ body:
539
+ encoding: US-ASCII
540
+ string: ''
541
+ headers:
542
+ User-Agent:
543
+ - Faraday v0.9.0
544
+ Content-Type:
545
+ - application/json
546
+ Api-Token:
547
+ - testing
548
+ Accept-Encoding:
549
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
550
+ Accept:
551
+ - "*/*"
552
+ response:
553
+ status:
554
+ code: 200
555
+ message: 'OK '
556
+ headers:
557
+ X-Frame-Options:
558
+ - SAMEORIGIN
559
+ X-Xss-Protection:
560
+ - 1; mode=block
561
+ X-Content-Type-Options:
562
+ - nosniff
563
+ X-Ua-Compatible:
564
+ - chrome=1
565
+ Content-Type:
566
+ - application/json; charset=utf-8
567
+ Etag:
568
+ - '"a12d0c5691827e748f169597cf942b86"'
569
+ Cache-Control:
570
+ - max-age=0, private, must-revalidate
571
+ X-Request-Id:
572
+ - 205be1d6-2846-4d8e-a444-5dad67a9414a
573
+ X-Runtime:
574
+ - '0.010022'
575
+ Server:
576
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
577
+ Date:
578
+ - Mon, 08 Sep 2014 12:29:23 GMT
579
+ Content-Length:
580
+ - '913'
581
+ Connection:
582
+ - Keep-Alive
583
+ body:
584
+ encoding: UTF-8
585
+ string: |-
586
+ {
587
+ "id": 18,
588
+ "user_id": 12,
589
+ "_links": {
590
+ "self": {
591
+ "href": "http://localhost:3000/api/surveys/18"
592
+ },
593
+ "submit": {
594
+ "href": "http://localhost:3000/api/surveys/18/survey_questions"
595
+ }
596
+ },
597
+ "survey_questions": [
598
+ {
599
+ "id": 40,
600
+ "text": "Where are you?",
601
+ "type": "multiple",
602
+ "responses": [
603
+ "At Home",
604
+ "At Work",
605
+ "In a car",
606
+ "Other"
607
+ ],
608
+ "answer": null,
609
+ "freeform": true,
610
+ "_links": {
611
+ "self": {
612
+ "href": "http://localhost:3000/api/surveys/18/survey_questions/40"
613
+ },
614
+ "survey": {
615
+ "href": "http://localhost:3000/api/surveys/18"
616
+ },
617
+ "create": {
618
+ "href": "http://localhost:3000/api/surveys/18/survey_questions"
619
+ },
620
+ "submit": {
621
+ "href": "http://localhost:3000/api/surveys/18/survey_questions/40"
622
+ }
623
+ }
624
+ }
625
+ ]
626
+ }
627
+ http_version:
628
+ recorded_at: Mon, 08 Sep 2014 12:29:23 GMT
629
+ - request:
630
+ method: put
631
+ uri: http://localhost:3000/api/surveys/18/survey_questions/40
632
+ body:
633
+ encoding: UTF-8
634
+ string: '{"id":40,"survey_question":{"answer":"true"}}'
635
+ headers:
636
+ User-Agent:
637
+ - Faraday v0.9.0
638
+ Content-Type:
639
+ - application/json
640
+ Api-Token:
641
+ - testing
642
+ Accept-Encoding:
643
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
644
+ Accept:
645
+ - "*/*"
646
+ response:
647
+ status:
648
+ code: 204
649
+ message: 'No Content '
650
+ headers:
651
+ X-Frame-Options:
652
+ - SAMEORIGIN
653
+ X-Xss-Protection:
654
+ - 1; mode=block
655
+ X-Content-Type-Options:
656
+ - nosniff
657
+ X-Ua-Compatible:
658
+ - chrome=1
659
+ Cache-Control:
660
+ - no-cache
661
+ X-Request-Id:
662
+ - b987ab5a-611f-47e1-9490-7028c8134c60
663
+ X-Runtime:
664
+ - '0.008017'
665
+ Server:
666
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
667
+ Date:
668
+ - Mon, 08 Sep 2014 12:29:23 GMT
669
+ Connection:
670
+ - Keep-Alive
671
+ body:
672
+ encoding: UTF-8
673
+ string: ''
674
+ http_version:
675
+ recorded_at: Mon, 08 Sep 2014 12:29:23 GMT
676
+ - request:
677
+ method: get
678
+ uri: http://localhost:3000/api/surveys/18
679
+ body:
680
+ encoding: US-ASCII
681
+ string: ''
682
+ headers:
683
+ User-Agent:
684
+ - Faraday v0.9.0
685
+ Content-Type:
686
+ - application/json
687
+ Api-Token:
688
+ - testing
689
+ Accept-Encoding:
690
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
691
+ Accept:
692
+ - "*/*"
693
+ response:
694
+ status:
695
+ code: 200
696
+ message: 'OK '
697
+ headers:
698
+ X-Frame-Options:
699
+ - SAMEORIGIN
700
+ X-Xss-Protection:
701
+ - 1; mode=block
702
+ X-Content-Type-Options:
703
+ - nosniff
704
+ X-Ua-Compatible:
705
+ - chrome=1
706
+ Content-Type:
707
+ - application/json; charset=utf-8
708
+ Etag:
709
+ - '"cdd3f822591dc3ee29b18ca8f01b6786"'
710
+ Cache-Control:
711
+ - max-age=0, private, must-revalidate
712
+ X-Request-Id:
713
+ - 263bd492-3339-4f5b-8ce8-cf4872ab58d3
714
+ X-Runtime:
715
+ - '0.009139'
716
+ Server:
717
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
718
+ Date:
719
+ - Mon, 08 Sep 2014 12:29:23 GMT
720
+ Content-Length:
721
+ - '915'
722
+ Connection:
723
+ - Keep-Alive
724
+ body:
725
+ encoding: UTF-8
726
+ string: |-
727
+ {
728
+ "id": 18,
729
+ "user_id": 12,
730
+ "_links": {
731
+ "self": {
732
+ "href": "http://localhost:3000/api/surveys/18"
733
+ },
734
+ "submit": {
735
+ "href": "http://localhost:3000/api/surveys/18/survey_questions"
736
+ }
737
+ },
738
+ "survey_questions": [
739
+ {
740
+ "id": 40,
741
+ "text": "Where are you?",
742
+ "type": "multiple",
743
+ "responses": [
744
+ "At Home",
745
+ "At Work",
746
+ "In a car",
747
+ "Other"
748
+ ],
749
+ "answer": "true",
750
+ "freeform": true,
751
+ "_links": {
752
+ "self": {
753
+ "href": "http://localhost:3000/api/surveys/18/survey_questions/40"
754
+ },
755
+ "survey": {
756
+ "href": "http://localhost:3000/api/surveys/18"
757
+ },
758
+ "create": {
759
+ "href": "http://localhost:3000/api/surveys/18/survey_questions"
760
+ },
761
+ "submit": {
762
+ "href": "http://localhost:3000/api/surveys/18/survey_questions/40"
763
+ }
764
+ }
765
+ }
766
+ ]
767
+ }
768
+ http_version:
769
+ recorded_at: Mon, 08 Sep 2014 12:29:23 GMT
770
+ - request:
771
+ method: get
772
+ uri: http://localhost:3000/
773
+ body:
774
+ encoding: US-ASCII
775
+ string: ''
776
+ headers:
777
+ User-Agent:
778
+ - Faraday v0.9.0
779
+ Content-Type:
780
+ - application/json
781
+ Api-Token:
782
+ - testing
783
+ Accept-Encoding:
784
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
785
+ Accept:
786
+ - "*/*"
787
+ response:
788
+ status:
789
+ code: 200
790
+ message: 'OK '
791
+ headers:
792
+ X-Frame-Options:
793
+ - SAMEORIGIN
794
+ X-Xss-Protection:
795
+ - 1; mode=block
796
+ X-Content-Type-Options:
797
+ - nosniff
798
+ X-Ua-Compatible:
799
+ - chrome=1
800
+ Content-Type:
801
+ - application/json; charset=utf-8
802
+ Etag:
803
+ - '"a723ac88b99a06c255a3384c2d01f4fb"'
804
+ Cache-Control:
805
+ - max-age=0, private, must-revalidate
806
+ X-Request-Id:
807
+ - 858df11d-84d6-4f9a-bb68-998c2d1abb78
808
+ X-Runtime:
809
+ - '0.004584'
810
+ Server:
811
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
812
+ Date:
813
+ - Mon, 08 Sep 2014 12:29:35 GMT
814
+ Content-Length:
815
+ - '305'
816
+ Connection:
817
+ - Keep-Alive
818
+ body:
819
+ encoding: UTF-8
820
+ string: |-
821
+ {
822
+ "_links": {
823
+ "self": {
824
+ "href": "http://localhost:3000/api"
825
+ },
826
+ "surveys": {
827
+ "href": "http://localhost:3000/api/surveys"
828
+ },
829
+ "users": {
830
+ "href": "http://localhost:3000/api/users"
831
+ },
832
+ "questions": {
833
+ "href": "http://localhost:3000/api/questions"
834
+ }
835
+ }
836
+ }
837
+ http_version:
838
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
839
+ - request:
840
+ method: get
841
+ uri: http://localhost:3000/api/questions
842
+ body:
843
+ encoding: US-ASCII
844
+ string: ''
845
+ headers:
846
+ User-Agent:
847
+ - Faraday v0.9.0
848
+ Content-Type:
849
+ - application/json
850
+ Api-Token:
851
+ - testing
852
+ Accept-Encoding:
853
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
854
+ Accept:
855
+ - "*/*"
856
+ response:
857
+ status:
858
+ code: 200
859
+ message: 'OK '
860
+ headers:
861
+ X-Frame-Options:
862
+ - SAMEORIGIN
863
+ X-Xss-Protection:
864
+ - 1; mode=block
865
+ X-Content-Type-Options:
866
+ - nosniff
867
+ X-Ua-Compatible:
868
+ - chrome=1
869
+ Content-Type:
870
+ - application/json; charset=utf-8
871
+ Etag:
872
+ - '"5aab699a4a9070bc0fb494071db80563"'
873
+ Cache-Control:
874
+ - max-age=0, private, must-revalidate
875
+ X-Request-Id:
876
+ - ce6af021-cefd-4a08-9074-40c953c29bc0
877
+ X-Runtime:
878
+ - '0.009082'
879
+ Server:
880
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
881
+ Date:
882
+ - Mon, 08 Sep 2014 12:29:35 GMT
883
+ Content-Length:
884
+ - '7062'
885
+ Connection:
886
+ - Keep-Alive
887
+ body:
888
+ encoding: UTF-8
889
+ string: |-
890
+ [
891
+ {
892
+ "id": 1,
893
+ "question_type": "multiple",
894
+ "text": "How hungry or full are you right now?",
895
+ "responses": [
896
+ "Very hungry",
897
+ "Somewhat hungry",
898
+ "Neither full nor hungry",
899
+ "Somewhat full",
900
+ "Very full"
901
+ ]
902
+ },
903
+ {
904
+ "id": 2,
905
+ "question_type": "time",
906
+ "text": "What time did you wake up this morning?",
907
+ "responses": null
908
+ },
909
+ {
910
+ "id": 3,
911
+ "question_type": "time",
912
+ "text": "What time did you got to sleep last night?",
913
+ "responses": null
914
+ },
915
+ {
916
+ "id": 4,
917
+ "question_type": "multiple",
918
+ "text": "Are you judging or evaluating yourself right now (i.e. at the moment just before you were notified)?",
919
+ "responses": [
920
+ "f",
921
+ "Yes - Negatively",
922
+ "Yes - Neutrally",
923
+ "Yes - Positively"
924
+ ]
925
+ },
926
+ {
927
+ "id": 5,
928
+ "question_type": "range",
929
+ "text": "How well did you sleep last night?",
930
+ "responses": [
931
+ "0",
932
+ "10"
933
+ ]
934
+ },
935
+ {
936
+ "id": 6,
937
+ "question_type": "range",
938
+ "text": "To what extent are you engrossed in what you are doing?",
939
+ "responses": [
940
+ "0",
941
+ "10"
942
+ ]
943
+ },
944
+ {
945
+ "id": 7,
946
+ "question_type": "multiple",
947
+ "text": "Are you judging or evaluating what you are doing right now (i.e. at the moment just before you were notified?)",
948
+ "responses": [
949
+ "f",
950
+ "Yes - Negatively",
951
+ "Yes - Neutrally",
952
+ "Yes - Positively"
953
+ ]
954
+ },
955
+ {
956
+ "id": 8,
957
+ "question_type": "boolean",
958
+ "text": "In the past 24 hours, have you engaged in sexual activity with another person?",
959
+ "responses": [
960
+ "t",
961
+ "f"
962
+ ]
963
+ },
964
+ {
965
+ "id": 9,
966
+ "question_type": "multiple",
967
+ "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?",
968
+ "responses": [
969
+ "0",
970
+ "1",
971
+ "2",
972
+ "3",
973
+ "4",
974
+ "5",
975
+ "6",
976
+ "7",
977
+ "8",
978
+ "9",
979
+ "10"
980
+ ]
981
+ },
982
+ {
983
+ "id": 10,
984
+ "question_type": "boolean",
985
+ "text": "Have you surprised someone with a gift (including small gifts) in the last week?",
986
+ "responses": [
987
+ "t",
988
+ "f"
989
+ ]
990
+ },
991
+ {
992
+ "id": 11,
993
+ "question_type": "multiple",
994
+ "text": "In general, how is your health?",
995
+ "responses": [
996
+ "Excellent",
997
+ "Very Good",
998
+ "Good",
999
+ "Fair",
1000
+ "Poor"
1001
+ ]
1002
+ },
1003
+ {
1004
+ "id": 12,
1005
+ "question_type": "range",
1006
+ "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.",
1007
+ "responses": [
1008
+ "0",
1009
+ "10"
1010
+ ]
1011
+ },
1012
+ {
1013
+ "id": 13,
1014
+ "question_type": "range",
1015
+ "text": "To what extent is what you're doing interesting?",
1016
+ "responses": [
1017
+ "0",
1018
+ "10"
1019
+ ]
1020
+ },
1021
+ {
1022
+ "id": 14,
1023
+ "question_type": "multiple",
1024
+ "text": "On average, how many hours do you work each week?",
1025
+ "responses": [
1026
+ "Less than 5",
1027
+ "5-10",
1028
+ "10-20",
1029
+ "20-30",
1030
+ "30-40",
1031
+ "40-50",
1032
+ "50-60",
1033
+ "60-70",
1034
+ "More than 70"
1035
+ ]
1036
+ },
1037
+ {
1038
+ "id": 15,
1039
+ "question_type": "range",
1040
+ "text": "How do you feel right now?",
1041
+ "responses": [
1042
+ "0",
1043
+ "10"
1044
+ ]
1045
+ },
1046
+ {
1047
+ "id": 16,
1048
+ "question_type": "range",
1049
+ "text": "To what extent do you expect good things to happen in the future?",
1050
+ "responses": [
1051
+ "0",
1052
+ "10"
1053
+ ]
1054
+ },
1055
+ {
1056
+ "id": 17,
1057
+ "question_type": "boolean",
1058
+ "text": "Have you taken any over-the-counter pain medication in the past 24 hours?",
1059
+ "responses": [
1060
+ "t",
1061
+ "f"
1062
+ ]
1063
+ },
1064
+ {
1065
+ "id": 18,
1066
+ "question_type": "range",
1067
+ "text": "To what extent have you procrastinated so far today?",
1068
+ "responses": [
1069
+ "0",
1070
+ "10"
1071
+ ]
1072
+ },
1073
+ {
1074
+ "id": 19,
1075
+ "question_type": "range",
1076
+ "text": "To what extent are you being productive?",
1077
+ "responses": [
1078
+ "0",
1079
+ "10"
1080
+ ]
1081
+ },
1082
+ {
1083
+ "id": 20,
1084
+ "question_type": "multiple",
1085
+ "text": "Who are you talking or interacting with?",
1086
+ "responses": [
1087
+ "Spouse/partner/significant other",
1088
+ "Children",
1089
+ "Parents",
1090
+ "Other relatives",
1091
+ "Friends",
1092
+ "Acquaintances",
1093
+ "Strangers",
1094
+ "Co-workers",
1095
+ "Customers/students",
1096
+ "Boss",
1097
+ "No one"
1098
+ ]
1099
+ },
1100
+ {
1101
+ "id": 30,
1102
+ "question_type": "multiple",
1103
+ "text": "Beyond any work you've already done today, how many additional hours do you expect to work today?",
1104
+ "responses": [
1105
+ "0 (none)",
1106
+ "Less than 1 hour",
1107
+ "1-2 hours",
1108
+ "2-3 hours",
1109
+ "3-4 hours",
1110
+ "4-5 hours",
1111
+ "5-6 hours"
1112
+ ]
1113
+ },
1114
+ {
1115
+ "id": 21,
1116
+ "question_type": "range",
1117
+ "text": "To what extent do you feel accepted by the person/people you are interacting with?",
1118
+ "responses": [
1119
+ "0",
1120
+ "10"
1121
+ ]
1122
+ },
1123
+ {
1124
+ "id": 22,
1125
+ "question_type": "boolean",
1126
+ "text": "Are you alone?",
1127
+ "responses": [
1128
+ "t",
1129
+ "f"
1130
+ ]
1131
+ },
1132
+ {
1133
+ "id": 23,
1134
+ "question_type": "boolean",
1135
+ "text": "Do you want to do what you're doing?",
1136
+ "responses": [
1137
+ "t",
1138
+ "f"
1139
+ ]
1140
+ },
1141
+ {
1142
+ "id": 24,
1143
+ "question_type": "boolean",
1144
+ "text": "Are you talking or interacting with anyone?",
1145
+ "responses": [
1146
+ "t",
1147
+ "f"
1148
+ ]
1149
+ },
1150
+ {
1151
+ "id": 25,
1152
+ "question_type": "multiple",
1153
+ "text": "Where are you?",
1154
+ "responses": [
1155
+ "At Home",
1156
+ "At Work",
1157
+ "In a car",
1158
+ "Other"
1159
+ ]
1160
+ },
1161
+ {
1162
+ "id": 26,
1163
+ "question_type": "multiple",
1164
+ "text": "How many people are you talking or interacting with?",
1165
+ "responses": [
1166
+ "0",
1167
+ "1",
1168
+ "2",
1169
+ "3",
1170
+ "4",
1171
+ "5",
1172
+ "6",
1173
+ "7",
1174
+ "8",
1175
+ "9",
1176
+ "10",
1177
+ "More than 10"
1178
+ ]
1179
+ },
1180
+ {
1181
+ "id": 27,
1182
+ "question_type": "boolean",
1183
+ "text": "Do you have to do what you're doing?",
1184
+ "responses": [
1185
+ "t",
1186
+ "f"
1187
+ ]
1188
+ },
1189
+ {
1190
+ "id": 28,
1191
+ "question_type": "range",
1192
+ "text": "To what extent are you focused on what you are doing?",
1193
+ "responses": [
1194
+ "0",
1195
+ "10"
1196
+ ]
1197
+ },
1198
+ {
1199
+ "id": 29,
1200
+ "question_type": "multiple",
1201
+ "text": "When did you last check Facebook?",
1202
+ "responses": [
1203
+ "Right now",
1204
+ "In the last 5 minutes",
1205
+ "In the last 15 minutes",
1206
+ "In the last 30 minutes",
1207
+ "In the last hour",
1208
+ "1-2 hours ago",
1209
+ "3-5 hours ago",
1210
+ "6-12 hours ago",
1211
+ "24 hours ago",
1212
+ "Don't use facebook"
1213
+ ]
1214
+ },
1215
+ {
1216
+ "id": 31,
1217
+ "question_type": "boolean",
1218
+ "text": "If you could, and it had no negative consequences, would you jump forward in time 24 hours?",
1219
+ "responses": [
1220
+ "t",
1221
+ "f"
1222
+ ]
1223
+ }
1224
+ ]
1225
+ http_version:
1226
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1227
+ - request:
1228
+ method: get
1229
+ uri: http://localhost:3000/
1230
+ body:
1231
+ encoding: US-ASCII
1232
+ string: ''
1233
+ headers:
1234
+ User-Agent:
1235
+ - Faraday v0.9.0
1236
+ Content-Type:
1237
+ - application/json
1238
+ Api-Token:
1239
+ - testing
1240
+ Accept-Encoding:
1241
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
1242
+ Accept:
1243
+ - "*/*"
1244
+ response:
1245
+ status:
1246
+ code: 200
1247
+ message: 'OK '
1248
+ headers:
1249
+ X-Frame-Options:
1250
+ - SAMEORIGIN
1251
+ X-Xss-Protection:
1252
+ - 1; mode=block
1253
+ X-Content-Type-Options:
1254
+ - nosniff
1255
+ X-Ua-Compatible:
1256
+ - chrome=1
1257
+ Content-Type:
1258
+ - application/json; charset=utf-8
1259
+ Etag:
1260
+ - '"a723ac88b99a06c255a3384c2d01f4fb"'
1261
+ Cache-Control:
1262
+ - max-age=0, private, must-revalidate
1263
+ X-Request-Id:
1264
+ - a38b0b33-837c-4244-bfe7-bc37b40d413a
1265
+ X-Runtime:
1266
+ - '0.005069'
1267
+ Server:
1268
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
1269
+ Date:
1270
+ - Mon, 08 Sep 2014 12:29:35 GMT
1271
+ Content-Length:
1272
+ - '305'
1273
+ Connection:
1274
+ - Keep-Alive
1275
+ body:
1276
+ encoding: UTF-8
1277
+ string: |-
1278
+ {
1279
+ "_links": {
1280
+ "self": {
1281
+ "href": "http://localhost:3000/api"
1282
+ },
1283
+ "surveys": {
1284
+ "href": "http://localhost:3000/api/surveys"
1285
+ },
1286
+ "users": {
1287
+ "href": "http://localhost:3000/api/users"
1288
+ },
1289
+ "questions": {
1290
+ "href": "http://localhost:3000/api/questions"
1291
+ }
1292
+ }
1293
+ }
1294
+ http_version:
1295
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1296
+ - request:
1297
+ method: post
1298
+ uri: http://localhost:3000/api/users
1299
+ body:
1300
+ encoding: UTF-8
1301
+ string: '{"user":{"external_user_id":42}}'
1302
+ headers:
1303
+ User-Agent:
1304
+ - Faraday v0.9.0
1305
+ Content-Type:
1306
+ - application/json
1307
+ Api-Token:
1308
+ - testing
1309
+ Accept-Encoding:
1310
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
1311
+ Accept:
1312
+ - "*/*"
1313
+ response:
1314
+ status:
1315
+ code: 201
1316
+ message: 'Created '
1317
+ headers:
1318
+ X-Frame-Options:
1319
+ - SAMEORIGIN
1320
+ X-Xss-Protection:
1321
+ - 1; mode=block
1322
+ X-Content-Type-Options:
1323
+ - nosniff
1324
+ X-Ua-Compatible:
1325
+ - chrome=1
1326
+ Content-Type:
1327
+ - application/json; charset=utf-8
1328
+ Etag:
1329
+ - '"23a5e1f148eaf3b5d0fcd9bd94148550"'
1330
+ Cache-Control:
1331
+ - max-age=0, private, must-revalidate
1332
+ X-Request-Id:
1333
+ - 9733ef3d-5592-450d-a31c-a3b4f8315844
1334
+ X-Runtime:
1335
+ - '0.007873'
1336
+ Server:
1337
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
1338
+ Date:
1339
+ - Mon, 08 Sep 2014 12:29:35 GMT
1340
+ Content-Length:
1341
+ - '130'
1342
+ Connection:
1343
+ - Keep-Alive
1344
+ body:
1345
+ encoding: UTF-8
1346
+ string: |-
1347
+ {
1348
+ "id": 13,
1349
+ "external_user_id": 42,
1350
+ "_links": {
1351
+ "self": {
1352
+ "href": "http://localhost:3000/api/users/13"
1353
+ }
1354
+ }
1355
+ }
1356
+ http_version:
1357
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1358
+ - request:
1359
+ method: get
1360
+ uri: http://localhost:3000/
1361
+ body:
1362
+ encoding: US-ASCII
1363
+ string: ''
1364
+ headers:
1365
+ User-Agent:
1366
+ - Faraday v0.9.0
1367
+ Content-Type:
1368
+ - application/json
1369
+ Api-Token:
1370
+ - testing
1371
+ Accept-Encoding:
1372
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
1373
+ Accept:
1374
+ - "*/*"
1375
+ response:
1376
+ status:
1377
+ code: 200
1378
+ message: 'OK '
1379
+ headers:
1380
+ X-Frame-Options:
1381
+ - SAMEORIGIN
1382
+ X-Xss-Protection:
1383
+ - 1; mode=block
1384
+ X-Content-Type-Options:
1385
+ - nosniff
1386
+ X-Ua-Compatible:
1387
+ - chrome=1
1388
+ Content-Type:
1389
+ - application/json; charset=utf-8
1390
+ Etag:
1391
+ - '"a723ac88b99a06c255a3384c2d01f4fb"'
1392
+ Cache-Control:
1393
+ - max-age=0, private, must-revalidate
1394
+ X-Request-Id:
1395
+ - 8e63802d-1c1f-4259-ab4a-6125e9acda23
1396
+ X-Runtime:
1397
+ - '0.006548'
1398
+ Server:
1399
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
1400
+ Date:
1401
+ - Mon, 08 Sep 2014 12:29:35 GMT
1402
+ Content-Length:
1403
+ - '305'
1404
+ Connection:
1405
+ - Keep-Alive
1406
+ body:
1407
+ encoding: UTF-8
1408
+ string: |-
1409
+ {
1410
+ "_links": {
1411
+ "self": {
1412
+ "href": "http://localhost:3000/api"
1413
+ },
1414
+ "surveys": {
1415
+ "href": "http://localhost:3000/api/surveys"
1416
+ },
1417
+ "users": {
1418
+ "href": "http://localhost:3000/api/users"
1419
+ },
1420
+ "questions": {
1421
+ "href": "http://localhost:3000/api/questions"
1422
+ }
1423
+ }
1424
+ }
1425
+ http_version:
1426
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1427
+ - request:
1428
+ method: post
1429
+ uri: http://localhost:3000/api/surveys
1430
+ body:
1431
+ encoding: UTF-8
1432
+ string: '{"survey":{"user_id":13}}'
1433
+ headers:
1434
+ User-Agent:
1435
+ - Faraday v0.9.0
1436
+ Content-Type:
1437
+ - application/json
1438
+ Api-Token:
1439
+ - testing
1440
+ Accept-Encoding:
1441
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
1442
+ Accept:
1443
+ - "*/*"
1444
+ response:
1445
+ status:
1446
+ code: 201
1447
+ message: 'Created '
1448
+ headers:
1449
+ X-Frame-Options:
1450
+ - SAMEORIGIN
1451
+ X-Xss-Protection:
1452
+ - 1; mode=block
1453
+ X-Content-Type-Options:
1454
+ - nosniff
1455
+ X-Ua-Compatible:
1456
+ - chrome=1
1457
+ Content-Type:
1458
+ - application/json; charset=utf-8
1459
+ Etag:
1460
+ - '"d26ffed5fb61119a8e003a7885856bc9"'
1461
+ Cache-Control:
1462
+ - max-age=0, private, must-revalidate
1463
+ X-Request-Id:
1464
+ - eb83ac25-a489-4931-983c-cf58670089a6
1465
+ X-Runtime:
1466
+ - '0.008453'
1467
+ Server:
1468
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
1469
+ Date:
1470
+ - Mon, 08 Sep 2014 12:29:35 GMT
1471
+ Content-Length:
1472
+ - '246'
1473
+ Connection:
1474
+ - Keep-Alive
1475
+ body:
1476
+ encoding: UTF-8
1477
+ string: |-
1478
+ {
1479
+ "id": 19,
1480
+ "user_id": 13,
1481
+ "_links": {
1482
+ "self": {
1483
+ "href": "http://localhost:3000/api/surveys/19"
1484
+ },
1485
+ "submit": {
1486
+ "href": "http://localhost:3000/api/surveys/19/survey_questions"
1487
+ }
1488
+ },
1489
+ "survey_questions": [
1490
+
1491
+ ]
1492
+ }
1493
+ http_version:
1494
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1495
+ - request:
1496
+ method: post
1497
+ uri: http://localhost:3000/api/surveys/19/survey_questions
1498
+ body:
1499
+ encoding: UTF-8
1500
+ string: '{"survey_question":{"question_id":25}}'
1501
+ headers:
1502
+ User-Agent:
1503
+ - Faraday v0.9.0
1504
+ Content-Type:
1505
+ - application/json
1506
+ Api-Token:
1507
+ - testing
1508
+ Accept-Encoding:
1509
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
1510
+ Accept:
1511
+ - "*/*"
1512
+ response:
1513
+ status:
1514
+ code: 201
1515
+ message: 'Created '
1516
+ headers:
1517
+ X-Frame-Options:
1518
+ - SAMEORIGIN
1519
+ X-Xss-Protection:
1520
+ - 1; mode=block
1521
+ X-Content-Type-Options:
1522
+ - nosniff
1523
+ X-Ua-Compatible:
1524
+ - chrome=1
1525
+ Content-Type:
1526
+ - application/json; charset=utf-8
1527
+ Etag:
1528
+ - '"b31005b78acc1fbad6c06e6c799f4b65"'
1529
+ Cache-Control:
1530
+ - max-age=0, private, must-revalidate
1531
+ X-Request-Id:
1532
+ - 6713918f-61dc-4046-8cee-af1726c1128b
1533
+ X-Runtime:
1534
+ - '0.008351'
1535
+ Server:
1536
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
1537
+ Date:
1538
+ - Mon, 08 Sep 2014 12:29:35 GMT
1539
+ Content-Length:
1540
+ - '183'
1541
+ Connection:
1542
+ - Keep-Alive
1543
+ body:
1544
+ encoding: UTF-8
1545
+ string: |-
1546
+ {
1547
+ "id": 41,
1548
+ "survey_id": 19,
1549
+ "question_id": 25,
1550
+ "order_index": null,
1551
+ "answer": null,
1552
+ "created_at": "2014-09-08T12:29:35.671Z",
1553
+ "updated_at": "2014-09-08T12:29:35.671Z"
1554
+ }
1555
+ http_version:
1556
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1557
+ - request:
1558
+ method: get
1559
+ uri: http://localhost:3000/api/surveys/19
1560
+ body:
1561
+ encoding: US-ASCII
1562
+ string: ''
1563
+ headers:
1564
+ User-Agent:
1565
+ - Faraday v0.9.0
1566
+ Content-Type:
1567
+ - application/json
1568
+ Api-Token:
1569
+ - testing
1570
+ Accept-Encoding:
1571
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
1572
+ Accept:
1573
+ - "*/*"
1574
+ response:
1575
+ status:
1576
+ code: 200
1577
+ message: 'OK '
1578
+ headers:
1579
+ X-Frame-Options:
1580
+ - SAMEORIGIN
1581
+ X-Xss-Protection:
1582
+ - 1; mode=block
1583
+ X-Content-Type-Options:
1584
+ - nosniff
1585
+ X-Ua-Compatible:
1586
+ - chrome=1
1587
+ Content-Type:
1588
+ - application/json; charset=utf-8
1589
+ Etag:
1590
+ - '"4166397ee513b6d4a4d864e4d9f0fb68"'
1591
+ Cache-Control:
1592
+ - max-age=0, private, must-revalidate
1593
+ X-Request-Id:
1594
+ - 266d84fc-48fe-474a-a56e-aafe6547d152
1595
+ X-Runtime:
1596
+ - '0.009675'
1597
+ Server:
1598
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
1599
+ Date:
1600
+ - Mon, 08 Sep 2014 12:29:35 GMT
1601
+ Content-Length:
1602
+ - '913'
1603
+ Connection:
1604
+ - Keep-Alive
1605
+ body:
1606
+ encoding: UTF-8
1607
+ string: |-
1608
+ {
1609
+ "id": 19,
1610
+ "user_id": 13,
1611
+ "_links": {
1612
+ "self": {
1613
+ "href": "http://localhost:3000/api/surveys/19"
1614
+ },
1615
+ "submit": {
1616
+ "href": "http://localhost:3000/api/surveys/19/survey_questions"
1617
+ }
1618
+ },
1619
+ "survey_questions": [
1620
+ {
1621
+ "id": 41,
1622
+ "text": "Where are you?",
1623
+ "type": "multiple",
1624
+ "responses": [
1625
+ "At Home",
1626
+ "At Work",
1627
+ "In a car",
1628
+ "Other"
1629
+ ],
1630
+ "answer": null,
1631
+ "freeform": true,
1632
+ "_links": {
1633
+ "self": {
1634
+ "href": "http://localhost:3000/api/surveys/19/survey_questions/41"
1635
+ },
1636
+ "survey": {
1637
+ "href": "http://localhost:3000/api/surveys/19"
1638
+ },
1639
+ "create": {
1640
+ "href": "http://localhost:3000/api/surveys/19/survey_questions"
1641
+ },
1642
+ "submit": {
1643
+ "href": "http://localhost:3000/api/surveys/19/survey_questions/41"
1644
+ }
1645
+ }
1646
+ }
1647
+ ]
1648
+ }
1649
+ http_version:
1650
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1651
+ - request:
1652
+ method: put
1653
+ uri: http://localhost:3000/api/surveys/19/survey_questions/41
1654
+ body:
1655
+ encoding: UTF-8
1656
+ string: '{"id":41,"survey_question":{"answer":"At Home"}}'
1657
+ headers:
1658
+ User-Agent:
1659
+ - Faraday v0.9.0
1660
+ Content-Type:
1661
+ - application/json
1662
+ Api-Token:
1663
+ - testing
1664
+ Accept-Encoding:
1665
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
1666
+ Accept:
1667
+ - "*/*"
1668
+ response:
1669
+ status:
1670
+ code: 204
1671
+ message: 'No Content '
1672
+ headers:
1673
+ X-Frame-Options:
1674
+ - SAMEORIGIN
1675
+ X-Xss-Protection:
1676
+ - 1; mode=block
1677
+ X-Content-Type-Options:
1678
+ - nosniff
1679
+ X-Ua-Compatible:
1680
+ - chrome=1
1681
+ Cache-Control:
1682
+ - no-cache
1683
+ X-Request-Id:
1684
+ - c60ebedc-7aa7-4f76-b7f5-5f7e8b9a05bc
1685
+ X-Runtime:
1686
+ - '0.007712'
1687
+ Server:
1688
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
1689
+ Date:
1690
+ - Mon, 08 Sep 2014 12:29:35 GMT
1691
+ Connection:
1692
+ - Keep-Alive
1693
+ body:
1694
+ encoding: UTF-8
1695
+ string: ''
1696
+ http_version:
1697
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1698
+ - request:
1699
+ method: get
1700
+ uri: http://localhost:3000/api/surveys/19
1701
+ body:
1702
+ encoding: US-ASCII
1703
+ string: ''
1704
+ headers:
1705
+ User-Agent:
1706
+ - Faraday v0.9.0
1707
+ Content-Type:
1708
+ - application/json
1709
+ Api-Token:
1710
+ - testing
1711
+ Accept-Encoding:
1712
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
1713
+ Accept:
1714
+ - "*/*"
1715
+ response:
1716
+ status:
1717
+ code: 200
1718
+ message: 'OK '
1719
+ headers:
1720
+ X-Frame-Options:
1721
+ - SAMEORIGIN
1722
+ X-Xss-Protection:
1723
+ - 1; mode=block
1724
+ X-Content-Type-Options:
1725
+ - nosniff
1726
+ X-Ua-Compatible:
1727
+ - chrome=1
1728
+ Content-Type:
1729
+ - application/json; charset=utf-8
1730
+ Etag:
1731
+ - '"ca635284eef5bd98e104ea00a480ac52"'
1732
+ Cache-Control:
1733
+ - max-age=0, private, must-revalidate
1734
+ X-Request-Id:
1735
+ - 114412e4-7dfa-4638-a89f-88e37c487bd0
1736
+ X-Runtime:
1737
+ - '0.014204'
1738
+ Server:
1739
+ - WEBrick/1.3.1 (Ruby/2.1.2/2014-05-08)
1740
+ Date:
1741
+ - Mon, 08 Sep 2014 12:29:35 GMT
1742
+ Content-Length:
1743
+ - '918'
1744
+ Connection:
1745
+ - Keep-Alive
1746
+ body:
1747
+ encoding: UTF-8
1748
+ string: |-
1749
+ {
1750
+ "id": 19,
1751
+ "user_id": 13,
1752
+ "_links": {
1753
+ "self": {
1754
+ "href": "http://localhost:3000/api/surveys/19"
1755
+ },
1756
+ "submit": {
1757
+ "href": "http://localhost:3000/api/surveys/19/survey_questions"
1758
+ }
1759
+ },
1760
+ "survey_questions": [
1761
+ {
1762
+ "id": 41,
1763
+ "text": "Where are you?",
1764
+ "type": "multiple",
1765
+ "responses": [
1766
+ "At Home",
1767
+ "At Work",
1768
+ "In a car",
1769
+ "Other"
1770
+ ],
1771
+ "answer": "At Home",
1772
+ "freeform": true,
1773
+ "_links": {
1774
+ "self": {
1775
+ "href": "http://localhost:3000/api/surveys/19/survey_questions/41"
1776
+ },
1777
+ "survey": {
1778
+ "href": "http://localhost:3000/api/surveys/19"
1779
+ },
1780
+ "create": {
1781
+ "href": "http://localhost:3000/api/surveys/19/survey_questions"
1782
+ },
1783
+ "submit": {
1784
+ "href": "http://localhost:3000/api/surveys/19/survey_questions/41"
1785
+ }
1786
+ }
1787
+ }
1788
+ ]
1789
+ }
1790
+ http_version:
1791
+ recorded_at: Mon, 08 Sep 2014 12:29:35 GMT
1792
+ recorded_with: VCR 2.6.0