conekta 7.0.3 → 9.0.0

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 (430) hide show
  1. checksums.yaml +4 -4
  2. data/Makefile +3 -3
  3. data/README.md +52 -49
  4. data/VERSION +1 -1
  5. data/conekta.gemspec +2 -2
  6. data/config-ruby.json +4 -1
  7. data/docs/AntifraudApi.md +14 -14
  8. data/docs/ApiKeyCreateResponse.md +3 -3
  9. data/docs/ApiKeysApi.md +5 -5
  10. data/docs/{BalanceCommonField.md → BalanceCommonFielsResponse.md} +2 -2
  11. data/docs/BalanceResponse.md +9 -9
  12. data/docs/BalancesApi.md +1 -1
  13. data/docs/{PaymentMethodCashResponseAllOfAgreements.md → CashAgreementsResponse.md} +2 -2
  14. data/docs/ChargeOrderResponsePaymentMethod.md +1 -1
  15. data/docs/ChargeResponse.md +3 -1
  16. data/docs/ChargebackFileResponse.md +24 -0
  17. data/docs/ChargebackResponse.md +38 -0
  18. data/docs/ChargesApi.md +4 -4
  19. data/docs/ChargesDataResponse.md +3 -1
  20. data/docs/ChargesOrderResponse.md +5 -1
  21. data/docs/Checkout.md +13 -5
  22. data/docs/CheckoutOrderTemplate.md +5 -3
  23. data/docs/CheckoutOrderTemplateCustomerInfo.md +2 -2
  24. data/docs/CheckoutResponse.md +9 -7
  25. data/docs/CompaniesApi.md +80 -8
  26. data/docs/CompanyDocumentRequest.md +1 -1
  27. data/docs/CompanyResponse.md +6 -2
  28. data/docs/CreateCustomerFiscalEntitiesResponse.md +1 -1
  29. data/docs/CreateCustomerPaymentMethodsResponse.md +3 -3
  30. data/docs/{CreateRiskRulesData.md → CreateRuleWhitelistRequest.md} +2 -2
  31. data/docs/Customer.md +2 -2
  32. data/docs/CustomerDetails.md +24 -0
  33. data/docs/CustomerFiscalEntitiesDataResponse.md +1 -1
  34. data/docs/{CustomerInfoJustCustomerId.md → CustomerInfoCustomerId.md} +2 -2
  35. data/docs/CustomerPaymentMethodsData.md +3 -3
  36. data/docs/CustomerPortalResponse.md +40 -0
  37. data/docs/CustomerShippingContactsAddress.md +3 -1
  38. data/docs/CustomerShippingContactsDataResponse.md +1 -1
  39. data/docs/{CustomerShippingContacts.md → CustomerShippingContactsRequest.md} +3 -3
  40. data/docs/{CustomerShippingContactsResponseAddress.md → CustomerShippingContactsRequestAddress.md} +3 -5
  41. data/docs/CustomerShippingContactsResponse.md +1 -1
  42. data/docs/{CustomerUpdateShippingContacts.md → CustomerUpdateShippingContactsRequest.md} +3 -3
  43. data/docs/CustomersApi.md +19 -19
  44. data/docs/CustomersResponse.md +3 -3
  45. data/docs/DiscountsApi.md +5 -5
  46. data/docs/EventResponse.md +1 -1
  47. data/docs/EventsApi.md +9 -9
  48. data/docs/{CustomerFiscalEntitiesRequest.md → FiscalEntityRequest.md} +3 -3
  49. data/docs/{CustomerAddress.md → FiscalEntityRequestAddress.md} +2 -2
  50. data/docs/GetCustomerPaymentMethodDataResponse.md +3 -3
  51. data/docs/LogResponseForRequest.md +56 -0
  52. data/docs/LogsApi.md +10 -10
  53. data/docs/LogsResponseData.md +7 -7
  54. data/docs/{LogsResponse.md → LogsResponseForRequest.md} +2 -2
  55. data/docs/OrderChargesResponse.md +4 -0
  56. data/docs/OrderCheckoutRequest.md +46 -0
  57. data/docs/OrderRequest.md +9 -9
  58. data/docs/OrderRequestCustomerInfo.md +2 -2
  59. data/docs/OrderResponse.md +5 -1
  60. data/docs/OrderResponseCheckout.md +14 -10
  61. data/docs/OrderResponseCustomerInfo.md +2 -2
  62. data/docs/{OrderDiscountLinesResponse.md → OrderResponseDiscountLines.md} +6 -2
  63. data/docs/OrderResponseShippingContact.md +7 -7
  64. data/docs/OrderResponseShippingLines.md +26 -0
  65. data/docs/{Page.md → OrderResponseTaxLines.md} +9 -3
  66. data/docs/OrderTaxRequest.md +1 -1
  67. data/docs/{UpdateOrderTaxResponse.md → OrderTaxResponse.md} +2 -2
  68. data/docs/{OrderUpdateRequest.md → OrderUpdate.md} +9 -9
  69. data/docs/{OrderUpdateRequestCustomerInfo.md → OrderUpdateCustomerInfo.md} +6 -6
  70. data/docs/OrdersApi.md +17 -15
  71. data/docs/{UpdateOrderTaxRequest.md → OrdersUpdateTaxesRequest.md} +2 -2
  72. data/docs/PaymentLinkApi.md +7 -7
  73. data/docs/PaymentMethodBnplPayment.md +1 -1
  74. data/docs/PaymentMethodCardResponse.md +2 -0
  75. data/docs/PaymentMethodCashRecurrentResponse.md +1 -1
  76. data/docs/PaymentMethodCashResponse.md +1 -1
  77. data/docs/{PaymentMethodSpeiRecurrent.md → PaymentMethodSpeiRecurrentResponse.md} +2 -2
  78. data/docs/PaymentMethodTokenRequest.md +1 -1
  79. data/docs/PaymentMethodsApi.md +10 -10
  80. data/docs/{PayoutOrder.md → PayoutOrderRequest.md} +7 -5
  81. data/docs/{CustomerInfoJustCustomerIdResponse.md → PayoutOrderRequestCustomerInfo.md} +3 -3
  82. data/docs/PayoutOrderResponse.md +4 -4
  83. data/docs/PayoutOrderResponseCustomerInfo.md +3 -3
  84. data/docs/PayoutOrdersApi.md +10 -10
  85. data/docs/PayoutOrdersResponse.md +3 -3
  86. data/docs/PlansApi.md +16 -12
  87. data/docs/Product.md +3 -3
  88. data/docs/ProductsApi.md +3 -3
  89. data/docs/{ResendRequest.md → ResendEventRequest.md} +3 -3
  90. data/docs/RiskRulesData.md +1 -1
  91. data/docs/ShippingContactsApi.md +15 -15
  92. data/docs/ShippingLinesDataResponse.md +32 -0
  93. data/docs/ShippingRequest.md +1 -1
  94. data/docs/ShippingsApi.md +3 -3
  95. data/docs/SubscriptionDetails.md +36 -0
  96. data/docs/SubscriptionDetailsCard.md +40 -0
  97. data/docs/SubscriptionDetailsPlan.md +36 -0
  98. data/docs/SubscriptionsApi.md +28 -28
  99. data/docs/SubscriptionsCustomerPortalApi.md +159 -0
  100. data/docs/TaxLinesDataResponse.md +28 -0
  101. data/docs/TaxesApi.md +19 -19
  102. data/docs/TokenRequest.md +20 -0
  103. data/docs/{TokenCard.md → TokenRequestCard.md} +2 -2
  104. data/docs/{TokenCheckout.md → TokenRequestCheckout.md} +2 -2
  105. data/docs/TokenResponseCheckout.md +1 -1
  106. data/docs/TokensApi.md +8 -8
  107. data/docs/TransactionsApi.md +2 -2
  108. data/docs/TransfersApi.md +2 -2
  109. data/docs/UpdateCustomer.md +2 -2
  110. data/docs/UpdateCustomerFiscalEntitiesResponse.md +1 -1
  111. data/docs/UpdateCustomerPaymentMethodsResponse.md +3 -3
  112. data/docs/{CustomerUpdateFiscalEntitiesRequest.md → UpdateFiscalEntityRequest.md} +3 -3
  113. data/docs/{UpdatePaymentMethods.md → UpdatePaymentMethodsCard.md} +2 -2
  114. data/docs/{PlanUpdateRequest.md → UpdatePlan.md} +2 -2
  115. data/docs/{WebhookUpdateRequest.md → UpdateWebhook.md} +2 -2
  116. data/docs/{SubscriptionUpdateRequest.md → UpdatesASubscription.md} +2 -2
  117. data/docs/WebhookKeysApi.md +5 -5
  118. data/docs/WebhookLog.md +1 -1
  119. data/docs/WebhookResponse.md +1 -1
  120. data/docs/WebhooksApi.md +12 -12
  121. data/examples/one_time_charge_pbb.rb +23 -6
  122. data/lib/conekta/api/antifraud_api.rb +22 -22
  123. data/lib/conekta/api/api_keys_api.rb +10 -10
  124. data/lib/conekta/api/balances_api.rb +3 -3
  125. data/lib/conekta/api/charges_api.rb +9 -9
  126. data/lib/conekta/api/companies_api.rb +76 -12
  127. data/lib/conekta/api/customers_api.rb +32 -32
  128. data/lib/conekta/api/discounts_api.rb +12 -12
  129. data/lib/conekta/api/events_api.rb +16 -16
  130. data/lib/conekta/api/logs_api.rb +11 -11
  131. data/lib/conekta/api/orders_api.rb +28 -25
  132. data/lib/conekta/api/payment_link_api.rb +12 -12
  133. data/lib/conekta/api/payment_methods_api.rb +19 -19
  134. data/lib/conekta/api/payout_orders_api.rb +17 -17
  135. data/lib/conekta/api/plans_api.rb +25 -19
  136. data/lib/conekta/api/products_api.rb +8 -8
  137. data/lib/conekta/api/shipping_contacts_api.rb +26 -26
  138. data/lib/conekta/api/shippings_api.rb +8 -8
  139. data/lib/conekta/api/subscriptions_api.rb +52 -52
  140. data/lib/conekta/api/subscriptions_customer_portal_api.rb +168 -0
  141. data/lib/conekta/api/taxes_api.rb +26 -26
  142. data/lib/conekta/api/tokens_api.rb +14 -14
  143. data/lib/conekta/api/transactions_api.rb +5 -5
  144. data/lib/conekta/api/transfers_api.rb +5 -5
  145. data/lib/conekta/api/webhook_keys_api.rb +10 -10
  146. data/lib/conekta/api/webhooks_api.rb +21 -21
  147. data/lib/conekta/api_client.rb +31 -27
  148. data/lib/conekta/api_error.rb +2 -2
  149. data/lib/conekta/api_model_base.rb +88 -0
  150. data/lib/conekta/configuration.rb +2 -4
  151. data/lib/conekta/models/api_key_create_response.rb +26 -102
  152. data/lib/conekta/models/api_key_request.rb +22 -79
  153. data/lib/conekta/models/api_key_response.rb +12 -81
  154. data/lib/conekta/models/api_key_update_request.rb +12 -79
  155. data/lib/conekta/models/{balance_common_field.rb → balance_common_fiels_response.rb} +13 -80
  156. data/lib/conekta/models/balance_response.rb +21 -88
  157. data/lib/conekta/models/blacklist_rule_response.rb +12 -79
  158. data/lib/conekta/models/{payment_method_cash_response_all_of_agreements.rb → cash_agreements_response.rb} +13 -80
  159. data/lib/conekta/models/charge_order_response.rb +12 -83
  160. data/lib/conekta/models/charge_order_response_payment_method.rb +3 -3
  161. data/lib/conekta/models/charge_request.rb +22 -79
  162. data/lib/conekta/models/charge_request_payment_method.rb +4 -5
  163. data/lib/conekta/models/charge_response.rb +103 -84
  164. data/lib/conekta/models/charge_response_channel.rb +12 -79
  165. data/lib/conekta/models/charge_response_payment_method.rb +2 -2
  166. data/lib/conekta/models/charge_response_refunds.rb +32 -89
  167. data/lib/conekta/models/charge_response_refunds_data.rb +52 -79
  168. data/lib/conekta/models/charge_update_request.rb +12 -79
  169. data/lib/conekta/models/{risk_rules.rb → chargeback_file_response.rb} +48 -89
  170. data/lib/conekta/models/chargeback_response.rb +298 -0
  171. data/lib/conekta/models/charges_data_response.rb +103 -91
  172. data/lib/conekta/models/charges_order_response.rb +54 -88
  173. data/lib/conekta/models/checkout.rb +162 -91
  174. data/lib/conekta/models/checkout_order_template.rb +50 -95
  175. data/lib/conekta/models/checkout_order_template_customer_info.rb +5 -6
  176. data/lib/conekta/models/checkout_response.rb +89 -82
  177. data/lib/conekta/models/checkouts_response.rb +32 -89
  178. data/lib/conekta/models/company_document_request.rb +42 -79
  179. data/lib/conekta/models/company_document_response.rb +32 -79
  180. data/lib/conekta/models/company_response.rb +151 -85
  181. data/lib/conekta/models/create_company_request.rb +12 -79
  182. data/lib/conekta/models/create_company_request_bank_account_info.rb +12 -79
  183. data/lib/conekta/models/create_company_request_comercial_info.rb +12 -79
  184. data/lib/conekta/models/create_company_request_fiscal_info.rb +12 -79
  185. data/lib/conekta/models/create_customer_fiscal_entities_response.rb +54 -90
  186. data/lib/conekta/models/create_customer_payment_methods_request.rb +4 -5
  187. data/lib/conekta/models/create_customer_payment_methods_response.rb +4 -4
  188. data/lib/conekta/models/{create_risk_rules_data.rb → create_rule_whitelist_request.rb} +43 -80
  189. data/lib/conekta/models/customer.rb +44 -82
  190. data/lib/conekta/models/customer_antifraud_info.rb +12 -79
  191. data/lib/conekta/models/customer_antifraud_info_response.rb +12 -79
  192. data/lib/conekta/models/{product_order_response_all_of.rb → customer_details.rb} +30 -87
  193. data/lib/conekta/models/customer_fiscal_entities_data_response.rb +54 -90
  194. data/lib/conekta/models/customer_fiscal_entities_response.rb +32 -86
  195. data/lib/conekta/models/customer_info.rb +42 -79
  196. data/lib/conekta/models/{customer_info_just_customer_id.rb → customer_info_customer_id.rb} +23 -80
  197. data/lib/conekta/models/customer_payment_methods_data.rb +4 -4
  198. data/lib/conekta/models/customer_payment_methods_request.rb +4 -5
  199. data/lib/conekta/models/customer_payment_methods_response.rb +32 -89
  200. data/lib/conekta/models/{customer_shipping_contacts_data_response_all_of.rb → customer_portal_response.rb} +108 -105
  201. data/lib/conekta/models/customer_response.rb +62 -82
  202. data/lib/conekta/models/customer_response_shipping_contacts.rb +32 -86
  203. data/lib/conekta/models/customer_shipping_contacts_address.rb +22 -83
  204. data/lib/conekta/models/customer_shipping_contacts_data_response.rb +53 -89
  205. data/lib/conekta/models/{customer_shipping_contacts.rb → customer_shipping_contacts_request.rb} +25 -84
  206. data/lib/conekta/models/{customer_shipping_contacts_response_address.rb → customer_shipping_contacts_request_address.rb} +16 -91
  207. data/lib/conekta/models/customer_shipping_contacts_response.rb +13 -81
  208. data/lib/conekta/models/{customer_update_shipping_contacts.rb → customer_update_shipping_contacts_request.rb} +15 -84
  209. data/lib/conekta/models/customers_response.rb +47 -104
  210. data/lib/conekta/models/delete_api_keys_response.rb +12 -87
  211. data/lib/conekta/models/deleted_blacklist_rule_response.rb +12 -79
  212. data/lib/conekta/models/deleted_whitelist_rule_response.rb +12 -79
  213. data/lib/conekta/models/details_error.rb +12 -80
  214. data/lib/conekta/models/discount_lines_data_response.rb +62 -86
  215. data/lib/conekta/models/discount_lines_response.rb +62 -86
  216. data/lib/conekta/models/email_checkout_request.rb +22 -79
  217. data/lib/conekta/models/error.rb +12 -87
  218. data/lib/conekta/models/event_response.rb +12 -79
  219. data/lib/conekta/models/event_types.rb +2 -2
  220. data/lib/conekta/models/events_resend_response.rb +12 -79
  221. data/lib/conekta/models/fiscal_entity_address.rb +62 -80
  222. data/lib/conekta/models/{customer_fiscal_entities_request.rb → fiscal_entity_request.rb} +25 -84
  223. data/lib/conekta/models/{customer_address.rb → fiscal_entity_request_address.rb} +43 -80
  224. data/lib/conekta/models/get_api_keys_response.rb +32 -89
  225. data/lib/conekta/models/get_charges_response.rb +32 -89
  226. data/lib/conekta/models/get_companies_response.rb +32 -89
  227. data/lib/conekta/models/get_customer_payment_method_data_response.rb +4 -4
  228. data/lib/conekta/models/get_events_response.rb +32 -89
  229. data/lib/conekta/models/get_order_discount_lines_response.rb +32 -89
  230. data/lib/conekta/models/get_orders_response.rb +42 -90
  231. data/lib/conekta/models/get_payment_method_response.rb +32 -89
  232. data/lib/conekta/models/get_plans_response.rb +32 -89
  233. data/lib/conekta/models/get_transactions_response.rb +32 -89
  234. data/lib/conekta/models/get_transfers_response.rb +32 -89
  235. data/lib/conekta/models/get_webhook_keys_response.rb +32 -89
  236. data/lib/conekta/models/get_webhooks_response.rb +32 -89
  237. data/lib/conekta/models/{log_response.rb → log_response_for_request.rb} +45 -89
  238. data/lib/conekta/models/logs_response_data.rb +14 -88
  239. data/lib/conekta/models/{logs_response.rb → logs_response_for_request.rb} +13 -83
  240. data/lib/conekta/models/order_capture_request.rb +12 -79
  241. data/lib/conekta/models/order_channel_response.rb +12 -79
  242. data/lib/conekta/models/order_charges_response.rb +53 -87
  243. data/lib/conekta/models/{checkout_request.rb → order_checkout_request.rb} +81 -90
  244. data/lib/conekta/models/order_discount_lines_request.rb +32 -79
  245. data/lib/conekta/models/order_fiscal_entity_address_response.rb +62 -87
  246. data/lib/conekta/models/order_fiscal_entity_request.rb +22 -81
  247. data/lib/conekta/models/order_fiscal_entity_response.rb +52 -83
  248. data/lib/conekta/models/order_next_action_response.rb +12 -79
  249. data/lib/conekta/models/order_next_action_response_redirect_to_url.rb +12 -79
  250. data/lib/conekta/models/order_refund_request.rb +32 -79
  251. data/lib/conekta/models/order_request.rb +40 -89
  252. data/lib/conekta/models/order_request_customer_info.rb +5 -6
  253. data/lib/conekta/models/order_response.rb +32 -82
  254. data/lib/conekta/models/order_response_checkout.rb +146 -84
  255. data/lib/conekta/models/order_response_customer_info.rb +22 -98
  256. data/lib/conekta/models/order_response_discount_lines.rb +54 -87
  257. data/lib/conekta/models/order_response_products.rb +32 -89
  258. data/lib/conekta/models/order_response_shipping_contact.rb +41 -116
  259. data/lib/conekta/models/{order_discount_lines_response.rb → order_response_shipping_lines.rb} +56 -89
  260. data/lib/conekta/models/{order_response_charges.rb → order_response_tax_lines.rb} +56 -90
  261. data/lib/conekta/models/order_tax_request.rb +14 -81
  262. data/lib/conekta/models/{update_order_tax_response.rb → order_tax_response.rb} +25 -89
  263. data/lib/conekta/models/{order_update_request.rb → order_update.rb} +20 -91
  264. data/lib/conekta/models/{order_update_request_customer_info.rb → order_update_customer_info.rb} +6 -7
  265. data/lib/conekta/models/order_update_fiscal_entity_request.rb +22 -81
  266. data/lib/conekta/models/{update_order_tax_request.rb → orders_update_taxes_request.rb} +17 -90
  267. data/lib/conekta/models/payment_method_bank_transfer.rb +22 -96
  268. data/lib/conekta/models/payment_method_bnpl_payment.rb +66 -86
  269. data/lib/conekta/models/payment_method_bnpl_request.rb +64 -88
  270. data/lib/conekta/models/payment_method_card.rb +22 -86
  271. data/lib/conekta/models/payment_method_card_request.rb +48 -92
  272. data/lib/conekta/models/payment_method_card_response.rb +63 -87
  273. data/lib/conekta/models/payment_method_cash.rb +22 -89
  274. data/lib/conekta/models/payment_method_cash_recurrent_response.rb +53 -87
  275. data/lib/conekta/models/payment_method_cash_request.rb +22 -86
  276. data/lib/conekta/models/payment_method_cash_response.rb +53 -87
  277. data/lib/conekta/models/payment_method_general_request.rb +22 -79
  278. data/lib/conekta/models/payment_method_pbb_payment.rb +67 -91
  279. data/lib/conekta/models/payment_method_pbb_request.rb +22 -86
  280. data/lib/conekta/models/{payment_method_spei_recurrent.rb → payment_method_spei_recurrent_response.rb} +53 -87
  281. data/lib/conekta/models/payment_method_spei_request.rb +22 -86
  282. data/lib/conekta/models/payment_method_token_request.rb +33 -87
  283. data/lib/conekta/models/payout.rb +22 -79
  284. data/lib/conekta/models/payout_method.rb +22 -79
  285. data/lib/conekta/models/payout_order_payouts_item.rb +62 -79
  286. data/lib/conekta/models/{payout_order.rb → payout_order_request.rb} +102 -82
  287. data/lib/conekta/models/{customer_info_just_customer_id_response.rb → payout_order_request_customer_info.rb} +31 -80
  288. data/lib/conekta/models/payout_order_response.rb +146 -79
  289. data/lib/conekta/models/payout_order_response_customer_info.rb +38 -103
  290. data/lib/conekta/models/payout_orders_response.rb +47 -104
  291. data/lib/conekta/models/plan_request.rb +22 -79
  292. data/lib/conekta/models/plan_response.rb +12 -81
  293. data/lib/conekta/models/product.rb +22 -79
  294. data/lib/conekta/models/product_data_response.rb +22 -86
  295. data/lib/conekta/models/product_order_response.rb +22 -86
  296. data/lib/conekta/models/{resend_request.rb → resend_event_request.rb} +23 -80
  297. data/lib/conekta/models/risk_rules_data.rb +12 -79
  298. data/lib/conekta/models/risk_rules_list.rb +32 -89
  299. data/lib/conekta/models/{discount_lines_response_all_of.rb → shipping_lines_data_response.rb} +105 -99
  300. data/lib/conekta/models/shipping_order_response.rb +12 -86
  301. data/lib/conekta/models/shipping_request.rb +12 -79
  302. data/lib/conekta/models/sms_checkout_request.rb +22 -79
  303. data/lib/conekta/models/{order_response_shipping_contact_all_of.rb → subscription_details.rb} +87 -90
  304. data/lib/conekta/models/{payment_method_card_response_all_of.rb → subscription_details_card.rb} +68 -118
  305. data/lib/conekta/models/{product_data_response_all_of.rb → subscription_details_plan.rb} +83 -87
  306. data/lib/conekta/models/subscription_events_response.rb +32 -89
  307. data/lib/conekta/models/subscription_request.rb +22 -79
  308. data/lib/conekta/models/subscription_response.rb +12 -86
  309. data/lib/conekta/models/{payment_method_response.rb → tax_lines_data_response.rb} +118 -112
  310. data/lib/conekta/models/{token.rb → token_request.rb} +15 -84
  311. data/lib/conekta/models/{token_card.rb → token_request_card.rb} +33 -80
  312. data/lib/conekta/models/{token_checkout.rb → token_request_checkout.rb} +13 -80
  313. data/lib/conekta/models/token_response.rb +52 -80
  314. data/lib/conekta/models/token_response_checkout.rb +12 -79
  315. data/lib/conekta/models/transaction_response.rb +112 -79
  316. data/lib/conekta/models/transfer_destination_response.rb +12 -79
  317. data/lib/conekta/models/transfer_method_response.rb +12 -79
  318. data/lib/conekta/models/transfer_response.rb +12 -79
  319. data/lib/conekta/models/transfers_response.rb +12 -79
  320. data/lib/conekta/models/update_customer.rb +14 -82
  321. data/lib/conekta/models/update_customer_antifraud_info.rb +12 -79
  322. data/lib/conekta/models/update_customer_fiscal_entities_response.rb +54 -90
  323. data/lib/conekta/models/update_customer_payment_methods_response.rb +4 -4
  324. data/lib/conekta/models/{customer_update_fiscal_entities_request.rb → update_fiscal_entity_request.rb} +15 -84
  325. data/lib/conekta/models/update_order_discount_lines_request.rb +12 -79
  326. data/lib/conekta/models/{update_payment_methods.rb → update_payment_methods_card.rb} +13 -80
  327. data/lib/conekta/models/{plan_update_request.rb → update_plan.rb} +13 -80
  328. data/lib/conekta/models/update_product.rb +14 -85
  329. data/lib/conekta/models/{webhook_update_request.rb → update_webhook.rb} +13 -80
  330. data/lib/conekta/models/{subscription_update_request.rb → updates_a_subscription.rb} +13 -80
  331. data/lib/conekta/models/webhook_key_create_response.rb +12 -79
  332. data/lib/conekta/models/webhook_key_delete_response.rb +12 -79
  333. data/lib/conekta/models/webhook_key_request.rb +12 -79
  334. data/lib/conekta/models/webhook_key_response.rb +12 -80
  335. data/lib/conekta/models/webhook_key_update_request.rb +12 -79
  336. data/lib/conekta/models/webhook_log.rb +12 -79
  337. data/lib/conekta/models/webhook_request.rb +12 -79
  338. data/lib/conekta/models/webhook_response.rb +12 -79
  339. data/lib/conekta/models/whitelistlist_rule_response.rb +12 -79
  340. data/lib/conekta/version.rb +3 -3
  341. data/lib/conekta.rb +44 -42
  342. data/spec/api/antifraud_api_spec.rb +4 -4
  343. data/spec/api/api_keys_api_spec.rb +2 -2
  344. data/spec/api/balances_api_spec.rb +2 -2
  345. data/spec/api/charges_api_spec.rb +2 -2
  346. data/spec/api/companies_api_spec.rb +14 -2
  347. data/spec/api/customers_api_spec.rb +4 -4
  348. data/spec/api/discounts_api_spec.rb +2 -2
  349. data/spec/api/events_api_spec.rb +3 -3
  350. data/spec/api/logs_api_spec.rb +4 -4
  351. data/spec/api/orders_api_spec.rb +4 -3
  352. data/spec/api/payment_link_api_spec.rb +2 -2
  353. data/spec/api/payment_methods_api_spec.rb +3 -3
  354. data/spec/api/payout_orders_api_spec.rb +3 -3
  355. data/spec/api/plans_api_spec.rb +5 -3
  356. data/spec/api/products_api_spec.rb +2 -2
  357. data/spec/api/shipping_contacts_api_spec.rb +4 -4
  358. data/spec/api/shippings_api_spec.rb +2 -2
  359. data/spec/api/subscriptions_api_spec.rb +4 -4
  360. data/spec/api/subscriptions_customer_portal_api_spec.rb +63 -0
  361. data/spec/api/taxes_api_spec.rb +6 -6
  362. data/spec/api/tokens_api_spec.rb +4 -4
  363. data/spec/api/transactions_api_spec.rb +2 -2
  364. data/spec/api/transfers_api_spec.rb +2 -2
  365. data/spec/api/webhook_keys_api_spec.rb +2 -2
  366. data/spec/api/webhooks_api_spec.rb +3 -3
  367. data/spec/spec_helper.rb +2 -2
  368. metadata +104 -147
  369. data/docs/ApiKeyResponseOnDelete.md +0 -34
  370. data/docs/ChargesOrderResponseAllOfData.md +0 -52
  371. data/docs/CheckoutRequest.md +0 -40
  372. data/docs/CompanyResponseDocumentsInner.md +0 -22
  373. data/docs/CustomerPaymentMethodRequest.md +0 -18
  374. data/docs/Details.md +0 -18
  375. data/docs/LogResponse.md +0 -56
  376. data/docs/OrderCustomerInfoResponse.md +0 -28
  377. data/docs/OrdersResponse.md +0 -18
  378. data/docs/Pagination.md +0 -20
  379. data/docs/PaymentMethod.md +0 -20
  380. data/docs/PaymentMethodResponse.md +0 -26
  381. data/docs/Token.md +0 -20
  382. data/lib/conekta/models/api_key_create_response_all_of.rb +0 -215
  383. data/lib/conekta/models/api_key_response_on_delete.rb +0 -297
  384. data/lib/conekta/models/charge_data_payment_method_bank_transfer_response.rb +0 -362
  385. data/lib/conekta/models/charge_data_payment_method_card_response.rb +0 -308
  386. data/lib/conekta/models/charge_data_payment_method_cash_response.rb +0 -281
  387. data/lib/conekta/models/charge_response_refunds_all_of.rb +0 -217
  388. data/lib/conekta/models/charges_order_response_all_of_data.rb +0 -439
  389. data/lib/conekta/models/checkouts_response_all_of.rb +0 -216
  390. data/lib/conekta/models/company_fiscal_info_address_response.rb +0 -330
  391. data/lib/conekta/models/company_fiscal_info_response.rb +0 -309
  392. data/lib/conekta/models/company_payout_destination_response.rb +0 -312
  393. data/lib/conekta/models/company_response_documents_inner.rb +0 -270
  394. data/lib/conekta/models/create_customer_fiscal_entities_response_all_of.rb +0 -271
  395. data/lib/conekta/models/customer_fiscal_entities_request_address.rb +0 -308
  396. data/lib/conekta/models/customer_fiscal_entities_response_all_of.rb +0 -216
  397. data/lib/conekta/models/customer_payment_method_request.rb +0 -223
  398. data/lib/conekta/models/customer_payment_methods.rb +0 -216
  399. data/lib/conekta/models/customer_response_shipping_contacts_all_of.rb +0 -216
  400. data/lib/conekta/models/customers_response_all_of.rb +0 -216
  401. data/lib/conekta/models/delete_api_keys_response_all_of.rb +0 -214
  402. data/lib/conekta/models/details.rb +0 -216
  403. data/lib/conekta/models/error_all_of.rb +0 -234
  404. data/lib/conekta/models/get_api_keys_response_all_of.rb +0 -216
  405. data/lib/conekta/models/get_charges_response_all_of.rb +0 -216
  406. data/lib/conekta/models/get_companies_response_all_of.rb +0 -216
  407. data/lib/conekta/models/get_events_response_all_of.rb +0 -216
  408. data/lib/conekta/models/get_order_discount_lines_response_all_of.rb +0 -216
  409. data/lib/conekta/models/get_payment_method_response_all_of.rb +0 -216
  410. data/lib/conekta/models/get_plans_response_all_of.rb +0 -216
  411. data/lib/conekta/models/get_transactions_response_all_of.rb +0 -217
  412. data/lib/conekta/models/get_transfers_response_all_of.rb +0 -217
  413. data/lib/conekta/models/get_webhook_keys_response_all_of.rb +0 -216
  414. data/lib/conekta/models/get_webhooks_response_all_of.rb +0 -216
  415. data/lib/conekta/models/order_customer_info_response.rb +0 -263
  416. data/lib/conekta/models/order_fiscal_entity_address_response_all_of.rb +0 -214
  417. data/lib/conekta/models/order_response_charges_all_of.rb +0 -216
  418. data/lib/conekta/models/order_response_customer_info_all_of.rb +0 -214
  419. data/lib/conekta/models/order_response_discount_lines_all_of.rb +0 -216
  420. data/lib/conekta/models/order_response_products_all_of.rb +0 -216
  421. data/lib/conekta/models/orders_response.rb +0 -223
  422. data/lib/conekta/models/page.rb +0 -228
  423. data/lib/conekta/models/pagination.rb +0 -240
  424. data/lib/conekta/models/payment_method.rb +0 -230
  425. data/lib/conekta/models/payment_method_card_request_all_of.rb +0 -215
  426. data/lib/conekta/models/payment_method_cash_request_all_of.rb +0 -214
  427. data/lib/conekta/models/payment_method_cash_response_all_of.rb +0 -251
  428. data/lib/conekta/models/payment_method_spei_recurrent_all_of.rb +0 -224
  429. data/lib/conekta/models/update_customer_fiscal_entities_response_all_of.rb +0 -271
  430. data/lib/conekta/models/update_order_tax_response_all_of.rb +0 -232
