onlinepayments-sdk-ruby 3.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (269) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +2 -0
  3. data/LICENSE.txt +22 -0
  4. data/README.md +140 -0
  5. data/Rakefile +34 -0
  6. data/lib/onlinepayments/sdk/api_exception.rb +42 -0
  7. data/lib/onlinepayments/sdk/api_resource.rb +115 -0
  8. data/lib/onlinepayments/sdk/authenticator.rb +16 -0
  9. data/lib/onlinepayments/sdk/authorization_exception.rb +13 -0
  10. data/lib/onlinepayments/sdk/call_context.rb +26 -0
  11. data/lib/onlinepayments/sdk/client.rb +82 -0
  12. data/lib/onlinepayments/sdk/communication_exception.rb +16 -0
  13. data/lib/onlinepayments/sdk/communicator.rb +300 -0
  14. data/lib/onlinepayments/sdk/communicator_configuration.rb +59 -0
  15. data/lib/onlinepayments/sdk/connection.rb +41 -0
  16. data/lib/onlinepayments/sdk/data_object.rb +31 -0
  17. data/lib/onlinepayments/sdk/declined_payment_exception.rb +30 -0
  18. data/lib/onlinepayments/sdk/declined_payout_exception.rb +32 -0
  19. data/lib/onlinepayments/sdk/declined_refund_exception.rb +32 -0
  20. data/lib/onlinepayments/sdk/declined_transaction_exception.rb +16 -0
  21. data/lib/onlinepayments/sdk/defaultimpl/authorization_type.rb +24 -0
  22. data/lib/onlinepayments/sdk/defaultimpl/default_authenticator.rb +108 -0
  23. data/lib/onlinepayments/sdk/defaultimpl/default_connection.rb +295 -0
  24. data/lib/onlinepayments/sdk/defaultimpl/default_marshaller.rb +32 -0
  25. data/lib/onlinepayments/sdk/defaultimpl.rb +6 -0
  26. data/lib/onlinepayments/sdk/domain/account_on_file.rb +49 -0
  27. data/lib/onlinepayments/sdk/domain/account_on_file_attribute.rb +38 -0
  28. data/lib/onlinepayments/sdk/domain/account_on_file_display_hints.rb +37 -0
  29. data/lib/onlinepayments/sdk/domain/additional_order_input.rb +54 -0
  30. data/lib/onlinepayments/sdk/domain/address.rb +50 -0
  31. data/lib/onlinepayments/sdk/domain/address_personal.rb +58 -0
  32. data/lib/onlinepayments/sdk/domain/airline_data.rb +128 -0
  33. data/lib/onlinepayments/sdk/domain/airline_flight_leg.rb +102 -0
  34. data/lib/onlinepayments/sdk/domain/airline_passenger.rb +38 -0
  35. data/lib/onlinepayments/sdk/domain/amount_breakdown.rb +30 -0
  36. data/lib/onlinepayments/sdk/domain/amount_of_money.rb +30 -0
  37. data/lib/onlinepayments/sdk/domain/api_error.rb +46 -0
  38. data/lib/onlinepayments/sdk/domain/bank_account_iban.rb +26 -0
  39. data/lib/onlinepayments/sdk/domain/browser_data.rb +42 -0
  40. data/lib/onlinepayments/sdk/domain/cancel_payment_response.rb +30 -0
  41. data/lib/onlinepayments/sdk/domain/capture.rb +46 -0
  42. data/lib/onlinepayments/sdk/domain/capture_output.rb +82 -0
  43. data/lib/onlinepayments/sdk/domain/capture_payment_request.rb +38 -0
  44. data/lib/onlinepayments/sdk/domain/capture_response.rb +46 -0
  45. data/lib/onlinepayments/sdk/domain/capture_status_output.rb +26 -0
  46. data/lib/onlinepayments/sdk/domain/captures_response.rb +33 -0
  47. data/lib/onlinepayments/sdk/domain/card.rb +38 -0
  48. data/lib/onlinepayments/sdk/domain/card_essentials.rb +34 -0
  49. data/lib/onlinepayments/sdk/domain/card_fraud_results.rb +34 -0
  50. data/lib/onlinepayments/sdk/domain/card_payment_method_specific_input.rb +98 -0
  51. data/lib/onlinepayments/sdk/domain/card_payment_method_specific_input_base.rb +86 -0
  52. data/lib/onlinepayments/sdk/domain/card_payment_method_specific_input_for_hosted_checkout.rb +26 -0
  53. data/lib/onlinepayments/sdk/domain/card_payment_method_specific_output.rb +78 -0
  54. data/lib/onlinepayments/sdk/domain/card_payout_method_specific_input.rb +38 -0
  55. data/lib/onlinepayments/sdk/domain/card_recurrence_details.rb +26 -0
  56. data/lib/onlinepayments/sdk/domain/card_without_cvv.rb +34 -0
  57. data/lib/onlinepayments/sdk/domain/company_information.rb +26 -0
  58. data/lib/onlinepayments/sdk/domain/complete_payment_card_payment_method_specific_input.rb +30 -0
  59. data/lib/onlinepayments/sdk/domain/complete_payment_request.rb +38 -0
  60. data/lib/onlinepayments/sdk/domain/complete_payment_response.rb +46 -0
  61. data/lib/onlinepayments/sdk/domain/contact_details.rb +42 -0
  62. data/lib/onlinepayments/sdk/domain/create_hosted_checkout_request.rb +78 -0
  63. data/lib/onlinepayments/sdk/domain/create_hosted_checkout_response.rb +48 -0
  64. data/lib/onlinepayments/sdk/domain/create_hosted_tokenization_request.rb +38 -0
  65. data/lib/onlinepayments/sdk/domain/create_hosted_tokenization_response.rb +50 -0
  66. data/lib/onlinepayments/sdk/domain/create_mandate_request.rb +58 -0
  67. data/lib/onlinepayments/sdk/domain/create_mandate_response.rb +38 -0
  68. data/lib/onlinepayments/sdk/domain/create_mandate_with_return_url.rb +58 -0
  69. data/lib/onlinepayments/sdk/domain/create_payment_request.rb +74 -0
  70. data/lib/onlinepayments/sdk/domain/create_payment_response.rb +46 -0
  71. data/lib/onlinepayments/sdk/domain/create_payout_request.rb +46 -0
  72. data/lib/onlinepayments/sdk/domain/create_token_request.rb +34 -0
  73. data/lib/onlinepayments/sdk/domain/created_payment_output.rb +34 -0
  74. data/lib/onlinepayments/sdk/domain/created_token_response.rb +50 -0
  75. data/lib/onlinepayments/sdk/domain/customer.rb +86 -0
  76. data/lib/onlinepayments/sdk/domain/customer_account.rb +70 -0
  77. data/lib/onlinepayments/sdk/domain/customer_account_authentication.rb +30 -0
  78. data/lib/onlinepayments/sdk/domain/customer_device.rb +50 -0
  79. data/lib/onlinepayments/sdk/domain/customer_payment_activity.rb +34 -0
  80. data/lib/onlinepayments/sdk/domain/customer_token.rb +46 -0
  81. data/lib/onlinepayments/sdk/domain/decrypted_payment_data.rb +42 -0
  82. data/lib/onlinepayments/sdk/domain/directory_entry.rb +34 -0
  83. data/lib/onlinepayments/sdk/domain/empty_validator.rb +12 -0
  84. data/lib/onlinepayments/sdk/domain/error_response.rb +37 -0
  85. data/lib/onlinepayments/sdk/domain/external_cardholder_authentication_data.rb +58 -0
  86. data/lib/onlinepayments/sdk/domain/external_token_linked.rb +34 -0
  87. data/lib/onlinepayments/sdk/domain/fixed_list_validator.rb +32 -0
  88. data/lib/onlinepayments/sdk/domain/fraud_fields.rb +30 -0
  89. data/lib/onlinepayments/sdk/domain/fraud_results.rb +26 -0
  90. data/lib/onlinepayments/sdk/domain/g_pay_three_d_secure.rb +46 -0
  91. data/lib/onlinepayments/sdk/domain/get_hosted_checkout_response.rb +34 -0
  92. data/lib/onlinepayments/sdk/domain/get_hosted_tokenization_response.rb +34 -0
  93. data/lib/onlinepayments/sdk/domain/get_iin_details_request.rb +34 -0
  94. data/lib/onlinepayments/sdk/domain/get_iin_details_response.rb +45 -0
  95. data/lib/onlinepayments/sdk/domain/get_mandate_response.rb +30 -0
  96. data/lib/onlinepayments/sdk/domain/get_payment_product_groups_response.rb +33 -0
  97. data/lib/onlinepayments/sdk/domain/get_payment_products_response.rb +33 -0
  98. data/lib/onlinepayments/sdk/domain/gift_card_purchase.rb +34 -0
  99. data/lib/onlinepayments/sdk/domain/hosted_checkout_specific_input.rb +66 -0
  100. data/lib/onlinepayments/sdk/domain/hosted_checkout_specific_output.rb +30 -0
  101. data/lib/onlinepayments/sdk/domain/iin_detail.rb +30 -0
  102. data/lib/onlinepayments/sdk/domain/label_template_element.rb +30 -0
  103. data/lib/onlinepayments/sdk/domain/length_validator.rb +30 -0
  104. data/lib/onlinepayments/sdk/domain/line_item.rb +46 -0
  105. data/lib/onlinepayments/sdk/domain/line_item_invoice_data.rb +26 -0
  106. data/lib/onlinepayments/sdk/domain/loan_recipient.rb +42 -0
  107. data/lib/onlinepayments/sdk/domain/lodging_data.rb +26 -0
  108. data/lib/onlinepayments/sdk/domain/mandate_address.rb +42 -0
  109. data/lib/onlinepayments/sdk/domain/mandate_contact_details.rb +26 -0
  110. data/lib/onlinepayments/sdk/domain/mandate_customer.rb +58 -0
  111. data/lib/onlinepayments/sdk/domain/mandate_merchant_action.rb +34 -0
  112. data/lib/onlinepayments/sdk/domain/mandate_personal_information.rb +34 -0
  113. data/lib/onlinepayments/sdk/domain/mandate_personal_name.rb +30 -0
  114. data/lib/onlinepayments/sdk/domain/mandate_redirect_data.rb +30 -0
  115. data/lib/onlinepayments/sdk/domain/mandate_response.rb +50 -0
  116. data/lib/onlinepayments/sdk/domain/merchant_action.rb +34 -0
  117. data/lib/onlinepayments/sdk/domain/mobile_payment_data.rb +30 -0
  118. data/lib/onlinepayments/sdk/domain/mobile_payment_method_hosted_checkout_specific_input.rb +30 -0
  119. data/lib/onlinepayments/sdk/domain/mobile_payment_method_specific_input.rb +62 -0
  120. data/lib/onlinepayments/sdk/domain/mobile_payment_method_specific_output.rb +58 -0
  121. data/lib/onlinepayments/sdk/domain/mobile_payment_product320_specific_input.rb +30 -0
  122. data/lib/onlinepayments/sdk/domain/operation_output.rb +58 -0
  123. data/lib/onlinepayments/sdk/domain/order.rb +70 -0
  124. data/lib/onlinepayments/sdk/domain/order_line_details.rb +54 -0
  125. data/lib/onlinepayments/sdk/domain/order_references.rb +34 -0
  126. data/lib/onlinepayments/sdk/domain/order_status_output.rb +49 -0
  127. data/lib/onlinepayments/sdk/domain/order_type_information.rb +30 -0
  128. data/lib/onlinepayments/sdk/domain/payment_account_on_file.rb +30 -0
  129. data/lib/onlinepayments/sdk/domain/payment_context.rb +38 -0
  130. data/lib/onlinepayments/sdk/domain/payment_creation_output.rb +38 -0
  131. data/lib/onlinepayments/sdk/domain/payment_details_response.rb +65 -0
  132. data/lib/onlinepayments/sdk/domain/payment_error_response.rb +45 -0
  133. data/lib/onlinepayments/sdk/domain/payment_output.rb +82 -0
  134. data/lib/onlinepayments/sdk/domain/payment_product.rb +102 -0
  135. data/lib/onlinepayments/sdk/domain/payment_product130_specific_input.rb +30 -0
  136. data/lib/onlinepayments/sdk/domain/payment_product130_specific_three_d_secure.rb +38 -0
  137. data/lib/onlinepayments/sdk/domain/payment_product302_specific_data.rb +32 -0
  138. data/lib/onlinepayments/sdk/domain/payment_product320_specific_data.rb +36 -0
  139. data/lib/onlinepayments/sdk/domain/payment_product5100_specific_input.rb +26 -0
  140. data/lib/onlinepayments/sdk/domain/payment_product5402_specific_output.rb +26 -0
  141. data/lib/onlinepayments/sdk/domain/payment_product5500_specific_output.rb +34 -0
  142. data/lib/onlinepayments/sdk/domain/payment_product771_specific_output.rb +26 -0
  143. data/lib/onlinepayments/sdk/domain/payment_product840_customer_account.rb +54 -0
  144. data/lib/onlinepayments/sdk/domain/payment_product840_specific_output.rb +53 -0
  145. data/lib/onlinepayments/sdk/domain/payment_product_display_hints.rb +34 -0
  146. data/lib/onlinepayments/sdk/domain/payment_product_field.rb +46 -0
  147. data/lib/onlinepayments/sdk/domain/payment_product_field_data_restrictions.rb +34 -0
  148. data/lib/onlinepayments/sdk/domain/payment_product_field_display_element.rb +38 -0
  149. data/lib/onlinepayments/sdk/domain/payment_product_field_display_hints.rb +70 -0
  150. data/lib/onlinepayments/sdk/domain/payment_product_field_form_element.rb +37 -0
  151. data/lib/onlinepayments/sdk/domain/payment_product_field_tooltip.rb +30 -0
  152. data/lib/onlinepayments/sdk/domain/payment_product_field_validators.rb +90 -0
  153. data/lib/onlinepayments/sdk/domain/payment_product_filter.rb +42 -0
  154. data/lib/onlinepayments/sdk/domain/payment_product_filters_hosted_checkout.rb +37 -0
  155. data/lib/onlinepayments/sdk/domain/payment_product_group.rb +52 -0
  156. data/lib/onlinepayments/sdk/domain/payment_product_networks_response.rb +32 -0
  157. data/lib/onlinepayments/sdk/domain/payment_references.rb +30 -0
  158. data/lib/onlinepayments/sdk/domain/payment_response.rb +54 -0
  159. data/lib/onlinepayments/sdk/domain/payment_status_output.rb +57 -0
  160. data/lib/onlinepayments/sdk/domain/payout_error_response.rb +45 -0
  161. data/lib/onlinepayments/sdk/domain/payout_output.rb +30 -0
  162. data/lib/onlinepayments/sdk/domain/payout_response.rb +46 -0
  163. data/lib/onlinepayments/sdk/domain/payout_result.rb +46 -0
  164. data/lib/onlinepayments/sdk/domain/payout_status_output.rb +34 -0
  165. data/lib/onlinepayments/sdk/domain/personal_information.rb +38 -0
  166. data/lib/onlinepayments/sdk/domain/personal_information_token.rb +30 -0
  167. data/lib/onlinepayments/sdk/domain/personal_name.rb +34 -0
  168. data/lib/onlinepayments/sdk/domain/personal_name_token.rb +30 -0
  169. data/lib/onlinepayments/sdk/domain/product_directory.rb +33 -0
  170. data/lib/onlinepayments/sdk/domain/protection_eligibility.rb +30 -0
  171. data/lib/onlinepayments/sdk/domain/range_validator.rb +30 -0
  172. data/lib/onlinepayments/sdk/domain/redirect_data.rb +30 -0
  173. data/lib/onlinepayments/sdk/domain/redirect_payment_method_specific_input.rb +66 -0
  174. data/lib/onlinepayments/sdk/domain/redirect_payment_method_specific_output.rb +66 -0
  175. data/lib/onlinepayments/sdk/domain/redirect_payment_product809_specific_input.rb +26 -0
  176. data/lib/onlinepayments/sdk/domain/redirect_payment_product840_specific_input.rb +26 -0
  177. data/lib/onlinepayments/sdk/domain/redirection_data.rb +26 -0
  178. data/lib/onlinepayments/sdk/domain/refund_card_method_specific_output.rb +30 -0
  179. data/lib/onlinepayments/sdk/domain/refund_e_wallet_method_specific_output.rb +38 -0
  180. data/lib/onlinepayments/sdk/domain/refund_error_response.rb +45 -0
  181. data/lib/onlinepayments/sdk/domain/refund_mobile_method_specific_output.rb +34 -0
  182. data/lib/onlinepayments/sdk/domain/refund_output.rb +82 -0
  183. data/lib/onlinepayments/sdk/domain/refund_payment_product840_customer_account.rb +34 -0
  184. data/lib/onlinepayments/sdk/domain/refund_payment_product840_specific_output.rb +30 -0
  185. data/lib/onlinepayments/sdk/domain/refund_redirect_method_specific_output.rb +30 -0
  186. data/lib/onlinepayments/sdk/domain/refund_request.rb +38 -0
  187. data/lib/onlinepayments/sdk/domain/refund_response.rb +46 -0
  188. data/lib/onlinepayments/sdk/domain/refunds_response.rb +33 -0
  189. data/lib/onlinepayments/sdk/domain/regular_expression_validator.rb +26 -0
  190. data/lib/onlinepayments/sdk/domain/sepa_direct_debit_payment_method_specific_input.rb +34 -0
  191. data/lib/onlinepayments/sdk/domain/sepa_direct_debit_payment_method_specific_input_base.rb +34 -0
  192. data/lib/onlinepayments/sdk/domain/sepa_direct_debit_payment_method_specific_output.rb +42 -0
  193. data/lib/onlinepayments/sdk/domain/sepa_direct_debit_payment_product771_specific_input.rb +34 -0
  194. data/lib/onlinepayments/sdk/domain/sepa_direct_debit_payment_product771_specific_input_base.rb +34 -0
  195. data/lib/onlinepayments/sdk/domain/session_request.rb +32 -0
  196. data/lib/onlinepayments/sdk/domain/session_response.rb +48 -0
  197. data/lib/onlinepayments/sdk/domain/shipping.rb +58 -0
  198. data/lib/onlinepayments/sdk/domain/shopping_cart.rb +64 -0
  199. data/lib/onlinepayments/sdk/domain/shopping_cart_extension.rb +52 -0
  200. data/lib/onlinepayments/sdk/domain/test_connection.rb +26 -0
  201. data/lib/onlinepayments/sdk/domain/three_d_secure.rb +78 -0
  202. data/lib/onlinepayments/sdk/domain/three_d_secure_base.rb +58 -0
  203. data/lib/onlinepayments/sdk/domain/three_d_secure_data.rb +34 -0
  204. data/lib/onlinepayments/sdk/domain/three_d_secure_results.rb +30 -0
  205. data/lib/onlinepayments/sdk/domain/token_card.rb +34 -0
  206. data/lib/onlinepayments/sdk/domain/token_card_data.rb +30 -0
  207. data/lib/onlinepayments/sdk/domain/token_card_specific_input.rb +30 -0
  208. data/lib/onlinepayments/sdk/domain/token_data.rb +30 -0
  209. data/lib/onlinepayments/sdk/domain/token_e_wallet.rb +34 -0
  210. data/lib/onlinepayments/sdk/domain/token_response.rb +58 -0
  211. data/lib/onlinepayments/sdk/domain/value_mapping_element.rb +37 -0
  212. data/lib/onlinepayments/sdk/endpoint_configuration.rb +127 -0
  213. data/lib/onlinepayments/sdk/exceptions.rb +8 -0
  214. data/lib/onlinepayments/sdk/factory.rb +136 -0
  215. data/lib/onlinepayments/sdk/idempotence_exception.rb +24 -0
  216. data/lib/onlinepayments/sdk/logging/communicator_logger.rb +22 -0
  217. data/lib/onlinepayments/sdk/logging/log_message_builder.rb +56 -0
  218. data/lib/onlinepayments/sdk/logging/logging_capable.rb +17 -0
  219. data/lib/onlinepayments/sdk/logging/logging_util.rb +286 -0
  220. data/lib/onlinepayments/sdk/logging/request_log_message_builder.rb +39 -0
  221. data/lib/onlinepayments/sdk/logging/response_log_message_builder.rb +34 -0
  222. data/lib/onlinepayments/sdk/logging/ruby_communicator_logger.rb +57 -0
  223. data/lib/onlinepayments/sdk/logging/stdout_communicator_logger.rb +34 -0
  224. data/lib/onlinepayments/sdk/logging.rb +10 -0
  225. data/lib/onlinepayments/sdk/marshaller.rb +24 -0
  226. data/lib/onlinepayments/sdk/marshaller_syntax_exception.rb +6 -0
  227. data/lib/onlinepayments/sdk/merchant/hostedcheckout/hosted_checkout_client.rb +86 -0
  228. data/lib/onlinepayments/sdk/merchant/hostedtokenization/hosted_tokenization_client.rb +86 -0
  229. data/lib/onlinepayments/sdk/merchant/mandates/mandates_client.rb +182 -0
  230. data/lib/onlinepayments/sdk/merchant/merchant_client.rb +89 -0
  231. data/lib/onlinepayments/sdk/merchant/payments/payments_client.rb +322 -0
  232. data/lib/onlinepayments/sdk/merchant/payouts/payouts_client.rb +86 -0
  233. data/lib/onlinepayments/sdk/merchant/productgroups/get_product_group_params.rb +57 -0
  234. data/lib/onlinepayments/sdk/merchant/productgroups/get_product_groups_params.rb +57 -0
  235. data/lib/onlinepayments/sdk/merchant/productgroups/product_groups_client.rb +87 -0
  236. data/lib/onlinepayments/sdk/merchant/products/get_payment_product_networks_params.rb +38 -0
  237. data/lib/onlinepayments/sdk/merchant/products/get_payment_product_params.rb +57 -0
  238. data/lib/onlinepayments/sdk/merchant/products/get_payment_products_params.rb +57 -0
  239. data/lib/onlinepayments/sdk/merchant/products/get_product_directory_params.rb +30 -0
  240. data/lib/onlinepayments/sdk/merchant/products/products_client.rb +155 -0
  241. data/lib/onlinepayments/sdk/merchant/services/services_client.rb +82 -0
  242. data/lib/onlinepayments/sdk/merchant/sessions/sessions_client.rb +54 -0
  243. data/lib/onlinepayments/sdk/merchant/tokens/tokens_client.rb +116 -0
  244. data/lib/onlinepayments/sdk/meta_data_provider.rb +150 -0
  245. data/lib/onlinepayments/sdk/modules.rb +62 -0
  246. data/lib/onlinepayments/sdk/not_found_exception.rb +16 -0
  247. data/lib/onlinepayments/sdk/param_request.rb +11 -0
  248. data/lib/onlinepayments/sdk/payment_platform_exception.rb +15 -0
  249. data/lib/onlinepayments/sdk/pooled_connection.rb +21 -0
  250. data/lib/onlinepayments/sdk/proxy_configuration.rb +74 -0
  251. data/lib/onlinepayments/sdk/reference_exception.rb +14 -0
  252. data/lib/onlinepayments/sdk/request_header.rb +50 -0
  253. data/lib/onlinepayments/sdk/request_param.rb +23 -0
  254. data/lib/onlinepayments/sdk/response_exception.rb +47 -0
  255. data/lib/onlinepayments/sdk/response_header.rb +42 -0
  256. data/lib/onlinepayments/sdk/validation_exception.rb +14 -0
  257. data/lib/onlinepayments/sdk/webhooks/api_version_mismatch_exception.rb +20 -0
  258. data/lib/onlinepayments/sdk/webhooks/in_memory_secret_key_store.rb +56 -0
  259. data/lib/onlinepayments/sdk/webhooks/secret_key_not_available_exception.rb +17 -0
  260. data/lib/onlinepayments/sdk/webhooks/secret_key_store.rb +16 -0
  261. data/lib/onlinepayments/sdk/webhooks/signature_validation_exception.rb +19 -0
  262. data/lib/onlinepayments/sdk/webhooks/webhooks.rb +22 -0
  263. data/lib/onlinepayments/sdk/webhooks/webhooks_event.rb +58 -0
  264. data/lib/onlinepayments/sdk/webhooks/webhooks_helper.rb +100 -0
  265. data/lib/onlinepayments/sdk/webhooks/webhooks_helper_builder.rb +25 -0
  266. data/lib/onlinepayments/sdk/webhooks.rb +11 -0
  267. data/lib/onlinepayments/sdk.rb +26 -0
  268. data/onlinepayments-sdk-ruby.gemspec +28 -0
  269. metadata +416 -0
