apimatic-bcd-travel-sdk 0.0.1

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 (233) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +28 -0
  3. data/README.md +180 -0
  4. data/bin/console +15 -0
  5. data/lib/bcd_travel_api/api_helper.rb +10 -0
  6. data/lib/bcd_travel_api/apis/air_api.rb +138 -0
  7. data/lib/bcd_travel_api/apis/air_availability_return_flight_api.rb +31 -0
  8. data/lib/bcd_travel_api/apis/air_fare_search_optional_services_api.rb +31 -0
  9. data/lib/bcd_travel_api/apis/air_fare_search_select_seat_api.rb +53 -0
  10. data/lib/bcd_travel_api/apis/air_fare_search_simple_api.rb +195 -0
  11. data/lib/bcd_travel_api/apis/base_api.rb +67 -0
  12. data/lib/bcd_travel_api/apis/cars_api.rb +563 -0
  13. data/lib/bcd_travel_api/apis/hotels_api.rb +930 -0
  14. data/lib/bcd_travel_api/apis/retrieve_versions_api.rb +32 -0
  15. data/lib/bcd_travel_api/apis/search_expenses_api.rb +88 -0
  16. data/lib/bcd_travel_api/apis/v20_api.rb +72 -0
  17. data/lib/bcd_travel_api/apis/v21_api.rb +535 -0
  18. data/lib/bcd_travel_api/client.rb +136 -0
  19. data/lib/bcd_travel_api/configuration.rb +205 -0
  20. data/lib/bcd_travel_api/exceptions/api_exception.rb +21 -0
  21. data/lib/bcd_travel_api/http/api_response.rb +19 -0
  22. data/lib/bcd_travel_api/http/auth/basic.rb +62 -0
  23. data/lib/bcd_travel_api/http/auth/bearer.rb +53 -0
  24. data/lib/bcd_travel_api/http/http_call_back.rb +10 -0
  25. data/lib/bcd_travel_api/http/http_method_enum.rb +10 -0
  26. data/lib/bcd_travel_api/http/http_request.rb +10 -0
  27. data/lib/bcd_travel_api/http/http_response.rb +10 -0
  28. data/lib/bcd_travel_api/http/proxy_settings.rb +22 -0
  29. data/lib/bcd_travel_api/logging/configuration/api_logging_configuration.rb +186 -0
  30. data/lib/bcd_travel_api/logging/sdk_logger.rb +17 -0
  31. data/lib/bcd_travel_api/models/address.rb +74 -0
  32. data/lib/bcd_travel_api/models/address1.rb +111 -0
  33. data/lib/bcd_travel_api/models/address3.rb +109 -0
  34. data/lib/bcd_travel_api/models/address32.rb +75 -0
  35. data/lib/bcd_travel_api/models/address33.rb +103 -0
  36. data/lib/bcd_travel_api/models/address5.rb +100 -0
  37. data/lib/bcd_travel_api/models/air.rb +108 -0
  38. data/lib/bcd_travel_api/models/air1.rb +108 -0
  39. data/lib/bcd_travel_api/models/air16.rb +100 -0
  40. data/lib/bcd_travel_api/models/air2.rb +108 -0
  41. data/lib/bcd_travel_api/models/airavailabilityrequest.rb +164 -0
  42. data/lib/bcd_travel_api/models/airbookrequest.rb +350 -0
  43. data/lib/bcd_travel_api/models/aircancel_reservation_request4.rb +161 -0
  44. data/lib/bcd_travel_api/models/aircancel_reservationrefundquoteconfirmrequest.rb +164 -0
  45. data/lib/bcd_travel_api/models/aircomplete_verification_request.rb +146 -0
  46. data/lib/bcd_travel_api/models/airdocuments_issue_request.rb +163 -0
  47. data/lib/bcd_travel_api/models/airfare_rules_request.rb +155 -0
  48. data/lib/bcd_travel_api/models/airfare_search_request.rb +243 -0
  49. data/lib/bcd_travel_api/models/airget_checkout_data_request.rb +177 -0
  50. data/lib/bcd_travel_api/models/airpricingavailabilityrequest.rb +222 -0
  51. data/lib/bcd_travel_api/models/airpricingavailabilityrequest1.rb +231 -0
  52. data/lib/bcd_travel_api/models/airpricingfare_searchrequest.rb +214 -0
  53. data/lib/bcd_travel_api/models/airretrieve_reservations_list_request.rb +172 -0
  54. data/lib/bcd_travel_api/models/airseat_map_request.rb +175 -0
  55. data/lib/bcd_travel_api/models/arrival_location.rb +82 -0
  56. data/lib/bcd_travel_api/models/base_fare.rb +91 -0
  57. data/lib/bcd_travel_api/models/base_fare1.rb +119 -0
  58. data/lib/bcd_travel_api/models/base_fare2.rb +91 -0
  59. data/lib/bcd_travel_api/models/base_model.rb +110 -0
  60. data/lib/bcd_travel_api/models/billing_address.rb +110 -0
  61. data/lib/bcd_travel_api/models/booking_data.rb +73 -0
  62. data/lib/bcd_travel_api/models/broker.rb +82 -0
  63. data/lib/bcd_travel_api/models/broker16.rb +82 -0
  64. data/lib/bcd_travel_api/models/car.rb +91 -0
  65. data/lib/bcd_travel_api/models/car1.rb +91 -0
  66. data/lib/bcd_travel_api/models/car16.rb +83 -0
  67. data/lib/bcd_travel_api/models/car2.rb +91 -0
  68. data/lib/bcd_travel_api/models/card_detail.rb +104 -0
  69. data/lib/bcd_travel_api/models/carsbookcardrequest.rb +310 -0
  70. data/lib/bcd_travel_api/models/carsbookguaranteerequest.rb +236 -0
  71. data/lib/bcd_travel_api/models/carsbookvoucherrequest.rb +266 -0
  72. data/lib/bcd_travel_api/models/carscancel_reservation_request1.rb +163 -0
  73. data/lib/bcd_travel_api/models/carsdirect_sell_bookcardrequest.rb +362 -0
  74. data/lib/bcd_travel_api/models/carsdirect_sell_bookno_paymentrequest.rb +307 -0
  75. data/lib/bcd_travel_api/models/carsmodify_reservation_request.rb +215 -0
  76. data/lib/bcd_travel_api/models/carsretrieve_reservations_list_request.rb +172 -0
  77. data/lib/bcd_travel_api/models/client_reportable_datum.rb +82 -0
  78. data/lib/bcd_travel_api/models/content_type.rb +26 -0
  79. data/lib/bcd_travel_api/models/cruise_ferry.rb +91 -0
  80. data/lib/bcd_travel_api/models/departure_location.rb +82 -0
  81. data/lib/bcd_travel_api/models/document.rb +150 -0
  82. data/lib/bcd_travel_api/models/drop_off_location.rb +122 -0
  83. data/lib/bcd_travel_api/models/drop_off_location1.rb +118 -0
  84. data/lib/bcd_travel_api/models/drop_off_location16.rb +83 -0
  85. data/lib/bcd_travel_api/models/drop_off_location2.rb +82 -0
  86. data/lib/bcd_travel_api/models/end_location_address.rb +109 -0
  87. data/lib/bcd_travel_api/models/fare.rb +117 -0
  88. data/lib/bcd_travel_api/models/fare2.rb +119 -0
  89. data/lib/bcd_travel_api/models/fare3.rb +119 -0
  90. data/lib/bcd_travel_api/models/fare5.rb +91 -0
  91. data/lib/bcd_travel_api/models/ff_number.rb +82 -0
  92. data/lib/bcd_travel_api/models/filter.rb +185 -0
  93. data/lib/bcd_travel_api/models/filter1.rb +74 -0
  94. data/lib/bcd_travel_api/models/filter10.rb +74 -0
  95. data/lib/bcd_travel_api/models/filter11.rb +75 -0
  96. data/lib/bcd_travel_api/models/filter12.rb +75 -0
  97. data/lib/bcd_travel_api/models/filter13.rb +74 -0
  98. data/lib/bcd_travel_api/models/filter14.rb +75 -0
  99. data/lib/bcd_travel_api/models/filter15.rb +75 -0
  100. data/lib/bcd_travel_api/models/filter2.rb +74 -0
  101. data/lib/bcd_travel_api/models/filter3.rb +74 -0
  102. data/lib/bcd_travel_api/models/filter4.rb +75 -0
  103. data/lib/bcd_travel_api/models/filter6.rb +75 -0
  104. data/lib/bcd_travel_api/models/filter8.rb +75 -0
  105. data/lib/bcd_travel_api/models/generate_oauth_20_token.rb +91 -0
  106. data/lib/bcd_travel_api/models/get_configurations_post_request.rb +193 -0
  107. data/lib/bcd_travel_api/models/get_versionsbytrip_id.rb +99 -0
  108. data/lib/bcd_travel_api/models/guest.rb +82 -0
  109. data/lib/bcd_travel_api/models/hotel.rb +91 -0
  110. data/lib/bcd_travel_api/models/hotel1.rb +91 -0
  111. data/lib/bcd_travel_api/models/hotel16.rb +83 -0
  112. data/lib/bcd_travel_api/models/hotel2.rb +91 -0
  113. data/lib/bcd_travel_api/models/hotelsbookrequest.rb +418 -0
  114. data/lib/bcd_travel_api/models/hotelsbookrequest1.rb +445 -0
  115. data/lib/bcd_travel_api/models/hotelscancel_reservation_request.rb +153 -0
  116. data/lib/bcd_travel_api/models/hotelsrebookrequest.rb +214 -0
  117. data/lib/bcd_travel_api/models/hotelsrebookrequest1.rb +231 -0
  118. data/lib/bcd_travel_api/models/hotelsupdate_reservation_details_request.rb +153 -0
  119. data/lib/bcd_travel_api/models/hotelsupdate_reservation_details_request1.rb +164 -0
  120. data/lib/bcd_travel_api/models/leg.rb +166 -0
  121. data/lib/bcd_travel_api/models/leg1.rb +168 -0
  122. data/lib/bcd_travel_api/models/leg2.rb +156 -0
  123. data/lib/bcd_travel_api/models/leg3.rb +160 -0
  124. data/lib/bcd_travel_api/models/leg33.rb +164 -0
  125. data/lib/bcd_travel_api/models/leg34.rb +143 -0
  126. data/lib/bcd_travel_api/models/leg4.rb +154 -0
  127. data/lib/bcd_travel_api/models/leg6.rb +143 -0
  128. data/lib/bcd_travel_api/models/line_item.rb +109 -0
  129. data/lib/bcd_travel_api/models/line_item1.rb +119 -0
  130. data/lib/bcd_travel_api/models/location.rb +73 -0
  131. data/lib/bcd_travel_api/models/location16.rb +73 -0
  132. data/lib/bcd_travel_api/models/misc.rb +91 -0
  133. data/lib/bcd_travel_api/models/misc10.rb +83 -0
  134. data/lib/bcd_travel_api/models/options.rb +84 -0
  135. data/lib/bcd_travel_api/models/origin_destination.rb +134 -0
  136. data/lib/bcd_travel_api/models/origin_destination1.rb +108 -0
  137. data/lib/bcd_travel_api/models/passenger.rb +104 -0
  138. data/lib/bcd_travel_api/models/passport.rb +102 -0
  139. data/lib/bcd_travel_api/models/payment.rb +137 -0
  140. data/lib/bcd_travel_api/models/payment1.rb +141 -0
  141. data/lib/bcd_travel_api/models/payment2.rb +121 -0
  142. data/lib/bcd_travel_api/models/payment3.rb +111 -0
  143. data/lib/bcd_travel_api/models/pickup_location.rb +122 -0
  144. data/lib/bcd_travel_api/models/pickup_location1.rb +118 -0
  145. data/lib/bcd_travel_api/models/pickup_location16.rb +83 -0
  146. data/lib/bcd_travel_api/models/pickup_location2.rb +82 -0
  147. data/lib/bcd_travel_api/models/ping_getresponse.rb +72 -0
  148. data/lib/bcd_travel_api/models/pingrequest.rb +126 -0
  149. data/lib/bcd_travel_api/models/pingrequest2.rb +146 -0
  150. data/lib/bcd_travel_api/models/products.rb +129 -0
  151. data/lib/bcd_travel_api/models/products1.rb +117 -0
  152. data/lib/bcd_travel_api/models/products16.rb +111 -0
  153. data/lib/bcd_travel_api/models/products2.rb +107 -0
  154. data/lib/bcd_travel_api/models/rail.rb +91 -0
  155. data/lib/bcd_travel_api/models/rail1.rb +91 -0
  156. data/lib/bcd_travel_api/models/rail16.rb +82 -0
  157. data/lib/bcd_travel_api/models/rail2.rb +91 -0
  158. data/lib/bcd_travel_api/models/reservation.rb +223 -0
  159. data/lib/bcd_travel_api/models/reservation1.rb +239 -0
  160. data/lib/bcd_travel_api/models/reservation2.rb +170 -0
  161. data/lib/bcd_travel_api/models/reservation3.rb +193 -0
  162. data/lib/bcd_travel_api/models/reservation4.rb +201 -0
  163. data/lib/bcd_travel_api/models/reservation56.rb +220 -0
  164. data/lib/bcd_travel_api/models/reservation57.rb +219 -0
  165. data/lib/bcd_travel_api/models/reservation6.rb +240 -0
  166. data/lib/bcd_travel_api/models/reservation8.rb +220 -0
  167. data/lib/bcd_travel_api/models/reservation9.rb +239 -0
  168. data/lib/bcd_travel_api/models/result.rb +299 -0
  169. data/lib/bcd_travel_api/models/result1.rb +267 -0
  170. data/lib/bcd_travel_api/models/result16.rb +295 -0
  171. data/lib/bcd_travel_api/models/result2.rb +295 -0
  172. data/lib/bcd_travel_api/models/search_expenses.rb +111 -0
  173. data/lib/bcd_travel_api/models/search_expenses_request.rb +99 -0
  174. data/lib/bcd_travel_api/models/search_expensesbyaccount_id.rb +111 -0
  175. data/lib/bcd_travel_api/models/search_expensesbyaccount_id_request.rb +90 -0
  176. data/lib/bcd_travel_api/models/search_expensesbybooking_date_time.rb +111 -0
  177. data/lib/bcd_travel_api/models/search_expensesbybooking_date_time_request.rb +90 -0
  178. data/lib/bcd_travel_api/models/search_expensesbybooking_date_timerange.rb +111 -0
  179. data/lib/bcd_travel_api/models/search_expensesbybooking_date_timerange_request.rb +90 -0
  180. data/lib/bcd_travel_api/models/search_expensesbycalculated_ticket_status.rb +111 -0
  181. data/lib/bcd_travel_api/models/search_expensesbycalculated_ticket_status_request.rb +90 -0
  182. data/lib/bcd_travel_api/models/search_expensesbycustomer_number.rb +111 -0
  183. data/lib/bcd_travel_api/models/search_expensesbycustomer_number_request.rb +90 -0
  184. data/lib/bcd_travel_api/models/search_expensesbyglobal_customer_number.rb +111 -0
  185. data/lib/bcd_travel_api/models/search_expensesbyglobal_customer_number_request.rb +90 -0
  186. data/lib/bcd_travel_api/models/search_expensesbyhas_transaction.rb +111 -0
  187. data/lib/bcd_travel_api/models/search_expensesbyhas_transaction_request.rb +90 -0
  188. data/lib/bcd_travel_api/models/search_expensesbyinvoice_date_time.rb +111 -0
  189. data/lib/bcd_travel_api/models/search_expensesbyinvoice_date_time_request.rb +90 -0
  190. data/lib/bcd_travel_api/models/search_expensesbyinvoice_date_timerange.rb +111 -0
  191. data/lib/bcd_travel_api/models/search_expensesbyinvoice_date_timerange_request.rb +90 -0
  192. data/lib/bcd_travel_api/models/search_expensesbyinvoice_number.rb +111 -0
  193. data/lib/bcd_travel_api/models/search_expensesbyinvoice_number_request.rb +90 -0
  194. data/lib/bcd_travel_api/models/search_expensesbylast_modified_date_time.rb +111 -0
  195. data/lib/bcd_travel_api/models/search_expensesbylast_modified_date_time_request.rb +90 -0
  196. data/lib/bcd_travel_api/models/search_expensesbylast_modified_date_timerange.rb +111 -0
  197. data/lib/bcd_travel_api/models/search_expensesbylast_modified_date_timerange_request.rb +90 -0
  198. data/lib/bcd_travel_api/models/search_expensesbyrecord_locator.rb +111 -0
  199. data/lib/bcd_travel_api/models/search_expensesbyrecord_locator_request.rb +90 -0
  200. data/lib/bcd_travel_api/models/search_expensesbyticket_status.rb +111 -0
  201. data/lib/bcd_travel_api/models/search_expensesbyticket_status_request.rb +90 -0
  202. data/lib/bcd_travel_api/models/search_expensesbytraveler_email.rb +111 -0
  203. data/lib/bcd_travel_api/models/search_expensesbytraveler_email_request.rb +90 -0
  204. data/lib/bcd_travel_api/models/segment_option.rb +85 -0
  205. data/lib/bcd_travel_api/models/seller.rb +83 -0
  206. data/lib/bcd_travel_api/models/seller16.rb +72 -0
  207. data/lib/bcd_travel_api/models/sort.rb +86 -0
  208. data/lib/bcd_travel_api/models/specific_flight.rb +82 -0
  209. data/lib/bcd_travel_api/models/start_location_address.rb +109 -0
  210. data/lib/bcd_travel_api/models/taxis.rb +145 -0
  211. data/lib/bcd_travel_api/models/taxis1.rb +132 -0
  212. data/lib/bcd_travel_api/models/taxis3.rb +143 -0
  213. data/lib/bcd_travel_api/models/taxis4.rb +130 -0
  214. data/lib/bcd_travel_api/models/ticket.rb +334 -0
  215. data/lib/bcd_travel_api/models/ticket1.rb +156 -0
  216. data/lib/bcd_travel_api/models/ticket2.rb +244 -0
  217. data/lib/bcd_travel_api/models/ticket3.rb +156 -0
  218. data/lib/bcd_travel_api/models/ticket32.rb +337 -0
  219. data/lib/bcd_travel_api/models/ticket33.rb +156 -0
  220. data/lib/bcd_travel_api/models/ticket4.rb +337 -0
  221. data/lib/bcd_travel_api/models/ticket5.rb +156 -0
  222. data/lib/bcd_travel_api/models/time_restriction.rb +90 -0
  223. data/lib/bcd_travel_api/models/tour.rb +91 -0
  224. data/lib/bcd_travel_api/models/traveler.rb +91 -0
  225. data/lib/bcd_travel_api/models/traveler1.rb +110 -0
  226. data/lib/bcd_travel_api/models/traveler3.rb +91 -0
  227. data/lib/bcd_travel_api/models/traveler4.rb +120 -0
  228. data/lib/bcd_travel_api/models/traveler_name.rb +82 -0
  229. data/lib/bcd_travel_api/utilities/date_time_helper.rb +11 -0
  230. data/lib/bcd_travel_api/utilities/file_wrapper.rb +28 -0
  231. data/lib/bcd_travel_api/utilities/union_type_lookup.rb +128 -0
  232. data/lib/bcd_travel_api.rb +270 -0
  233. metadata +316 -0
