orb-billing 0.3.1 → 0.3.2
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 +14 -0
- data/README.md +3 -3
- data/lib/orb/file_part.rb +2 -2
- data/lib/orb/internal/type/enum.rb +3 -3
- data/lib/orb/internal/type/request_parameters.rb +4 -4
- data/lib/orb/internal/type/union.rb +4 -4
- data/lib/orb/internal/util.rb +1 -1
- data/lib/orb/models/alert.rb +29 -32
- data/lib/orb/models/alert_create_for_customer_params.rb +7 -8
- data/lib/orb/models/alert_create_for_external_customer_params.rb +7 -8
- data/lib/orb/models/alert_create_for_subscription_params.rb +7 -8
- data/lib/orb/models/alert_list_params.rb +0 -1
- data/lib/orb/models/alert_update_params.rb +4 -5
- data/lib/orb/models/amount_discount.rb +6 -7
- data/lib/orb/models/billable_metric.rb +9 -11
- data/lib/orb/models/coupon.rb +9 -12
- data/lib/orb/models/coupon_create_params.rb +6 -8
- data/lib/orb/models/coupon_list_params.rb +0 -2
- data/lib/orb/models/coupons/subscription_list_params.rb +0 -1
- data/lib/orb/models/credit_note.rb +48 -46
- data/lib/orb/models/credit_note_create_params.rb +6 -6
- data/lib/orb/models/credit_note_list_params.rb +0 -1
- data/lib/orb/models/customer.rb +54 -61
- data/lib/orb/models/customer_create_params.rb +41 -53
- data/lib/orb/models/customer_list_params.rb +0 -1
- data/lib/orb/models/customer_update_by_external_id_params.rb +41 -53
- data/lib/orb/models/customer_update_params.rb +41 -51
- data/lib/orb/models/customers/balance_transaction_create_params.rb +3 -3
- data/lib/orb/models/customers/balance_transaction_create_response.rb +0 -2
- data/lib/orb/models/customers/balance_transaction_list_params.rb +0 -1
- data/lib/orb/models/customers/balance_transaction_list_response.rb +0 -2
- data/lib/orb/models/customers/cost_list_by_external_id_params.rb +3 -4
- data/lib/orb/models/customers/cost_list_by_external_id_response.rb +3 -3
- data/lib/orb/models/customers/cost_list_params.rb +3 -4
- data/lib/orb/models/customers/cost_list_response.rb +3 -3
- data/lib/orb/models/customers/credit_list_by_external_id_params.rb +0 -2
- data/lib/orb/models/customers/credit_list_params.rb +0 -2
- data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb +12 -21
- data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rb +0 -7
- data/lib/orb/models/customers/credits/ledger_create_entry_params.rb +11 -22
- data/lib/orb/models/customers/credits/ledger_create_entry_response.rb +0 -7
- data/lib/orb/models/customers/credits/ledger_list_by_external_id_params.rb +6 -7
- data/lib/orb/models/customers/credits/ledger_list_by_external_id_response.rb +0 -7
- data/lib/orb/models/customers/credits/ledger_list_params.rb +8 -9
- data/lib/orb/models/customers/credits/ledger_list_response.rb +0 -7
- data/lib/orb/models/customers/credits/top_up_create_by_external_id_params.rb +10 -15
- data/lib/orb/models/customers/credits/top_up_create_by_external_id_response.rb +0 -6
- data/lib/orb/models/customers/credits/top_up_create_params.rb +7 -15
- data/lib/orb/models/customers/credits/top_up_create_response.rb +0 -6
- data/lib/orb/models/customers/credits/top_up_list_by_external_id_params.rb +0 -1
- data/lib/orb/models/customers/credits/top_up_list_by_external_id_response.rb +0 -6
- data/lib/orb/models/customers/credits/top_up_list_params.rb +0 -1
- data/lib/orb/models/customers/credits/top_up_list_response.rb +0 -6
- data/lib/orb/models/dimensional_price_group.rb +1 -3
- data/lib/orb/models/dimensional_price_group_create_params.rb +0 -1
- data/lib/orb/models/dimensional_price_group_list_params.rb +0 -1
- data/lib/orb/models/dimensional_price_groups.rb +6 -6
- data/lib/orb/models/discount.rb +5 -5
- data/lib/orb/models/evaluate_price_group.rb +1 -1
- data/lib/orb/models/event_ingest_params.rb +4 -9
- data/lib/orb/models/event_ingest_response.rb +0 -3
- data/lib/orb/models/event_search_params.rb +0 -3
- data/lib/orb/models/event_search_response.rb +0 -4
- data/lib/orb/models/event_update_params.rb +0 -3
- data/lib/orb/models/events/backfill_close_response.rb +0 -4
- data/lib/orb/models/events/backfill_create_params.rb +0 -7
- data/lib/orb/models/events/backfill_create_response.rb +0 -4
- data/lib/orb/models/events/backfill_fetch_response.rb +0 -4
- data/lib/orb/models/events/backfill_list_params.rb +0 -1
- data/lib/orb/models/events/backfill_list_response.rb +0 -4
- data/lib/orb/models/events/backfill_revert_response.rb +0 -4
- data/lib/orb/models/events/event_volumes.rb +3 -3
- data/lib/orb/models/events/volume_list_params.rb +0 -3
- data/lib/orb/models/invoice.rb +157 -202
- data/lib/orb/models/invoice_create_params.rb +14 -21
- data/lib/orb/models/invoice_fetch_upcoming_response.rb +9 -54
- data/lib/orb/models/invoice_issue_params.rb +0 -1
- data/lib/orb/models/invoice_level_discount.rb +4 -4
- data/lib/orb/models/invoice_line_item_create_params.rb +0 -1
- data/lib/orb/models/invoice_line_item_create_response.rb +6 -26
- data/lib/orb/models/invoice_list_params.rb +6 -10
- data/lib/orb/models/invoice_update_params.rb +0 -1
- data/lib/orb/models/item.rb +7 -8
- data/lib/orb/models/item_list_params.rb +0 -1
- data/lib/orb/models/item_update_params.rb +7 -7
- data/lib/orb/models/metric_create_params.rb +0 -1
- data/lib/orb/models/metric_list_params.rb +0 -1
- data/lib/orb/models/metric_update_params.rb +0 -1
- data/lib/orb/models/percentage_discount.rb +6 -8
- data/lib/orb/models/plan.rb +78 -103
- data/lib/orb/models/plan_create_params.rb +727 -800
- data/lib/orb/models/plan_list_params.rb +3 -4
- data/lib/orb/models/plan_update_params.rb +0 -2
- data/lib/orb/models/plans/external_plan_id_update_params.rb +0 -2
- data/lib/orb/models/price.rb +1671 -1724
- data/lib/orb/models/price_create_params.rb +75 -84
- data/lib/orb/models/price_evaluate_params.rb +0 -2
- data/lib/orb/models/price_evaluate_response.rb +3 -3
- data/lib/orb/models/price_list_params.rb +0 -1
- data/lib/orb/models/price_update_params.rb +0 -1
- data/lib/orb/models/prices/external_price_id_update_params.rb +0 -1
- data/lib/orb/models/subscription.rb +86 -122
- data/lib/orb/models/subscription_cancel_params.rb +3 -5
- data/lib/orb/models/subscription_cancel_response.rb +21 -57
- data/lib/orb/models/subscription_change_apply_response.rb +21 -58
- data/lib/orb/models/subscription_change_cancel_response.rb +21 -58
- data/lib/orb/models/subscription_change_retrieve_response.rb +21 -58
- data/lib/orb/models/subscription_create_params.rb +1865 -1815
- data/lib/orb/models/subscription_create_response.rb +21 -57
- data/lib/orb/models/subscription_fetch_costs_params.rb +3 -4
- data/lib/orb/models/subscription_fetch_costs_response.rb +3 -3
- data/lib/orb/models/subscription_fetch_schedule_params.rb +0 -1
- data/lib/orb/models/subscription_fetch_schedule_response.rb +0 -1
- data/lib/orb/models/subscription_fetch_usage_params.rb +6 -8
- data/lib/orb/models/subscription_list_params.rb +3 -4
- data/lib/orb/models/subscription_price_intervals_params.rb +1105 -1017
- data/lib/orb/models/subscription_price_intervals_response.rb +21 -57
- data/lib/orb/models/subscription_schedule_plan_change_params.rb +1906 -1791
- data/lib/orb/models/subscription_schedule_plan_change_response.rb +21 -57
- data/lib/orb/models/subscription_trigger_phase_params.rb +0 -2
- data/lib/orb/models/subscription_trigger_phase_response.rb +21 -57
- data/lib/orb/models/subscription_unschedule_cancellation_response.rb +21 -57
- data/lib/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rb +21 -57
- data/lib/orb/models/subscription_unschedule_pending_plan_changes_response.rb +21 -57
- data/lib/orb/models/subscription_update_fixed_fee_quantity_params.rb +3 -6
- data/lib/orb/models/subscription_update_fixed_fee_quantity_response.rb +21 -57
- data/lib/orb/models/subscription_update_params.rb +0 -5
- data/lib/orb/models/subscription_update_trial_params.rb +4 -6
- data/lib/orb/models/subscription_update_trial_response.rb +21 -57
- data/lib/orb/models/subscription_usage.rb +46 -39
- data/lib/orb/models/subscriptions.rb +6 -6
- data/lib/orb/models/trial_discount.rb +6 -7
- data/lib/orb/models/usage_discount.rb +6 -8
- data/lib/orb/resources/alerts.rb +30 -31
- data/lib/orb/resources/coupons/subscriptions.rb +3 -4
- data/lib/orb/resources/coupons.rb +11 -21
- data/lib/orb/resources/credit_notes.rb +10 -11
- data/lib/orb/resources/customers/balance_transactions.rb +3 -4
- data/lib/orb/resources/customers/costs.rb +4 -6
- data/lib/orb/resources/customers/credits/ledger.rb +14 -33
- data/lib/orb/resources/customers/credits/top_ups.rb +10 -20
- data/lib/orb/resources/customers/credits.rb +2 -6
- data/lib/orb/resources/customers.rb +40 -67
- data/lib/orb/resources/dimensional_price_groups/external_dimensional_price_group_id.rb +2 -2
- data/lib/orb/resources/dimensional_price_groups.rb +8 -10
- data/lib/orb/resources/events/backfills.rb +2 -10
- data/lib/orb/resources/events/volume.rb +3 -6
- data/lib/orb/resources/events.rb +4 -12
- data/lib/orb/resources/invoice_line_items.rb +1 -2
- data/lib/orb/resources/invoices.rb +26 -43
- data/lib/orb/resources/items.rb +12 -13
- data/lib/orb/resources/metrics.rb +11 -14
- data/lib/orb/resources/plans/external_plan_id.rb +5 -7
- data/lib/orb/resources/plans.rb +14 -23
- data/lib/orb/resources/prices/external_price_id.rb +5 -6
- data/lib/orb/resources/prices.rb +25 -35
- data/lib/orb/resources/subscription_changes.rb +1 -1
- data/lib/orb/resources/subscriptions.rb +49 -107
- data/lib/orb/version.rb +1 -1
- data/lib/orb.rb +1 -0
- data/rbi/orb/client.rbi +5 -4
- data/rbi/orb/errors.rbi +59 -28
- data/rbi/orb/file_part.rbi +9 -6
- data/rbi/orb/internal/page.rbi +19 -6
- data/rbi/orb/internal/transport/base_client.rbi +131 -73
- data/rbi/orb/internal/transport/pooled_net_requester.rbi +25 -12
- data/rbi/orb/internal/type/array_of.rbi +42 -34
- data/rbi/orb/internal/type/base_model.rbi +124 -65
- data/rbi/orb/internal/type/base_page.rbi +11 -7
- data/rbi/orb/internal/type/boolean.rbi +16 -10
- data/rbi/orb/internal/type/converter.rbi +66 -31
- data/rbi/orb/internal/type/enum.rbi +27 -15
- data/rbi/orb/internal/type/file_input.rbi +12 -10
- data/rbi/orb/internal/type/hash_of.rbi +34 -24
- data/rbi/orb/internal/type/request_parameters.rbi +12 -4
- data/rbi/orb/internal/type/union.rbi +60 -25
- data/rbi/orb/internal/type/unknown.rbi +20 -12
- data/rbi/orb/internal/util.rbi +210 -89
- data/rbi/orb/models/alert.rbi +107 -70
- data/rbi/orb/models/alert_create_for_customer_params.rbi +60 -27
- data/rbi/orb/models/alert_create_for_external_customer_params.rbi +68 -29
- data/rbi/orb/models/alert_create_for_subscription_params.rbi +53 -26
- data/rbi/orb/models/alert_disable_params.rbi +17 -6
- data/rbi/orb/models/alert_enable_params.rbi +17 -6
- data/rbi/orb/models/alert_list_params.rbi +23 -20
- data/rbi/orb/models/alert_retrieve_params.rbi +10 -4
- data/rbi/orb/models/alert_update_params.rbi +25 -14
- data/rbi/orb/models/amount_discount.rbi +28 -19
- data/rbi/orb/models/billable_metric.rbi +33 -26
- data/rbi/orb/models/billing_cycle_relative_date.rbi +11 -5
- data/rbi/orb/models/coupon.rbi +28 -20
- data/rbi/orb/models/coupon_archive_params.rbi +10 -4
- data/rbi/orb/models/coupon_create_params.rbi +72 -38
- data/rbi/orb/models/coupon_fetch_params.rbi +10 -4
- data/rbi/orb/models/coupon_list_params.rbi +18 -15
- data/rbi/orb/models/coupons/subscription_list_params.rbi +16 -6
- data/rbi/orb/models/credit_note.rbi +293 -158
- data/rbi/orb/models/credit_note_create_params.rbi +58 -29
- data/rbi/orb/models/credit_note_fetch_params.rbi +10 -4
- data/rbi/orb/models/credit_note_list_params.rbi +20 -17
- data/rbi/orb/models/customer.rbi +430 -329
- data/rbi/orb/models/customer_create_params.rbi +662 -325
- data/rbi/orb/models/customer_delete_params.rbi +10 -4
- data/rbi/orb/models/customer_fetch_by_external_id_params.rbi +10 -4
- data/rbi/orb/models/customer_fetch_params.rbi +10 -4
- data/rbi/orb/models/customer_list_params.rbi +20 -17
- data/rbi/orb/models/customer_sync_payment_methods_from_gateway_by_external_customer_id_params.rbi +10 -4
- data/rbi/orb/models/customer_sync_payment_methods_from_gateway_params.rbi +10 -4
- data/rbi/orb/models/customer_update_by_external_id_params.rbi +1136 -336
- data/rbi/orb/models/customer_update_params.rbi +661 -324
- data/rbi/orb/models/customers/balance_transaction_create_params.rbi +50 -21
- data/rbi/orb/models/customers/balance_transaction_create_response.rbi +154 -61
- data/rbi/orb/models/customers/balance_transaction_list_params.rbi +20 -17
- data/rbi/orb/models/customers/balance_transaction_list_response.rbi +164 -59
- data/rbi/orb/models/customers/cost_list_by_external_id_params.rbi +56 -22
- data/rbi/orb/models/customers/cost_list_by_external_id_response.rbi +162 -124
- data/rbi/orb/models/customers/cost_list_params.rbi +45 -22
- data/rbi/orb/models/customers/cost_list_response.rbi +154 -123
- data/rbi/orb/models/customers/credit_list_by_external_id_params.rbi +18 -15
- data/rbi/orb/models/customers/credit_list_by_external_id_response.rbi +48 -22
- data/rbi/orb/models/customers/credit_list_params.rbi +18 -15
- data/rbi/orb/models/customers/credit_list_response.rbi +44 -21
- data/rbi/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rbi +106 -68
- data/rbi/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbi +643 -434
- data/rbi/orb/models/customers/credits/ledger_create_entry_params.rbi +117 -59
- data/rbi/orb/models/customers/credits/ledger_create_entry_response.rbi +700 -425
- data/rbi/orb/models/customers/credits/ledger_list_by_external_id_params.rbi +102 -44
- data/rbi/orb/models/customers/credits/ledger_list_by_external_id_response.rbi +681 -432
- data/rbi/orb/models/customers/credits/ledger_list_params.rbi +123 -40
- data/rbi/orb/models/customers/credits/ledger_list_response.rbi +735 -389
- data/rbi/orb/models/customers/credits/top_up_create_by_external_id_params.rbi +74 -53
- data/rbi/orb/models/customers/credits/top_up_create_by_external_id_response.rbi +65 -48
- data/rbi/orb/models/customers/credits/top_up_create_params.rbi +84 -45
- data/rbi/orb/models/customers/credits/top_up_create_response.rbi +83 -43
- data/rbi/orb/models/customers/credits/top_up_delete_by_external_id_params.rbi +16 -6
- data/rbi/orb/models/customers/credits/top_up_delete_params.rbi +15 -5
- data/rbi/orb/models/customers/credits/top_up_list_by_external_id_params.rbi +9 -5
- data/rbi/orb/models/customers/credits/top_up_list_by_external_id_response.rbi +70 -49
- data/rbi/orb/models/customers/credits/top_up_list_params.rbi +9 -5
- data/rbi/orb/models/customers/credits/top_up_list_response.rbi +84 -43
- data/rbi/orb/models/dimensional_price_group.rbi +18 -15
- data/rbi/orb/models/dimensional_price_group_create_params.rbi +19 -16
- data/rbi/orb/models/dimensional_price_group_list_params.rbi +16 -6
- data/rbi/orb/models/dimensional_price_group_retrieve_params.rbi +10 -4
- data/rbi/orb/models/dimensional_price_groups/external_dimensional_price_group_id_retrieve_params.rbi +10 -9
- data/rbi/orb/models/dimensional_price_groups.rbi +18 -13
- data/rbi/orb/models/discount.rbi +11 -5
- data/rbi/orb/models/evaluate_price_group.rbi +28 -12
- data/rbi/orb/models/event_deprecate_params.rbi +10 -4
- data/rbi/orb/models/event_deprecate_response.rbi +8 -3
- data/rbi/orb/models/event_ingest_params.rbi +37 -31
- data/rbi/orb/models/event_ingest_response.rbi +63 -23
- data/rbi/orb/models/event_search_params.rbi +17 -14
- data/rbi/orb/models/event_search_response.rbi +33 -21
- data/rbi/orb/models/event_update_params.rbi +19 -16
- data/rbi/orb/models/event_update_response.rbi +8 -3
- data/rbi/orb/models/events/backfill_close_params.rbi +10 -9
- data/rbi/orb/models/events/backfill_close_response.rbi +64 -29
- data/rbi/orb/models/events/backfill_create_params.rbi +21 -18
- data/rbi/orb/models/events/backfill_create_response.rbi +63 -29
- data/rbi/orb/models/events/backfill_fetch_params.rbi +10 -9
- data/rbi/orb/models/events/backfill_fetch_response.rbi +64 -29
- data/rbi/orb/models/events/backfill_list_params.rbi +16 -6
- data/rbi/orb/models/events/backfill_list_response.rbi +62 -28
- data/rbi/orb/models/events/backfill_revert_params.rbi +10 -9
- data/rbi/orb/models/events/backfill_revert_response.rbi +63 -29
- data/rbi/orb/models/events/event_volumes.rbi +32 -10
- data/rbi/orb/models/events/volume_list_params.rbi +18 -15
- data/rbi/orb/models/invoice.rbi +1286 -805
- data/rbi/orb/models/invoice_create_params.rbi +97 -69
- data/rbi/orb/models/invoice_fetch_params.rbi +10 -4
- data/rbi/orb/models/invoice_fetch_upcoming_params.rbi +15 -5
- data/rbi/orb/models/invoice_fetch_upcoming_response.rbi +1991 -861
- data/rbi/orb/models/invoice_issue_params.rbi +16 -5
- data/rbi/orb/models/invoice_level_discount.rbi +11 -4
- data/rbi/orb/models/invoice_line_item_create_params.rbi +20 -17
- data/rbi/orb/models/invoice_line_item_create_response.rbi +573 -376
- data/rbi/orb/models/invoice_list_params.rbi +67 -47
- data/rbi/orb/models/invoice_mark_paid_params.rbi +17 -14
- data/rbi/orb/models/invoice_pay_params.rbi +10 -4
- data/rbi/orb/models/invoice_update_params.rbi +15 -10
- data/rbi/orb/models/invoice_void_params.rbi +10 -4
- data/rbi/orb/models/item.rbi +87 -39
- data/rbi/orb/models/item_create_params.rbi +14 -5
- data/rbi/orb/models/item_fetch_params.rbi +10 -4
- data/rbi/orb/models/item_list_params.rbi +16 -6
- data/rbi/orb/models/item_update_params.rbi +79 -39
- data/rbi/orb/models/metric_create_params.rbi +19 -16
- data/rbi/orb/models/metric_fetch_params.rbi +10 -4
- data/rbi/orb/models/metric_list_params.rbi +20 -17
- data/rbi/orb/models/metric_update_params.rbi +15 -10
- data/rbi/orb/models/pagination_metadata.rbi +16 -4
- data/rbi/orb/models/percentage_discount.rbi +32 -19
- data/rbi/orb/models/plan.rbi +496 -365
- data/rbi/orb/models/plan_create_params.rbi +4785 -2875
- data/rbi/orb/models/plan_fetch_params.rbi +10 -4
- data/rbi/orb/models/plan_list_params.rbi +34 -27
- data/rbi/orb/models/plan_update_params.rbi +16 -13
- data/rbi/orb/models/plans/external_plan_id_fetch_params.rbi +10 -9
- data/rbi/orb/models/plans/external_plan_id_update_params.rbi +16 -13
- data/rbi/orb/models/price.rbi +9969 -5024
- data/rbi/orb/models/price_create_params.rbi +501 -245
- data/rbi/orb/models/price_evaluate_params.rbi +20 -17
- data/rbi/orb/models/price_evaluate_response.rbi +11 -6
- data/rbi/orb/models/price_fetch_params.rbi +10 -4
- data/rbi/orb/models/price_list_params.rbi +16 -6
- data/rbi/orb/models/price_update_params.rbi +15 -10
- data/rbi/orb/models/prices/external_price_id_fetch_params.rbi +10 -9
- data/rbi/orb/models/prices/external_price_id_update_params.rbi +15 -10
- data/rbi/orb/models/subscription.rbi +578 -420
- data/rbi/orb/models/subscription_cancel_params.rbi +44 -22
- data/rbi/orb/models/subscription_cancel_response.rbi +700 -438
- data/rbi/orb/models/subscription_change_apply_params.rbi +16 -13
- data/rbi/orb/models/subscription_change_apply_response.rbi +784 -504
- data/rbi/orb/models/subscription_change_cancel_params.rbi +10 -4
- data/rbi/orb/models/subscription_change_cancel_response.rbi +783 -514
- data/rbi/orb/models/subscription_change_retrieve_params.rbi +10 -4
- data/rbi/orb/models/subscription_change_retrieve_response.rbi +782 -524
- data/rbi/orb/models/subscription_create_params.rbi +9021 -6730
- data/rbi/orb/models/subscription_create_response.rbi +700 -438
- data/rbi/orb/models/subscription_fetch_costs_params.rbi +47 -22
- data/rbi/orb/models/subscription_fetch_costs_response.rbi +154 -123
- data/rbi/orb/models/subscription_fetch_params.rbi +10 -4
- data/rbi/orb/models/subscription_fetch_schedule_params.rbi +20 -17
- data/rbi/orb/models/subscription_fetch_schedule_response.rbi +33 -19
- data/rbi/orb/models/subscription_fetch_usage_params.rbi +81 -34
- data/rbi/orb/models/subscription_list_params.rbi +39 -28
- data/rbi/orb/models/subscription_price_intervals_params.rbi +5181 -3822
- data/rbi/orb/models/subscription_price_intervals_response.rbi +720 -453
- data/rbi/orb/models/subscription_schedule_plan_change_params.rbi +8602 -6910
- data/rbi/orb/models/subscription_schedule_plan_change_response.rbi +718 -467
- data/rbi/orb/models/subscription_trigger_phase_params.rbi +16 -13
- data/rbi/orb/models/subscription_trigger_phase_response.rbi +712 -448
- data/rbi/orb/models/subscription_unschedule_cancellation_params.rbi +10 -4
- data/rbi/orb/models/subscription_unschedule_cancellation_response.rbi +719 -467
- data/rbi/orb/models/subscription_unschedule_fixed_fee_quantity_updates_params.rbi +16 -5
- data/rbi/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbi +693 -502
- data/rbi/orb/models/subscription_unschedule_pending_plan_changes_params.rbi +10 -4
- data/rbi/orb/models/subscription_unschedule_pending_plan_changes_response.rbi +708 -497
- data/rbi/orb/models/subscription_update_fixed_fee_quantity_params.rbi +57 -26
- data/rbi/orb/models/subscription_update_fixed_fee_quantity_response.rbi +719 -467
- data/rbi/orb/models/subscription_update_params.rbi +19 -16
- data/rbi/orb/models/subscription_update_trial_params.rbi +57 -19
- data/rbi/orb/models/subscription_update_trial_response.rbi +712 -447
- data/rbi/orb/models/subscription_usage.rbi +271 -121
- data/rbi/orb/models/subscriptions.rbi +18 -11
- data/rbi/orb/models/top_level_ping_params.rbi +10 -4
- data/rbi/orb/models/top_level_ping_response.rbi +7 -3
- data/rbi/orb/models/trial_discount.rbi +29 -20
- data/rbi/orb/models/usage_discount.rbi +28 -19
- data/rbi/orb/models.rbi +22 -11
- data/rbi/orb/request_options.rbi +12 -6
- data/rbi/orb/resources/alerts.rbi +61 -40
- data/rbi/orb/resources/coupons/subscriptions.rbi +7 -5
- data/rbi/orb/resources/coupons.rbi +33 -18
- data/rbi/orb/resources/credit_notes.rbi +22 -13
- data/rbi/orb/resources/customers/balance_transactions.rbi +17 -9
- data/rbi/orb/resources/customers/costs.rbi +18 -11
- data/rbi/orb/resources/customers/credits/ledger.rbi +98 -74
- data/rbi/orb/resources/customers/credits/top_ups.rbi +61 -25
- data/rbi/orb/resources/customers/credits.rbi +16 -7
- data/rbi/orb/resources/customers.rbi +137 -72
- data/rbi/orb/resources/dimensional_price_groups/external_dimensional_price_group_id.rbi +8 -4
- data/rbi/orb/resources/dimensional_price_groups.rbi +26 -12
- data/rbi/orb/resources/events/backfills.rbi +35 -17
- data/rbi/orb/resources/events/volume.rbi +7 -5
- data/rbi/orb/resources/events.rbi +26 -16
- data/rbi/orb/resources/invoice_line_items.rbi +7 -5
- data/rbi/orb/resources/invoices.rbi +72 -41
- data/rbi/orb/resources/items.rbi +40 -13
- data/rbi/orb/resources/metrics.rbi +25 -15
- data/rbi/orb/resources/plans/external_plan_id.rbi +15 -7
- data/rbi/orb/resources/plans.rbi +57 -47
- data/rbi/orb/resources/prices/external_price_id.rbi +73 -68
- data/rbi/orb/resources/prices.rbi +176 -156
- data/rbi/orb/resources/subscription_changes.rbi +19 -11
- data/rbi/orb/resources/subscriptions.rbi +200 -114
- data/rbi/orb/resources/top_level.rbi +9 -3
- data/sig/orb/internal/page.rbs +0 -2
- data/sig/orb/internal/type/request_parameters.rbs +3 -1
- data/sig/orb/models/alert.rbs +19 -31
- data/sig/orb/models/alert_create_for_customer_params.rbs +3 -7
- data/sig/orb/models/alert_create_for_external_customer_params.rbs +3 -7
- data/sig/orb/models/alert_create_for_subscription_params.rbs +3 -7
- data/sig/orb/models/alert_disable_params.rbs +0 -2
- data/sig/orb/models/alert_enable_params.rbs +0 -2
- data/sig/orb/models/alert_list_params.rbs +0 -2
- data/sig/orb/models/alert_retrieve_params.rbs +0 -2
- data/sig/orb/models/alert_update_params.rbs +3 -7
- data/sig/orb/models/amount_discount.rbs +4 -6
- data/sig/orb/models/billable_metric.rbs +7 -9
- data/sig/orb/models/coupon.rbs +5 -8
- data/sig/orb/models/coupon_archive_params.rbs +0 -2
- data/sig/orb/models/coupon_create_params.rbs +3 -9
- data/sig/orb/models/coupon_fetch_params.rbs +0 -2
- data/sig/orb/models/coupon_list_params.rbs +0 -2
- data/sig/orb/models/coupons/subscription_list_params.rbs +0 -2
- data/sig/orb/models/credit_note.rbs +48 -66
- data/sig/orb/models/credit_note_create_params.rbs +3 -7
- data/sig/orb/models/credit_note_fetch_params.rbs +0 -2
- data/sig/orb/models/credit_note_list_params.rbs +0 -2
- data/sig/orb/models/customer.rbs +43 -63
- data/sig/orb/models/customer_create_params.rbs +32 -52
- data/sig/orb/models/customer_delete_params.rbs +0 -2
- data/sig/orb/models/customer_fetch_by_external_id_params.rbs +0 -2
- data/sig/orb/models/customer_fetch_params.rbs +0 -2
- data/sig/orb/models/customer_list_params.rbs +0 -2
- data/sig/orb/models/customer_sync_payment_methods_from_gateway_by_external_customer_id_params.rbs +0 -2
- data/sig/orb/models/customer_sync_payment_methods_from_gateway_params.rbs +0 -2
- data/sig/orb/models/customer_update_by_external_id_params.rbs +32 -52
- data/sig/orb/models/customer_update_params.rbs +32 -52
- data/sig/orb/models/customers/balance_transaction_create_params.rbs +0 -2
- data/sig/orb/models/customers/balance_transaction_create_response.rbs +0 -6
- data/sig/orb/models/customers/balance_transaction_list_params.rbs +0 -2
- data/sig/orb/models/customers/balance_transaction_list_response.rbs +0 -6
- data/sig/orb/models/customers/cost_list_by_external_id_params.rbs +0 -2
- data/sig/orb/models/customers/cost_list_by_external_id_response.rbs +0 -6
- data/sig/orb/models/customers/cost_list_params.rbs +0 -2
- data/sig/orb/models/customers/cost_list_response.rbs +0 -6
- data/sig/orb/models/customers/credit_list_by_external_id_params.rbs +0 -2
- data/sig/orb/models/customers/credit_list_by_external_id_response.rbs +0 -2
- data/sig/orb/models/customers/credit_list_params.rbs +0 -2
- data/sig/orb/models/customers/credit_list_response.rbs +0 -2
- data/sig/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rbs +3 -7
- data/sig/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbs +1 -43
- data/sig/orb/models/customers/credits/ledger_create_entry_params.rbs +3 -7
- data/sig/orb/models/customers/credits/ledger_create_entry_response.rbs +1 -43
- data/sig/orb/models/customers/credits/ledger_list_by_external_id_params.rbs +0 -2
- data/sig/orb/models/customers/credits/ledger_list_by_external_id_response.rbs +1 -43
- data/sig/orb/models/customers/credits/ledger_list_params.rbs +0 -2
- data/sig/orb/models/customers/credits/ledger_list_response.rbs +1 -43
- data/sig/orb/models/customers/credits/top_up_create_by_external_id_params.rbs +3 -7
- data/sig/orb/models/customers/credits/top_up_create_by_external_id_response.rbs +0 -4
- data/sig/orb/models/customers/credits/top_up_create_params.rbs +3 -7
- data/sig/orb/models/customers/credits/top_up_create_response.rbs +0 -4
- data/sig/orb/models/customers/credits/top_up_delete_by_external_id_params.rbs +0 -2
- data/sig/orb/models/customers/credits/top_up_delete_params.rbs +0 -2
- data/sig/orb/models/customers/credits/top_up_list_by_external_id_params.rbs +0 -2
- data/sig/orb/models/customers/credits/top_up_list_by_external_id_response.rbs +0 -4
- data/sig/orb/models/customers/credits/top_up_list_params.rbs +0 -2
- data/sig/orb/models/customers/credits/top_up_list_response.rbs +0 -4
- data/sig/orb/models/dimensional_price_group.rbs +0 -2
- data/sig/orb/models/dimensional_price_group_create_params.rbs +0 -2
- data/sig/orb/models/dimensional_price_group_list_params.rbs +0 -2
- data/sig/orb/models/dimensional_price_group_retrieve_params.rbs +0 -2
- data/sig/orb/models/dimensional_price_groups/external_dimensional_price_group_id_retrieve_params.rbs +0 -2
- data/sig/orb/models/dimensional_price_groups.rbs +6 -8
- data/sig/orb/models/discount.rbs +5 -5
- data/sig/orb/models/evaluate_price_group.rbs +4 -6
- data/sig/orb/models/event_deprecate_params.rbs +0 -2
- data/sig/orb/models/event_deprecate_response.rbs +0 -2
- data/sig/orb/models/event_ingest_params.rbs +3 -7
- data/sig/orb/models/event_ingest_response.rbs +0 -6
- data/sig/orb/models/event_search_params.rbs +0 -2
- data/sig/orb/models/event_search_response.rbs +0 -4
- data/sig/orb/models/event_update_params.rbs +0 -2
- data/sig/orb/models/event_update_response.rbs +0 -2
- data/sig/orb/models/events/backfill_close_params.rbs +0 -2
- data/sig/orb/models/events/backfill_close_response.rbs +0 -2
- data/sig/orb/models/events/backfill_create_params.rbs +0 -2
- data/sig/orb/models/events/backfill_create_response.rbs +0 -2
- data/sig/orb/models/events/backfill_fetch_params.rbs +0 -2
- data/sig/orb/models/events/backfill_fetch_response.rbs +0 -2
- data/sig/orb/models/events/backfill_list_params.rbs +0 -2
- data/sig/orb/models/events/backfill_list_response.rbs +0 -2
- data/sig/orb/models/events/backfill_revert_params.rbs +0 -2
- data/sig/orb/models/events/backfill_revert_response.rbs +0 -2
- data/sig/orb/models/events/event_volumes.rbs +3 -10
- data/sig/orb/models/events/volume_list_params.rbs +0 -2
- data/sig/orb/models/invoice.rbs +110 -172
- data/sig/orb/models/invoice_create_params.rbs +10 -16
- data/sig/orb/models/invoice_fetch_params.rbs +0 -2
- data/sig/orb/models/invoice_fetch_upcoming_params.rbs +0 -2
- data/sig/orb/models/invoice_fetch_upcoming_response.rbs +2 -64
- data/sig/orb/models/invoice_issue_params.rbs +0 -2
- data/sig/orb/models/invoice_level_discount.rbs +2 -4
- data/sig/orb/models/invoice_line_item_create_params.rbs +0 -2
- data/sig/orb/models/invoice_line_item_create_response.rbs +2 -36
- data/sig/orb/models/invoice_list_params.rbs +4 -6
- data/sig/orb/models/invoice_mark_paid_params.rbs +0 -2
- data/sig/orb/models/invoice_pay_params.rbs +0 -2
- data/sig/orb/models/invoice_update_params.rbs +0 -2
- data/sig/orb/models/invoice_void_params.rbs +0 -2
- data/sig/orb/models/item.rbs +7 -11
- data/sig/orb/models/item_create_params.rbs +0 -2
- data/sig/orb/models/item_fetch_params.rbs +0 -2
- data/sig/orb/models/item_list_params.rbs +0 -2
- data/sig/orb/models/item_update_params.rbs +7 -11
- data/sig/orb/models/metric_create_params.rbs +0 -2
- data/sig/orb/models/metric_fetch_params.rbs +0 -2
- data/sig/orb/models/metric_list_params.rbs +0 -2
- data/sig/orb/models/metric_update_params.rbs +0 -2
- data/sig/orb/models/pagination_metadata.rbs +0 -2
- data/sig/orb/models/percentage_discount.rbs +4 -6
- data/sig/orb/models/plan.rbs +45 -73
- data/sig/orb/models/plan_create_params.rbs +518 -696
- data/sig/orb/models/plan_fetch_params.rbs +0 -2
- data/sig/orb/models/plan_list_params.rbs +0 -2
- data/sig/orb/models/plan_update_params.rbs +0 -2
- data/sig/orb/models/plans/external_plan_id_fetch_params.rbs +0 -2
- data/sig/orb/models/plans/external_plan_id_update_params.rbs +0 -2
- data/sig/orb/models/price.rbs +1194 -1730
- data/sig/orb/models/price_create_params.rbs +59 -97
- data/sig/orb/models/price_evaluate_params.rbs +0 -2
- data/sig/orb/models/price_evaluate_response.rbs +3 -6
- data/sig/orb/models/price_fetch_params.rbs +0 -2
- data/sig/orb/models/price_list_params.rbs +0 -2
- data/sig/orb/models/price_update_params.rbs +0 -2
- data/sig/orb/models/prices/external_price_id_fetch_params.rbs +0 -2
- data/sig/orb/models/prices/external_price_id_update_params.rbs +0 -2
- data/sig/orb/models/subscription.rbs +56 -94
- data/sig/orb/models/subscription_cancel_params.rbs +0 -2
- data/sig/orb/models/subscription_cancel_response.rbs +20 -60
- data/sig/orb/models/subscription_change_apply_params.rbs +0 -2
- data/sig/orb/models/subscription_change_apply_response.rbs +20 -62
- data/sig/orb/models/subscription_change_cancel_params.rbs +0 -2
- data/sig/orb/models/subscription_change_cancel_response.rbs +20 -62
- data/sig/orb/models/subscription_change_retrieve_params.rbs +0 -2
- data/sig/orb/models/subscription_change_retrieve_response.rbs +20 -62
- data/sig/orb/models/subscription_create_params.rbs +1103 -1499
- data/sig/orb/models/subscription_create_response.rbs +20 -60
- data/sig/orb/models/subscription_fetch_costs_params.rbs +0 -2
- data/sig/orb/models/subscription_fetch_costs_response.rbs +0 -6
- data/sig/orb/models/subscription_fetch_params.rbs +0 -2
- data/sig/orb/models/subscription_fetch_schedule_params.rbs +0 -2
- data/sig/orb/models/subscription_fetch_schedule_response.rbs +0 -4
- data/sig/orb/models/subscription_fetch_usage_params.rbs +0 -2
- data/sig/orb/models/subscription_list_params.rbs +0 -2
- data/sig/orb/models/subscription_price_intervals_params.rbs +666 -896
- data/sig/orb/models/subscription_price_intervals_response.rbs +20 -60
- data/sig/orb/models/subscription_schedule_plan_change_params.rbs +1103 -1499
- data/sig/orb/models/subscription_schedule_plan_change_response.rbs +20 -60
- data/sig/orb/models/subscription_trigger_phase_params.rbs +0 -2
- data/sig/orb/models/subscription_trigger_phase_response.rbs +20 -60
- data/sig/orb/models/subscription_unschedule_cancellation_params.rbs +0 -2
- data/sig/orb/models/subscription_unschedule_cancellation_response.rbs +20 -60
- data/sig/orb/models/subscription_unschedule_fixed_fee_quantity_updates_params.rbs +0 -2
- data/sig/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbs +20 -60
- data/sig/orb/models/subscription_unschedule_pending_plan_changes_params.rbs +0 -2
- data/sig/orb/models/subscription_unschedule_pending_plan_changes_response.rbs +20 -60
- data/sig/orb/models/subscription_update_fixed_fee_quantity_params.rbs +0 -2
- data/sig/orb/models/subscription_update_fixed_fee_quantity_response.rbs +20 -60
- data/sig/orb/models/subscription_update_params.rbs +0 -2
- data/sig/orb/models/subscription_update_trial_params.rbs +1 -3
- data/sig/orb/models/subscription_update_trial_response.rbs +20 -60
- data/sig/orb/models/subscription_usage.rbs +35 -53
- data/sig/orb/models/subscriptions.rbs +6 -8
- data/sig/orb/models/top_level_ping_params.rbs +0 -2
- data/sig/orb/models/top_level_ping_response.rbs +0 -2
- data/sig/orb/models/trial_discount.rbs +4 -6
- data/sig/orb/models/usage_discount.rbs +4 -6
- data/sig/orb/request_options.rbs +1 -1
- data/sig/orb/resources/alerts.rbs +12 -12
- data/sig/orb/resources/coupons/subscriptions.rbs +1 -1
- data/sig/orb/resources/coupons.rbs +4 -4
- data/sig/orb/resources/credit_notes.rbs +4 -4
- data/sig/orb/resources/customers/credits/ledger.rbs +2 -2
- data/sig/orb/resources/customers/credits/top_ups.rbs +2 -2
- data/sig/orb/resources/customers.rbs +24 -24
- data/sig/orb/resources/dimensional_price_groups/external_dimensional_price_group_id.rbs +1 -1
- data/sig/orb/resources/dimensional_price_groups.rbs +3 -3
- data/sig/orb/resources/events/volume.rbs +1 -1
- data/sig/orb/resources/events.rbs +1 -1
- data/sig/orb/resources/invoices.rbs +10 -10
- data/sig/orb/resources/items.rbs +5 -5
- data/sig/orb/resources/metrics.rbs +4 -4
- data/sig/orb/resources/plans/external_plan_id.rbs +2 -2
- data/sig/orb/resources/plans.rbs +5 -5
- data/sig/orb/resources/prices.rbs +11 -11
- data/sig/orb/resources/subscriptions.rbs +21 -21
- metadata +2 -2
@@ -3,6 +3,8 @@
|
|
3
3
|
module Orb
|
4
4
|
module Models
|
5
5
|
class SubscriptionChangeCancelResponse < Orb::Internal::Type::BaseModel
|
6
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
7
|
+
|
6
8
|
sig { returns(String) }
|
7
9
|
attr_accessor :id
|
8
10
|
|
@@ -10,17 +12,27 @@ module Orb
|
|
10
12
|
sig { returns(Time) }
|
11
13
|
attr_accessor :expiration_time
|
12
14
|
|
13
|
-
sig
|
15
|
+
sig do
|
16
|
+
returns(
|
17
|
+
Orb::Models::SubscriptionChangeCancelResponse::Status::TaggedSymbol
|
18
|
+
)
|
19
|
+
end
|
14
20
|
attr_accessor :status
|
15
21
|
|
16
|
-
sig
|
22
|
+
sig do
|
23
|
+
returns(
|
24
|
+
T.nilable(Orb::Models::SubscriptionChangeCancelResponse::Subscription)
|
25
|
+
)
|
26
|
+
end
|
17
27
|
attr_reader :subscription
|
18
28
|
|
19
29
|
sig do
|
20
30
|
params(
|
21
|
-
subscription:
|
22
|
-
|
23
|
-
|
31
|
+
subscription:
|
32
|
+
T.nilable(
|
33
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::OrHash
|
34
|
+
)
|
35
|
+
).void
|
24
36
|
end
|
25
37
|
attr_writer :subscription
|
26
38
|
|
@@ -40,12 +52,15 @@ module Orb
|
|
40
52
|
params(
|
41
53
|
id: String,
|
42
54
|
expiration_time: Time,
|
43
|
-
status:
|
44
|
-
|
55
|
+
status:
|
56
|
+
Orb::Models::SubscriptionChangeCancelResponse::Status::OrSymbol,
|
57
|
+
subscription:
|
58
|
+
T.nilable(
|
59
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::OrHash
|
60
|
+
),
|
45
61
|
applied_at: T.nilable(Time),
|
46
62
|
cancelled_at: T.nilable(Time)
|
47
|
-
)
|
48
|
-
.returns(T.attached_class)
|
63
|
+
).returns(T.attached_class)
|
49
64
|
end
|
50
65
|
def self.new(
|
51
66
|
id:,
|
@@ -57,37 +72,67 @@ module Orb
|
|
57
72
|
applied_at: nil,
|
58
73
|
# When this change was cancelled.
|
59
74
|
cancelled_at: nil
|
60
|
-
)
|
75
|
+
)
|
76
|
+
end
|
77
|
+
|
61
78
|
sig do
|
62
|
-
override
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
79
|
+
override.returns(
|
80
|
+
{
|
81
|
+
id: String,
|
82
|
+
expiration_time: Time,
|
83
|
+
status:
|
84
|
+
Orb::Models::SubscriptionChangeCancelResponse::Status::TaggedSymbol,
|
85
|
+
subscription:
|
86
|
+
T.nilable(
|
87
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription
|
88
|
+
),
|
89
|
+
applied_at: T.nilable(Time),
|
90
|
+
cancelled_at: T.nilable(Time)
|
91
|
+
}
|
92
|
+
)
|
93
|
+
end
|
94
|
+
def to_hash
|
73
95
|
end
|
74
|
-
def to_hash; end
|
75
96
|
|
76
97
|
module Status
|
77
98
|
extend Orb::Internal::Type::Enum
|
78
99
|
|
79
|
-
TaggedSymbol =
|
100
|
+
TaggedSymbol =
|
101
|
+
T.type_alias do
|
102
|
+
T.all(Symbol, Orb::Models::SubscriptionChangeCancelResponse::Status)
|
103
|
+
end
|
80
104
|
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
81
105
|
|
82
|
-
PENDING =
|
83
|
-
|
84
|
-
|
106
|
+
PENDING =
|
107
|
+
T.let(
|
108
|
+
:pending,
|
109
|
+
Orb::Models::SubscriptionChangeCancelResponse::Status::TaggedSymbol
|
110
|
+
)
|
111
|
+
APPLIED =
|
112
|
+
T.let(
|
113
|
+
:applied,
|
114
|
+
Orb::Models::SubscriptionChangeCancelResponse::Status::TaggedSymbol
|
115
|
+
)
|
116
|
+
CANCELLED =
|
117
|
+
T.let(
|
118
|
+
:cancelled,
|
119
|
+
Orb::Models::SubscriptionChangeCancelResponse::Status::TaggedSymbol
|
120
|
+
)
|
85
121
|
|
86
|
-
sig
|
87
|
-
|
122
|
+
sig do
|
123
|
+
override.returns(
|
124
|
+
T::Array[
|
125
|
+
Orb::Models::SubscriptionChangeCancelResponse::Status::TaggedSymbol
|
126
|
+
]
|
127
|
+
)
|
128
|
+
end
|
129
|
+
def self.values
|
130
|
+
end
|
88
131
|
end
|
89
132
|
|
90
133
|
class Subscription < Orb::Internal::Type::BaseModel
|
134
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
135
|
+
|
91
136
|
sig { returns(String) }
|
92
137
|
attr_accessor :id
|
93
138
|
|
@@ -98,7 +143,13 @@ module Orb
|
|
98
143
|
|
99
144
|
# The adjustment intervals for this subscription sorted by the start_date of the
|
100
145
|
# adjustment interval.
|
101
|
-
sig
|
146
|
+
sig do
|
147
|
+
returns(
|
148
|
+
T::Array[
|
149
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval
|
150
|
+
]
|
151
|
+
)
|
152
|
+
end
|
102
153
|
attr_accessor :adjustment_intervals
|
103
154
|
|
104
155
|
# Determines whether issued invoices for this subscription will automatically be
|
@@ -107,17 +158,18 @@ module Orb
|
|
107
158
|
sig { returns(T.nilable(T::Boolean)) }
|
108
159
|
attr_accessor :auto_collection
|
109
160
|
|
110
|
-
sig
|
161
|
+
sig do
|
162
|
+
returns(
|
163
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::BillingCycleAnchorConfiguration
|
164
|
+
)
|
165
|
+
end
|
111
166
|
attr_reader :billing_cycle_anchor_configuration
|
112
167
|
|
113
168
|
sig do
|
114
169
|
params(
|
115
|
-
billing_cycle_anchor_configuration:
|
116
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::BillingCycleAnchorConfiguration
|
117
|
-
|
118
|
-
)
|
119
|
-
)
|
120
|
-
.void
|
170
|
+
billing_cycle_anchor_configuration:
|
171
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::BillingCycleAnchorConfiguration::OrHash
|
172
|
+
).void
|
121
173
|
end
|
122
174
|
attr_writer :billing_cycle_anchor_configuration
|
123
175
|
|
@@ -161,10 +213,10 @@ module Orb
|
|
161
213
|
# [IANA timezone database](https://www.iana.org/time-zones)), which defaults to
|
162
214
|
# your account's timezone. See [Timezone localization](/essentials/timezones) for
|
163
215
|
# information on what this timezone parameter influences within Orb.
|
164
|
-
sig { returns(Orb::
|
216
|
+
sig { returns(Orb::Customer) }
|
165
217
|
attr_reader :customer
|
166
218
|
|
167
|
-
sig { params(customer:
|
219
|
+
sig { params(customer: Orb::Customer::OrHash).void }
|
168
220
|
attr_writer :customer
|
169
221
|
|
170
222
|
# Determines the default memo on this subscriptions' invoices. Note that if this
|
@@ -190,14 +242,26 @@ module Orb
|
|
190
242
|
sig { returns(T.nilable(Time)) }
|
191
243
|
attr_accessor :end_date
|
192
244
|
|
193
|
-
sig
|
245
|
+
sig do
|
246
|
+
returns(
|
247
|
+
T::Array[
|
248
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::FixedFeeQuantitySchedule
|
249
|
+
]
|
250
|
+
)
|
251
|
+
end
|
194
252
|
attr_accessor :fixed_fee_quantity_schedule
|
195
253
|
|
196
254
|
sig { returns(T.nilable(String)) }
|
197
255
|
attr_accessor :invoicing_threshold
|
198
256
|
|
199
257
|
# The maximum intervals for this subscription sorted by the start_date.
|
200
|
-
sig
|
258
|
+
sig do
|
259
|
+
returns(
|
260
|
+
T::Array[
|
261
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::MaximumInterval
|
262
|
+
]
|
263
|
+
)
|
264
|
+
end
|
201
265
|
attr_accessor :maximum_intervals
|
202
266
|
|
203
267
|
# User specified key-value pairs for the resource. If not present, this defaults
|
@@ -208,7 +272,13 @@ module Orb
|
|
208
272
|
attr_accessor :metadata
|
209
273
|
|
210
274
|
# The minimum intervals for this subscription sorted by the start_date.
|
211
|
-
sig
|
275
|
+
sig do
|
276
|
+
returns(
|
277
|
+
T::Array[
|
278
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::MinimumInterval
|
279
|
+
]
|
280
|
+
)
|
281
|
+
end
|
212
282
|
attr_accessor :minimum_intervals
|
213
283
|
|
214
284
|
# Determines the difference between the invoice issue date for subscription
|
@@ -219,19 +289,22 @@ module Orb
|
|
219
289
|
attr_accessor :net_terms
|
220
290
|
|
221
291
|
# A pending subscription change if one exists on this subscription.
|
222
|
-
sig
|
292
|
+
sig do
|
293
|
+
returns(
|
294
|
+
T.nilable(
|
295
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PendingSubscriptionChange
|
296
|
+
)
|
297
|
+
)
|
298
|
+
end
|
223
299
|
attr_reader :pending_subscription_change
|
224
300
|
|
225
301
|
sig do
|
226
302
|
params(
|
227
|
-
pending_subscription_change:
|
228
|
-
T.
|
229
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PendingSubscriptionChange
|
230
|
-
Orb::Internal::AnyHash
|
303
|
+
pending_subscription_change:
|
304
|
+
T.nilable(
|
305
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PendingSubscriptionChange::OrHash
|
231
306
|
)
|
232
|
-
|
233
|
-
)
|
234
|
-
.void
|
307
|
+
).void
|
235
308
|
end
|
236
309
|
attr_writer :pending_subscription_change
|
237
310
|
|
@@ -239,26 +312,38 @@ module Orb
|
|
239
312
|
# subscribed to by a customer. Plans define the billing behavior of the
|
240
313
|
# subscription. You can see more about how to configure prices in the
|
241
314
|
# [Price resource](/reference/price).
|
242
|
-
sig { returns(Orb::
|
315
|
+
sig { returns(Orb::Plan) }
|
243
316
|
attr_reader :plan
|
244
317
|
|
245
|
-
sig { params(plan:
|
318
|
+
sig { params(plan: Orb::Plan::OrHash).void }
|
246
319
|
attr_writer :plan
|
247
320
|
|
248
321
|
# The price intervals for this subscription.
|
249
|
-
sig
|
322
|
+
sig do
|
323
|
+
returns(
|
324
|
+
T::Array[
|
325
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PriceInterval
|
326
|
+
]
|
327
|
+
)
|
328
|
+
end
|
250
329
|
attr_accessor :price_intervals
|
251
330
|
|
252
|
-
sig
|
331
|
+
sig do
|
332
|
+
returns(
|
333
|
+
T.nilable(
|
334
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::RedeemedCoupon
|
335
|
+
)
|
336
|
+
)
|
337
|
+
end
|
253
338
|
attr_reader :redeemed_coupon
|
254
339
|
|
255
340
|
sig do
|
256
341
|
params(
|
257
|
-
redeemed_coupon:
|
258
|
-
T.
|
259
|
-
|
260
|
-
|
261
|
-
|
342
|
+
redeemed_coupon:
|
343
|
+
T.nilable(
|
344
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::RedeemedCoupon::OrHash
|
345
|
+
)
|
346
|
+
).void
|
262
347
|
end
|
263
348
|
attr_writer :redeemed_coupon
|
264
349
|
|
@@ -266,36 +351,47 @@ module Orb
|
|
266
351
|
sig { returns(Time) }
|
267
352
|
attr_accessor :start_date
|
268
353
|
|
269
|
-
sig
|
354
|
+
sig do
|
355
|
+
returns(
|
356
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::Status::TaggedSymbol
|
357
|
+
)
|
358
|
+
end
|
270
359
|
attr_accessor :status
|
271
360
|
|
272
|
-
sig
|
361
|
+
sig do
|
362
|
+
returns(
|
363
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::TrialInfo
|
364
|
+
)
|
365
|
+
end
|
273
366
|
attr_reader :trial_info
|
274
367
|
|
275
368
|
sig do
|
276
369
|
params(
|
277
|
-
trial_info:
|
278
|
-
|
279
|
-
|
370
|
+
trial_info:
|
371
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::TrialInfo::OrHash
|
372
|
+
).void
|
280
373
|
end
|
281
374
|
attr_writer :trial_info
|
282
375
|
|
283
376
|
# The resources that were changed as part of this operation. Only present when
|
284
377
|
# fetched through the subscription changes API or if the
|
285
378
|
# `include_changed_resources` parameter was passed in the request.
|
286
|
-
sig
|
379
|
+
sig do
|
380
|
+
returns(
|
381
|
+
T.nilable(
|
382
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::ChangedResources
|
383
|
+
)
|
384
|
+
)
|
385
|
+
end
|
287
386
|
attr_reader :changed_resources
|
288
387
|
|
289
388
|
sig do
|
290
389
|
params(
|
291
|
-
changed_resources:
|
292
|
-
T.
|
293
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::ChangedResources
|
294
|
-
Orb::Internal::AnyHash
|
390
|
+
changed_resources:
|
391
|
+
T.nilable(
|
392
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::ChangedResources::OrHash
|
295
393
|
)
|
296
|
-
|
297
|
-
)
|
298
|
-
.void
|
394
|
+
).void
|
299
395
|
end
|
300
396
|
attr_writer :changed_resources
|
301
397
|
|
@@ -303,75 +399,66 @@ module Orb
|
|
303
399
|
params(
|
304
400
|
id: String,
|
305
401
|
active_plan_phase_order: T.nilable(Integer),
|
306
|
-
adjustment_intervals:
|
307
|
-
T
|
308
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval
|
309
|
-
|
310
|
-
)
|
311
|
-
],
|
402
|
+
adjustment_intervals:
|
403
|
+
T::Array[
|
404
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::OrHash
|
405
|
+
],
|
312
406
|
auto_collection: T.nilable(T::Boolean),
|
313
|
-
billing_cycle_anchor_configuration:
|
314
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::BillingCycleAnchorConfiguration,
|
315
|
-
Orb::Internal::AnyHash
|
316
|
-
),
|
407
|
+
billing_cycle_anchor_configuration:
|
408
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::BillingCycleAnchorConfiguration::OrHash,
|
317
409
|
billing_cycle_day: Integer,
|
318
410
|
created_at: Time,
|
319
411
|
current_billing_period_end_date: T.nilable(Time),
|
320
412
|
current_billing_period_start_date: T.nilable(Time),
|
321
|
-
customer:
|
413
|
+
customer: Orb::Customer::OrHash,
|
322
414
|
default_invoice_memo: T.nilable(String),
|
323
|
-
discount_intervals:
|
324
|
-
T
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
|
329
|
-
|
330
|
-
|
415
|
+
discount_intervals:
|
416
|
+
T::Array[
|
417
|
+
T.any(
|
418
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Amount::OrHash,
|
419
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Percentage::OrHash,
|
420
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Usage::OrHash
|
421
|
+
)
|
422
|
+
],
|
331
423
|
end_date: T.nilable(Time),
|
332
|
-
fixed_fee_quantity_schedule:
|
333
|
-
T
|
334
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::FixedFeeQuantitySchedule
|
335
|
-
|
336
|
-
)
|
337
|
-
],
|
424
|
+
fixed_fee_quantity_schedule:
|
425
|
+
T::Array[
|
426
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::FixedFeeQuantitySchedule::OrHash
|
427
|
+
],
|
338
428
|
invoicing_threshold: T.nilable(String),
|
339
|
-
maximum_intervals:
|
340
|
-
T
|
341
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::MaximumInterval
|
342
|
-
|
343
|
-
)
|
344
|
-
],
|
429
|
+
maximum_intervals:
|
430
|
+
T::Array[
|
431
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::MaximumInterval::OrHash
|
432
|
+
],
|
345
433
|
metadata: T::Hash[Symbol, String],
|
346
|
-
minimum_intervals:
|
347
|
-
T
|
348
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::MinimumInterval
|
349
|
-
|
350
|
-
)
|
351
|
-
],
|
434
|
+
minimum_intervals:
|
435
|
+
T::Array[
|
436
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::MinimumInterval::OrHash
|
437
|
+
],
|
352
438
|
net_terms: Integer,
|
353
|
-
pending_subscription_change:
|
354
|
-
T.
|
355
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PendingSubscriptionChange
|
356
|
-
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
439
|
+
pending_subscription_change:
|
440
|
+
T.nilable(
|
441
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PendingSubscriptionChange::OrHash
|
442
|
+
),
|
443
|
+
plan: Orb::Plan::OrHash,
|
444
|
+
price_intervals:
|
445
|
+
T::Array[
|
446
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PriceInterval::OrHash
|
447
|
+
],
|
448
|
+
redeemed_coupon:
|
449
|
+
T.nilable(
|
450
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::RedeemedCoupon::OrHash
|
451
|
+
),
|
364
452
|
start_date: Time,
|
365
|
-
status:
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
453
|
+
status:
|
454
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::Status::OrSymbol,
|
455
|
+
trial_info:
|
456
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::TrialInfo::OrHash,
|
457
|
+
changed_resources:
|
458
|
+
T.nilable(
|
459
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::ChangedResources::OrHash
|
371
460
|
)
|
372
|
-
|
373
|
-
)
|
374
|
-
.returns(T.attached_class)
|
461
|
+
).returns(T.attached_class)
|
375
462
|
end
|
376
463
|
def self.new(
|
377
464
|
id:,
|
@@ -460,50 +547,82 @@ module Orb
|
|
460
547
|
# fetched through the subscription changes API or if the
|
461
548
|
# `include_changed_resources` parameter was passed in the request.
|
462
549
|
changed_resources: nil
|
463
|
-
)
|
550
|
+
)
|
551
|
+
end
|
552
|
+
|
464
553
|
sig do
|
465
|
-
override
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
554
|
+
override.returns(
|
555
|
+
{
|
556
|
+
id: String,
|
557
|
+
active_plan_phase_order: T.nilable(Integer),
|
558
|
+
adjustment_intervals:
|
559
|
+
T::Array[
|
560
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval
|
561
|
+
],
|
562
|
+
auto_collection: T.nilable(T::Boolean),
|
563
|
+
billing_cycle_anchor_configuration:
|
564
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::BillingCycleAnchorConfiguration,
|
565
|
+
billing_cycle_day: Integer,
|
566
|
+
created_at: Time,
|
567
|
+
current_billing_period_end_date: T.nilable(Time),
|
568
|
+
current_billing_period_start_date: T.nilable(Time),
|
569
|
+
customer: Orb::Customer,
|
570
|
+
default_invoice_memo: T.nilable(String),
|
571
|
+
discount_intervals:
|
572
|
+
T::Array[
|
480
573
|
T.any(
|
481
574
|
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Amount,
|
482
575
|
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Percentage,
|
483
576
|
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Usage
|
484
577
|
)
|
485
578
|
],
|
486
|
-
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
|
493
|
-
|
494
|
-
|
495
|
-
|
496
|
-
|
497
|
-
|
498
|
-
|
499
|
-
|
500
|
-
|
501
|
-
|
502
|
-
|
579
|
+
end_date: T.nilable(Time),
|
580
|
+
fixed_fee_quantity_schedule:
|
581
|
+
T::Array[
|
582
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::FixedFeeQuantitySchedule
|
583
|
+
],
|
584
|
+
invoicing_threshold: T.nilable(String),
|
585
|
+
maximum_intervals:
|
586
|
+
T::Array[
|
587
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::MaximumInterval
|
588
|
+
],
|
589
|
+
metadata: T::Hash[Symbol, String],
|
590
|
+
minimum_intervals:
|
591
|
+
T::Array[
|
592
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::MinimumInterval
|
593
|
+
],
|
594
|
+
net_terms: Integer,
|
595
|
+
pending_subscription_change:
|
596
|
+
T.nilable(
|
597
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PendingSubscriptionChange
|
598
|
+
),
|
599
|
+
plan: Orb::Plan,
|
600
|
+
price_intervals:
|
601
|
+
T::Array[
|
602
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PriceInterval
|
603
|
+
],
|
604
|
+
redeemed_coupon:
|
605
|
+
T.nilable(
|
606
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::RedeemedCoupon
|
607
|
+
),
|
608
|
+
start_date: Time,
|
609
|
+
status:
|
610
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::Status::TaggedSymbol,
|
611
|
+
trial_info:
|
612
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::TrialInfo,
|
613
|
+
changed_resources:
|
614
|
+
T.nilable(
|
615
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::ChangedResources
|
616
|
+
)
|
617
|
+
}
|
618
|
+
)
|
619
|
+
end
|
620
|
+
def to_hash
|
503
621
|
end
|
504
|
-
def to_hash; end
|
505
622
|
|
506
623
|
class AdjustmentInterval < Orb::Internal::Type::BaseModel
|
624
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
625
|
+
|
507
626
|
sig { returns(String) }
|
508
627
|
attr_accessor :id
|
509
628
|
|
@@ -535,19 +654,18 @@ module Orb
|
|
535
654
|
sig do
|
536
655
|
params(
|
537
656
|
id: String,
|
538
|
-
adjustment:
|
539
|
-
|
540
|
-
|
541
|
-
|
542
|
-
|
543
|
-
|
544
|
-
|
545
|
-
|
657
|
+
adjustment:
|
658
|
+
T.any(
|
659
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::UsageDiscount::OrHash,
|
660
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::AmountDiscount::OrHash,
|
661
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::PercentageDiscount::OrHash,
|
662
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::Minimum::OrHash,
|
663
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::Maximum::OrHash
|
664
|
+
),
|
546
665
|
applies_to_price_interval_ids: T::Array[String],
|
547
666
|
end_date: T.nilable(Time),
|
548
667
|
start_date: Time
|
549
|
-
)
|
550
|
-
.returns(T.attached_class)
|
668
|
+
).returns(T.attached_class)
|
551
669
|
end
|
552
670
|
def self.new(
|
553
671
|
id:,
|
@@ -558,31 +676,48 @@ module Orb
|
|
558
676
|
end_date:,
|
559
677
|
# The start date of the adjustment interval.
|
560
678
|
start_date:
|
561
|
-
)
|
679
|
+
)
|
680
|
+
end
|
681
|
+
|
562
682
|
sig do
|
563
|
-
override
|
564
|
-
|
565
|
-
|
566
|
-
|
567
|
-
|
683
|
+
override.returns(
|
684
|
+
{
|
685
|
+
id: String,
|
686
|
+
adjustment:
|
687
|
+
T.any(
|
568
688
|
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::UsageDiscount,
|
569
689
|
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::AmountDiscount,
|
570
690
|
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::PercentageDiscount,
|
571
691
|
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::Minimum,
|
572
692
|
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::Maximum
|
573
693
|
),
|
574
|
-
|
575
|
-
|
576
|
-
|
577
|
-
|
578
|
-
|
694
|
+
applies_to_price_interval_ids: T::Array[String],
|
695
|
+
end_date: T.nilable(Time),
|
696
|
+
start_date: Time
|
697
|
+
}
|
698
|
+
)
|
699
|
+
end
|
700
|
+
def to_hash
|
579
701
|
end
|
580
|
-
def to_hash; end
|
581
702
|
|
582
703
|
module Adjustment
|
583
704
|
extend Orb::Internal::Type::Union
|
584
705
|
|
706
|
+
Variants =
|
707
|
+
T.type_alias do
|
708
|
+
T.any(
|
709
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::UsageDiscount,
|
710
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::AmountDiscount,
|
711
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::PercentageDiscount,
|
712
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::Minimum,
|
713
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::Maximum
|
714
|
+
)
|
715
|
+
end
|
716
|
+
|
585
717
|
class UsageDiscount < Orb::Internal::Type::BaseModel
|
718
|
+
OrHash =
|
719
|
+
T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
720
|
+
|
586
721
|
sig { returns(String) }
|
587
722
|
attr_accessor :id
|
588
723
|
|
@@ -620,8 +755,7 @@ module Orb
|
|
620
755
|
reason: T.nilable(String),
|
621
756
|
usage_discount: Float,
|
622
757
|
adjustment_type: Symbol
|
623
|
-
)
|
624
|
-
.returns(T.attached_class)
|
758
|
+
).returns(T.attached_class)
|
625
759
|
end
|
626
760
|
def self.new(
|
627
761
|
id:,
|
@@ -638,25 +772,30 @@ module Orb
|
|
638
772
|
# to in a given billing period.
|
639
773
|
usage_discount:,
|
640
774
|
adjustment_type: :usage_discount
|
641
|
-
)
|
775
|
+
)
|
776
|
+
end
|
777
|
+
|
642
778
|
sig do
|
643
|
-
override
|
644
|
-
|
645
|
-
|
646
|
-
|
647
|
-
|
648
|
-
|
649
|
-
|
650
|
-
|
651
|
-
|
652
|
-
|
653
|
-
|
654
|
-
|
779
|
+
override.returns(
|
780
|
+
{
|
781
|
+
id: String,
|
782
|
+
adjustment_type: Symbol,
|
783
|
+
applies_to_price_ids: T::Array[String],
|
784
|
+
is_invoice_level: T::Boolean,
|
785
|
+
plan_phase_order: T.nilable(Integer),
|
786
|
+
reason: T.nilable(String),
|
787
|
+
usage_discount: Float
|
788
|
+
}
|
789
|
+
)
|
790
|
+
end
|
791
|
+
def to_hash
|
655
792
|
end
|
656
|
-
def to_hash; end
|
657
793
|
end
|
658
794
|
|
659
795
|
class AmountDiscount < Orb::Internal::Type::BaseModel
|
796
|
+
OrHash =
|
797
|
+
T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
798
|
+
|
660
799
|
sig { returns(String) }
|
661
800
|
attr_accessor :id
|
662
801
|
|
@@ -694,8 +833,7 @@ module Orb
|
|
694
833
|
plan_phase_order: T.nilable(Integer),
|
695
834
|
reason: T.nilable(String),
|
696
835
|
adjustment_type: Symbol
|
697
|
-
)
|
698
|
-
.returns(T.attached_class)
|
836
|
+
).returns(T.attached_class)
|
699
837
|
end
|
700
838
|
def self.new(
|
701
839
|
id:,
|
@@ -712,25 +850,30 @@ module Orb
|
|
712
850
|
# The reason for the adjustment.
|
713
851
|
reason:,
|
714
852
|
adjustment_type: :amount_discount
|
715
|
-
)
|
853
|
+
)
|
854
|
+
end
|
855
|
+
|
716
856
|
sig do
|
717
|
-
override
|
718
|
-
|
719
|
-
|
720
|
-
|
721
|
-
|
722
|
-
|
723
|
-
|
724
|
-
|
725
|
-
|
726
|
-
|
727
|
-
|
728
|
-
|
857
|
+
override.returns(
|
858
|
+
{
|
859
|
+
id: String,
|
860
|
+
adjustment_type: Symbol,
|
861
|
+
amount_discount: String,
|
862
|
+
applies_to_price_ids: T::Array[String],
|
863
|
+
is_invoice_level: T::Boolean,
|
864
|
+
plan_phase_order: T.nilable(Integer),
|
865
|
+
reason: T.nilable(String)
|
866
|
+
}
|
867
|
+
)
|
868
|
+
end
|
869
|
+
def to_hash
|
729
870
|
end
|
730
|
-
def to_hash; end
|
731
871
|
end
|
732
872
|
|
733
873
|
class PercentageDiscount < Orb::Internal::Type::BaseModel
|
874
|
+
OrHash =
|
875
|
+
T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
876
|
+
|
734
877
|
sig { returns(String) }
|
735
878
|
attr_accessor :id
|
736
879
|
|
@@ -768,8 +911,7 @@ module Orb
|
|
768
911
|
plan_phase_order: T.nilable(Integer),
|
769
912
|
reason: T.nilable(String),
|
770
913
|
adjustment_type: Symbol
|
771
|
-
)
|
772
|
-
.returns(T.attached_class)
|
914
|
+
).returns(T.attached_class)
|
773
915
|
end
|
774
916
|
def self.new(
|
775
917
|
id:,
|
@@ -786,25 +928,30 @@ module Orb
|
|
786
928
|
# The reason for the adjustment.
|
787
929
|
reason:,
|
788
930
|
adjustment_type: :percentage_discount
|
789
|
-
)
|
931
|
+
)
|
932
|
+
end
|
933
|
+
|
790
934
|
sig do
|
791
|
-
override
|
792
|
-
|
793
|
-
|
794
|
-
|
795
|
-
|
796
|
-
|
797
|
-
|
798
|
-
|
799
|
-
|
800
|
-
|
801
|
-
|
802
|
-
|
935
|
+
override.returns(
|
936
|
+
{
|
937
|
+
id: String,
|
938
|
+
adjustment_type: Symbol,
|
939
|
+
applies_to_price_ids: T::Array[String],
|
940
|
+
is_invoice_level: T::Boolean,
|
941
|
+
percentage_discount: Float,
|
942
|
+
plan_phase_order: T.nilable(Integer),
|
943
|
+
reason: T.nilable(String)
|
944
|
+
}
|
945
|
+
)
|
946
|
+
end
|
947
|
+
def to_hash
|
803
948
|
end
|
804
|
-
def to_hash; end
|
805
949
|
end
|
806
950
|
|
807
951
|
class Minimum < Orb::Internal::Type::BaseModel
|
952
|
+
OrHash =
|
953
|
+
T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
954
|
+
|
808
955
|
sig { returns(String) }
|
809
956
|
attr_accessor :id
|
810
957
|
|
@@ -847,8 +994,7 @@ module Orb
|
|
847
994
|
plan_phase_order: T.nilable(Integer),
|
848
995
|
reason: T.nilable(String),
|
849
996
|
adjustment_type: Symbol
|
850
|
-
)
|
851
|
-
.returns(T.attached_class)
|
997
|
+
).returns(T.attached_class)
|
852
998
|
end
|
853
999
|
def self.new(
|
854
1000
|
id:,
|
@@ -867,26 +1013,31 @@ module Orb
|
|
867
1013
|
# The reason for the adjustment.
|
868
1014
|
reason:,
|
869
1015
|
adjustment_type: :minimum
|
870
|
-
)
|
1016
|
+
)
|
1017
|
+
end
|
1018
|
+
|
871
1019
|
sig do
|
872
|
-
override
|
873
|
-
|
874
|
-
|
875
|
-
|
876
|
-
|
877
|
-
|
878
|
-
|
879
|
-
|
880
|
-
|
881
|
-
|
882
|
-
|
883
|
-
|
884
|
-
|
1020
|
+
override.returns(
|
1021
|
+
{
|
1022
|
+
id: String,
|
1023
|
+
adjustment_type: Symbol,
|
1024
|
+
applies_to_price_ids: T::Array[String],
|
1025
|
+
is_invoice_level: T::Boolean,
|
1026
|
+
item_id: String,
|
1027
|
+
minimum_amount: String,
|
1028
|
+
plan_phase_order: T.nilable(Integer),
|
1029
|
+
reason: T.nilable(String)
|
1030
|
+
}
|
1031
|
+
)
|
1032
|
+
end
|
1033
|
+
def to_hash
|
885
1034
|
end
|
886
|
-
def to_hash; end
|
887
1035
|
end
|
888
1036
|
|
889
1037
|
class Maximum < Orb::Internal::Type::BaseModel
|
1038
|
+
OrHash =
|
1039
|
+
T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1040
|
+
|
890
1041
|
sig { returns(String) }
|
891
1042
|
attr_accessor :id
|
892
1043
|
|
@@ -924,8 +1075,7 @@ module Orb
|
|
924
1075
|
plan_phase_order: T.nilable(Integer),
|
925
1076
|
reason: T.nilable(String),
|
926
1077
|
adjustment_type: Symbol
|
927
|
-
)
|
928
|
-
.returns(T.attached_class)
|
1078
|
+
).returns(T.attached_class)
|
929
1079
|
end
|
930
1080
|
def self.new(
|
931
1081
|
id:,
|
@@ -942,35 +1092,41 @@ module Orb
|
|
942
1092
|
# The reason for the adjustment.
|
943
1093
|
reason:,
|
944
1094
|
adjustment_type: :maximum
|
945
|
-
)
|
1095
|
+
)
|
1096
|
+
end
|
1097
|
+
|
946
1098
|
sig do
|
947
|
-
override
|
948
|
-
|
949
|
-
|
950
|
-
|
951
|
-
|
952
|
-
|
953
|
-
|
954
|
-
|
955
|
-
|
956
|
-
|
957
|
-
|
958
|
-
|
1099
|
+
override.returns(
|
1100
|
+
{
|
1101
|
+
id: String,
|
1102
|
+
adjustment_type: Symbol,
|
1103
|
+
applies_to_price_ids: T::Array[String],
|
1104
|
+
is_invoice_level: T::Boolean,
|
1105
|
+
maximum_amount: String,
|
1106
|
+
plan_phase_order: T.nilable(Integer),
|
1107
|
+
reason: T.nilable(String)
|
1108
|
+
}
|
1109
|
+
)
|
1110
|
+
end
|
1111
|
+
def to_hash
|
959
1112
|
end
|
960
|
-
def to_hash; end
|
961
1113
|
end
|
962
1114
|
|
963
1115
|
sig do
|
964
|
-
override
|
965
|
-
|
966
|
-
|
967
|
-
|
1116
|
+
override.returns(
|
1117
|
+
T::Array[
|
1118
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::AdjustmentInterval::Adjustment::Variants
|
1119
|
+
]
|
1120
|
+
)
|
1121
|
+
end
|
1122
|
+
def self.variants
|
968
1123
|
end
|
969
|
-
def self.variants; end
|
970
1124
|
end
|
971
1125
|
end
|
972
1126
|
|
973
1127
|
class BillingCycleAnchorConfiguration < Orb::Internal::Type::BaseModel
|
1128
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1129
|
+
|
974
1130
|
# The day of the month on which the billing cycle is anchored. If the maximum
|
975
1131
|
# number of days in a month is greater than this value, the last day of the month
|
976
1132
|
# is the billing cycle day (e.g. billing_cycle_day=31 for April means the billing
|
@@ -1009,15 +1165,37 @@ module Orb
|
|
1009
1165
|
# The year on which the billing cycle is anchored (e.g. a 2 year billing cycle
|
1010
1166
|
# anchored on 2021 would have cycles starting on 2021, 2023, 2025, etc.).
|
1011
1167
|
year: nil
|
1012
|
-
)
|
1013
|
-
|
1014
|
-
|
1168
|
+
)
|
1169
|
+
end
|
1170
|
+
|
1171
|
+
sig do
|
1172
|
+
override.returns(
|
1173
|
+
{
|
1174
|
+
day: Integer,
|
1175
|
+
month: T.nilable(Integer),
|
1176
|
+
year: T.nilable(Integer)
|
1177
|
+
}
|
1178
|
+
)
|
1179
|
+
end
|
1180
|
+
def to_hash
|
1181
|
+
end
|
1015
1182
|
end
|
1016
1183
|
|
1017
1184
|
module DiscountInterval
|
1018
1185
|
extend Orb::Internal::Type::Union
|
1019
1186
|
|
1187
|
+
Variants =
|
1188
|
+
T.type_alias do
|
1189
|
+
T.any(
|
1190
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Amount,
|
1191
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Percentage,
|
1192
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Usage
|
1193
|
+
)
|
1194
|
+
end
|
1195
|
+
|
1020
1196
|
class Amount < Orb::Internal::Type::BaseModel
|
1197
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1198
|
+
|
1021
1199
|
# Only available if discount_type is `amount`.
|
1022
1200
|
sig { returns(String) }
|
1023
1201
|
attr_accessor :amount_discount
|
@@ -1049,8 +1227,7 @@ module Orb
|
|
1049
1227
|
end_date: T.nilable(Time),
|
1050
1228
|
start_date: Time,
|
1051
1229
|
discount_type: Symbol
|
1052
|
-
)
|
1053
|
-
.returns(T.attached_class)
|
1230
|
+
).returns(T.attached_class)
|
1054
1231
|
end
|
1055
1232
|
def self.new(
|
1056
1233
|
# Only available if discount_type is `amount`.
|
@@ -1064,24 +1241,28 @@ module Orb
|
|
1064
1241
|
# The start date of the discount interval.
|
1065
1242
|
start_date:,
|
1066
1243
|
discount_type: :amount
|
1067
|
-
)
|
1244
|
+
)
|
1245
|
+
end
|
1246
|
+
|
1068
1247
|
sig do
|
1069
|
-
override
|
1070
|
-
|
1071
|
-
|
1072
|
-
|
1073
|
-
|
1074
|
-
|
1075
|
-
|
1076
|
-
|
1077
|
-
|
1078
|
-
|
1079
|
-
|
1248
|
+
override.returns(
|
1249
|
+
{
|
1250
|
+
amount_discount: String,
|
1251
|
+
applies_to_price_ids: T::Array[String],
|
1252
|
+
applies_to_price_interval_ids: T::Array[String],
|
1253
|
+
discount_type: Symbol,
|
1254
|
+
end_date: T.nilable(Time),
|
1255
|
+
start_date: Time
|
1256
|
+
}
|
1257
|
+
)
|
1258
|
+
end
|
1259
|
+
def to_hash
|
1080
1260
|
end
|
1081
|
-
def to_hash; end
|
1082
1261
|
end
|
1083
1262
|
|
1084
1263
|
class Percentage < Orb::Internal::Type::BaseModel
|
1264
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1265
|
+
|
1085
1266
|
# The price ids that this discount interval applies to.
|
1086
1267
|
sig { returns(T::Array[String]) }
|
1087
1268
|
attr_accessor :applies_to_price_ids
|
@@ -1114,8 +1295,7 @@ module Orb
|
|
1114
1295
|
percentage_discount: Float,
|
1115
1296
|
start_date: Time,
|
1116
1297
|
discount_type: Symbol
|
1117
|
-
)
|
1118
|
-
.returns(T.attached_class)
|
1298
|
+
).returns(T.attached_class)
|
1119
1299
|
end
|
1120
1300
|
def self.new(
|
1121
1301
|
# The price ids that this discount interval applies to.
|
@@ -1130,24 +1310,28 @@ module Orb
|
|
1130
1310
|
# The start date of the discount interval.
|
1131
1311
|
start_date:,
|
1132
1312
|
discount_type: :percentage
|
1133
|
-
)
|
1313
|
+
)
|
1314
|
+
end
|
1315
|
+
|
1134
1316
|
sig do
|
1135
|
-
override
|
1136
|
-
|
1137
|
-
|
1138
|
-
|
1139
|
-
|
1140
|
-
|
1141
|
-
|
1142
|
-
|
1143
|
-
|
1144
|
-
|
1145
|
-
|
1317
|
+
override.returns(
|
1318
|
+
{
|
1319
|
+
applies_to_price_ids: T::Array[String],
|
1320
|
+
applies_to_price_interval_ids: T::Array[String],
|
1321
|
+
discount_type: Symbol,
|
1322
|
+
end_date: T.nilable(Time),
|
1323
|
+
percentage_discount: Float,
|
1324
|
+
start_date: Time
|
1325
|
+
}
|
1326
|
+
)
|
1327
|
+
end
|
1328
|
+
def to_hash
|
1146
1329
|
end
|
1147
|
-
def to_hash; end
|
1148
1330
|
end
|
1149
1331
|
|
1150
1332
|
class Usage < Orb::Internal::Type::BaseModel
|
1333
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1334
|
+
|
1151
1335
|
# The price ids that this discount interval applies to.
|
1152
1336
|
sig { returns(T::Array[String]) }
|
1153
1337
|
attr_accessor :applies_to_price_ids
|
@@ -1180,8 +1364,7 @@ module Orb
|
|
1180
1364
|
start_date: Time,
|
1181
1365
|
usage_discount: Float,
|
1182
1366
|
discount_type: Symbol
|
1183
|
-
)
|
1184
|
-
.returns(T.attached_class)
|
1367
|
+
).returns(T.attached_class)
|
1185
1368
|
end
|
1186
1369
|
def self.new(
|
1187
1370
|
# The price ids that this discount interval applies to.
|
@@ -1196,33 +1379,39 @@ module Orb
|
|
1196
1379
|
# discount is for
|
1197
1380
|
usage_discount:,
|
1198
1381
|
discount_type: :usage
|
1199
|
-
)
|
1382
|
+
)
|
1383
|
+
end
|
1384
|
+
|
1200
1385
|
sig do
|
1201
|
-
override
|
1202
|
-
|
1203
|
-
|
1204
|
-
|
1205
|
-
|
1206
|
-
|
1207
|
-
|
1208
|
-
|
1209
|
-
|
1210
|
-
|
1211
|
-
|
1386
|
+
override.returns(
|
1387
|
+
{
|
1388
|
+
applies_to_price_ids: T::Array[String],
|
1389
|
+
applies_to_price_interval_ids: T::Array[String],
|
1390
|
+
discount_type: Symbol,
|
1391
|
+
end_date: T.nilable(Time),
|
1392
|
+
start_date: Time,
|
1393
|
+
usage_discount: Float
|
1394
|
+
}
|
1395
|
+
)
|
1396
|
+
end
|
1397
|
+
def to_hash
|
1212
1398
|
end
|
1213
|
-
def to_hash; end
|
1214
1399
|
end
|
1215
1400
|
|
1216
1401
|
sig do
|
1217
|
-
override
|
1218
|
-
|
1219
|
-
|
1220
|
-
|
1402
|
+
override.returns(
|
1403
|
+
T::Array[
|
1404
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::DiscountInterval::Variants
|
1405
|
+
]
|
1406
|
+
)
|
1407
|
+
end
|
1408
|
+
def self.variants
|
1221
1409
|
end
|
1222
|
-
def self.variants; end
|
1223
1410
|
end
|
1224
1411
|
|
1225
1412
|
class FixedFeeQuantitySchedule < Orb::Internal::Type::BaseModel
|
1413
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1414
|
+
|
1226
1415
|
sig { returns(T.nilable(Time)) }
|
1227
1416
|
attr_accessor :end_date
|
1228
1417
|
|
@@ -1236,18 +1425,33 @@ module Orb
|
|
1236
1425
|
attr_accessor :start_date
|
1237
1426
|
|
1238
1427
|
sig do
|
1239
|
-
params(
|
1240
|
-
.
|
1428
|
+
params(
|
1429
|
+
end_date: T.nilable(Time),
|
1430
|
+
price_id: String,
|
1431
|
+
quantity: Float,
|
1432
|
+
start_date: Time
|
1433
|
+
).returns(T.attached_class)
|
1434
|
+
end
|
1435
|
+
def self.new(end_date:, price_id:, quantity:, start_date:)
|
1241
1436
|
end
|
1242
|
-
def self.new(end_date:, price_id:, quantity:, start_date:); end
|
1243
1437
|
|
1244
1438
|
sig do
|
1245
|
-
override.returns(
|
1439
|
+
override.returns(
|
1440
|
+
{
|
1441
|
+
end_date: T.nilable(Time),
|
1442
|
+
price_id: String,
|
1443
|
+
quantity: Float,
|
1444
|
+
start_date: Time
|
1445
|
+
}
|
1446
|
+
)
|
1447
|
+
end
|
1448
|
+
def to_hash
|
1246
1449
|
end
|
1247
|
-
def to_hash; end
|
1248
1450
|
end
|
1249
1451
|
|
1250
1452
|
class MaximumInterval < Orb::Internal::Type::BaseModel
|
1453
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1454
|
+
|
1251
1455
|
# The price ids that this maximum interval applies to.
|
1252
1456
|
sig { returns(T::Array[String]) }
|
1253
1457
|
attr_accessor :applies_to_price_ids
|
@@ -1276,8 +1480,7 @@ module Orb
|
|
1276
1480
|
end_date: T.nilable(Time),
|
1277
1481
|
maximum_amount: String,
|
1278
1482
|
start_date: Time
|
1279
|
-
)
|
1280
|
-
.returns(T.attached_class)
|
1483
|
+
).returns(T.attached_class)
|
1281
1484
|
end
|
1282
1485
|
def self.new(
|
1283
1486
|
# The price ids that this maximum interval applies to.
|
@@ -1291,23 +1494,27 @@ module Orb
|
|
1291
1494
|
maximum_amount:,
|
1292
1495
|
# The start date of the maximum interval.
|
1293
1496
|
start_date:
|
1294
|
-
)
|
1497
|
+
)
|
1498
|
+
end
|
1499
|
+
|
1295
1500
|
sig do
|
1296
|
-
override
|
1297
|
-
|
1298
|
-
|
1299
|
-
|
1300
|
-
|
1301
|
-
|
1302
|
-
|
1303
|
-
|
1304
|
-
|
1305
|
-
|
1501
|
+
override.returns(
|
1502
|
+
{
|
1503
|
+
applies_to_price_ids: T::Array[String],
|
1504
|
+
applies_to_price_interval_ids: T::Array[String],
|
1505
|
+
end_date: T.nilable(Time),
|
1506
|
+
maximum_amount: String,
|
1507
|
+
start_date: Time
|
1508
|
+
}
|
1509
|
+
)
|
1510
|
+
end
|
1511
|
+
def to_hash
|
1306
1512
|
end
|
1307
|
-
def to_hash; end
|
1308
1513
|
end
|
1309
1514
|
|
1310
1515
|
class MinimumInterval < Orb::Internal::Type::BaseModel
|
1516
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1517
|
+
|
1311
1518
|
# The price ids that this minimum interval applies to.
|
1312
1519
|
sig { returns(T::Array[String]) }
|
1313
1520
|
attr_accessor :applies_to_price_ids
|
@@ -1336,8 +1543,7 @@ module Orb
|
|
1336
1543
|
end_date: T.nilable(Time),
|
1337
1544
|
minimum_amount: String,
|
1338
1545
|
start_date: Time
|
1339
|
-
)
|
1340
|
-
.returns(T.attached_class)
|
1546
|
+
).returns(T.attached_class)
|
1341
1547
|
end
|
1342
1548
|
def self.new(
|
1343
1549
|
# The price ids that this minimum interval applies to.
|
@@ -1351,35 +1557,43 @@ module Orb
|
|
1351
1557
|
minimum_amount:,
|
1352
1558
|
# The start date of the minimum interval.
|
1353
1559
|
start_date:
|
1354
|
-
)
|
1560
|
+
)
|
1561
|
+
end
|
1562
|
+
|
1355
1563
|
sig do
|
1356
|
-
override
|
1357
|
-
|
1358
|
-
|
1359
|
-
|
1360
|
-
|
1361
|
-
|
1362
|
-
|
1363
|
-
|
1364
|
-
|
1365
|
-
|
1564
|
+
override.returns(
|
1565
|
+
{
|
1566
|
+
applies_to_price_ids: T::Array[String],
|
1567
|
+
applies_to_price_interval_ids: T::Array[String],
|
1568
|
+
end_date: T.nilable(Time),
|
1569
|
+
minimum_amount: String,
|
1570
|
+
start_date: Time
|
1571
|
+
}
|
1572
|
+
)
|
1573
|
+
end
|
1574
|
+
def to_hash
|
1366
1575
|
end
|
1367
|
-
def to_hash; end
|
1368
1576
|
end
|
1369
1577
|
|
1370
1578
|
class PendingSubscriptionChange < Orb::Internal::Type::BaseModel
|
1579
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1580
|
+
|
1371
1581
|
sig { returns(String) }
|
1372
1582
|
attr_accessor :id
|
1373
1583
|
|
1374
1584
|
# A pending subscription change if one exists on this subscription.
|
1375
1585
|
sig { params(id: String).returns(T.attached_class) }
|
1376
|
-
def self.new(id:)
|
1586
|
+
def self.new(id:)
|
1587
|
+
end
|
1377
1588
|
|
1378
|
-
sig { override.returns({id: String}) }
|
1379
|
-
def to_hash
|
1589
|
+
sig { override.returns({ id: String }) }
|
1590
|
+
def to_hash
|
1591
|
+
end
|
1380
1592
|
end
|
1381
1593
|
|
1382
1594
|
class PriceInterval < Orb::Internal::Type::BaseModel
|
1595
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1596
|
+
|
1383
1597
|
sig { returns(String) }
|
1384
1598
|
attr_accessor :id
|
1385
1599
|
|
@@ -1413,7 +1627,9 @@ module Orb
|
|
1413
1627
|
sig do
|
1414
1628
|
returns(
|
1415
1629
|
T.nilable(
|
1416
|
-
T::Array[
|
1630
|
+
T::Array[
|
1631
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PriceInterval::FixedFeeQuantityTransition
|
1632
|
+
]
|
1417
1633
|
)
|
1418
1634
|
)
|
1419
1635
|
end
|
@@ -1432,34 +1648,34 @@ module Orb
|
|
1432
1648
|
sig do
|
1433
1649
|
returns(
|
1434
1650
|
T.any(
|
1435
|
-
Orb::
|
1436
|
-
Orb::
|
1437
|
-
Orb::
|
1438
|
-
Orb::
|
1439
|
-
Orb::
|
1440
|
-
Orb::
|
1441
|
-
Orb::
|
1442
|
-
Orb::
|
1443
|
-
Orb::
|
1444
|
-
Orb::
|
1445
|
-
Orb::
|
1446
|
-
Orb::
|
1447
|
-
Orb::
|
1448
|
-
Orb::
|
1449
|
-
Orb::
|
1450
|
-
Orb::
|
1451
|
-
Orb::
|
1452
|
-
Orb::
|
1453
|
-
Orb::
|
1454
|
-
Orb::
|
1455
|
-
Orb::
|
1456
|
-
Orb::
|
1457
|
-
Orb::
|
1458
|
-
Orb::
|
1459
|
-
Orb::
|
1460
|
-
Orb::
|
1461
|
-
Orb::
|
1462
|
-
Orb::
|
1651
|
+
Orb::Price::Unit,
|
1652
|
+
Orb::Price::Package,
|
1653
|
+
Orb::Price::Matrix,
|
1654
|
+
Orb::Price::Tiered,
|
1655
|
+
Orb::Price::TieredBps,
|
1656
|
+
Orb::Price::Bps,
|
1657
|
+
Orb::Price::BulkBps,
|
1658
|
+
Orb::Price::Bulk,
|
1659
|
+
Orb::Price::ThresholdTotalAmount,
|
1660
|
+
Orb::Price::TieredPackage,
|
1661
|
+
Orb::Price::GroupedTiered,
|
1662
|
+
Orb::Price::TieredWithMinimum,
|
1663
|
+
Orb::Price::TieredPackageWithMinimum,
|
1664
|
+
Orb::Price::PackageWithAllocation,
|
1665
|
+
Orb::Price::UnitWithPercent,
|
1666
|
+
Orb::Price::MatrixWithAllocation,
|
1667
|
+
Orb::Price::TieredWithProration,
|
1668
|
+
Orb::Price::UnitWithProration,
|
1669
|
+
Orb::Price::GroupedAllocation,
|
1670
|
+
Orb::Price::GroupedWithProratedMinimum,
|
1671
|
+
Orb::Price::GroupedWithMeteredMinimum,
|
1672
|
+
Orb::Price::MatrixWithDisplayName,
|
1673
|
+
Orb::Price::BulkWithProration,
|
1674
|
+
Orb::Price::GroupedTieredPackage,
|
1675
|
+
Orb::Price::MaxGroupTieredPackage,
|
1676
|
+
Orb::Price::ScalableMatrixWithUnitPricing,
|
1677
|
+
Orb::Price::ScalableMatrixWithTieredPricing,
|
1678
|
+
Orb::Price::CumulativeGroupedBulk
|
1463
1679
|
)
|
1464
1680
|
)
|
1465
1681
|
end
|
@@ -1486,49 +1702,46 @@ module Orb
|
|
1486
1702
|
current_billing_period_start_date: T.nilable(Time),
|
1487
1703
|
end_date: T.nilable(Time),
|
1488
1704
|
filter: T.nilable(String),
|
1489
|
-
fixed_fee_quantity_transitions:
|
1490
|
-
T
|
1491
|
-
T
|
1492
|
-
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PriceInterval::FixedFeeQuantityTransition
|
1493
|
-
|
1494
|
-
|
1495
|
-
|
1496
|
-
|
1497
|
-
|
1498
|
-
|
1499
|
-
|
1500
|
-
|
1501
|
-
|
1502
|
-
|
1503
|
-
|
1504
|
-
|
1505
|
-
|
1506
|
-
|
1507
|
-
|
1508
|
-
|
1509
|
-
|
1510
|
-
|
1511
|
-
|
1512
|
-
|
1513
|
-
|
1514
|
-
|
1515
|
-
|
1516
|
-
|
1517
|
-
|
1518
|
-
|
1519
|
-
|
1520
|
-
|
1521
|
-
|
1522
|
-
|
1523
|
-
|
1524
|
-
|
1525
|
-
|
1526
|
-
Orb::Models::Price::CumulativeGroupedBulk
|
1527
|
-
),
|
1705
|
+
fixed_fee_quantity_transitions:
|
1706
|
+
T.nilable(
|
1707
|
+
T::Array[
|
1708
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PriceInterval::FixedFeeQuantityTransition::OrHash
|
1709
|
+
]
|
1710
|
+
),
|
1711
|
+
price:
|
1712
|
+
T.any(
|
1713
|
+
Orb::Price::Unit::OrHash,
|
1714
|
+
Orb::Price::Package::OrHash,
|
1715
|
+
Orb::Price::Matrix::OrHash,
|
1716
|
+
Orb::Price::Tiered::OrHash,
|
1717
|
+
Orb::Price::TieredBps::OrHash,
|
1718
|
+
Orb::Price::Bps::OrHash,
|
1719
|
+
Orb::Price::BulkBps::OrHash,
|
1720
|
+
Orb::Price::Bulk::OrHash,
|
1721
|
+
Orb::Price::ThresholdTotalAmount::OrHash,
|
1722
|
+
Orb::Price::TieredPackage::OrHash,
|
1723
|
+
Orb::Price::GroupedTiered::OrHash,
|
1724
|
+
Orb::Price::TieredWithMinimum::OrHash,
|
1725
|
+
Orb::Price::TieredPackageWithMinimum::OrHash,
|
1726
|
+
Orb::Price::PackageWithAllocation::OrHash,
|
1727
|
+
Orb::Price::UnitWithPercent::OrHash,
|
1728
|
+
Orb::Price::MatrixWithAllocation::OrHash,
|
1729
|
+
Orb::Price::TieredWithProration::OrHash,
|
1730
|
+
Orb::Price::UnitWithProration::OrHash,
|
1731
|
+
Orb::Price::GroupedAllocation::OrHash,
|
1732
|
+
Orb::Price::GroupedWithProratedMinimum::OrHash,
|
1733
|
+
Orb::Price::GroupedWithMeteredMinimum::OrHash,
|
1734
|
+
Orb::Price::MatrixWithDisplayName::OrHash,
|
1735
|
+
Orb::Price::BulkWithProration::OrHash,
|
1736
|
+
Orb::Price::GroupedTieredPackage::OrHash,
|
1737
|
+
Orb::Price::MaxGroupTieredPackage::OrHash,
|
1738
|
+
Orb::Price::ScalableMatrixWithUnitPricing::OrHash,
|
1739
|
+
Orb::Price::ScalableMatrixWithTieredPricing::OrHash,
|
1740
|
+
Orb::Price::CumulativeGroupedBulk::OrHash
|
1741
|
+
),
|
1528
1742
|
start_date: Time,
|
1529
1743
|
usage_customer_ids: T.nilable(T::Array[String])
|
1530
|
-
)
|
1531
|
-
.returns(T.attached_class)
|
1744
|
+
).returns(T.attached_class)
|
1532
1745
|
end
|
1533
1746
|
def self.new(
|
1534
1747
|
id:,
|
@@ -1567,58 +1780,66 @@ module Orb
|
|
1567
1780
|
# A list of customer IDs whose usage events will be aggregated and billed under
|
1568
1781
|
# this price interval.
|
1569
1782
|
usage_customer_ids:
|
1570
|
-
)
|
1783
|
+
)
|
1784
|
+
end
|
1785
|
+
|
1571
1786
|
sig do
|
1572
|
-
override
|
1573
|
-
|
1574
|
-
|
1575
|
-
|
1576
|
-
|
1577
|
-
|
1578
|
-
|
1579
|
-
|
1580
|
-
|
1581
|
-
|
1582
|
-
T::Array[
|
1787
|
+
override.returns(
|
1788
|
+
{
|
1789
|
+
id: String,
|
1790
|
+
billing_cycle_day: Integer,
|
1791
|
+
current_billing_period_end_date: T.nilable(Time),
|
1792
|
+
current_billing_period_start_date: T.nilable(Time),
|
1793
|
+
end_date: T.nilable(Time),
|
1794
|
+
filter: T.nilable(String),
|
1795
|
+
fixed_fee_quantity_transitions:
|
1796
|
+
T.nilable(
|
1797
|
+
T::Array[
|
1798
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::PriceInterval::FixedFeeQuantityTransition
|
1799
|
+
]
|
1583
1800
|
),
|
1584
|
-
|
1585
|
-
|
1586
|
-
Orb::
|
1587
|
-
Orb::
|
1588
|
-
Orb::
|
1589
|
-
Orb::
|
1590
|
-
Orb::
|
1591
|
-
Orb::
|
1592
|
-
Orb::
|
1593
|
-
Orb::
|
1594
|
-
Orb::
|
1595
|
-
Orb::
|
1596
|
-
Orb::
|
1597
|
-
Orb::
|
1598
|
-
Orb::
|
1599
|
-
Orb::
|
1600
|
-
Orb::
|
1601
|
-
Orb::
|
1602
|
-
Orb::
|
1603
|
-
Orb::
|
1604
|
-
Orb::
|
1605
|
-
Orb::
|
1606
|
-
Orb::
|
1607
|
-
Orb::
|
1608
|
-
Orb::
|
1609
|
-
Orb::
|
1610
|
-
Orb::
|
1611
|
-
Orb::
|
1612
|
-
Orb::
|
1801
|
+
price:
|
1802
|
+
T.any(
|
1803
|
+
Orb::Price::Unit,
|
1804
|
+
Orb::Price::Package,
|
1805
|
+
Orb::Price::Matrix,
|
1806
|
+
Orb::Price::Tiered,
|
1807
|
+
Orb::Price::TieredBps,
|
1808
|
+
Orb::Price::Bps,
|
1809
|
+
Orb::Price::BulkBps,
|
1810
|
+
Orb::Price::Bulk,
|
1811
|
+
Orb::Price::ThresholdTotalAmount,
|
1812
|
+
Orb::Price::TieredPackage,
|
1813
|
+
Orb::Price::GroupedTiered,
|
1814
|
+
Orb::Price::TieredWithMinimum,
|
1815
|
+
Orb::Price::TieredPackageWithMinimum,
|
1816
|
+
Orb::Price::PackageWithAllocation,
|
1817
|
+
Orb::Price::UnitWithPercent,
|
1818
|
+
Orb::Price::MatrixWithAllocation,
|
1819
|
+
Orb::Price::TieredWithProration,
|
1820
|
+
Orb::Price::UnitWithProration,
|
1821
|
+
Orb::Price::GroupedAllocation,
|
1822
|
+
Orb::Price::GroupedWithProratedMinimum,
|
1823
|
+
Orb::Price::GroupedWithMeteredMinimum,
|
1824
|
+
Orb::Price::MatrixWithDisplayName,
|
1825
|
+
Orb::Price::BulkWithProration,
|
1826
|
+
Orb::Price::GroupedTieredPackage,
|
1827
|
+
Orb::Price::MaxGroupTieredPackage,
|
1828
|
+
Orb::Price::ScalableMatrixWithUnitPricing,
|
1829
|
+
Orb::Price::ScalableMatrixWithTieredPricing,
|
1830
|
+
Orb::Price::CumulativeGroupedBulk
|
1613
1831
|
),
|
1614
|
-
|
1615
|
-
|
1616
|
-
|
1617
|
-
|
1832
|
+
start_date: Time,
|
1833
|
+
usage_customer_ids: T.nilable(T::Array[String])
|
1834
|
+
}
|
1835
|
+
)
|
1836
|
+
end
|
1837
|
+
def to_hash
|
1618
1838
|
end
|
1619
|
-
def to_hash; end
|
1620
1839
|
|
1621
1840
|
class FixedFeeQuantityTransition < Orb::Internal::Type::BaseModel
|
1841
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1842
|
+
|
1622
1843
|
sig { returns(Time) }
|
1623
1844
|
attr_accessor :effective_date
|
1624
1845
|
|
@@ -1629,16 +1850,28 @@ module Orb
|
|
1629
1850
|
attr_accessor :quantity
|
1630
1851
|
|
1631
1852
|
sig do
|
1632
|
-
params(
|
1853
|
+
params(
|
1854
|
+
effective_date: Time,
|
1855
|
+
price_id: String,
|
1856
|
+
quantity: Integer
|
1857
|
+
).returns(T.attached_class)
|
1858
|
+
end
|
1859
|
+
def self.new(effective_date:, price_id:, quantity:)
|
1633
1860
|
end
|
1634
|
-
def self.new(effective_date:, price_id:, quantity:); end
|
1635
1861
|
|
1636
|
-
sig
|
1637
|
-
|
1862
|
+
sig do
|
1863
|
+
override.returns(
|
1864
|
+
{ effective_date: Time, price_id: String, quantity: Integer }
|
1865
|
+
)
|
1866
|
+
end
|
1867
|
+
def to_hash
|
1868
|
+
end
|
1638
1869
|
end
|
1639
1870
|
end
|
1640
1871
|
|
1641
1872
|
class RedeemedCoupon < Orb::Internal::Type::BaseModel
|
1873
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1874
|
+
|
1642
1875
|
sig { returns(String) }
|
1643
1876
|
attr_accessor :coupon_id
|
1644
1877
|
|
@@ -1649,60 +1882,95 @@ module Orb
|
|
1649
1882
|
attr_accessor :start_date
|
1650
1883
|
|
1651
1884
|
sig do
|
1652
|
-
params(
|
1885
|
+
params(
|
1886
|
+
coupon_id: String,
|
1887
|
+
end_date: T.nilable(Time),
|
1888
|
+
start_date: Time
|
1889
|
+
).returns(T.attached_class)
|
1890
|
+
end
|
1891
|
+
def self.new(coupon_id:, end_date:, start_date:)
|
1653
1892
|
end
|
1654
|
-
def self.new(coupon_id:, end_date:, start_date:); end
|
1655
1893
|
|
1656
|
-
sig
|
1657
|
-
|
1894
|
+
sig do
|
1895
|
+
override.returns(
|
1896
|
+
{ coupon_id: String, end_date: T.nilable(Time), start_date: Time }
|
1897
|
+
)
|
1898
|
+
end
|
1899
|
+
def to_hash
|
1900
|
+
end
|
1658
1901
|
end
|
1659
1902
|
|
1660
1903
|
module Status
|
1661
1904
|
extend Orb::Internal::Type::Enum
|
1662
1905
|
|
1663
1906
|
TaggedSymbol =
|
1664
|
-
T.type_alias
|
1907
|
+
T.type_alias do
|
1908
|
+
T.all(
|
1909
|
+
Symbol,
|
1910
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::Status
|
1911
|
+
)
|
1912
|
+
end
|
1665
1913
|
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
1666
1914
|
|
1667
1915
|
ACTIVE =
|
1668
|
-
T.let(
|
1669
|
-
|
1916
|
+
T.let(
|
1917
|
+
:active,
|
1918
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::Status::TaggedSymbol
|
1919
|
+
)
|
1920
|
+
ENDED =
|
1921
|
+
T.let(
|
1922
|
+
:ended,
|
1923
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::Status::TaggedSymbol
|
1924
|
+
)
|
1670
1925
|
UPCOMING =
|
1671
|
-
T.let(
|
1926
|
+
T.let(
|
1927
|
+
:upcoming,
|
1928
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::Status::TaggedSymbol
|
1929
|
+
)
|
1672
1930
|
|
1673
1931
|
sig do
|
1674
|
-
override
|
1675
|
-
|
1932
|
+
override.returns(
|
1933
|
+
T::Array[
|
1934
|
+
Orb::Models::SubscriptionChangeCancelResponse::Subscription::Status::TaggedSymbol
|
1935
|
+
]
|
1936
|
+
)
|
1937
|
+
end
|
1938
|
+
def self.values
|
1676
1939
|
end
|
1677
|
-
def self.values; end
|
1678
1940
|
end
|
1679
1941
|
|
1680
1942
|
class TrialInfo < Orb::Internal::Type::BaseModel
|
1943
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1944
|
+
|
1681
1945
|
sig { returns(T.nilable(Time)) }
|
1682
1946
|
attr_accessor :end_date
|
1683
1947
|
|
1684
1948
|
sig { params(end_date: T.nilable(Time)).returns(T.attached_class) }
|
1685
|
-
def self.new(end_date:)
|
1949
|
+
def self.new(end_date:)
|
1950
|
+
end
|
1686
1951
|
|
1687
|
-
sig { override.returns({end_date: T.nilable(Time)}) }
|
1688
|
-
def to_hash
|
1952
|
+
sig { override.returns({ end_date: T.nilable(Time) }) }
|
1953
|
+
def to_hash
|
1954
|
+
end
|
1689
1955
|
end
|
1690
1956
|
|
1691
1957
|
class ChangedResources < Orb::Internal::Type::BaseModel
|
1958
|
+
OrHash = T.type_alias { T.any(T.self_type, Orb::Internal::AnyHash) }
|
1959
|
+
|
1692
1960
|
# The credit notes that were created as part of this operation.
|
1693
|
-
sig { returns(T::Array[Orb::
|
1961
|
+
sig { returns(T::Array[Orb::CreditNote]) }
|
1694
1962
|
attr_accessor :created_credit_notes
|
1695
1963
|
|
1696
1964
|
# The invoices that were created as part of this operation.
|
1697
|
-
sig { returns(T::Array[Orb::
|
1965
|
+
sig { returns(T::Array[Orb::Invoice]) }
|
1698
1966
|
attr_accessor :created_invoices
|
1699
1967
|
|
1700
1968
|
# The credit notes that were voided as part of this operation.
|
1701
|
-
sig { returns(T::Array[Orb::
|
1969
|
+
sig { returns(T::Array[Orb::CreditNote]) }
|
1702
1970
|
attr_accessor :voided_credit_notes
|
1703
1971
|
|
1704
1972
|
# The invoices that were voided as part of this operation.
|
1705
|
-
sig { returns(T::Array[Orb::
|
1973
|
+
sig { returns(T::Array[Orb::Invoice]) }
|
1706
1974
|
attr_accessor :voided_invoices
|
1707
1975
|
|
1708
1976
|
# The resources that were changed as part of this operation. Only present when
|
@@ -1710,12 +1978,11 @@ module Orb
|
|
1710
1978
|
# `include_changed_resources` parameter was passed in the request.
|
1711
1979
|
sig do
|
1712
1980
|
params(
|
1713
|
-
created_credit_notes: T::Array[
|
1714
|
-
created_invoices: T::Array[
|
1715
|
-
voided_credit_notes: T::Array[
|
1716
|
-
voided_invoices: T::Array[
|
1717
|
-
)
|
1718
|
-
.returns(T.attached_class)
|
1981
|
+
created_credit_notes: T::Array[Orb::CreditNote::OrHash],
|
1982
|
+
created_invoices: T::Array[Orb::Invoice::OrHash],
|
1983
|
+
voided_credit_notes: T::Array[Orb::CreditNote::OrHash],
|
1984
|
+
voided_invoices: T::Array[Orb::Invoice::OrHash]
|
1985
|
+
).returns(T.attached_class)
|
1719
1986
|
end
|
1720
1987
|
def self.new(
|
1721
1988
|
# The credit notes that were created as part of this operation.
|
@@ -1726,19 +1993,21 @@ module Orb
|
|
1726
1993
|
voided_credit_notes:,
|
1727
1994
|
# The invoices that were voided as part of this operation.
|
1728
1995
|
voided_invoices:
|
1729
|
-
)
|
1996
|
+
)
|
1997
|
+
end
|
1998
|
+
|
1730
1999
|
sig do
|
1731
|
-
override
|
1732
|
-
|
1733
|
-
|
1734
|
-
|
1735
|
-
|
1736
|
-
|
1737
|
-
|
1738
|
-
|
1739
|
-
|
2000
|
+
override.returns(
|
2001
|
+
{
|
2002
|
+
created_credit_notes: T::Array[Orb::CreditNote],
|
2003
|
+
created_invoices: T::Array[Orb::Invoice],
|
2004
|
+
voided_credit_notes: T::Array[Orb::CreditNote],
|
2005
|
+
voided_invoices: T::Array[Orb::Invoice]
|
2006
|
+
}
|
2007
|
+
)
|
2008
|
+
end
|
2009
|
+
def to_hash
|
1740
2010
|
end
|
1741
|
-
def to_hash; end
|
1742
2011
|
end
|
1743
2012
|
end
|
1744
2013
|
end
|