quicktravel_client 1.0.2

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.
Files changed (104) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +25 -0
  3. data/.rspec +2 -0
  4. data/.rubocop.yml +13 -0
  5. data/.ruby-version +1 -0
  6. data/.travis.yml +18 -0
  7. data/Gemfile +5 -0
  8. data/LICENSE +22 -0
  9. data/README.md +17 -0
  10. data/Rakefile +18 -0
  11. data/bootstrap/boot.rb +4 -0
  12. data/examples/example_config.rb +4 -0
  13. data/examples/login_example.rb +25 -0
  14. data/lib/extensions.rb +12 -0
  15. data/lib/quick_travel/accommodation.rb +72 -0
  16. data/lib/quick_travel/adapter.rb +283 -0
  17. data/lib/quick_travel/adapter_exception.rb +20 -0
  18. data/lib/quick_travel/address.rb +27 -0
  19. data/lib/quick_travel/adjustment.rb +8 -0
  20. data/lib/quick_travel/background_check.rb +9 -0
  21. data/lib/quick_travel/bed_configuration.rb +7 -0
  22. data/lib/quick_travel/bed_requirement.rb +7 -0
  23. data/lib/quick_travel/booking.rb +370 -0
  24. data/lib/quick_travel/cache.rb +38 -0
  25. data/lib/quick_travel/client.rb +8 -0
  26. data/lib/quick_travel/client_type.rb +6 -0
  27. data/lib/quick_travel/config.rb +26 -0
  28. data/lib/quick_travel/connection_error.rb +9 -0
  29. data/lib/quick_travel/constants.rb +16 -0
  30. data/lib/quick_travel/contact.rb +5 -0
  31. data/lib/quick_travel/country.rb +11 -0
  32. data/lib/quick_travel/credit_card.rb +12 -0
  33. data/lib/quick_travel/discounts/booking_discount.rb +18 -0
  34. data/lib/quick_travel/discounts/discount.rb +21 -0
  35. data/lib/quick_travel/discounts/discount_tree.rb +35 -0
  36. data/lib/quick_travel/discounts.rb +3 -0
  37. data/lib/quick_travel/document.rb +20 -0
  38. data/lib/quick_travel/document_group.rb +14 -0
  39. data/lib/quick_travel/encrypt.rb +13 -0
  40. data/lib/quick_travel/graphic.rb +18 -0
  41. data/lib/quick_travel/init_from_hash.rb +16 -0
  42. data/lib/quick_travel/location.rb +14 -0
  43. data/lib/quick_travel/mock.rb +41 -0
  44. data/lib/quick_travel/party.rb +49 -0
  45. data/lib/quick_travel/passenger.rb +7 -0
  46. data/lib/quick_travel/passenger_price_break.rb +8 -0
  47. data/lib/quick_travel/passenger_type.rb +21 -0
  48. data/lib/quick_travel/payment.rb +41 -0
  49. data/lib/quick_travel/payment_type.rb +37 -0
  50. data/lib/quick_travel/price.rb +14 -0
  51. data/lib/quick_travel/product.rb +165 -0
  52. data/lib/quick_travel/product_configuration.rb +134 -0
  53. data/lib/quick_travel/product_passenger_search_criteria.rb +28 -0
  54. data/lib/quick_travel/product_type.rb +28 -0
  55. data/lib/quick_travel/property.rb +99 -0
  56. data/lib/quick_travel/property_facility.rb +7 -0
  57. data/lib/quick_travel/property_type.rb +20 -0
  58. data/lib/quick_travel/region.rb +21 -0
  59. data/lib/quick_travel/reservation.rb +110 -0
  60. data/lib/quick_travel/resource.rb +50 -0
  61. data/lib/quick_travel/room_facility.rb +7 -0
  62. data/lib/quick_travel/route.rb +81 -0
  63. data/lib/quick_travel/route_stop.rb +7 -0
  64. data/lib/quick_travel/search.rb +14 -0
  65. data/lib/quick_travel/service.rb +5 -0
  66. data/lib/quick_travel/trip.rb +8 -0
  67. data/lib/quick_travel/vehicle.rb +17 -0
  68. data/lib/quick_travel/vehicle_type.rb +11 -0
  69. data/lib/quick_travel/version.rb +3 -0
  70. data/lib/quick_travel.rb +59 -0
  71. data/lib/quicktravel_client.rb +1 -0
  72. data/quicktravel_client.gemspec +37 -0
  73. data/spec/booking_spec.rb +107 -0
  74. data/spec/country_spec.rb +18 -0
  75. data/spec/credit_card_spec.rb +11 -0
  76. data/spec/discounts_spec.rb +121 -0
  77. data/spec/passenger_type_spec.rb +32 -0
  78. data/spec/payment_type_spec.rb +18 -0
  79. data/spec/product_spec.rb +82 -0
  80. data/spec/region_spec.rb +29 -0
  81. data/spec/reservation_spec.rb +50 -0
  82. data/spec/resource_spec.rb +22 -0
  83. data/spec/spec_helper.rb +77 -0
  84. data/spec/support/cassettes/booking_create.yml +50 -0
  85. data/spec/support/cassettes/booking_create_legacy.yml +50 -0
  86. data/spec/support/cassettes/booking_discounts.yml +53 -0
  87. data/spec/support/cassettes/booking_documents.yml +48 -0
  88. data/spec/support/cassettes/booking_show.yml +49 -0
  89. data/spec/support/cassettes/booking_update.yml +94 -0
  90. data/spec/support/cassettes/booking_with_discounts.yml +72 -0
  91. data/spec/support/cassettes/booking_with_documents.yml +117 -0
  92. data/spec/support/cassettes/booking_with_nested_attributes.yml +187 -0
  93. data/spec/support/cassettes/country_all.yml +127 -0
  94. data/spec/support/cassettes/create_reservation_fail.yml +47 -0
  95. data/spec/support/cassettes/create_reservation_with_booking.yml +53 -0
  96. data/spec/support/cassettes/passenger_all.yml +48 -0
  97. data/spec/support/cassettes/product_date_range_bookability.yml +118 -0
  98. data/spec/support/cassettes/product_show.yml +52 -0
  99. data/spec/support/cassettes/region_index.yml +48 -0
  100. data/spec/support/cassettes/region_show.yml +48 -0
  101. data/spec/support/cassettes/reservation_with_extra_picks.yml +165 -0
  102. data/spec/support/cassettes/resource_fare_bases.yml +97 -0
  103. data/spec/support/cassettes/resource_show.yml +50 -0
  104. metadata +421 -0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://0.0.0.0:8080/passenger_types.json?
