cybersource_rest_client 0.0.84 → 0.0.85

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 (272) hide show
  1. checksums.yaml +4 -4
  2. data/lib/AuthenticationSDK/core/MerchantConfig.rb +11 -10
  3. data/lib/AuthenticationSDK/logging/sensitive_logging.rb +265 -93
  4. data/lib/AuthenticationSDK/util/AuthJWEUtility.rb +53 -3
  5. data/lib/AuthenticationSDK/util/Cache.rb +13 -8
  6. data/lib/AuthenticationSDK/util/Constants.rb +87 -32
  7. data/lib/AuthenticationSDK/util/MLEUtility.rb +42 -2
  8. data/lib/cybersource_rest_client/api/{instructions_api.rb → agent_capabilities_api.rb} +106 -25
  9. data/lib/cybersource_rest_client/api/billing_agreements_api.rb +6 -6
  10. data/lib/cybersource_rest_client/api/capture_api.rb +2 -2
  11. data/lib/cybersource_rest_client/api/credentials_api.rb +1 -1
  12. data/lib/cybersource_rest_client/api/credit_api.rb +2 -2
  13. data/lib/cybersource_rest_client/api/invoice_settings_api.rb +2 -2
  14. data/lib/cybersource_rest_client/api/invoices_api.rb +6 -6
  15. data/lib/cybersource_rest_client/api/merchant_boarding_api.rb +2 -2
  16. data/lib/cybersource_rest_client/api/orders_api.rb +4 -4
  17. data/lib/cybersource_rest_client/api/payment_links_api.rb +4 -4
  18. data/lib/cybersource_rest_client/api/payment_tokens_api.rb +2 -2
  19. data/lib/cybersource_rest_client/api/payments_api.rb +21 -21
  20. data/lib/cybersource_rest_client/api/refund_api.rb +4 -4
  21. data/lib/cybersource_rest_client/api/reversal_api.rb +4 -4
  22. data/lib/cybersource_rest_client/api/void_api.rb +10 -10
  23. data/lib/cybersource_rest_client/api_client.rb +31 -2
  24. data/lib/cybersource_rest_client/configuration.rb +2 -2
  25. data/lib/cybersource_rest_client/models/{commerce_solutions_products_account_updater_configuration_information_configurations.rb → account_updater_configurations.rb} +4 -4
  26. data/lib/cybersource_rest_client/models/{commerce_solutions_products_account_updater_configuration_information_configurations_amex.rb → account_updater_configurations_amex.rb} +1 -1
  27. data/lib/cybersource_rest_client/models/{commerce_solutions_products_account_updater_configuration_information_configurations_master_card.rb → account_updater_configurations_master_card.rb} +1 -1
  28. data/lib/cybersource_rest_client/models/{commerce_solutions_products_account_updater_configuration_information_configurations_visa.rb → account_updater_configurations_visa.rb} +1 -1
  29. data/lib/cybersource_rest_client/models/{ptsv1pullfundstransfer_processing_information_funding_options.rb → aft_funding_options.rb} +2 -2
  30. data/lib/cybersource_rest_client/models/{ptsv1pullfundstransfer_processing_information_funding_options_initiator.rb → aft_funding_options_initiator.rb} +2 -2
  31. data/lib/cybersource_rest_client/models/{ptsv1pullfundstransfer_processing_info_funding_options_initiator_origin_ini_transaction.rb → aft_funding_options_initiator_originator_initiated_transaction.rb} +1 -1
  32. data/lib/cybersource_rest_client/models/agentic_cancel_purchase_intent_request.rb +3 -3
  33. data/lib/cybersource_rest_client/models/agentic_card_enrollment_request.rb +8 -8
  34. data/lib/cybersource_rest_client/models/agentic_confirm_transaction_events_request.rb +2 -2
  35. data/lib/cybersource_rest_client/models/agentic_create_purchase_intent_request.rb +5 -5
  36. data/lib/cybersource_rest_client/models/agentic_retrieve_payment_credentials_request.rb +2 -2
  37. data/lib/cybersource_rest_client/models/agentic_retrieve_payment_credentials_response200.rb +1 -1
  38. data/lib/cybersource_rest_client/models/agentic_update_purchase_intent_request.rb +5 -5
  39. data/lib/cybersource_rest_client/models/{payments_products_alternative_payment_methods_configuration_information_configurations_processors.rb → alternative_payments_processor_configuration.rb} +1 -1
  40. data/lib/cybersource_rest_client/models/bin_lookup403_response.rb +223 -0
  41. data/lib/cybersource_rest_client/models/bin_lookupv400_response.rb +235 -0
  42. data/lib/cybersource_rest_client/models/{card_processing_config_common_acquirer_agreement_acquirer_code.rb → boarding_acquirer_details.rb} +2 -2
  43. data/lib/cybersource_rest_client/models/{card_processing_config_common_acquirer_agreement_acquirer_code_payment_options.rb → boarding_acquirer_details_payment_options.rb} +1 -1
  44. data/lib/cybersource_rest_client/models/{boardingv1registrations_organization_information_business_information.rb → boarding_business_information.rb} +6 -6
  45. data/lib/cybersource_rest_client/models/{boardingv1registrations_organization_information_business_information_address.rb → boarding_business_information_address.rb} +1 -1
  46. data/lib/cybersource_rest_client/models/{boardingv1registrations_organization_information_business_information_business_contact.rb → boarding_business_information_business_contact.rb} +1 -1
  47. data/lib/cybersource_rest_client/models/{boardingv1registrations_organization_information_business_information_localized_names.rb → boarding_business_information_localized_names.rb} +1 -1
  48. data/lib/cybersource_rest_client/models/{payments_products_payouts_configuration_information_configurations.rb → boarding_payouts_configurations.rb} +2 -2
  49. data/lib/cybersource_rest_client/models/{payments_products_payouts_configuration_information_configurations_common.rb → boarding_payouts_configurations_common.rb} +2 -2
  50. data/lib/cybersource_rest_client/models/{payments_products_payouts_configuration_information_configurations_common_aggregator.rb → boarding_payouts_configurations_common_aggregator.rb} +1 -1
  51. data/lib/cybersource_rest_client/models/boardingv1registrations_organization_information.rb +1 -1
  52. data/lib/cybersource_rest_client/models/boardingv1registrations_organization_information_owners.rb +1 -1
  53. data/lib/cybersource_rest_client/models/card_processing_config_common_acquirer_agreement.rb +1 -1
  54. data/lib/cybersource_rest_client/models/commerce_solutions_products_account_updater_configuration_information.rb +1 -1
  55. data/lib/cybersource_rest_client/models/create_subscription_response.rb +1 -1
  56. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument.rb → default_payment_instrument.rb} +9 -9
  57. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument__embedded.rb → default_payment_instrument__embedded.rb} +1 -1
  58. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument__links.rb → default_payment_instrument__links.rb} +2 -2
  59. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument__links_self.rb → default_payment_instrument__links_self.rb} +1 -1
  60. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument_bank_account.rb → default_payment_instrument_bank_account.rb} +1 -1
  61. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument_bill_to.rb → default_payment_instrument_bill_to.rb} +1 -1
  62. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument_buyer_information.rb → default_payment_instrument_buyer_information.rb} +2 -2
  63. data/lib/cybersource_rest_client/models/{tmsv2tokenize_default_payment_instrument_buyer_info_issued_by.rb → default_payment_instrument_buyer_information_issued_by.rb} +1 -1
  64. data/lib/cybersource_rest_client/models/{tmsv2tokenize_default_payment_instrument_buyer_info_personal_identification.rb → default_payment_instrument_buyer_information_personal_identification.rb} +2 -2
  65. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument_card.rb → default_payment_instrument_card.rb} +2 -2
  66. data/lib/cybersource_rest_client/models/{tmsv2tokenize_default_payment_instrument_card_tokenized_info.rb → default_payment_instrument_card_tokenized_information.rb} +1 -1
  67. data/lib/cybersource_rest_client/models/{tmsv2tokenize_default_payment_instrument_instrument_identifier.rb → default_payment_instrument_instrument_identifier.rb} +1 -1
  68. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_payment_instrument_metadata.rb → default_payment_instrument_metadata.rb} +1 -1
  69. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_shipping_address.rb → default_shipping_address.rb} +4 -4
  70. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_shipping_address__links.rb → default_shipping_address__links.rb} +3 -3
  71. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_shipping_address__links_customer.rb → default_shipping_address__links_customer.rb} +1 -1
  72. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_shipping_address__links_self.rb → default_shipping_address__links_self.rb} +1 -1
  73. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_shipping_address_metadata.rb → default_shipping_address_metadata.rb} +1 -1
  74. data/lib/cybersource_rest_client/models/{tmsv2tokenize_token_information_customer__embedded_default_shipping_address_ship_to.rb → default_shipping_address_ship_to.rb} +1 -1
  75. data/lib/cybersource_rest_client/models/{pts_v2_payments_post201_response_watchlist_screening_information_watch_list.rb → export_compliance_watch_list.rb} +2 -2
  76. data/lib/cybersource_rest_client/models/{pts_v2_payments_post201_response_watchlist_screening_information_watch_list_matches.rb → export_compliance_watch_list_matches.rb} +1 -1
  77. data/lib/cybersource_rest_client/models/{get_subscription_response_1_payment_instrument_buyer_information.rb → follow_on_transaction_buyer_information.rb} +2 -2
  78. data/lib/cybersource_rest_client/models/generate_unified_checkout_v1_capture_context_request.rb +2 -2
  79. data/lib/cybersource_rest_client/models/get_subscription_response_1_payment_instrument.rb +2 -2
  80. data/lib/cybersource_rest_client/models/get_subscription_response_1_shipping_address.rb +1 -1
  81. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_order_information_amount_detail.rb → icc_amount_detail.rb} +1 -1
  82. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_order_information_items.rb → icc_line_item.rb} +4 -4
  83. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_order_information_items_additional_info.rb → icc_line_item_additional_info.rb} +1 -1
  84. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_order_information_items_policies.rb → icc_line_item_policies.rb} +1 -1
  85. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_merchant_information_merchant_descriptor.rb → icc_merchant_descriptor.rb} +1 -1
  86. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idconfirmations_processor_information_payment_instrument.rb → icc_payment_instrument.rb} +2 -2
  87. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idconf_processor_info_payment_instrument_verifi_results.rb → icc_payment_instrument_verification_results.rb} +1 -1
  88. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idconfirmations_order_information_shipping_details.rb → icc_shipping_details.rb} +1 -1
  89. data/lib/cybersource_rest_client/models/{agentic_retrieve_payment_credentials_response200_transaction_response_with_pending_events.rb → icc_transaction_response_pending_events.rb} +1 -1
  90. data/lib/cybersource_rest_client/models/{acpv1instructions_decline_threshold.rb → iccv1instructions_decline_threshold.rb} +1 -1
  91. data/lib/cybersource_rest_client/models/{acpv1instructions_mandates.rb → iccv1instructions_mandates.rb} +3 -3
  92. data/lib/cybersource_rest_client/models/{acpv1instructions_recurring_payment_information.rb → iccv1instructions_recurring_payment_information.rb} +1 -1
  93. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idconfirmations_confirmation_data.rb → iccv1instructionsinstruction_idconfirmations_confirmation_data.rb} +5 -5
  94. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idconfirmations_merchant_information.rb → iccv1instructionsinstruction_idconfirmations_merchant_information.rb} +1 -1
  95. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idconfirmations_order_information.rb → iccv1instructionsinstruction_idconfirmations_order_information.rb} +5 -5
  96. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idconfirmations_processor_information.rb → iccv1instructionsinstruction_idconfirmations_processor_information.rb} +3 -3
  97. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_attachments.rb → iccv1instructionsinstruction_idcredentials_attachments.rb} +1 -1
  98. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_client_reference_information.rb → iccv1instructionsinstruction_idcredentials_client_reference_information.rb} +1 -1
  99. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_mandate_reference_data.rb → iccv1instructionsinstruction_idcredentials_mandate_reference_data.rb} +1 -1
  100. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_merchant_information.rb → iccv1instructionsinstruction_idcredentials_merchant_information.rb} +2 -2
  101. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_order_information.rb → iccv1instructionsinstruction_idcredentials_order_information.rb} +4 -4
  102. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_order_information_line_items.rb → iccv1instructionsinstruction_idcredentials_order_information_line_items.rb} +2 -2
  103. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_order_information_ship_to.rb → iccv1instructionsinstruction_idcredentials_order_information_ship_to.rb} +1 -1
  104. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_payment_options.rb → iccv1instructionsinstruction_idcredentials_payment_options.rb} +1 -1
  105. data/lib/cybersource_rest_client/models/{acpv1instructionsinstruction_idcredentials_transaction_data.rb → iccv1instructionsinstruction_idcredentials_transaction_data.rb} +7 -7
  106. data/lib/cybersource_rest_client/models/{acpv1mppcredentials_challenge.rb → iccv1mppcredentials_challenge.rb} +2 -2
  107. data/lib/cybersource_rest_client/models/{acpv1mppcredentials_challenge_encryption_jwk.rb → iccv1mppcredentials_challenge_encryption_jwk.rb} +1 -1
  108. data/lib/cybersource_rest_client/models/{acpv1tokens_assurance_data.rb → iccv1tokens_assurance_data.rb} +3 -3
  109. data/lib/cybersource_rest_client/models/{acpv1tokens_authenticated_identities.rb → iccv1tokens_authenticated_identities.rb} +1 -1
  110. data/lib/cybersource_rest_client/models/{acpv1tokens_authentication_context.rb → iccv1tokens_authentication_context.rb} +1 -1
  111. data/lib/cybersource_rest_client/models/{acpv1tokens_bill_to.rb → iccv1tokens_bill_to.rb} +1 -1
  112. data/lib/cybersource_rest_client/models/{acpv1tokens_buyer_information.rb → iccv1tokens_buyer_information.rb} +2 -2
  113. data/lib/cybersource_rest_client/models/{acpv1tokens_buyer_information_personal_identification.rb → iccv1tokens_buyer_information_personal_identification.rb} +9 -9
  114. data/lib/cybersource_rest_client/models/{acpv1tokens_consent_data.rb → iccv1tokens_consent_data.rb} +1 -1
  115. data/lib/cybersource_rest_client/models/{acpv1tokens_consumer_identity.rb → iccv1tokens_consumer_identity.rb} +1 -1
  116. data/lib/cybersource_rest_client/models/{acpv1tokens_device_information.rb → iccv1tokens_device_information.rb} +2 -2
  117. data/lib/cybersource_rest_client/models/{acpv1tokens_device_information_device_data.rb → iccv1tokens_device_information_device_data.rb} +1 -1
  118. data/lib/cybersource_rest_client/models/{acpv1tokens_enrollment_reference_data.rb → iccv1tokens_enrollment_reference_data.rb} +1 -1
  119. data/lib/cybersource_rest_client/models/{acpv1tokens_payment_information.rb → iccv1tokens_payment_information.rb} +4 -4
  120. data/lib/cybersource_rest_client/models/{acpv1tokens_payment_information_customer.rb → iccv1tokens_payment_information_customer.rb} +1 -1
  121. data/lib/cybersource_rest_client/models/{acpv1tokens_payment_information_instrument_identifier.rb → iccv1tokens_payment_information_instrument_identifier.rb} +1 -1
  122. data/lib/cybersource_rest_client/models/{acpv1tokens_payment_information_payment_instrument.rb → iccv1tokens_payment_information_payment_instrument.rb} +1 -1
  123. data/lib/cybersource_rest_client/models/inline_response_201_4_setups.rb +1 -1
  124. data/lib/cybersource_rest_client/models/inline_response_201_4_setups_commerce_solutions.rb +4 -4
  125. data/lib/cybersource_rest_client/models/inline_response_201_4_setups_risk.rb +3 -3
  126. data/lib/cybersource_rest_client/models/inline_response_201_4_setups_value_added_services.rb +5 -5
  127. data/lib/cybersource_rest_client/models/inline_response_400_11.rb +42 -35
  128. data/lib/cybersource_rest_client/models/inline_response_400_12.rb +16 -62
  129. data/lib/cybersource_rest_client/models/{inline_response_400_11_details.rb → inline_response_400_12_details.rb} +1 -1
  130. data/lib/cybersource_rest_client/models/inline_response_400_13.rb +281 -0
  131. data/lib/cybersource_rest_client/models/inline_response_502.rb +9 -53
  132. data/lib/cybersource_rest_client/models/inline_response_502_1.rb +24 -12
  133. data/lib/cybersource_rest_client/models/inline_response_502_2.rb +19 -47
  134. data/lib/cybersource_rest_client/models/inline_response_502_3.rb +251 -0
  135. data/lib/cybersource_rest_client/models/{payments_products_microform_configuration_information_configurations_features.rb → microform_config_features.rb} +2 -2
  136. data/lib/cybersource_rest_client/models/{payments_products_microform_configuration_information_configurations_features_gateway_agnostic.rb → microform_config_features_gateway_agnostic.rb} +1 -1
  137. data/lib/cybersource_rest_client/models/mpp_credentials_request.rb +1 -1
  138. data/lib/cybersource_rest_client/models/patch_customer_payment_instrument_request.rb +7 -7
  139. data/lib/cybersource_rest_client/models/patch_customer_shipping_address_request.rb +3 -3
  140. data/lib/cybersource_rest_client/models/patch_instrument_identifier_request.rb +1 -1
  141. data/lib/cybersource_rest_client/models/patch_payment_instrument_request.rb +7 -7
  142. data/lib/cybersource_rest_client/models/{payment_instrument_list__embedded_payment_instruments.rb → payment_instrument.rb} +8 -8
  143. data/lib/cybersource_rest_client/models/payment_instrument_list__embedded.rb +1 -1
  144. data/lib/cybersource_rest_client/models/{inline_response_201_4_setups_payments.rb → payments_configuration_setup.rb} +23 -23
  145. data/lib/cybersource_rest_client/models/{inline_response_201_4_setups_payments_alternative_payment_methods.rb → payments_configuration_setup_alternative_payment_methods.rb} +3 -3
  146. data/lib/cybersource_rest_client/models/{inline_response_201_4_setups_payments_alternative_payment_methods_configuration_status.rb → payments_configuration_setup_alternative_payment_methods_configuration_status.rb} +1 -1
  147. data/lib/cybersource_rest_client/models/{inline_response_201_4_setups_payments_card_processing.rb → payments_configuration_setup_card_processing.rb} +3 -3
  148. data/lib/cybersource_rest_client/models/{inline_response_201_4_setups_payments_card_processing_configuration_status.rb → payments_configuration_setup_card_processing_configuration_status.rb} +1 -1
  149. data/lib/cybersource_rest_client/models/{inline_response_201_4_setups_payments_card_processing_subscription_status.rb → payments_configuration_setup_card_processing_subscription_status.rb} +1 -1
  150. data/lib/cybersource_rest_client/models/{inline_response_201_4_setups_payments_digital_payments.rb → payments_configuration_setup_digital_payments.rb} +2 -2
  151. data/lib/cybersource_rest_client/models/payments_products_alternative_payment_methods_configuration_information_configurations.rb +1 -1
  152. data/lib/cybersource_rest_client/models/payments_products_microform_configuration_information_configurations.rb +1 -1
  153. data/lib/cybersource_rest_client/models/payments_products_payouts_configuration_information.rb +1 -1
  154. data/lib/cybersource_rest_client/models/payments_products_unified_checkout_configuration_information.rb +1 -1
  155. data/lib/cybersource_rest_client/models/payments_products_unified_checkout_subscription_information.rb +1 -1
  156. data/lib/cybersource_rest_client/models/post_customer_payment_instrument_request.rb +7 -7
  157. data/lib/cybersource_rest_client/models/post_customer_shipping_address_request.rb +3 -3
  158. data/lib/cybersource_rest_client/models/post_instrument_identifier_enrollment_request.rb +1 -1
  159. data/lib/cybersource_rest_client/models/post_instrument_identifier_request.rb +1 -1
  160. data/lib/cybersource_rest_client/models/post_issuer_life_cycle_simulation_request.rb +1 -1
  161. data/lib/cybersource_rest_client/models/post_payment_credentials_request.rb +1 -1
  162. data/lib/cybersource_rest_client/models/post_payment_credentials_request_1.rb +1 -1
  163. data/lib/cybersource_rest_client/models/post_payment_instrument_request.rb +7 -7
  164. data/lib/cybersource_rest_client/models/{ptsv2payments_processing_information_authorization_options.rb → processing_info_authorization_options.rb} +2 -2
  165. data/lib/cybersource_rest_client/models/{ptsv2payments_processing_information_authorization_options_initiator.rb → processing_info_authorization_options_initiator.rb} +2 -2
  166. data/lib/cybersource_rest_client/models/{ptsv2payments_merchant_initiated_transaction.rb → processing_info_authorization_options_initiator_merchant_initiated_transaction.rb} +4 -4
  167. data/lib/cybersource_rest_client/models/{pts_v2_payments_post201_response_processor_information_seller_protection.rb → processor_information_seller_protection.rb} +1 -1
  168. data/lib/cybersource_rest_client/models/pts_v2_credits_post201_response.rb +1 -1
  169. data/lib/cybersource_rest_client/models/pts_v2_incremental_authorization_patch201_response_processor_information.rb +1 -1
  170. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_1_processor_information.rb +1 -1
  171. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_processor_information.rb +1 -1
  172. data/lib/cybersource_rest_client/models/pts_v2_payments_post201_response_watchlist_screening_information.rb +1 -1
  173. data/lib/cybersource_rest_client/models/pts_v2_payouts_post201_response_issuer_information.rb +166 -1
  174. data/lib/cybersource_rest_client/models/ptsv1pullfundstransfer_processing_information.rb +1 -1
  175. data/lib/cybersource_rest_client/models/ptsv1pushfundstransfer_recipient_information.rb +1 -1
  176. data/lib/cybersource_rest_client/models/ptsv2credits_processing_information.rb +1 -1
  177. data/lib/cybersource_rest_client/models/ptsv2credits_processing_information_refund_options.rb +22 -5
  178. data/lib/cybersource_rest_client/models/ptsv2payments_processing_information.rb +2 -2
  179. data/lib/cybersource_rest_client/models/ptsv2payments_processor_information.rb +22 -5
  180. data/lib/cybersource_rest_client/models/ptsv2paymentsidcaptures_processing_information.rb +1 -1
  181. data/lib/cybersource_rest_client/models/ptsv2paymentsidrefunds_processing_information.rb +1 -1
  182. data/lib/cybersource_rest_client/models/ptsv2paymentsidrefunds_processing_information_refund_options.rb +22 -5
  183. data/lib/cybersource_rest_client/models/ptsv2paymentsidreversals_processing_information.rb +1 -1
  184. data/lib/cybersource_rest_client/models/push_funds201_response.rb +11 -1
  185. data/lib/cybersource_rest_client/models/push_funds201_response_issuer_information.rb +344 -0
  186. data/lib/cybersource_rest_client/models/{ptsv1pushfundstransfer_recipient_information_payment_information.rb → push_funds_transfer_payment_information.rb} +2 -2
  187. data/lib/cybersource_rest_client/models/{ptsv1pushfundstransfer_recipient_information_payment_information_card.rb → push_funds_transfer_payment_information_card.rb} +4 -4
  188. data/lib/cybersource_rest_client/models/{ptsv1pushfundstransfer_recipient_information_payment_information_card_customer.rb → push_funds_transfer_payment_information_card_customer.rb} +1 -1
  189. data/lib/cybersource_rest_client/models/{ptsv1pushfundstransfer_recipient_information_payment_information_card_instrument_identifier.rb → push_funds_transfer_payment_information_card_instrument_identifier.rb} +1 -1
  190. data/lib/cybersource_rest_client/models/{ptsv1pushfundstransfer_recipient_information_payment_information_card_payment_instrument.rb → push_funds_transfer_payment_information_card_payment_instrument.rb} +1 -1
  191. data/lib/cybersource_rest_client/models/{rbsv1subscriptions_processing_information_authorization_options.rb → rbs_authorization_options.rb} +2 -2
  192. data/lib/cybersource_rest_client/models/{rbsv1subscriptions_processing_information_authorization_options_initiator.rb → rbs_authorization_options_initiator.rb} +1 -1
  193. data/lib/cybersource_rest_client/models/rbsv1subscriptions_processing_information.rb +1 -1
  194. data/lib/cybersource_rest_client/models/{reporting_v3_report_definitions_name_get200_response_default_settings.rb → report_definition_default_settings.rb} +1 -1
  195. data/lib/cybersource_rest_client/models/reporting_v3_report_definitions_get200_response_report_definitions.rb +1 -1
  196. data/lib/cybersource_rest_client/models/reporting_v3_report_definitions_name_get200_response.rb +1 -1
  197. data/lib/cybersource_rest_client/models/{risk_v1_address_verifications_post201_response_address_verification_information.rb → risk_address_verification_information.rb} +3 -3
  198. data/lib/cybersource_rest_client/models/{risk_v1_address_verifications_post201_response_address_verification_information_bar_code.rb → risk_address_verification_information_bar_code.rb} +1 -1
  199. data/lib/cybersource_rest_client/models/{risk_v1_address_verifications_post201_response_address_verification_information_standard_address.rb → risk_address_verification_information_standard_address.rb} +2 -2
  200. data/lib/cybersource_rest_client/models/{risk_v1_address_verifications_post201_response_address1.rb → risk_address_verification_information_standard_address_address1.rb} +1 -1
  201. data/lib/cybersource_rest_client/models/risk_v1_address_verifications_post201_response.rb +1 -1
  202. data/lib/cybersource_rest_client/models/shipping_address_list_for_customer__embedded.rb +1 -1
  203. data/lib/cybersource_rest_client/models/tms_embedded_instrument_identifier.rb +1 -1
  204. data/lib/cybersource_rest_client/models/{tmsv2tokenizedcardstokenized_card_idissuerlifecycleeventsimulations_metadata.rb → tms_issuer_life_cycle_event_simulation_metadata.rb} +2 -2
  205. data/lib/cybersource_rest_client/models/{tmsv2tokenizedcardstokenized_card_idissuerlifecycleeventsimulations_metadata_card_art.rb → tms_issuer_life_cycle_event_simulation_metadata_card_art.rb} +2 -2
  206. data/lib/cybersource_rest_client/models/{tms_issuerlifecycleeventsimulations_metadata_card_art_combined_asset.rb → tms_issuer_life_cycle_event_simulation_metadata_card_art_combined_asset.rb} +1 -1
  207. data/lib/cybersource_rest_client/models/{tms_embedded_instrument_identifier_point_of_sale_information.rb → tms_point_of_sale_information.rb} +2 -2
  208. data/lib/cybersource_rest_client/models/{tms_embedded_instrument_identifier_point_of_sale_information_emv_tags.rb → tms_point_of_sale_information_emv_tags.rb} +1 -1
  209. data/lib/cybersource_rest_client/models/tmsv2customers__embedded.rb +1 -1
  210. data/lib/cybersource_rest_client/models/tmsv2tokenize_token_information.rb +2 -2
  211. data/lib/cybersource_rest_client/models/tmsv2tokenize_token_information_customer__embedded.rb +2 -2
  212. data/lib/cybersource_rest_client/models/tmsv3tokenstoken_idpaymentcredentials_authenticated_identities.rb +19 -8
  213. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_configuration_information_configurations.rb → uc_configurations.rb} +2 -2
  214. data/lib/cybersource_rest_client/models/uc_configurations_features.rb +209 -0
  215. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_configuration_information_configurations_features.rb → uc_configurations_features_click_to_pay.rb} +9 -9
  216. data/lib/cybersource_rest_client/models/uc_configurations_features_click_to_pay_enrollment_data.rb +223 -0
  217. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_configuration_information_configurations_features_paze.rb → uc_configurations_features_paze.rb} +2 -2
  218. data/lib/cybersource_rest_client/models/uc_configurations_features_portfolio_accessto_sensitive_data.rb +190 -0
  219. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features.rb → uc_feature_subscription.rb} +22 -22
  220. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_after_pay.rb → uc_feature_subscription_after_pay.rb} +1 -1
  221. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_apple_pay.rb → uc_feature_subscription_apple_pay.rb} +1 -1
  222. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_bancontact.rb → uc_feature_subscription_bancontact.rb} +1 -1
  223. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_click_to_pay.rb → uc_feature_subscription_click_to_pay.rb} +1 -1
  224. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_decision_manager.rb → uc_feature_subscription_decision_manager.rb} +1 -1
  225. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_dragon_pay.rb → uc_feature_subscription_dragon_pay.rb} +1 -1
  226. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_e_check.rb → uc_feature_subscription_e_check.rb} +1 -1
  227. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_google_pay.rb → uc_feature_subscription_google_pay.rb} +1 -1
  228. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_ideal.rb → uc_feature_subscription_ideal.rb} +1 -1
  229. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_konbini.rb → uc_feature_subscription_konbini.rb} +1 -1
  230. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_multibanco.rb → uc_feature_subscription_multibanco.rb} +1 -1
  231. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_my_bank.rb → uc_feature_subscription_my_bank.rb} +1 -1
  232. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_p24.rb → uc_feature_subscription_p24.rb} +1 -1
  233. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_pay_pal.rb → uc_feature_subscription_pay_pal.rb} +1 -1
  234. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_payer_authentication.rb → uc_feature_subscription_payer_authentication.rb} +1 -1
  235. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_paze_for_unified_checkout.rb → uc_feature_subscription_paze_for_unified_checkout.rb} +1 -1
  236. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_info_features_portfolio_accessof_sensi_data.rb → uc_feature_subscription_portfolio_accessof_sensitive_data.rb} +1 -1
  237. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_tink_pay_by_bank.rb → uc_feature_subscription_tink_pay_by_bank.rb} +1 -1
  238. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_token_management.rb → uc_feature_subscription_token_management.rb} +1 -1
  239. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_unified_click_to_pay_sdk.rb → uc_feature_subscription_unified_click_to_pay_sdk.rb} +1 -1
  240. data/lib/cybersource_rest_client/models/{payments_products_unified_checkout_subscription_information_features_venmo.rb → uc_feature_subscription_venmo.rb} +1 -1
  241. data/lib/cybersource_rest_client/models/ucv1sessions_complete_mandate.rb +1 -1
  242. data/lib/cybersource_rest_client/models/ucv1sessions_data.rb +1 -1
  243. data/lib/cybersource_rest_client/models/ucv1sessions_data_client_reference_information.rb +227 -0
  244. data/lib/cybersource_rest_client/models/ucv1sessions_data_order_information.rb +1 -1
  245. data/lib/cybersource_rest_client/models/ucv1sessions_data_order_information_line_items.rb +2 -2
  246. data/lib/cybersource_rest_client/models/ucv1sessions_data_order_information_ship_to.rb +388 -0
  247. data/lib/cybersource_rest_client/models/ucv1sessions_data_processing_information_authorization_options_initiator.rb +1 -1
  248. data/lib/cybersource_rest_client/models/ucv1sessions_payment_configurations.rb +11 -1
  249. data/lib/cybersource_rest_client/models/ucv1sessions_payment_configurations_googlepay.rb +1 -1
  250. data/lib/cybersource_rest_client/models/ucv1sessions_payment_configurations_paypal.rb +211 -0
  251. data/lib/cybersource_rest_client/models/ucv1sessions_payment_configurations_paypal_tokenized_payment_method.rb +213 -0
  252. data/lib/cybersource_rest_client/models/ucv1sessions_payment_configurations_tms_token.rb +1 -1
  253. data/lib/cybersource_rest_client/models/{underwriting_configuration_organization_information_business_information_business_details.rb → underwriting_configuration_business_details.rb} +2 -2
  254. data/lib/cybersource_rest_client/models/underwriting_configuration_business_details_product_services_subscription.rb +1 -1
  255. data/lib/cybersource_rest_client/models/underwriting_configuration_organization_information_business_information.rb +1 -1
  256. data/lib/cybersource_rest_client/models/{upv1capturecontexts_data_processing_info_mit.rb → unified_checkout_merchant_initiated_transaction.rb} +1 -1
  257. data/lib/cybersource_rest_client/models/upv1capturecontexts_data_order_information.rb +4 -2
  258. data/lib/cybersource_rest_client/models/upv1capturecontexts_data_order_information_line_items.rb +2 -2
  259. data/lib/cybersource_rest_client/models/{upv1capturecontexts_data_order_information_line_items_passenger.rb → upv1capturecontexts_data_order_information_passenger.rb} +1 -1
  260. data/lib/cybersource_rest_client/models/{upv1capturecontexts_data_order_information_line_items_tax_details.rb → upv1capturecontexts_data_order_information_tax_details.rb} +1 -1
  261. data/lib/cybersource_rest_client/models/upv1capturecontexts_data_processing_information_authorization_options_initiator.rb +1 -1
  262. data/lib/cybersource_rest_client/models/{vt_config_card_not_present_global_payment_information.rb → virtual_terminal_global_payment_settings.rb} +4 -4
  263. data/lib/cybersource_rest_client/models/{vt_config_card_not_present_global_payment_information_basic_information.rb → virtual_terminal_global_payment_settings_basic_information.rb} +1 -1
  264. data/lib/cybersource_rest_client/models/{vt_config_card_not_present_global_payment_information_merchant_defined_data_fields.rb → virtual_terminal_global_payment_settings_merchant_defined_data_fields.rb} +1 -1
  265. data/lib/cybersource_rest_client/models/{vt_config_card_not_present_global_payment_information_payment_information.rb → virtual_terminal_global_payment_settings_payment_information.rb} +1 -1
  266. data/lib/cybersource_rest_client/models/vt_config_card_not_present.rb +1 -1
  267. data/lib/cybersource_rest_client.rb +160 -152
  268. metadata +161 -153
  269. data/lib/cybersource_rest_client/api/enrollment_api.rb +0 -104
  270. data/lib/cybersource_rest_client/models/tmsv3tokenstoken_idpaymentcredentials_merchant_information.rb +0 -189
  271. data/lib/cybersource_rest_client/models/tmsv3tokenstoken_idpaymentcredentials_merchant_information_merchant_descriptor.rb +0 -201
  272. data/lib/cybersource_rest_client/utilities/flex/token_verification.rb +0 -42
