orb-billing 0.3.1 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +35 -0
- data/README.md +3 -3
- data/lib/orb/errors.rb +1 -1
- data/lib/orb/file_part.rb +2 -2
- data/lib/orb/internal/transport/base_client.rb +74 -5
- data/lib/orb/internal/transport/pooled_net_requester.rb +14 -0
- data/lib/orb/internal/type/array_of.rb +1 -1
- data/lib/orb/internal/type/base_model.rb +62 -30
- data/lib/orb/internal/type/converter.rb +18 -0
- data/lib/orb/internal/type/enum.rb +4 -3
- data/lib/orb/internal/type/hash_of.rb +1 -1
- data/lib/orb/internal/type/request_parameters.rb +4 -4
- data/lib/orb/internal/type/union.rb +5 -4
- data/lib/orb/internal/util.rb +57 -1
- data/lib/orb/internal.rb +6 -0
- 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 +13 -12
- data/lib/orb/models/coupon_create_params.rb +12 -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 +50 -53
- data/lib/orb/models/customer_list_params.rb +0 -1
- data/lib/orb/models/customer_update_by_external_id_params.rb +50 -53
- data/lib/orb/models/customer_update_params.rb +50 -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 +14 -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 +14 -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 +14 -7
- data/lib/orb/models/customers/credits/ledger_list_params.rb +8 -9
- data/lib/orb/models/customers/credits/ledger_list_response.rb +14 -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 +11 -5
- data/lib/orb/models/evaluate_price_group.rb +5 -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 +179 -202
- data/lib/orb/models/invoice_create_params.rb +14 -21
- data/lib/orb/models/invoice_fetch_upcoming_response.rb +31 -54
- data/lib/orb/models/invoice_issue_params.rb +0 -1
- data/lib/orb/models/invoice_level_discount.rb +8 -4
- data/lib/orb/models/invoice_line_item_create_params.rb +0 -1
- data/lib/orb/models/invoice_line_item_create_response.rb +28 -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 +90 -103
- data/lib/orb/models/plan_create_params.rb +759 -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 +1706 -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 +108 -122
- data/lib/orb/models/subscription_cancel_params.rb +3 -5
- data/lib/orb/models/subscription_cancel_response.rb +43 -57
- data/lib/orb/models/subscription_change_apply_response.rb +43 -58
- data/lib/orb/models/subscription_change_cancel_response.rb +43 -58
- data/lib/orb/models/subscription_change_retrieve_response.rb +43 -58
- data/lib/orb/models/subscription_create_params.rb +1953 -1815
- data/lib/orb/models/subscription_create_response.rb +43 -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 +1194 -1017
- data/lib/orb/models/subscription_price_intervals_response.rb +43 -57
- data/lib/orb/models/subscription_schedule_plan_change_params.rb +1994 -1791
- data/lib/orb/models/subscription_schedule_plan_change_response.rb +43 -57
- data/lib/orb/models/subscription_trigger_phase_params.rb +0 -2
- data/lib/orb/models/subscription_trigger_phase_response.rb +43 -57
- data/lib/orb/models/subscription_unschedule_cancellation_response.rb +43 -57
- data/lib/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rb +43 -57
- data/lib/orb/models/subscription_unschedule_pending_plan_changes_response.rb +43 -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 +43 -57
- data/lib/orb/models/subscription_update_params.rb +0 -5
- data/lib/orb/models/subscription_update_trial_params.rb +8 -6
- data/lib/orb/models/subscription_update_trial_response.rb +43 -57
- data/lib/orb/models/subscription_usage.rb +55 -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/models.rb +24 -0
- data/lib/orb/request_options.rb +4 -0
- 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 +3 -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 +20 -6
- data/rbi/orb/internal/transport/base_client.rbi +159 -78
- data/rbi/orb/internal/transport/pooled_net_requester.rbi +27 -13
- data/rbi/orb/internal/type/array_of.rbi +42 -34
- data/rbi/orb/internal/type/base_model.rbi +144 -69
- data/rbi/orb/internal/type/base_page.rbi +12 -8
- data/rbi/orb/internal/type/boolean.rbi +16 -10
- data/rbi/orb/internal/type/converter.rbi +68 -31
- data/rbi/orb/internal/type/enum.rbi +28 -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 +61 -25
- data/rbi/orb/internal/type/unknown.rbi +20 -12
- data/rbi/orb/internal/util.rbi +232 -90
- data/rbi/orb/internal.rbi +2 -0
- data/rbi/orb/models/alert.rbi +114 -70
- data/rbi/orb/models/alert_create_for_customer_params.rbi +69 -27
- data/rbi/orb/models/alert_create_for_external_customer_params.rbi +80 -29
- data/rbi/orb/models/alert_create_for_subscription_params.rbi +62 -26
- data/rbi/orb/models/alert_disable_params.rbi +18 -6
- data/rbi/orb/models/alert_enable_params.rbi +18 -6
- data/rbi/orb/models/alert_list_params.rbi +24 -20
- data/rbi/orb/models/alert_retrieve_params.rbi +11 -4
- data/rbi/orb/models/alert_update_params.rbi +29 -14
- data/rbi/orb/models/amount_discount.rbi +29 -19
- data/rbi/orb/models/billable_metric.rbi +34 -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 +11 -4
- data/rbi/orb/models/coupon_create_params.rbi +85 -38
- data/rbi/orb/models/coupon_fetch_params.rbi +11 -4
- data/rbi/orb/models/coupon_list_params.rbi +19 -15
- data/rbi/orb/models/coupons/subscription_list_params.rbi +19 -6
- data/rbi/orb/models/credit_note.rbi +329 -158
- data/rbi/orb/models/credit_note_create_params.rbi +64 -29
- data/rbi/orb/models/credit_note_fetch_params.rbi +13 -4
- data/rbi/orb/models/credit_note_list_params.rbi +23 -17
- data/rbi/orb/models/customer.rbi +461 -329
- data/rbi/orb/models/customer_create_params.rbi +713 -325
- data/rbi/orb/models/customer_delete_params.rbi +13 -4
- data/rbi/orb/models/customer_fetch_by_external_id_params.rbi +13 -4
- data/rbi/orb/models/customer_fetch_params.rbi +11 -4
- data/rbi/orb/models/customer_list_params.rbi +21 -17
- data/rbi/orb/models/customer_sync_payment_methods_from_gateway_by_external_customer_id_params.rbi +16 -4
- data/rbi/orb/models/customer_sync_payment_methods_from_gateway_params.rbi +16 -4
- data/rbi/orb/models/customer_update_by_external_id_params.rbi +1193 -336
- data/rbi/orb/models/customer_update_params.rbi +712 -324
- data/rbi/orb/models/customers/balance_transaction_create_params.rbi +56 -21
- data/rbi/orb/models/customers/balance_transaction_create_response.rbi +172 -61
- data/rbi/orb/models/customers/balance_transaction_list_params.rbi +26 -17
- data/rbi/orb/models/customers/balance_transaction_list_response.rbi +182 -59
- data/rbi/orb/models/customers/cost_list_by_external_id_params.rbi +62 -22
- data/rbi/orb/models/customers/cost_list_by_external_id_response.rbi +180 -124
- data/rbi/orb/models/customers/cost_list_params.rbi +48 -22
- data/rbi/orb/models/customers/cost_list_response.rbi +172 -123
- data/rbi/orb/models/customers/credit_list_by_external_id_params.rbi +24 -15
- data/rbi/orb/models/customers/credit_list_by_external_id_response.rbi +54 -22
- data/rbi/orb/models/customers/credit_list_params.rbi +21 -15
- data/rbi/orb/models/customers/credit_list_response.rbi +50 -21
- data/rbi/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rbi +118 -68
- data/rbi/orb/models/customers/credits/ledger_create_entry_by_external_id_response.rbi +755 -434
- data/rbi/orb/models/customers/credits/ledger_create_entry_params.rbi +129 -59
- data/rbi/orb/models/customers/credits/ledger_create_entry_response.rbi +812 -425
- data/rbi/orb/models/customers/credits/ledger_list_by_external_id_params.rbi +108 -44
- data/rbi/orb/models/customers/credits/ledger_list_by_external_id_response.rbi +793 -432
- data/rbi/orb/models/customers/credits/ledger_list_params.rbi +129 -40
- data/rbi/orb/models/customers/credits/ledger_list_response.rbi +847 -389
- data/rbi/orb/models/customers/credits/top_up_create_by_external_id_params.rbi +86 -53
- data/rbi/orb/models/customers/credits/top_up_create_by_external_id_response.rbi +77 -48
- data/rbi/orb/models/customers/credits/top_up_create_params.rbi +96 -45
- data/rbi/orb/models/customers/credits/top_up_create_response.rbi +95 -43
- data/rbi/orb/models/customers/credits/top_up_delete_by_external_id_params.rbi +22 -6
- data/rbi/orb/models/customers/credits/top_up_delete_params.rbi +21 -5
- data/rbi/orb/models/customers/credits/top_up_list_by_external_id_params.rbi +15 -5
- data/rbi/orb/models/customers/credits/top_up_list_by_external_id_response.rbi +82 -49
- data/rbi/orb/models/customers/credits/top_up_list_params.rbi +15 -5
- data/rbi/orb/models/customers/credits/top_up_list_response.rbi +96 -43
- data/rbi/orb/models/dimensional_price_group.rbi +21 -15
- data/rbi/orb/models/dimensional_price_group_create_params.rbi +22 -16
- data/rbi/orb/models/dimensional_price_group_list_params.rbi +19 -6
- data/rbi/orb/models/dimensional_price_group_retrieve_params.rbi +16 -4
- data/rbi/orb/models/dimensional_price_groups/external_dimensional_price_group_id_retrieve_params.rbi +15 -8
- data/rbi/orb/models/dimensional_price_groups.rbi +21 -13
- data/rbi/orb/models/discount.rbi +11 -5
- data/rbi/orb/models/evaluate_price_group.rbi +29 -12
- data/rbi/orb/models/event_deprecate_params.rbi +13 -4
- data/rbi/orb/models/event_deprecate_response.rbi +11 -3
- data/rbi/orb/models/event_ingest_params.rbi +41 -31
- data/rbi/orb/models/event_ingest_response.rbi +78 -23
- data/rbi/orb/models/event_search_params.rbi +18 -14
- data/rbi/orb/models/event_search_response.rbi +42 -21
- data/rbi/orb/models/event_update_params.rbi +20 -16
- data/rbi/orb/models/event_update_response.rbi +11 -3
- data/rbi/orb/models/events/backfill_close_params.rbi +13 -9
- data/rbi/orb/models/events/backfill_close_response.rbi +70 -29
- data/rbi/orb/models/events/backfill_create_params.rbi +24 -18
- data/rbi/orb/models/events/backfill_create_response.rbi +69 -29
- data/rbi/orb/models/events/backfill_fetch_params.rbi +13 -9
- data/rbi/orb/models/events/backfill_fetch_response.rbi +70 -29
- data/rbi/orb/models/events/backfill_list_params.rbi +19 -6
- data/rbi/orb/models/events/backfill_list_response.rbi +68 -28
- data/rbi/orb/models/events/backfill_revert_params.rbi +13 -9
- data/rbi/orb/models/events/backfill_revert_response.rbi +69 -29
- data/rbi/orb/models/events/event_volumes.rbi +38 -10
- data/rbi/orb/models/events/volume_list_params.rbi +21 -15
- data/rbi/orb/models/invoice.rbi +1411 -805
- data/rbi/orb/models/invoice_create_params.rbi +107 -69
- data/rbi/orb/models/invoice_fetch_params.rbi +11 -4
- data/rbi/orb/models/invoice_fetch_upcoming_params.rbi +18 -5
- data/rbi/orb/models/invoice_fetch_upcoming_response.rbi +2187 -876
- data/rbi/orb/models/invoice_issue_params.rbi +17 -5
- data/rbi/orb/models/invoice_level_discount.rbi +11 -4
- data/rbi/orb/models/invoice_line_item_create_params.rbi +23 -17
- data/rbi/orb/models/invoice_line_item_create_response.rbi +675 -376
- data/rbi/orb/models/invoice_list_params.rbi +68 -47
- data/rbi/orb/models/invoice_mark_paid_params.rbi +20 -14
- data/rbi/orb/models/invoice_pay_params.rbi +11 -4
- data/rbi/orb/models/invoice_update_params.rbi +16 -10
- data/rbi/orb/models/invoice_void_params.rbi +11 -4
- data/rbi/orb/models/item.rbi +90 -39
- data/rbi/orb/models/item_create_params.rbi +15 -5
- data/rbi/orb/models/item_fetch_params.rbi +11 -4
- data/rbi/orb/models/item_list_params.rbi +17 -6
- data/rbi/orb/models/item_update_params.rbi +86 -39
- data/rbi/orb/models/metric_create_params.rbi +20 -16
- data/rbi/orb/models/metric_fetch_params.rbi +11 -4
- data/rbi/orb/models/metric_list_params.rbi +21 -17
- data/rbi/orb/models/metric_update_params.rbi +16 -10
- data/rbi/orb/models/pagination_metadata.rbi +17 -4
- data/rbi/orb/models/percentage_discount.rbi +33 -19
- data/rbi/orb/models/plan.rbi +532 -365
- data/rbi/orb/models/plan_create_params.rbi +5295 -2870
- data/rbi/orb/models/plan_fetch_params.rbi +11 -4
- data/rbi/orb/models/plan_list_params.rbi +35 -27
- data/rbi/orb/models/plan_update_params.rbi +17 -13
- data/rbi/orb/models/plans/external_plan_id_fetch_params.rbi +13 -9
- data/rbi/orb/models/plans/external_plan_id_update_params.rbi +22 -13
- data/rbi/orb/models/price.rbi +11332 -5033
- data/rbi/orb/models/price_create_params.rbi +583 -245
- data/rbi/orb/models/price_evaluate_params.rbi +21 -17
- data/rbi/orb/models/price_evaluate_response.rbi +14 -6
- data/rbi/orb/models/price_fetch_params.rbi +11 -4
- data/rbi/orb/models/price_list_params.rbi +17 -6
- data/rbi/orb/models/price_update_params.rbi +16 -10
- data/rbi/orb/models/prices/external_price_id_fetch_params.rbi +15 -8
- data/rbi/orb/models/prices/external_price_id_update_params.rbi +21 -10
- data/rbi/orb/models/subscription.rbi +668 -420
- data/rbi/orb/models/subscription_cancel_params.rbi +47 -22
- data/rbi/orb/models/subscription_cancel_response.rbi +817 -438
- data/rbi/orb/models/subscription_change_apply_params.rbi +19 -13
- data/rbi/orb/models/subscription_change_apply_response.rbi +906 -505
- data/rbi/orb/models/subscription_change_cancel_params.rbi +13 -4
- data/rbi/orb/models/subscription_change_cancel_response.rbi +906 -516
- data/rbi/orb/models/subscription_change_retrieve_params.rbi +13 -4
- data/rbi/orb/models/subscription_change_retrieve_response.rbi +903 -524
- data/rbi/orb/models/subscription_create_params.rbi +10096 -6746
- data/rbi/orb/models/subscription_create_response.rbi +817 -438
- data/rbi/orb/models/subscription_fetch_costs_params.rbi +50 -22
- data/rbi/orb/models/subscription_fetch_costs_response.rbi +172 -123
- data/rbi/orb/models/subscription_fetch_params.rbi +13 -4
- data/rbi/orb/models/subscription_fetch_schedule_params.rbi +23 -17
- data/rbi/orb/models/subscription_fetch_schedule_response.rbi +45 -19
- data/rbi/orb/models/subscription_fetch_usage_params.rbi +84 -34
- data/rbi/orb/models/subscription_list_params.rbi +42 -28
- data/rbi/orb/models/subscription_price_intervals_params.rbi +5798 -3823
- data/rbi/orb/models/subscription_price_intervals_response.rbi +840 -453
- data/rbi/orb/models/subscription_schedule_plan_change_params.rbi +9676 -6922
- data/rbi/orb/models/subscription_schedule_plan_change_response.rbi +838 -467
- data/rbi/orb/models/subscription_trigger_phase_params.rbi +19 -13
- data/rbi/orb/models/subscription_trigger_phase_response.rbi +832 -448
- data/rbi/orb/models/subscription_unschedule_cancellation_params.rbi +16 -4
- data/rbi/orb/models/subscription_unschedule_cancellation_response.rbi +839 -467
- data/rbi/orb/models/subscription_unschedule_fixed_fee_quantity_updates_params.rbi +22 -5
- data/rbi/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rbi +815 -504
- data/rbi/orb/models/subscription_unschedule_pending_plan_changes_params.rbi +16 -4
- data/rbi/orb/models/subscription_unschedule_pending_plan_changes_response.rbi +828 -497
- data/rbi/orb/models/subscription_update_fixed_fee_quantity_params.rbi +63 -26
- data/rbi/orb/models/subscription_update_fixed_fee_quantity_response.rbi +839 -467
- data/rbi/orb/models/subscription_update_params.rbi +22 -16
- data/rbi/orb/models/subscription_update_trial_params.rbi +60 -19
- data/rbi/orb/models/subscription_update_trial_response.rbi +832 -447
- data/rbi/orb/models/subscription_usage.rbi +325 -121
- data/rbi/orb/models/subscriptions.rbi +19 -11
- data/rbi/orb/models/top_level_ping_params.rbi +11 -4
- data/rbi/orb/models/top_level_ping_response.rbi +10 -3
- data/rbi/orb/models/trial_discount.rbi +30 -20
- data/rbi/orb/models/usage_discount.rbi +29 -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/transport/base_client.rbs +16 -1
- data/sig/orb/internal/transport/pooled_net_requester.rbs +2 -0
- data/sig/orb/internal/type/base_model.rbs +11 -5
- data/sig/orb/internal/type/base_page.rbs +1 -1
- data/sig/orb/internal/type/converter.rbs +2 -0
- data/sig/orb/internal/type/enum.rbs +1 -0
- data/sig/orb/internal/type/request_parameters.rbs +3 -1
- data/sig/orb/internal/type/union.rbs +1 -0
- data/sig/orb/internal/util.rbs +13 -0
- data/sig/orb/internal.rbs +2 -0
- 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,14 @@
|
|
3
3
|
module Orb
|
4
4
|
module Models
|
5
5
|
class SubscriptionUpdateTrialResponse < Orb::Internal::Type::BaseModel
|
6
|
+
OrHash =
|
7
|
+
T.type_alias do
|
8
|
+
T.any(
|
9
|
+
Orb::Models::SubscriptionUpdateTrialResponse,
|
10
|
+
Orb::Internal::AnyHash
|
11
|
+
)
|
12
|
+
end
|
13
|
+
|
6
14
|
sig { returns(String) }
|
7
15
|
attr_accessor :id
|
8
16
|
|
@@ -13,7 +21,13 @@ module Orb
|
|
13
21
|
|
14
22
|
# The adjustment intervals for this subscription sorted by the start_date of the
|
15
23
|
# adjustment interval.
|
16
|
-
sig
|
24
|
+
sig do
|
25
|
+
returns(
|
26
|
+
T::Array[
|
27
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval
|
28
|
+
]
|
29
|
+
)
|
30
|
+
end
|
17
31
|
attr_accessor :adjustment_intervals
|
18
32
|
|
19
33
|
# Determines whether issued invoices for this subscription will automatically be
|
@@ -22,17 +36,18 @@ module Orb
|
|
22
36
|
sig { returns(T.nilable(T::Boolean)) }
|
23
37
|
attr_accessor :auto_collection
|
24
38
|
|
25
|
-
sig
|
39
|
+
sig do
|
40
|
+
returns(
|
41
|
+
Orb::Models::SubscriptionUpdateTrialResponse::BillingCycleAnchorConfiguration
|
42
|
+
)
|
43
|
+
end
|
26
44
|
attr_reader :billing_cycle_anchor_configuration
|
27
45
|
|
28
46
|
sig do
|
29
47
|
params(
|
30
|
-
billing_cycle_anchor_configuration:
|
31
|
-
Orb::Models::SubscriptionUpdateTrialResponse::BillingCycleAnchorConfiguration
|
32
|
-
|
33
|
-
)
|
34
|
-
)
|
35
|
-
.void
|
48
|
+
billing_cycle_anchor_configuration:
|
49
|
+
Orb::Models::SubscriptionUpdateTrialResponse::BillingCycleAnchorConfiguration::OrHash
|
50
|
+
).void
|
36
51
|
end
|
37
52
|
attr_writer :billing_cycle_anchor_configuration
|
38
53
|
|
@@ -76,10 +91,10 @@ module Orb
|
|
76
91
|
# [IANA timezone database](https://www.iana.org/time-zones)), which defaults to
|
77
92
|
# your account's timezone. See [Timezone localization](/essentials/timezones) for
|
78
93
|
# information on what this timezone parameter influences within Orb.
|
79
|
-
sig { returns(Orb::
|
94
|
+
sig { returns(Orb::Customer) }
|
80
95
|
attr_reader :customer
|
81
96
|
|
82
|
-
sig { params(customer:
|
97
|
+
sig { params(customer: Orb::Customer::OrHash).void }
|
83
98
|
attr_writer :customer
|
84
99
|
|
85
100
|
# Determines the default memo on this subscriptions' invoices. Note that if this
|
@@ -105,14 +120,26 @@ module Orb
|
|
105
120
|
sig { returns(T.nilable(Time)) }
|
106
121
|
attr_accessor :end_date
|
107
122
|
|
108
|
-
sig
|
123
|
+
sig do
|
124
|
+
returns(
|
125
|
+
T::Array[
|
126
|
+
Orb::Models::SubscriptionUpdateTrialResponse::FixedFeeQuantitySchedule
|
127
|
+
]
|
128
|
+
)
|
129
|
+
end
|
109
130
|
attr_accessor :fixed_fee_quantity_schedule
|
110
131
|
|
111
132
|
sig { returns(T.nilable(String)) }
|
112
133
|
attr_accessor :invoicing_threshold
|
113
134
|
|
114
135
|
# The maximum intervals for this subscription sorted by the start_date.
|
115
|
-
sig
|
136
|
+
sig do
|
137
|
+
returns(
|
138
|
+
T::Array[
|
139
|
+
Orb::Models::SubscriptionUpdateTrialResponse::MaximumInterval
|
140
|
+
]
|
141
|
+
)
|
142
|
+
end
|
116
143
|
attr_accessor :maximum_intervals
|
117
144
|
|
118
145
|
# User specified key-value pairs for the resource. If not present, this defaults
|
@@ -123,7 +150,13 @@ module Orb
|
|
123
150
|
attr_accessor :metadata
|
124
151
|
|
125
152
|
# The minimum intervals for this subscription sorted by the start_date.
|
126
|
-
sig
|
153
|
+
sig do
|
154
|
+
returns(
|
155
|
+
T::Array[
|
156
|
+
Orb::Models::SubscriptionUpdateTrialResponse::MinimumInterval
|
157
|
+
]
|
158
|
+
)
|
159
|
+
end
|
127
160
|
attr_accessor :minimum_intervals
|
128
161
|
|
129
162
|
# Determines the difference between the invoice issue date for subscription
|
@@ -134,16 +167,22 @@ module Orb
|
|
134
167
|
attr_accessor :net_terms
|
135
168
|
|
136
169
|
# A pending subscription change if one exists on this subscription.
|
137
|
-
sig
|
170
|
+
sig do
|
171
|
+
returns(
|
172
|
+
T.nilable(
|
173
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PendingSubscriptionChange
|
174
|
+
)
|
175
|
+
)
|
176
|
+
end
|
138
177
|
attr_reader :pending_subscription_change
|
139
178
|
|
140
179
|
sig do
|
141
180
|
params(
|
142
|
-
pending_subscription_change:
|
143
|
-
T.
|
144
|
-
|
145
|
-
|
146
|
-
|
181
|
+
pending_subscription_change:
|
182
|
+
T.nilable(
|
183
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PendingSubscriptionChange::OrHash
|
184
|
+
)
|
185
|
+
).void
|
147
186
|
end
|
148
187
|
attr_writer :pending_subscription_change
|
149
188
|
|
@@ -151,24 +190,36 @@ module Orb
|
|
151
190
|
# subscribed to by a customer. Plans define the billing behavior of the
|
152
191
|
# subscription. You can see more about how to configure prices in the
|
153
192
|
# [Price resource](/reference/price).
|
154
|
-
sig { returns(Orb::
|
193
|
+
sig { returns(Orb::Plan) }
|
155
194
|
attr_reader :plan
|
156
195
|
|
157
|
-
sig { params(plan:
|
196
|
+
sig { params(plan: Orb::Plan::OrHash).void }
|
158
197
|
attr_writer :plan
|
159
198
|
|
160
199
|
# The price intervals for this subscription.
|
161
|
-
sig
|
200
|
+
sig do
|
201
|
+
returns(
|
202
|
+
T::Array[Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval]
|
203
|
+
)
|
204
|
+
end
|
162
205
|
attr_accessor :price_intervals
|
163
206
|
|
164
|
-
sig
|
207
|
+
sig do
|
208
|
+
returns(
|
209
|
+
T.nilable(
|
210
|
+
Orb::Models::SubscriptionUpdateTrialResponse::RedeemedCoupon
|
211
|
+
)
|
212
|
+
)
|
213
|
+
end
|
165
214
|
attr_reader :redeemed_coupon
|
166
215
|
|
167
216
|
sig do
|
168
217
|
params(
|
169
|
-
redeemed_coupon:
|
170
|
-
|
171
|
-
|
218
|
+
redeemed_coupon:
|
219
|
+
T.nilable(
|
220
|
+
Orb::Models::SubscriptionUpdateTrialResponse::RedeemedCoupon::OrHash
|
221
|
+
)
|
222
|
+
).void
|
172
223
|
end
|
173
224
|
attr_writer :redeemed_coupon
|
174
225
|
|
@@ -176,29 +227,43 @@ module Orb
|
|
176
227
|
sig { returns(Time) }
|
177
228
|
attr_accessor :start_date
|
178
229
|
|
179
|
-
sig
|
230
|
+
sig do
|
231
|
+
returns(
|
232
|
+
Orb::Models::SubscriptionUpdateTrialResponse::Status::TaggedSymbol
|
233
|
+
)
|
234
|
+
end
|
180
235
|
attr_accessor :status
|
181
236
|
|
182
237
|
sig { returns(Orb::Models::SubscriptionUpdateTrialResponse::TrialInfo) }
|
183
238
|
attr_reader :trial_info
|
184
239
|
|
185
240
|
sig do
|
186
|
-
params(
|
187
|
-
|
241
|
+
params(
|
242
|
+
trial_info:
|
243
|
+
Orb::Models::SubscriptionUpdateTrialResponse::TrialInfo::OrHash
|
244
|
+
).void
|
188
245
|
end
|
189
246
|
attr_writer :trial_info
|
190
247
|
|
191
248
|
# The resources that were changed as part of this operation. Only present when
|
192
249
|
# fetched through the subscription changes API or if the
|
193
250
|
# `include_changed_resources` parameter was passed in the request.
|
194
|
-
sig
|
251
|
+
sig do
|
252
|
+
returns(
|
253
|
+
T.nilable(
|
254
|
+
Orb::Models::SubscriptionUpdateTrialResponse::ChangedResources
|
255
|
+
)
|
256
|
+
)
|
257
|
+
end
|
195
258
|
attr_reader :changed_resources
|
196
259
|
|
197
260
|
sig do
|
198
261
|
params(
|
199
|
-
changed_resources:
|
200
|
-
|
201
|
-
|
262
|
+
changed_resources:
|
263
|
+
T.nilable(
|
264
|
+
Orb::Models::SubscriptionUpdateTrialResponse::ChangedResources::OrHash
|
265
|
+
)
|
266
|
+
).void
|
202
267
|
end
|
203
268
|
attr_writer :changed_resources
|
204
269
|
|
@@ -206,45 +271,66 @@ module Orb
|
|
206
271
|
params(
|
207
272
|
id: String,
|
208
273
|
active_plan_phase_order: T.nilable(Integer),
|
209
|
-
adjustment_intervals:
|
274
|
+
adjustment_intervals:
|
275
|
+
T::Array[
|
276
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::OrHash
|
277
|
+
],
|
210
278
|
auto_collection: T.nilable(T::Boolean),
|
211
|
-
billing_cycle_anchor_configuration:
|
212
|
-
Orb::Models::SubscriptionUpdateTrialResponse::BillingCycleAnchorConfiguration,
|
213
|
-
Orb::Internal::AnyHash
|
214
|
-
),
|
279
|
+
billing_cycle_anchor_configuration:
|
280
|
+
Orb::Models::SubscriptionUpdateTrialResponse::BillingCycleAnchorConfiguration::OrHash,
|
215
281
|
billing_cycle_day: Integer,
|
216
282
|
created_at: Time,
|
217
283
|
current_billing_period_end_date: T.nilable(Time),
|
218
284
|
current_billing_period_start_date: T.nilable(Time),
|
219
|
-
customer:
|
285
|
+
customer: Orb::Customer::OrHash,
|
220
286
|
default_invoice_memo: T.nilable(String),
|
221
|
-
discount_intervals:
|
222
|
-
T
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
287
|
+
discount_intervals:
|
288
|
+
T::Array[
|
289
|
+
T.any(
|
290
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Amount::OrHash,
|
291
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Percentage::OrHash,
|
292
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Usage::OrHash
|
293
|
+
)
|
294
|
+
],
|
229
295
|
end_date: T.nilable(Time),
|
230
|
-
fixed_fee_quantity_schedule:
|
296
|
+
fixed_fee_quantity_schedule:
|
297
|
+
T::Array[
|
298
|
+
Orb::Models::SubscriptionUpdateTrialResponse::FixedFeeQuantitySchedule::OrHash
|
299
|
+
],
|
231
300
|
invoicing_threshold: T.nilable(String),
|
232
|
-
maximum_intervals:
|
301
|
+
maximum_intervals:
|
302
|
+
T::Array[
|
303
|
+
Orb::Models::SubscriptionUpdateTrialResponse::MaximumInterval::OrHash
|
304
|
+
],
|
233
305
|
metadata: T::Hash[Symbol, String],
|
234
|
-
minimum_intervals:
|
306
|
+
minimum_intervals:
|
307
|
+
T::Array[
|
308
|
+
Orb::Models::SubscriptionUpdateTrialResponse::MinimumInterval::OrHash
|
309
|
+
],
|
235
310
|
net_terms: Integer,
|
236
|
-
pending_subscription_change:
|
237
|
-
T.
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
311
|
+
pending_subscription_change:
|
312
|
+
T.nilable(
|
313
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PendingSubscriptionChange::OrHash
|
314
|
+
),
|
315
|
+
plan: Orb::Plan::OrHash,
|
316
|
+
price_intervals:
|
317
|
+
T::Array[
|
318
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval::OrHash
|
319
|
+
],
|
320
|
+
redeemed_coupon:
|
321
|
+
T.nilable(
|
322
|
+
Orb::Models::SubscriptionUpdateTrialResponse::RedeemedCoupon::OrHash
|
323
|
+
),
|
242
324
|
start_date: Time,
|
243
|
-
status:
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
325
|
+
status:
|
326
|
+
Orb::Models::SubscriptionUpdateTrialResponse::Status::OrSymbol,
|
327
|
+
trial_info:
|
328
|
+
Orb::Models::SubscriptionUpdateTrialResponse::TrialInfo::OrHash,
|
329
|
+
changed_resources:
|
330
|
+
T.nilable(
|
331
|
+
Orb::Models::SubscriptionUpdateTrialResponse::ChangedResources::OrHash
|
332
|
+
)
|
333
|
+
).returns(T.attached_class)
|
248
334
|
end
|
249
335
|
def self.new(
|
250
336
|
id:,
|
@@ -333,50 +419,87 @@ module Orb
|
|
333
419
|
# fetched through the subscription changes API or if the
|
334
420
|
# `include_changed_resources` parameter was passed in the request.
|
335
421
|
changed_resources: nil
|
336
|
-
)
|
422
|
+
)
|
423
|
+
end
|
424
|
+
|
337
425
|
sig do
|
338
|
-
override
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
426
|
+
override.returns(
|
427
|
+
{
|
428
|
+
id: String,
|
429
|
+
active_plan_phase_order: T.nilable(Integer),
|
430
|
+
adjustment_intervals:
|
431
|
+
T::Array[
|
432
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval
|
433
|
+
],
|
434
|
+
auto_collection: T.nilable(T::Boolean),
|
435
|
+
billing_cycle_anchor_configuration:
|
436
|
+
Orb::Models::SubscriptionUpdateTrialResponse::BillingCycleAnchorConfiguration,
|
437
|
+
billing_cycle_day: Integer,
|
438
|
+
created_at: Time,
|
439
|
+
current_billing_period_end_date: T.nilable(Time),
|
440
|
+
current_billing_period_start_date: T.nilable(Time),
|
441
|
+
customer: Orb::Customer,
|
442
|
+
default_invoice_memo: T.nilable(String),
|
443
|
+
discount_intervals:
|
444
|
+
T::Array[
|
353
445
|
T.any(
|
354
446
|
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Amount,
|
355
447
|
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Percentage,
|
356
448
|
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Usage
|
357
449
|
)
|
358
450
|
],
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
451
|
+
end_date: T.nilable(Time),
|
452
|
+
fixed_fee_quantity_schedule:
|
453
|
+
T::Array[
|
454
|
+
Orb::Models::SubscriptionUpdateTrialResponse::FixedFeeQuantitySchedule
|
455
|
+
],
|
456
|
+
invoicing_threshold: T.nilable(String),
|
457
|
+
maximum_intervals:
|
458
|
+
T::Array[
|
459
|
+
Orb::Models::SubscriptionUpdateTrialResponse::MaximumInterval
|
460
|
+
],
|
461
|
+
metadata: T::Hash[Symbol, String],
|
462
|
+
minimum_intervals:
|
463
|
+
T::Array[
|
464
|
+
Orb::Models::SubscriptionUpdateTrialResponse::MinimumInterval
|
465
|
+
],
|
466
|
+
net_terms: Integer,
|
467
|
+
pending_subscription_change:
|
468
|
+
T.nilable(
|
469
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PendingSubscriptionChange
|
470
|
+
),
|
471
|
+
plan: Orb::Plan,
|
472
|
+
price_intervals:
|
473
|
+
T::Array[
|
474
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval
|
475
|
+
],
|
476
|
+
redeemed_coupon:
|
477
|
+
T.nilable(
|
478
|
+
Orb::Models::SubscriptionUpdateTrialResponse::RedeemedCoupon
|
479
|
+
),
|
480
|
+
start_date: Time,
|
481
|
+
status:
|
482
|
+
Orb::Models::SubscriptionUpdateTrialResponse::Status::TaggedSymbol,
|
483
|
+
trial_info: Orb::Models::SubscriptionUpdateTrialResponse::TrialInfo,
|
484
|
+
changed_resources:
|
485
|
+
T.nilable(
|
486
|
+
Orb::Models::SubscriptionUpdateTrialResponse::ChangedResources
|
487
|
+
)
|
488
|
+
}
|
489
|
+
)
|
490
|
+
end
|
491
|
+
def to_hash
|
376
492
|
end
|
377
|
-
def to_hash; end
|
378
493
|
|
379
494
|
class AdjustmentInterval < Orb::Internal::Type::BaseModel
|
495
|
+
OrHash =
|
496
|
+
T.type_alias do
|
497
|
+
T.any(
|
498
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval,
|
499
|
+
Orb::Internal::AnyHash
|
500
|
+
)
|
501
|
+
end
|
502
|
+
|
380
503
|
sig { returns(String) }
|
381
504
|
attr_accessor :id
|
382
505
|
|
@@ -408,19 +531,18 @@ module Orb
|
|
408
531
|
sig do
|
409
532
|
params(
|
410
533
|
id: String,
|
411
|
-
adjustment:
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
|
534
|
+
adjustment:
|
535
|
+
T.any(
|
536
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::UsageDiscount::OrHash,
|
537
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::AmountDiscount::OrHash,
|
538
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::PercentageDiscount::OrHash,
|
539
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Minimum::OrHash,
|
540
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Maximum::OrHash
|
541
|
+
),
|
419
542
|
applies_to_price_interval_ids: T::Array[String],
|
420
543
|
end_date: T.nilable(Time),
|
421
544
|
start_date: Time
|
422
|
-
)
|
423
|
-
.returns(T.attached_class)
|
545
|
+
).returns(T.attached_class)
|
424
546
|
end
|
425
547
|
def self.new(
|
426
548
|
id:,
|
@@ -431,31 +553,53 @@ module Orb
|
|
431
553
|
end_date:,
|
432
554
|
# The start date of the adjustment interval.
|
433
555
|
start_date:
|
434
|
-
)
|
556
|
+
)
|
557
|
+
end
|
558
|
+
|
435
559
|
sig do
|
436
|
-
override
|
437
|
-
|
438
|
-
|
439
|
-
|
440
|
-
|
560
|
+
override.returns(
|
561
|
+
{
|
562
|
+
id: String,
|
563
|
+
adjustment:
|
564
|
+
T.any(
|
441
565
|
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::UsageDiscount,
|
442
566
|
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::AmountDiscount,
|
443
567
|
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::PercentageDiscount,
|
444
568
|
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Minimum,
|
445
569
|
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Maximum
|
446
570
|
),
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
571
|
+
applies_to_price_interval_ids: T::Array[String],
|
572
|
+
end_date: T.nilable(Time),
|
573
|
+
start_date: Time
|
574
|
+
}
|
575
|
+
)
|
576
|
+
end
|
577
|
+
def to_hash
|
452
578
|
end
|
453
|
-
def to_hash; end
|
454
579
|
|
455
580
|
module Adjustment
|
456
581
|
extend Orb::Internal::Type::Union
|
457
582
|
|
583
|
+
Variants =
|
584
|
+
T.type_alias do
|
585
|
+
T.any(
|
586
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::UsageDiscount,
|
587
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::AmountDiscount,
|
588
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::PercentageDiscount,
|
589
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Minimum,
|
590
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Maximum
|
591
|
+
)
|
592
|
+
end
|
593
|
+
|
458
594
|
class UsageDiscount < Orb::Internal::Type::BaseModel
|
595
|
+
OrHash =
|
596
|
+
T.type_alias do
|
597
|
+
T.any(
|
598
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::UsageDiscount,
|
599
|
+
Orb::Internal::AnyHash
|
600
|
+
)
|
601
|
+
end
|
602
|
+
|
459
603
|
sig { returns(String) }
|
460
604
|
attr_accessor :id
|
461
605
|
|
@@ -493,8 +637,7 @@ module Orb
|
|
493
637
|
reason: T.nilable(String),
|
494
638
|
usage_discount: Float,
|
495
639
|
adjustment_type: Symbol
|
496
|
-
)
|
497
|
-
.returns(T.attached_class)
|
640
|
+
).returns(T.attached_class)
|
498
641
|
end
|
499
642
|
def self.new(
|
500
643
|
id:,
|
@@ -511,25 +654,35 @@ module Orb
|
|
511
654
|
# to in a given billing period.
|
512
655
|
usage_discount:,
|
513
656
|
adjustment_type: :usage_discount
|
514
|
-
)
|
657
|
+
)
|
658
|
+
end
|
659
|
+
|
515
660
|
sig do
|
516
|
-
override
|
517
|
-
|
518
|
-
|
519
|
-
|
520
|
-
|
521
|
-
|
522
|
-
|
523
|
-
|
524
|
-
|
525
|
-
|
526
|
-
|
527
|
-
|
661
|
+
override.returns(
|
662
|
+
{
|
663
|
+
id: String,
|
664
|
+
adjustment_type: Symbol,
|
665
|
+
applies_to_price_ids: T::Array[String],
|
666
|
+
is_invoice_level: T::Boolean,
|
667
|
+
plan_phase_order: T.nilable(Integer),
|
668
|
+
reason: T.nilable(String),
|
669
|
+
usage_discount: Float
|
670
|
+
}
|
671
|
+
)
|
672
|
+
end
|
673
|
+
def to_hash
|
528
674
|
end
|
529
|
-
def to_hash; end
|
530
675
|
end
|
531
676
|
|
532
677
|
class AmountDiscount < Orb::Internal::Type::BaseModel
|
678
|
+
OrHash =
|
679
|
+
T.type_alias do
|
680
|
+
T.any(
|
681
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::AmountDiscount,
|
682
|
+
Orb::Internal::AnyHash
|
683
|
+
)
|
684
|
+
end
|
685
|
+
|
533
686
|
sig { returns(String) }
|
534
687
|
attr_accessor :id
|
535
688
|
|
@@ -567,8 +720,7 @@ module Orb
|
|
567
720
|
plan_phase_order: T.nilable(Integer),
|
568
721
|
reason: T.nilable(String),
|
569
722
|
adjustment_type: Symbol
|
570
|
-
)
|
571
|
-
.returns(T.attached_class)
|
723
|
+
).returns(T.attached_class)
|
572
724
|
end
|
573
725
|
def self.new(
|
574
726
|
id:,
|
@@ -585,25 +737,35 @@ module Orb
|
|
585
737
|
# The reason for the adjustment.
|
586
738
|
reason:,
|
587
739
|
adjustment_type: :amount_discount
|
588
|
-
)
|
740
|
+
)
|
741
|
+
end
|
742
|
+
|
589
743
|
sig do
|
590
|
-
override
|
591
|
-
|
592
|
-
|
593
|
-
|
594
|
-
|
595
|
-
|
596
|
-
|
597
|
-
|
598
|
-
|
599
|
-
|
600
|
-
|
601
|
-
|
744
|
+
override.returns(
|
745
|
+
{
|
746
|
+
id: String,
|
747
|
+
adjustment_type: Symbol,
|
748
|
+
amount_discount: String,
|
749
|
+
applies_to_price_ids: T::Array[String],
|
750
|
+
is_invoice_level: T::Boolean,
|
751
|
+
plan_phase_order: T.nilable(Integer),
|
752
|
+
reason: T.nilable(String)
|
753
|
+
}
|
754
|
+
)
|
755
|
+
end
|
756
|
+
def to_hash
|
602
757
|
end
|
603
|
-
def to_hash; end
|
604
758
|
end
|
605
759
|
|
606
760
|
class PercentageDiscount < Orb::Internal::Type::BaseModel
|
761
|
+
OrHash =
|
762
|
+
T.type_alias do
|
763
|
+
T.any(
|
764
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::PercentageDiscount,
|
765
|
+
Orb::Internal::AnyHash
|
766
|
+
)
|
767
|
+
end
|
768
|
+
|
607
769
|
sig { returns(String) }
|
608
770
|
attr_accessor :id
|
609
771
|
|
@@ -641,8 +803,7 @@ module Orb
|
|
641
803
|
plan_phase_order: T.nilable(Integer),
|
642
804
|
reason: T.nilable(String),
|
643
805
|
adjustment_type: Symbol
|
644
|
-
)
|
645
|
-
.returns(T.attached_class)
|
806
|
+
).returns(T.attached_class)
|
646
807
|
end
|
647
808
|
def self.new(
|
648
809
|
id:,
|
@@ -659,25 +820,35 @@ module Orb
|
|
659
820
|
# The reason for the adjustment.
|
660
821
|
reason:,
|
661
822
|
adjustment_type: :percentage_discount
|
662
|
-
)
|
823
|
+
)
|
824
|
+
end
|
825
|
+
|
663
826
|
sig do
|
664
|
-
override
|
665
|
-
|
666
|
-
|
667
|
-
|
668
|
-
|
669
|
-
|
670
|
-
|
671
|
-
|
672
|
-
|
673
|
-
|
674
|
-
|
675
|
-
|
827
|
+
override.returns(
|
828
|
+
{
|
829
|
+
id: String,
|
830
|
+
adjustment_type: Symbol,
|
831
|
+
applies_to_price_ids: T::Array[String],
|
832
|
+
is_invoice_level: T::Boolean,
|
833
|
+
percentage_discount: Float,
|
834
|
+
plan_phase_order: T.nilable(Integer),
|
835
|
+
reason: T.nilable(String)
|
836
|
+
}
|
837
|
+
)
|
838
|
+
end
|
839
|
+
def to_hash
|
676
840
|
end
|
677
|
-
def to_hash; end
|
678
841
|
end
|
679
842
|
|
680
843
|
class Minimum < Orb::Internal::Type::BaseModel
|
844
|
+
OrHash =
|
845
|
+
T.type_alias do
|
846
|
+
T.any(
|
847
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Minimum,
|
848
|
+
Orb::Internal::AnyHash
|
849
|
+
)
|
850
|
+
end
|
851
|
+
|
681
852
|
sig { returns(String) }
|
682
853
|
attr_accessor :id
|
683
854
|
|
@@ -720,8 +891,7 @@ module Orb
|
|
720
891
|
plan_phase_order: T.nilable(Integer),
|
721
892
|
reason: T.nilable(String),
|
722
893
|
adjustment_type: Symbol
|
723
|
-
)
|
724
|
-
.returns(T.attached_class)
|
894
|
+
).returns(T.attached_class)
|
725
895
|
end
|
726
896
|
def self.new(
|
727
897
|
id:,
|
@@ -740,26 +910,36 @@ module Orb
|
|
740
910
|
# The reason for the adjustment.
|
741
911
|
reason:,
|
742
912
|
adjustment_type: :minimum
|
743
|
-
)
|
913
|
+
)
|
914
|
+
end
|
915
|
+
|
744
916
|
sig do
|
745
|
-
override
|
746
|
-
|
747
|
-
|
748
|
-
|
749
|
-
|
750
|
-
|
751
|
-
|
752
|
-
|
753
|
-
|
754
|
-
|
755
|
-
|
756
|
-
|
757
|
-
|
917
|
+
override.returns(
|
918
|
+
{
|
919
|
+
id: String,
|
920
|
+
adjustment_type: Symbol,
|
921
|
+
applies_to_price_ids: T::Array[String],
|
922
|
+
is_invoice_level: T::Boolean,
|
923
|
+
item_id: String,
|
924
|
+
minimum_amount: String,
|
925
|
+
plan_phase_order: T.nilable(Integer),
|
926
|
+
reason: T.nilable(String)
|
927
|
+
}
|
928
|
+
)
|
929
|
+
end
|
930
|
+
def to_hash
|
758
931
|
end
|
759
|
-
def to_hash; end
|
760
932
|
end
|
761
933
|
|
762
934
|
class Maximum < Orb::Internal::Type::BaseModel
|
935
|
+
OrHash =
|
936
|
+
T.type_alias do
|
937
|
+
T.any(
|
938
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Maximum,
|
939
|
+
Orb::Internal::AnyHash
|
940
|
+
)
|
941
|
+
end
|
942
|
+
|
763
943
|
sig { returns(String) }
|
764
944
|
attr_accessor :id
|
765
945
|
|
@@ -797,8 +977,7 @@ module Orb
|
|
797
977
|
plan_phase_order: T.nilable(Integer),
|
798
978
|
reason: T.nilable(String),
|
799
979
|
adjustment_type: Symbol
|
800
|
-
)
|
801
|
-
.returns(T.attached_class)
|
980
|
+
).returns(T.attached_class)
|
802
981
|
end
|
803
982
|
def self.new(
|
804
983
|
id:,
|
@@ -815,35 +994,47 @@ module Orb
|
|
815
994
|
# The reason for the adjustment.
|
816
995
|
reason:,
|
817
996
|
adjustment_type: :maximum
|
818
|
-
)
|
997
|
+
)
|
998
|
+
end
|
999
|
+
|
819
1000
|
sig do
|
820
|
-
override
|
821
|
-
|
822
|
-
|
823
|
-
|
824
|
-
|
825
|
-
|
826
|
-
|
827
|
-
|
828
|
-
|
829
|
-
|
830
|
-
|
831
|
-
|
1001
|
+
override.returns(
|
1002
|
+
{
|
1003
|
+
id: String,
|
1004
|
+
adjustment_type: Symbol,
|
1005
|
+
applies_to_price_ids: T::Array[String],
|
1006
|
+
is_invoice_level: T::Boolean,
|
1007
|
+
maximum_amount: String,
|
1008
|
+
plan_phase_order: T.nilable(Integer),
|
1009
|
+
reason: T.nilable(String)
|
1010
|
+
}
|
1011
|
+
)
|
1012
|
+
end
|
1013
|
+
def to_hash
|
832
1014
|
end
|
833
|
-
def to_hash; end
|
834
1015
|
end
|
835
1016
|
|
836
1017
|
sig do
|
837
|
-
override
|
838
|
-
|
839
|
-
|
840
|
-
|
1018
|
+
override.returns(
|
1019
|
+
T::Array[
|
1020
|
+
Orb::Models::SubscriptionUpdateTrialResponse::AdjustmentInterval::Adjustment::Variants
|
1021
|
+
]
|
1022
|
+
)
|
1023
|
+
end
|
1024
|
+
def self.variants
|
841
1025
|
end
|
842
|
-
def self.variants; end
|
843
1026
|
end
|
844
1027
|
end
|
845
1028
|
|
846
1029
|
class BillingCycleAnchorConfiguration < Orb::Internal::Type::BaseModel
|
1030
|
+
OrHash =
|
1031
|
+
T.type_alias do
|
1032
|
+
T.any(
|
1033
|
+
Orb::Models::SubscriptionUpdateTrialResponse::BillingCycleAnchorConfiguration,
|
1034
|
+
Orb::Internal::AnyHash
|
1035
|
+
)
|
1036
|
+
end
|
1037
|
+
|
847
1038
|
# The day of the month on which the billing cycle is anchored. If the maximum
|
848
1039
|
# number of days in a month is greater than this value, the last day of the month
|
849
1040
|
# is the billing cycle day (e.g. billing_cycle_day=31 for April means the billing
|
@@ -863,7 +1054,11 @@ module Orb
|
|
863
1054
|
attr_accessor :year
|
864
1055
|
|
865
1056
|
sig do
|
866
|
-
params(
|
1057
|
+
params(
|
1058
|
+
day: Integer,
|
1059
|
+
month: T.nilable(Integer),
|
1060
|
+
year: T.nilable(Integer)
|
1061
|
+
).returns(T.attached_class)
|
867
1062
|
end
|
868
1063
|
def self.new(
|
869
1064
|
# The day of the month on which the billing cycle is anchored. If the maximum
|
@@ -878,15 +1073,43 @@ module Orb
|
|
878
1073
|
# The year on which the billing cycle is anchored (e.g. a 2 year billing cycle
|
879
1074
|
# anchored on 2021 would have cycles starting on 2021, 2023, 2025, etc.).
|
880
1075
|
year: nil
|
881
|
-
)
|
882
|
-
|
883
|
-
|
1076
|
+
)
|
1077
|
+
end
|
1078
|
+
|
1079
|
+
sig do
|
1080
|
+
override.returns(
|
1081
|
+
{
|
1082
|
+
day: Integer,
|
1083
|
+
month: T.nilable(Integer),
|
1084
|
+
year: T.nilable(Integer)
|
1085
|
+
}
|
1086
|
+
)
|
1087
|
+
end
|
1088
|
+
def to_hash
|
1089
|
+
end
|
884
1090
|
end
|
885
1091
|
|
886
1092
|
module DiscountInterval
|
887
1093
|
extend Orb::Internal::Type::Union
|
888
1094
|
|
1095
|
+
Variants =
|
1096
|
+
T.type_alias do
|
1097
|
+
T.any(
|
1098
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Amount,
|
1099
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Percentage,
|
1100
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Usage
|
1101
|
+
)
|
1102
|
+
end
|
1103
|
+
|
889
1104
|
class Amount < Orb::Internal::Type::BaseModel
|
1105
|
+
OrHash =
|
1106
|
+
T.type_alias do
|
1107
|
+
T.any(
|
1108
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Amount,
|
1109
|
+
Orb::Internal::AnyHash
|
1110
|
+
)
|
1111
|
+
end
|
1112
|
+
|
890
1113
|
# Only available if discount_type is `amount`.
|
891
1114
|
sig { returns(String) }
|
892
1115
|
attr_accessor :amount_discount
|
@@ -918,8 +1141,7 @@ module Orb
|
|
918
1141
|
end_date: T.nilable(Time),
|
919
1142
|
start_date: Time,
|
920
1143
|
discount_type: Symbol
|
921
|
-
)
|
922
|
-
.returns(T.attached_class)
|
1144
|
+
).returns(T.attached_class)
|
923
1145
|
end
|
924
1146
|
def self.new(
|
925
1147
|
# Only available if discount_type is `amount`.
|
@@ -933,24 +1155,34 @@ module Orb
|
|
933
1155
|
# The start date of the discount interval.
|
934
1156
|
start_date:,
|
935
1157
|
discount_type: :amount
|
936
|
-
)
|
1158
|
+
)
|
1159
|
+
end
|
1160
|
+
|
937
1161
|
sig do
|
938
|
-
override
|
939
|
-
|
940
|
-
|
941
|
-
|
942
|
-
|
943
|
-
|
944
|
-
|
945
|
-
|
946
|
-
|
947
|
-
|
948
|
-
|
1162
|
+
override.returns(
|
1163
|
+
{
|
1164
|
+
amount_discount: String,
|
1165
|
+
applies_to_price_ids: T::Array[String],
|
1166
|
+
applies_to_price_interval_ids: T::Array[String],
|
1167
|
+
discount_type: Symbol,
|
1168
|
+
end_date: T.nilable(Time),
|
1169
|
+
start_date: Time
|
1170
|
+
}
|
1171
|
+
)
|
1172
|
+
end
|
1173
|
+
def to_hash
|
949
1174
|
end
|
950
|
-
def to_hash; end
|
951
1175
|
end
|
952
1176
|
|
953
1177
|
class Percentage < Orb::Internal::Type::BaseModel
|
1178
|
+
OrHash =
|
1179
|
+
T.type_alias do
|
1180
|
+
T.any(
|
1181
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Percentage,
|
1182
|
+
Orb::Internal::AnyHash
|
1183
|
+
)
|
1184
|
+
end
|
1185
|
+
|
954
1186
|
# The price ids that this discount interval applies to.
|
955
1187
|
sig { returns(T::Array[String]) }
|
956
1188
|
attr_accessor :applies_to_price_ids
|
@@ -983,8 +1215,7 @@ module Orb
|
|
983
1215
|
percentage_discount: Float,
|
984
1216
|
start_date: Time,
|
985
1217
|
discount_type: Symbol
|
986
|
-
)
|
987
|
-
.returns(T.attached_class)
|
1218
|
+
).returns(T.attached_class)
|
988
1219
|
end
|
989
1220
|
def self.new(
|
990
1221
|
# The price ids that this discount interval applies to.
|
@@ -999,24 +1230,34 @@ module Orb
|
|
999
1230
|
# The start date of the discount interval.
|
1000
1231
|
start_date:,
|
1001
1232
|
discount_type: :percentage
|
1002
|
-
)
|
1233
|
+
)
|
1234
|
+
end
|
1235
|
+
|
1003
1236
|
sig do
|
1004
|
-
override
|
1005
|
-
|
1006
|
-
|
1007
|
-
|
1008
|
-
|
1009
|
-
|
1010
|
-
|
1011
|
-
|
1012
|
-
|
1013
|
-
|
1014
|
-
|
1237
|
+
override.returns(
|
1238
|
+
{
|
1239
|
+
applies_to_price_ids: T::Array[String],
|
1240
|
+
applies_to_price_interval_ids: T::Array[String],
|
1241
|
+
discount_type: Symbol,
|
1242
|
+
end_date: T.nilable(Time),
|
1243
|
+
percentage_discount: Float,
|
1244
|
+
start_date: Time
|
1245
|
+
}
|
1246
|
+
)
|
1247
|
+
end
|
1248
|
+
def to_hash
|
1015
1249
|
end
|
1016
|
-
def to_hash; end
|
1017
1250
|
end
|
1018
1251
|
|
1019
1252
|
class Usage < Orb::Internal::Type::BaseModel
|
1253
|
+
OrHash =
|
1254
|
+
T.type_alias do
|
1255
|
+
T.any(
|
1256
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Usage,
|
1257
|
+
Orb::Internal::AnyHash
|
1258
|
+
)
|
1259
|
+
end
|
1260
|
+
|
1020
1261
|
# The price ids that this discount interval applies to.
|
1021
1262
|
sig { returns(T::Array[String]) }
|
1022
1263
|
attr_accessor :applies_to_price_ids
|
@@ -1049,8 +1290,7 @@ module Orb
|
|
1049
1290
|
start_date: Time,
|
1050
1291
|
usage_discount: Float,
|
1051
1292
|
discount_type: Symbol
|
1052
|
-
)
|
1053
|
-
.returns(T.attached_class)
|
1293
|
+
).returns(T.attached_class)
|
1054
1294
|
end
|
1055
1295
|
def self.new(
|
1056
1296
|
# The price ids that this discount interval applies to.
|
@@ -1065,33 +1305,45 @@ module Orb
|
|
1065
1305
|
# discount is for
|
1066
1306
|
usage_discount:,
|
1067
1307
|
discount_type: :usage
|
1068
|
-
)
|
1308
|
+
)
|
1309
|
+
end
|
1310
|
+
|
1069
1311
|
sig do
|
1070
|
-
override
|
1071
|
-
|
1072
|
-
|
1073
|
-
|
1074
|
-
|
1075
|
-
|
1076
|
-
|
1077
|
-
|
1078
|
-
|
1079
|
-
|
1080
|
-
|
1312
|
+
override.returns(
|
1313
|
+
{
|
1314
|
+
applies_to_price_ids: T::Array[String],
|
1315
|
+
applies_to_price_interval_ids: T::Array[String],
|
1316
|
+
discount_type: Symbol,
|
1317
|
+
end_date: T.nilable(Time),
|
1318
|
+
start_date: Time,
|
1319
|
+
usage_discount: Float
|
1320
|
+
}
|
1321
|
+
)
|
1322
|
+
end
|
1323
|
+
def to_hash
|
1081
1324
|
end
|
1082
|
-
def to_hash; end
|
1083
1325
|
end
|
1084
1326
|
|
1085
1327
|
sig do
|
1086
|
-
override
|
1087
|
-
|
1088
|
-
|
1089
|
-
|
1328
|
+
override.returns(
|
1329
|
+
T::Array[
|
1330
|
+
Orb::Models::SubscriptionUpdateTrialResponse::DiscountInterval::Variants
|
1331
|
+
]
|
1332
|
+
)
|
1333
|
+
end
|
1334
|
+
def self.variants
|
1090
1335
|
end
|
1091
|
-
def self.variants; end
|
1092
1336
|
end
|
1093
1337
|
|
1094
1338
|
class FixedFeeQuantitySchedule < Orb::Internal::Type::BaseModel
|
1339
|
+
OrHash =
|
1340
|
+
T.type_alias do
|
1341
|
+
T.any(
|
1342
|
+
Orb::Models::SubscriptionUpdateTrialResponse::FixedFeeQuantitySchedule,
|
1343
|
+
Orb::Internal::AnyHash
|
1344
|
+
)
|
1345
|
+
end
|
1346
|
+
|
1095
1347
|
sig { returns(T.nilable(Time)) }
|
1096
1348
|
attr_accessor :end_date
|
1097
1349
|
|
@@ -1105,18 +1357,39 @@ module Orb
|
|
1105
1357
|
attr_accessor :start_date
|
1106
1358
|
|
1107
1359
|
sig do
|
1108
|
-
params(
|
1109
|
-
.
|
1360
|
+
params(
|
1361
|
+
end_date: T.nilable(Time),
|
1362
|
+
price_id: String,
|
1363
|
+
quantity: Float,
|
1364
|
+
start_date: Time
|
1365
|
+
).returns(T.attached_class)
|
1366
|
+
end
|
1367
|
+
def self.new(end_date:, price_id:, quantity:, start_date:)
|
1110
1368
|
end
|
1111
|
-
def self.new(end_date:, price_id:, quantity:, start_date:); end
|
1112
1369
|
|
1113
1370
|
sig do
|
1114
|
-
override.returns(
|
1371
|
+
override.returns(
|
1372
|
+
{
|
1373
|
+
end_date: T.nilable(Time),
|
1374
|
+
price_id: String,
|
1375
|
+
quantity: Float,
|
1376
|
+
start_date: Time
|
1377
|
+
}
|
1378
|
+
)
|
1379
|
+
end
|
1380
|
+
def to_hash
|
1115
1381
|
end
|
1116
|
-
def to_hash; end
|
1117
1382
|
end
|
1118
1383
|
|
1119
1384
|
class MaximumInterval < Orb::Internal::Type::BaseModel
|
1385
|
+
OrHash =
|
1386
|
+
T.type_alias do
|
1387
|
+
T.any(
|
1388
|
+
Orb::Models::SubscriptionUpdateTrialResponse::MaximumInterval,
|
1389
|
+
Orb::Internal::AnyHash
|
1390
|
+
)
|
1391
|
+
end
|
1392
|
+
|
1120
1393
|
# The price ids that this maximum interval applies to.
|
1121
1394
|
sig { returns(T::Array[String]) }
|
1122
1395
|
attr_accessor :applies_to_price_ids
|
@@ -1145,8 +1418,7 @@ module Orb
|
|
1145
1418
|
end_date: T.nilable(Time),
|
1146
1419
|
maximum_amount: String,
|
1147
1420
|
start_date: Time
|
1148
|
-
)
|
1149
|
-
.returns(T.attached_class)
|
1421
|
+
).returns(T.attached_class)
|
1150
1422
|
end
|
1151
1423
|
def self.new(
|
1152
1424
|
# The price ids that this maximum interval applies to.
|
@@ -1160,23 +1432,33 @@ module Orb
|
|
1160
1432
|
maximum_amount:,
|
1161
1433
|
# The start date of the maximum interval.
|
1162
1434
|
start_date:
|
1163
|
-
)
|
1435
|
+
)
|
1436
|
+
end
|
1437
|
+
|
1164
1438
|
sig do
|
1165
|
-
override
|
1166
|
-
|
1167
|
-
|
1168
|
-
|
1169
|
-
|
1170
|
-
|
1171
|
-
|
1172
|
-
|
1173
|
-
|
1174
|
-
|
1439
|
+
override.returns(
|
1440
|
+
{
|
1441
|
+
applies_to_price_ids: T::Array[String],
|
1442
|
+
applies_to_price_interval_ids: T::Array[String],
|
1443
|
+
end_date: T.nilable(Time),
|
1444
|
+
maximum_amount: String,
|
1445
|
+
start_date: Time
|
1446
|
+
}
|
1447
|
+
)
|
1448
|
+
end
|
1449
|
+
def to_hash
|
1175
1450
|
end
|
1176
|
-
def to_hash; end
|
1177
1451
|
end
|
1178
1452
|
|
1179
1453
|
class MinimumInterval < Orb::Internal::Type::BaseModel
|
1454
|
+
OrHash =
|
1455
|
+
T.type_alias do
|
1456
|
+
T.any(
|
1457
|
+
Orb::Models::SubscriptionUpdateTrialResponse::MinimumInterval,
|
1458
|
+
Orb::Internal::AnyHash
|
1459
|
+
)
|
1460
|
+
end
|
1461
|
+
|
1180
1462
|
# The price ids that this minimum interval applies to.
|
1181
1463
|
sig { returns(T::Array[String]) }
|
1182
1464
|
attr_accessor :applies_to_price_ids
|
@@ -1205,8 +1487,7 @@ module Orb
|
|
1205
1487
|
end_date: T.nilable(Time),
|
1206
1488
|
minimum_amount: String,
|
1207
1489
|
start_date: Time
|
1208
|
-
)
|
1209
|
-
.returns(T.attached_class)
|
1490
|
+
).returns(T.attached_class)
|
1210
1491
|
end
|
1211
1492
|
def self.new(
|
1212
1493
|
# The price ids that this minimum interval applies to.
|
@@ -1220,35 +1501,55 @@ module Orb
|
|
1220
1501
|
minimum_amount:,
|
1221
1502
|
# The start date of the minimum interval.
|
1222
1503
|
start_date:
|
1223
|
-
)
|
1504
|
+
)
|
1505
|
+
end
|
1506
|
+
|
1224
1507
|
sig do
|
1225
|
-
override
|
1226
|
-
|
1227
|
-
|
1228
|
-
|
1229
|
-
|
1230
|
-
|
1231
|
-
|
1232
|
-
|
1233
|
-
|
1234
|
-
|
1508
|
+
override.returns(
|
1509
|
+
{
|
1510
|
+
applies_to_price_ids: T::Array[String],
|
1511
|
+
applies_to_price_interval_ids: T::Array[String],
|
1512
|
+
end_date: T.nilable(Time),
|
1513
|
+
minimum_amount: String,
|
1514
|
+
start_date: Time
|
1515
|
+
}
|
1516
|
+
)
|
1517
|
+
end
|
1518
|
+
def to_hash
|
1235
1519
|
end
|
1236
|
-
def to_hash; end
|
1237
1520
|
end
|
1238
1521
|
|
1239
1522
|
class PendingSubscriptionChange < Orb::Internal::Type::BaseModel
|
1523
|
+
OrHash =
|
1524
|
+
T.type_alias do
|
1525
|
+
T.any(
|
1526
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PendingSubscriptionChange,
|
1527
|
+
Orb::Internal::AnyHash
|
1528
|
+
)
|
1529
|
+
end
|
1530
|
+
|
1240
1531
|
sig { returns(String) }
|
1241
1532
|
attr_accessor :id
|
1242
1533
|
|
1243
1534
|
# A pending subscription change if one exists on this subscription.
|
1244
1535
|
sig { params(id: String).returns(T.attached_class) }
|
1245
|
-
def self.new(id:)
|
1536
|
+
def self.new(id:)
|
1537
|
+
end
|
1246
1538
|
|
1247
|
-
sig { override.returns({id: String}) }
|
1248
|
-
def to_hash
|
1539
|
+
sig { override.returns({ id: String }) }
|
1540
|
+
def to_hash
|
1541
|
+
end
|
1249
1542
|
end
|
1250
1543
|
|
1251
1544
|
class PriceInterval < Orb::Internal::Type::BaseModel
|
1545
|
+
OrHash =
|
1546
|
+
T.type_alias do
|
1547
|
+
T.any(
|
1548
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval,
|
1549
|
+
Orb::Internal::AnyHash
|
1550
|
+
)
|
1551
|
+
end
|
1552
|
+
|
1252
1553
|
sig { returns(String) }
|
1253
1554
|
attr_accessor :id
|
1254
1555
|
|
@@ -1282,7 +1583,9 @@ module Orb
|
|
1282
1583
|
sig do
|
1283
1584
|
returns(
|
1284
1585
|
T.nilable(
|
1285
|
-
T::Array[
|
1586
|
+
T::Array[
|
1587
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval::FixedFeeQuantityTransition
|
1588
|
+
]
|
1286
1589
|
)
|
1287
1590
|
)
|
1288
1591
|
end
|
@@ -1301,34 +1604,34 @@ module Orb
|
|
1301
1604
|
sig do
|
1302
1605
|
returns(
|
1303
1606
|
T.any(
|
1304
|
-
Orb::
|
1305
|
-
Orb::
|
1306
|
-
Orb::
|
1307
|
-
Orb::
|
1308
|
-
Orb::
|
1309
|
-
Orb::
|
1310
|
-
Orb::
|
1311
|
-
Orb::
|
1312
|
-
Orb::
|
1313
|
-
Orb::
|
1314
|
-
Orb::
|
1315
|
-
Orb::
|
1316
|
-
Orb::
|
1317
|
-
Orb::
|
1318
|
-
Orb::
|
1319
|
-
Orb::
|
1320
|
-
Orb::
|
1321
|
-
Orb::
|
1322
|
-
Orb::
|
1323
|
-
Orb::
|
1324
|
-
Orb::
|
1325
|
-
Orb::
|
1326
|
-
Orb::
|
1327
|
-
Orb::
|
1328
|
-
Orb::
|
1329
|
-
Orb::
|
1330
|
-
Orb::
|
1331
|
-
Orb::
|
1607
|
+
Orb::Price::Unit,
|
1608
|
+
Orb::Price::Package,
|
1609
|
+
Orb::Price::Matrix,
|
1610
|
+
Orb::Price::Tiered,
|
1611
|
+
Orb::Price::TieredBps,
|
1612
|
+
Orb::Price::Bps,
|
1613
|
+
Orb::Price::BulkBps,
|
1614
|
+
Orb::Price::Bulk,
|
1615
|
+
Orb::Price::ThresholdTotalAmount,
|
1616
|
+
Orb::Price::TieredPackage,
|
1617
|
+
Orb::Price::GroupedTiered,
|
1618
|
+
Orb::Price::TieredWithMinimum,
|
1619
|
+
Orb::Price::TieredPackageWithMinimum,
|
1620
|
+
Orb::Price::PackageWithAllocation,
|
1621
|
+
Orb::Price::UnitWithPercent,
|
1622
|
+
Orb::Price::MatrixWithAllocation,
|
1623
|
+
Orb::Price::TieredWithProration,
|
1624
|
+
Orb::Price::UnitWithProration,
|
1625
|
+
Orb::Price::GroupedAllocation,
|
1626
|
+
Orb::Price::GroupedWithProratedMinimum,
|
1627
|
+
Orb::Price::GroupedWithMeteredMinimum,
|
1628
|
+
Orb::Price::MatrixWithDisplayName,
|
1629
|
+
Orb::Price::BulkWithProration,
|
1630
|
+
Orb::Price::GroupedTieredPackage,
|
1631
|
+
Orb::Price::MaxGroupTieredPackage,
|
1632
|
+
Orb::Price::ScalableMatrixWithUnitPricing,
|
1633
|
+
Orb::Price::ScalableMatrixWithTieredPricing,
|
1634
|
+
Orb::Price::CumulativeGroupedBulk
|
1332
1635
|
)
|
1333
1636
|
)
|
1334
1637
|
end
|
@@ -1355,49 +1658,46 @@ module Orb
|
|
1355
1658
|
current_billing_period_start_date: T.nilable(Time),
|
1356
1659
|
end_date: T.nilable(Time),
|
1357
1660
|
filter: T.nilable(String),
|
1358
|
-
fixed_fee_quantity_transitions:
|
1359
|
-
T
|
1360
|
-
T
|
1361
|
-
Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval::FixedFeeQuantityTransition
|
1362
|
-
|
1363
|
-
|
1364
|
-
|
1365
|
-
|
1366
|
-
|
1367
|
-
|
1368
|
-
|
1369
|
-
|
1370
|
-
|
1371
|
-
|
1372
|
-
|
1373
|
-
|
1374
|
-
|
1375
|
-
|
1376
|
-
|
1377
|
-
|
1378
|
-
|
1379
|
-
|
1380
|
-
|
1381
|
-
|
1382
|
-
|
1383
|
-
|
1384
|
-
|
1385
|
-
|
1386
|
-
|
1387
|
-
|
1388
|
-
|
1389
|
-
|
1390
|
-
|
1391
|
-
|
1392
|
-
|
1393
|
-
|
1394
|
-
|
1395
|
-
Orb::Models::Price::CumulativeGroupedBulk
|
1396
|
-
),
|
1661
|
+
fixed_fee_quantity_transitions:
|
1662
|
+
T.nilable(
|
1663
|
+
T::Array[
|
1664
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval::FixedFeeQuantityTransition::OrHash
|
1665
|
+
]
|
1666
|
+
),
|
1667
|
+
price:
|
1668
|
+
T.any(
|
1669
|
+
Orb::Price::Unit::OrHash,
|
1670
|
+
Orb::Price::Package::OrHash,
|
1671
|
+
Orb::Price::Matrix::OrHash,
|
1672
|
+
Orb::Price::Tiered::OrHash,
|
1673
|
+
Orb::Price::TieredBps::OrHash,
|
1674
|
+
Orb::Price::Bps::OrHash,
|
1675
|
+
Orb::Price::BulkBps::OrHash,
|
1676
|
+
Orb::Price::Bulk::OrHash,
|
1677
|
+
Orb::Price::ThresholdTotalAmount::OrHash,
|
1678
|
+
Orb::Price::TieredPackage::OrHash,
|
1679
|
+
Orb::Price::GroupedTiered::OrHash,
|
1680
|
+
Orb::Price::TieredWithMinimum::OrHash,
|
1681
|
+
Orb::Price::TieredPackageWithMinimum::OrHash,
|
1682
|
+
Orb::Price::PackageWithAllocation::OrHash,
|
1683
|
+
Orb::Price::UnitWithPercent::OrHash,
|
1684
|
+
Orb::Price::MatrixWithAllocation::OrHash,
|
1685
|
+
Orb::Price::TieredWithProration::OrHash,
|
1686
|
+
Orb::Price::UnitWithProration::OrHash,
|
1687
|
+
Orb::Price::GroupedAllocation::OrHash,
|
1688
|
+
Orb::Price::GroupedWithProratedMinimum::OrHash,
|
1689
|
+
Orb::Price::GroupedWithMeteredMinimum::OrHash,
|
1690
|
+
Orb::Price::MatrixWithDisplayName::OrHash,
|
1691
|
+
Orb::Price::BulkWithProration::OrHash,
|
1692
|
+
Orb::Price::GroupedTieredPackage::OrHash,
|
1693
|
+
Orb::Price::MaxGroupTieredPackage::OrHash,
|
1694
|
+
Orb::Price::ScalableMatrixWithUnitPricing::OrHash,
|
1695
|
+
Orb::Price::ScalableMatrixWithTieredPricing::OrHash,
|
1696
|
+
Orb::Price::CumulativeGroupedBulk::OrHash
|
1697
|
+
),
|
1397
1698
|
start_date: Time,
|
1398
1699
|
usage_customer_ids: T.nilable(T::Array[String])
|
1399
|
-
)
|
1400
|
-
.returns(T.attached_class)
|
1700
|
+
).returns(T.attached_class)
|
1401
1701
|
end
|
1402
1702
|
def self.new(
|
1403
1703
|
id:,
|
@@ -1436,58 +1736,72 @@ module Orb
|
|
1436
1736
|
# A list of customer IDs whose usage events will be aggregated and billed under
|
1437
1737
|
# this price interval.
|
1438
1738
|
usage_customer_ids:
|
1439
|
-
)
|
1739
|
+
)
|
1740
|
+
end
|
1741
|
+
|
1440
1742
|
sig do
|
1441
|
-
override
|
1442
|
-
|
1443
|
-
|
1444
|
-
|
1445
|
-
|
1446
|
-
|
1447
|
-
|
1448
|
-
|
1449
|
-
|
1450
|
-
|
1451
|
-
T::Array[
|
1743
|
+
override.returns(
|
1744
|
+
{
|
1745
|
+
id: String,
|
1746
|
+
billing_cycle_day: Integer,
|
1747
|
+
current_billing_period_end_date: T.nilable(Time),
|
1748
|
+
current_billing_period_start_date: T.nilable(Time),
|
1749
|
+
end_date: T.nilable(Time),
|
1750
|
+
filter: T.nilable(String),
|
1751
|
+
fixed_fee_quantity_transitions:
|
1752
|
+
T.nilable(
|
1753
|
+
T::Array[
|
1754
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval::FixedFeeQuantityTransition
|
1755
|
+
]
|
1452
1756
|
),
|
1453
|
-
|
1454
|
-
|
1455
|
-
Orb::
|
1456
|
-
Orb::
|
1457
|
-
Orb::
|
1458
|
-
Orb::
|
1459
|
-
Orb::
|
1460
|
-
Orb::
|
1461
|
-
Orb::
|
1462
|
-
Orb::
|
1463
|
-
Orb::
|
1464
|
-
Orb::
|
1465
|
-
Orb::
|
1466
|
-
Orb::
|
1467
|
-
Orb::
|
1468
|
-
Orb::
|
1469
|
-
Orb::
|
1470
|
-
Orb::
|
1471
|
-
Orb::
|
1472
|
-
Orb::
|
1473
|
-
Orb::
|
1474
|
-
Orb::
|
1475
|
-
Orb::
|
1476
|
-
Orb::
|
1477
|
-
Orb::
|
1478
|
-
Orb::
|
1479
|
-
Orb::
|
1480
|
-
Orb::
|
1481
|
-
Orb::
|
1757
|
+
price:
|
1758
|
+
T.any(
|
1759
|
+
Orb::Price::Unit,
|
1760
|
+
Orb::Price::Package,
|
1761
|
+
Orb::Price::Matrix,
|
1762
|
+
Orb::Price::Tiered,
|
1763
|
+
Orb::Price::TieredBps,
|
1764
|
+
Orb::Price::Bps,
|
1765
|
+
Orb::Price::BulkBps,
|
1766
|
+
Orb::Price::Bulk,
|
1767
|
+
Orb::Price::ThresholdTotalAmount,
|
1768
|
+
Orb::Price::TieredPackage,
|
1769
|
+
Orb::Price::GroupedTiered,
|
1770
|
+
Orb::Price::TieredWithMinimum,
|
1771
|
+
Orb::Price::TieredPackageWithMinimum,
|
1772
|
+
Orb::Price::PackageWithAllocation,
|
1773
|
+
Orb::Price::UnitWithPercent,
|
1774
|
+
Orb::Price::MatrixWithAllocation,
|
1775
|
+
Orb::Price::TieredWithProration,
|
1776
|
+
Orb::Price::UnitWithProration,
|
1777
|
+
Orb::Price::GroupedAllocation,
|
1778
|
+
Orb::Price::GroupedWithProratedMinimum,
|
1779
|
+
Orb::Price::GroupedWithMeteredMinimum,
|
1780
|
+
Orb::Price::MatrixWithDisplayName,
|
1781
|
+
Orb::Price::BulkWithProration,
|
1782
|
+
Orb::Price::GroupedTieredPackage,
|
1783
|
+
Orb::Price::MaxGroupTieredPackage,
|
1784
|
+
Orb::Price::ScalableMatrixWithUnitPricing,
|
1785
|
+
Orb::Price::ScalableMatrixWithTieredPricing,
|
1786
|
+
Orb::Price::CumulativeGroupedBulk
|
1482
1787
|
),
|
1483
|
-
|
1484
|
-
|
1485
|
-
|
1486
|
-
|
1788
|
+
start_date: Time,
|
1789
|
+
usage_customer_ids: T.nilable(T::Array[String])
|
1790
|
+
}
|
1791
|
+
)
|
1792
|
+
end
|
1793
|
+
def to_hash
|
1487
1794
|
end
|
1488
|
-
def to_hash; end
|
1489
1795
|
|
1490
1796
|
class FixedFeeQuantityTransition < Orb::Internal::Type::BaseModel
|
1797
|
+
OrHash =
|
1798
|
+
T.type_alias do
|
1799
|
+
T.any(
|
1800
|
+
Orb::Models::SubscriptionUpdateTrialResponse::PriceInterval::FixedFeeQuantityTransition,
|
1801
|
+
Orb::Internal::AnyHash
|
1802
|
+
)
|
1803
|
+
end
|
1804
|
+
|
1491
1805
|
sig { returns(Time) }
|
1492
1806
|
attr_accessor :effective_date
|
1493
1807
|
|
@@ -1497,15 +1811,35 @@ module Orb
|
|
1497
1811
|
sig { returns(Integer) }
|
1498
1812
|
attr_accessor :quantity
|
1499
1813
|
|
1500
|
-
sig
|
1501
|
-
|
1814
|
+
sig do
|
1815
|
+
params(
|
1816
|
+
effective_date: Time,
|
1817
|
+
price_id: String,
|
1818
|
+
quantity: Integer
|
1819
|
+
).returns(T.attached_class)
|
1820
|
+
end
|
1821
|
+
def self.new(effective_date:, price_id:, quantity:)
|
1822
|
+
end
|
1502
1823
|
|
1503
|
-
sig
|
1504
|
-
|
1824
|
+
sig do
|
1825
|
+
override.returns(
|
1826
|
+
{ effective_date: Time, price_id: String, quantity: Integer }
|
1827
|
+
)
|
1828
|
+
end
|
1829
|
+
def to_hash
|
1830
|
+
end
|
1505
1831
|
end
|
1506
1832
|
end
|
1507
1833
|
|
1508
1834
|
class RedeemedCoupon < Orb::Internal::Type::BaseModel
|
1835
|
+
OrHash =
|
1836
|
+
T.type_alias do
|
1837
|
+
T.any(
|
1838
|
+
Orb::Models::SubscriptionUpdateTrialResponse::RedeemedCoupon,
|
1839
|
+
Orb::Internal::AnyHash
|
1840
|
+
)
|
1841
|
+
end
|
1842
|
+
|
1509
1843
|
sig { returns(String) }
|
1510
1844
|
attr_accessor :coupon_id
|
1511
1845
|
|
@@ -1516,54 +1850,104 @@ module Orb
|
|
1516
1850
|
attr_accessor :start_date
|
1517
1851
|
|
1518
1852
|
sig do
|
1519
|
-
params(
|
1853
|
+
params(
|
1854
|
+
coupon_id: String,
|
1855
|
+
end_date: T.nilable(Time),
|
1856
|
+
start_date: Time
|
1857
|
+
).returns(T.attached_class)
|
1858
|
+
end
|
1859
|
+
def self.new(coupon_id:, end_date:, start_date:)
|
1520
1860
|
end
|
1521
|
-
def self.new(coupon_id:, end_date:, start_date:); end
|
1522
1861
|
|
1523
|
-
sig
|
1524
|
-
|
1862
|
+
sig do
|
1863
|
+
override.returns(
|
1864
|
+
{ coupon_id: String, end_date: T.nilable(Time), start_date: Time }
|
1865
|
+
)
|
1866
|
+
end
|
1867
|
+
def to_hash
|
1868
|
+
end
|
1525
1869
|
end
|
1526
1870
|
|
1527
1871
|
module Status
|
1528
1872
|
extend Orb::Internal::Type::Enum
|
1529
1873
|
|
1530
|
-
TaggedSymbol =
|
1874
|
+
TaggedSymbol =
|
1875
|
+
T.type_alias do
|
1876
|
+
T.all(Symbol, Orb::Models::SubscriptionUpdateTrialResponse::Status)
|
1877
|
+
end
|
1531
1878
|
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
1532
1879
|
|
1533
|
-
ACTIVE =
|
1534
|
-
|
1535
|
-
|
1880
|
+
ACTIVE =
|
1881
|
+
T.let(
|
1882
|
+
:active,
|
1883
|
+
Orb::Models::SubscriptionUpdateTrialResponse::Status::TaggedSymbol
|
1884
|
+
)
|
1885
|
+
ENDED =
|
1886
|
+
T.let(
|
1887
|
+
:ended,
|
1888
|
+
Orb::Models::SubscriptionUpdateTrialResponse::Status::TaggedSymbol
|
1889
|
+
)
|
1890
|
+
UPCOMING =
|
1891
|
+
T.let(
|
1892
|
+
:upcoming,
|
1893
|
+
Orb::Models::SubscriptionUpdateTrialResponse::Status::TaggedSymbol
|
1894
|
+
)
|
1536
1895
|
|
1537
|
-
sig
|
1538
|
-
|
1896
|
+
sig do
|
1897
|
+
override.returns(
|
1898
|
+
T::Array[
|
1899
|
+
Orb::Models::SubscriptionUpdateTrialResponse::Status::TaggedSymbol
|
1900
|
+
]
|
1901
|
+
)
|
1902
|
+
end
|
1903
|
+
def self.values
|
1904
|
+
end
|
1539
1905
|
end
|
1540
1906
|
|
1541
1907
|
class TrialInfo < Orb::Internal::Type::BaseModel
|
1908
|
+
OrHash =
|
1909
|
+
T.type_alias do
|
1910
|
+
T.any(
|
1911
|
+
Orb::Models::SubscriptionUpdateTrialResponse::TrialInfo,
|
1912
|
+
Orb::Internal::AnyHash
|
1913
|
+
)
|
1914
|
+
end
|
1915
|
+
|
1542
1916
|
sig { returns(T.nilable(Time)) }
|
1543
1917
|
attr_accessor :end_date
|
1544
1918
|
|
1545
1919
|
sig { params(end_date: T.nilable(Time)).returns(T.attached_class) }
|
1546
|
-
def self.new(end_date:)
|
1920
|
+
def self.new(end_date:)
|
1921
|
+
end
|
1547
1922
|
|
1548
|
-
sig { override.returns({end_date: T.nilable(Time)}) }
|
1549
|
-
def to_hash
|
1923
|
+
sig { override.returns({ end_date: T.nilable(Time) }) }
|
1924
|
+
def to_hash
|
1925
|
+
end
|
1550
1926
|
end
|
1551
1927
|
|
1552
1928
|
class ChangedResources < Orb::Internal::Type::BaseModel
|
1929
|
+
OrHash =
|
1930
|
+
T.type_alias do
|
1931
|
+
T.any(
|
1932
|
+
Orb::Models::SubscriptionUpdateTrialResponse::ChangedResources,
|
1933
|
+
Orb::Internal::AnyHash
|
1934
|
+
)
|
1935
|
+
end
|
1936
|
+
|
1553
1937
|
# The credit notes that were created as part of this operation.
|
1554
|
-
sig { returns(T::Array[Orb::
|
1938
|
+
sig { returns(T::Array[Orb::CreditNote]) }
|
1555
1939
|
attr_accessor :created_credit_notes
|
1556
1940
|
|
1557
1941
|
# The invoices that were created as part of this operation.
|
1558
|
-
sig { returns(T::Array[Orb::
|
1942
|
+
sig { returns(T::Array[Orb::Invoice]) }
|
1559
1943
|
attr_accessor :created_invoices
|
1560
1944
|
|
1561
1945
|
# The credit notes that were voided as part of this operation.
|
1562
|
-
sig { returns(T::Array[Orb::
|
1946
|
+
sig { returns(T::Array[Orb::CreditNote]) }
|
1563
1947
|
attr_accessor :voided_credit_notes
|
1564
1948
|
|
1565
1949
|
# The invoices that were voided as part of this operation.
|
1566
|
-
sig { returns(T::Array[Orb::
|
1950
|
+
sig { returns(T::Array[Orb::Invoice]) }
|
1567
1951
|
attr_accessor :voided_invoices
|
1568
1952
|
|
1569
1953
|
# The resources that were changed as part of this operation. Only present when
|
@@ -1571,12 +1955,11 @@ module Orb
|
|
1571
1955
|
# `include_changed_resources` parameter was passed in the request.
|
1572
1956
|
sig do
|
1573
1957
|
params(
|
1574
|
-
created_credit_notes: T::Array[
|
1575
|
-
created_invoices: T::Array[
|
1576
|
-
voided_credit_notes: T::Array[
|
1577
|
-
voided_invoices: T::Array[
|
1578
|
-
)
|
1579
|
-
.returns(T.attached_class)
|
1958
|
+
created_credit_notes: T::Array[Orb::CreditNote::OrHash],
|
1959
|
+
created_invoices: T::Array[Orb::Invoice::OrHash],
|
1960
|
+
voided_credit_notes: T::Array[Orb::CreditNote::OrHash],
|
1961
|
+
voided_invoices: T::Array[Orb::Invoice::OrHash]
|
1962
|
+
).returns(T.attached_class)
|
1580
1963
|
end
|
1581
1964
|
def self.new(
|
1582
1965
|
# The credit notes that were created as part of this operation.
|
@@ -1587,19 +1970,21 @@ module Orb
|
|
1587
1970
|
voided_credit_notes:,
|
1588
1971
|
# The invoices that were voided as part of this operation.
|
1589
1972
|
voided_invoices:
|
1590
|
-
)
|
1973
|
+
)
|
1974
|
+
end
|
1975
|
+
|
1591
1976
|
sig do
|
1592
|
-
override
|
1593
|
-
|
1594
|
-
|
1595
|
-
|
1596
|
-
|
1597
|
-
|
1598
|
-
|
1599
|
-
|
1600
|
-
|
1977
|
+
override.returns(
|
1978
|
+
{
|
1979
|
+
created_credit_notes: T::Array[Orb::CreditNote],
|
1980
|
+
created_invoices: T::Array[Orb::Invoice],
|
1981
|
+
voided_credit_notes: T::Array[Orb::CreditNote],
|
1982
|
+
voided_invoices: T::Array[Orb::Invoice]
|
1983
|
+
}
|
1984
|
+
)
|
1985
|
+
end
|
1986
|
+
def to_hash
|
1601
1987
|
end
|
1602
|
-
def to_hash; end
|
1603
1988
|
end
|
1604
1989
|
end
|
1605
1990
|
end
|