6
+ body:
7
+ encoding: US-ASCII
8
+ string: access_key=<QT_KEY>
9
+ headers:
10
+ content-length:
11
+ - '0'
12
+ response:
13
+ status:
14
+ code: 200
15
+ message: ! 'OK '
16
+ headers:
17
+ p3p:
18
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ x-ua-compatible:
22
+ - IE=Edge,chrome=1
23
+ etag:
24
+ - ! '"9a626d0671a91ec1f177c50925f2d74a"'
25
+ cache-control:
26
+ - max-age=0, private, must-revalidate
27
+ x-request-id:
28
+ - dc992b62dc7de0631c1dd146a6458d2b
29
+ x-runtime:
30
+ - '0.021192'
31
+ date:
32
+ - Thu, 28 Feb 2013 14:22:17 GMT
33
+ x-rack-cache:
34
+ - miss
35
+ server:
36
+ - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
+ content-length:
38
+ - '488'
39
+ connection:
40
+ - close
41
+ set-cookie:
42
+ - _session_id=79bfcc83fe8879e29d3fac1b4d669a9f; path=/; HttpOnly
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '[{"id":1,"name":"Adult","minimum_age":null,"maximum_age":null,"age_range_required":false,"position":1,"default_age":30,"created_at":null,"updated_at":null,"code":"Ad"},{"id":3,"name":"Infant","minimum_age":0,"maximum_age":2,"age_range_required":true,"position":2,"default_age":0,"created_at":null,"updated_at":null,"code":"In"},{"id":2,"name":"Child","minimum_age":3,"maximum_age":14,"age_range_required":true,"position":3,"default_age":3,"created_at":null,"updated_at":null,"code":"Ch"}]'
46
+ http_version: '1.1'
47
+ recorded_at: Thu, 18 Dec 2014 07:39:06 GMT
48
+ recorded_with: VCR 2.9.3
@@ -0,0 +1,118 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://0.0.0.0:8080/api/products/date_range_bookability.json?travel_date=2016-03-01&duration=7&default_pax_type_numbers[1]=1&passenger_type_numbers[1]=2&passenger_type_numbers[2]=1&resource_ids[]=3&resource_ids[]=4&resource_ids[]=6
6
+ body:
7
+ encoding: US-ASCII
8
+ string: access_key=<QT_KEY>
9
+ headers:
10
+ content-length:
11
+ - '0'
12
+ response:
13
+ status:
14
+ code: 200
15
+ message: ! 'OK '
16
+ headers:
17
+ p3p:
18
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ x-ua-compatible:
22
+ - IE=Edge,chrome=1
23
+ etag:
24
+ - ! '"b62d88353d656ffbd977844c49249cbd"'
25
+ cache-control:
26
+ - max-age=0, private, must-revalidate
27
+ x-request-id:
28
+ - 27d67bbdfb4740625ddd39e02668dde7
29
+ x-runtime:
30
+ - '1.535397'
31
+ date:
32
+ - Thu, 28 Feb 2013 13:48:11 GMT
33
+ x-rack-cache:
34
+ - miss
35
+ server:
36
+ - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
+ content-length:
38
+ - '23034'
39
+ connection:
40
+ - close
41
+ set-cookie:
42
+ - _session_id=7028952a6de9d2e6e96caafc21dad8f7; path=/; HttpOnly
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '[{"resource":{"id":6,"name":"Executive Room"},"bookability":{"2016-03-01":{"available":false,"availability_details":{"available":false,"capacity":2,"available_capacity":1,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":0,"price":{"_type":"Money","_value":30000},"pricing_details":{"minimum_price":{"_type":"Money","_value":30000},"minimum_price_with_adjustments":{"_type":"Money","_value":15000},"adjustments_to_apply":[{"description":"50%
46
+ Off","gross":{"_type":"Money","_value":-15000},"gross_in_cents":-15000}],"total_adjustments":{"_type":"Money","_value":-15000},"price_per_pax_type":{"":30000},"minimum_price_in_cents":30000,"minimum_price_with_adjustments_in_cents":15000,"total_adjustments_in_cents":-15000,"adjustments_to_apply_in_cents":[-15000],"applied_rules":["Test
47
+ Discount Hilton"]},"reservation_attributes":{"resource_id":6},"resource_class_name_underscore":"accommodation","product_name_underscore":"accommodation","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Executive
48
+ Room","description":"Hilton Hotel - Executive Room","error_message":"Cannot
49
+ reserve more than 2 passengers in #\u003CResourceService::ConsumerRestrictionChecker:0x0000000e847c00\u003E"},"2016-03-02":{"available":false,"availability_details":{"available":false,"capacity":2,"available_capacity":1,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":0,"price":{"_type":"Money","_value":30000},"pricing_details":{"minimum_price":{"_type":"Money","_value":30000},"minimum_price_with_adjustments":{"_type":"Money","_value":15000},"adjustments_to_apply":[{"description":"50%
50
+ Off","gross":{"_type":"Money","_value":-15000},"gross_in_cents":-15000}],"total_adjustments":{"_type":"Money","_value":-15000},"price_per_pax_type":{"":30000},"minimum_price_in_cents":30000,"minimum_price_with_adjustments_in_cents":15000,"total_adjustments_in_cents":-15000,"adjustments_to_apply_in_cents":[-15000],"applied_rules":["Test
51
+ Discount Hilton"]},"reservation_attributes":{"resource_id":6},"resource_class_name_underscore":"accommodation","product_name_underscore":"accommodation","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Executive
52
+ Room","description":"Hilton Hotel - Executive Room","error_message":"Cannot
53
+ reserve more than 2 passengers in #\u003CResourceService::ConsumerRestrictionChecker:0x00000007dad570\u003E"},"2016-03-03":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":0,"price":{"_type":"Money","_value":30000},"pricing_details":{"minimum_price":{"_type":"Money","_value":30000},"minimum_price_with_adjustments":{"_type":"Money","_value":15000},"adjustments_to_apply":[{"description":"50%
54
+ Off","gross":{"_type":"Money","_value":-15000},"gross_in_cents":-15000}],"total_adjustments":{"_type":"Money","_value":-15000},"price_per_pax_type":{"":30000},"minimum_price_in_cents":30000,"minimum_price_with_adjustments_in_cents":15000,"total_adjustments_in_cents":-15000,"adjustments_to_apply_in_cents":[-15000],"applied_rules":["Test
55
+ Discount Hilton"]},"reservation_attributes":{"resource_id":6},"resource_class_name_underscore":"accommodation","product_name_underscore":"accommodation","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Executive
56
+ Room","description":"Hilton Hotel - Executive Room","error_message":"Cannot
57
+ reserve more than 2 passengers in #\u003CResourceService::ConsumerRestrictionChecker:0x0000000d307b88\u003E"},"2016-03-04":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":0,"price":{"_type":"Money","_value":30000},"pricing_details":{"minimum_price":{"_type":"Money","_value":30000},"minimum_price_with_adjustments":{"_type":"Money","_value":15000},"adjustments_to_apply":[{"description":"50%
58
+ Off","gross":{"_type":"Money","_value":-15000},"gross_in_cents":-15000}],"total_adjustments":{"_type":"Money","_value":-15000},"price_per_pax_type":{"":30000},"minimum_price_in_cents":30000,"minimum_price_with_adjustments_in_cents":15000,"total_adjustments_in_cents":-15000,"adjustments_to_apply_in_cents":[-15000],"applied_rules":["Test
59
+ Discount Hilton"]},"reservation_attributes":{"resource_id":6},"resource_class_name_underscore":"accommodation","product_name_underscore":"accommodation","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Executive
60
+ Room","description":"Hilton Hotel - Executive Room","error_message":"Cannot
61
+ reserve more than 2 passengers in #\u003CResourceService::ConsumerRestrictionChecker:0x0000000e0414c0\u003E"},"2016-03-05":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":0,"price":{"_type":"Money","_value":30000},"pricing_details":{"minimum_price":{"_type":"Money","_value":30000},"minimum_price_with_adjustments":{"_type":"Money","_value":15000},"adjustments_to_apply":[{"description":"50%
62
+ Off","gross":{"_type":"Money","_value":-15000},"gross_in_cents":-15000}],"total_adjustments":{"_type":"Money","_value":-15000},"price_per_pax_type":{"":30000},"minimum_price_in_cents":30000,"minimum_price_with_adjustments_in_cents":15000,"total_adjustments_in_cents":-15000,"adjustments_to_apply_in_cents":[-15000],"applied_rules":["Test
63
+ Discount Hilton"]},"reservation_attributes":{"resource_id":6},"resource_class_name_underscore":"accommodation","product_name_underscore":"accommodation","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Executive
64
+ Room","description":"Hilton Hotel - Executive Room","error_message":"Cannot
65
+ reserve more than 2 passengers in #\u003CResourceService::ConsumerRestrictionChecker:0x0000000e98f7c0\u003E"},"2016-03-06":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":0,"price":{"_type":"Money","_value":30000},"pricing_details":{"minimum_price":{"_type":"Money","_value":30000},"minimum_price_with_adjustments":{"_type":"Money","_value":15000},"adjustments_to_apply":[{"description":"50%
66
+ Off","gross":{"_type":"Money","_value":-15000},"gross_in_cents":-15000}],"total_adjustments":{"_type":"Money","_value":-15000},"price_per_pax_type":{"":30000},"minimum_price_in_cents":30000,"minimum_price_with_adjustments_in_cents":15000,"total_adjustments_in_cents":-15000,"adjustments_to_apply_in_cents":[-15000],"applied_rules":["Test
67
+ Discount Hilton"]},"reservation_attributes":{"resource_id":6},"resource_class_name_underscore":"accommodation","product_name_underscore":"accommodation","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Executive
68
+ Room","description":"Hilton Hotel - Executive Room","error_message":"Cannot
69
+ reserve more than 2 passengers in #\u003CResourceService::ConsumerRestrictionChecker:0x0000000f1ea758\u003E"},"2016-03-07":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":0,"price":{"_type":"Money","_value":30000},"pricing_details":{"minimum_price":{"_type":"Money","_value":30000},"minimum_price_with_adjustments":{"_type":"Money","_value":15000},"adjustments_to_apply":[{"description":"50%
70
+ Off","gross":{"_type":"Money","_value":-15000},"gross_in_cents":-15000}],"total_adjustments":{"_type":"Money","_value":-15000},"price_per_pax_type":{"":30000},"minimum_price_in_cents":30000,"minimum_price_with_adjustments_in_cents":15000,"total_adjustments_in_cents":-15000,"adjustments_to_apply_in_cents":[-15000],"applied_rules":["Test
71
+ Discount Hilton"]},"reservation_attributes":{"resource_id":6},"resource_class_name_underscore":"accommodation","product_name_underscore":"accommodation","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Executive
72
+ Room","description":"Hilton Hotel - Executive Room","error_message":"Cannot
73
+ reserve more than 2 passengers in #\u003CResourceService::ConsumerRestrictionChecker:0x0000000e7d23b0\u003E"}}},{"resource":{"id":3,"name":"QBE
74
+ Travel Insurance - Policy E"},"bookability":{"2016-03-01":{"available":true,"availability_details":{"available":true,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":3000},"adjustments_to_apply":[{"description":"50%
75
+ Off","gross":{"_type":"Money","_value":-3000},"gross_in_cents":-3000}],"total_adjustments":{"_type":"Money","_value":-3000},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":3000,"total_adjustments_in_cents":-3000,"adjustments_to_apply_in_cents":[-3000],"applied_rules":["QBE
76
+ Get Me"]},"reservation_attributes":{"resource_id":3},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"QBE
77
+ Travel Insurance - Policy E","description":"QBE Travel Insurance - Policy
78
+ E","error_message":null},"2016-03-02":{"available":true,"availability_details":{"available":true,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":3000},"adjustments_to_apply":[{"description":"50%
79
+ Off","gross":{"_type":"Money","_value":-3000},"gross_in_cents":-3000}],"total_adjustments":{"_type":"Money","_value":-3000},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":3000,"total_adjustments_in_cents":-3000,"adjustments_to_apply_in_cents":[-3000],"applied_rules":["QBE
80
+ Get Me"]},"reservation_attributes":{"resource_id":3},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"QBE
81
+ Travel Insurance - Policy E","description":"QBE Travel Insurance - Policy
82
+ E","error_message":null},"2016-03-03":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":3000},"adjustments_to_apply":[{"description":"50%
83
+ Off","gross":{"_type":"Money","_value":-3000},"gross_in_cents":-3000}],"total_adjustments":{"_type":"Money","_value":-3000},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":3000,"total_adjustments_in_cents":-3000,"adjustments_to_apply_in_cents":[-3000],"applied_rules":["QBE
84
+ Get Me"]},"reservation_attributes":{"resource_id":3},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"QBE
85
+ Travel Insurance - Policy E","description":"QBE Travel Insurance - Policy
86
+ E","error_message":"No services setup"},"2016-03-04":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":3000},"adjustments_to_apply":[{"description":"50%
87
+ Off","gross":{"_type":"Money","_value":-3000},"gross_in_cents":-3000}],"total_adjustments":{"_type":"Money","_value":-3000},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":3000,"total_adjustments_in_cents":-3000,"adjustments_to_apply_in_cents":[-3000],"applied_rules":["QBE
88
+ Get Me"]},"reservation_attributes":{"resource_id":3},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"QBE
89
+ Travel Insurance - Policy E","description":"QBE Travel Insurance - Policy
90
+ E","error_message":"No services setup"},"2016-03-05":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":3000},"adjustments_to_apply":[{"description":"50%
91
+ Off","gross":{"_type":"Money","_value":-3000},"gross_in_cents":-3000}],"total_adjustments":{"_type":"Money","_value":-3000},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":3000,"total_adjustments_in_cents":-3000,"adjustments_to_apply_in_cents":[-3000],"applied_rules":["QBE
92
+ Get Me"]},"reservation_attributes":{"resource_id":3},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"QBE
93
+ Travel Insurance - Policy E","description":"QBE Travel Insurance - Policy
94
+ E","error_message":"No services setup"},"2016-03-06":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":3000},"adjustments_to_apply":[{"description":"50%
95
+ Off","gross":{"_type":"Money","_value":-3000},"gross_in_cents":-3000}],"total_adjustments":{"_type":"Money","_value":-3000},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":3000,"total_adjustments_in_cents":-3000,"adjustments_to_apply_in_cents":[-3000],"applied_rules":["QBE
96
+ Get Me"]},"reservation_attributes":{"resource_id":3},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"QBE
97
+ Travel Insurance - Policy E","description":"QBE Travel Insurance - Policy
98
+ E","error_message":"No services setup"},"2016-03-07":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":3000},"adjustments_to_apply":[{"description":"50%
99
+ Off","gross":{"_type":"Money","_value":-3000},"gross_in_cents":-3000}],"total_adjustments":{"_type":"Money","_value":-3000},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":3000,"total_adjustments_in_cents":-3000,"adjustments_to_apply_in_cents":[-3000],"applied_rules":["QBE
100
+ Get Me"]},"reservation_attributes":{"resource_id":3},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"QBE
101
+ Travel Insurance - Policy E","description":"QBE Travel Insurance - Policy
102
+ E","error_message":"No services setup"}}},{"resource":{"id":4,"name":"Travel
103
+ Insurance - Declined"},"bookability":{"2016-03-01":{"available":true,"availability_details":{"available":true,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":4},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Travel
104
+ Insurance - Declined","description":"Travel Insurance - Declined","error_message":null},"2016-03-02":{"available":true,"availability_details":{"available":true,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":4},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Travel
105
+ Insurance - Declined","description":"Travel Insurance - Declined","error_message":null},"2016-03-03":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":4},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Travel
106
+ Insurance - Declined","description":"Travel Insurance - Declined","error_message":"No
107
+ services setup"},"2016-03-04":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":4},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Travel
108
+ Insurance - Declined","description":"Travel Insurance - Declined","error_message":"No
109
+ services setup"},"2016-03-05":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":4},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Travel
110
+ Insurance - Declined","description":"Travel Insurance - Declined","error_message":"No
111
+ services setup"},"2016-03-06":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":4},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Travel
112
+ Insurance - Declined","description":"Travel Insurance - Declined","error_message":"No
113
+ services setup"},"2016-03-07":{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":3000,"2":0},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":4},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"selection_name":"Travel
114
+ Insurance - Declined","description":"Travel Insurance - Declined","error_message":"No
115
+ services setup"}}}]'
116
+ http_version: '1.1'
117
+ recorded_at: Fri, 19 Dec 2014 00:10:15 GMT
118
+ recorded_with: VCR 2.9.3
@@ -0,0 +1,52 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://0.0.0.0:8080/api/products/6.json?first_travel_date=2016-03-01&passenger_type_numbers[1]=1&date_range[start_date]=2016-03-01&date_range[end_date]=2016-03-02
6
+ body:
7
+ encoding: US-ASCII
8
+ string: access_key=<QT_KEY>
9
+ headers:
10
+ content-length:
11
+ - '0'
12
+ response:
13
+ status:
14
+ code: 200
15
+ message: ! 'OK '
16
+ headers:
17
+ p3p:
18
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ x-ua-compatible:
22
+ - IE=Edge,chrome=1
23
+ etag:
24
+ - ! '"0523c4af577a1cbb2a0df19e26e34e31"'
25
+ cache-control:
26
+ - max-age=0, private, must-revalidate
27
+ x-request-id:
28
+ - d9d5669b34a7e1e20dd30c76819941a0
29
+ x-runtime:
30
+ - '0.181506'
31
+ date:
32
+ - Thu, 28 Feb 2013 13:41:36 GMT
33
+ x-rack-cache:
34
+ - miss
35
+ server:
36
+ - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
+ content-length:
38
+ - '2927'
39
+ connection:
40
+ - close
41
+ set-cookie:
42
+ - _session_id=62528a0ae9953ba030b851762c88a927; path=/; HttpOnly
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"available":true,"availability_details":{"available":true,"capacity":2,"available_capacity":1,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":0,"price":{"_type":"Money","_value":40000},"pricing_details":{"minimum_price":{"_type":"Money","_value":40000},"minimum_price_with_adjustments":{"_type":"Money","_value":40000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"":40000},"minimum_price_in_cents":40000,"minimum_price_with_adjustments_in_cents":40000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":6},"resource_class_name_underscore":"accommodation","product_name_underscore":"accommodation","image":{"url":"/assets/default-icon.png","desc":""},"extras":[{"available":false,"availability_details":{"available":false,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":6000},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":3},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"extras":[],"selection_name":"QBE
46
+ Travel Insurance - Policy E","description":"QBE Travel Insurance - Policy
47
+ E","error_message":"QBE Travel Insurance - Policy E cannot be booked on www.sealink.com.au"},{"available":true,"availability_details":{"available":true,"capacity":null,"available_capacity":null,"master_capacity":null,"master_available_capacity":null,"unavailable_type":null},"inventory_type":1,"price":{"_type":"Money","_value":6000},"pricing_details":{"minimum_price":{"_type":"Money","_value":6000},"minimum_price_with_adjustments":{"_type":"Money","_value":6000},"adjustments_to_apply":[],"total_adjustments":{"_type":"Money","_value":0},"price_per_pax_type":{"1":6000},"minimum_price_in_cents":6000,"minimum_price_with_adjustments_in_cents":6000,"total_adjustments_in_cents":0,"adjustments_to_apply_in_cents":[],"applied_rules":[]},"reservation_attributes":{"resource_id":4},"resource_class_name_underscore":"insurance","product_name_underscore":"travel_insurance","image":{"url":"/assets/default-icon.png","desc":""},"extras":[],"selection_name":"Travel
48
+ Insurance - Declined","description":"Travel Insurance - Declined","error_message":null}],"selection_name":"Executive
49
+ Room","description":"Hilton Hotel - Executive Room","error_message":null}'
50
+ http_version: '1.1'
51
+ recorded_at: Thu, 18 Dec 2014 08:09:01 GMT
52
+ recorded_with: VCR 2.9.3
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://0.0.0.0:8080/regions.json?
6
+ body:
7
+ encoding: US-ASCII
8
+ string: access_key=<QT_KEY>
9
+ headers:
10
+ content-length:
11
+ - '0'
12
+ response:
13
+ status:
14
+ code: 200
15
+ message: ! 'OK '
16
+ headers:
17
+ p3p:
18
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ x-ua-compatible:
22
+ - IE=Edge,chrome=1
23
+ etag:
24
+ - ! '"a4c8faefeca1cec1ee7134663a0817b7"'
25
+ cache-control:
26
+ - max-age=0, private, must-revalidate
27
+ x-request-id:
28
+ - 958983dcd32b33f7157f7ff616d4d77a
29
+ x-runtime:
30
+ - '0.021027'
31
+ date:
32
+ - Thu, 28 Feb 2013 14:27:23 GMT
33
+ x-rack-cache:
34
+ - miss
35
+ server:
36
+ - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
+ content-length:
38
+ - '47'
39
+ connection:
40
+ - close
41
+ set-cookie:
42
+ - _session_id=943b65a0bca41cbb3f90757a768011a9; path=/; HttpOnly
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '[{"id":2,"name":"Adelaide","location_ids":[1]}]'
46
+ http_version: '1.1'
47
+ recorded_at: Thu, 18 Dec 2014 07:44:13 GMT
48
+ recorded_with: VCR 2.9.3
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://0.0.0.0:8080/regions.json?
6
+ body:
7
+ encoding: US-ASCII
8
+ string: access_key=<QT_KEY>
9
+ headers:
10
+ content-length:
11
+ - '0'
12
+ response:
13
+ status:
14
+ code: 200
15
+ message: ! 'OK '
16
+ headers:
17
+ p3p:
18
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ x-ua-compatible:
22
+ - IE=Edge,chrome=1
23
+ etag:
24
+ - ! '"a4c8faefeca1cec1ee7134663a0817b7"'
25
+ cache-control:
26
+ - max-age=0, private, must-revalidate
27
+ x-request-id:
28
+ - 1dde85b8855d0a8d1cd3c12c383b7cf5
29
+ x-runtime:
30
+ - '0.020357'
31
+ date:
32
+ - Thu, 28 Feb 2013 14:27:23 GMT
33
+ x-rack-cache:
34
+ - miss
35
+ server:
36
+ - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
+ content-length:
38
+ - '47'
39
+ connection:
40
+ - close
41
+ set-cookie:
42
+ - _session_id=507d1450bb15f478a526bde216134374; path=/; HttpOnly
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '[{"id":2,"name":"Adelaide","location_ids":[1]}]'
46
+ http_version: '1.1'
47
+ recorded_at: Thu, 18 Dec 2014 07:44:13 GMT
48
+ recorded_with: VCR 2.9.3
@@ -0,0 +1,165 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://0.0.0.0:8080/api/bookings/1.json?
6
+ body:
7
+ encoding: US-ASCII
8
+ string: access_key=<QT_KEY>
9
+ headers:
10
+ content-length:
11
+ - '0'
12
+ response:
13
+ status:
14
+ code: 200
15
+ message: ! 'OK '
16
+ headers:
17
+ p3p:
18
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
19
+ content-type:
20
+ - application/json; charset=utf-8
21
+ x-ua-compatible:
22
+ - IE=Edge,chrome=1
23
+ etag:
24
+ - ! '"fb23f3c2051044b8e40d91664bfeab4b"'
25
+ cache-control:
26
+ - max-age=0, private, must-revalidate
27
+ x-request-id:
28
+ - f204232612f0aa0e7772629ebe6dee13
29
+ x-runtime:
30
+ - '0.299561'
31
+ date:
32
+ - Thu, 28 Feb 2013 13:37:39 GMT
33
+ x-rack-cache:
34
+ - miss
35
+ server:
36
+ - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
37
+ content-length:
38
+ - '11695'
39
+ connection:
40
+ - close
41
+ set-cookie:
42
+ - _session_id=197594ff19022f808e3746d353940390; path=/; HttpOnly
43
+ body:
44
+ encoding: US-ASCII
45
+ string: ! '{"id":1,"state":"new","reference":"222223","public_comments":null,"internal_comments":null,"customer_contact_name":null,"customer_contact_phone":null,"customer_contact_mobile":null,"customer_contact_email":null,"currency_iso_code":"AUD","country_id":14,"post_code":null,"referral_code_id":1,"total_adjustments_in_cents":0,"pre_adjusted_gross_in_cents":38000,"nett_in_cents":38000,"gross_in_cents":38000,"commission_in_cents":0,"balance_in_cents":38000,"paid_in_cents":0,"surcharge_in_cents":0,"deposit_in_cents":0,"web_site_name":null,"promo_code":null,"insurance_offered":false,"deposit_due_on":{"_type":"Date","_value":"2016-03-01T00:00:00+10:30"},"balance_due_on":{"_type":"Date","_value":"2016-03-01T00:00:00+10:30"},"first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"complete":true,"reason_not_complete":null,"discardable_in":93,"inactivatable_in":43,"notices":{},"deposit_relevant":false,"passenger_ids":[1,2],"vehicle_ids":[],"reservation_ids":[1,3,2],"adjustment_ids":[],"todo_items":[],"confirmation_requests":[],"passengers_attributes":[{"id":1,"title":null,"first_name":null,"last_name":null,"passenger_type_id":1,"age":30,"gender":null,"position":1},{"id":2,"title":null,"first_name":null,"last_name":null,"passenger_type_id":1,"age":30,"gender":null,"position":2}],"vehicles_attributes":[],"reservations_attributes":[{"id":1,"booking_id":1,"description":"A
46
+ basic studio room","comment":"","active":true,"service_ids":[3,4],"resource_id":6,"quantity":null,"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"bed_configuration":"1
47
+ x Double","product_type_id":2,"itinerary_footer":false,"fare_basis_set_id":12,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":6,"pick_up_info":null,"drop_off_info":null,"selection_name":"Hilton
48
+ Hotel: Executive Room","product_name_underscore":"accommodation","resource_class_name_underscore":"accommodation","resource_class_name":"Accommodation","first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"durational":true,"duration":2,"checkout_date":{"_type":"Date","_value":"2016-03-03"},"duration_units":"Nights","date_start_label":"In:","date_end_label":"Out:","accommodation_extra_picks":false,"has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
49
+ Priced as: Rack Rate","gross_including_packaged_item_in_cents":38000,"pre_adjusted_gross_including_packaged_item_in_cents":64000,"gross_in_cents":20000,"pre_adjusted_gross_in_cents":40000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":20000,"sub_items_gross_in_cents":18000,"adjustments_attributes":[{"id":6,"gross_in_cents":-20000,"creator":{"_access_ip":null,"_access_key":null,"_crypted_password":null,"_login":null,"_password":null,"_remember_token":null,"_remember_token_expires_at":null,"_salt":null,"active":true,"age":null,"business_number":null,"business_number_type":null,"created_at":"2013-03-01T00:00:02+10:30","creator_id":null,"currency_iso_code":"AUD","first_name":"administrator","gender":null,"id":1,"internal_staff":true,"internal_subdivision":false,"last_name":"administrator","name":"Administrator
50
+ Administrator","notes":null,"remember_token":null,"remember_token_expires_at":null,"salt":null,"title":null,"updated_at":"2013-03-01T00:00:03+10:30","updator_id":null},"created_at":"2013-03-01T00:40:04+10:30","description":"50%
51
+ Off","adjustable_item_type":"Reservation","adjustable_item_id":1,"automatic":true}],"rules":[{"unique_name":"Test
52
+ Discount Hilton","description":"","display_name":"Test Discount Hilton"}],"package":false,"sub_reservation_depth":0,"sub_reservations_attributes":[{"id":3,"booking_id":1,"description":"You
53
+ have declined Travel Insurance for your booking. If you wish to add Travel
54
+ Insurance to this booking, please contact the SeaLink Travel Group on 13 13
55
+ 01 prior to commencing your travels.","comment":null,"active":true,"service_ids":[7,8],"resource_id":4,"quantity":null,"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"product_type_id":7,"itinerary_footer":true,"fare_basis_set_id":8,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":4,"pick_up_info":null,"drop_off_info":null,"selection_name":"Travel
56
+ Insurance - Declined","product_name_underscore":"travel_insurance","resource_class_name_underscore":"insurance","resource_class_name":"Insurance","first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"durational":true,"duration":2,"duration_units":"Days","date_start_label":"Start
57
+ Date:","date_end_label":"End Date:","has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
58
+ Priced as: Rack Rate","gross_including_packaged_item_in_cents":12000,"pre_adjusted_gross_including_packaged_item_in_cents":12000,"gross_in_cents":12000,"pre_adjusted_gross_in_cents":12000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":8000,"adjustments_attributes":[],"rules":[],"package":false,"sub_reservation_depth":1,"extra_pick":null,"child_resource":true,"pending_confirmation":false,"confirmation_request_fields":["pick_up_information","drop_off_information","vendor_pnr","notes_for_vendor","vendor_staff","note_for_inventory_type_change"],"report_reservation_changes":false,"vendor_pnr":null,"pickup_information":null,"dropoff_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":3,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:17:34+10:30","gross_in_cents":6000,"id":7,"services_deck_division_id":null,"updated_at":"2013-03-01T00:17:34+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":3,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:17:34+10:30","gross_in_cents":6000,"id":8,"services_deck_division_id":null,"updated_at":"2013-03-01T00:17:34+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":6000,"2":6000}},{"id":2,"booking_id":1,"description":"QBE
59
+ Travel Insurance Policy E known as the ''Australian Cancellation and Additional
60
+ Expenses'' plan has been included into this booking. This covers you for defined
61
+ unforeseen cancellations and additional expenses. Please refer to the Product
62
+ Disclosure Statement for further information.","comment":null,"active":true,"service_ids":[5,6],"resource_id":3,"quantity":null,"complete":true,"reason_not_complete":null,"enough_time_before_travel_to_edit":true,"product_type_id":7,"itinerary_footer":true,"fare_basis_set_id":8,"manually_priced":false,"manually_assigned_fare_basis_set":false,"has_fare_basis":true,"fare_basis_season_name":"","fare_basis_pointer_id":4,"pick_up_info":null,"drop_off_info":null,"selection_name":"QBE
63
+ Travel Insurance - Policy E","product_name_underscore":"travel_insurance","resource_class_name_underscore":"insurance","resource_class_name":"Insurance","first_travel_date":{"_type":"Date","_value":"2016-03-01"},"last_travel_date":{"_type":"Date","_value":"2016-03-02"},"durational":true,"duration":2,"duration_units":"Days","date_start_label":"Start
64
+ Date:","date_end_label":"End Date:","has_skipped_reservation_groups":false,"editable_reservation_groups":[],"tariff_level_name":"Auto
65
+ Priced as: Rack Rate","gross_including_packaged_item_in_cents":6000,"pre_adjusted_gross_including_packaged_item_in_cents":12000,"gross_in_cents":6000,"pre_adjusted_gross_in_cents":12000,"pre_adjusted_commission_in_cents":0,"cost_in_cents":8000,"adjustments_attributes":[{"id":5,"gross_in_cents":-6000,"creator":{"_access_ip":null,"_access_key":null,"_crypted_password":null,"_login":null,"_password":null,"_remember_token":null,"_remember_token_expires_at":null,"_salt":null,"active":true,"age":null,"business_number":null,"business_number_type":null,"created_at":"2013-03-01T00:00:02+10:30","creator_id":null,"currency_iso_code":"AUD","first_name":"administrator","gender":null,"id":1,"internal_staff":true,"internal_subdivision":false,"last_name":"administrator","name":"Administrator
66
+ Administrator","notes":null,"remember_token":null,"remember_token_expires_at":null,"salt":null,"title":null,"updated_at":"2013-03-01T00:00:03+10:30","updator_id":null},"created_at":"2013-03-01T00:40:04+10:30","description":"50%
67
+ Off","adjustable_item_type":"Reservation","adjustable_item_id":2,"automatic":true}],"rules":[{"unique_name":"QBE
68
+ Get Me","description":"","display_name":"QBE Get Me"}],"package":false,"sub_reservation_depth":1,"extra_pick":null,"child_resource":true,"pending_confirmation":false,"confirmation_request_fields":["pick_up_information","drop_off_information","vendor_pnr","notes_for_vendor","vendor_staff","note_for_inventory_type_change"],"report_reservation_changes":false,"vendor_pnr":null,"pickup_information":null,"dropoff_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":2,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:11:08+10:30","gross_in_cents":6000,"id":3,"services_deck_division_id":null,"updated_at":"2013-03-01T00:11:08+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":2,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:11:08+10:30","gross_in_cents":6000,"id":4,"services_deck_division_id":null,"updated_at":"2013-03-01T00:11:08+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":3000,"2":3000}}],"extra_pick":null,"child_resource":null,"pending_confirmation":false,"confirmation_request_fields":[],"report_reservation_changes":false,"vendor_pnr":null,"pickup_information":null,"dropoff_information":null,"vendor_staff":null,"notes_for_vendor":null,"passenger_ids":[1,2],"passenger_splits":[{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":1,"consumer_splittable_id":1,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:08:00+10:30","gross_in_cents":0,"id":1,"services_deck_division_id":null,"updated_at":"2013-03-01T00:08:00+10:30"},{"commission_in_cents":0,"commission_percentage":"0.0","consumer_id":2,"consumer_splittable_id":1,"consumer_splittable_type":"Reservation","created_at":"2013-03-01T00:08:00+10:30","gross_in_cents":0,"id":2,"services_deck_division_id":null,"updated_at":"2013-03-01T00:08:00+10:30"}],"vehicle_ids":[],"vehicle_splits":[],"consumer_grosses":{"1":0,"2":0}}],"adjustments_attributes":[],"payments_attributes":[],"payment_types_attributes":[{"id":5,"name":"master","description":"master","payment_method":"credit_card","credit_card_brand":"MasterCard","transaction_fee":"0.0","active":true,"position":2,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true},{"id":4,"name":"visa","description":"visa","payment_method":"credit_card","credit_card_brand":"Visa","transaction_fee":"0.0","active":true,"position":3,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true},{"id":7,"name":"PayPal","description":"Payments
69
+ made via PayPal account","payment_method":"paypal","credit_card_brand":null,"transaction_fee":"0.0","active":true,"position":6,"surchargeable":false,"for_frequent_traveller_redemption":false,"comment_required":false,"external":true}]}'
70
+ http_version: '1.1'
71
+ recorded_at: Thu, 18 Dec 2014 08:05:03 GMT
72
+ - request:
73
+ method: get
74
+ uri: http://0.0.0.0:8080/resources/4.json?
75
+ body:
76
+ encoding: US-ASCII
77
+ string: access_key=<QT_KEY>
78
+ headers:
79
+ content-length:
80
+ - '0'
81
+ response:
82
+ status:
83
+ code: 200
84
+ message: ! 'OK '
85
+ headers:
86
+ p3p:
87
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
88
+ content-type:
89
+ - application/json; charset=utf-8
90
+ x-ua-compatible:
91
+ - IE=Edge,chrome=1
92
+ etag:
93
+ - ! '"cc804dbaa7a14a59bff0d4f48de10f00"'
94
+ cache-control:
95
+ - max-age=0, private, must-revalidate
96
+ x-request-id:
97
+ - 5f1c7db043356a688b03f92a9078b433
98
+ x-runtime:
99
+ - '0.027709'
100
+ date:
101
+ - Thu, 28 Feb 2013 13:37:39 GMT
102
+ x-rack-cache:
103
+ - miss
104
+ server:
105
+ - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
106
+ content-length:
107
+ - '1504'
108
+ connection:
109
+ - close
110
+ set-cookie:
111
+ - _session_id=b8ada5a87c89e12352fee8415b543ec6; path=/; HttpOnly
112
+ body:
113
+ encoding: US-ASCII
114
+ string: ! '{"id":4,"name":"Travel Insurance - Declined","product_type_id":7,"default_capacity":null,"type":"Insurance","inventory_type":1,"maximum_occupancy":null,"location_id":null,"property_id":null,"fare_basis_pointer_id":4,"disclaimer_id":null,"deposit_rule_id":null,"vendor_id":null,"maximum_weight":null,"days_before_inventory_expires":null,"property_type_id":null,"star_rating":null,"booking_notes":"This
115
+ is only to be used if the clients have declined Travel Insurance.","expiry_units":null,"uses":null,"inline_price_in_cents":null,"inline_cost_in_cents":null,"expiry_level":null,"unlimited_uses":false,"no_expiry":false,"reason_required":false,"resource_category_id":null,"created_at":"2014-09-12T17:12:11+09:30","updated_at":"2013-03-01T00:17:12+10:30","code":"","restrict_to_client_types":false,"minimum_age":null,"guardian_minimum_age":null,"book_before_level":null,"book_before_units":"seconds","maximum_passengers_online":null,"active":true,"report_changes":false,"inline_pricing":false,"bookable_individually":true,"minimum_passengers":null,"maximum_passengers":null,"required_number_of_vehicles":null,"frequent_traveller_points_multiplier":null,"commissionable":true,"masterpoint_resource_id":null,"print_tickets":false,"individual_tickets":null,"vehicle_ticket_format_id":null,"passenger_ticket_format_id":null,"reservation_ticket_format_id":null,"frequent_traveller_redemption_rate":null,"client_type_ids":[],"category":null,"location":"","current_description":"","graphics":[],"graphic_names":[]}'
116
+ http_version: '1.1'
117
+ recorded_at: Thu, 18 Dec 2014 08:05:03 GMT
118
+ - request:
119
+ method: get
120
+ uri: http://0.0.0.0:8080/resources/3.json?
121
+ body:
122
+ encoding: US-ASCII
123
+ string: access_key=<QT_KEY>
124
+ headers:
125
+ content-length:
126
+ - '0'
127
+ response:
128
+ status:
129
+ code: 200
130
+ message: ! 'OK '
131
+ headers:
132
+ p3p:
133
+ - CP="IDC DSP CAO COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT"
134
+ content-type:
135
+ - application/json; charset=utf-8
136
+ x-ua-compatible:
137
+ - IE=Edge,chrome=1
138
+ etag:
139
+ - ! '"ca9887606178c2616a3099969524a30d"'
140
+ cache-control:
141
+ - max-age=0, private, must-revalidate
142
+ x-request-id:
143
+ - 16e5a711009ae75b76d9cd08badb1b7b
144
+ x-runtime:
145
+ - '0.031669'
146
+ date:
147
+ - Thu, 28 Feb 2013 13:37:39 GMT
148
+ x-rack-cache:
149
+ - miss
150
+ server:
151
+ - WEBrick/1.3.1 (Ruby/2.1.5/2014-11-13)
152
+ content-length:
153
+ - '1558'
154
+ connection:
155
+ - close
156
+ set-cookie:
157
+ - _session_id=092bffa29d160ebd51267b3f7b7f20b2; path=/; HttpOnly
158
+ body:
159
+ encoding: US-ASCII
160
+ string: ! '{"id":3,"name":"QBE Travel Insurance - Policy E","product_type_id":7,"default_capacity":null,"type":"Insurance","inventory_type":1,"maximum_occupancy":null,"location_id":null,"property_id":null,"fare_basis_pointer_id":4,"disclaimer_id":null,"deposit_rule_id":null,"vendor_id":null,"maximum_weight":null,"days_before_inventory_expires":null,"property_type_id":null,"star_rating":null,"booking_notes":"QBE
161
+ Travel Insurance Policy E covers the clients up to $1000 for defined unforeseen
162
+ cancellations and additional expenses.","expiry_units":null,"uses":null,"inline_price_in_cents":null,"inline_cost_in_cents":null,"expiry_level":null,"unlimited_uses":false,"no_expiry":false,"reason_required":false,"resource_category_id":null,"created_at":"2014-09-12T17:10:47+09:30","updated_at":"2014-09-12T17:10:55+09:30","code":"","restrict_to_client_types":false,"minimum_age":null,"guardian_minimum_age":19,"book_before_level":null,"book_before_units":"seconds","maximum_passengers_online":null,"active":true,"report_changes":false,"inline_pricing":false,"bookable_individually":true,"minimum_passengers":null,"maximum_passengers":null,"required_number_of_vehicles":null,"frequent_traveller_points_multiplier":null,"commissionable":true,"masterpoint_resource_id":null,"print_tickets":false,"individual_tickets":null,"vehicle_ticket_format_id":null,"passenger_ticket_format_id":null,"reservation_ticket_format_id":null,"frequent_traveller_redemption_rate":null,"client_type_ids":[],"category":null,"location":"","current_description":"","graphics":[],"graphic_names":[]}'
163
+ http_version: '1.1'
164
+ recorded_at: Thu, 18 Dec 2014 08:05:03 GMT
165
+ recorded_with: VCR 2.9.3