@@ -0,0 +1,45 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/api_error'
6
+ require 'onlinepayments/sdk/domain/refund_response'
7
+
8
+ module OnlinePayments::SDK
9
+ module Domain
10
+
11
+ # @attr [String] error_id
12
+ # @attr [Array<OnlinePayments::SDK::Domain::APIError>] errors
13
+ # @attr [OnlinePayments::SDK::Domain::RefundResponse] refund_result
14
+ class RefundErrorResponse < OnlinePayments::SDK::DataObject
15
+ attr_accessor :error_id
16
+ attr_accessor :errors
17
+ attr_accessor :refund_result
18
+
19
+ # @return (Hash)
20
+ def to_h
21
+ hash = super
22
+ hash['errorId'] = @error_id unless @error_id.nil?
23
+ hash['errors'] = @errors.collect(&:to_h) if @errors
24
+ hash['refundResult'] = @refund_result.to_h if @refund_result
25
+ hash
26
+ end
27
+
28
+ def from_hash(hash)
29
+ super
30
+ @error_id = hash['errorId'] if hash.key? 'errorId'
31
+ if hash.key? 'errors'
32
+ raise TypeError, "value '%s' is not an Array" % [hash['errors']] unless hash['errors'].is_a? Array
33
+ @errors = []
34
+ hash['errors'].each do |e|
35
+ @errors << OnlinePayments::SDK::Domain::APIError.new_from_hash(e)
36
+ end
37
+ end
38
+ if hash.key? 'refundResult'
39
+ raise TypeError, "value '%s' is not a Hash" % [hash['refundResult']] unless hash['refundResult'].is_a? Hash
40
+ @refund_result = OnlinePayments::SDK::Domain::RefundResponse.new_from_hash(hash['refundResult'])
41
+ end
42
+ end
43
+ end
44
+ end
45
+ end
@@ -0,0 +1,34 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+
6
+ module OnlinePayments::SDK
7
+ module Domain
8
+
9
+ # @attr [String] network
10
+ # @attr [Long] total_amount_paid
11
+ # @attr [Long] total_amount_refunded
12
+ class RefundMobileMethodSpecificOutput < OnlinePayments::SDK::DataObject
13
+ attr_accessor :network
14
+ attr_accessor :total_amount_paid
15
+ attr_accessor :total_amount_refunded
16
+
17
+ # @return (Hash)
18
+ def to_h
19
+ hash = super
20
+ hash['network'] = @network unless @network.nil?
21
+ hash['totalAmountPaid'] = @total_amount_paid unless @total_amount_paid.nil?
22
+ hash['totalAmountRefunded'] = @total_amount_refunded unless @total_amount_refunded.nil?
23
+ hash
24
+ end
25
+
26
+ def from_hash(hash)
27
+ super
28
+ @network = hash['network'] if hash.key? 'network'
29
+ @total_amount_paid = hash['totalAmountPaid'] if hash.key? 'totalAmountPaid'
30
+ @total_amount_refunded = hash['totalAmountRefunded'] if hash.key? 'totalAmountRefunded'
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,82 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/amount_of_money'
6
+ require 'onlinepayments/sdk/domain/payment_references'
7
+ require 'onlinepayments/sdk/domain/refund_card_method_specific_output'
8
+ require 'onlinepayments/sdk/domain/refund_e_wallet_method_specific_output'
9
+ require 'onlinepayments/sdk/domain/refund_mobile_method_specific_output'
10
+ require 'onlinepayments/sdk/domain/refund_redirect_method_specific_output'
11
+
12
+ module OnlinePayments::SDK
13
+ module Domain
14
+
15
+ # @attr [OnlinePayments::SDK::Domain::AmountOfMoney] amount_of_money
16
+ # @attr [Long] amount_paid
17
+ # @attr [OnlinePayments::SDK::Domain::RefundCardMethodSpecificOutput] card_refund_method_specific_output
18
+ # @attr [OnlinePayments::SDK::Domain::RefundEWalletMethodSpecificOutput] e_wallet_refund_method_specific_output
19
+ # @attr [String] merchant_parameters
20
+ # @attr [OnlinePayments::SDK::Domain::RefundMobileMethodSpecificOutput] mobile_refund_method_specific_output
21
+ # @attr [String] payment_method
22
+ # @attr [OnlinePayments::SDK::Domain::RefundRedirectMethodSpecificOutput] redirect_refund_method_specific_output
23
+ # @attr [OnlinePayments::SDK::Domain::PaymentReferences] references
24
+ class RefundOutput < OnlinePayments::SDK::DataObject
25
+ attr_accessor :amount_of_money
26
+ attr_accessor :amount_paid
27
+ attr_accessor :card_refund_method_specific_output
28
+ attr_accessor :e_wallet_refund_method_specific_output
29
+ attr_accessor :merchant_parameters
30
+ attr_accessor :mobile_refund_method_specific_output
31
+ attr_accessor :payment_method
32
+ attr_accessor :redirect_refund_method_specific_output
33
+ attr_accessor :references
34
+
35
+ # @return (Hash)
36
+ def to_h
37
+ hash = super
38
+ hash['amountOfMoney'] = @amount_of_money.to_h if @amount_of_money
39
+ hash['amountPaid'] = @amount_paid unless @amount_paid.nil?
40
+ hash['cardRefundMethodSpecificOutput'] = @card_refund_method_specific_output.to_h if @card_refund_method_specific_output
41
+ hash['eWalletRefundMethodSpecificOutput'] = @e_wallet_refund_method_specific_output.to_h if @e_wallet_refund_method_specific_output
42
+ hash['merchantParameters'] = @merchant_parameters unless @merchant_parameters.nil?
43
+ hash['mobileRefundMethodSpecificOutput'] = @mobile_refund_method_specific_output.to_h if @mobile_refund_method_specific_output
44
+ hash['paymentMethod'] = @payment_method unless @payment_method.nil?
45
+ hash['redirectRefundMethodSpecificOutput'] = @redirect_refund_method_specific_output.to_h if @redirect_refund_method_specific_output
46
+ hash['references'] = @references.to_h if @references
47
+ hash
48
+ end
49
+
50
+ def from_hash(hash)
51
+ super
52
+ if hash.key? 'amountOfMoney'
53
+ raise TypeError, "value '%s' is not a Hash" % [hash['amountOfMoney']] unless hash['amountOfMoney'].is_a? Hash
54
+ @amount_of_money = OnlinePayments::SDK::Domain::AmountOfMoney.new_from_hash(hash['amountOfMoney'])
55
+ end
56
+ @amount_paid = hash['amountPaid'] if hash.key? 'amountPaid'
57
+ if hash.key? 'cardRefundMethodSpecificOutput'
58
+ raise TypeError, "value '%s' is not a Hash" % [hash['cardRefundMethodSpecificOutput']] unless hash['cardRefundMethodSpecificOutput'].is_a? Hash
59
+ @card_refund_method_specific_output = OnlinePayments::SDK::Domain::RefundCardMethodSpecificOutput.new_from_hash(hash['cardRefundMethodSpecificOutput'])
60
+ end
61
+ if hash.key? 'eWalletRefundMethodSpecificOutput'
62
+ raise TypeError, "value '%s' is not a Hash" % [hash['eWalletRefundMethodSpecificOutput']] unless hash['eWalletRefundMethodSpecificOutput'].is_a? Hash
63
+ @e_wallet_refund_method_specific_output = OnlinePayments::SDK::Domain::RefundEWalletMethodSpecificOutput.new_from_hash(hash['eWalletRefundMethodSpecificOutput'])
64
+ end
65
+ @merchant_parameters = hash['merchantParameters'] if hash.key? 'merchantParameters'
66
+ if hash.key? 'mobileRefundMethodSpecificOutput'
67
+ raise TypeError, "value '%s' is not a Hash" % [hash['mobileRefundMethodSpecificOutput']] unless hash['mobileRefundMethodSpecificOutput'].is_a? Hash
68
+ @mobile_refund_method_specific_output = OnlinePayments::SDK::Domain::RefundMobileMethodSpecificOutput.new_from_hash(hash['mobileRefundMethodSpecificOutput'])
69
+ end
70
+ @payment_method = hash['paymentMethod'] if hash.key? 'paymentMethod'
71
+ if hash.key? 'redirectRefundMethodSpecificOutput'
72
+ raise TypeError, "value '%s' is not a Hash" % [hash['redirectRefundMethodSpecificOutput']] unless hash['redirectRefundMethodSpecificOutput'].is_a? Hash
73
+ @redirect_refund_method_specific_output = OnlinePayments::SDK::Domain::RefundRedirectMethodSpecificOutput.new_from_hash(hash['redirectRefundMethodSpecificOutput'])
74
+ end
75
+ if hash.key? 'references'
76
+ raise TypeError, "value '%s' is not a Hash" % [hash['references']] unless hash['references'].is_a? Hash
77
+ @references = OnlinePayments::SDK::Domain::PaymentReferences.new_from_hash(hash['references'])
78
+ end
79
+ end
80
+ end
81
+ end
82
+ end
@@ -0,0 +1,34 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+
6
+ module OnlinePayments::SDK
7
+ module Domain
8
+
9
+ # @attr [String] customer_account_status
10
+ # @attr [String] customer_address_status
11
+ # @attr [String] payer_id
12
+ class RefundPaymentProduct840CustomerAccount < OnlinePayments::SDK::DataObject
13
+ attr_accessor :customer_account_status
14
+ attr_accessor :customer_address_status
15
+ attr_accessor :payer_id
16
+
17
+ # @return (Hash)
18
+ def to_h
19
+ hash = super
20
+ hash['customerAccountStatus'] = @customer_account_status unless @customer_account_status.nil?
21
+ hash['customerAddressStatus'] = @customer_address_status unless @customer_address_status.nil?
22
+ hash['payerId'] = @payer_id unless @payer_id.nil?
23
+ hash
24
+ end
25
+
26
+ def from_hash(hash)
27
+ super
28
+ @customer_account_status = hash['customerAccountStatus'] if hash.key? 'customerAccountStatus'
29
+ @customer_address_status = hash['customerAddressStatus'] if hash.key? 'customerAddressStatus'
30
+ @payer_id = hash['payerId'] if hash.key? 'payerId'
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,30 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/refund_payment_product840_customer_account'
6
+
7
+ module OnlinePayments::SDK
8
+ module Domain
9
+
10
+ # @attr [OnlinePayments::SDK::Domain::RefundPaymentProduct840CustomerAccount] customer_account
11
+ class RefundPaymentProduct840SpecificOutput < OnlinePayments::SDK::DataObject
12
+ attr_accessor :customer_account
13
+
14
+ # @return (Hash)
15
+ def to_h
16
+ hash = super
17
+ hash['customerAccount'] = @customer_account.to_h if @customer_account
18
+ hash
19
+ end
20
+
21
+ def from_hash(hash)
22
+ super
23
+ if hash.key? 'customerAccount'
24
+ raise TypeError, "value '%s' is not a Hash" % [hash['customerAccount']] unless hash['customerAccount'].is_a? Hash
25
+ @customer_account = OnlinePayments::SDK::Domain::RefundPaymentProduct840CustomerAccount.new_from_hash(hash['customerAccount'])
26
+ end
27
+ end
28
+ end
29
+ end
30
+ end
@@ -0,0 +1,30 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+
6
+ module OnlinePayments::SDK
7
+ module Domain
8
+
9
+ # @attr [Long] total_amount_paid
10
+ # @attr [Long] total_amount_refunded
11
+ class RefundRedirectMethodSpecificOutput < OnlinePayments::SDK::DataObject
12
+ attr_accessor :total_amount_paid
13
+ attr_accessor :total_amount_refunded
14
+
15
+ # @return (Hash)
16
+ def to_h
17
+ hash = super
18
+ hash['totalAmountPaid'] = @total_amount_paid unless @total_amount_paid.nil?
19
+ hash['totalAmountRefunded'] = @total_amount_refunded unless @total_amount_refunded.nil?
20
+ hash
21
+ end
22
+
23
+ def from_hash(hash)
24
+ super
25
+ @total_amount_paid = hash['totalAmountPaid'] if hash.key? 'totalAmountPaid'
26
+ @total_amount_refunded = hash['totalAmountRefunded'] if hash.key? 'totalAmountRefunded'
27
+ end
28
+ end
29
+ end
30
+ end
@@ -0,0 +1,38 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/amount_of_money'
6
+ require 'onlinepayments/sdk/domain/payment_references'
7
+
8
+ module OnlinePayments::SDK
9
+ module Domain
10
+
11
+ # @attr [OnlinePayments::SDK::Domain::AmountOfMoney] amount_of_money
12
+ # @attr [OnlinePayments::SDK::Domain::PaymentReferences] references
13
+ class RefundRequest < OnlinePayments::SDK::DataObject
14
+ attr_accessor :amount_of_money
15
+ attr_accessor :references
16
+
17
+ # @return (Hash)
18
+ def to_h
19
+ hash = super
20
+ hash['amountOfMoney'] = @amount_of_money.to_h if @amount_of_money
21
+ hash['references'] = @references.to_h if @references
22
+ hash
23
+ end
24
+
25
+ def from_hash(hash)
26
+ super
27
+ if hash.key? 'amountOfMoney'
28
+ raise TypeError, "value '%s' is not a Hash" % [hash['amountOfMoney']] unless hash['amountOfMoney'].is_a? Hash
29
+ @amount_of_money = OnlinePayments::SDK::Domain::AmountOfMoney.new_from_hash(hash['amountOfMoney'])
30
+ end
31
+ if hash.key? 'references'
32
+ raise TypeError, "value '%s' is not a Hash" % [hash['references']] unless hash['references'].is_a? Hash
33
+ @references = OnlinePayments::SDK::Domain::PaymentReferences.new_from_hash(hash['references'])
34
+ end
35
+ end
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,46 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/order_status_output'
6
+ require 'onlinepayments/sdk/domain/refund_output'
7
+
8
+ module OnlinePayments::SDK
9
+ module Domain
10
+
11
+ # @attr [String] id
12
+ # @attr [OnlinePayments::SDK::Domain::RefundOutput] refund_output
13
+ # @attr [String] status
14
+ # @attr [OnlinePayments::SDK::Domain::OrderStatusOutput] status_output
15
+ class RefundResponse < OnlinePayments::SDK::DataObject
16
+ attr_accessor :id
17
+ attr_accessor :refund_output
18
+ attr_accessor :status
19
+ attr_accessor :status_output
20
+
21
+ # @return (Hash)
22
+ def to_h
23
+ hash = super
24
+ hash['id'] = @id unless @id.nil?
25
+ hash['refundOutput'] = @refund_output.to_h if @refund_output
26
+ hash['status'] = @status unless @status.nil?
27
+ hash['statusOutput'] = @status_output.to_h if @status_output
28
+ hash
29
+ end
30
+
31
+ def from_hash(hash)
32
+ super
33
+ @id = hash['id'] if hash.key? 'id'
34
+ if hash.key? 'refundOutput'
35
+ raise TypeError, "value '%s' is not a Hash" % [hash['refundOutput']] unless hash['refundOutput'].is_a? Hash
36
+ @refund_output = OnlinePayments::SDK::Domain::RefundOutput.new_from_hash(hash['refundOutput'])
37
+ end
38
+ @status = hash['status'] if hash.key? 'status'
39
+ if hash.key? 'statusOutput'
40
+ raise TypeError, "value '%s' is not a Hash" % [hash['statusOutput']] unless hash['statusOutput'].is_a? Hash
41
+ @status_output = OnlinePayments::SDK::Domain::OrderStatusOutput.new_from_hash(hash['statusOutput'])
42
+ end
43
+ end
44
+ end
45
+ end
46
+ end
@@ -0,0 +1,33 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/refund_response'
6
+
7
+ module OnlinePayments::SDK
8
+ module Domain
9
+
10
+ # @attr [Array<OnlinePayments::SDK::Domain::RefundResponse>] refunds
11
+ class RefundsResponse < OnlinePayments::SDK::DataObject
12
+ attr_accessor :refunds
13
+
14
+ # @return (Hash)
15
+ def to_h
16
+ hash = super
17
+ hash['refunds'] = @refunds.collect(&:to_h) if @refunds
18
+ hash
19
+ end
20
+
21
+ def from_hash(hash)
22
+ super
23
+ if hash.key? 'refunds'
24
+ raise TypeError, "value '%s' is not an Array" % [hash['refunds']] unless hash['refunds'].is_a? Array
25
+ @refunds = []
26
+ hash['refunds'].each do |e|
27
+ @refunds << OnlinePayments::SDK::Domain::RefundResponse.new_from_hash(e)
28
+ end
29
+ end
30
+ end
31
+ end
32
+ end
33
+ end
@@ -0,0 +1,26 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+
6
+ module OnlinePayments::SDK
7
+ module Domain
8
+
9
+ # @attr [String] regular_expression
10
+ class RegularExpressionValidator < OnlinePayments::SDK::DataObject
11
+ attr_accessor :regular_expression
12
+
13
+ # @return (Hash)
14
+ def to_h
15
+ hash = super
16
+ hash['regularExpression'] = @regular_expression unless @regular_expression.nil?
17
+ hash
18
+ end
19
+
20
+ def from_hash(hash)
21
+ super
22
+ @regular_expression = hash['regularExpression'] if hash.key? 'regularExpression'
23
+ end
24
+ end
25
+ end
26
+ end
@@ -0,0 +1,34 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/sepa_direct_debit_payment_product771_specific_input'
6
+
7
+ module OnlinePayments::SDK
8
+ module Domain
9
+
10
+ # @attr [OnlinePayments::SDK::Domain::SepaDirectDebitPaymentProduct771SpecificInput] payment_product771_specific_input
11
+ # @attr [Integer] payment_product_id
12
+ class SepaDirectDebitPaymentMethodSpecificInput < OnlinePayments::SDK::DataObject
13
+ attr_accessor :payment_product771_specific_input
14
+ attr_accessor :payment_product_id
15
+
16
+ # @return (Hash)
17
+ def to_h
18
+ hash = super
19
+ hash['paymentProduct771SpecificInput'] = @payment_product771_specific_input.to_h if @payment_product771_specific_input
20
+ hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
21
+ hash
22
+ end
23
+
24
+ def from_hash(hash)
25
+ super
26
+ if hash.key? 'paymentProduct771SpecificInput'
27
+ raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct771SpecificInput']] unless hash['paymentProduct771SpecificInput'].is_a? Hash
28
+ @payment_product771_specific_input = OnlinePayments::SDK::Domain::SepaDirectDebitPaymentProduct771SpecificInput.new_from_hash(hash['paymentProduct771SpecificInput'])
29
+ end
30
+ @payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId'
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,34 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/sepa_direct_debit_payment_product771_specific_input_base'
6
+
7
+ module OnlinePayments::SDK
8
+ module Domain
9
+
10
+ # @attr [OnlinePayments::SDK::Domain::SepaDirectDebitPaymentProduct771SpecificInputBase] payment_product771_specific_input
11
+ # @attr [Integer] payment_product_id
12
+ class SepaDirectDebitPaymentMethodSpecificInputBase < OnlinePayments::SDK::DataObject
13
+ attr_accessor :payment_product771_specific_input
14
+ attr_accessor :payment_product_id
15
+
16
+ # @return (Hash)
17
+ def to_h
18
+ hash = super
19
+ hash['paymentProduct771SpecificInput'] = @payment_product771_specific_input.to_h if @payment_product771_specific_input
20
+ hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
21
+ hash
22
+ end
23
+
24
+ def from_hash(hash)
25
+ super
26
+ if hash.key? 'paymentProduct771SpecificInput'
27
+ raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct771SpecificInput']] unless hash['paymentProduct771SpecificInput'].is_a? Hash
28
+ @payment_product771_specific_input = OnlinePayments::SDK::Domain::SepaDirectDebitPaymentProduct771SpecificInputBase.new_from_hash(hash['paymentProduct771SpecificInput'])
29
+ end
30
+ @payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId'
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,42 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/fraud_results'
6
+ require 'onlinepayments/sdk/domain/payment_product771_specific_output'
7
+
8
+ module OnlinePayments::SDK
9
+ module Domain
10
+
11
+ # @attr [OnlinePayments::SDK::Domain::FraudResults] fraud_results
12
+ # @attr [OnlinePayments::SDK::Domain::PaymentProduct771SpecificOutput] payment_product771_specific_output
13
+ # @attr [Integer] payment_product_id
14
+ class SepaDirectDebitPaymentMethodSpecificOutput < OnlinePayments::SDK::DataObject
15
+ attr_accessor :fraud_results
16
+ attr_accessor :payment_product771_specific_output
17
+ attr_accessor :payment_product_id
18
+
19
+ # @return (Hash)
20
+ def to_h
21
+ hash = super
22
+ hash['fraudResults'] = @fraud_results.to_h if @fraud_results
23
+ hash['paymentProduct771SpecificOutput'] = @payment_product771_specific_output.to_h if @payment_product771_specific_output
24
+ hash['paymentProductId'] = @payment_product_id unless @payment_product_id.nil?
25
+ hash
26
+ end
27
+
28
+ def from_hash(hash)
29
+ super
30
+ if hash.key? 'fraudResults'
31
+ raise TypeError, "value '%s' is not a Hash" % [hash['fraudResults']] unless hash['fraudResults'].is_a? Hash
32
+ @fraud_results = OnlinePayments::SDK::Domain::FraudResults.new_from_hash(hash['fraudResults'])
33
+ end
34
+ if hash.key? 'paymentProduct771SpecificOutput'
35
+ raise TypeError, "value '%s' is not a Hash" % [hash['paymentProduct771SpecificOutput']] unless hash['paymentProduct771SpecificOutput'].is_a? Hash
36
+ @payment_product771_specific_output = OnlinePayments::SDK::Domain::PaymentProduct771SpecificOutput.new_from_hash(hash['paymentProduct771SpecificOutput'])
37
+ end
38
+ @payment_product_id = hash['paymentProductId'] if hash.key? 'paymentProductId'
39
+ end
40
+ end
41
+ end
42
+ end
@@ -0,0 +1,34 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/create_mandate_with_return_url'
6
+
7
+ module OnlinePayments::SDK
8
+ module Domain
9
+
10
+ # @attr [String] existing_unique_mandate_reference
11
+ # @attr [OnlinePayments::SDK::Domain::CreateMandateWithReturnUrl] mandate
12
+ class SepaDirectDebitPaymentProduct771SpecificInput < OnlinePayments::SDK::DataObject
13
+ attr_accessor :existing_unique_mandate_reference
14
+ attr_accessor :mandate
15
+
16
+ # @return (Hash)
17
+ def to_h
18
+ hash = super
19
+ hash['existingUniqueMandateReference'] = @existing_unique_mandate_reference unless @existing_unique_mandate_reference.nil?
20
+ hash['mandate'] = @mandate.to_h if @mandate
21
+ hash
22
+ end
23
+
24
+ def from_hash(hash)
25
+ super
26
+ @existing_unique_mandate_reference = hash['existingUniqueMandateReference'] if hash.key? 'existingUniqueMandateReference'
27
+ if hash.key? 'mandate'
28
+ raise TypeError, "value '%s' is not a Hash" % [hash['mandate']] unless hash['mandate'].is_a? Hash
29
+ @mandate = OnlinePayments::SDK::Domain::CreateMandateWithReturnUrl.new_from_hash(hash['mandate'])
30
+ end
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,34 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+ require 'onlinepayments/sdk/domain/create_mandate_request'
6
+
7
+ module OnlinePayments::SDK
8
+ module Domain
9
+
10
+ # @attr [String] existing_unique_mandate_reference
11
+ # @attr [OnlinePayments::SDK::Domain::CreateMandateRequest] mandate
12
+ class SepaDirectDebitPaymentProduct771SpecificInputBase < OnlinePayments::SDK::DataObject
13
+ attr_accessor :existing_unique_mandate_reference
14
+ attr_accessor :mandate
15
+
16
+ # @return (Hash)
17
+ def to_h
18
+ hash = super
19
+ hash['existingUniqueMandateReference'] = @existing_unique_mandate_reference unless @existing_unique_mandate_reference.nil?
20
+ hash['mandate'] = @mandate.to_h if @mandate
21
+ hash
22
+ end
23
+
24
+ def from_hash(hash)
25
+ super
26
+ @existing_unique_mandate_reference = hash['existingUniqueMandateReference'] if hash.key? 'existingUniqueMandateReference'
27
+ if hash.key? 'mandate'
28
+ raise TypeError, "value '%s' is not a Hash" % [hash['mandate']] unless hash['mandate'].is_a? Hash
29
+ @mandate = OnlinePayments::SDK::Domain::CreateMandateRequest.new_from_hash(hash['mandate'])
30
+ end
31
+ end
32
+ end
33
+ end
34
+ end
@@ -0,0 +1,32 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+
6
+ module OnlinePayments::SDK
7
+ module Domain
8
+
9
+ # @attr [Array<String>] tokens
10
+ class SessionRequest < OnlinePayments::SDK::DataObject
11
+ attr_accessor :tokens
12
+
13
+ # @return (Hash)
14
+ def to_h
15
+ hash = super
16
+ hash['tokens'] = @tokens unless @tokens.nil?
17
+ hash
18
+ end
19
+
20
+ def from_hash(hash)
21
+ super
22
+ if hash.key? 'tokens'
23
+ raise TypeError, "value '%s' is not an Array" % [hash['tokens']] unless hash['tokens'].is_a? Array
24
+ @tokens = []
25
+ hash['tokens'].each do |e|
26
+ @tokens << e
27
+ end
28
+ end
29
+ end
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,48 @@
1
+ #
2
+ # This class was auto-generated.
3
+ #
4
+ require 'onlinepayments/sdk/data_object'
5
+
6
+ module OnlinePayments::SDK
7
+ module Domain
8
+
9
+ # @attr [String] asset_url
10
+ # @attr [String] client_api_url
11
+ # @attr [String] client_session_id
12
+ # @attr [String] customer_id
13
+ # @attr [Array<String>] invalid_tokens
14
+ class SessionResponse < OnlinePayments::SDK::DataObject
15
+ attr_accessor :asset_url
16
+ attr_accessor :client_api_url
17
+ attr_accessor :client_session_id
18
+ attr_accessor :customer_id
19
+ attr_accessor :invalid_tokens
20
+
21
+ # @return (Hash)
22
+ def to_h
23
+ hash = super
24
+ hash['assetUrl'] = @asset_url unless @asset_url.nil?
25
+ hash['clientApiUrl'] = @client_api_url unless @client_api_url.nil?
26
+ hash['clientSessionId'] = @client_session_id unless @client_session_id.nil?
27
+ hash['customerId'] = @customer_id unless @customer_id.nil?
28
+ hash['invalidTokens'] = @invalid_tokens unless @invalid_tokens.nil?
29
+ hash
30
+ end
31
+
32
+ def from_hash(hash)
33
+ super
34
+ @asset_url = hash['assetUrl'] if hash.key? 'assetUrl'
35
+ @client_api_url = hash['clientApiUrl'] if hash.key? 'clientApiUrl'
36
+ @client_session_id = hash['clientSessionId'] if hash.key? 'clientSessionId'
37
+ @customer_id = hash['customerId'] if hash.key? 'customerId'
38
+ if hash.key? 'invalidTokens'
39
+ raise TypeError, "value '%s' is not an Array" % [hash['invalidTokens']] unless hash['invalidTokens'].is_a? Array
40
+ @invalid_tokens = []
41
+ hash['invalidTokens'].each do |e|
42
+ @invalid_tokens << e
43
+ end
44
+ end
45
+ end
46
+ end
47
+ end
48
+ end