@@ -3,10 +3,10 @@
3
3
 
4
4
  #Conekta sdk
5
5
 
6
- The version of the OpenAPI document: 2.2.0
6
+ The version of the OpenAPI document: 2.3.0
7
7
  Contact: engineering@conekta.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.5.0
9
+ Generator version: 7.24.0
10
10
 
11
11
  =end
12
12
 
@@ -14,7 +14,7 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Conekta
17
- class UpdateCustomerAntifraudInfo
17
+ class UpdateCustomerAntifraudInfo < ApiModelBase
18
18
  attr_accessor :account_created_at
19
19
 
20
20
  attr_accessor :first_paid_at
@@ -27,9 +27,14 @@ module Conekta
27
27
  }
28
28
  end
29
29
 
30
+ # Returns attribute mapping this model knows about
31
+ def self.acceptable_attribute_map
32
+ attribute_map
33
+ end
34
+
30
35
  # Returns all the JSON keys this model knows about
31
36
  def self.acceptable_attributes
32
- attribute_map.values
37
+ acceptable_attribute_map.values
33
38
  end
34
39
 
35
40
  # Attribute type mapping.
@@ -54,9 +59,10 @@ module Conekta
54
59
  end
55
60
 
56
61
  # check to see if the attribute exists and convert string to symbol for hash key