@@ -1,104 +0,0 @@
1
- =begin
2
- #CyberSource Merged Spec
3
-
4
- #All CyberSource API specs merged together. These are available at https://developer.cybersource.com/api/reference/api-reference.html
5
-
6
- OpenAPI spec version: 0.0.1
7
-
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.4.38
10
- =end
11
-
12
- require 'uri'
13
- require 'AuthenticationSDK/util/MLEUtility'
14
- module CyberSource
15
- class EnrollmentApi
16
- attr_accessor :api_client
17
-
18
- def initialize(api_client = ApiClient.default, config)
19
- @api_client = api_client
20
- @api_client.set_configuration(config)
21
- end
22
- # Enroll a card
23
- # Enroll a payment card for agentic or e-commerce transactions. This is typically the first step in the Intelligent Commerce payment lifecycle — the agent calls this endpoint to register a consumer's card, creating a tokenized reference that can be used in subsequent purchase instructions and payment credential retrieval. Requires device information, consumer identity, billing details, and payment instrument references. Returns a status of ACTIVE (HTTP 200) if enrollment completes immediately, or PENDING (HTTP 202) with pendingEvents if cardholder authentication is required. Call this endpoint when a consumer wants to add a new payment card or when setting up a card for agentic payment flows.
24
- #
25
- # @param agentic_card_enrollment_request
26
- # @param [Hash] opts the optional parameters
27
- # @return [AgenticCardEnrollmentResponse200]
28
- #
29
- def enroll_card(agentic_card_enrollment_request, opts = {})
30
- data, status_code, headers = enroll_card_with_http_info(agentic_card_enrollment_request, opts)
31
- return data, status_code, headers
32
- end
33
-
34
- # Enroll a card
35
- # Enroll a payment card for agentic or e-commerce transactions. This is typically the first step in the Intelligent Commerce payment lifecycle — the agent calls this endpoint to register a consumer's card, creating a tokenized reference that can be used in subsequent purchase instructions and payment credential retrieval. Requires device information, consumer identity, billing details, and payment instrument references. Returns a status of ACTIVE (HTTP 200) if enrollment completes immediately, or PENDING (HTTP 202) with pendingEvents if cardholder authentication is required. Call this endpoint when a consumer wants to add a new payment card or when setting up a card for agentic payment flows.
36
- # @param agentic_card_enrollment_request
37
- # @param [Hash] opts the optional parameters
38
- # @return [Array<(AgenticCardEnrollmentResponse200, Fixnum, Hash)>] AgenticCardEnrollmentResponse200 data, response status code and response headers
39
- def enroll_card_with_http_info(agentic_card_enrollment_request, opts = {})
40
-
41
- if @api_client.config.debugging
42
- begin
43
- raise
44
- @api_client.config.logger.debug 'Calling API: EnrollmentApi.enroll_card ...'
45
- rescue
46
- puts 'Cannot write to log'
47
- end
48
- end
49
- # verify the required parameter 'agentic_card_enrollment_request' is set
50
- if @api_client.config.client_side_validation && agentic_card_enrollment_request.nil?
51
- fail ArgumentError, "Missing the required parameter 'agentic_card_enrollment_request' when calling EnrollmentApi.enroll_card"
52
- end
53
- # resource path
54
- local_var_path = 'acp/v1/tokens'
55
-
56
- # query parameters
57
- query_params = {}
58
-
59
- # header parameters
60
- header_params = {}
61
- # HTTP header 'Accept' (if needed)
62
- header_params['Accept'] = @api_client.select_header_accept(['application/hal+json;charset=utf-8'])
63
- # HTTP header 'Content-Type'
64
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json;charset=utf-8'])
65
-
66
- # form parameters
67
- form_params = {}
68
-
69
- # http body (model)
70
- post_body = @api_client.object_to_http_body(agentic_card_enrollment_request)
71
- sdk_tracker = SdkTracker.new
72
- post_body = sdk_tracker.insert_developer_id_tracker(post_body, 'AgenticCardEnrollmentRequest', @api_client.config.host, @api_client.merchantconfig.defaultDeveloperId)
73
- inbound_mle_status = "mandatory"
74
- if MLEUtility.check_is_mle_for_API(@api_client.merchantconfig, inbound_mle_status, ["enroll_card","enroll_card_with_http_info"])
75
- begin
76
- post_body = MLEUtility.encrypt_request_payload(@api_client.merchantconfig, post_body)
77
- rescue
78
- raise
79
- end
80
- end
81
-
82
- is_response_mle_for_api = MLEUtility.check_is_response_mle_for_api(@api_client.merchantconfig, ["enroll_card","enroll_card_with_http_info"])
83
-
84
- auth_names = []
85
- data, status_code, headers = @api_client.call_api(:POST, local_var_path,
86
- :header_params => header_params,
87
- :query_params => query_params,
88
- :form_params => form_params,
89
- :body => post_body,
90
- :auth_names => auth_names,
91
- :return_type => 'AgenticCardEnrollmentResponse200',
92
- :isResponseMLEForApi => is_response_mle_for_api)
93
- if @api_client.config.debugging
94
- begin
95
- raise
96
- @api_client.config.logger.debug "API called: EnrollmentApi#enroll_card\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
97
- rescue
98
- puts 'Cannot write to log'
99
- end
100
- end
101
- return data, status_code, headers
102
- end
103
- end
104
- end
@@ -1,189 +0,0 @@
1
- =begin
2
- #CyberSource Merged Spec
3
-
4
- #All CyberSource API specs merged together. These are available at https://developer.cybersource.com/api/reference/api-reference.html
5
-
6
- OpenAPI spec version: 0.0.1
7
-
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.4.38
10
- =end
11
-
12
- require 'date'
13
-
14
- module CyberSource
15
- class Tmsv3tokenstokenIdpaymentcredentialsMerchantInformation
16
- attr_accessor :merchant_descriptor
17
-
18
- # Attribute mapping from ruby-style variable name to JSON key.
19
- def self.attribute_map
20
- {
21
- :'merchant_descriptor' => :'merchantDescriptor'
22
- }
23
- end
24
-
25
- # Attribute mapping from JSON key to ruby-style variable name.
26
- def self.json_map
27
- {
28
- :'merchant_descriptor' => :'merchant_descriptor'
29
- }
30
- end
31
-
32
- # Attribute type mapping.
33
- def self.swagger_types
34
- {
35
- :'merchant_descriptor' => :'Tmsv3tokenstokenIdpaymentcredentialsMerchantInformationMerchantDescriptor'
36
- }
37
- end
38
-
39
- # Initializes the object
40
- # @param [Hash] attributes Model attributes in the form of hash
41
- def initialize(attributes = {})
42
- return unless attributes.is_a?(Hash)
43
-
44
- # convert string to symbol for hash key
45
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
46
-
47
- if attributes.has_key?(:'merchantDescriptor')
48
- self.merchant_descriptor = attributes[:'merchantDescriptor']
49
- end
50
- end
51
-
52
- # Show invalid properties with the reasons. Usually used together with valid?
53
- # @return Array for valid properties with the reasons
54
- def list_invalid_properties
55
- invalid_properties = Array.new
56
- invalid_properties
57
- end
58
-
59
- # Check to see if the all the properties in the model are valid
60
- # @return true if the model is valid
61
- def valid?
62
- true
63
- end
64
-
65
- # Checks equality by comparing each attribute.
66
- # @param [Object] Object to be compared
67
- def ==(o)
68
- return true if self.equal?(o)
69
- self.class == o.class &&
70
- merchant_descriptor == o.merchant_descriptor
71
- end
72
-
73
- # @see the `==` method
74
- # @param [Object] Object to be compared
75
- def eql?(o)
76
- self == o
77
- end
78
-
79
- # Calculates hash code according to all attributes.
80
- # @return [Fixnum] Hash code
81
- def hash
82
- [merchant_descriptor].hash
83
- end
84
-
85
- # Builds the object from hash
86
- # @param [Hash] attributes Model attributes in the form of hash
87
- # @return [Object] Returns the model itself
88
- def build_from_hash(attributes)
89
- return nil unless attributes.is_a?(Hash)
90
- self.class.swagger_types.each_pair do |key, type|
91
- if type =~ /\AArray<(.*)>/i
92
- # check to ensure the input is an array given that the the attribute
93
- # is documented as an array but the input is not
94
- if attributes[self.class.attribute_map[key]].is_a?(Array)
95
- self.send("#{self.class.json_map[key]}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
96
- end
97
- elsif !attributes[self.class.attribute_map[key]].nil?
98
- self.send("#{self.class.json_map[key]}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
99
- end # or else data not found in attributes(hash), not an issue as the data can be optional
100
- end
101
-
102
- self
103
- end
104
-
105
- # Deserializes the data based on type
106
- # @param string type Data type
107
- # @param string value Value to be deserialized
108
- # @return [Object] Deserialized data
109
- def _deserialize(type, value)
110
- case type.to_sym
111
- when :DateTime
112
- DateTime.parse(value)
113
- when :Date
114
- Date.parse(value)
115
- when :String
116
- value.to_s
117
- when :Integer
118
- value.to_i
119
- when :Float
120
- value.to_f
121
- when :BOOLEAN
122
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
123
- true
124
- else
125
- false
126
- end
127
- when :Object
128
- # generic object (usually a Hash), return directly
129
- value
130
- when /\AArray<(?<inner_type>.+)>\z/
131
- inner_type = Regexp.last_match[:inner_type]
132
- value.map { |v| _deserialize(inner_type, v) }
133
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
134
- k_type = Regexp.last_match[:k_type]
135
- v_type = Regexp.last_match[:v_type]
136
- {}.tap do |hash|
137
- value.each do |k, v|
138
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
139
- end
140
- end
141
- else # model
142
- temp_model = CyberSource.const_get(type).new
143
- temp_model.build_from_hash(value)
144
- end
145
- end
146
-
147
- # Returns the string representation of the object
148
- # @return [String] String presentation of the object
149
- def to_s
150
- to_hash.to_s
151
- end
152
-
153
- # to_body is an alias to to_hash (backward compatibility)
154
- # @return [Hash] Returns the object in the form of hash
155
- def to_body
156
- to_hash
157
- end
158
-
159
- # Returns the object in the form of hash
160
- # @return [Hash] Returns the object in the form of hash
161
- def to_hash
162
- hash = {}
163
- self.class.attribute_map.each_pair do |attr, param|
164
- value = self.send(attr)
165
- next if value.nil?
166
- hash[param] = _to_hash(value)
167
- end
168
- hash
169
- end
170
-
171
- # Outputs non-array value in the form of hash
172
- # For object, use to_hash. Otherwise, just return the value
173
- # @param [Object] value Any valid value
174
- # @return [Hash] Returns the value in the form of hash
175
- def _to_hash(value)
176
- if value.is_a?(Array)
177
- value.compact.map { |v| _to_hash(v) }
178
- elsif value.is_a?(Hash)
179
- {}.tap do |hash|
180
- value.each { |k, v| hash[k] = _to_hash(v) }
181
- end
182
- elsif value.respond_to? :to_hash
183
- value.to_hash
184
- else
185
- value
186
- end
187
- end
188
- end
189
- end
@@ -1,201 +0,0 @@
1
- =begin
2
- #CyberSource Merged Spec
3
-
4
- #All CyberSource API specs merged together. These are available at https://developer.cybersource.com/api/reference/api-reference.html
5
-
6
- OpenAPI spec version: 0.0.1
7
-
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
- Swagger Codegen version: 2.4.38
10
- =end
11
-
12
- require 'date'
13
-
14
- module CyberSource
15
- class Tmsv3tokenstokenIdpaymentcredentialsMerchantInformationMerchantDescriptor
16
- # Merchant's name
17
- attr_accessor :name
18
-
19
- # Address of company's website provided by merchant
20
- attr_accessor :url
21
-
22
- # Attribute mapping from ruby-style variable name to JSON key.
23
- def self.attribute_map
24
- {
25
- :'name' => :'name',
26
- :'url' => :'url'
27
- }
28
- end
29
-
30
- # Attribute mapping from JSON key to ruby-style variable name.
31
- def self.json_map
32
- {
33
- :'name' => :'name',
34
- :'url' => :'url'
35
- }
36
- end
37
-
38
- # Attribute type mapping.
39
- def self.swagger_types
40
- {
41
- :'name' => :'String',
42
- :'url' => :'String'
43
- }
44
- end
45
-
46
- # Initializes the object
47
- # @param [Hash] attributes Model attributes in the form of hash
48
- def initialize(attributes = {})
49
- return unless attributes.is_a?(Hash)
50
-
51
- # convert string to symbol for hash key
52
- attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
53
-
54
- if attributes.has_key?(:'name')
55
- self.name = attributes[:'name']
56
- end
57
-
58
- if attributes.has_key?(:'url')
59
- self.url = attributes[:'url']
60
- end
61
- end
62
-
63
- # Show invalid properties with the reasons. Usually used together with valid?
64
- # @return Array for valid properties with the reasons
65
- def list_invalid_properties
66
- invalid_properties = Array.new
67
- invalid_properties
68
- end
69
-
70
- # Check to see if the all the properties in the model are valid
71
- # @return true if the model is valid
72
- def valid?
73
- true
74
- end
75
-
76
- # Checks equality by comparing each attribute.
77
- # @param [Object] Object to be compared
78
- def ==(o)
79
- return true if self.equal?(o)
80
- self.class == o.class &&
81
- name == o.name &&
82
- url == o.url
83
- end
84
-
85
- # @see the `==` method
86
- # @param [Object] Object to be compared
87
- def eql?(o)
88
- self == o
89
- end
90
-
91
- # Calculates hash code according to all attributes.
92
- # @return [Fixnum] Hash code
93
- def hash
94
- [name, url].hash
95
- end
96
-
97
- # Builds the object from hash
98
- # @param [Hash] attributes Model attributes in the form of hash
99
- # @return [Object] Returns the model itself
100
- def build_from_hash(attributes)
101
- return nil unless attributes.is_a?(Hash)
102
- self.class.swagger_types.each_pair do |key, type|
103
- if type =~ /\AArray<(.*)>/i
104
- # check to ensure the input is an array given that the the attribute
105
- # is documented as an array but the input is not
106
- if attributes[self.class.attribute_map[key]].is_a?(Array)
107
- self.send("#{self.class.json_map[key]}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
108
- end
109
- elsif !attributes[self.class.attribute_map[key]].nil?
110
- self.send("#{self.class.json_map[key]}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
111
- end # or else data not found in attributes(hash), not an issue as the data can be optional
112
- end
113
-
114
- self
115
- end
116
-
117
- # Deserializes the data based on type
118
- # @param string type Data type
119
- # @param string value Value to be deserialized
120
- # @return [Object] Deserialized data
121
- def _deserialize(type, value)
122
- case type.to_sym
123
- when :DateTime
124
- DateTime.parse(value)
125
- when :Date
126
- Date.parse(value)
127
- when :String
128
- value.to_s
129
- when :Integer
130
- value.to_i
131
- when :Float
132
- value.to_f
133
- when :BOOLEAN
134
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
135
- true
136
- else
137
- false
138
- end
139
- when :Object
140
- # generic object (usually a Hash), return directly
141
- value
142
- when /\AArray<(?<inner_type>.+)>\z/
143
- inner_type = Regexp.last_match[:inner_type]
144
- value.map { |v| _deserialize(inner_type, v) }
145
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
146
- k_type = Regexp.last_match[:k_type]
147
- v_type = Regexp.last_match[:v_type]
148
- {}.tap do |hash|
149
- value.each do |k, v|
150
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
151
- end
152
- end
153
- else # model
154
- temp_model = CyberSource.const_get(type).new
155
- temp_model.build_from_hash(value)
156
- end
157
- end
158
-
159
- # Returns the string representation of the object
160
- # @return [String] String presentation of the object
161
- def to_s
162
- to_hash.to_s
163
- end
164
-
165
- # to_body is an alias to to_hash (backward compatibility)
166
- # @return [Hash] Returns the object in the form of hash
167
- def to_body
168
- to_hash
169
- end
170
-
171
- # Returns the object in the form of hash
172
- # @return [Hash] Returns the object in the form of hash
173
- def to_hash
174
- hash = {}
175
- self.class.attribute_map.each_pair do |attr, param|
176
- value = self.send(attr)
177
- next if value.nil?
178
- hash[param] = _to_hash(value)
179
- end
180
- hash
181
- end
182
-
183
- # Outputs non-array value in the form of hash
184
- # For object, use to_hash. Otherwise, just return the value
185
- # @param [Object] value Any valid value
186
- # @return [Hash] Returns the value in the form of hash
187
- def _to_hash(value)
188
- if value.is_a?(Array)
189
- value.compact.map { |v| _to_hash(v) }
190
- elsif value.is_a?(Hash)
191
- {}.tap do |hash|
192
- value.each { |k, v| hash[k] = _to_hash(v) }
193
- end
194
- elsif value.respond_to? :to_hash
195
- value.to_hash
196
- else
197
- value
198
- end
199
- end
200
- end
201
- end
@@ -1,42 +0,0 @@
1
- module CyberSource
2
- class TokenVerification
3
- def verifyToken(public_key, post_param)
4
- post_param = JSON.parse(post_param)
5
- signed_fields = Array.new
6
- get_signed_fields = Array.new
7
- signed_values = ""
8
- signature = ""
9
- if post_param['signedFields'].to_s.empty?
10
- raise StandardError.new("Missing required field: signed_fields")
11
- else
12
- signed_fields = post_param['signedFields'].split(',')
13
- end
14
- signed_fields.each do |value|
15
- signed_values << ','
16
- signed_values << post_param[value].to_s
17
- end
18
- if signed_values.length > 0
19
- signed_values.slice!(0)
20
- end
21
- if post_param['signature'].to_s.empty?
22
- raise StandardError.new("Missing required field: signature")
23
- else
24
- signature = post_param['signature']
25
- end
26
- string_to_pem = Base64.decode64(public_key)
27
- public_key_to_pem = OpenSSL::PKey::RSA.new(string_to_pem)
28
- verify = public_key_to_pem.verify(OpenSSL::Digest::SHA512.new, Base64.decode64(signature), signed_values)
29
- rescue StandardError => err
30
- raise err
31
- end
32
-
33
- # Converting response field from camelCase to Underscore
34
- def CamelCasetoUnderscore(str)
35
- str.gsub(/::/, '/').
36
- gsub(/([A-Z]+)([A-Z][a-z])/,'\1_\2').
37
- gsub(/([a-z\d])([A-Z])/,'\1_\2').
38
- tr("-", "_").
39
- downcase
40
- end
41
- end
42
- end