maxio-advanced-billing-sdk 1.0.0 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +59 -297
- data/lib/advanced_billing/client.rb +21 -22
- data/lib/advanced_billing/configuration.rb +17 -18
- data/lib/advanced_billing/controllers/advance_invoice_controller.rb +8 -10
- data/lib/advanced_billing/controllers/api_exports_controller.rb +9 -9
- data/lib/advanced_billing/controllers/base_controller.rb +2 -1
- data/lib/advanced_billing/controllers/billing_portal_controller.rb +4 -4
- data/lib/advanced_billing/controllers/components_controller.rb +22 -22
- data/lib/advanced_billing/controllers/coupons_controller.rb +14 -14
- data/lib/advanced_billing/controllers/custom_fields_controller.rb +9 -9
- data/lib/advanced_billing/controllers/customers_controller.rb +7 -7
- data/lib/advanced_billing/controllers/events_based_billing_segments_controller.rb +6 -6
- data/lib/advanced_billing/controllers/events_controller.rb +3 -3
- data/lib/advanced_billing/controllers/insights_controller.rb +4 -4
- data/lib/advanced_billing/controllers/invoices_controller.rb +24 -20
- data/lib/advanced_billing/controllers/offers_controller.rb +5 -5
- data/lib/advanced_billing/controllers/payment_profiles_controller.rb +12 -12
- data/lib/advanced_billing/controllers/product_families_controller.rb +4 -4
- data/lib/advanced_billing/controllers/product_price_points_controller.rb +11 -11
- data/lib/advanced_billing/controllers/products_controller.rb +6 -6
- data/lib/advanced_billing/controllers/proforma_invoices_controller.rb +44 -25
- data/lib/advanced_billing/controllers/reason_codes_controller.rb +5 -5
- data/lib/advanced_billing/controllers/referral_codes_controller.rb +2 -2
- data/lib/advanced_billing/controllers/sales_commissions_controller.rb +3 -3
- data/lib/advanced_billing/controllers/sites_controller.rb +3 -3
- data/lib/advanced_billing/controllers/subscription_components_controller.rb +37 -31
- data/lib/advanced_billing/controllers/subscription_group_invoice_account_controller.rb +4 -4
- data/lib/advanced_billing/controllers/subscription_group_status_controller.rb +4 -4
- data/lib/advanced_billing/controllers/subscription_groups_controller.rb +23 -16
- data/lib/advanced_billing/controllers/subscription_invoice_account_controller.rb +11 -7
- data/lib/advanced_billing/controllers/subscription_notes_controller.rb +5 -5
- data/lib/advanced_billing/controllers/subscription_products_controller.rb +2 -2
- data/lib/advanced_billing/controllers/subscription_status_controller.rb +10 -10
- data/lib/advanced_billing/controllers/subscriptions_controller.rb +12 -12
- data/lib/advanced_billing/controllers/webhooks_controller.rb +8 -8
- data/lib/advanced_billing/exceptions/subscription_group_create_error_response_exception.rb +34 -0
- data/lib/advanced_billing/http/auth/basic_auth.rb +27 -6
- data/lib/advanced_billing/models/account_balance.rb +44 -3
- data/lib/advanced_billing/models/account_balances.rb +24 -2
- data/lib/advanced_billing/models/ach_agreement.rb +12 -2
- data/lib/advanced_billing/models/activate_subscription_request.rb +12 -2
- data/lib/advanced_billing/models/add_coupons_request.rb +12 -2
- data/lib/advanced_billing/models/add_subscription_to_a_group.rb +12 -2
- data/lib/advanced_billing/models/address_change.rb +12 -2
- data/lib/advanced_billing/models/agreement_acceptance.rb +12 -2
- data/lib/advanced_billing/models/allocate_components.rb +12 -2
- data/lib/advanced_billing/models/allocation.rb +56 -2
- data/lib/advanced_billing/models/allocation_expiration_date.rb +23 -4
- data/lib/advanced_billing/models/allocation_preview.rb +33 -6
- data/lib/advanced_billing/models/allocation_preview_item.rb +12 -2
- data/lib/advanced_billing/models/allocation_preview_line_item.rb +12 -2
- data/lib/advanced_billing/models/allocation_preview_response.rb +12 -2
- data/lib/advanced_billing/models/allocation_response.rb +12 -2
- data/lib/advanced_billing/models/allocation_settings.rb +12 -2
- data/lib/advanced_billing/models/applied_credit_note_data.rb +12 -2
- data/lib/advanced_billing/models/apply_credit_note_event_data.rb +12 -2
- data/lib/advanced_billing/models/apply_debit_note_event_data.rb +12 -2
- data/lib/advanced_billing/models/apply_payment_event_data.rb +12 -2
- data/lib/advanced_billing/models/attribute_error.rb +12 -2
- data/lib/advanced_billing/models/auto_resume.rb +12 -2
- data/lib/advanced_billing/models/bank_account_attributes.rb +12 -2
- data/lib/advanced_billing/models/bank_account_payment_profile.rb +13 -2
- data/lib/advanced_billing/models/bank_account_response.rb +12 -2
- data/lib/advanced_billing/models/bank_account_verification.rb +12 -2
- data/lib/advanced_billing/models/bank_account_verification_request.rb +12 -2
- data/lib/advanced_billing/models/base_refund_error.rb +12 -2
- data/lib/advanced_billing/models/base_string_error.rb +12 -2
- data/lib/advanced_billing/models/batch_job.rb +33 -6
- data/lib/advanced_billing/models/batch_job_response.rb +12 -2
- data/lib/advanced_billing/models/billing_address.rb +12 -2
- data/lib/advanced_billing/models/billing_manifest.rb +33 -6
- data/lib/advanced_billing/models/billing_manifest_item.rb +12 -2
- data/lib/advanced_billing/models/billing_schedule.rb +12 -2
- data/lib/advanced_billing/models/breakouts.rb +12 -2
- data/lib/advanced_billing/models/{bulk_component_s_price_point_assignment.rb → bulk_components_price_point_assignment.rb} +16 -6
- data/lib/advanced_billing/models/bulk_create_product_price_points_request.rb +12 -2
- data/lib/advanced_billing/models/bulk_create_product_price_points_response.rb +12 -2
- data/lib/advanced_billing/models/bulk_create_segments.rb +12 -2
- data/lib/advanced_billing/models/bulk_update_segments.rb +12 -2
- data/lib/advanced_billing/models/bulk_update_segments_item.rb +12 -2
- data/lib/advanced_billing/models/calendar_billing.rb +12 -2
- data/lib/advanced_billing/models/cancel_grouped_subscriptions_request.rb +12 -2
- data/lib/advanced_billing/models/cancellation_options.rb +12 -2
- data/lib/advanced_billing/models/cancellation_request.rb +12 -2
- data/lib/advanced_billing/models/change_invoice_collection_method_event_data.rb +12 -2
- data/lib/advanced_billing/models/chargify_ebb.rb +33 -6
- data/lib/advanced_billing/models/component.rb +22 -4
- data/lib/advanced_billing/models/component_allocation_change.rb +12 -2
- data/lib/advanced_billing/models/component_allocation_error_item.rb +12 -2
- data/lib/advanced_billing/models/component_cost_data.rb +12 -2
- data/lib/advanced_billing/models/component_cost_data_rate_tier.rb +12 -2
- data/lib/advanced_billing/models/component_currency_price.rb +12 -2
- data/lib/advanced_billing/models/component_currency_prices_response.rb +12 -2
- data/lib/advanced_billing/models/component_custom_price.rb +12 -2
- data/lib/advanced_billing/models/component_price.rb +12 -2
- data/lib/advanced_billing/models/component_price_point.rb +12 -2
- data/lib/advanced_billing/models/{component_s_price_point_assignment.rb → component_price_point_assignment.rb} +17 -7
- data/lib/advanced_billing/models/component_price_point_error_item.rb +12 -2
- data/lib/advanced_billing/models/component_price_point_item.rb +12 -2
- data/lib/advanced_billing/models/component_price_point_response.rb +12 -2
- data/lib/advanced_billing/models/component_price_points_response.rb +12 -2
- data/lib/advanced_billing/models/component_response.rb +12 -2
- data/lib/advanced_billing/models/consolidated_invoice.rb +12 -2
- data/lib/advanced_billing/models/count_response.rb +12 -2
- data/lib/advanced_billing/models/coupon.rb +78 -12
- data/lib/advanced_billing/models/coupon_currency.rb +12 -2
- data/lib/advanced_billing/models/coupon_currency_request.rb +12 -2
- data/lib/advanced_billing/models/coupon_currency_response.rb +12 -2
- data/lib/advanced_billing/models/coupon_response.rb +12 -2
- data/lib/advanced_billing/models/coupon_restriction.rb +12 -2
- data/lib/advanced_billing/models/coupon_subcodes.rb +12 -2
- data/lib/advanced_billing/models/coupon_subcodes_response.rb +12 -2
- data/lib/advanced_billing/models/coupon_usage.rb +12 -2
- data/lib/advanced_billing/models/create_allocation.rb +12 -2
- data/lib/advanced_billing/models/create_allocation_request.rb +12 -2
- data/lib/advanced_billing/models/create_component_price_point.rb +12 -2
- data/lib/advanced_billing/models/create_component_price_point_request.rb +12 -2
- data/lib/advanced_billing/models/create_component_price_points_request.rb +12 -2
- data/lib/advanced_billing/models/create_currency_price.rb +12 -2
- data/lib/advanced_billing/models/create_currency_prices_request.rb +12 -2
- data/lib/advanced_billing/models/create_customer.rb +12 -2
- data/lib/advanced_billing/models/create_customer_request.rb +12 -2
- data/lib/advanced_billing/models/create_ebb_component.rb +12 -2
- data/lib/advanced_billing/models/create_invoice.rb +12 -2
- data/lib/advanced_billing/models/create_invoice_address.rb +12 -2
- data/lib/advanced_billing/models/create_invoice_coupon.rb +12 -2
- data/lib/advanced_billing/models/create_invoice_item.rb +12 -2
- data/lib/advanced_billing/models/create_invoice_payment.rb +23 -2
- data/lib/advanced_billing/models/create_invoice_payment_application.rb +12 -2
- data/lib/advanced_billing/models/create_invoice_payment_request.rb +12 -2
- data/lib/advanced_billing/models/create_invoice_request.rb +12 -2
- data/lib/advanced_billing/models/create_metadata.rb +12 -2
- data/lib/advanced_billing/models/create_metadata_request.rb +12 -2
- data/lib/advanced_billing/models/create_metafield.rb +12 -2
- data/lib/advanced_billing/models/create_metafields_request.rb +12 -2
- data/lib/advanced_billing/models/create_metered_component.rb +12 -2
- data/lib/advanced_billing/models/create_multi_invoice_payment.rb +12 -2
- data/lib/advanced_billing/models/create_multi_invoice_payment_request.rb +12 -2
- data/lib/advanced_billing/models/create_offer.rb +12 -2
- data/lib/advanced_billing/models/create_offer_component.rb +12 -2
- data/lib/advanced_billing/models/create_offer_request.rb +12 -2
- data/lib/advanced_billing/models/create_on_off_component.rb +12 -2
- data/lib/advanced_billing/models/create_or_update_coupon.rb +12 -2
- data/lib/advanced_billing/models/{update_endpoint.rb → create_or_update_endpoint.rb} +14 -4
- data/lib/advanced_billing/models/{update_endpoint_request.rb → create_or_update_endpoint_request.rb} +15 -5
- data/lib/advanced_billing/models/create_or_update_flat_amount_coupon.rb +29 -2
- data/lib/advanced_billing/models/create_or_update_percentage_coupon.rb +29 -2
- data/lib/advanced_billing/models/create_or_update_product.rb +86 -4
- data/lib/advanced_billing/models/create_or_update_product_request.rb +12 -2
- data/lib/advanced_billing/models/create_or_update_segment_price.rb +12 -2
- data/lib/advanced_billing/models/create_payment.rb +14 -4
- data/lib/advanced_billing/models/create_payment_profile.rb +12 -2
- data/lib/advanced_billing/models/create_payment_profile_request.rb +12 -2
- data/lib/advanced_billing/models/create_prepaid_component.rb +12 -2
- data/lib/advanced_billing/models/create_prepaid_usage_component_price_point.rb +12 -2
- data/lib/advanced_billing/models/create_prepayment.rb +13 -3
- data/lib/advanced_billing/models/create_prepayment_method.rb +44 -0
- data/lib/advanced_billing/models/create_prepayment_request.rb +12 -2
- data/lib/advanced_billing/models/create_prepayment_response.rb +12 -2
- data/lib/advanced_billing/models/create_product_currency_price.rb +12 -2
- data/lib/advanced_billing/models/create_product_currency_prices_request.rb +12 -2
- data/lib/advanced_billing/models/create_product_family.rb +12 -2
- data/lib/advanced_billing/models/create_product_family_request.rb +12 -2
- data/lib/advanced_billing/models/create_product_price_point.rb +16 -6
- data/lib/advanced_billing/models/create_product_price_point_request.rb +12 -2
- data/lib/advanced_billing/models/create_quantity_based_component.rb +12 -2
- data/lib/advanced_billing/models/create_reason_code.rb +12 -2
- data/lib/advanced_billing/models/create_reason_code_request.rb +12 -2
- data/lib/advanced_billing/models/create_segment.rb +12 -2
- data/lib/advanced_billing/models/create_segment_request.rb +12 -2
- data/lib/advanced_billing/models/create_signup_proforma_preview_include.rb +20 -0
- data/lib/advanced_billing/models/create_subscription.rb +22 -4
- data/lib/advanced_billing/models/create_subscription_component.rb +12 -2
- data/lib/advanced_billing/models/create_subscription_group.rb +15 -20
- data/lib/advanced_billing/models/create_subscription_group_request.rb +12 -2
- data/lib/advanced_billing/models/create_subscription_request.rb +12 -2
- data/lib/advanced_billing/models/create_usage.rb +12 -2
- data/lib/advanced_billing/models/create_usage_request.rb +12 -2
- data/lib/advanced_billing/models/created_prepayment.rb +23 -4
- data/lib/advanced_billing/models/credit_account_balance_changed.rb +22 -5
- data/lib/advanced_billing/models/credit_card_attributes.rb +12 -2
- data/lib/advanced_billing/models/credit_card_payment_profile.rb +12 -2
- data/lib/advanced_billing/models/credit_note.rb +12 -2
- data/lib/advanced_billing/models/credit_note1.rb +12 -2
- data/lib/advanced_billing/models/credit_note_application.rb +23 -5
- data/lib/advanced_billing/models/credit_note_line_item.rb +38 -4
- data/lib/advanced_billing/models/credit_scheme_request.rb +12 -2
- data/lib/advanced_billing/models/currency_price.rb +12 -2
- data/lib/advanced_billing/models/currency_prices_response.rb +12 -2
- data/lib/advanced_billing/models/custom_field_value_change.rb +12 -2
- data/lib/advanced_billing/models/customer.rb +63 -15
- data/lib/advanced_billing/models/customer1.rb +13 -2
- data/lib/advanced_billing/models/customer_attributes.rb +12 -2
- data/lib/advanced_billing/models/customer_change.rb +12 -2
- data/lib/advanced_billing/models/customer_changes_preview_response.rb +12 -2
- data/lib/advanced_billing/models/customer_custom_fields_change.rb +12 -2
- data/lib/advanced_billing/models/customer_error.rb +12 -2
- data/lib/advanced_billing/models/customer_payer_change.rb +12 -2
- data/lib/advanced_billing/models/customer_response.rb +12 -2
- data/lib/advanced_billing/models/deduct_service_credit.rb +12 -2
- data/lib/advanced_billing/models/deduct_service_credit_request.rb +12 -2
- data/lib/advanced_billing/models/delayed_cancellation_response.rb +12 -2
- data/lib/advanced_billing/models/delete_subscription_group_response.rb +12 -2
- data/lib/advanced_billing/models/dunner_data.rb +29 -7
- data/lib/advanced_billing/models/dunning_step_data.rb +12 -2
- data/lib/advanced_billing/models/dunning_step_reached.rb +12 -2
- data/lib/advanced_billing/models/ebb_component.rb +12 -2
- data/lib/advanced_billing/models/ebb_event.rb +12 -2
- data/lib/advanced_billing/models/enable_webhooks_request.rb +12 -2
- data/lib/advanced_billing/models/enable_webhooks_response.rb +12 -2
- data/lib/advanced_billing/models/endpoint.rb +12 -2
- data/lib/advanced_billing/models/endpoint_response.rb +12 -2
- data/lib/advanced_billing/models/errors.rb +12 -2
- data/lib/advanced_billing/models/event.rb +23 -5
- data/lib/advanced_billing/models/event_based_billing_segment_error.rb +12 -2
- data/lib/advanced_billing/models/event_response.rb +12 -2
- data/lib/advanced_billing/models/full_subscription_group_response.rb +369 -11
- data/lib/advanced_billing/models/get_one_time_token_payment_profile.rb +12 -2
- data/lib/advanced_billing/models/get_one_time_token_request.rb +12 -2
- data/lib/advanced_billing/models/group_billing.rb +12 -2
- data/lib/advanced_billing/models/group_settings.rb +12 -2
- data/lib/advanced_billing/models/group_target.rb +12 -2
- data/lib/advanced_billing/models/group_type.rb +23 -0
- data/lib/advanced_billing/models/invoice.rb +12 -2
- data/lib/advanced_billing/models/invoice_address.rb +12 -2
- data/lib/advanced_billing/models/invoice_balance_item.rb +12 -2
- data/lib/advanced_billing/models/invoice_credit.rb +12 -2
- data/lib/advanced_billing/models/invoice_custom_field.rb +12 -2
- data/lib/advanced_billing/models/invoice_customer.rb +13 -2
- data/lib/advanced_billing/models/invoice_discount.rb +14 -4
- data/lib/advanced_billing/models/invoice_discount_breakout.rb +12 -2
- data/lib/advanced_billing/models/invoice_discount_source_type.rb +26 -0
- data/lib/advanced_billing/models/invoice_discount_type.rb +26 -0
- data/lib/advanced_billing/models/invoice_display_settings.rb +12 -2
- data/lib/advanced_billing/models/invoice_event.rb +23 -4
- data/lib/advanced_billing/models/invoice_event_data.rb +12 -2
- data/lib/advanced_billing/models/invoice_event_payment.rb +12 -2
- data/lib/advanced_billing/models/invoice_event_payment1.rb +12 -2
- data/lib/advanced_billing/models/invoice_issued.rb +27 -15
- data/lib/advanced_billing/models/invoice_line_item.rb +22 -2
- data/lib/advanced_billing/models/invoice_line_item_component_cost_data.rb +12 -2
- data/lib/advanced_billing/models/invoice_line_item_event_data.rb +12 -2
- data/lib/advanced_billing/models/invoice_line_item_pricing_detail.rb +12 -2
- data/lib/advanced_billing/models/invoice_payer.rb +12 -2
- data/lib/advanced_billing/models/invoice_payer_change.rb +12 -2
- data/lib/advanced_billing/models/invoice_payment.rb +12 -2
- data/lib/advanced_billing/models/invoice_payment_application.rb +12 -2
- data/lib/advanced_billing/models/invoice_payment_method.rb +12 -2
- data/lib/advanced_billing/models/invoice_pre_payment.rb +25 -5
- data/lib/advanced_billing/models/invoice_previous_balance.rb +12 -2
- data/lib/advanced_billing/models/invoice_refund.rb +34 -2
- data/lib/advanced_billing/models/invoice_response.rb +12 -2
- data/lib/advanced_billing/models/invoice_seller.rb +12 -2
- data/lib/advanced_billing/models/invoice_tax.rb +13 -3
- data/lib/advanced_billing/models/invoice_tax_breakout.rb +23 -2
- data/lib/advanced_billing/models/invoice_tax_component_breakout.rb +12 -2
- data/lib/advanced_billing/models/issue_advance_invoice_request.rb +12 -2
- data/lib/advanced_billing/models/issue_invoice_event_data.rb +12 -2
- data/lib/advanced_billing/models/issue_invoice_request.rb +12 -2
- data/lib/advanced_billing/models/issue_service_credit.rb +12 -2
- data/lib/advanced_billing/models/issue_service_credit_request.rb +12 -2
- data/lib/advanced_billing/models/item_price_point_changed.rb +12 -2
- data/lib/advanced_billing/models/item_price_point_data.rb +12 -2
- data/lib/advanced_billing/models/list_components_price_points_response.rb +12 -2
- data/lib/advanced_billing/models/list_credit_notes_response.rb +12 -2
- data/lib/advanced_billing/models/list_invoice_events_response.rb +12 -2
- data/lib/advanced_billing/models/list_invoices_response.rb +12 -2
- data/lib/advanced_billing/models/list_metafields_response.rb +12 -2
- data/lib/advanced_billing/models/list_mrr_response.rb +12 -2
- data/lib/advanced_billing/models/list_mrr_response_result.rb +12 -2
- data/lib/advanced_billing/models/list_offers_response.rb +12 -2
- data/lib/advanced_billing/models/list_product_price_points_response.rb +12 -2
- data/lib/advanced_billing/models/list_proforma_invoices_meta.rb +90 -0
- data/lib/advanced_billing/models/list_proforma_invoices_response.rb +79 -0
- data/lib/advanced_billing/models/list_public_keys_meta.rb +12 -2
- data/lib/advanced_billing/models/list_public_keys_response.rb +12 -2
- data/lib/advanced_billing/models/list_sale_rep_item.rb +12 -2
- data/lib/advanced_billing/models/list_segments_response.rb +12 -2
- data/lib/advanced_billing/models/list_subcription_group_prepayment_item.rb +25 -12
- data/lib/advanced_billing/models/list_subscription_components_response.rb +12 -2
- data/lib/advanced_billing/models/list_subscription_group_prepayment.rb +12 -2
- data/lib/advanced_billing/models/list_subscription_group_prepayment_response.rb +12 -2
- data/lib/advanced_billing/models/list_subscription_groups_item.rb +33 -5
- data/lib/advanced_billing/models/list_subscription_groups_meta.rb +12 -2
- data/lib/advanced_billing/models/list_subscription_groups_response.rb +12 -2
- data/lib/advanced_billing/models/metadata.rb +23 -4
- data/lib/advanced_billing/models/metafield.rb +12 -2
- data/lib/advanced_billing/models/metafield_scope.rb +12 -2
- data/lib/advanced_billing/models/metered_component.rb +12 -2
- data/lib/advanced_billing/models/metered_usage.rb +12 -2
- data/lib/advanced_billing/models/movement.rb +23 -4
- data/lib/advanced_billing/models/movement_line_item.rb +12 -2
- data/lib/advanced_billing/models/mrr.rb +23 -4
- data/lib/advanced_billing/models/mrr_movement.rb +12 -2
- data/lib/advanced_billing/models/mrr_response.rb +12 -2
- data/lib/advanced_billing/models/multi_invoice_payment.rb +12 -2
- data/lib/advanced_billing/models/multi_invoice_payment_response.rb +12 -2
- data/lib/advanced_billing/models/nested_subscription_group.rb +12 -2
- data/lib/advanced_billing/models/net_terms.rb +12 -2
- data/lib/advanced_billing/models/offer.rb +43 -8
- data/lib/advanced_billing/models/offer_discount.rb +12 -2
- data/lib/advanced_billing/models/offer_item.rb +12 -2
- data/lib/advanced_billing/models/offer_response.rb +12 -2
- data/lib/advanced_billing/models/offer_signup_page.rb +12 -2
- data/lib/advanced_billing/models/on_off_component.rb +12 -2
- data/lib/advanced_billing/models/organization_address.rb +12 -2
- data/lib/advanced_billing/models/origin_invoice.rb +12 -2
- data/lib/advanced_billing/models/overage_pricing.rb +12 -2
- data/lib/advanced_billing/models/override_subscription.rb +12 -2
- data/lib/advanced_billing/models/override_subscription_request.rb +12 -2
- data/lib/advanced_billing/models/paginated_metadata.rb +12 -2
- data/lib/advanced_billing/models/{payment.rb → paid_invoice.rb} +23 -13
- data/lib/advanced_billing/models/pause_request.rb +12 -2
- data/lib/advanced_billing/models/payer_attributes.rb +13 -3
- data/lib/advanced_billing/models/payer_error.rb +12 -2
- data/lib/advanced_billing/models/payment_collection_method_changed.rb +12 -2
- data/lib/advanced_billing/models/payment_for_allocation.rb +12 -2
- data/lib/advanced_billing/models/payment_method_apple_pay.rb +12 -2
- data/lib/advanced_billing/models/payment_method_bank_account.rb +12 -2
- data/lib/advanced_billing/models/payment_method_credit_card.rb +12 -2
- data/lib/advanced_billing/models/payment_method_external.rb +12 -2
- data/lib/advanced_billing/models/payment_method_paypal.rb +12 -2
- data/lib/advanced_billing/models/payment_profile_attributes.rb +12 -2
- data/lib/advanced_billing/models/payment_profile_response.rb +12 -2
- data/lib/advanced_billing/models/payment_related_events.rb +12 -2
- data/lib/advanced_billing/models/pending_cancellation_change.rb +22 -5
- data/lib/advanced_billing/models/portal_management_link.rb +53 -12
- data/lib/advanced_billing/models/prepaid_component_price_point.rb +12 -2
- data/lib/advanced_billing/models/prepaid_configuration.rb +12 -2
- data/lib/advanced_billing/models/prepaid_configuration_response.rb +12 -2
- data/lib/advanced_billing/models/prepaid_subscription_balance_changed.rb +12 -2
- data/lib/advanced_billing/models/prepaid_usage.rb +12 -2
- data/lib/advanced_billing/models/prepaid_usage_allocation_detail.rb +12 -2
- data/lib/advanced_billing/models/prepaid_usage_component.rb +12 -2
- data/lib/advanced_billing/models/prepayment.rb +21 -4
- data/lib/advanced_billing/models/prepayment_account_balance_changed.rb +12 -2
- data/lib/advanced_billing/models/prepayment_aggregated_error.rb +12 -2
- data/lib/advanced_billing/models/prepayment_method.rb +3 -6
- data/lib/advanced_billing/models/prepayment_response.rb +12 -2
- data/lib/advanced_billing/models/prepayments_response.rb +12 -2
- data/lib/advanced_billing/models/preview_allocations_request.rb +12 -2
- data/lib/advanced_billing/models/price.rb +12 -2
- data/lib/advanced_billing/models/price_point.rb +12 -2
- data/lib/advanced_billing/models/product.rb +14 -4
- data/lib/advanced_billing/models/product_family.rb +33 -6
- data/lib/advanced_billing/models/product_family_response.rb +12 -2
- data/lib/advanced_billing/models/product_price_point.rb +16 -6
- data/lib/advanced_billing/models/product_price_point_errors.rb +12 -2
- data/lib/advanced_billing/models/product_price_point_response.rb +12 -2
- data/lib/advanced_billing/models/product_response.rb +12 -2
- data/lib/advanced_billing/models/proforma_error.rb +12 -2
- data/lib/advanced_billing/models/proforma_invoice.rb +87 -19
- data/lib/advanced_billing/models/proforma_invoice_credit.rb +12 -2
- data/lib/advanced_billing/models/proforma_invoice_discount.rb +37 -7
- data/lib/advanced_billing/models/proforma_invoice_discount_source_type.rb +23 -0
- data/lib/advanced_billing/models/proforma_invoice_issued.rb +23 -6
- data/lib/advanced_billing/models/proforma_invoice_payment.rb +12 -2
- data/lib/advanced_billing/models/proforma_invoice_role.rb +30 -0
- data/lib/advanced_billing/models/proforma_invoice_status.rb +26 -0
- data/lib/advanced_billing/models/proforma_invoice_tax.rb +15 -5
- data/lib/advanced_billing/models/proforma_invoice_tax_source_type.rb +23 -0
- data/lib/advanced_billing/models/proration.rb +12 -2
- data/lib/advanced_billing/models/public_key.rb +23 -4
- data/lib/advanced_billing/models/public_signup_page.rb +12 -2
- data/lib/advanced_billing/models/quantity_based_component.rb +12 -2
- data/lib/advanced_billing/models/reactivate_subscription_group_request.rb +12 -2
- data/lib/advanced_billing/models/reactivate_subscription_group_response.rb +23 -5
- data/lib/advanced_billing/models/reactivate_subscription_request.rb +12 -2
- data/lib/advanced_billing/models/reactivation_billing.rb +12 -2
- data/lib/advanced_billing/models/reason_code.rb +33 -6
- data/lib/advanced_billing/models/reason_code_response.rb +12 -2
- data/lib/advanced_billing/models/reason_codes_json_response.rb +12 -2
- data/lib/advanced_billing/models/record_payment_request.rb +12 -2
- data/lib/advanced_billing/models/{payment_response.rb → record_payment_response.rb} +33 -9
- data/lib/advanced_billing/models/referral_code.rb +12 -2
- data/lib/advanced_billing/models/referral_validation_response.rb +12 -2
- data/lib/advanced_billing/models/refund.rb +12 -2
- data/lib/advanced_billing/models/refund_consolidated_invoice.rb +12 -2
- data/lib/advanced_billing/models/refund_invoice.rb +12 -2
- data/lib/advanced_billing/models/refund_invoice_event_data.rb +12 -2
- data/lib/advanced_billing/models/refund_invoice_request.rb +12 -2
- data/lib/advanced_billing/models/refund_prepayment.rb +12 -2
- data/lib/advanced_billing/models/refund_prepayment_aggregated_error.rb +12 -2
- data/lib/advanced_billing/models/refund_prepayment_base_refund_error.rb +12 -2
- data/lib/advanced_billing/models/refund_prepayment_request.rb +12 -2
- data/lib/advanced_billing/models/refund_success.rb +12 -2
- data/lib/advanced_billing/models/remove_payment_event_data.rb +12 -2
- data/lib/advanced_billing/models/renewal_preview.rb +23 -5
- data/lib/advanced_billing/models/renewal_preview_component.rb +12 -2
- data/lib/advanced_billing/models/renewal_preview_line_item.rb +12 -2
- data/lib/advanced_billing/models/renewal_preview_request.rb +12 -2
- data/lib/advanced_billing/models/renewal_preview_response.rb +12 -2
- data/lib/advanced_billing/models/replay_webhooks_request.rb +12 -2
- data/lib/advanced_billing/models/replay_webhooks_response.rb +12 -2
- data/lib/advanced_billing/models/resent_invitation.rb +12 -2
- data/lib/advanced_billing/models/resume_options.rb +12 -2
- data/lib/advanced_billing/models/revoked_invitation.rb +12 -2
- data/lib/advanced_billing/models/sale_rep.rb +12 -2
- data/lib/advanced_billing/models/sale_rep_item_mrr.rb +12 -2
- data/lib/advanced_billing/models/sale_rep_settings.rb +12 -2
- data/lib/advanced_billing/models/sale_rep_subscription.rb +12 -2
- data/lib/advanced_billing/models/segment.rb +33 -6
- data/lib/advanced_billing/models/segment_price.rb +12 -2
- data/lib/advanced_billing/models/segment_response.rb +12 -2
- data/lib/advanced_billing/models/seller.rb +12 -2
- data/lib/advanced_billing/models/send_invoice_request.rb +12 -2
- data/lib/advanced_billing/models/service_credit.rb +12 -2
- data/lib/advanced_billing/models/service_credit_response.rb +12 -2
- data/lib/advanced_billing/models/shipping_address.rb +12 -2
- data/lib/advanced_billing/models/signup_proforma_preview.rb +12 -2
- data/lib/advanced_billing/models/signup_proforma_preview_response.rb +12 -2
- data/lib/advanced_billing/models/site.rb +12 -2
- data/lib/advanced_billing/models/site_response.rb +12 -2
- data/lib/advanced_billing/models/site_statistics.rb +16 -6
- data/lib/advanced_billing/models/site_summary.rb +12 -2
- data/lib/advanced_billing/models/subscription.rb +12 -2
- data/lib/advanced_billing/models/subscription_component.rb +22 -4
- data/lib/advanced_billing/models/subscription_component_allocation_error_item.rb +12 -2
- data/lib/advanced_billing/models/subscription_component_response.rb +12 -2
- data/lib/advanced_billing/models/subscription_component_subscription.rb +23 -4
- data/lib/advanced_billing/models/subscription_custom_price.rb +12 -2
- data/lib/advanced_billing/models/subscription_group.rb +38 -10
- data/lib/advanced_billing/models/subscription_group_balances.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_bank_account.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_component_custom_price.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_credit_card.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_customer.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_include.rb +20 -0
- data/lib/advanced_billing/models/subscription_group_item.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_member_error.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_members_array_error.rb +72 -0
- data/lib/advanced_billing/models/subscription_group_payment_profile.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_prepayment.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_prepayment_request.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_prepayment_response.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_response.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup_component.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup_error.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup_failure.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup_failure_data.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup_item.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup_request.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup_response.rb +231 -9
- data/lib/advanced_billing/models/subscription_group_signup_success.rb +12 -2
- data/lib/advanced_billing/models/subscription_group_signup_success_data.rb +21 -5
- data/lib/advanced_billing/models/subscription_group_single_error.rb +73 -0
- data/lib/advanced_billing/models/subscription_group_subscription_error.rb +66 -2
- data/lib/advanced_billing/models/subscription_group_update_error.rb +12 -2
- data/lib/advanced_billing/models/subscription_groups_list_include.rb +20 -0
- data/lib/advanced_billing/models/subscription_included_coupon.rb +12 -2
- data/lib/advanced_billing/models/subscription_migration_preview.rb +12 -2
- data/lib/advanced_billing/models/subscription_migration_preview_options.rb +23 -5
- data/lib/advanced_billing/models/subscription_migration_preview_request.rb +12 -2
- data/lib/advanced_billing/models/subscription_migration_preview_response.rb +12 -2
- data/lib/advanced_billing/models/subscription_mrr.rb +12 -2
- data/lib/advanced_billing/models/subscription_mrr_breakout.rb +12 -2
- data/lib/advanced_billing/models/subscription_mrr_response.rb +12 -2
- data/lib/advanced_billing/models/subscription_note.rb +33 -6
- data/lib/advanced_billing/models/subscription_note_response.rb +12 -2
- data/lib/advanced_billing/models/subscription_preview.rb +12 -2
- data/lib/advanced_billing/models/subscription_preview_response.rb +12 -2
- data/lib/advanced_billing/models/subscription_product_change.rb +12 -2
- data/lib/advanced_billing/models/subscription_product_migration.rb +12 -2
- data/lib/advanced_billing/models/subscription_product_migration_request.rb +12 -2
- data/lib/advanced_billing/models/subscription_response.rb +12 -2
- data/lib/advanced_billing/models/subscription_state_change.rb +12 -2
- data/lib/advanced_billing/models/tax_configuration.rb +12 -2
- data/lib/advanced_billing/models/too_many_management_link_requests.rb +12 -2
- data/lib/advanced_billing/models/update_allocation_expiration_date.rb +12 -2
- data/lib/advanced_billing/models/update_component.rb +12 -2
- data/lib/advanced_billing/models/update_component_price_point.rb +12 -2
- data/lib/advanced_billing/models/update_component_price_point_request.rb +12 -2
- data/lib/advanced_billing/models/update_component_request.rb +12 -2
- data/lib/advanced_billing/models/update_coupon_currency.rb +12 -2
- data/lib/advanced_billing/models/update_currency_price.rb +12 -2
- data/lib/advanced_billing/models/update_currency_prices_request.rb +12 -2
- data/lib/advanced_billing/models/update_customer.rb +12 -2
- data/lib/advanced_billing/models/update_customer_request.rb +12 -2
- data/lib/advanced_billing/models/update_metadata.rb +12 -2
- data/lib/advanced_billing/models/update_metadata_request.rb +12 -2
- data/lib/advanced_billing/models/update_metafield.rb +12 -2
- data/lib/advanced_billing/models/update_metafields_request.rb +12 -2
- data/lib/advanced_billing/models/update_payment_profile.rb +12 -2
- data/lib/advanced_billing/models/update_payment_profile_request.rb +12 -2
- data/lib/advanced_billing/models/update_price.rb +12 -2
- data/lib/advanced_billing/models/update_product_price_point.rb +12 -2
- data/lib/advanced_billing/models/update_product_price_point_request.rb +12 -2
- data/lib/advanced_billing/models/update_reason_code.rb +12 -2
- data/lib/advanced_billing/models/update_reason_code_request.rb +12 -2
- data/lib/advanced_billing/models/update_segment.rb +12 -2
- data/lib/advanced_billing/models/update_segment_request.rb +12 -2
- data/lib/advanced_billing/models/update_subscription.rb +23 -5
- data/lib/advanced_billing/models/update_subscription_component.rb +12 -2
- data/lib/advanced_billing/models/update_subscription_group.rb +12 -2
- data/lib/advanced_billing/models/update_subscription_group_request.rb +12 -2
- data/lib/advanced_billing/models/update_subscription_note.rb +12 -2
- data/lib/advanced_billing/models/update_subscription_note_request.rb +12 -2
- data/lib/advanced_billing/models/update_subscription_request.rb +12 -2
- data/lib/advanced_billing/models/upsert_prepaid_configuration.rb +12 -2
- data/lib/advanced_billing/models/upsert_prepaid_configuration_request.rb +12 -2
- data/lib/advanced_billing/models/usage.rb +12 -2
- data/lib/advanced_billing/models/usage_response.rb +12 -2
- data/lib/advanced_billing/models/void_invoice.rb +12 -2
- data/lib/advanced_billing/models/void_invoice_event_data.rb +12 -2
- data/lib/advanced_billing/models/void_invoice_request.rb +12 -2
- data/lib/advanced_billing/models/void_remainder_event_data.rb +12 -2
- data/lib/advanced_billing/models/webhook.rb +53 -10
- data/lib/advanced_billing/models/webhook_response.rb +12 -2
- data/lib/advanced_billing/utilities/union_type_lookup.rb +20 -8
- data/lib/advanced_billing.rb +25 -12
- metadata +24 -11
- data/lib/advanced_billing/models/proforma_invoice_discount_breakout.rb +0 -62
- data/lib/advanced_billing/models/proforma_invoice_preview.rb +0 -484
- data/lib/advanced_billing/models/proforma_invoice_tax_breakout.rb +0 -61
@@ -3,6 +3,7 @@
|
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
+
require 'date'
|
6
7
|
module AdvancedBilling
|
7
8
|
# An optional object, will be returned if provided `include=subscription`
|
8
9
|
# query param.
|
@@ -151,7 +152,7 @@ module AdvancedBilling
|
|
151
152
|
# See [Subscription
|
152
153
|
# States](https://maxio-chargify.zendesk.com/hc/en-us/articles/5404222005773
|
153
154
|
# ) for more info about subscription states and state transitions.
|
154
|
-
# @return [
|
155
|
+
# @return [DateTime]
|
155
156
|
attr_accessor :updated_at
|
156
157
|
|
157
158
|
# A mapping from model property names to API property names.
|
@@ -176,9 +177,15 @@ module AdvancedBilling
|
|
176
177
|
end
|
177
178
|
|
178
179
|
def initialize(state = SKIP,
|
179
|
-
updated_at = SKIP
|
180
|
+
updated_at = SKIP,
|
181
|
+
additional_properties = {})
|
180
182
|
@state = state unless state == SKIP
|
181
183
|
@updated_at = updated_at unless updated_at == SKIP
|
184
|
+
|
185
|
+
# Add additional model properties to the instance.
|
186
|
+
additional_properties.each do |_name, _value|
|
187
|
+
instance_variable_set("@#{_name}", _value)
|
188
|
+
end
|
182
189
|
end
|
183
190
|
|
184
191
|
# Creates an instance of the object from a hash.
|
@@ -187,11 +194,23 @@ module AdvancedBilling
|
|
187
194
|
|
188
195
|
# Extract variables from the hash.
|
189
196
|
state = hash.key?('state') ? hash['state'] : SKIP
|
190
|
-
updated_at = hash.key?('updated_at')
|
197
|
+
updated_at = if hash.key?('updated_at')
|
198
|
+
(DateTimeHelper.from_rfc3339(hash['updated_at']) if hash['updated_at'])
|
199
|
+
else
|
200
|
+
SKIP
|
201
|
+
end
|
202
|
+
|
203
|
+
# Clean out expected properties from Hash.
|
204
|
+
names.each_value { |k| hash.delete(k) }
|
191
205
|
|
192
206
|
# Create object from extracted values.
|
193
207
|
SubscriptionComponentSubscription.new(state,
|
194
|
-
updated_at
|
208
|
+
updated_at,
|
209
|
+
hash)
|
210
|
+
end
|
211
|
+
|
212
|
+
def to_custom_updated_at
|
213
|
+
DateTimeHelper.to_rfc3339(updated_at)
|
195
214
|
end
|
196
215
|
end
|
197
216
|
end
|
@@ -114,7 +114,8 @@ module AdvancedBilling
|
|
114
114
|
initial_charge_after_trial = SKIP,
|
115
115
|
expiration_interval = SKIP,
|
116
116
|
expiration_interval_unit = SKIP,
|
117
|
-
tax_included = SKIP
|
117
|
+
tax_included = SKIP,
|
118
|
+
additional_properties = {})
|
118
119
|
@name = name unless name == SKIP
|
119
120
|
@handle = handle unless handle == SKIP
|
120
121
|
@price_in_cents = price_in_cents
|
@@ -131,6 +132,11 @@ module AdvancedBilling
|
|
131
132
|
@expiration_interval = expiration_interval unless expiration_interval == SKIP
|
132
133
|
@expiration_interval_unit = expiration_interval_unit unless expiration_interval_unit == SKIP
|
133
134
|
@tax_included = tax_included unless tax_included == SKIP
|
135
|
+
|
136
|
+
# Add additional model properties to the instance.
|
137
|
+
additional_properties.each do |_name, _value|
|
138
|
+
instance_variable_set("@#{_name}", _value)
|
139
|
+
end
|
134
140
|
end
|
135
141
|
|
136
142
|
# Creates an instance of the object from a hash.
|
@@ -167,6 +173,9 @@ module AdvancedBilling
|
|
167
173
|
hash.key?('expiration_interval_unit') ? hash['expiration_interval_unit'] : SKIP
|
168
174
|
tax_included = hash.key?('tax_included') ? hash['tax_included'] : SKIP
|
169
175
|
|
176
|
+
# Clean out expected properties from Hash.
|
177
|
+
names.each_value { |k| hash.delete(k) }
|
178
|
+
|
170
179
|
# Create object from extracted values.
|
171
180
|
SubscriptionCustomPrice.new(price_in_cents,
|
172
181
|
interval,
|
@@ -180,7 +189,8 @@ module AdvancedBilling
|
|
180
189
|
initial_charge_after_trial,
|
181
190
|
expiration_interval,
|
182
191
|
expiration_interval_unit,
|
183
|
-
tax_included
|
192
|
+
tax_included,
|
193
|
+
hash)
|
184
194
|
end
|
185
195
|
|
186
196
|
# Validates an instance of the object from a given value.
|
@@ -3,6 +3,7 @@
|
|
3
3
|
# This file was automatically generated by APIMATIC v2.0
|
4
4
|
# ( https://apimatic.io ).
|
5
5
|
|
6
|
+
require 'date'
|
6
7
|
module AdvancedBilling
|
7
8
|
# SubscriptionGroup Model.
|
8
9
|
class SubscriptionGroup < BaseModel
|
@@ -17,16 +18,25 @@ module AdvancedBilling
|
|
17
18
|
# @return [SubscriptionGroupPaymentProfile]
|
18
19
|
attr_accessor :payment_profile
|
19
20
|
|
20
|
-
#
|
21
|
-
#
|
21
|
+
# The type of payment collection to be used in the subscription. For legacy
|
22
|
+
# Statements Architecture valid options are - `invoice`, `automatic`. For
|
23
|
+
# current Relationship Invoicing Architecture valid options are -
|
24
|
+
# `remittance`, `automatic`, `prepaid`.
|
25
|
+
# @return [CollectionMethod]
|
22
26
|
attr_accessor :payment_collection_method
|
23
27
|
|
24
|
-
#
|
28
|
+
# The type of payment collection to be used in the subscription. For legacy
|
29
|
+
# Statements Architecture valid options are - `invoice`, `automatic`. For
|
30
|
+
# current Relationship Invoicing Architecture valid options are -
|
31
|
+
# `remittance`, `automatic`, `prepaid`.
|
25
32
|
# @return [Array[Integer]]
|
26
33
|
attr_accessor :subscription_ids
|
27
34
|
|
28
|
-
#
|
29
|
-
#
|
35
|
+
# The type of payment collection to be used in the subscription. For legacy
|
36
|
+
# Statements Architecture valid options are - `invoice`, `automatic`. For
|
37
|
+
# current Relationship Invoicing Architecture valid options are -
|
38
|
+
# `remittance`, `automatic`, `prepaid`.
|
39
|
+
# @return [DateTime]
|
30
40
|
attr_accessor :created_at
|
31
41
|
|
32
42
|
# A mapping from model property names to API property names.
|
@@ -58,9 +68,10 @@ module AdvancedBilling
|
|
58
68
|
|
59
69
|
def initialize(customer_id = SKIP,
|
60
70
|
payment_profile = SKIP,
|
61
|
-
payment_collection_method =
|
71
|
+
payment_collection_method = CollectionMethod::AUTOMATIC,
|
62
72
|
subscription_ids = SKIP,
|
63
|
-
created_at = SKIP
|
73
|
+
created_at = SKIP,
|
74
|
+
additional_properties = {})
|
64
75
|
@customer_id = customer_id unless customer_id == SKIP
|
65
76
|
@payment_profile = payment_profile unless payment_profile == SKIP
|
66
77
|
unless payment_collection_method == SKIP
|
@@ -69,6 +80,11 @@ module AdvancedBilling
|
|
69
80
|
end
|
70
81
|
@subscription_ids = subscription_ids unless subscription_ids == SKIP
|
71
82
|
@created_at = created_at unless created_at == SKIP
|
83
|
+
|
84
|
+
# Add additional model properties to the instance.
|
85
|
+
additional_properties.each do |_name, _value|
|
86
|
+
instance_variable_set("@#{_name}", _value)
|
87
|
+
end
|
72
88
|
end
|
73
89
|
|
74
90
|
# Creates an instance of the object from a hash.
|
@@ -80,17 +96,29 @@ module AdvancedBilling
|
|
80
96
|
payment_profile = SubscriptionGroupPaymentProfile.from_hash(hash['payment_profile']) if
|
81
97
|
hash['payment_profile']
|
82
98
|
payment_collection_method =
|
83
|
-
hash
|
99
|
+
hash['payment_collection_method'] ||= CollectionMethod::AUTOMATIC
|
84
100
|
subscription_ids =
|
85
101
|
hash.key?('subscription_ids') ? hash['subscription_ids'] : SKIP
|
86
|
-
created_at = hash.key?('created_at')
|
102
|
+
created_at = if hash.key?('created_at')
|
103
|
+
(DateTimeHelper.from_rfc3339(hash['created_at']) if hash['created_at'])
|
104
|
+
else
|
105
|
+
SKIP
|
106
|
+
end
|
107
|
+
|
108
|
+
# Clean out expected properties from Hash.
|
109
|
+
names.each_value { |k| hash.delete(k) }
|
87
110
|
|
88
111
|
# Create object from extracted values.
|
89
112
|
SubscriptionGroup.new(customer_id,
|
90
113
|
payment_profile,
|
91
114
|
payment_collection_method,
|
92
115
|
subscription_ids,
|
93
|
-
created_at
|
116
|
+
created_at,
|
117
|
+
hash)
|
118
|
+
end
|
119
|
+
|
120
|
+
def to_custom_created_at
|
121
|
+
DateTimeHelper.to_rfc3339(created_at)
|
94
122
|
end
|
95
123
|
end
|
96
124
|
end
|
@@ -53,11 +53,17 @@ module AdvancedBilling
|
|
53
53
|
def initialize(prepayments = SKIP,
|
54
54
|
service_credits = SKIP,
|
55
55
|
open_invoices = SKIP,
|
56
|
-
pending_discounts = SKIP
|
56
|
+
pending_discounts = SKIP,
|
57
|
+
additional_properties = {})
|
57
58
|
@prepayments = prepayments unless prepayments == SKIP
|
58
59
|
@service_credits = service_credits unless service_credits == SKIP
|
59
60
|
@open_invoices = open_invoices unless open_invoices == SKIP
|
60
61
|
@pending_discounts = pending_discounts unless pending_discounts == SKIP
|
62
|
+
|
63
|
+
# Add additional model properties to the instance.
|
64
|
+
additional_properties.each do |_name, _value|
|
65
|
+
instance_variable_set("@#{_name}", _value)
|
66
|
+
end
|
61
67
|
end
|
62
68
|
|
63
69
|
# Creates an instance of the object from a hash.
|
@@ -72,11 +78,15 @@ module AdvancedBilling
|
|
72
78
|
pending_discounts = AccountBalance.from_hash(hash['pending_discounts']) if
|
73
79
|
hash['pending_discounts']
|
74
80
|
|
81
|
+
# Clean out expected properties from Hash.
|
82
|
+
names.each_value { |k| hash.delete(k) }
|
83
|
+
|
75
84
|
# Create object from extracted values.
|
76
85
|
SubscriptionGroupBalances.new(prepayments,
|
77
86
|
service_credits,
|
78
87
|
open_invoices,
|
79
|
-
pending_discounts
|
88
|
+
pending_discounts,
|
89
|
+
hash)
|
80
90
|
end
|
81
91
|
end
|
82
92
|
end
|
@@ -144,7 +144,8 @@ module AdvancedBilling
|
|
144
144
|
billing_country = SKIP,
|
145
145
|
chargify_token = SKIP,
|
146
146
|
current_vault = SKIP,
|
147
|
-
gateway_handle = SKIP
|
147
|
+
gateway_handle = SKIP,
|
148
|
+
additional_properties = {})
|
148
149
|
@bank_name = bank_name unless bank_name == SKIP
|
149
150
|
@bank_account_number = bank_account_number unless bank_account_number == SKIP
|
150
151
|
@bank_routing_number = bank_routing_number unless bank_routing_number == SKIP
|
@@ -161,6 +162,11 @@ module AdvancedBilling
|
|
161
162
|
@chargify_token = chargify_token unless chargify_token == SKIP
|
162
163
|
@current_vault = current_vault unless current_vault == SKIP
|
163
164
|
@gateway_handle = gateway_handle unless gateway_handle == SKIP
|
165
|
+
|
166
|
+
# Add additional model properties to the instance.
|
167
|
+
additional_properties.each do |_name, _value|
|
168
|
+
instance_variable_set("@#{_name}", _value)
|
169
|
+
end
|
164
170
|
end
|
165
171
|
|
166
172
|
# Creates an instance of the object from a hash.
|
@@ -194,6 +200,9 @@ module AdvancedBilling
|
|
194
200
|
gateway_handle =
|
195
201
|
hash.key?('gateway_handle') ? hash['gateway_handle'] : SKIP
|
196
202
|
|
203
|
+
# Clean out expected properties from Hash.
|
204
|
+
names.each_value { |k| hash.delete(k) }
|
205
|
+
|
197
206
|
# Create object from extracted values.
|
198
207
|
SubscriptionGroupBankAccount.new(bank_name,
|
199
208
|
bank_account_number,
|
@@ -210,7 +219,8 @@ module AdvancedBilling
|
|
210
219
|
billing_country,
|
211
220
|
chargify_token,
|
212
221
|
current_vault,
|
213
|
-
gateway_handle
|
222
|
+
gateway_handle,
|
223
|
+
hash)
|
214
224
|
end
|
215
225
|
end
|
216
226
|
end
|
@@ -53,10 +53,16 @@ module AdvancedBilling
|
|
53
53
|
|
54
54
|
def initialize(pricing_scheme = SKIP,
|
55
55
|
prices = SKIP,
|
56
|
-
overage_pricing = SKIP
|
56
|
+
overage_pricing = SKIP,
|
57
|
+
additional_properties = {})
|
57
58
|
@pricing_scheme = pricing_scheme unless pricing_scheme == SKIP
|
58
59
|
@prices = prices unless prices == SKIP
|
59
60
|
@overage_pricing = overage_pricing unless overage_pricing == SKIP
|
61
|
+
|
62
|
+
# Add additional model properties to the instance.
|
63
|
+
additional_properties.each do |_name, _value|
|
64
|
+
instance_variable_set("@#{_name}", _value)
|
65
|
+
end
|
60
66
|
end
|
61
67
|
|
62
68
|
# Creates an instance of the object from a hash.
|
@@ -87,10 +93,14 @@ module AdvancedBilling
|
|
87
93
|
|
88
94
|
overage_pricing = SKIP unless hash.key?('overage_pricing')
|
89
95
|
|
96
|
+
# Clean out expected properties from Hash.
|
97
|
+
names.each_value { |k| hash.delete(k) }
|
98
|
+
|
90
99
|
# Create object from extracted values.
|
91
100
|
SubscriptionGroupComponentCustomPrice.new(pricing_scheme,
|
92
101
|
prices,
|
93
|
-
overage_pricing
|
102
|
+
overage_pricing,
|
103
|
+
hash)
|
94
104
|
end
|
95
105
|
end
|
96
106
|
end
|
@@ -176,7 +176,8 @@ module AdvancedBilling
|
|
176
176
|
card_type = SKIP,
|
177
177
|
customer_vault_token = SKIP,
|
178
178
|
cvv = SKIP,
|
179
|
-
payment_type = SKIP
|
179
|
+
payment_type = SKIP,
|
180
|
+
additional_properties = {})
|
180
181
|
@full_number = full_number unless full_number == SKIP
|
181
182
|
@expiration_month = expiration_month unless expiration_month == SKIP
|
182
183
|
@expiration_year = expiration_year unless expiration_year == SKIP
|
@@ -197,6 +198,11 @@ module AdvancedBilling
|
|
197
198
|
@customer_vault_token = customer_vault_token unless customer_vault_token == SKIP
|
198
199
|
@cvv = cvv unless cvv == SKIP
|
199
200
|
@payment_type = payment_type unless payment_type == SKIP
|
201
|
+
|
202
|
+
# Add additional model properties to the instance.
|
203
|
+
additional_properties.each do |_name, _value|
|
204
|
+
instance_variable_set("@#{_name}", _value)
|
205
|
+
end
|
200
206
|
end
|
201
207
|
|
202
208
|
# Creates an instance of the object from a hash.
|
@@ -237,6 +243,9 @@ module AdvancedBilling
|
|
237
243
|
cvv = hash.key?('cvv') ? hash['cvv'] : SKIP
|
238
244
|
payment_type = hash.key?('payment_type') ? hash['payment_type'] : SKIP
|
239
245
|
|
246
|
+
# Clean out expected properties from Hash.
|
247
|
+
names.each_value { |k| hash.delete(k) }
|
248
|
+
|
240
249
|
# Create object from extracted values.
|
241
250
|
SubscriptionGroupCreditCard.new(full_number,
|
242
251
|
expiration_month,
|
@@ -257,7 +266,8 @@ module AdvancedBilling
|
|
257
266
|
card_type,
|
258
267
|
customer_vault_token,
|
259
268
|
cvv,
|
260
|
-
payment_type
|
269
|
+
payment_type,
|
270
|
+
hash)
|
261
271
|
end
|
262
272
|
|
263
273
|
# Validates an instance of the object from a given value.
|
@@ -60,12 +60,18 @@ module AdvancedBilling
|
|
60
60
|
last_name = SKIP,
|
61
61
|
organization = SKIP,
|
62
62
|
email = SKIP,
|
63
|
-
reference = SKIP
|
63
|
+
reference = SKIP,
|
64
|
+
additional_properties = {})
|
64
65
|
@first_name = first_name unless first_name == SKIP
|
65
66
|
@last_name = last_name unless last_name == SKIP
|
66
67
|
@organization = organization unless organization == SKIP
|
67
68
|
@email = email unless email == SKIP
|
68
69
|
@reference = reference unless reference == SKIP
|
70
|
+
|
71
|
+
# Add additional model properties to the instance.
|
72
|
+
additional_properties.each do |_name, _value|
|
73
|
+
instance_variable_set("@#{_name}", _value)
|
74
|
+
end
|
69
75
|
end
|
70
76
|
|
71
77
|
# Creates an instance of the object from a hash.
|
@@ -79,12 +85,16 @@ module AdvancedBilling
|
|
79
85
|
email = hash.key?('email') ? hash['email'] : SKIP
|
80
86
|
reference = hash.key?('reference') ? hash['reference'] : SKIP
|
81
87
|
|
88
|
+
# Clean out expected properties from Hash.
|
89
|
+
names.each_value { |k| hash.delete(k) }
|
90
|
+
|
82
91
|
# Create object from extracted values.
|
83
92
|
SubscriptionGroupCustomer.new(first_name,
|
84
93
|
last_name,
|
85
94
|
organization,
|
86
95
|
email,
|
87
|
-
reference
|
96
|
+
reference,
|
97
|
+
hash)
|
88
98
|
end
|
89
99
|
end
|
90
100
|
end
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# advanced_billing
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module AdvancedBilling
|
7
|
+
# Subscription Group Include.
|
8
|
+
class SubscriptionGroupInclude
|
9
|
+
SUBSCRIPTION_GROUP_INCLUDE = [
|
10
|
+
# TODO: Write general description for CURRENT_BILLING_AMOUNT_IN_CENTS
|
11
|
+
CURRENT_BILLING_AMOUNT_IN_CENTS = 'current_billing_amount_in_cents'.freeze
|
12
|
+
].freeze
|
13
|
+
|
14
|
+
def self.validate(value)
|
15
|
+
return false if value.nil?
|
16
|
+
|
17
|
+
SUBSCRIPTION_GROUP_INCLUDE.include?(value)
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
@@ -99,7 +99,8 @@ module AdvancedBilling
|
|
99
99
|
currency = SKIP,
|
100
100
|
coupon_code = SKIP,
|
101
101
|
total_revenue_in_cents = SKIP,
|
102
|
-
balance_in_cents = SKIP
|
102
|
+
balance_in_cents = SKIP,
|
103
|
+
additional_properties = {})
|
103
104
|
@id = id unless id == SKIP
|
104
105
|
@reference = reference unless reference == SKIP
|
105
106
|
@product_id = product_id unless product_id == SKIP
|
@@ -113,6 +114,11 @@ module AdvancedBilling
|
|
113
114
|
@coupon_code = coupon_code unless coupon_code == SKIP
|
114
115
|
@total_revenue_in_cents = total_revenue_in_cents unless total_revenue_in_cents == SKIP
|
115
116
|
@balance_in_cents = balance_in_cents unless balance_in_cents == SKIP
|
117
|
+
|
118
|
+
# Add additional model properties to the instance.
|
119
|
+
additional_properties.each do |_name, _value|
|
120
|
+
instance_variable_set("@#{_name}", _value)
|
121
|
+
end
|
116
122
|
end
|
117
123
|
|
118
124
|
# Creates an instance of the object from a hash.
|
@@ -136,6 +142,9 @@ module AdvancedBilling
|
|
136
142
|
balance_in_cents =
|
137
143
|
hash.key?('balance_in_cents') ? hash['balance_in_cents'] : SKIP
|
138
144
|
|
145
|
+
# Clean out expected properties from Hash.
|
146
|
+
names.each_value { |k| hash.delete(k) }
|
147
|
+
|
139
148
|
# Create object from extracted values.
|
140
149
|
SubscriptionGroupItem.new(id,
|
141
150
|
reference,
|
@@ -146,7 +155,8 @@ module AdvancedBilling
|
|
146
155
|
currency,
|
147
156
|
coupon_code,
|
148
157
|
total_revenue_in_cents,
|
149
|
-
balance_in_cents
|
158
|
+
balance_in_cents,
|
159
|
+
hash)
|
150
160
|
end
|
151
161
|
end
|
152
162
|
end
|
@@ -46,10 +46,16 @@ module AdvancedBilling
|
|
46
46
|
|
47
47
|
def initialize(id = SKIP,
|
48
48
|
type = SKIP,
|
49
|
-
message = SKIP
|
49
|
+
message = SKIP,
|
50
|
+
additional_properties = {})
|
50
51
|
@id = id unless id == SKIP
|
51
52
|
@type = type unless type == SKIP
|
52
53
|
@message = message unless message == SKIP
|
54
|
+
|
55
|
+
# Add additional model properties to the instance.
|
56
|
+
additional_properties.each do |_name, _value|
|
57
|
+
instance_variable_set("@#{_name}", _value)
|
58
|
+
end
|
53
59
|
end
|
54
60
|
|
55
61
|
# Creates an instance of the object from a hash.
|
@@ -61,10 +67,14 @@ module AdvancedBilling
|
|
61
67
|
type = hash.key?('type') ? hash['type'] : SKIP
|
62
68
|
message = hash.key?('message') ? hash['message'] : SKIP
|
63
69
|
|
70
|
+
# Clean out expected properties from Hash.
|
71
|
+
names.each_value { |k| hash.delete(k) }
|
72
|
+
|
64
73
|
# Create object from extracted values.
|
65
74
|
SubscriptionGroupMemberError.new(id,
|
66
75
|
type,
|
67
|
-
message
|
76
|
+
message,
|
77
|
+
hash)
|
68
78
|
end
|
69
79
|
end
|
70
80
|
end
|
@@ -0,0 +1,72 @@
|
|
1
|
+
# advanced_billing
|
2
|
+
#
|
3
|
+
# This file was automatically generated by APIMATIC v2.0
|
4
|
+
# ( https://apimatic.io ).
|
5
|
+
|
6
|
+
module AdvancedBilling
|
7
|
+
# SubscriptionGroupMembersArrayError Model.
|
8
|
+
class SubscriptionGroupMembersArrayError < BaseModel
|
9
|
+
SKIP = Object.new
|
10
|
+
private_constant :SKIP
|
11
|
+
|
12
|
+
# TODO: Write general description for this method
|
13
|
+
# @return [Array[String]]
|
14
|
+
attr_accessor :members
|
15
|
+
|
16
|
+
# A mapping from model property names to API property names.
|
17
|
+
def self.names
|
18
|
+
@_hash = {} if @_hash.nil?
|
19
|
+
@_hash['members'] = 'members'
|
20
|
+
@_hash
|
21
|
+
end
|
22
|
+
|
23
|
+
# An array for optional fields
|
24
|
+
def self.optionals
|
25
|
+
[]
|
26
|
+
end
|
27
|
+
|
28
|
+
# An array for nullable fields
|
29
|
+
def self.nullables
|
30
|
+
[]
|
31
|
+
end
|
32
|
+
|
33
|
+
def initialize(members = nil,
|
34
|
+
additional_properties = {})
|
35
|
+
@members = members
|
36
|
+
|
37
|
+
# Add additional model properties to the instance.
|
38
|
+
additional_properties.each do |_name, _value|
|
39
|
+
instance_variable_set("@#{_name}", _value)
|
40
|
+
end
|
41
|
+
end
|
42
|
+
|
43
|
+
# Creates an instance of the object from a hash.
|
44
|
+
def self.from_hash(hash)
|
45
|
+
return nil unless hash
|
46
|
+
|
47
|
+
# Extract variables from the hash.
|
48
|
+
members = hash.key?('members') ? hash['members'] : nil
|
49
|
+
|
50
|
+
# Clean out expected properties from Hash.
|
51
|
+
names.each_value { |k| hash.delete(k) }
|
52
|
+
|
53
|
+
# Create object from extracted values.
|
54
|
+
SubscriptionGroupMembersArrayError.new(members,
|
55
|
+
hash)
|
56
|
+
end
|
57
|
+
|
58
|
+
# Validates an instance of the object from a given value.
|
59
|
+
# @param [SubscriptionGroupMembersArrayError | Hash] The value against the validation is performed.
|
60
|
+
def self.validate(value)
|
61
|
+
if value.instance_of? self
|
62
|
+
return APIHelper.valid_type?(value.members,
|
63
|
+
->(val) { val.instance_of? String })
|
64
|
+
end
|
65
|
+
|
66
|
+
return false unless value.instance_of? Hash
|
67
|
+
|
68
|
+
APIHelper.valid_type?(value['members'],
|
69
|
+
->(val) { val.instance_of? String })
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
@@ -53,11 +53,17 @@ module AdvancedBilling
|
|
53
53
|
def initialize(id = SKIP,
|
54
54
|
first_name = SKIP,
|
55
55
|
last_name = SKIP,
|
56
|
-
masked_card_number = SKIP
|
56
|
+
masked_card_number = SKIP,
|
57
|
+
additional_properties = {})
|
57
58
|
@id = id unless id == SKIP
|
58
59
|
@first_name = first_name unless first_name == SKIP
|
59
60
|
@last_name = last_name unless last_name == SKIP
|
60
61
|
@masked_card_number = masked_card_number unless masked_card_number == SKIP
|
62
|
+
|
63
|
+
# Add additional model properties to the instance.
|
64
|
+
additional_properties.each do |_name, _value|
|
65
|
+
instance_variable_set("@#{_name}", _value)
|
66
|
+
end
|
61
67
|
end
|
62
68
|
|
63
69
|
# Creates an instance of the object from a hash.
|
@@ -71,11 +77,15 @@ module AdvancedBilling
|
|
71
77
|
masked_card_number =
|
72
78
|
hash.key?('masked_card_number') ? hash['masked_card_number'] : SKIP
|
73
79
|
|
80
|
+
# Clean out expected properties from Hash.
|
81
|
+
names.each_value { |k| hash.delete(k) }
|
82
|
+
|
74
83
|
# Create object from extracted values.
|
75
84
|
SubscriptionGroupPaymentProfile.new(id,
|
76
85
|
first_name,
|
77
86
|
last_name,
|
78
|
-
masked_card_number
|
87
|
+
masked_card_number,
|
88
|
+
hash)
|
79
89
|
end
|
80
90
|
end
|
81
91
|
end
|
@@ -48,11 +48,17 @@ module AdvancedBilling
|
|
48
48
|
def initialize(amount = nil,
|
49
49
|
details = nil,
|
50
50
|
memo = nil,
|
51
|
-
method = nil
|
51
|
+
method = nil,
|
52
|
+
additional_properties = {})
|
52
53
|
@amount = amount
|
53
54
|
@details = details
|
54
55
|
@memo = memo
|
55
56
|
@method = method
|
57
|
+
|
58
|
+
# Add additional model properties to the instance.
|
59
|
+
additional_properties.each do |_name, _value|
|
60
|
+
instance_variable_set("@#{_name}", _value)
|
61
|
+
end
|
56
62
|
end
|
57
63
|
|
58
64
|
# Creates an instance of the object from a hash.
|
@@ -65,11 +71,15 @@ module AdvancedBilling
|
|
65
71
|
memo = hash.key?('memo') ? hash['memo'] : nil
|
66
72
|
method = hash.key?('method') ? hash['method'] : nil
|
67
73
|
|
74
|
+
# Clean out expected properties from Hash.
|
75
|
+
names.each_value { |k| hash.delete(k) }
|
76
|
+
|
68
77
|
# Create object from extracted values.
|
69
78
|
SubscriptionGroupPrepayment.new(amount,
|
70
79
|
details,
|
71
80
|
memo,
|
72
|
-
method
|
81
|
+
method,
|
82
|
+
hash)
|
73
83
|
end
|
74
84
|
end
|
75
85
|
end
|
@@ -30,8 +30,14 @@ module AdvancedBilling
|
|
30
30
|
[]
|
31
31
|
end
|
32
32
|
|
33
|
-
def initialize(prepayment = nil
|
33
|
+
def initialize(prepayment = nil,
|
34
|
+
additional_properties = {})
|
34
35
|
@prepayment = prepayment
|
36
|
+
|
37
|
+
# Add additional model properties to the instance.
|
38
|
+
additional_properties.each do |_name, _value|
|
39
|
+
instance_variable_set("@#{_name}", _value)
|
40
|
+
end
|
35
41
|
end
|
36
42
|
|
37
43
|
# Creates an instance of the object from a hash.
|
@@ -41,8 +47,12 @@ module AdvancedBilling
|
|
41
47
|
# Extract variables from the hash.
|
42
48
|
prepayment = SubscriptionGroupPrepayment.from_hash(hash['prepayment']) if hash['prepayment']
|
43
49
|
|
50
|
+
# Clean out expected properties from Hash.
|
51
|
+
names.each_value { |k| hash.delete(k) }
|
52
|
+
|
44
53
|
# Create object from extracted values.
|
45
|
-
SubscriptionGroupPrepaymentRequest.new(prepayment
|
54
|
+
SubscriptionGroupPrepaymentRequest.new(prepayment,
|
55
|
+
hash)
|
46
56
|
end
|
47
57
|
end
|
48
58
|
end
|