62
+ acceptable_attribute_map = self.class.acceptable_attribute_map
57
63
  attributes = attributes.each_with_object({}) { |(k, v), h|
58
- if (!self.class.attribute_map.key?(k.to_sym))
59
- fail ArgumentError, "`#{k}` is not a valid attribute in `Conekta::UpdateCustomerAntifraudInfo`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
64
+ if (!acceptable_attribute_map.key?(k.to_sym))
65
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Conekta::UpdateCustomerAntifraudInfo`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
60
66
  end
61
67
  h[k.to_sym] = v
62
68
  }
@@ -129,61 +135,6 @@ module Conekta
129
135
  new(transformed_hash)
130
136
  end
131
137
 
132
- # Deserializes the data based on type
133
- # @param string type Data type
134
- # @param string value Value to be deserialized
135
- # @return [Object] Deserialized data
136
- def self._deserialize(type, value)
137
- case type.to_sym
138
- when :Time
139
- Time.parse(value)
140
- when :Date
141
- Date.parse(value)
142
- when :String
143
- value.to_s
144
- when :Integer
145
- value.to_i
146
- when :Float
147
- value.to_f
148
- when :Boolean
149
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
150
- true
151
- else
152
- false
153
- end
154
- when :Object
155
- # generic object (usually a Hash), return directly
156
- value
157
- when /\AArray<(?<inner_type>.+)>\z/
158
- inner_type = Regexp.last_match[:inner_type]
159
- value.map { |v| _deserialize(inner_type, v) }
160
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
161
- k_type = Regexp.last_match[:k_type]
162
- v_type = Regexp.last_match[:v_type]
163
- {}.tap do |hash|
164
- value.each do |k, v|
165
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
166
- end
167
- end
168
- else # model
169
- # models (e.g. Pet) or oneOf
170
- klass = Conekta.const_get(type)
171
- klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
172
- end
173
- end
174
-
175
- # Returns the string representation of the object
176
- # @return [String] String presentation of the object
177
- def to_s
178
- to_hash.to_s
179
- end
180
-
181
- # to_body is an alias to to_hash (backward compatibility)
182
- # @return [Hash] Returns the object in the form of hash
183
- def to_body
184
- to_hash
185
- end
186
-
187
138
  # Returns the object in the form of hash
188
139
  # @return [Hash] Returns the object in the form of hash
189
140
  def to_hash
@@ -200,24 +151,6 @@ module Conekta
200
151
  hash
201
152
  end
202
153
 
203
- # Outputs non-array value in the form of hash
204
- # For object, use to_hash. Otherwise, just return the value
205
- # @param [Object] value Any valid value
206
- # @return [Hash] Returns the value in the form of hash
207
- def _to_hash(value)
208
- if value.is_a?(Array)
209
- value.compact.map { |v| _to_hash(v) }
210
- elsif value.is_a?(Hash)
211
- {}.tap do |hash|
212
- value.each { |k, v| hash[k] = _to_hash(v) }
213
- end
214
- elsif value.respond_to? :to_hash
215
- value.to_hash
216
- else
217
- value
218
- end
219
- end
220
-
221
154
  end
222
155
 
223
156
  end
@@ -3,10 +3,10 @@
3
3
 
4
4
  #Conekta sdk
5
5
 
6
- The version of the OpenAPI document: 2.2.0
6
+ The version of the OpenAPI document: 2.3.0
7
7
  Contact: engineering@conekta.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.5.0
9
+ Generator version: 7.24.0
10
10
 
11
11
  =end
12
12
 
@@ -14,7 +14,7 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Conekta
17
- class UpdateCustomerFiscalEntitiesResponse
17
+ class UpdateCustomerFiscalEntitiesResponse < ApiModelBase
18
18
  attr_accessor :address
19
19
 
20
20
  attr_accessor :tax_id
@@ -54,15 +54,20 @@ module Conekta
54
54
  }
55
55
  end
56
56
 
57
+ # Returns attribute mapping this model knows about
58
+ def self.acceptable_attribute_map
59
+ attribute_map
60
+ end
61
+
57
62
  # Returns all the JSON keys this model knows about
58
63
  def self.acceptable_attributes
59
- attribute_map.values
64
+ acceptable_attribute_map.values
60
65
  end
61
66
 
62
67
  # Attribute type mapping.
63
68
  def self.openapi_types
64
69
  {
65
- :'address' => :'CustomerAddress',
70
+ :'address' => :'FiscalEntityRequestAddress',
66
71
  :'tax_id' => :'String',
67
72
  :'email' => :'String',
68
73
  :'phone' => :'String',
@@ -79,16 +84,10 @@ module Conekta
79
84
  # List of attributes with nullable: true
80
85
  def self.openapi_nullable
81
86
  Set.new([
87
+ :'metadata',
82
88
  ])
83
89
  end
84
90
 
85
- # List of class defined in allOf (OpenAPI v3)
86
- def self.openapi_all_of
87
- [
88
- :'CustomerFiscalEntitiesRequest'
89
- ]
90
- end
91
-
92
91
  # Initializes the object
93
92
  # @param [Hash] attributes Model attributes in the form of hash
94
93
  def initialize(attributes = {})
@@ -97,9 +96,10 @@ module Conekta
97
96
  end
98
97
 
99
98
  # check to see if the attribute exists and convert string to symbol for hash key
99
+ acceptable_attribute_map = self.class.acceptable_attribute_map
100
100
  attributes = attributes.each_with_object({}) { |(k, v), h|
101
- if (!self.class.attribute_map.key?(k.to_sym))
102
- fail ArgumentError, "`#{k}` is not a valid attribute in `Conekta::UpdateCustomerFiscalEntitiesResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
101
+ if (!acceptable_attribute_map.key?(k.to_sym))
102
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Conekta::UpdateCustomerFiscalEntitiesResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
103
103
  end
104
104
  h[k.to_sym] = v
105
105
  }
