orb-billing 0.2.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +67 -0
- data/README.md +63 -53
- data/lib/orb/client.rb +4 -4
- data/lib/orb/errors.rb +9 -9
- data/lib/orb/file_part.rb +55 -0
- data/lib/orb/internal/page.rb +7 -11
- data/lib/orb/internal/transport/base_client.rb +10 -10
- data/lib/orb/internal/transport/pooled_net_requester.rb +2 -2
- data/lib/orb/internal/type/array_of.rb +11 -0
- data/lib/orb/internal/type/base_model.rb +33 -23
- data/lib/orb/internal/type/base_page.rb +9 -1
- data/lib/orb/internal/type/boolean.rb +14 -11
- data/lib/orb/internal/type/converter.rb +4 -1
- data/lib/orb/internal/type/enum.rb +19 -16
- data/lib/orb/internal/type/{io_like.rb → file_input.rb} +33 -15
- data/lib/orb/internal/type/hash_of.rb +11 -0
- data/lib/orb/internal/type/request_parameters.rb +3 -10
- data/lib/orb/internal/type/union.rb +10 -1
- data/lib/orb/internal/type/unknown.rb +14 -11
- data/lib/orb/internal/util.rb +88 -64
- data/lib/orb/internal.rb +0 -1
- data/lib/orb/models/alert.rb +68 -71
- data/lib/orb/models/alert_create_for_customer_params.rb +20 -25
- data/lib/orb/models/alert_create_for_external_customer_params.rb +20 -25
- data/lib/orb/models/alert_create_for_subscription_params.rb +20 -25
- data/lib/orb/models/alert_disable_params.rb +5 -9
- data/lib/orb/models/alert_enable_params.rb +5 -9
- data/lib/orb/models/alert_list_params.rb +26 -36
- data/lib/orb/models/alert_retrieve_params.rb +3 -8
- data/lib/orb/models/alert_update_params.rb +14 -18
- data/lib/orb/models/amount_discount.rb +14 -14
- data/lib/orb/models/billable_metric.rb +23 -20
- data/lib/orb/models/billing_cycle_relative_date.rb +2 -5
- data/lib/orb/models/coupon.rb +28 -21
- data/lib/orb/models/coupon_archive_params.rb +3 -8
- data/lib/orb/models/coupon_create_params.rb +29 -34
- data/lib/orb/models/coupon_fetch_params.rb +3 -8
- data/lib/orb/models/coupon_list_params.rb +17 -17
- data/lib/orb/models/coupons/subscription_list_params.rb +12 -15
- data/lib/orb/models/credit_note.rb +100 -166
- data/lib/orb/models/credit_note_create_params.rb +15 -23
- data/lib/orb/models/credit_note_fetch_params.rb +3 -8
- data/lib/orb/models/credit_note_list_params.rb +20 -30
- data/lib/orb/models/customer.rb +224 -271
- data/lib/orb/models/customer_create_params.rb +216 -257
- data/lib/orb/models/customer_delete_params.rb +3 -8
- data/lib/orb/models/customer_fetch_by_external_id_params.rb +3 -8
- data/lib/orb/models/customer_fetch_params.rb +3 -8
- data/lib/orb/models/customer_list_params.rb +20 -30
- data/lib/orb/models/customer_sync_payment_methods_from_gateway_by_external_customer_id_params.rb +3 -8
- data/lib/orb/models/customer_sync_payment_methods_from_gateway_params.rb +3 -8
- data/lib/orb/models/customer_update_by_external_id_params.rb +212 -257
- data/lib/orb/models/customer_update_params.rb +212 -255
- data/lib/orb/models/customers/balance_transaction_create_params.rb +11 -16
- data/lib/orb/models/customers/balance_transaction_create_response.rb +33 -51
- data/lib/orb/models/customers/balance_transaction_list_params.rb +20 -30
- data/lib/orb/models/customers/balance_transaction_list_response.rb +33 -51
- data/lib/orb/models/customers/cost_list_by_external_id_params.rb +17 -17
- data/lib/orb/models/customers/cost_list_by_external_id_response.rb +23 -27
- data/lib/orb/models/customers/cost_list_params.rb +17 -17
- data/lib/orb/models/customers/cost_list_response.rb +23 -27
- data/lib/orb/models/customers/credit_list_by_external_id_params.rb +18 -22
- data/lib/orb/models/customers/credit_list_by_external_id_response.rb +10 -17
- data/lib/orb/models/customers/credit_list_params.rb +18 -22
- data/lib/orb/models/customers/credit_list_response.rb +10 -17
- data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb +64 -66
- data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rb +384 -491
- data/lib/orb/models/customers/credits/ledger_create_entry_params.rb +63 -66
- data/lib/orb/models/customers/credits/ledger_create_entry_response.rb +384 -498
- data/lib/orb/models/customers/credits/ledger_list_by_external_id_params.rb +33 -48
- data/lib/orb/models/customers/credits/ledger_list_by_external_id_response.rb +384 -494
- data/lib/orb/models/customers/credits/ledger_list_params.rb +32 -48
- data/lib/orb/models/customers/credits/ledger_list_response.rb +383 -501
- data/lib/orb/models/customers/credits/top_up_create_by_external_id_params.rb +47 -50
- data/lib/orb/models/customers/credits/top_up_create_by_external_id_response.rb +43 -46
- data/lib/orb/models/customers/credits/top_up_create_params.rb +46 -50
- data/lib/orb/models/customers/credits/top_up_create_response.rb +42 -46
- data/lib/orb/models/customers/credits/top_up_delete_by_external_id_params.rb +4 -9
- data/lib/orb/models/customers/credits/top_up_delete_params.rb +4 -9
- data/lib/orb/models/customers/credits/top_up_list_by_external_id_params.rb +12 -15
- data/lib/orb/models/customers/credits/top_up_list_by_external_id_response.rb +43 -46
- data/lib/orb/models/customers/credits/top_up_list_params.rb +12 -15
- data/lib/orb/models/customers/credits/top_up_list_response.rb +42 -46
- data/lib/orb/models/dimensional_price_group.rb +21 -15
- data/lib/orb/models/dimensional_price_group_create_params.rb +17 -23
- data/lib/orb/models/dimensional_price_group_list_params.rb +12 -15
- data/lib/orb/models/dimensional_price_group_retrieve_params.rb +3 -8
- data/lib/orb/models/dimensional_price_groups/external_dimensional_price_group_id_retrieve_params.rb +3 -8
- data/lib/orb/models/dimensional_price_groups.rb +3 -7
- data/lib/orb/models/discount.rb +2 -3
- data/lib/orb/models/evaluate_price_group.rb +8 -11
- data/lib/orb/models/event_deprecate_params.rb +3 -8
- data/lib/orb/models/event_deprecate_response.rb +2 -6
- data/lib/orb/models/event_ingest_params.rb +33 -27
- data/lib/orb/models/event_ingest_response.rb +23 -24
- data/lib/orb/models/event_search_params.rb +15 -11
- data/lib/orb/models/event_search_response.rb +27 -22
- data/lib/orb/models/event_update_params.rb +19 -13
- data/lib/orb/models/event_update_response.rb +2 -6
- data/lib/orb/models/events/backfill_close_params.rb +3 -8
- data/lib/orb/models/events/backfill_close_response.rb +34 -39
- data/lib/orb/models/events/backfill_create_params.rb +28 -32
- data/lib/orb/models/events/backfill_create_response.rb +34 -39
- data/lib/orb/models/events/backfill_fetch_params.rb +3 -8
- data/lib/orb/models/events/backfill_fetch_response.rb +34 -39
- data/lib/orb/models/events/backfill_list_params.rb +12 -15
- data/lib/orb/models/events/backfill_list_response.rb +34 -39
- data/lib/orb/models/events/backfill_revert_params.rb +3 -8
- data/lib/orb/models/events/backfill_revert_response.rb +34 -39
- data/lib/orb/models/events/event_volumes.rb +11 -17
- data/lib/orb/models/events/volume_list_params.rb +19 -22
- data/lib/orb/models/invoice.rb +619 -681
- data/lib/orb/models/invoice_create_params.rb +52 -61
- data/lib/orb/models/invoice_fetch_params.rb +3 -8
- data/lib/orb/models/invoice_fetch_upcoming_params.rb +4 -9
- data/lib/orb/models/invoice_fetch_upcoming_response.rb +618 -669
- data/lib/orb/models/invoice_issue_params.rb +10 -14
- data/lib/orb/models/invoice_level_discount.rb +2 -3
- data/lib/orb/models/invoice_line_item_create_params.rb +19 -14
- data/lib/orb/models/invoice_line_item_create_response.rb +281 -306
- data/lib/orb/models/invoice_list_params.rb +51 -66
- data/lib/orb/models/invoice_mark_paid_params.rb +9 -11
- data/lib/orb/models/invoice_pay_params.rb +3 -8
- data/lib/orb/models/invoice_update_params.rb +9 -9
- data/lib/orb/models/invoice_void_params.rb +3 -8
- data/lib/orb/models/item.rb +14 -25
- data/lib/orb/models/item_create_params.rb +5 -9
- data/lib/orb/models/item_fetch_params.rb +3 -8
- data/lib/orb/models/item_list_params.rb +12 -15
- data/lib/orb/models/item_update_params.rb +10 -22
- data/lib/orb/models/metric_create_params.rb +17 -13
- data/lib/orb/models/metric_fetch_params.rb +3 -8
- data/lib/orb/models/metric_list_params.rb +20 -30
- data/lib/orb/models/metric_update_params.rb +9 -9
- data/lib/orb/models/pagination_metadata.rb +3 -7
- data/lib/orb/models/percentage_discount.rb +15 -14
- data/lib/orb/models/plan.rb +259 -291
- data/lib/orb/models/plan_create_params.rb +2070 -2466
- data/lib/orb/models/plan_fetch_params.rb +3 -8
- data/lib/orb/models/plan_list_params.rb +25 -42
- data/lib/orb/models/plan_update_params.rb +12 -10
- data/lib/orb/models/plans/external_plan_id_fetch_params.rb +3 -8
- data/lib/orb/models/plans/external_plan_id_update_params.rb +12 -10
- data/lib/orb/models/price.rb +3842 -5005
- data/lib/orb/models/price_create_params.rb +203 -244
- data/lib/orb/models/price_evaluate_params.rb +21 -30
- data/lib/orb/models/price_evaluate_response.rb +2 -6
- data/lib/orb/models/price_fetch_params.rb +3 -8
- data/lib/orb/models/price_list_params.rb +12 -15
- data/lib/orb/models/price_update_params.rb +9 -9
- data/lib/orb/models/prices/external_price_id_fetch_params.rb +3 -8
- data/lib/orb/models/prices/external_price_id_update_params.rb +9 -9
- data/lib/orb/models/subscription.rb +360 -405
- data/lib/orb/models/subscription_cancel_params.rb +16 -16
- data/lib/orb/models/subscription_cancel_response.rb +358 -399
- data/lib/orb/models/subscription_change_apply_params.rb +7 -10
- data/lib/orb/models/subscription_change_apply_response.rb +384 -418
- data/lib/orb/models/subscription_change_cancel_params.rb +3 -8
- data/lib/orb/models/subscription_change_cancel_response.rb +384 -417
- data/lib/orb/models/subscription_change_retrieve_params.rb +3 -8
- data/lib/orb/models/subscription_change_retrieve_response.rb +385 -417
- data/lib/orb/models/subscription_create_params.rb +4735 -5417
- data/lib/orb/models/subscription_create_response.rb +358 -399
- data/lib/orb/models/subscription_fetch_costs_params.rb +17 -17
- data/lib/orb/models/subscription_fetch_costs_response.rb +23 -27
- data/lib/orb/models/subscription_fetch_params.rb +3 -8
- data/lib/orb/models/subscription_fetch_schedule_params.rb +20 -30
- data/lib/orb/models/subscription_fetch_schedule_response.rb +15 -17
- data/lib/orb/models/subscription_fetch_usage_params.rb +32 -43
- data/lib/orb/models/subscription_list_params.rb +28 -41
- data/lib/orb/models/subscription_price_intervals_params.rb +2560 -3040
- data/lib/orb/models/subscription_price_intervals_response.rb +361 -399
- data/lib/orb/models/subscription_schedule_plan_change_params.rb +4728 -5411
- data/lib/orb/models/subscription_schedule_plan_change_response.rb +361 -398
- data/lib/orb/models/subscription_trigger_phase_params.rb +12 -10
- data/lib/orb/models/subscription_trigger_phase_response.rb +360 -399
- data/lib/orb/models/subscription_unschedule_cancellation_params.rb +3 -8
- data/lib/orb/models/subscription_unschedule_cancellation_response.rb +361 -398
- data/lib/orb/models/subscription_unschedule_fixed_fee_quantity_updates_params.rb +5 -9
- data/lib/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rb +362 -396
- data/lib/orb/models/subscription_unschedule_pending_plan_changes_params.rb +3 -8
- data/lib/orb/models/subscription_unschedule_pending_plan_changes_response.rb +362 -396
- data/lib/orb/models/subscription_update_fixed_fee_quantity_params.rb +22 -33
- data/lib/orb/models/subscription_update_fixed_fee_quantity_response.rb +361 -398
- data/lib/orb/models/subscription_update_params.rb +21 -23
- data/lib/orb/models/subscription_update_trial_params.rb +15 -18
- data/lib/orb/models/subscription_update_trial_response.rb +360 -399
- data/lib/orb/models/subscription_usage.rb +37 -80
- data/lib/orb/models/subscriptions.rb +3 -7
- data/lib/orb/models/top_level_ping_params.rb +3 -8
- data/lib/orb/models/top_level_ping_response.rb +2 -6
- data/lib/orb/models/trial_discount.rb +16 -24
- data/lib/orb/models/usage_discount.rb +15 -14
- data/lib/orb/models.rb +220 -0
- data/lib/orb/request_options.rb +4 -6
- data/lib/orb/resources/alerts.rb +48 -17
- data/lib/orb/resources/coupons/subscriptions.rb +9 -2
- data/lib/orb/resources/coupons.rb +26 -8
- data/lib/orb/resources/credit_notes.rb +17 -4
- data/lib/orb/resources/customers/balance_transactions.rb +18 -3
- data/lib/orb/resources/customers/costs.rb +26 -8
- data/lib/orb/resources/customers/credits/ledger.rb +112 -32
- data/lib/orb/resources/customers/credits/top_ups.rb +67 -20
- data/lib/orb/resources/customers/credits.rb +28 -8
- data/lib/orb/resources/customers.rb +138 -39
- data/lib/orb/resources/dimensional_price_groups.rb +19 -4
- data/lib/orb/resources/events/backfills.rb +32 -9
- data/lib/orb/resources/events/volume.rb +14 -4
- data/lib/orb/resources/events.rb +40 -11
- data/lib/orb/resources/invoice_line_items.rb +16 -6
- data/lib/orb/resources/invoices.rb +77 -17
- data/lib/orb/resources/items.rb +10 -3
- data/lib/orb/resources/metrics.rb +33 -8
- data/lib/orb/resources/plans/external_plan_id.rb +10 -2
- data/lib/orb/resources/plans.rb +47 -11
- data/lib/orb/resources/prices/external_price_id.rb +9 -3
- data/lib/orb/resources/prices.rb +101 -26
- data/lib/orb/resources/subscription_changes.rb +5 -2
- data/lib/orb/resources/subscriptions.rb +292 -78
- data/lib/orb/version.rb +1 -1
- data/lib/orb.rb +2 -10
- data/rbi/{lib/orb → orb}/client.rbi +4 -4
- data/rbi/{lib/orb → orb}/errors.rbi +1 -1
- data/rbi/orb/file_part.rbi +34 -0
- data/rbi/{lib/orb → orb}/internal/transport/base_client.rbi +19 -5
- data/rbi/{lib/orb → orb}/internal/type/array_of.rbi +3 -0
- data/rbi/{lib/orb → orb}/internal/type/base_model.rbi +7 -1
- data/rbi/{lib/orb → orb}/internal/type/base_page.rbi +2 -0
- data/rbi/{lib/orb → orb}/internal/type/enum.rbi +3 -6
- data/rbi/{lib/orb/internal/type/io_like.rbi → orb/internal/type/file_input.rbi} +5 -2
- data/rbi/{lib/orb → orb}/internal/type/hash_of.rbi +3 -0
- data/rbi/{lib/orb → orb}/internal/type/request_parameters.rbi +1 -1
- data/rbi/{lib/orb → orb}/internal/type/union.rbi +3 -0
- data/rbi/{lib/orb → orb}/internal/util.rbi +28 -19
- data/rbi/{lib/orb → orb}/internal.rbi +0 -1
- data/rbi/{lib/orb → orb}/models/alert.rbi +28 -8
- data/rbi/{lib/orb → orb}/models/alert_create_for_customer_params.rbi +16 -6
- data/rbi/{lib/orb → orb}/models/alert_create_for_external_customer_params.rbi +16 -6
- data/rbi/{lib/orb → orb}/models/alert_create_for_subscription_params.rbi +16 -6
- data/rbi/{lib/orb → orb}/models/alert_disable_params.rbi +5 -2
- data/rbi/{lib/orb → orb}/models/alert_enable_params.rbi +5 -2
- data/rbi/{lib/orb → orb}/models/alert_list_params.rbi +6 -0
- data/rbi/{lib/orb → orb}/models/alert_update_params.rbi +11 -4
- data/rbi/{lib/orb → orb}/models/amount_discount.rbi +10 -4
- data/rbi/{lib/orb → orb}/models/billable_metric.rbi +16 -3
- data/rbi/{lib/orb → orb}/models/billing_cycle_relative_date.rbi +1 -1
- data/rbi/{lib/orb → orb}/models/coupon.rbi +10 -3
- data/rbi/{lib/orb → orb}/models/coupon_create_params.rbi +15 -12
- data/rbi/{lib/orb → orb}/models/coupon_list_params.rbi +13 -3
- data/rbi/{lib/orb → orb}/models/coupons/subscription_list_params.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/credit_note.rbi +44 -12
- data/rbi/{lib/orb → orb}/models/credit_note_create_params.rbi +15 -6
- data/rbi/{lib/orb → orb}/models/credit_note_list_params.rbi +3 -0
- data/rbi/{lib/orb → orb}/models/customer.rbi +130 -11
- data/rbi/{lib/orb → orb}/models/customer_create_params.rbi +151 -17
- data/rbi/{lib/orb → orb}/models/customer_list_params.rbi +3 -0
- data/rbi/{lib/orb → orb}/models/customer_update_by_external_id_params.rbi +149 -17
- data/rbi/{lib/orb → orb}/models/customer_update_params.rbi +149 -17
- data/rbi/{lib/orb → orb}/models/customers/balance_transaction_create_params.rbi +8 -4
- data/rbi/{lib/orb → orb}/models/customers/balance_transaction_create_response.rbi +18 -8
- data/rbi/{lib/orb → orb}/models/customers/balance_transaction_list_params.rbi +3 -0
- data/rbi/{lib/orb → orb}/models/customers/balance_transaction_list_response.rbi +18 -8
- data/rbi/{lib/orb → orb}/models/customers/cost_list_by_external_id_params.rbi +9 -5
- data/rbi/orb/models/customers/cost_list_by_external_id_response.rbi +225 -0
- data/rbi/{lib/orb → orb}/models/customers/cost_list_params.rbi +9 -5
- data/rbi/orb/models/customers/cost_list_response.rbi +223 -0
- data/rbi/{lib/orb → orb}/models/customers/credit_list_by_external_id_params.rbi +13 -3
- data/rbi/{lib/orb → orb}/models/customers/credit_list_by_external_id_response.rbi +1 -2
- data/rbi/{lib/orb → orb}/models/customers/credit_list_params.rbi +13 -3
- data/rbi/{lib/orb → orb}/models/customers/credit_list_response.rbi +1 -2
- data/rbi/{lib/orb → orb}/models/customers/credits/ledger_create_entry_by_external_id_params.rbi +40 -18
- data/rbi/{lib/orb/models/customers/credits/ledger_create_entry_response.rbi → orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbi} +157 -170
- data/rbi/{lib/orb → orb}/models/customers/credits/ledger_create_entry_params.rbi +40 -6
- data/rbi/{lib/orb/models/customers/credits/ledger_list_response.rbi → orb/models/customers/credits/ledger_create_entry_response.rbi} +149 -196
- data/rbi/{lib/orb → orb}/models/customers/credits/ledger_list_by_external_id_params.rbi +6 -16
- data/rbi/{lib/orb → orb}/models/customers/credits/ledger_list_by_external_id_response.rbi +148 -229
- data/rbi/{lib/orb → orb}/models/customers/credits/ledger_list_params.rbi +6 -4
- data/rbi/{lib/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbi → orb/models/customers/credits/ledger_list_response.rbi} +149 -343
- data/rbi/{lib/orb → orb}/models/customers/credits/top_up_create_by_external_id_params.rbi +27 -10
- data/rbi/{lib/orb → orb}/models/customers/credits/top_up_create_by_external_id_response.rbi +25 -10
- data/rbi/{lib/orb → orb}/models/customers/credits/top_up_create_params.rbi +27 -4
- data/rbi/{lib/orb → orb}/models/customers/credits/top_up_create_response.rbi +25 -10
- data/rbi/{lib/orb → orb}/models/customers/credits/top_up_list_by_external_id_params.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/customers/credits/top_up_list_by_external_id_response.rbi +25 -10
- data/rbi/{lib/orb → orb}/models/customers/credits/top_up_list_params.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/customers/credits/top_up_list_response.rbi +25 -4
- data/rbi/{lib/orb → orb}/models/dimensional_price_group.rbi +11 -3
- data/rbi/{lib/orb → orb}/models/dimensional_price_group_create_params.rbi +4 -0
- data/rbi/{lib/orb → orb}/models/dimensional_price_group_list_params.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/evaluate_price_group.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/event_deprecate_response.rbi +4 -2
- data/rbi/{lib/orb → orb}/models/event_ingest_params.rbi +22 -5
- data/rbi/{lib/orb → orb}/models/event_ingest_response.rbi +15 -4
- data/rbi/{lib/orb → orb}/models/event_search_params.rbi +14 -2
- data/rbi/{lib/orb → orb}/models/event_search_response.rbi +14 -3
- data/rbi/{lib/orb → orb}/models/event_update_params.rbi +10 -3
- data/rbi/{lib/orb → orb}/models/event_update_response.rbi +4 -2
- data/rbi/{lib/orb → orb}/models/events/backfill_close_response.rbi +14 -2
- data/rbi/{lib/orb → orb}/models/events/backfill_create_params.rbi +18 -0
- data/rbi/{lib/orb → orb}/models/events/backfill_create_response.rbi +14 -2
- data/rbi/{lib/orb → orb}/models/events/backfill_fetch_response.rbi +14 -2
- data/rbi/{lib/orb → orb}/models/events/backfill_list_params.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/events/backfill_list_response.rbi +14 -2
- data/rbi/{lib/orb → orb}/models/events/backfill_revert_response.rbi +14 -2
- data/rbi/{lib/orb → orb}/models/events/event_volumes.rbi +8 -4
- data/rbi/{lib/orb → orb}/models/events/volume_list_params.rbi +18 -2
- data/rbi/{lib/orb → orb}/models/invoice.rbi +513 -202
- data/rbi/{lib/orb → orb}/models/invoice_create_params.rbi +38 -6
- data/rbi/{lib/orb → orb}/models/invoice_fetch_upcoming_response.rbi +513 -216
- data/rbi/{lib/orb → orb}/models/invoice_issue_params.rbi +9 -2
- data/rbi/{lib/orb → orb}/models/invoice_line_item_create_params.rbi +16 -2
- data/rbi/{lib/orb → orb}/models/invoice_line_item_create_response.rbi +279 -182
- data/rbi/{lib/orb → orb}/models/invoice_list_params.rbi +9 -2
- data/rbi/{lib/orb → orb}/models/invoice_mark_paid_params.rbi +9 -2
- data/rbi/{lib/orb → orb}/models/invoice_update_params.rbi +7 -2
- data/rbi/{lib/orb → orb}/models/item.rbi +1 -2
- data/rbi/{lib/orb → orb}/models/item_create_params.rbi +5 -2
- data/rbi/{lib/orb → orb}/models/item_list_params.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/item_update_params.rbi +1 -8
- data/rbi/{lib/orb → orb}/models/metric_create_params.rbi +15 -2
- data/rbi/{lib/orb → orb}/models/metric_list_params.rbi +3 -0
- data/rbi/{lib/orb → orb}/models/metric_update_params.rbi +7 -2
- data/rbi/{lib/orb → orb}/models/percentage_discount.rbi +11 -4
- data/rbi/{lib/orb → orb}/models/plan.rbi +207 -120
- data/rbi/{lib/orb → orb}/models/plan_create_params.rbi +1971 -2414
- data/rbi/{lib/orb → orb}/models/plan_list_params.rbi +5 -1
- data/rbi/{lib/orb → orb}/models/plan_update_params.rbi +11 -2
- data/rbi/{lib/orb → orb}/models/plans/external_plan_id_update_params.rbi +11 -2
- data/rbi/{lib/orb → orb}/models/price.rbi +2594 -2957
- data/rbi/{lib/orb → orb}/models/price_create_params.rbi +137 -53
- data/rbi/{lib/orb → orb}/models/price_evaluate_params.rbi +10 -0
- data/rbi/{lib/orb → orb}/models/price_list_params.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/price_update_params.rbi +7 -2
- data/rbi/{lib/orb → orb}/models/prices/external_price_id_update_params.rbi +7 -2
- data/rbi/{lib/orb → orb}/models/subscription.rbi +292 -129
- data/rbi/{lib/orb → orb}/models/subscription_cancel_params.rbi +8 -5
- data/rbi/{lib/orb → orb}/models/subscription_cancel_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_change_apply_params.rbi +7 -2
- data/rbi/{lib/orb → orb}/models/subscription_change_apply_response.rbi +317 -136
- data/rbi/{lib/orb → orb}/models/subscription_change_cancel_response.rbi +317 -136
- data/rbi/{lib/orb → orb}/models/subscription_change_retrieve_response.rbi +317 -136
- data/rbi/{lib/orb → orb}/models/subscription_create_params.rbi +4271 -4270
- data/rbi/{lib/orb → orb}/models/subscription_create_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_fetch_costs_params.rbi +9 -5
- data/rbi/orb/models/subscription_fetch_costs_response.rbi +221 -0
- data/rbi/{lib/orb → orb}/models/subscription_fetch_schedule_params.rbi +3 -0
- data/rbi/{lib/orb → orb}/models/subscription_fetch_schedule_response.rbi +8 -2
- data/rbi/{lib/orb → orb}/models/subscription_fetch_usage_params.rbi +13 -4
- data/rbi/{lib/orb → orb}/models/subscription_list_params.rbi +4 -2
- data/rbi/{lib/orb → orb}/models/subscription_price_intervals_params.rbi +2354 -2317
- data/rbi/{lib/orb → orb}/models/subscription_price_intervals_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_schedule_plan_change_params.rbi +4280 -3758
- data/rbi/{lib/orb → orb}/models/subscription_schedule_plan_change_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_trigger_phase_params.rbi +10 -2
- data/rbi/{lib/orb → orb}/models/subscription_trigger_phase_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_unschedule_cancellation_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_unschedule_fixed_fee_quantity_updates_params.rbi +5 -2
- data/rbi/{lib/orb → orb}/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbi +305 -138
- data/rbi/{lib/orb → orb}/models/subscription_unschedule_pending_plan_changes_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_update_fixed_fee_quantity_params.rbi +11 -2
- data/rbi/{lib/orb → orb}/models/subscription_update_fixed_fee_quantity_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_update_params.rbi +15 -0
- data/rbi/{lib/orb → orb}/models/subscription_update_trial_params.rbi +11 -5
- data/rbi/{lib/orb → orb}/models/subscription_update_trial_response.rbi +305 -132
- data/rbi/{lib/orb → orb}/models/subscription_usage.rbi +2 -16
- data/rbi/{lib/orb → orb}/models/trial_discount.rbi +5 -1
- data/rbi/{lib/orb → orb}/models/usage_discount.rbi +11 -3
- data/rbi/orb/models.rbi +220 -0
- data/rbi/{lib/orb → orb}/request_options.rbi +2 -0
- data/rbi/{lib/orb → orb}/resources/alerts.rbi +8 -14
- data/rbi/{lib/orb → orb}/resources/coupons/subscriptions.rbi +1 -1
- data/rbi/{lib/orb → orb}/resources/coupons.rbi +6 -18
- data/rbi/{lib/orb → orb}/resources/credit_notes.rbi +3 -9
- data/rbi/{lib/orb → orb}/resources/customers/balance_transactions.rbi +2 -2
- data/rbi/{lib/orb → orb}/resources/customers/costs.rbi +2 -2
- data/rbi/{lib/orb → orb}/resources/customers/credits/ledger.rbi +32 -32
- data/rbi/{lib/orb → orb}/resources/customers/credits/top_ups.rbi +6 -18
- data/rbi/{lib/orb → orb}/resources/customers/credits.rbi +2 -2
- data/rbi/{lib/orb → orb}/resources/customers.rbi +15 -45
- data/rbi/{lib/orb → orb}/resources/dimensional_price_groups/external_dimensional_price_group_id.rbi +1 -4
- data/rbi/{lib/orb → orb}/resources/dimensional_price_groups.rbi +3 -10
- data/rbi/{lib/orb → orb}/resources/events/backfills.rbi +5 -18
- data/rbi/{lib/orb → orb}/resources/events/volume.rbi +1 -1
- data/rbi/{lib/orb → orb}/resources/events.rbi +4 -10
- data/rbi/{lib/orb → orb}/resources/invoice_line_items.rbi +1 -1
- data/rbi/{lib/orb → orb}/resources/invoices.rbi +9 -34
- data/rbi/{lib/orb → orb}/resources/items.rbi +4 -17
- data/rbi/{lib/orb → orb}/resources/metrics.rbi +4 -10
- data/rbi/{lib/orb → orb}/resources/plans/external_plan_id.rbi +2 -8
- data/rbi/{lib/orb → orb}/resources/plans.rbi +29 -35
- data/rbi/orb/resources/prices/external_price_id.rbi +103 -0
- data/rbi/{lib/orb → orb}/resources/prices.rbi +117 -124
- data/rbi/{lib/orb → orb}/resources/subscription_changes.rbi +3 -9
- data/rbi/{lib/orb → orb}/resources/subscriptions.rbi +16 -32
- data/rbi/{lib/orb → orb}/resources/top_level.rbi +1 -4
- data/sig/orb/file_part.rbs +21 -0
- data/sig/orb/internal/transport/base_client.rbs +9 -3
- data/sig/orb/internal/type/array_of.rbs +2 -0
- data/sig/orb/internal/type/base_model.rbs +4 -0
- data/sig/orb/internal/type/enum.rbs +2 -2
- data/sig/orb/internal/type/{io_like.rbs → file_input.rbs} +1 -1
- data/sig/orb/internal/type/hash_of.rbs +2 -0
- data/sig/orb/internal/type/union.rbs +2 -0
- data/sig/orb/internal/util.rbs +16 -12
- data/sig/orb/models/coupon_create_params.rbs +9 -10
- data/sig/orb/models/customer_create_params.rbs +9 -10
- data/sig/orb/models/customer_update_by_external_id_params.rbs +9 -10
- data/sig/orb/models/customer_update_params.rbs +9 -10
- data/sig/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbs +113 -113
- data/sig/orb/models/customers/credits/ledger_create_entry_response.rbs +113 -113
- data/sig/orb/models/customers/credits/ledger_list_by_external_id_response.rbs +113 -113
- data/sig/orb/models/customers/credits/ledger_list_response.rbs +113 -113
- data/sig/orb/models/invoice.rbs +54 -54
- data/sig/orb/models/invoice_fetch_upcoming_response.rbs +54 -54
- data/sig/orb/models/invoice_line_item_create_response.rbs +54 -54
- data/sig/orb/models/plan.rbs +21 -21
- data/sig/orb/models/plan_create_params.rbs +653 -653
- data/sig/orb/models/price.rbs +1517 -1521
- data/sig/orb/models/subscription.rbs +34 -34
- data/sig/orb/models/subscription_cancel_response.rbs +34 -34
- data/sig/orb/models/subscription_change_apply_response.rbs +34 -34
- data/sig/orb/models/subscription_change_cancel_response.rbs +34 -34
- data/sig/orb/models/subscription_change_retrieve_response.rbs +34 -34
- data/sig/orb/models/subscription_create_params.rbs +1348 -1348
- data/sig/orb/models/subscription_create_response.rbs +34 -34
- data/sig/orb/models/subscription_price_intervals_params.rbs +767 -769
- data/sig/orb/models/subscription_price_intervals_response.rbs +34 -34
- data/sig/orb/models/subscription_schedule_plan_change_params.rbs +1348 -1348
- data/sig/orb/models/subscription_schedule_plan_change_response.rbs +34 -34
- data/sig/orb/models/subscription_trigger_phase_response.rbs +34 -34
- data/sig/orb/models/subscription_unschedule_cancellation_response.rbs +34 -34
- data/sig/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbs +34 -34
- data/sig/orb/models/subscription_unschedule_pending_plan_changes_response.rbs +34 -34
- data/sig/orb/models/subscription_update_fixed_fee_quantity_response.rbs +34 -34
- data/sig/orb/models/subscription_update_trial_response.rbs +34 -34
- data/sig/orb/models.rbs +215 -0
- metadata +230 -224
- data/rbi/lib/orb/models/customers/cost_list_by_external_id_response.rbi +0 -208
- data/rbi/lib/orb/models/customers/cost_list_response.rbi +0 -206
- data/rbi/lib/orb/models/subscription_fetch_costs_response.rbi +0 -204
- data/rbi/lib/orb/resources/prices/external_price_id.rbi +0 -106
- /data/rbi/{lib/orb → orb}/internal/page.rbi +0 -0
- /data/rbi/{lib/orb → orb}/internal/transport/pooled_net_requester.rbi +0 -0
- /data/rbi/{lib/orb → orb}/internal/type/boolean.rbi +0 -0
- /data/rbi/{lib/orb → orb}/internal/type/converter.rbi +0 -0
- /data/rbi/{lib/orb → orb}/internal/type/unknown.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/alert_retrieve_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/coupon_archive_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/coupon_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/credit_note_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/customer_delete_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/customer_fetch_by_external_id_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/customer_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/customer_sync_payment_methods_from_gateway_by_external_customer_id_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/customer_sync_payment_methods_from_gateway_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/customers/credits/top_up_delete_by_external_id_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/customers/credits/top_up_delete_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/dimensional_price_group_retrieve_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/dimensional_price_groups/external_dimensional_price_group_id_retrieve_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/dimensional_price_groups.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/discount.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/event_deprecate_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/events/backfill_close_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/events/backfill_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/events/backfill_revert_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/invoice_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/invoice_fetch_upcoming_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/invoice_level_discount.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/invoice_pay_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/invoice_void_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/item_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/metric_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/pagination_metadata.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/plan_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/plans/external_plan_id_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/price_evaluate_response.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/price_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/prices/external_price_id_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/subscription_change_cancel_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/subscription_change_retrieve_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/subscription_fetch_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/subscription_unschedule_cancellation_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/subscription_unschedule_pending_plan_changes_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/subscriptions.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/top_level_ping_params.rbi +0 -0
- /data/rbi/{lib/orb → orb}/models/top_level_ping_response.rbi +0 -0
- /data/rbi/{lib/orb → orb}/version.rbi +0 -0
@@ -101,7 +101,7 @@ module Orb
|
|
101
101
|
# @!attribute discount_intervals
|
102
102
|
# The discount intervals for this subscription sorted by the start_date.
|
103
103
|
#
|
104
|
-
# @return [Array<Orb::Models::Subscription::DiscountInterval::
|
104
|
+
# @return [Array<Orb::Models::Subscription::DiscountInterval::Amount, Orb::Models::Subscription::DiscountInterval::Percentage, Orb::Models::Subscription::DiscountInterval::Usage>]
|
105
105
|
required :discount_intervals,
|
106
106
|
-> { Orb::Internal::Type::ArrayOf[union: Orb::Models::Subscription::DiscountInterval] }
|
107
107
|
|
@@ -198,87 +198,92 @@ module Orb
|
|
198
198
|
# @return [Orb::Models::Subscription::TrialInfo]
|
199
199
|
required :trial_info, -> { Orb::Models::Subscription::TrialInfo }
|
200
200
|
|
201
|
-
# @!
|
202
|
-
#
|
203
|
-
#
|
204
|
-
#
|
205
|
-
# #
|
206
|
-
#
|
207
|
-
#
|
208
|
-
#
|
209
|
-
#
|
210
|
-
#
|
211
|
-
#
|
212
|
-
#
|
213
|
-
#
|
214
|
-
#
|
215
|
-
#
|
216
|
-
#
|
217
|
-
#
|
218
|
-
#
|
219
|
-
#
|
220
|
-
#
|
221
|
-
#
|
222
|
-
#
|
223
|
-
#
|
224
|
-
#
|
225
|
-
#
|
226
|
-
#
|
227
|
-
#
|
228
|
-
#
|
229
|
-
#
|
230
|
-
#
|
231
|
-
#
|
232
|
-
#
|
233
|
-
#
|
234
|
-
#
|
235
|
-
#
|
236
|
-
#
|
237
|
-
#
|
238
|
-
#
|
239
|
-
#
|
240
|
-
#
|
241
|
-
#
|
242
|
-
#
|
243
|
-
#
|
244
|
-
#
|
245
|
-
#
|
246
|
-
#
|
247
|
-
#
|
248
|
-
#
|
249
|
-
#
|
250
|
-
#
|
251
|
-
#
|
252
|
-
#
|
253
|
-
#
|
254
|
-
#
|
255
|
-
#
|
256
|
-
#
|
257
|
-
#
|
258
|
-
#
|
259
|
-
#
|
260
|
-
#
|
261
|
-
#
|
262
|
-
#
|
263
|
-
#
|
264
|
-
#
|
265
|
-
#
|
266
|
-
#
|
267
|
-
#
|
268
|
-
#
|
269
|
-
#
|
270
|
-
#
|
271
|
-
#
|
272
|
-
#
|
273
|
-
#
|
274
|
-
#
|
275
|
-
#
|
276
|
-
#
|
277
|
-
#
|
278
|
-
#
|
279
|
-
#
|
280
|
-
|
281
|
-
#
|
201
|
+
# @!method initialize(id:, active_plan_phase_order:, adjustment_intervals:, auto_collection:, billing_cycle_anchor_configuration:, billing_cycle_day:, created_at:, current_billing_period_end_date:, current_billing_period_start_date:, customer:, default_invoice_memo:, discount_intervals:, end_date:, fixed_fee_quantity_schedule:, invoicing_threshold:, maximum_intervals:, metadata:, minimum_intervals:, net_terms:, pending_subscription_change:, plan:, price_intervals:, redeemed_coupon:, start_date:, status:, trial_info:)
|
202
|
+
# Some parameter documentations has been truncated, see
|
203
|
+
# {Orb::Models::Subscription} for more details.
|
204
|
+
#
|
205
|
+
# A [subscription](/core-concepts#subscription) represents the purchase of a plan
|
206
|
+
# by a customer.
|
207
|
+
#
|
208
|
+
# By default, subscriptions begin on the day that they're created and renew
|
209
|
+
# automatically for each billing cycle at the cadence that's configured in the
|
210
|
+
# plan definition.
|
211
|
+
#
|
212
|
+
# Subscriptions also default to **beginning of month alignment**, which means the
|
213
|
+
# first invoice issued for the subscription will have pro-rated charges between
|
214
|
+
# the `start_date` and the first of the following month. Subsequent billing
|
215
|
+
# periods will always start and end on a month boundary (e.g. subsequent month
|
216
|
+
# starts for monthly billing).
|
217
|
+
#
|
218
|
+
# Depending on the plan configuration, any _flat_ recurring fees will be billed
|
219
|
+
# either at the beginning (in-advance) or end (in-arrears) of each billing cycle.
|
220
|
+
# Plans default to **in-advance billing**. Usage-based fees are billed in arrears
|
221
|
+
# as usage is accumulated. In the normal course of events, you can expect an
|
222
|
+
# invoice to contain usage-based charges for the previous period, and a recurring
|
223
|
+
# fee for the following period.
|
224
|
+
#
|
225
|
+
# @param id [String]
|
226
|
+
#
|
227
|
+
# @param active_plan_phase_order [Integer, nil] The current plan phase that is active, only if the subscription's plan has phase
|
228
|
+
# ...
|
229
|
+
#
|
230
|
+
# @param adjustment_intervals [Array<Orb::Models::Subscription::AdjustmentInterval>] The adjustment intervals for this subscription sorted by the start_date of the a
|
231
|
+
# ...
|
232
|
+
#
|
233
|
+
# @param auto_collection [Boolean, nil] Determines whether issued invoices for this subscription will automatically be c
|
234
|
+
# ...
|
235
|
+
#
|
236
|
+
# @param billing_cycle_anchor_configuration [Orb::Models::Subscription::BillingCycleAnchorConfiguration]
|
237
|
+
#
|
238
|
+
# @param billing_cycle_day [Integer] The day of the month on which the billing cycle is anchored. If the maximum numb
|
239
|
+
# ...
|
240
|
+
#
|
241
|
+
# @param created_at [Time]
|
242
|
+
#
|
243
|
+
# @param current_billing_period_end_date [Time, nil] The end of the current billing period. This is an exclusive timestamp, such that
|
244
|
+
# ...
|
245
|
+
#
|
246
|
+
# @param current_billing_period_start_date [Time, nil] The start date of the current billing period. This is an inclusive timestamp; th
|
247
|
+
# ...
|
248
|
+
#
|
249
|
+
# @param customer [Orb::Models::Customer] A customer is a buyer of your products, and the other party to the billing relat
|
250
|
+
# ...
|
251
|
+
#
|
252
|
+
# @param default_invoice_memo [String, nil] Determines the default memo on this subscriptions' invoices. Note that if this i
|
253
|
+
# ...
|
254
|
+
#
|
255
|
+
# @param discount_intervals [Array<Orb::Models::Subscription::DiscountInterval::Amount, Orb::Models::Subscription::DiscountInterval::Percentage, Orb::Models::Subscription::DiscountInterval::Usage>] The discount intervals for this subscription sorted by the start_date.
|
256
|
+
#
|
257
|
+
# @param end_date [Time, nil] The date Orb stops billing for this subscription.
|
258
|
+
#
|
259
|
+
# @param fixed_fee_quantity_schedule [Array<Orb::Models::Subscription::FixedFeeQuantitySchedule>]
|
260
|
+
#
|
261
|
+
# @param invoicing_threshold [String, nil]
|
262
|
+
#
|
263
|
+
# @param maximum_intervals [Array<Orb::Models::Subscription::MaximumInterval>] The maximum intervals for this subscription sorted by the start_date.
|
264
|
+
#
|
265
|
+
# @param metadata [Hash{Symbol=>String}] User specified key-value pairs for the resource. If not present, this defaults t
|
266
|
+
# ...
|
267
|
+
#
|
268
|
+
# @param minimum_intervals [Array<Orb::Models::Subscription::MinimumInterval>] The minimum intervals for this subscription sorted by the start_date.
|
269
|
+
#
|
270
|
+
# @param net_terms [Integer] Determines the difference between the invoice issue date for subscription invoic
|
271
|
+
# ...
|
272
|
+
#
|
273
|
+
# @param pending_subscription_change [Orb::Models::Subscription::PendingSubscriptionChange, nil] A pending subscription change if one exists on this subscription.
|
274
|
+
#
|
275
|
+
# @param plan [Orb::Models::Plan] The [Plan](/core-concepts#plan-and-price) resource represents a plan that can be
|
276
|
+
# ...
|
277
|
+
#
|
278
|
+
# @param price_intervals [Array<Orb::Models::Subscription::PriceInterval>] The price intervals for this subscription.
|
279
|
+
#
|
280
|
+
# @param redeemed_coupon [Orb::Models::Subscription::RedeemedCoupon, nil]
|
281
|
+
#
|
282
|
+
# @param start_date [Time] The date Orb starts billing for this subscription.
|
283
|
+
#
|
284
|
+
# @param status [Symbol, Orb::Models::Subscription::Status]
|
285
|
+
#
|
286
|
+
# @param trial_info [Orb::Models::Subscription::TrialInfo]
|
282
287
|
|
283
288
|
class AdjustmentInterval < Orb::Internal::Type::BaseModel
|
284
289
|
# @!attribute id
|
@@ -288,7 +293,7 @@ module Orb
|
|
288
293
|
|
289
294
|
# @!attribute adjustment
|
290
295
|
#
|
291
|
-
# @return [Orb::Models::Subscription::AdjustmentInterval::Adjustment::
|
296
|
+
# @return [Orb::Models::Subscription::AdjustmentInterval::Adjustment::UsageDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::AmountDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::PercentageDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::Minimum, Orb::Models::Subscription::AdjustmentInterval::Adjustment::Maximum]
|
292
297
|
required :adjustment, union: -> { Orb::Models::Subscription::AdjustmentInterval::Adjustment }
|
293
298
|
|
294
299
|
# @!attribute applies_to_price_interval_ids
|
@@ -309,16 +314,16 @@ module Orb
|
|
309
314
|
# @return [Time]
|
310
315
|
required :start_date, Time
|
311
316
|
|
312
|
-
# @!
|
313
|
-
#
|
314
|
-
#
|
315
|
-
#
|
316
|
-
#
|
317
|
-
#
|
318
|
-
#
|
319
|
-
#
|
320
|
-
|
321
|
-
#
|
317
|
+
# @!method initialize(id:, adjustment:, applies_to_price_interval_ids:, end_date:, start_date:)
|
318
|
+
# @param id [String]
|
319
|
+
#
|
320
|
+
# @param adjustment [Orb::Models::Subscription::AdjustmentInterval::Adjustment::UsageDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::AmountDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::PercentageDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::Minimum, Orb::Models::Subscription::AdjustmentInterval::Adjustment::Maximum]
|
321
|
+
#
|
322
|
+
# @param applies_to_price_interval_ids [Array<String>] The price interval IDs that this adjustment applies to.
|
323
|
+
#
|
324
|
+
# @param end_date [Time, nil] The end date of the adjustment interval.
|
325
|
+
#
|
326
|
+
# @param start_date [Time] The start date of the adjustment interval.
|
322
327
|
|
323
328
|
# @see Orb::Models::Subscription::AdjustmentInterval#adjustment
|
324
329
|
module Adjustment
|
@@ -326,22 +331,18 @@ module Orb
|
|
326
331
|
|
327
332
|
discriminator :adjustment_type
|
328
333
|
|
329
|
-
variant :usage_discount,
|
330
|
-
-> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::PlanPhaseUsageDiscountAdjustment }
|
334
|
+
variant :usage_discount, -> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::UsageDiscount }
|
331
335
|
|
332
|
-
variant :amount_discount,
|
333
|
-
-> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::PlanPhaseAmountDiscountAdjustment }
|
336
|
+
variant :amount_discount, -> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::AmountDiscount }
|
334
337
|
|
335
338
|
variant :percentage_discount,
|
336
|
-
-> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::
|
339
|
+
-> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::PercentageDiscount }
|
337
340
|
|
338
|
-
variant :minimum,
|
339
|
-
-> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::PlanPhaseMinimumAdjustment }
|
341
|
+
variant :minimum, -> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::Minimum }
|
340
342
|
|
341
|
-
variant :maximum,
|
342
|
-
-> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::PlanPhaseMaximumAdjustment }
|
343
|
+
variant :maximum, -> { Orb::Models::Subscription::AdjustmentInterval::Adjustment::Maximum }
|
343
344
|
|
344
|
-
class
|
345
|
+
class UsageDiscount < Orb::Internal::Type::BaseModel
|
345
346
|
# @!attribute id
|
346
347
|
#
|
347
348
|
# @return [String]
|
@@ -384,32 +385,29 @@ module Orb
|
|
384
385
|
# @return [Float]
|
385
386
|
required :usage_discount, Float
|
386
387
|
|
387
|
-
# @!
|
388
|
-
#
|
389
|
-
#
|
390
|
-
#
|
391
|
-
#
|
392
|
-
#
|
393
|
-
#
|
394
|
-
#
|
395
|
-
#
|
396
|
-
#
|
397
|
-
#
|
398
|
-
#
|
399
|
-
#
|
400
|
-
#
|
401
|
-
#
|
402
|
-
#
|
403
|
-
#
|
404
|
-
#
|
405
|
-
#
|
406
|
-
#
|
407
|
-
# end
|
408
|
-
|
409
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
388
|
+
# @!method initialize(id:, applies_to_price_ids:, is_invoice_level:, plan_phase_order:, reason:, usage_discount:, adjustment_type: :usage_discount)
|
389
|
+
# Some parameter documentations has been truncated, see
|
390
|
+
# {Orb::Models::Subscription::AdjustmentInterval::Adjustment::UsageDiscount} for
|
391
|
+
# more details.
|
392
|
+
#
|
393
|
+
# @param id [String]
|
394
|
+
#
|
395
|
+
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
396
|
+
#
|
397
|
+
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
398
|
+
# ...
|
399
|
+
#
|
400
|
+
# @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
|
401
|
+
#
|
402
|
+
# @param reason [String, nil] The reason for the adjustment.
|
403
|
+
#
|
404
|
+
# @param usage_discount [Float] The number of usage units by which to discount the price this adjustment applies
|
405
|
+
# ...
|
406
|
+
#
|
407
|
+
# @param adjustment_type [Symbol, :usage_discount]
|
410
408
|
end
|
411
409
|
|
412
|
-
class
|
410
|
+
class AmountDiscount < Orb::Internal::Type::BaseModel
|
413
411
|
# @!attribute id
|
414
412
|
#
|
415
413
|
# @return [String]
|
@@ -452,32 +450,29 @@ module Orb
|
|
452
450
|
# @return [String, nil]
|
453
451
|
required :reason, String, nil?: true
|
454
452
|
|
455
|
-
# @!
|
456
|
-
#
|
457
|
-
#
|
458
|
-
#
|
459
|
-
#
|
460
|
-
#
|
461
|
-
#
|
462
|
-
#
|
463
|
-
#
|
464
|
-
#
|
465
|
-
#
|
466
|
-
#
|
467
|
-
#
|
468
|
-
#
|
469
|
-
#
|
470
|
-
#
|
471
|
-
#
|
472
|
-
#
|
473
|
-
#
|
474
|
-
#
|
475
|
-
# end
|
476
|
-
|
477
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
453
|
+
# @!method initialize(id:, amount_discount:, applies_to_price_ids:, is_invoice_level:, plan_phase_order:, reason:, adjustment_type: :amount_discount)
|
454
|
+
# Some parameter documentations has been truncated, see
|
455
|
+
# {Orb::Models::Subscription::AdjustmentInterval::Adjustment::AmountDiscount} for
|
456
|
+
# more details.
|
457
|
+
#
|
458
|
+
# @param id [String]
|
459
|
+
#
|
460
|
+
# @param amount_discount [String] The amount by which to discount the prices this adjustment applies to in a given
|
461
|
+
# ...
|
462
|
+
#
|
463
|
+
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
464
|
+
#
|
465
|
+
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
466
|
+
# ...
|
467
|
+
#
|
468
|
+
# @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
|
469
|
+
#
|
470
|
+
# @param reason [String, nil] The reason for the adjustment.
|
471
|
+
#
|
472
|
+
# @param adjustment_type [Symbol, :amount_discount]
|
478
473
|
end
|
479
474
|
|
480
|
-
class
|
475
|
+
class PercentageDiscount < Orb::Internal::Type::BaseModel
|
481
476
|
# @!attribute id
|
482
477
|
#
|
483
478
|
# @return [String]
|
@@ -520,32 +515,29 @@ module Orb
|
|
520
515
|
# @return [String, nil]
|
521
516
|
required :reason, String, nil?: true
|
522
517
|
|
523
|
-
# @!
|
524
|
-
#
|
525
|
-
#
|
526
|
-
#
|
527
|
-
#
|
528
|
-
#
|
529
|
-
#
|
530
|
-
#
|
531
|
-
#
|
532
|
-
#
|
533
|
-
#
|
534
|
-
#
|
535
|
-
#
|
536
|
-
#
|
537
|
-
#
|
538
|
-
#
|
539
|
-
#
|
540
|
-
#
|
541
|
-
#
|
542
|
-
#
|
543
|
-
# end
|
544
|
-
|
545
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
518
|
+
# @!method initialize(id:, applies_to_price_ids:, is_invoice_level:, percentage_discount:, plan_phase_order:, reason:, adjustment_type: :percentage_discount)
|
519
|
+
# Some parameter documentations has been truncated, see
|
520
|
+
# {Orb::Models::Subscription::AdjustmentInterval::Adjustment::PercentageDiscount}
|
521
|
+
# for more details.
|
522
|
+
#
|
523
|
+
# @param id [String]
|
524
|
+
#
|
525
|
+
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
526
|
+
#
|
527
|
+
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
528
|
+
# ...
|
529
|
+
#
|
530
|
+
# @param percentage_discount [Float] The percentage (as a value between 0 and 1) by which to discount the price inter
|
531
|
+
# ...
|
532
|
+
#
|
533
|
+
# @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
|
534
|
+
#
|
535
|
+
# @param reason [String, nil] The reason for the adjustment.
|
536
|
+
#
|
537
|
+
# @param adjustment_type [Symbol, :percentage_discount]
|
546
538
|
end
|
547
539
|
|
548
|
-
class
|
540
|
+
class Minimum < Orb::Internal::Type::BaseModel
|
549
541
|
# @!attribute id
|
550
542
|
#
|
551
543
|
# @return [String]
|
@@ -594,34 +586,31 @@ module Orb
|
|
594
586
|
# @return [String, nil]
|
595
587
|
required :reason, String, nil?: true
|
596
588
|
|
597
|
-
# @!
|
598
|
-
#
|
599
|
-
#
|
600
|
-
#
|
601
|
-
#
|
602
|
-
#
|
603
|
-
#
|
604
|
-
#
|
605
|
-
#
|
606
|
-
#
|
607
|
-
#
|
608
|
-
#
|
609
|
-
#
|
610
|
-
#
|
611
|
-
#
|
612
|
-
#
|
613
|
-
#
|
614
|
-
#
|
615
|
-
#
|
616
|
-
#
|
617
|
-
#
|
618
|
-
#
|
619
|
-
# end
|
620
|
-
|
621
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
589
|
+
# @!method initialize(id:, applies_to_price_ids:, is_invoice_level:, item_id:, minimum_amount:, plan_phase_order:, reason:, adjustment_type: :minimum)
|
590
|
+
# Some parameter documentations has been truncated, see
|
591
|
+
# {Orb::Models::Subscription::AdjustmentInterval::Adjustment::Minimum} for more
|
592
|
+
# details.
|
593
|
+
#
|
594
|
+
# @param id [String]
|
595
|
+
#
|
596
|
+
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
597
|
+
#
|
598
|
+
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
599
|
+
# ...
|
600
|
+
#
|
601
|
+
# @param item_id [String] The item ID that revenue from this minimum will be attributed to.
|
602
|
+
#
|
603
|
+
# @param minimum_amount [String] The minimum amount to charge in a given billing period for the prices this adjus
|
604
|
+
# ...
|
605
|
+
#
|
606
|
+
# @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
|
607
|
+
#
|
608
|
+
# @param reason [String, nil] The reason for the adjustment.
|
609
|
+
#
|
610
|
+
# @param adjustment_type [Symbol, :minimum]
|
622
611
|
end
|
623
612
|
|
624
|
-
class
|
613
|
+
class Maximum < Orb::Internal::Type::BaseModel
|
625
614
|
# @!attribute id
|
626
615
|
#
|
627
616
|
# @return [String]
|
@@ -664,34 +653,30 @@ module Orb
|
|
664
653
|
# @return [String, nil]
|
665
654
|
required :reason, String, nil?: true
|
666
655
|
|
667
|
-
# @!
|
668
|
-
#
|
669
|
-
#
|
670
|
-
#
|
671
|
-
#
|
672
|
-
#
|
673
|
-
#
|
674
|
-
#
|
675
|
-
#
|
676
|
-
#
|
677
|
-
#
|
678
|
-
#
|
679
|
-
#
|
680
|
-
#
|
681
|
-
#
|
682
|
-
#
|
683
|
-
#
|
684
|
-
#
|
685
|
-
#
|
686
|
-
#
|
687
|
-
# end
|
688
|
-
|
689
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
656
|
+
# @!method initialize(id:, applies_to_price_ids:, is_invoice_level:, maximum_amount:, plan_phase_order:, reason:, adjustment_type: :maximum)
|
657
|
+
# Some parameter documentations has been truncated, see
|
658
|
+
# {Orb::Models::Subscription::AdjustmentInterval::Adjustment::Maximum} for more
|
659
|
+
# details.
|
660
|
+
#
|
661
|
+
# @param id [String]
|
662
|
+
#
|
663
|
+
# @param applies_to_price_ids [Array<String>] The price IDs that this adjustment applies to.
|
664
|
+
#
|
665
|
+
# @param is_invoice_level [Boolean] True for adjustments that apply to an entire invocice, false for adjustments tha
|
666
|
+
# ...
|
667
|
+
#
|
668
|
+
# @param maximum_amount [String] The maximum amount to charge in a given billing period for the prices this adjus
|
669
|
+
# ...
|
670
|
+
#
|
671
|
+
# @param plan_phase_order [Integer, nil] The plan phase in which this adjustment is active.
|
672
|
+
#
|
673
|
+
# @param reason [String, nil] The reason for the adjustment.
|
674
|
+
#
|
675
|
+
# @param adjustment_type [Symbol, :maximum]
|
690
676
|
end
|
691
677
|
|
692
|
-
# @!
|
693
|
-
#
|
694
|
-
# def self.variants; end
|
678
|
+
# @!method self.variants
|
679
|
+
# @return [Array(Orb::Models::Subscription::AdjustmentInterval::Adjustment::UsageDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::AmountDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::PercentageDiscount, Orb::Models::Subscription::AdjustmentInterval::Adjustment::Minimum, Orb::Models::Subscription::AdjustmentInterval::Adjustment::Maximum)]
|
695
680
|
end
|
696
681
|
end
|
697
682
|
|
@@ -721,14 +706,18 @@ module Orb
|
|
721
706
|
# @return [Integer, nil]
|
722
707
|
optional :year, Integer, nil?: true
|
723
708
|
|
724
|
-
# @!
|
725
|
-
#
|
726
|
-
#
|
727
|
-
#
|
728
|
-
#
|
729
|
-
#
|
730
|
-
|
731
|
-
#
|
709
|
+
# @!method initialize(day:, month: nil, year: nil)
|
710
|
+
# Some parameter documentations has been truncated, see
|
711
|
+
# {Orb::Models::Subscription::BillingCycleAnchorConfiguration} for more details.
|
712
|
+
#
|
713
|
+
# @param day [Integer] The day of the month on which the billing cycle is anchored. If the maximum numb
|
714
|
+
# ...
|
715
|
+
#
|
716
|
+
# @param month [Integer, nil] The month on which the billing cycle is anchored (e.g. a quarterly price anchore
|
717
|
+
# ...
|
718
|
+
#
|
719
|
+
# @param year [Integer, nil] The year on which the billing cycle is anchored (e.g. a 2 year billing cycle anc
|
720
|
+
# ...
|
732
721
|
end
|
733
722
|
|
734
723
|
module DiscountInterval
|
@@ -736,13 +725,13 @@ module Orb
|
|
736
725
|
|
737
726
|
discriminator :discount_type
|
738
727
|
|
739
|
-
variant :amount, -> { Orb::Models::Subscription::DiscountInterval::
|
728
|
+
variant :amount, -> { Orb::Models::Subscription::DiscountInterval::Amount }
|
740
729
|
|
741
|
-
variant :percentage, -> { Orb::Models::Subscription::DiscountInterval::
|
730
|
+
variant :percentage, -> { Orb::Models::Subscription::DiscountInterval::Percentage }
|
742
731
|
|
743
|
-
variant :usage, -> { Orb::Models::Subscription::DiscountInterval::
|
732
|
+
variant :usage, -> { Orb::Models::Subscription::DiscountInterval::Usage }
|
744
733
|
|
745
|
-
class
|
734
|
+
class Amount < Orb::Internal::Type::BaseModel
|
746
735
|
# @!attribute amount_discount
|
747
736
|
# Only available if discount_type is `amount`.
|
748
737
|
#
|
@@ -778,30 +767,21 @@ module Orb
|
|
778
767
|
# @return [Time]
|
779
768
|
required :start_date, Time
|
780
769
|
|
781
|
-
# @!
|
782
|
-
#
|
783
|
-
#
|
784
|
-
#
|
785
|
-
#
|
786
|
-
#
|
787
|
-
#
|
788
|
-
#
|
789
|
-
#
|
790
|
-
#
|
791
|
-
#
|
792
|
-
#
|
793
|
-
# end_date:,
|
794
|
-
# start_date:,
|
795
|
-
# discount_type: :amount,
|
796
|
-
# **
|
797
|
-
# )
|
798
|
-
# super
|
799
|
-
# end
|
800
|
-
|
801
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
770
|
+
# @!method initialize(amount_discount:, applies_to_price_ids:, applies_to_price_interval_ids:, end_date:, start_date:, discount_type: :amount)
|
771
|
+
# @param amount_discount [String] Only available if discount_type is `amount`.
|
772
|
+
#
|
773
|
+
# @param applies_to_price_ids [Array<String>] The price ids that this discount interval applies to.
|
774
|
+
#
|
775
|
+
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this discount interval applies to.
|
776
|
+
#
|
777
|
+
# @param end_date [Time, nil] The end date of the discount interval.
|
778
|
+
#
|
779
|
+
# @param start_date [Time] The start date of the discount interval.
|
780
|
+
#
|
781
|
+
# @param discount_type [Symbol, :amount]
|
802
782
|
end
|
803
783
|
|
804
|
-
class
|
784
|
+
class Percentage < Orb::Internal::Type::BaseModel
|
805
785
|
# @!attribute applies_to_price_ids
|
806
786
|
# The price ids that this discount interval applies to.
|
807
787
|
#
|
@@ -838,30 +818,25 @@ module Orb
|
|
838
818
|
# @return [Time]
|
839
819
|
required :start_date, Time
|
840
820
|
|
841
|
-
# @!
|
842
|
-
#
|
843
|
-
#
|
844
|
-
#
|
845
|
-
#
|
846
|
-
#
|
847
|
-
#
|
848
|
-
#
|
849
|
-
#
|
850
|
-
#
|
851
|
-
#
|
852
|
-
#
|
853
|
-
#
|
854
|
-
#
|
855
|
-
#
|
856
|
-
#
|
857
|
-
# )
|
858
|
-
# super
|
859
|
-
# end
|
860
|
-
|
861
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
821
|
+
# @!method initialize(applies_to_price_ids:, applies_to_price_interval_ids:, end_date:, percentage_discount:, start_date:, discount_type: :percentage)
|
822
|
+
# Some parameter documentations has been truncated, see
|
823
|
+
# {Orb::Models::Subscription::DiscountInterval::Percentage} for more details.
|
824
|
+
#
|
825
|
+
# @param applies_to_price_ids [Array<String>] The price ids that this discount interval applies to.
|
826
|
+
#
|
827
|
+
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this discount interval applies to.
|
828
|
+
#
|
829
|
+
# @param end_date [Time, nil] The end date of the discount interval.
|
830
|
+
#
|
831
|
+
# @param percentage_discount [Float] Only available if discount_type is `percentage`.This is a number between 0 and 1
|
832
|
+
# ...
|
833
|
+
#
|
834
|
+
# @param start_date [Time] The start date of the discount interval.
|
835
|
+
#
|
836
|
+
# @param discount_type [Symbol, :percentage]
|
862
837
|
end
|
863
838
|
|
864
|
-
class
|
839
|
+
class Usage < Orb::Internal::Type::BaseModel
|
865
840
|
# @!attribute applies_to_price_ids
|
866
841
|
# The price ids that this discount interval applies to.
|
867
842
|
#
|
@@ -898,32 +873,26 @@ module Orb
|
|
898
873
|
# @return [Float]
|
899
874
|
required :usage_discount, Float
|
900
875
|
|
901
|
-
# @!
|
902
|
-
#
|
903
|
-
#
|
904
|
-
#
|
905
|
-
#
|
906
|
-
#
|
907
|
-
#
|
908
|
-
#
|
909
|
-
#
|
910
|
-
#
|
911
|
-
#
|
912
|
-
#
|
913
|
-
#
|
914
|
-
#
|
915
|
-
#
|
916
|
-
#
|
917
|
-
# )
|
918
|
-
# super
|
919
|
-
# end
|
920
|
-
|
921
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
876
|
+
# @!method initialize(applies_to_price_ids:, applies_to_price_interval_ids:, end_date:, start_date:, usage_discount:, discount_type: :usage)
|
877
|
+
# Some parameter documentations has been truncated, see
|
878
|
+
# {Orb::Models::Subscription::DiscountInterval::Usage} for more details.
|
879
|
+
#
|
880
|
+
# @param applies_to_price_ids [Array<String>] The price ids that this discount interval applies to.
|
881
|
+
#
|
882
|
+
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this discount interval applies to.
|
883
|
+
#
|
884
|
+
# @param end_date [Time, nil] The end date of the discount interval.
|
885
|
+
#
|
886
|
+
# @param start_date [Time] The start date of the discount interval.
|
887
|
+
#
|
888
|
+
# @param usage_discount [Float] Only available if discount_type is `usage`. Number of usage units that this disc
|
889
|
+
# ...
|
890
|
+
#
|
891
|
+
# @param discount_type [Symbol, :usage]
|
922
892
|
end
|
923
893
|
|
924
|
-
# @!
|
925
|
-
#
|
926
|
-
# def self.variants; end
|
894
|
+
# @!method self.variants
|
895
|
+
# @return [Array(Orb::Models::Subscription::DiscountInterval::Amount, Orb::Models::Subscription::DiscountInterval::Percentage, Orb::Models::Subscription::DiscountInterval::Usage)]
|
927
896
|
end
|
928
897
|
|
929
898
|
class FixedFeeQuantitySchedule < Orb::Internal::Type::BaseModel
|
@@ -947,15 +916,11 @@ module Orb
|
|
947
916
|
# @return [Time]
|
948
917
|
required :start_date, Time
|
949
918
|
|
950
|
-
# @!
|
951
|
-
#
|
952
|
-
#
|
953
|
-
#
|
954
|
-
#
|
955
|
-
# #
|
956
|
-
# def initialize(end_date:, price_id:, quantity:, start_date:, **) = super
|
957
|
-
|
958
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
919
|
+
# @!method initialize(end_date:, price_id:, quantity:, start_date:)
|
920
|
+
# @param end_date [Time, nil]
|
921
|
+
# @param price_id [String]
|
922
|
+
# @param quantity [Float]
|
923
|
+
# @param start_date [Time]
|
959
924
|
end
|
960
925
|
|
961
926
|
class MaximumInterval < Orb::Internal::Type::BaseModel
|
@@ -990,16 +955,20 @@ module Orb
|
|
990
955
|
# @return [Time]
|
991
956
|
required :start_date, Time
|
992
957
|
|
993
|
-
# @!
|
994
|
-
#
|
995
|
-
#
|
996
|
-
#
|
997
|
-
#
|
998
|
-
#
|
999
|
-
#
|
1000
|
-
#
|
1001
|
-
|
1002
|
-
#
|
958
|
+
# @!method initialize(applies_to_price_ids:, applies_to_price_interval_ids:, end_date:, maximum_amount:, start_date:)
|
959
|
+
# Some parameter documentations has been truncated, see
|
960
|
+
# {Orb::Models::Subscription::MaximumInterval} for more details.
|
961
|
+
#
|
962
|
+
# @param applies_to_price_ids [Array<String>] The price ids that this maximum interval applies to.
|
963
|
+
#
|
964
|
+
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this maximum interval applies to.
|
965
|
+
#
|
966
|
+
# @param end_date [Time, nil] The end date of the maximum interval.
|
967
|
+
#
|
968
|
+
# @param maximum_amount [String] The maximum amount to charge in a given billing period for the price intervals t
|
969
|
+
# ...
|
970
|
+
#
|
971
|
+
# @param start_date [Time] The start date of the maximum interval.
|
1003
972
|
end
|
1004
973
|
|
1005
974
|
class MinimumInterval < Orb::Internal::Type::BaseModel
|
@@ -1034,16 +1003,20 @@ module Orb
|
|
1034
1003
|
# @return [Time]
|
1035
1004
|
required :start_date, Time
|
1036
1005
|
|
1037
|
-
# @!
|
1038
|
-
#
|
1039
|
-
#
|
1040
|
-
#
|
1041
|
-
#
|
1042
|
-
#
|
1043
|
-
#
|
1044
|
-
#
|
1045
|
-
|
1046
|
-
#
|
1006
|
+
# @!method initialize(applies_to_price_ids:, applies_to_price_interval_ids:, end_date:, minimum_amount:, start_date:)
|
1007
|
+
# Some parameter documentations has been truncated, see
|
1008
|
+
# {Orb::Models::Subscription::MinimumInterval} for more details.
|
1009
|
+
#
|
1010
|
+
# @param applies_to_price_ids [Array<String>] The price ids that this minimum interval applies to.
|
1011
|
+
#
|
1012
|
+
# @param applies_to_price_interval_ids [Array<String>] The price interval ids that this minimum interval applies to.
|
1013
|
+
#
|
1014
|
+
# @param end_date [Time, nil] The end date of the minimum interval.
|
1015
|
+
#
|
1016
|
+
# @param minimum_amount [String] The minimum amount to charge in a given billing period for the price intervals t
|
1017
|
+
# ...
|
1018
|
+
#
|
1019
|
+
# @param start_date [Time] The start date of the minimum interval.
|
1047
1020
|
end
|
1048
1021
|
|
1049
1022
|
# @see Orb::Models::Subscription#pending_subscription_change
|
@@ -1053,14 +1026,10 @@ module Orb
|
|
1053
1026
|
# @return [String]
|
1054
1027
|
required :id, String
|
1055
1028
|
|
1056
|
-
# @!
|
1057
|
-
#
|
1058
|
-
#
|
1059
|
-
#
|
1060
|
-
# #
|
1061
|
-
# def initialize(id:, **) = super
|
1062
|
-
|
1063
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
1029
|
+
# @!method initialize(id:)
|
1030
|
+
# A pending subscription change if one exists on this subscription.
|
1031
|
+
#
|
1032
|
+
# @param id [String]
|
1064
1033
|
end
|
1065
1034
|
|
1066
1035
|
class PriceInterval < Orb::Internal::Type::BaseModel
|
@@ -1125,7 +1094,7 @@ module Orb
|
|
1125
1094
|
# For more on the types of prices, see
|
1126
1095
|
# [the core concepts documentation](/core-concepts#plan-and-price)
|
1127
1096
|
#
|
1128
|
-
# @return [Orb::Models::Price::
|
1097
|
+
# @return [Orb::Models::Price::Unit, Orb::Models::Price::Package, Orb::Models::Price::Matrix, Orb::Models::Price::Tiered, Orb::Models::Price::TieredBps, Orb::Models::Price::Bps, Orb::Models::Price::BulkBps, Orb::Models::Price::Bulk, Orb::Models::Price::ThresholdTotalAmount, Orb::Models::Price::TieredPackage, Orb::Models::Price::GroupedTiered, Orb::Models::Price::TieredWithMinimum, Orb::Models::Price::TieredPackageWithMinimum, Orb::Models::Price::PackageWithAllocation, Orb::Models::Price::UnitWithPercent, Orb::Models::Price::MatrixWithAllocation, Orb::Models::Price::TieredWithProration, Orb::Models::Price::UnitWithProration, Orb::Models::Price::GroupedAllocation, Orb::Models::Price::GroupedWithProratedMinimum, Orb::Models::Price::GroupedWithMeteredMinimum, Orb::Models::Price::MatrixWithDisplayName, Orb::Models::Price::BulkWithProration, Orb::Models::Price::GroupedTieredPackage, Orb::Models::Price::MaxGroupTieredPackage, Orb::Models::Price::ScalableMatrixWithUnitPricing, Orb::Models::Price::ScalableMatrixWithTieredPricing, Orb::Models::Price::CumulativeGroupedBulk]
|
1129
1098
|
required :price, union: -> { Orb::Models::Price }
|
1130
1099
|
|
1131
1100
|
# @!attribute start_date
|
@@ -1142,39 +1111,40 @@ module Orb
|
|
1142
1111
|
# @return [Array<String>, nil]
|
1143
1112
|
required :usage_customer_ids, Orb::Internal::Type::ArrayOf[String], nil?: true
|
1144
1113
|
|
1145
|
-
# @!
|
1146
|
-
#
|
1147
|
-
#
|
1148
|
-
#
|
1149
|
-
#
|
1150
|
-
#
|
1151
|
-
#
|
1152
|
-
#
|
1153
|
-
#
|
1154
|
-
#
|
1155
|
-
#
|
1156
|
-
#
|
1157
|
-
#
|
1158
|
-
#
|
1159
|
-
#
|
1160
|
-
#
|
1161
|
-
#
|
1162
|
-
#
|
1163
|
-
#
|
1164
|
-
#
|
1165
|
-
#
|
1166
|
-
#
|
1167
|
-
#
|
1168
|
-
#
|
1169
|
-
#
|
1170
|
-
#
|
1171
|
-
#
|
1172
|
-
#
|
1173
|
-
#
|
1174
|
-
#
|
1175
|
-
#
|
1176
|
-
|
1177
|
-
#
|
1114
|
+
# @!method initialize(id:, billing_cycle_day:, current_billing_period_end_date:, current_billing_period_start_date:, end_date:, filter:, fixed_fee_quantity_transitions:, price:, start_date:, usage_customer_ids:)
|
1115
|
+
# Some parameter documentations has been truncated, see
|
1116
|
+
# {Orb::Models::Subscription::PriceInterval} for more details.
|
1117
|
+
#
|
1118
|
+
# The Price Interval resource represents a period of time for which a price will
|
1119
|
+
# bill on a subscription. A subscription’s price intervals define its billing
|
1120
|
+
# behavior.
|
1121
|
+
#
|
1122
|
+
# @param id [String]
|
1123
|
+
#
|
1124
|
+
# @param billing_cycle_day [Integer] The day of the month that Orb bills for this price
|
1125
|
+
#
|
1126
|
+
# @param current_billing_period_end_date [Time, nil] The end of the current billing period. This is an exclusive timestamp, such that
|
1127
|
+
# ...
|
1128
|
+
#
|
1129
|
+
# @param current_billing_period_start_date [Time, nil] The start date of the current billing period. This is an inclusive timestamp; th
|
1130
|
+
# ...
|
1131
|
+
#
|
1132
|
+
# @param end_date [Time, nil] The end date of the price interval. This is the date that Orb stops billing for
|
1133
|
+
# ...
|
1134
|
+
#
|
1135
|
+
# @param filter [String, nil] An additional filter to apply to usage queries.
|
1136
|
+
#
|
1137
|
+
# @param fixed_fee_quantity_transitions [Array<Orb::Models::Subscription::PriceInterval::FixedFeeQuantityTransition>, nil] The fixed fee quantity transitions for this price interval. This is only relevan
|
1138
|
+
# ...
|
1139
|
+
#
|
1140
|
+
# @param price [Orb::Models::Price::Unit, Orb::Models::Price::Package, Orb::Models::Price::Matrix, Orb::Models::Price::Tiered, Orb::Models::Price::TieredBps, Orb::Models::Price::Bps, Orb::Models::Price::BulkBps, Orb::Models::Price::Bulk, Orb::Models::Price::ThresholdTotalAmount, Orb::Models::Price::TieredPackage, Orb::Models::Price::GroupedTiered, Orb::Models::Price::TieredWithMinimum, Orb::Models::Price::TieredPackageWithMinimum, Orb::Models::Price::PackageWithAllocation, Orb::Models::Price::UnitWithPercent, Orb::Models::Price::MatrixWithAllocation, Orb::Models::Price::TieredWithProration, Orb::Models::Price::UnitWithProration, Orb::Models::Price::GroupedAllocation, Orb::Models::Price::GroupedWithProratedMinimum, Orb::Models::Price::GroupedWithMeteredMinimum, Orb::Models::Price::MatrixWithDisplayName, Orb::Models::Price::BulkWithProration, Orb::Models::Price::GroupedTieredPackage, Orb::Models::Price::MaxGroupTieredPackage, Orb::Models::Price::ScalableMatrixWithUnitPricing, Orb::Models::Price::ScalableMatrixWithTieredPricing, Orb::Models::Price::CumulativeGroupedBulk] The Price resource represents a price that can be billed on a subscription, resu
|
1141
|
+
# ...
|
1142
|
+
#
|
1143
|
+
# @param start_date [Time] The start date of the price interval. This is the date that Orb starts billing f
|
1144
|
+
# ...
|
1145
|
+
#
|
1146
|
+
# @param usage_customer_ids [Array<String>, nil] A list of customer IDs whose usage events will be aggregated and billed under th
|
1147
|
+
# ...
|
1178
1148
|
|
1179
1149
|
class FixedFeeQuantityTransition < Orb::Internal::Type::BaseModel
|
1180
1150
|
# @!attribute effective_date
|
@@ -1192,14 +1162,10 @@ module Orb
|
|
1192
1162
|
# @return [Integer]
|
1193
1163
|
required :quantity, Integer
|
1194
1164
|
|
1195
|
-
# @!
|
1196
|
-
#
|
1197
|
-
#
|
1198
|
-
#
|
1199
|
-
# #
|
1200
|
-
# def initialize(effective_date:, price_id:, quantity:, **) = super
|
1201
|
-
|
1202
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
1165
|
+
# @!method initialize(effective_date:, price_id:, quantity:)
|
1166
|
+
# @param effective_date [Time]
|
1167
|
+
# @param price_id [String]
|
1168
|
+
# @param quantity [Integer]
|
1203
1169
|
end
|
1204
1170
|
end
|
1205
1171
|
|
@@ -1220,14 +1186,10 @@ module Orb
|
|
1220
1186
|
# @return [Time]
|
1221
1187
|
required :start_date, Time
|
1222
1188
|
|
1223
|
-
# @!
|
1224
|
-
#
|
1225
|
-
#
|
1226
|
-
#
|
1227
|
-
# #
|
1228
|
-
# def initialize(coupon_id:, end_date:, start_date:, **) = super
|
1229
|
-
|
1230
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
1189
|
+
# @!method initialize(coupon_id:, end_date:, start_date:)
|
1190
|
+
# @param coupon_id [String]
|
1191
|
+
# @param end_date [Time, nil]
|
1192
|
+
# @param start_date [Time]
|
1231
1193
|
end
|
1232
1194
|
|
1233
1195
|
# @see Orb::Models::Subscription#status
|
@@ -1238,11 +1200,8 @@ module Orb
|
|
1238
1200
|
ENDED = :ended
|
1239
1201
|
UPCOMING = :upcoming
|
1240
1202
|
|
1241
|
-
|
1242
|
-
|
1243
|
-
# @!parse
|
1244
|
-
# # @return [Array<Symbol>]
|
1245
|
-
# def self.values; end
|
1203
|
+
# @!method self.values
|
1204
|
+
# @return [Array<Symbol>]
|
1246
1205
|
end
|
1247
1206
|
|
1248
1207
|
# @see Orb::Models::Subscription#trial_info
|
@@ -1252,12 +1211,8 @@ module Orb
|
|
1252
1211
|
# @return [Time, nil]
|
1253
1212
|
required :end_date, Time, nil?: true
|
1254
1213
|
|
1255
|
-
# @!
|
1256
|
-
#
|
1257
|
-
# #
|
1258
|
-
# def initialize(end_date:, **) = super
|
1259
|
-
|
1260
|
-
# def initialize: (Hash | Orb::Internal::Type::BaseModel) -> void
|
1214
|
+
# @!method initialize(end_date:)
|
1215
|
+
# @param end_date [Time, nil]
|
1261
1216
|
end
|
1262
1217
|
end
|
1263
1218
|
end
|