@@ -0,0 +1,104 @@
1
+ # bcd_travel_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module BcdTravelApi
7
+ # CardDetail Model.
8
+ class CardDetail < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [String]
14
+ attr_accessor :type
15
+
16
+ # TODO: Write general description for this method
17
+ # @return [String]
18
+ attr_accessor :number
19
+
20
+ # A mapping from model property names to API property names.
21
+ def self.names
22
+ @_hash = {} if @_hash.nil?
23
+ @_hash['type'] = 'type'
24
+ @_hash['number'] = 'number'
25
+ @_hash
26
+ end
27
+
28
+ # An array for optional fields
29
+ def self.optionals
30
+ []
31
+ end
32
+
33
+ # An array for nullable fields
34
+ def self.nullables
35
+ []
36
+ end
37
+
38
+ def initialize(type:, number:, additional_properties: nil)
39
+ # Add additional model properties to the instance
40
+ additional_properties = {} if additional_properties.nil?
41
+
42
+ @type = type
43
+ @number = number
44
+ @additional_properties = additional_properties
45
+ end
46
+
47
+ # Creates an instance of the object from a hash.
48
+ def self.from_hash(hash)
49
+ return nil unless hash
50
+
51
+ # Extract variables from the hash.
52
+ type = hash.key?('type') ? hash['type'] : nil
53
+ number = hash.key?('number') ? hash['number'] : nil
54
+
55
+ # Create a new hash for additional properties, removing known properties.
56
+ new_hash = hash.reject { |k, _| names.value?(k) }
57
+
58
+ additional_properties = APIHelper.get_additional_properties(
59
+ new_hash, proc { |value| value }
60
+ )
61
+
62
+ # Create object from extracted values.
63
+ CardDetail.new(type: type,
64
+ number: number,
65
+ additional_properties: additional_properties)
66
+ end
67
+
68
+ # Validates an instance of the object from a given value.
69
+ # @param [CardDetail | Hash] The value against the validation is performed.
70
+ def self.validate(value)
71
+ if value.instance_of? self
72
+ return (
73
+ APIHelper.valid_type?(value.type,
74
+ ->(val) { val.instance_of? String }) and
75
+ APIHelper.valid_type?(value.number,
76
+ ->(val) { val.instance_of? String })
77
+ )
78
+ end
79
+
80
+ return false unless value.instance_of? Hash
81
+
82
+ (
83
+ APIHelper.valid_type?(value['type'],
84
+ ->(val) { val.instance_of? String }) and
85
+ APIHelper.valid_type?(value['number'],
86
+ ->(val) { val.instance_of? String })
87
+ )
88
+ end
89
+
90
+ # Provides a human-readable string representation of the object.
91
+ def to_s
92
+ class_name = self.class.name.split('::').last
93
+ "<#{class_name} type: #{@type}, number: #{@number}, additional_properties:"\
94
+ " #{@additional_properties}>"
95
+ end
96
+
97
+ # Provides a debugging-friendly string with detailed object information.
98
+ def inspect
99
+ class_name = self.class.name.split('::').last
100
+ "<#{class_name} type: #{@type.inspect}, number: #{@number.inspect}, additional_properties:"\
101
+ " #{@additional_properties}>"
102
+ end
103
+ end
104
+ end
@@ -0,0 +1,310 @@
1
+ # bcd_travel_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module BcdTravelApi
7
+ # Carsbookcardrequest Model.
8
+ class Carsbookcardrequest < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [String]
14
+ attr_accessor :api_key
15
+
16
+ # TODO: Write general description for this method
17
+ # @return [String]
18
+ attr_accessor :timestamp
19
+
20
+ # TODO: Write general description for this method
21
+ # @return [String]
22
+ attr_accessor :nonce
23
+
24
+ # TODO: Write general description for this method
25
+ # @return [String]
26
+ attr_accessor :locale
27
+
28
+ # TODO: Write general description for this method
29
+ # @return [String]
30
+ attr_accessor :customer_ip
31
+
32
+ # TODO: Write general description for this method
33
+ # @return [String]
34
+ attr_accessor :session_id
35
+
36
+ # TODO: Write general description for this method
37
+ # @return [String]
38
+ attr_accessor :user_agent
39
+
40
+ # TODO: Write general description for this method
41
+ # @return [Integer]
42
+ attr_accessor :configuration_id
43
+
44
+ # TODO: Write general description for this method
45
+ # @return [String]
46
+ attr_accessor :system
47
+
48
+ # TODO: Write general description for this method
49
+ # @return [String]
50
+ attr_accessor :booktrack_id
51
+
52
+ # TODO: Write general description for this method
53
+ # @return [String]
54
+ attr_accessor :rate_key
55
+
56
+ # TODO: Write general description for this method
57
+ # @return [String]
58
+ attr_accessor :booker_email
59
+
60
+ # TODO: Write general description for this method
61
+ # @return [String]
62
+ attr_accessor :booker_first_name
63
+
64
+ # TODO: Write general description for this method
65
+ # @return [String]
66
+ attr_accessor :booker_last_name
67
+
68
+ # TODO: Write general description for this method
69
+ # @return [String]
70
+ attr_accessor :pnr_id
71
+
72
+ # TODO: Write general description for this method
73
+ # @return [String]
74
+ attr_accessor :traveler_email
75
+
76
+ # TODO: Write general description for this method
77
+ # @return [String]
78
+ attr_accessor :traveler_first_name
79
+
80
+ # TODO: Write general description for this method
81
+ # @return [String]
82
+ attr_accessor :traveler_last_name
83
+
84
+ # TODO: Write general description for this method
85
+ # @return [String]
86
+ attr_accessor :special_information
87
+
88
+ # TODO: Write general description for this method
89
+ # @return [String]
90
+ attr_accessor :payment_method
91
+
92
+ # TODO: Write general description for this method
93
+ # @return [String]
94
+ attr_accessor :credit_card_number
95
+
96
+ # TODO: Write general description for this method
97
+ # @return [String]
98
+ attr_accessor :credit_card_expiration_year
99
+
100
+ # TODO: Write general description for this method
101
+ # @return [String]
102
+ attr_accessor :credit_card_expiration_month
103
+
104
+ # TODO: Write general description for this method
105
+ # @return [String]
106
+ attr_accessor :credit_card_first_name
107
+
108
+ # TODO: Write general description for this method
109
+ # @return [String]
110
+ attr_accessor :credit_card_last_name
111
+
112
+ # A mapping from model property names to API property names.
113
+ def self.names
114
+ @_hash = {} if @_hash.nil?
115
+ @_hash['api_key'] = 'api_key'
116
+ @_hash['timestamp'] = 'timestamp'
117
+ @_hash['nonce'] = 'nonce'
118
+ @_hash['locale'] = 'locale'
119
+ @_hash['customer_ip'] = 'customer_ip'
120
+ @_hash['session_id'] = 'session_id'
121
+ @_hash['user_agent'] = 'user_agent'
122
+ @_hash['configuration_id'] = 'configuration_id'
123
+ @_hash['system'] = 'system'
124
+ @_hash['booktrack_id'] = 'booktrack_id'
125
+ @_hash['rate_key'] = 'rate_key'
126
+ @_hash['booker_email'] = 'booker_email'
127
+ @_hash['booker_first_name'] = 'booker_first_name'
128
+ @_hash['booker_last_name'] = 'booker_last_name'
129
+ @_hash['pnr_id'] = 'pnr_id'
130
+ @_hash['traveler_email'] = 'traveler_email'
131
+ @_hash['traveler_first_name'] = 'traveler_first_name'
132
+ @_hash['traveler_last_name'] = 'traveler_last_name'
133
+ @_hash['special_information'] = 'special_information'
134
+ @_hash['payment_method'] = 'payment_method'
135
+ @_hash['credit_card_number'] = 'credit_card_number'
136
+ @_hash['credit_card_expiration_year'] = 'credit_card_expiration_year'
137
+ @_hash['credit_card_expiration_month'] = 'credit_card_expiration_month'
138
+ @_hash['credit_card_first_name'] = 'credit_card_first_name'
139
+ @_hash['credit_card_last_name'] = 'credit_card_last_name'
140
+ @_hash
141
+ end
142
+
143
+ # An array for optional fields
144
+ def self.optionals
145
+ []
146
+ end
147
+
148
+ # An array for nullable fields
149
+ def self.nullables
150
+ []
151
+ end
152
+
153
+ def initialize(api_key:, timestamp:, nonce:, locale:, customer_ip:,
154
+ session_id:, user_agent:, configuration_id:, system:,
155
+ booktrack_id:, rate_key:, booker_email:, booker_first_name:,
156
+ booker_last_name:, pnr_id:, traveler_email:,
157
+ traveler_first_name:, traveler_last_name:,
158
+ special_information:, payment_method:, credit_card_number:,
159
+ credit_card_expiration_year:, credit_card_expiration_month:,
160
+ credit_card_first_name:, credit_card_last_name:,
161
+ additional_properties: nil)
162
+ # Add additional model properties to the instance
163
+ additional_properties = {} if additional_properties.nil?
164
+
165
+ @api_key = api_key
166
+ @timestamp = timestamp
167
+ @nonce = nonce
168
+ @locale = locale
169
+ @customer_ip = customer_ip
170
+ @session_id = session_id
171
+ @user_agent = user_agent
172
+ @configuration_id = configuration_id
173
+ @system = system
174
+ @booktrack_id = booktrack_id
175
+ @rate_key = rate_key
176
+ @booker_email = booker_email
177
+ @booker_first_name = booker_first_name
178
+ @booker_last_name = booker_last_name
179
+ @pnr_id = pnr_id
180
+ @traveler_email = traveler_email
181
+ @traveler_first_name = traveler_first_name
182
+ @traveler_last_name = traveler_last_name
183
+ @special_information = special_information
184
+ @payment_method = payment_method
185
+ @credit_card_number = credit_card_number
186
+ @credit_card_expiration_year = credit_card_expiration_year
187
+ @credit_card_expiration_month = credit_card_expiration_month
188
+ @credit_card_first_name = credit_card_first_name
189
+ @credit_card_last_name = credit_card_last_name
190
+ @additional_properties = additional_properties
191
+ end
192
+
193
+ # Creates an instance of the object from a hash.
194
+ def self.from_hash(hash)
195
+ return nil unless hash
196
+
197
+ # Extract variables from the hash.
198
+ api_key = hash.key?('api_key') ? hash['api_key'] : nil
199
+ timestamp = hash.key?('timestamp') ? hash['timestamp'] : nil
200
+ nonce = hash.key?('nonce') ? hash['nonce'] : nil
201
+ locale = hash.key?('locale') ? hash['locale'] : nil
202
+ customer_ip = hash.key?('customer_ip') ? hash['customer_ip'] : nil
203
+ session_id = hash.key?('session_id') ? hash['session_id'] : nil
204
+ user_agent = hash.key?('user_agent') ? hash['user_agent'] : nil
205
+ configuration_id =
206
+ hash.key?('configuration_id') ? hash['configuration_id'] : nil
207
+ system = hash.key?('system') ? hash['system'] : nil
208
+ booktrack_id = hash.key?('booktrack_id') ? hash['booktrack_id'] : nil
209
+ rate_key = hash.key?('rate_key') ? hash['rate_key'] : nil
210
+ booker_email = hash.key?('booker_email') ? hash['booker_email'] : nil
211
+ booker_first_name =
212
+ hash.key?('booker_first_name') ? hash['booker_first_name'] : nil
213
+ booker_last_name =
214
+ hash.key?('booker_last_name') ? hash['booker_last_name'] : nil
215
+ pnr_id = hash.key?('pnr_id') ? hash['pnr_id'] : nil
216
+ traveler_email =
217
+ hash.key?('traveler_email') ? hash['traveler_email'] : nil
218
+ traveler_first_name =
219
+ hash.key?('traveler_first_name') ? hash['traveler_first_name'] : nil
220
+ traveler_last_name =
221
+ hash.key?('traveler_last_name') ? hash['traveler_last_name'] : nil
222
+ special_information =
223
+ hash.key?('special_information') ? hash['special_information'] : nil
224
+ payment_method =
225
+ hash.key?('payment_method') ? hash['payment_method'] : nil
226
+ credit_card_number =
227
+ hash.key?('credit_card_number') ? hash['credit_card_number'] : nil
228
+ credit_card_expiration_year =
229
+ hash.key?('credit_card_expiration_year') ? hash['credit_card_expiration_year'] : nil
230
+ credit_card_expiration_month =
231
+ hash.key?('credit_card_expiration_month') ? hash['credit_card_expiration_month'] : nil
232
+ credit_card_first_name =
233
+ hash.key?('credit_card_first_name') ? hash['credit_card_first_name'] : nil
234
+ credit_card_last_name =
235
+ hash.key?('credit_card_last_name') ? hash['credit_card_last_name'] : nil
236
+
237
+ # Create a new hash for additional properties, removing known properties.
238
+ new_hash = hash.reject { |k, _| names.value?(k) }
239
+
240
+ additional_properties = APIHelper.get_additional_properties(
241
+ new_hash, proc { |value| value }
242
+ )
243
+
244
+ # Create object from extracted values.
245
+ Carsbookcardrequest.new(api_key: api_key,
246
+ timestamp: timestamp,
247
+ nonce: nonce,
248
+ locale: locale,
249
+ customer_ip: customer_ip,
250
+ session_id: session_id,
251
+ user_agent: user_agent,
252
+ configuration_id: configuration_id,
253
+ system: system,
254
+ booktrack_id: booktrack_id,
255
+ rate_key: rate_key,
256
+ booker_email: booker_email,
257
+ booker_first_name: booker_first_name,
258
+ booker_last_name: booker_last_name,
259
+ pnr_id: pnr_id,
260
+ traveler_email: traveler_email,
261
+ traveler_first_name: traveler_first_name,
262
+ traveler_last_name: traveler_last_name,
263
+ special_information: special_information,
264
+ payment_method: payment_method,
265
+ credit_card_number: credit_card_number,
266
+ credit_card_expiration_year: credit_card_expiration_year,
267
+ credit_card_expiration_month: credit_card_expiration_month,
268
+ credit_card_first_name: credit_card_first_name,
269
+ credit_card_last_name: credit_card_last_name,
270
+ additional_properties: additional_properties)
271
+ end
272
+
273
+ # Provides a human-readable string representation of the object.
274
+ def to_s
275
+ class_name = self.class.name.split('::').last
276
+ "<#{class_name} api_key: #{@api_key}, timestamp: #{@timestamp}, nonce: #{@nonce}, locale:"\
277
+ " #{@locale}, customer_ip: #{@customer_ip}, session_id: #{@session_id}, user_agent:"\
278
+ " #{@user_agent}, configuration_id: #{@configuration_id}, system: #{@system}, booktrack_id:"\
279
+ " #{@booktrack_id}, rate_key: #{@rate_key}, booker_email: #{@booker_email},"\
280
+ " booker_first_name: #{@booker_first_name}, booker_last_name: #{@booker_last_name}, pnr_id:"\
281
+ " #{@pnr_id}, traveler_email: #{@traveler_email}, traveler_first_name:"\
282
+ " #{@traveler_first_name}, traveler_last_name: #{@traveler_last_name}, special_information:"\
283
+ " #{@special_information}, payment_method: #{@payment_method}, credit_card_number:"\
284
+ " #{@credit_card_number}, credit_card_expiration_year: #{@credit_card_expiration_year},"\
285
+ " credit_card_expiration_month: #{@credit_card_expiration_month}, credit_card_first_name:"\
286
+ " #{@credit_card_first_name}, credit_card_last_name: #{@credit_card_last_name},"\
287
+ " additional_properties: #{@additional_properties}>"
288
+ end
289
+
290
+ # Provides a debugging-friendly string with detailed object information.
291
+ def inspect
292
+ class_name = self.class.name.split('::').last
293
+ "<#{class_name} api_key: #{@api_key.inspect}, timestamp: #{@timestamp.inspect}, nonce:"\
294
+ " #{@nonce.inspect}, locale: #{@locale.inspect}, customer_ip: #{@customer_ip.inspect},"\
295
+ " session_id: #{@session_id.inspect}, user_agent: #{@user_agent.inspect}, configuration_id:"\
296
+ " #{@configuration_id.inspect}, system: #{@system.inspect}, booktrack_id:"\
297
+ " #{@booktrack_id.inspect}, rate_key: #{@rate_key.inspect}, booker_email:"\
298
+ " #{@booker_email.inspect}, booker_first_name: #{@booker_first_name.inspect},"\
299
+ " booker_last_name: #{@booker_last_name.inspect}, pnr_id: #{@pnr_id.inspect},"\
300
+ " traveler_email: #{@traveler_email.inspect}, traveler_first_name:"\
301
+ " #{@traveler_first_name.inspect}, traveler_last_name: #{@traveler_last_name.inspect},"\
302
+ " special_information: #{@special_information.inspect}, payment_method:"\
303
+ " #{@payment_method.inspect}, credit_card_number: #{@credit_card_number.inspect},"\
304
+ " credit_card_expiration_year: #{@credit_card_expiration_year.inspect},"\
305
+ " credit_card_expiration_month: #{@credit_card_expiration_month.inspect},"\
306
+ " credit_card_first_name: #{@credit_card_first_name.inspect}, credit_card_last_name:"\
307
+ " #{@credit_card_last_name.inspect}, additional_properties: #{@additional_properties}>"
308
+ end
309
+ end
310
+ end
@@ -0,0 +1,236 @@
1
+ # bcd_travel_api
2
+ #
3
+ # This file was automatically generated by APIMATIC v3.0 (
4
+ # https://www.apimatic.io ).
5
+
6
+ module BcdTravelApi
7
+ # Carsbookguaranteerequest Model.
8
+ class Carsbookguaranteerequest < BaseModel
9
+ SKIP = Object.new
10
+ private_constant :SKIP
11
+
12
+ # TODO: Write general description for this method
13
+ # @return [String]
14
+ attr_accessor :api_key
15
+
16
+ # TODO: Write general description for this method
17
+ # @return [String]
18
+ attr_accessor :timestamp
19
+
20
+ # TODO: Write general description for this method
21
+ # @return [String]
22
+ attr_accessor :nonce
23
+
24
+ # TODO: Write general description for this method
25
+ # @return [String]
26
+ attr_accessor :locale
27
+
28
+ # TODO: Write general description for this method
29
+ # @return [String]
30
+ attr_accessor :customer_ip
31
+
32
+ # TODO: Write general description for this method
33
+ # @return [String]
34
+ attr_accessor :session_id
35
+
36
+ # TODO: Write general description for this method
37
+ # @return [String]
38
+ attr_accessor :user_agent
39
+
40
+ # TODO: Write general description for this method
41
+ # @return [Integer]
42
+ attr_accessor :configuration_id
43
+
44
+ # TODO: Write general description for this method
45
+ # @return [String]
46
+ attr_accessor :system
47
+
48
+ # TODO: Write general description for this method
49
+ # @return [String]
50
+ attr_accessor :booktrack_id
51
+
52
+ # TODO: Write general description for this method
53
+ # @return [String]
54
+ attr_accessor :rate_key
55
+
56
+ # TODO: Write general description for this method
57
+ # @return [String]
58
+ attr_accessor :booker_email
59
+
60
+ # TODO: Write general description for this method
61
+ # @return [String]
62
+ attr_accessor :booker_first_name
63
+
64
+ # TODO: Write general description for this method
65
+ # @return [String]
66
+ attr_accessor :booker_last_name
67
+
68
+ # TODO: Write general description for this method
69
+ # @return [String]
70
+ attr_accessor :traveler_email
71
+
72
+ # TODO: Write general description for this method
73
+ # @return [String]
74
+ attr_accessor :traveler_first_name
75
+
76
+ # TODO: Write general description for this method
77
+ # @return [String]
78
+ attr_accessor :traveler_last_name
79
+
80
+ # TODO: Write general description for this method
81
+ # @return [String]
82
+ attr_accessor :special_information
83
+
84
+ # A mapping from model property names to API property names.
85
+ def self.names
86
+ @_hash = {} if @_hash.nil?
87
+ @_hash['api_key'] = 'api_key'
88
+ @_hash['timestamp'] = 'timestamp'
89
+ @_hash['nonce'] = 'nonce'
90
+ @_hash['locale'] = 'locale'
91
+ @_hash['customer_ip'] = 'customer_ip'
92
+ @_hash['session_id'] = 'session_id'
93
+ @_hash['user_agent'] = 'user_agent'
94
+ @_hash['configuration_id'] = 'configuration_id'
95
+ @_hash['system'] = 'system'
96
+ @_hash['booktrack_id'] = 'booktrack_id'
97
+ @_hash['rate_key'] = 'rate_key'
98
+ @_hash['booker_email'] = 'booker_email'
99
+ @_hash['booker_first_name'] = 'booker_first_name'
100
+ @_hash['booker_last_name'] = 'booker_last_name'
101
+ @_hash['traveler_email'] = 'traveler_email'
102
+ @_hash['traveler_first_name'] = 'traveler_first_name'
103
+ @_hash['traveler_last_name'] = 'traveler_last_name'
104
+ @_hash['special_information'] = 'special_information'
105
+ @_hash
106
+ end
107
+
108
+ # An array for optional fields
109
+ def self.optionals
110
+ []
111
+ end
112
+
113
+ # An array for nullable fields
114
+ def self.nullables
115
+ []
116
+ end
117
+
118
+ def initialize(api_key:, timestamp:, nonce:, locale:, customer_ip:,
119
+ session_id:, user_agent:, configuration_id:, system:,
120
+ booktrack_id:, rate_key:, booker_email:, booker_first_name:,
121
+ booker_last_name:, traveler_email:, traveler_first_name:,
122
+ traveler_last_name:, special_information:,
123
+ additional_properties: nil)
124
+ # Add additional model properties to the instance
125
+ additional_properties = {} if additional_properties.nil?
126
+
127
+ @api_key = api_key
128
+ @timestamp = timestamp
129
+ @nonce = nonce
130
+ @locale = locale
131
+ @customer_ip = customer_ip
132
+ @session_id = session_id
133
+ @user_agent = user_agent
134
+ @configuration_id = configuration_id
135
+ @system = system
136
+ @booktrack_id = booktrack_id
137
+ @rate_key = rate_key
138
+ @booker_email = booker_email
139
+ @booker_first_name = booker_first_name
140
+ @booker_last_name = booker_last_name
141
+ @traveler_email = traveler_email
142
+ @traveler_first_name = traveler_first_name
143
+ @traveler_last_name = traveler_last_name
144
+ @special_information = special_information
145
+ @additional_properties = additional_properties
146
+ end
147
+
148
+ # Creates an instance of the object from a hash.
149
+ def self.from_hash(hash)
150
+ return nil unless hash
151
+
152
+ # Extract variables from the hash.
153
+ api_key = hash.key?('api_key') ? hash['api_key'] : nil
154
+ timestamp = hash.key?('timestamp') ? hash['timestamp'] : nil
155
+ nonce = hash.key?('nonce') ? hash['nonce'] : nil
156
+ locale = hash.key?('locale') ? hash['locale'] : nil
157
+ customer_ip = hash.key?('customer_ip') ? hash['customer_ip'] : nil
158
+ session_id = hash.key?('session_id') ? hash['session_id'] : nil
159
+ user_agent = hash.key?('user_agent') ? hash['user_agent'] : nil
160
+ configuration_id =
161
+ hash.key?('configuration_id') ? hash['configuration_id'] : nil
162
+ system = hash.key?('system') ? hash['system'] : nil
163
+ booktrack_id = hash.key?('booktrack_id') ? hash['booktrack_id'] : nil
164
+ rate_key = hash.key?('rate_key') ? hash['rate_key'] : nil
165
+ booker_email = hash.key?('booker_email') ? hash['booker_email'] : nil
166
+ booker_first_name =
167
+ hash.key?('booker_first_name') ? hash['booker_first_name'] : nil
168
+ booker_last_name =
169
+ hash.key?('booker_last_name') ? hash['booker_last_name'] : nil
170
+ traveler_email =
171
+ hash.key?('traveler_email') ? hash['traveler_email'] : nil
172
+ traveler_first_name =
173
+ hash.key?('traveler_first_name') ? hash['traveler_first_name'] : nil
174
+ traveler_last_name =
175
+ hash.key?('traveler_last_name') ? hash['traveler_last_name'] : nil
176
+ special_information =
177
+ hash.key?('special_information') ? hash['special_information'] : nil
178
+
179
+ # Create a new hash for additional properties, removing known properties.
180
+ new_hash = hash.reject { |k, _| names.value?(k) }
181
+
182
+ additional_properties = APIHelper.get_additional_properties(
183
+ new_hash, proc { |value| value }
184
+ )
185
+
186
+ # Create object from extracted values.
187
+ Carsbookguaranteerequest.new(api_key: api_key,
188
+ timestamp: timestamp,
189
+ nonce: nonce,
190
+ locale: locale,
191
+ customer_ip: customer_ip,
192
+ session_id: session_id,
193
+ user_agent: user_agent,
194
+ configuration_id: configuration_id,
195
+ system: system,
196
+ booktrack_id: booktrack_id,
197
+ rate_key: rate_key,
198
+ booker_email: booker_email,
199
+ booker_first_name: booker_first_name,
200
+ booker_last_name: booker_last_name,
201
+ traveler_email: traveler_email,
202
+ traveler_first_name: traveler_first_name,
203
+ traveler_last_name: traveler_last_name,
204
+ special_information: special_information,
205
+ additional_properties: additional_properties)
206
+ end
207
+
208
+ # Provides a human-readable string representation of the object.
209
+ def to_s
210
+ class_name = self.class.name.split('::').last
211
+ "<#{class_name} api_key: #{@api_key}, timestamp: #{@timestamp}, nonce: #{@nonce}, locale:"\
212
+ " #{@locale}, customer_ip: #{@customer_ip}, session_id: #{@session_id}, user_agent:"\
213
+ " #{@user_agent}, configuration_id: #{@configuration_id}, system: #{@system}, booktrack_id:"\
214
+ " #{@booktrack_id}, rate_key: #{@rate_key}, booker_email: #{@booker_email},"\
215
+ " booker_first_name: #{@booker_first_name}, booker_last_name: #{@booker_last_name},"\
216
+ " traveler_email: #{@traveler_email}, traveler_first_name: #{@traveler_first_name},"\
217
+ " traveler_last_name: #{@traveler_last_name}, special_information: #{@special_information},"\
218
+ " additional_properties: #{@additional_properties}>"
219
+ end
220
+
221
+ # Provides a debugging-friendly string with detailed object information.
222
+ def inspect
223
+ class_name = self.class.name.split('::').last
224
+ "<#{class_name} api_key: #{@api_key.inspect}, timestamp: #{@timestamp.inspect}, nonce:"\
225
+ " #{@nonce.inspect}, locale: #{@locale.inspect}, customer_ip: #{@customer_ip.inspect},"\
226
+ " session_id: #{@session_id.inspect}, user_agent: #{@user_agent.inspect}, configuration_id:"\
227
+ " #{@configuration_id.inspect}, system: #{@system.inspect}, booktrack_id:"\
228
+ " #{@booktrack_id.inspect}, rate_key: #{@rate_key.inspect}, booker_email:"\
229
+ " #{@booker_email.inspect}, booker_first_name: #{@booker_first_name.inspect},"\
230
+ " booker_last_name: #{@booker_last_name.inspect}, traveler_email:"\
231
+ " #{@traveler_email.inspect}, traveler_first_name: #{@traveler_first_name.inspect},"\
232
+ " traveler_last_name: #{@traveler_last_name.inspect}, special_information:"\
233
+ " #{@special_information.inspect}, additional_properties: #{@additional_properties}>"
234
+ end
235
+ end
236
+ end