@@ -123,9 +123,6 @@ module Conekta
123
123
  end
124
124
 
125
125
  if attributes.key?(:'metadata')
126
- if (value = attributes[:'metadata']).is_a?(Hash)
127
- self.metadata = value
128
- end
129
126
  end
130
127
 
131
128
  if attributes.key?(:'company_name')
@@ -194,6 +191,46 @@ module Conekta
194
191
  true
195
192
  end
196
193
 
194
+ # Custom attribute writer method with validation
195
+ # @param [Object] address Value to be assigned
196
+ def address=(address)
197
+ if address.nil?
198
+ fail ArgumentError, 'address cannot be nil'
199
+ end
200
+
201
+ @address = address
202
+ end
203
+
204
+ # Custom attribute writer method with validation
205
+ # @param [Object] id Value to be assigned
206
+ def id=(id)
207
+ if id.nil?
208
+ fail ArgumentError, 'id cannot be nil'
209
+ end
210
+
211
+ @id = id
212
+ end
213
+
214
+ # Custom attribute writer method with validation
215
+ # @param [Object] object Value to be assigned
216
+ def object=(object)
217
+ if object.nil?
218
+ fail ArgumentError, 'object cannot be nil'
219
+ end
220
+
221
+ @object = object
222
+ end
223
+
224
+ # Custom attribute writer method with validation
225
+ # @param [Object] created_at Value to be assigned
226
+ def created_at=(created_at)
227
+ if created_at.nil?
228
+ fail ArgumentError, 'created_at cannot be nil'
229
+ end
230
+
231
+ @created_at = created_at
232
+ end
233
+
197
234
  # Checks equality by comparing each attribute.
