orb-billing 0.1.0.pre.alpha.37 → 0.1.0.pre.alpha.38
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/README.md +29 -5
- data/lib/orb/internal/page.rb +6 -2
- data/lib/orb/internal/transport/base_client.rb +2 -2
- data/lib/orb/internal/transport/pooled_net_requester.rb +1 -1
- data/lib/orb/internal/type/array_of.rb +5 -3
- data/lib/orb/internal/type/base_model.rb +12 -6
- data/lib/orb/internal/type/base_page.rb +4 -1
- data/lib/orb/internal/type/{boolean_model.rb → boolean.rb} +2 -2
- data/lib/orb/internal/type/converter.rb +6 -1
- data/lib/orb/internal/type/enum.rb +2 -0
- data/lib/orb/internal/type/hash_of.rb +3 -1
- data/lib/orb/internal/util.rb +28 -45
- data/lib/orb/models/alert.rb +1 -1
- data/lib/orb/models/coupon_list_params.rb +1 -1
- data/lib/orb/models/customer.rb +5 -5
- data/lib/orb/models/customer_create_params.rb +6 -6
- data/lib/orb/models/customer_update_by_external_id_params.rb +6 -6
- data/lib/orb/models/customer_update_params.rb +6 -6
- data/lib/orb/models/customers/credit_list_by_external_id_params.rb +1 -1
- data/lib/orb/models/customers/credit_list_params.rb +1 -1
- data/lib/orb/models/customers/credits/ledger_create_entry_by_external_id_params.rb +2 -2
- data/lib/orb/models/customers/credits/ledger_create_entry_params.rb +2 -2
- data/lib/orb/models/customers/credits/top_up_create_by_external_id_params.rb +2 -2
- data/lib/orb/models/customers/credits/top_up_create_by_external_id_response.rb +2 -2
- data/lib/orb/models/customers/credits/top_up_create_params.rb +2 -2
- data/lib/orb/models/customers/credits/top_up_create_response.rb +2 -2
- data/lib/orb/models/customers/credits/top_up_list_by_external_id_response.rb +2 -2
- data/lib/orb/models/customers/credits/top_up_list_response.rb +2 -2
- data/lib/orb/models/evaluate_price_group.rb +1 -1
- data/lib/orb/models/event_ingest_params.rb +1 -1
- data/lib/orb/models/event_search_response.rb +1 -1
- data/lib/orb/models/events/backfill_close_response.rb +1 -1
- data/lib/orb/models/events/backfill_create_params.rb +1 -1
- data/lib/orb/models/events/backfill_create_response.rb +1 -1
- data/lib/orb/models/events/backfill_fetch_response.rb +1 -1
- data/lib/orb/models/events/backfill_list_response.rb +1 -1
- data/lib/orb/models/events/backfill_revert_response.rb +1 -1
- data/lib/orb/models/invoice.rb +8 -8
- data/lib/orb/models/invoice_create_params.rb +1 -1
- data/lib/orb/models/invoice_fetch_upcoming_response.rb +8 -8
- data/lib/orb/models/invoice_issue_params.rb +1 -1
- data/lib/orb/models/invoice_line_item_create_response.rb +5 -5
- data/lib/orb/models/invoice_list_params.rb +1 -1
- data/lib/orb/models/pagination_metadata.rb +1 -1
- data/lib/orb/models/plan.rb +5 -5
- data/lib/orb/models/plan_create_params.rb +25 -25
- data/lib/orb/models/price.rb +28 -28
- data/lib/orb/models/price_create_params.rb +1 -1
- data/lib/orb/models/subscription.rb +6 -6
- data/lib/orb/models/subscription_cancel_params.rb +1 -1
- data/lib/orb/models/subscription_cancel_response.rb +6 -6
- data/lib/orb/models/subscription_create_params.rb +64 -64
- data/lib/orb/models/subscription_create_response.rb +6 -6
- data/lib/orb/models/subscription_price_intervals_params.rb +35 -35
- data/lib/orb/models/subscription_price_intervals_response.rb +6 -6
- data/lib/orb/models/subscription_schedule_plan_change_params.rb +64 -64
- data/lib/orb/models/subscription_schedule_plan_change_response.rb +6 -6
- data/lib/orb/models/subscription_trigger_phase_params.rb +1 -1
- data/lib/orb/models/subscription_trigger_phase_response.rb +6 -6
- data/lib/orb/models/subscription_unschedule_cancellation_response.rb +6 -6
- data/lib/orb/models/subscription_unschedule_fixed_fee_quantity_updates_response.rb +6 -6
- data/lib/orb/models/subscription_unschedule_pending_plan_changes_response.rb +6 -6
- data/lib/orb/models/subscription_update_fixed_fee_quantity_params.rb +1 -1
- data/lib/orb/models/subscription_update_fixed_fee_quantity_response.rb +6 -6
- data/lib/orb/models/subscription_update_params.rb +1 -1
- data/lib/orb/models/subscription_update_trial_params.rb +1 -1
- data/lib/orb/models/subscription_update_trial_response.rb +6 -6
- data/lib/orb/resources/alerts.rb +6 -1
- data/lib/orb/resources/credit_notes.rb +6 -1
- data/lib/orb/resources/customers/balance_transactions.rb +6 -1
- data/lib/orb/resources/customers/credits/ledger.rb +12 -2
- data/lib/orb/resources/customers.rb +6 -1
- data/lib/orb/resources/invoices.rb +10 -1
- data/lib/orb/resources/metrics.rb +6 -1
- data/lib/orb/resources/plans.rb +6 -1
- data/lib/orb/resources/subscriptions.rb +12 -2
- data/lib/orb/version.rb +1 -1
- data/lib/orb.rb +1 -1
- data/rbi/lib/orb/internal/type/array_of.rbi +2 -2
- data/rbi/lib/orb/internal/type/{boolean_model.rbi → boolean.rbi} +1 -1
- data/rbi/lib/orb/internal/util.rbi +7 -5
- data/rbi/lib/orb/version.rbi +1 -1
- data/sig/orb/internal/type/array_of.rbs +2 -2
- data/sig/orb/internal/type/{boolean_model.rbs → boolean.rbs} +1 -1
- data/sig/orb/internal/util.rbs +5 -5
- data/sig/orb/version.rbs +1 -1
- metadata +5 -5
@@ -30,7 +30,7 @@ module Orb
|
|
30
30
|
# the plan's behavior. If null, defaults to the customer's setting.
|
31
31
|
#
|
32
32
|
# @return [Boolean, nil]
|
33
|
-
required :auto_collection, Orb::Internal::Type::
|
33
|
+
required :auto_collection, Orb::Internal::Type::Boolean, nil?: true
|
34
34
|
|
35
35
|
# @!attribute billing_cycle_anchor_configuration
|
36
36
|
#
|
@@ -337,7 +337,7 @@ module Orb
|
|
337
337
|
# that apply to only one price.
|
338
338
|
#
|
339
339
|
# @return [Boolean]
|
340
|
-
required :is_invoice_level, Orb::Internal::Type::
|
340
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
341
341
|
|
342
342
|
# @!attribute plan_phase_order
|
343
343
|
# The plan phase in which this adjustment is active.
|
@@ -412,7 +412,7 @@ module Orb
|
|
412
412
|
# that apply to only one price.
|
413
413
|
#
|
414
414
|
# @return [Boolean]
|
415
|
-
required :is_invoice_level, Orb::Internal::Type::
|
415
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
416
416
|
|
417
417
|
# @!attribute plan_phase_order
|
418
418
|
# The plan phase in which this adjustment is active.
|
@@ -473,7 +473,7 @@ module Orb
|
|
473
473
|
# that apply to only one price.
|
474
474
|
#
|
475
475
|
# @return [Boolean]
|
476
|
-
required :is_invoice_level, Orb::Internal::Type::
|
476
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
477
477
|
|
478
478
|
# @!attribute percentage_discount
|
479
479
|
# The percentage (as a value between 0 and 1) by which to discount the price
|
@@ -541,7 +541,7 @@ module Orb
|
|
541
541
|
# that apply to only one price.
|
542
542
|
#
|
543
543
|
# @return [Boolean]
|
544
|
-
required :is_invoice_level, Orb::Internal::Type::
|
544
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
545
545
|
|
546
546
|
# @!attribute item_id
|
547
547
|
# The item ID that revenue from this minimum will be attributed to.
|
@@ -617,7 +617,7 @@ module Orb
|
|
617
617
|
# that apply to only one price.
|
618
618
|
#
|
619
619
|
# @return [Boolean]
|
620
|
-
required :is_invoice_level, Orb::Internal::Type::
|
620
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
621
621
|
|
622
622
|
# @!attribute maximum_amount
|
623
623
|
# The maximum amount to charge in a given billing period for the prices this
|
@@ -30,7 +30,7 @@ module Orb
|
|
30
30
|
# the plan's behavior. If null, defaults to the customer's setting.
|
31
31
|
#
|
32
32
|
# @return [Boolean, nil]
|
33
|
-
required :auto_collection, Orb::Internal::Type::
|
33
|
+
required :auto_collection, Orb::Internal::Type::Boolean, nil?: true
|
34
34
|
|
35
35
|
# @!attribute billing_cycle_anchor_configuration
|
36
36
|
#
|
@@ -337,7 +337,7 @@ module Orb
|
|
337
337
|
# that apply to only one price.
|
338
338
|
#
|
339
339
|
# @return [Boolean]
|
340
|
-
required :is_invoice_level, Orb::Internal::Type::
|
340
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
341
341
|
|
342
342
|
# @!attribute plan_phase_order
|
343
343
|
# The plan phase in which this adjustment is active.
|
@@ -412,7 +412,7 @@ module Orb
|
|
412
412
|
# that apply to only one price.
|
413
413
|
#
|
414
414
|
# @return [Boolean]
|
415
|
-
required :is_invoice_level, Orb::Internal::Type::
|
415
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
416
416
|
|
417
417
|
# @!attribute plan_phase_order
|
418
418
|
# The plan phase in which this adjustment is active.
|
@@ -473,7 +473,7 @@ module Orb
|
|
473
473
|
# that apply to only one price.
|
474
474
|
#
|
475
475
|
# @return [Boolean]
|
476
|
-
required :is_invoice_level, Orb::Internal::Type::
|
476
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
477
477
|
|
478
478
|
# @!attribute percentage_discount
|
479
479
|
# The percentage (as a value between 0 and 1) by which to discount the price
|
@@ -541,7 +541,7 @@ module Orb
|
|
541
541
|
# that apply to only one price.
|
542
542
|
#
|
543
543
|
# @return [Boolean]
|
544
|
-
required :is_invoice_level, Orb::Internal::Type::
|
544
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
545
545
|
|
546
546
|
# @!attribute item_id
|
547
547
|
# The item ID that revenue from this minimum will be attributed to.
|
@@ -617,7 +617,7 @@ module Orb
|
|
617
617
|
# that apply to only one price.
|
618
618
|
#
|
619
619
|
# @return [Boolean]
|
620
|
-
required :is_invoice_level, Orb::Internal::Type::
|
620
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
621
621
|
|
622
622
|
# @!attribute maximum_amount
|
623
623
|
# The maximum amount to charge in a given billing period for the prices this
|
@@ -30,7 +30,7 @@ module Orb
|
|
30
30
|
# the plan's behavior. If null, defaults to the customer's setting.
|
31
31
|
#
|
32
32
|
# @return [Boolean, nil]
|
33
|
-
required :auto_collection, Orb::Internal::Type::
|
33
|
+
required :auto_collection, Orb::Internal::Type::Boolean, nil?: true
|
34
34
|
|
35
35
|
# @!attribute billing_cycle_anchor_configuration
|
36
36
|
#
|
@@ -337,7 +337,7 @@ module Orb
|
|
337
337
|
# that apply to only one price.
|
338
338
|
#
|
339
339
|
# @return [Boolean]
|
340
|
-
required :is_invoice_level, Orb::Internal::Type::
|
340
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
341
341
|
|
342
342
|
# @!attribute plan_phase_order
|
343
343
|
# The plan phase in which this adjustment is active.
|
@@ -412,7 +412,7 @@ module Orb
|
|
412
412
|
# that apply to only one price.
|
413
413
|
#
|
414
414
|
# @return [Boolean]
|
415
|
-
required :is_invoice_level, Orb::Internal::Type::
|
415
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
416
416
|
|
417
417
|
# @!attribute plan_phase_order
|
418
418
|
# The plan phase in which this adjustment is active.
|
@@ -473,7 +473,7 @@ module Orb
|
|
473
473
|
# that apply to only one price.
|
474
474
|
#
|
475
475
|
# @return [Boolean]
|
476
|
-
required :is_invoice_level, Orb::Internal::Type::
|
476
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
477
477
|
|
478
478
|
# @!attribute percentage_discount
|
479
479
|
# The percentage (as a value between 0 and 1) by which to discount the price
|
@@ -541,7 +541,7 @@ module Orb
|
|
541
541
|
# that apply to only one price.
|
542
542
|
#
|
543
543
|
# @return [Boolean]
|
544
|
-
required :is_invoice_level, Orb::Internal::Type::
|
544
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
545
545
|
|
546
546
|
# @!attribute item_id
|
547
547
|
# The item ID that revenue from this minimum will be attributed to.
|
@@ -617,7 +617,7 @@ module Orb
|
|
617
617
|
# that apply to only one price.
|
618
618
|
#
|
619
619
|
# @return [Boolean]
|
620
|
-
required :is_invoice_level, Orb::Internal::Type::
|
620
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
621
621
|
|
622
622
|
# @!attribute maximum_amount
|
623
623
|
# The maximum amount to charge in a given billing period for the prices this
|
@@ -25,7 +25,7 @@ module Orb
|
|
25
25
|
# existing invoices to be changed.
|
26
26
|
#
|
27
27
|
# @return [Boolean, nil]
|
28
|
-
optional :allow_invoice_credit_or_void, Orb::Internal::Type::
|
28
|
+
optional :allow_invoice_credit_or_void, Orb::Internal::Type::Boolean, nil?: true
|
29
29
|
|
30
30
|
# @!attribute [r] change_option
|
31
31
|
# Determines when the change takes effect. Note that if `effective_date` is
|
@@ -30,7 +30,7 @@ module Orb
|
|
30
30
|
# the plan's behavior. If null, defaults to the customer's setting.
|
31
31
|
#
|
32
32
|
# @return [Boolean, nil]
|
33
|
-
required :auto_collection, Orb::Internal::Type::
|
33
|
+
required :auto_collection, Orb::Internal::Type::Boolean, nil?: true
|
34
34
|
|
35
35
|
# @!attribute billing_cycle_anchor_configuration
|
36
36
|
#
|
@@ -337,7 +337,7 @@ module Orb
|
|
337
337
|
# that apply to only one price.
|
338
338
|
#
|
339
339
|
# @return [Boolean]
|
340
|
-
required :is_invoice_level, Orb::Internal::Type::
|
340
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
341
341
|
|
342
342
|
# @!attribute plan_phase_order
|
343
343
|
# The plan phase in which this adjustment is active.
|
@@ -412,7 +412,7 @@ module Orb
|
|
412
412
|
# that apply to only one price.
|
413
413
|
#
|
414
414
|
# @return [Boolean]
|
415
|
-
required :is_invoice_level, Orb::Internal::Type::
|
415
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
416
416
|
|
417
417
|
# @!attribute plan_phase_order
|
418
418
|
# The plan phase in which this adjustment is active.
|
@@ -473,7 +473,7 @@ module Orb
|
|
473
473
|
# that apply to only one price.
|
474
474
|
#
|
475
475
|
# @return [Boolean]
|
476
|
-
required :is_invoice_level, Orb::Internal::Type::
|
476
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
477
477
|
|
478
478
|
# @!attribute percentage_discount
|
479
479
|
# The percentage (as a value between 0 and 1) by which to discount the price
|
@@ -541,7 +541,7 @@ module Orb
|
|
541
541
|
# that apply to only one price.
|
542
542
|
#
|
543
543
|
# @return [Boolean]
|
544
|
-
required :is_invoice_level, Orb::Internal::Type::
|
544
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
545
545
|
|
546
546
|
# @!attribute item_id
|
547
547
|
# The item ID that revenue from this minimum will be attributed to.
|
@@ -617,7 +617,7 @@ module Orb
|
|
617
617
|
# that apply to only one price.
|
618
618
|
#
|
619
619
|
# @return [Boolean]
|
620
|
-
required :is_invoice_level, Orb::Internal::Type::
|
620
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
621
621
|
|
622
622
|
# @!attribute maximum_amount
|
623
623
|
# The maximum amount to charge in a given billing period for the prices this
|
@@ -14,7 +14,7 @@ module Orb
|
|
14
14
|
# the plan's behavior.
|
15
15
|
#
|
16
16
|
# @return [Boolean, nil]
|
17
|
-
optional :auto_collection, Orb::Internal::Type::
|
17
|
+
optional :auto_collection, Orb::Internal::Type::Boolean, nil?: true
|
18
18
|
|
19
19
|
# @!attribute default_invoice_memo
|
20
20
|
# Determines the default memo on this subscription's invoices. Note that if this
|
@@ -30,7 +30,7 @@ module Orb
|
|
30
30
|
# the plan's behavior. If null, defaults to the customer's setting.
|
31
31
|
#
|
32
32
|
# @return [Boolean, nil]
|
33
|
-
required :auto_collection, Orb::Internal::Type::
|
33
|
+
required :auto_collection, Orb::Internal::Type::Boolean, nil?: true
|
34
34
|
|
35
35
|
# @!attribute billing_cycle_anchor_configuration
|
36
36
|
#
|
@@ -335,7 +335,7 @@ module Orb
|
|
335
335
|
# that apply to only one price.
|
336
336
|
#
|
337
337
|
# @return [Boolean]
|
338
|
-
required :is_invoice_level, Orb::Internal::Type::
|
338
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
339
339
|
|
340
340
|
# @!attribute plan_phase_order
|
341
341
|
# The plan phase in which this adjustment is active.
|
@@ -410,7 +410,7 @@ module Orb
|
|
410
410
|
# that apply to only one price.
|
411
411
|
#
|
412
412
|
# @return [Boolean]
|
413
|
-
required :is_invoice_level, Orb::Internal::Type::
|
413
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
414
414
|
|
415
415
|
# @!attribute plan_phase_order
|
416
416
|
# The plan phase in which this adjustment is active.
|
@@ -471,7 +471,7 @@ module Orb
|
|
471
471
|
# that apply to only one price.
|
472
472
|
#
|
473
473
|
# @return [Boolean]
|
474
|
-
required :is_invoice_level, Orb::Internal::Type::
|
474
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
475
475
|
|
476
476
|
# @!attribute percentage_discount
|
477
477
|
# The percentage (as a value between 0 and 1) by which to discount the price
|
@@ -539,7 +539,7 @@ module Orb
|
|
539
539
|
# that apply to only one price.
|
540
540
|
#
|
541
541
|
# @return [Boolean]
|
542
|
-
required :is_invoice_level, Orb::Internal::Type::
|
542
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
543
543
|
|
544
544
|
# @!attribute item_id
|
545
545
|
# The item ID that revenue from this minimum will be attributed to.
|
@@ -615,7 +615,7 @@ module Orb
|
|
615
615
|
# that apply to only one price.
|
616
616
|
#
|
617
617
|
# @return [Boolean]
|
618
|
-
required :is_invoice_level, Orb::Internal::Type::
|
618
|
+
required :is_invoice_level, Orb::Internal::Type::Boolean
|
619
619
|
|
620
620
|
# @!attribute maximum_amount
|
621
621
|
# The maximum amount to charge in a given billing period for the prices this
|
data/lib/orb/resources/alerts.rb
CHANGED
@@ -77,7 +77,12 @@ module Orb
|
|
77
77
|
@client.request(
|
78
78
|
method: :get,
|
79
79
|
path: "alerts",
|
80
|
-
query: parsed
|
80
|
+
query: parsed.transform_keys(
|
81
|
+
created_at_gt: :"created_at[gt]",
|
82
|
+
created_at_gte: :"created_at[gte]",
|
83
|
+
created_at_lt: :"created_at[lt]",
|
84
|
+
created_at_lte: :"created_at[lte]"
|
85
|
+
),
|
81
86
|
page: Orb::Internal::Page,
|
82
87
|
model: Orb::Models::Alert,
|
83
88
|
options: options
|
@@ -49,7 +49,12 @@ module Orb
|
|
49
49
|
@client.request(
|
50
50
|
method: :get,
|
51
51
|
path: "credit_notes",
|
52
|
-
query: parsed
|
52
|
+
query: parsed.transform_keys(
|
53
|
+
created_at_gt: :"created_at[gt]",
|
54
|
+
created_at_gte: :"created_at[gte]",
|
55
|
+
created_at_lt: :"created_at[lt]",
|
56
|
+
created_at_lte: :"created_at[lte]"
|
57
|
+
),
|
53
58
|
page: Orb::Internal::Page,
|
54
59
|
model: Orb::Models::CreditNote,
|
55
60
|
options: options
|
@@ -77,7 +77,12 @@ module Orb
|
|
77
77
|
@client.request(
|
78
78
|
method: :get,
|
79
79
|
path: ["customers/%1$s/balance_transactions", customer_id],
|
80
|
-
query: parsed
|
80
|
+
query: parsed.transform_keys(
|
81
|
+
operation_time_gt: :"operation_time[gt]",
|
82
|
+
operation_time_gte: :"operation_time[gte]",
|
83
|
+
operation_time_lt: :"operation_time[lt]",
|
84
|
+
operation_time_lte: :"operation_time[lte]"
|
85
|
+
),
|
81
86
|
page: Orb::Internal::Page,
|
82
87
|
model: Orb::Models::Customers::BalanceTransactionListResponse,
|
83
88
|
options: options
|
@@ -110,7 +110,12 @@ module Orb
|
|
110
110
|
@client.request(
|
111
111
|
method: :get,
|
112
112
|
path: ["customers/%1$s/credits/ledger", customer_id],
|
113
|
-
query: parsed
|
113
|
+
query: parsed.transform_keys(
|
114
|
+
created_at_gt: :"created_at[gt]",
|
115
|
+
created_at_gte: :"created_at[gte]",
|
116
|
+
created_at_lt: :"created_at[lt]",
|
117
|
+
created_at_lte: :"created_at[lte]"
|
118
|
+
),
|
114
119
|
page: Orb::Internal::Page,
|
115
120
|
model: Orb::Models::Customers::Credits::LedgerListResponse,
|
116
121
|
options: options
|
@@ -507,7 +512,12 @@ module Orb
|
|
507
512
|
@client.request(
|
508
513
|
method: :get,
|
509
514
|
path: ["customers/external_customer_id/%1$s/credits/ledger", external_customer_id],
|
510
|
-
query: parsed
|
515
|
+
query: parsed.transform_keys(
|
516
|
+
created_at_gt: :"created_at[gt]",
|
517
|
+
created_at_gte: :"created_at[gte]",
|
518
|
+
created_at_lt: :"created_at[lt]",
|
519
|
+
created_at_lte: :"created_at[lte]"
|
520
|
+
),
|
511
521
|
page: Orb::Internal::Page,
|
512
522
|
model: Orb::Models::Customers::Credits::LedgerListByExternalIDResponse,
|
513
523
|
options: options
|
@@ -128,7 +128,12 @@ module Orb
|
|
128
128
|
@client.request(
|
129
129
|
method: :get,
|
130
130
|
path: "customers",
|
131
|
-
query: parsed
|
131
|
+
query: parsed.transform_keys(
|
132
|
+
created_at_gt: :"created_at[gt]",
|
133
|
+
created_at_gte: :"created_at[gte]",
|
134
|
+
created_at_lt: :"created_at[lt]",
|
135
|
+
created_at_lte: :"created_at[lte]"
|
136
|
+
),
|
132
137
|
page: Orb::Internal::Page,
|
133
138
|
model: Orb::Models::Customer,
|
134
139
|
options: options
|
@@ -104,7 +104,16 @@ module Orb
|
|
104
104
|
@client.request(
|
105
105
|
method: :get,
|
106
106
|
path: "invoices",
|
107
|
-
query: parsed
|
107
|
+
query: parsed.transform_keys(
|
108
|
+
amount_gt: :"amount[gt]",
|
109
|
+
amount_lt: :"amount[lt]",
|
110
|
+
due_date_gt: :"due_date[gt]",
|
111
|
+
due_date_lt: :"due_date[lt]",
|
112
|
+
invoice_date_gt: :"invoice_date[gt]",
|
113
|
+
invoice_date_gte: :"invoice_date[gte]",
|
114
|
+
invoice_date_lt: :"invoice_date[lt]",
|
115
|
+
invoice_date_lte: :"invoice_date[lte]"
|
116
|
+
),
|
108
117
|
page: Orb::Internal::Page,
|
109
118
|
model: Orb::Models::Invoice,
|
110
119
|
options: options
|
@@ -76,7 +76,12 @@ module Orb
|
|
76
76
|
@client.request(
|
77
77
|
method: :get,
|
78
78
|
path: "metrics",
|
79
|
-
query: parsed
|
79
|
+
query: parsed.transform_keys(
|
80
|
+
created_at_gt: :"created_at[gt]",
|
81
|
+
created_at_gte: :"created_at[gte]",
|
82
|
+
created_at_lt: :"created_at[lt]",
|
83
|
+
created_at_lte: :"created_at[lte]"
|
84
|
+
),
|
80
85
|
page: Orb::Internal::Page,
|
81
86
|
model: Orb::Models::BillableMetric,
|
82
87
|
options: options
|
data/lib/orb/resources/plans.rb
CHANGED
@@ -79,7 +79,12 @@ module Orb
|
|
79
79
|
@client.request(
|
80
80
|
method: :get,
|
81
81
|
path: "plans",
|
82
|
-
query: parsed
|
82
|
+
query: parsed.transform_keys(
|
83
|
+
created_at_gt: :"created_at[gt]",
|
84
|
+
created_at_gte: :"created_at[gte]",
|
85
|
+
created_at_lt: :"created_at[lt]",
|
86
|
+
created_at_lte: :"created_at[lte]"
|
87
|
+
),
|
83
88
|
page: Orb::Internal::Page,
|
84
89
|
model: Orb::Models::Plan,
|
85
90
|
options: options
|
@@ -368,7 +368,12 @@ module Orb
|
|
368
368
|
@client.request(
|
369
369
|
method: :get,
|
370
370
|
path: "subscriptions",
|
371
|
-
query: parsed
|
371
|
+
query: parsed.transform_keys(
|
372
|
+
created_at_gt: :"created_at[gt]",
|
373
|
+
created_at_gte: :"created_at[gte]",
|
374
|
+
created_at_lt: :"created_at[lt]",
|
375
|
+
created_at_lte: :"created_at[lte]"
|
376
|
+
),
|
372
377
|
page: Orb::Internal::Page,
|
373
378
|
model: Orb::Models::Subscription,
|
374
379
|
options: options
|
@@ -537,7 +542,12 @@ module Orb
|
|
537
542
|
@client.request(
|
538
543
|
method: :get,
|
539
544
|
path: ["subscriptions/%1$s/schedule", subscription_id],
|
540
|
-
query: parsed
|
545
|
+
query: parsed.transform_keys(
|
546
|
+
start_date_gt: :"start_date[gt]",
|
547
|
+
start_date_gte: :"start_date[gte]",
|
548
|
+
start_date_lt: :"start_date[lt]",
|
549
|
+
start_date_lte: :"start_date[lte]"
|
550
|
+
),
|
541
551
|
page: Orb::Internal::Page,
|
542
552
|
model: Orb::Models::SubscriptionFetchScheduleResponse,
|
543
553
|
options: options
|
data/lib/orb/version.rb
CHANGED
data/lib/orb.rb
CHANGED
@@ -39,7 +39,7 @@ require_relative "orb/version"
|
|
39
39
|
require_relative "orb/internal/util"
|
40
40
|
require_relative "orb/internal/type/converter"
|
41
41
|
require_relative "orb/internal/type/unknown"
|
42
|
-
require_relative "orb/internal/type/
|
42
|
+
require_relative "orb/internal/type/boolean"
|
43
43
|
require_relative "orb/internal/type/enum"
|
44
44
|
require_relative "orb/internal/type/union"
|
45
45
|
require_relative "orb/internal/type/array_of"
|
@@ -40,7 +40,7 @@ module Orb
|
|
40
40
|
sig(:final) do
|
41
41
|
override
|
42
42
|
.params(value: T.any(
|
43
|
-
T::
|
43
|
+
T::Array[T.anything],
|
44
44
|
T.anything
|
45
45
|
),
|
46
46
|
state: Orb::Internal::Type::Converter::State)
|
@@ -52,7 +52,7 @@ module Orb
|
|
52
52
|
# @api private
|
53
53
|
sig(:final) do
|
54
54
|
override
|
55
|
-
.params(value: T.any(T::
|
55
|
+
.params(value: T.any(T::Array[T.anything], T.anything))
|
56
56
|
.returns(T.any(T::Array[T.anything], T.anything))
|
57
57
|
end
|
58
58
|
def dump(value)
|
@@ -28,22 +28,22 @@ module Orb
|
|
28
28
|
end
|
29
29
|
|
30
30
|
# @api private
|
31
|
-
sig { params(input: T.
|
31
|
+
sig { params(input: T.any(String, T::Boolean)).returns(T.any(T::Boolean, T.anything)) }
|
32
32
|
def coerce_boolean(input)
|
33
33
|
end
|
34
34
|
|
35
35
|
# @api private
|
36
|
-
sig { params(input: T.
|
36
|
+
sig { params(input: T.any(String, T::Boolean)).returns(T.nilable(T::Boolean)) }
|
37
37
|
def coerce_boolean!(input)
|
38
38
|
end
|
39
39
|
|
40
40
|
# @api private
|
41
|
-
sig { params(input: T.
|
41
|
+
sig { params(input: T.any(String, Integer)).returns(T.any(Integer, T.anything)) }
|
42
42
|
def coerce_integer(input)
|
43
43
|
end
|
44
44
|
|
45
45
|
# @api private
|
46
|
-
sig { params(input: T.
|
46
|
+
sig { params(input: T.any(String, Integer, Float)).returns(T.any(Float, T.anything)) }
|
47
47
|
def coerce_float(input)
|
48
48
|
end
|
49
49
|
|
@@ -271,7 +271,9 @@ module Orb
|
|
271
271
|
# @api private
|
272
272
|
#
|
273
273
|
# https://html.spec.whatwg.org/multipage/server-sent-events.html#parsing-an-event-stream
|
274
|
-
sig
|
274
|
+
sig do
|
275
|
+
params(lines: T::Enumerable[String]).returns(T::Enumerable[Orb::Internal::Util::ServerSentEvent])
|
276
|
+
end
|
275
277
|
def decode_sse(lines)
|
276
278
|
end
|
277
279
|
end
|
data/rbi/lib/orb/version.rbi
CHANGED
@@ -16,11 +16,11 @@ module Orb
|
|
16
16
|
def ==: (top other) -> bool
|
17
17
|
|
18
18
|
def coerce: (
|
19
|
-
|
19
|
+
::Array[top] | top value,
|
20
20
|
state: Orb::Internal::Type::Converter::state
|
21
21
|
) -> (::Array[top] | top)
|
22
22
|
|
23
|
-
def dump: (
|
23
|
+
def dump: (::Array[top] | top value) -> (::Array[top] | top)
|
24
24
|
|
25
25
|
def item_type: -> Elem
|
26
26
|
|
data/sig/orb/internal/util.rbs
CHANGED
@@ -9,13 +9,13 @@ module Orb
|
|
9
9
|
|
10
10
|
def self?.primitive?: (top input) -> bool
|
11
11
|
|
12
|
-
def self?.coerce_boolean: (
|
12
|
+
def self?.coerce_boolean: (String | bool input) -> (bool | top)
|
13
13
|
|
14
|
-
def self?.coerce_boolean!: (
|
14
|
+
def self?.coerce_boolean!: (String | bool input) -> bool?
|
15
15
|
|
16
|
-
def self?.coerce_integer: (
|
16
|
+
def self?.coerce_integer: (String | Integer input) -> (Integer | top)
|
17
17
|
|
18
|
-
def self?.coerce_float: (
|
18
|
+
def self?.coerce_float: (String | Integer | Float input) -> (Float | top)
|
19
19
|
|
20
20
|
def self?.coerce_hash: (top input) -> (::Hash[top, top] | top)
|
21
21
|
|
@@ -133,7 +133,7 @@ module Orb
|
|
133
133
|
|
134
134
|
def self?.decode_sse: (
|
135
135
|
Enumerable[String] lines
|
136
|
-
) -> Orb::Internal::Util::server_sent_event
|
136
|
+
) -> Enumerable[Orb::Internal::Util::server_sent_event]
|
137
137
|
end
|
138
138
|
end
|
139
139
|
end
|
data/sig/orb/version.rbs
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: orb-billing
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.0.pre.alpha.
|
4
|
+
version: 0.1.0.pre.alpha.38
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Orb
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-04-
|
11
|
+
date: 2025-04-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: connection_pool
|
@@ -42,7 +42,7 @@ files:
|
|
42
42
|
- lib/orb/internal/type/array_of.rb
|
43
43
|
- lib/orb/internal/type/base_model.rb
|
44
44
|
- lib/orb/internal/type/base_page.rb
|
45
|
-
- lib/orb/internal/type/
|
45
|
+
- lib/orb/internal/type/boolean.rb
|
46
46
|
- lib/orb/internal/type/converter.rb
|
47
47
|
- lib/orb/internal/type/enum.rb
|
48
48
|
- lib/orb/internal/type/hash_of.rb
|
@@ -253,7 +253,7 @@ files:
|
|
253
253
|
- rbi/lib/orb/internal/type/array_of.rbi
|
254
254
|
- rbi/lib/orb/internal/type/base_model.rbi
|
255
255
|
- rbi/lib/orb/internal/type/base_page.rbi
|
256
|
-
- rbi/lib/orb/internal/type/
|
256
|
+
- rbi/lib/orb/internal/type/boolean.rbi
|
257
257
|
- rbi/lib/orb/internal/type/converter.rbi
|
258
258
|
- rbi/lib/orb/internal/type/enum.rbi
|
259
259
|
- rbi/lib/orb/internal/type/hash_of.rbi
|
@@ -463,7 +463,7 @@ files:
|
|
463
463
|
- sig/orb/internal/type/array_of.rbs
|
464
464
|
- sig/orb/internal/type/base_model.rbs
|
465
465
|
- sig/orb/internal/type/base_page.rbs
|
466
|
-
- sig/orb/internal/type/
|
466
|
+
- sig/orb/internal/type/boolean.rbs
|
467
467
|
- sig/orb/internal/type/converter.rbs
|
468
468
|
- sig/orb/internal/type/enum.rbs
|
469
469
|
- sig/orb/internal/type/hash_of.rbs
|