198
235
  # @param [Object] Object to be compared
199
236
  def ==(o)
@@ -247,61 +284,6 @@ module Conekta
247
284
  new(transformed_hash)
248
285
  end
249
286
 
250
- # Deserializes the data based on type
251
- # @param string type Data type
252
- # @param string value Value to be deserialized
253
- # @return [Object] Deserialized data
254
- def self._deserialize(type, value)
255
- case type.to_sym
256
- when :Time
257
- Time.parse(value)
258
- when :Date
259
- Date.parse(value)
260
- when :String
261
- value.to_s
262
- when :Integer
263
- value.to_i
264
- when :Float
265
- value.to_f
266
- when :Boolean
267
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
268
- true
269
- else
270
- false
271
- end
272
- when :Object
273
- # generic object (usually a Hash), return directly
274
- value
275
- when /\AArray<(?<inner_type>.+)>\z/
276
- inner_type = Regexp.last_match[:inner_type]
277
- value.map { |v| _deserialize(inner_type, v) }
278
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
279
- k_type = Regexp.last_match[:k_type]
280
- v_type = Regexp.last_match[:v_type]
281
- {}.tap do |hash|
282
- value.each do |k, v|
283
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
284
- end
285
- end
286
- else # model
287
- # models (e.g. Pet) or oneOf
288
- klass = Conekta.const_get(type)
289
- klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
290
- end
291
- end
292
-
293
- # Returns the string representation of the object
294
- # @return [String] String presentation of the object
295
- def to_s
296
- to_hash.to_s
297
- end
298
-
299
- # to_body is an alias to to_hash (backward compatibility)
300
- # @return [Hash] Returns the object in the form of hash
301
- def to_body
302
- to_hash
303
- end
304
-
305
287
  # Returns the object in the form of hash
306
288
  # @return [Hash] Returns the object in the form of hash
307
289
  def to_hash
@@ -318,24 +300,6 @@ module Conekta
318
300
  hash
319
301
  end
320
302
 
321
- # Outputs non-array value in the form of hash
322
- # For object, use to_hash. Otherwise, just return the value
323
- # @param [Object] value Any valid value
324
- # @return [Hash] Returns the value in the form of hash
325
- def _to_hash(value)
326
- if value.is_a?(Array)
327
- value.compact.map { |v| _to_hash(v) }
328
- elsif value.is_a?(Hash)
329
- {}.tap do |hash|
330
- value.each { |k, v| hash[k] = _to_hash(v) }
331
- end
332
- elsif value.respond_to? :to_hash
333
- value.to_hash
334
- else
335
- value
336
- end
337
- end
338
-
339
303
  end
340
304
 
341
305
  end
@@ -3,10 +3,10 @@
3
3
 
4
4
  #Conekta sdk
5
5
 
6
- The version of the OpenAPI document: 2.2.0
6
+ The version of the OpenAPI document: 2.3.0
7
7
  Contact: engineering@conekta.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.5.0
9
+ Generator version: 7.24.0
10
10
 
11
11
  =end
12
12
 
@@ -22,7 +22,7 @@ module Conekta
22
22
  :'PaymentMethodCardResponse',
23
23
  :'PaymentMethodCashRecurrentResponse',
24
24
  :'PaymentMethodCashResponse',
25
- :'PaymentMethodSpeiRecurrent'
25
+ :'PaymentMethodSpeiRecurrentResponse'
26
26
  ]
27
27
  end
28
28
 
@@ -37,7 +37,7 @@ module Conekta
37
37
  :'card' => :'PaymentMethodCardResponse',
38
38
  :'cash' => :'PaymentMethodCashResponse',
39
39
  :'cash_recurrent' => :'PaymentMethodCashRecurrentResponse',
40
- :'spei_recurrent' => :'PaymentMethodSpeiRecurrent'
40
+ :'spei_recurrent' => :'PaymentMethodSpeiRecurrentResponse'
41
41
  }
42
42
  end
43
43
 
@@ -3,10 +3,10 @@
3
3
 
4
4
  #Conekta sdk
5
5
 
6
- The version of the OpenAPI document: 2.2.0
6
+ The version of the OpenAPI document: 2.3.0
7
7
  Contact: engineering@conekta.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.5.0
9
+ Generator version: 7.24.0
10
10
 
11
11
  =end
12
12
 
@@ -14,7 +14,7 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Conekta
17
- class CustomerUpdateFiscalEntitiesRequest
17
+ class UpdateFiscalEntityRequest < ApiModelBase
18
18
  attr_accessor :address
19
19
 
20
20
  attr_accessor :tax_id
@@ -39,15 +39,20 @@ module Conekta
39
39
  }
40
40
  end
41
41
 
42
+ # Returns attribute mapping this model knows about
43
+ def self.acceptable_attribute_map
44
+ attribute_map
45
+ end
46
+
42
47
  # Returns all the JSON keys this model knows about
43
48
  def self.acceptable_attributes
44
- attribute_map.values
49
+ acceptable_attribute_map.values
45
50
  end
46
51
 
47
52
  # Attribute type mapping.
48
53
  def self.openapi_types
49
54
  {
50
- :'address' => :'CustomerAddress',
55
+ :'address' => :'FiscalEntityRequestAddress',
51
56
  :'tax_id' => :'String',
52
57
  :'email' => :'String',
53
58
  :'phone' => :'String',
@@ -59,6 +64,7 @@ module Conekta
59
64
  # List of attributes with nullable: true
60
65
  def self.openapi_nullable
61
66
  Set.new([
67
+ :'metadata',
62
68
  ])
63
69
  end
64
70
 
@@ -66,13 +72,14 @@ module Conekta
66
72
  # @param [Hash] attributes Model attributes in the form of hash
67
73
  def initialize(attributes = {})
68
74
  if (!attributes.is_a?(Hash))
69
- fail ArgumentError, "The input argument (attributes) must be a hash in `Conekta::CustomerUpdateFiscalEntitiesRequest` initialize method"
75
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Conekta::UpdateFiscalEntityRequest` initialize method"
70
76
  end
71
77
 
72
78
  # check to see if the attribute exists and convert string to symbol for hash key
79
+ acceptable_attribute_map = self.class.acceptable_attribute_map
73
80
  attributes = attributes.each_with_object({}) { |(k, v), h|
74
- if (!self.class.attribute_map.key?(k.to_sym))
75
- fail ArgumentError, "`#{k}` is not a valid attribute in `Conekta::CustomerUpdateFiscalEntitiesRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
81
+ if (!acceptable_attribute_map.key?(k.to_sym))
82
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Conekta::UpdateFiscalEntityRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
76
83
  end
77
84
  h[k.to_sym] = v
78
85
  }
@@ -94,9 +101,6 @@ module Conekta
94
101
  end
95
102
 
96
103
  if attributes.key?(:'metadata')
97
- if (value = attributes[:'metadata']).is_a?(Hash)
98
- self.metadata = value
99
- end
100
104
  end
101
105
 
102
106
  if attributes.key?(:'company_name')
@@ -167,61 +171,6 @@ module Conekta
167
171
  new(transformed_hash)
168
172
  end
169
173
 
170
- # Deserializes the data based on type
171
- # @param string type Data type
172
- # @param string value Value to be deserialized
173
- # @return [Object] Deserialized data
174
- def self._deserialize(type, value)
175
- case type.to_sym
176
- when :Time
177
- Time.parse(value)
178
- when :Date
179
- Date.parse(value)
180
- when :String
181
- value.to_s
182
- when :Integer
183
- value.to_i
184
- when :Float
185
- value.to_f
186
- when :Boolean
187
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
188
- true
189
- else
190
- false
191
- end
192
- when :Object
193
- # generic object (usually a Hash), return directly
194
- value
195
- when /\AArray<(?<inner_type>.+)>\z/
196
- inner_type = Regexp.last_match[:inner_type]
197
- value.map { |v| _deserialize(inner_type, v) }
198
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
199
- k_type = Regexp.last_match[:k_type]
200
- v_type = Regexp.last_match[:v_type]
201
- {}.tap do |hash|
202
- value.each do |k, v|
203
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
204
- end
205
- end
206
- else # model
207
- # models (e.g. Pet) or oneOf
208
- klass = Conekta.const_get(type)
209
- klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
210
- end
211
- end
212
-
213
- # Returns the string representation of the object
214
- # @return [String] String presentation of the object
215
- def to_s
216
- to_hash.to_s
217
- end
218
-
219
- # to_body is an alias to to_hash (backward compatibility)
220
- # @return [Hash] Returns the object in the form of hash
221
- def to_body
222
- to_hash
223
- end
224
-
225
174
  # Returns the object in the form of hash
226
175
  # @return [Hash] Returns the object in the form of hash
227
176
  def to_hash
@@ -238,24 +187,6 @@ module Conekta
238
187
  hash
239
188
  end
240
189
 
241
- # Outputs non-array value in the form of hash
242
- # For object, use to_hash. Otherwise, just return the value
243
- # @param [Object] value Any valid value
244
- # @return [Hash] Returns the value in the form of hash
245
- def _to_hash(value)
246
- if value.is_a?(Array)
247
- value.compact.map { |v| _to_hash(v) }
248
- elsif value.is_a?(Hash)
249
- {}.tap do |hash|
250
- value.each { |k, v| hash[k] = _to_hash(v) }
251
- end
252
- elsif value.respond_to? :to_hash
253
- value.to_hash
254
- else
255
- value
256
- end
257
- end
258
-
259
190
  end
260
191
 
261
192
  end
@@ -3,10 +3,10 @@
3
3
 
4
4
  #Conekta sdk
5
5
 
6
- The version of the OpenAPI document: 2.2.0
6
+ The version of the OpenAPI document: 2.3.0
7
7
  Contact: engineering@conekta.com
8
8
  Generated by: https://openapi-generator.tech
9
- Generator version: 7.5.0
9
+ Generator version: 7.24.0
10
10
 
11
11
  =end
12
12
 
@@ -15,7 +15,7 @@ require 'time'
15
15
 
16
16
  module Conekta
17
17
  # List of discounts that apply to the order.
18
- class UpdateOrderDiscountLinesRequest
18
+ class UpdateOrderDiscountLinesRequest < ApiModelBase
19
19
  attr_accessor :amount
20
20
 
21
21
  # Discount code.
@@ -32,9 +32,14 @@ module Conekta
32
32
  }
33
33
  end
34
34
 
35
+ # Returns attribute mapping this model knows about
36
+ def self.acceptable_attribute_map
37
+ attribute_map
38
+ end
39
+
35
40
  # Returns all the JSON keys this model knows about
36
41
  def self.acceptable_attributes
37
- attribute_map.values
42
+ acceptable_attribute_map.values
38
43
  end
39
44
 
40
45
  # Attribute type mapping.
@@ -60,9 +65,10 @@ module Conekta
60
65
  end
61
66
 
62
67
  # check to see if the attribute exists and convert string to symbol for hash key
68
+ acceptable_attribute_map = self.class.acceptable_attribute_map
63
69
  attributes = attributes.each_with_object({}) { |(k, v), h|
64
- if (!self.class.attribute_map.key?(k.to_sym))
65
- fail ArgumentError, "`#{k}` is not a valid attribute in `Conekta::UpdateOrderDiscountLinesRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
70
+ if (!acceptable_attribute_map.key?(k.to_sym))
71
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Conekta::UpdateOrderDiscountLinesRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
66
72
  end
67
73
  h[k.to_sym] = v
68
74
  }
@@ -159,61 +165,6 @@ module Conekta
159
165
  new(transformed_hash)
160
166
  end
161
167
 
162
- # Deserializes the data based on type
163
- # @param string type Data type
164
- # @param string value Value to be deserialized
165
- # @return [Object] Deserialized data
166
- def self._deserialize(type, value)
167
- case type.to_sym
168
- when :Time
169
- Time.parse(value)
170
- when :Date
171
- Date.parse(value)
172
- when :String
173
- value.to_s
174
- when :Integer
175
- value.to_i
176
- when :Float
177
- value.to_f
178
- when :Boolean
179
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
180
- true
181
- else
182
- false
183
- end
184
- when :Object
185
- # generic object (usually a Hash), return directly
186
- value
187
- when /\AArray<(?<inner_type>.+)>\z/
188
- inner_type = Regexp.last_match[:inner_type]
189
- value.map { |v| _deserialize(inner_type, v) }
190
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
191
- k_type = Regexp.last_match[:k_type]
192
- v_type = Regexp.last_match[:v_type]
193
- {}.tap do |hash|
194
- value.each do |k, v|
195
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
196
- end
197
- end
198
- else # model
199
- # models (e.g. Pet) or oneOf
200
- klass = Conekta.const_get(type)
201
- klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
202
- end
203
- end
204
-
205
- # Returns the string representation of the object
206
- # @return [String] String presentation of the object
207
- def to_s
208
- to_hash.to_s
209
- end
210
-
211
- # to_body is an alias to to_hash (backward compatibility)
212
- # @return [Hash] Returns the object in the form of hash
213
- def to_body
214
- to_hash
215
- end
216
-
217
168
  # Returns the object in the form of hash
218
169
  # @return [Hash] Returns the object in the form of hash
219
170
  def to_hash
@@ -230,24 +181,6 @@ module Conekta
230
181
  hash
231
182
  end
232
183
 
233
- # Outputs non-array value in the form of hash
234
- # For object, use to_hash. Otherwise, just return the value
235
- # @param [Object] value Any valid value
236
- # @return [Hash] Returns the value in the form of hash
237
- def _to_hash(value)
238
- if value.is_a?(Array)
239
- value.compact.map { |v| _to_hash(v) }
240
- elsif value.is_a?(Hash)
241
- {}.tap do |hash|
242
- value.each { |k, v| hash[k] = _to_hash(v) }
243
- end
244
- elsif value.respond_to? :to_hash
245
- value.to_hash
246
- else
247
- value
248
- end
249
- end
250
-
251
184
  end
252
185
 
253
186
  end