metronome-sdk 0.2.0 → 0.3.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 +25 -0
- data/README.md +1 -1
- data/lib/metronome_sdk/internal/type/array_of.rb +1 -0
- data/lib/metronome_sdk/internal/type/base_model.rb +3 -1
- data/lib/metronome_sdk/internal/type/converter.rb +27 -0
- data/lib/metronome_sdk/internal/type/hash_of.rb +1 -0
- data/lib/metronome_sdk/internal/type/union.rb +9 -7
- data/lib/metronome_sdk/models/schedule_point_in_time.rb +14 -1
- data/lib/metronome_sdk/models/v1/contract_amend_params.rb +54 -5
- data/lib/metronome_sdk/models/v1/contract_create_params.rb +60 -11
- data/lib/metronome_sdk/models/v1/contracts/product_create_params.rb +8 -1
- data/lib/metronome_sdk/models/v1/customers/commit_create_params.rb +10 -1
- data/lib/metronome_sdk/models/v1/customers/invoice.rb +13 -1
- data/lib/metronome_sdk/models/v2/contract_edit_commit_params.rb +10 -1
- data/lib/metronome_sdk/models/v2/contract_edit_credit_params.rb +10 -1
- data/lib/metronome_sdk/models/v2/contract_edit_params.rb +76 -13
- data/lib/metronome_sdk/models/v2/contract_get_edit_history_response.rb +34 -3
- data/lib/metronome_sdk/resources/v1/contracts/products.rb +3 -1
- data/lib/metronome_sdk/resources/v2/contracts.rb +6 -2
- data/lib/metronome_sdk/version.rb +1 -1
- data/rbi/metronome_sdk/internal/type/converter.rbi +58 -0
- data/rbi/metronome_sdk/internal/type/union.rbi +9 -2
- data/rbi/metronome_sdk/models/schedule_point_in_time.rbi +17 -1
- data/rbi/metronome_sdk/models/v1/contract_amend_params.rbi +76 -3
- data/rbi/metronome_sdk/models/v1/contract_create_params.rbi +84 -11
- data/rbi/metronome_sdk/models/v1/contracts/product_create_params.rbi +9 -0
- data/rbi/metronome_sdk/models/v1/customers/commit_create_params.rbi +13 -0
- data/rbi/metronome_sdk/models/v1/customers/invoice.rbi +16 -0
- data/rbi/metronome_sdk/models/v2/contract_edit_commit_params.rbi +10 -0
- data/rbi/metronome_sdk/models/v2/contract_edit_credit_params.rbi +10 -0
- data/rbi/metronome_sdk/models/v2/contract_edit_params.rbi +96 -11
- data/rbi/metronome_sdk/models/v2/contract_get_edit_history_response.rbi +33 -0
- data/rbi/metronome_sdk/resources/v1/contracts/products.rbi +2 -0
- data/rbi/metronome_sdk/resources/v2/contracts.rbi +8 -0
- data/sig/metronome_sdk/internal/type/converter.rbs +17 -0
- data/sig/metronome_sdk/internal/type/union.rbs +2 -2
- data/sig/metronome_sdk/models/schedule_point_in_time.rbs +7 -0
- data/sig/metronome_sdk/models/v1/contract_amend_params.rbs +38 -3
- data/sig/metronome_sdk/models/v1/contract_create_params.rbs +38 -3
- data/sig/metronome_sdk/models/v1/contracts/product_create_params.rbs +7 -0
- data/sig/metronome_sdk/models/v1/customers/commit_create_params.rbs +7 -0
- data/sig/metronome_sdk/models/v1/customers/invoice.rbs +5 -0
- data/sig/metronome_sdk/models/v2/contract_edit_commit_params.rbs +5 -0
- data/sig/metronome_sdk/models/v2/contract_edit_credit_params.rbs +5 -0
- data/sig/metronome_sdk/models/v2/contract_edit_params.rbs +48 -3
- data/sig/metronome_sdk/models/v2/contract_get_edit_history_response.rbs +17 -0
- data/sig/metronome_sdk/resources/v1/contracts/products.rbs +1 -0
- data/sig/metronome_sdk/resources/v2/contracts.rbs +2 -0
- metadata +2 -2
@@ -1505,6 +1505,14 @@ module MetronomeSDK
|
|
1505
1505
|
sig { params(credit_type_id: String).void }
|
1506
1506
|
attr_writer :credit_type_id
|
1507
1507
|
|
1508
|
+
# This field is only applicable to commit invoice schedules. If true, this
|
1509
|
+
# schedule will not generate an invoice.
|
1510
|
+
sig { returns(T.nilable(T::Boolean)) }
|
1511
|
+
attr_reader :do_not_invoice
|
1512
|
+
|
1513
|
+
sig { params(do_not_invoice: T::Boolean).void }
|
1514
|
+
attr_writer :do_not_invoice
|
1515
|
+
|
1508
1516
|
# Enter the unit price and quantity for the charge or instead only send the
|
1509
1517
|
# amount. If amount is sent, the unit price is assumed to be the amount and
|
1510
1518
|
# quantity is inferred to be 1.
|
@@ -1554,6 +1562,7 @@ module MetronomeSDK
|
|
1554
1562
|
sig do
|
1555
1563
|
params(
|
1556
1564
|
credit_type_id: String,
|
1565
|
+
do_not_invoice: T::Boolean,
|
1557
1566
|
recurring_schedule:
|
1558
1567
|
MetronomeSDK::V2::ContractEditParams::AddCommit::InvoiceSchedule::RecurringSchedule::OrHash,
|
1559
1568
|
schedule_items:
|
@@ -1565,6 +1574,9 @@ module MetronomeSDK
|
|
1565
1574
|
def self.new(
|
1566
1575
|
# Defaults to USD (cents) if not passed.
|
1567
1576
|
credit_type_id: nil,
|
1577
|
+
# This field is only applicable to commit invoice schedules. If true, this
|
1578
|
+
# schedule will not generate an invoice.
|
1579
|
+
do_not_invoice: nil,
|
1568
1580
|
# Enter the unit price and quantity for the charge or instead only send the
|
1569
1581
|
# amount. If amount is sent, the unit price is assumed to be the amount and
|
1570
1582
|
# quantity is inferred to be 1.
|
@@ -1578,6 +1590,7 @@ module MetronomeSDK
|
|
1578
1590
|
override.returns(
|
1579
1591
|
{
|
1580
1592
|
credit_type_id: String,
|
1593
|
+
do_not_invoice: T::Boolean,
|
1581
1594
|
recurring_schedule:
|
1582
1595
|
MetronomeSDK::V2::ContractEditParams::AddCommit::InvoiceSchedule::RecurringSchedule,
|
1583
1596
|
schedule_items:
|
@@ -2108,12 +2121,27 @@ module MetronomeSDK
|
|
2108
2121
|
sig { params(invoice_metadata: T::Hash[Symbol, String]).void }
|
2109
2122
|
attr_writer :invoice_metadata
|
2110
2123
|
|
2124
|
+
# If true, the payment will be made assuming the customer is present (i.e. on
|
2125
|
+
# session).
|
2126
|
+
#
|
2127
|
+
# If false, the payment will be made assuming the customer is not present (i.e.
|
2128
|
+
# off session). For cardholders from a country with an e-mandate requirement (e.g.
|
2129
|
+
# India), the payment may be declined.
|
2130
|
+
#
|
2131
|
+
# If left blank, will default to false.
|
2132
|
+
sig { returns(T.nilable(T::Boolean)) }
|
2133
|
+
attr_reader :on_session_payment
|
2134
|
+
|
2135
|
+
sig { params(on_session_payment: T::Boolean).void }
|
2136
|
+
attr_writer :on_session_payment
|
2137
|
+
|
2111
2138
|
# Only applicable if using STRIPE as your payment gateway type.
|
2112
2139
|
sig do
|
2113
2140
|
params(
|
2114
2141
|
payment_type:
|
2115
2142
|
MetronomeSDK::V2::ContractEditParams::AddCommit::PaymentGateConfig::StripeConfig::PaymentType::OrSymbol,
|
2116
|
-
invoice_metadata: T::Hash[Symbol, String]
|
2143
|
+
invoice_metadata: T::Hash[Symbol, String],
|
2144
|
+
on_session_payment: T::Boolean
|
2117
2145
|
).returns(T.attached_class)
|
2118
2146
|
end
|
2119
2147
|
def self.new(
|
@@ -2121,7 +2149,16 @@ module MetronomeSDK
|
|
2121
2149
|
payment_type:,
|
2122
2150
|
# Metadata to be added to the Stripe invoice. Only applicable if using INVOICE as
|
2123
2151
|
# your payment type.
|
2124
|
-
invoice_metadata: nil
|
2152
|
+
invoice_metadata: nil,
|
2153
|
+
# If true, the payment will be made assuming the customer is present (i.e. on
|
2154
|
+
# session).
|
2155
|
+
#
|
2156
|
+
# If false, the payment will be made assuming the customer is not present (i.e.
|
2157
|
+
# off session). For cardholders from a country with an e-mandate requirement (e.g.
|
2158
|
+
# India), the payment may be declined.
|
2159
|
+
#
|
2160
|
+
# If left blank, will default to false.
|
2161
|
+
on_session_payment: nil
|
2125
2162
|
)
|
2126
2163
|
end
|
2127
2164
|
|
@@ -2130,7 +2167,8 @@ module MetronomeSDK
|
|
2130
2167
|
{
|
2131
2168
|
payment_type:
|
2132
2169
|
MetronomeSDK::V2::ContractEditParams::AddCommit::PaymentGateConfig::StripeConfig::PaymentType::OrSymbol,
|
2133
|
-
invoice_metadata: T::Hash[Symbol, String]
|
2170
|
+
invoice_metadata: T::Hash[Symbol, String],
|
2171
|
+
on_session_payment: T::Boolean
|
2134
2172
|
}
|
2135
2173
|
)
|
2136
2174
|
end
|
@@ -3128,6 +3166,14 @@ module MetronomeSDK
|
|
3128
3166
|
sig { params(credit_type_id: String).void }
|
3129
3167
|
attr_writer :credit_type_id
|
3130
3168
|
|
3169
|
+
# This field is only applicable to commit invoice schedules. If true, this
|
3170
|
+
# schedule will not generate an invoice.
|
3171
|
+
sig { returns(T.nilable(T::Boolean)) }
|
3172
|
+
attr_reader :do_not_invoice
|
3173
|
+
|
3174
|
+
sig { params(do_not_invoice: T::Boolean).void }
|
3175
|
+
attr_writer :do_not_invoice
|
3176
|
+
|
3131
3177
|
# Enter the unit price and quantity for the charge or instead only send the
|
3132
3178
|
# amount. If amount is sent, the unit price is assumed to be the amount and
|
3133
3179
|
# quantity is inferred to be 1.
|
@@ -3174,6 +3220,7 @@ module MetronomeSDK
|
|
3174
3220
|
sig do
|
3175
3221
|
params(
|
3176
3222
|
credit_type_id: String,
|
3223
|
+
do_not_invoice: T::Boolean,
|
3177
3224
|
recurring_schedule:
|
3178
3225
|
MetronomeSDK::V2::ContractEditParams::AddDiscount::Schedule::RecurringSchedule::OrHash,
|
3179
3226
|
schedule_items:
|
@@ -3185,6 +3232,9 @@ module MetronomeSDK
|
|
3185
3232
|
def self.new(
|
3186
3233
|
# Defaults to USD (cents) if not passed.
|
3187
3234
|
credit_type_id: nil,
|
3235
|
+
# This field is only applicable to commit invoice schedules. If true, this
|
3236
|
+
# schedule will not generate an invoice.
|
3237
|
+
do_not_invoice: nil,
|
3188
3238
|
# Enter the unit price and quantity for the charge or instead only send the
|
3189
3239
|
# amount. If amount is sent, the unit price is assumed to be the amount and
|
3190
3240
|
# quantity is inferred to be 1.
|
@@ -3198,6 +3248,7 @@ module MetronomeSDK
|
|
3198
3248
|
override.returns(
|
3199
3249
|
{
|
3200
3250
|
credit_type_id: String,
|
3251
|
+
do_not_invoice: T::Boolean,
|
3201
3252
|
recurring_schedule:
|
3202
3253
|
MetronomeSDK::V2::ContractEditParams::AddDiscount::Schedule::RecurringSchedule,
|
3203
3254
|
schedule_items:
|
@@ -5367,8 +5418,8 @@ module MetronomeSDK
|
|
5367
5418
|
sig { returns(Float) }
|
5368
5419
|
attr_accessor :unit_price
|
5369
5420
|
|
5370
|
-
# This field is
|
5371
|
-
#
|
5421
|
+
# This field is required unless a subscription is attached via
|
5422
|
+
# `subscription_config`.
|
5372
5423
|
sig { returns(T.nilable(Float)) }
|
5373
5424
|
attr_reader :quantity
|
5374
5425
|
|
@@ -5386,8 +5437,8 @@ module MetronomeSDK
|
|
5386
5437
|
def self.new(
|
5387
5438
|
credit_type_id:,
|
5388
5439
|
unit_price:,
|
5389
|
-
# This field is
|
5390
|
-
#
|
5440
|
+
# This field is required unless a subscription is attached via
|
5441
|
+
# `subscription_config`.
|
5391
5442
|
quantity: nil
|
5392
5443
|
)
|
5393
5444
|
end
|
@@ -6513,8 +6564,8 @@ module MetronomeSDK
|
|
6513
6564
|
sig { returns(Float) }
|
6514
6565
|
attr_accessor :unit_price
|
6515
6566
|
|
6516
|
-
# This field is
|
6517
|
-
#
|
6567
|
+
# This field is required unless a subscription is attached via
|
6568
|
+
# `subscription_config`.
|
6518
6569
|
sig { returns(T.nilable(Float)) }
|
6519
6570
|
attr_reader :quantity
|
6520
6571
|
|
@@ -6532,8 +6583,8 @@ module MetronomeSDK
|
|
6532
6583
|
def self.new(
|
6533
6584
|
credit_type_id:,
|
6534
6585
|
unit_price:,
|
6535
|
-
# This field is
|
6536
|
-
#
|
6586
|
+
# This field is required unless a subscription is attached via
|
6587
|
+
# `subscription_config`.
|
6537
6588
|
quantity: nil
|
6538
6589
|
)
|
6539
6590
|
end
|
@@ -7555,6 +7606,12 @@ module MetronomeSDK
|
|
7555
7606
|
end
|
7556
7607
|
attr_writer :schedule
|
7557
7608
|
|
7609
|
+
sig { returns(T.nilable(T::Hash[Symbol, String])) }
|
7610
|
+
attr_reader :custom_fields
|
7611
|
+
|
7612
|
+
sig { params(custom_fields: T::Hash[Symbol, String]).void }
|
7613
|
+
attr_writer :custom_fields
|
7614
|
+
|
7558
7615
|
# displayed on invoices
|
7559
7616
|
sig { returns(T.nilable(String)) }
|
7560
7617
|
attr_reader :name
|
@@ -7574,6 +7631,7 @@ module MetronomeSDK
|
|
7574
7631
|
product_id: String,
|
7575
7632
|
schedule:
|
7576
7633
|
MetronomeSDK::V2::ContractEditParams::AddScheduledCharge::Schedule::OrHash,
|
7634
|
+
custom_fields: T::Hash[Symbol, String],
|
7577
7635
|
name: String,
|
7578
7636
|
netsuite_sales_order_id: String
|
7579
7637
|
).returns(T.attached_class)
|
@@ -7582,6 +7640,7 @@ module MetronomeSDK
|
|
7582
7640
|
product_id:,
|
7583
7641
|
# Must provide either schedule_items or recurring_schedule.
|
7584
7642
|
schedule:,
|
7643
|
+
custom_fields: nil,
|
7585
7644
|
# displayed on invoices
|
7586
7645
|
name: nil,
|
7587
7646
|
# This field's availability is dependent on your client's configuration.
|
@@ -7595,6 +7654,7 @@ module MetronomeSDK
|
|
7595
7654
|
product_id: String,
|
7596
7655
|
schedule:
|
7597
7656
|
MetronomeSDK::V2::ContractEditParams::AddScheduledCharge::Schedule,
|
7657
|
+
custom_fields: T::Hash[Symbol, String],
|
7598
7658
|
name: String,
|
7599
7659
|
netsuite_sales_order_id: String
|
7600
7660
|
}
|
@@ -7619,6 +7679,14 @@ module MetronomeSDK
|
|
7619
7679
|
sig { params(credit_type_id: String).void }
|
7620
7680
|
attr_writer :credit_type_id
|
7621
7681
|
|
7682
|
+
# This field is only applicable to commit invoice schedules. If true, this
|
7683
|
+
# schedule will not generate an invoice.
|
7684
|
+
sig { returns(T.nilable(T::Boolean)) }
|
7685
|
+
attr_reader :do_not_invoice
|
7686
|
+
|
7687
|
+
sig { params(do_not_invoice: T::Boolean).void }
|
7688
|
+
attr_writer :do_not_invoice
|
7689
|
+
|
7622
7690
|
# Enter the unit price and quantity for the charge or instead only send the
|
7623
7691
|
# amount. If amount is sent, the unit price is assumed to be the amount and
|
7624
7692
|
# quantity is inferred to be 1.
|
@@ -7665,6 +7733,7 @@ module MetronomeSDK
|
|
7665
7733
|
sig do
|
7666
7734
|
params(
|
7667
7735
|
credit_type_id: String,
|
7736
|
+
do_not_invoice: T::Boolean,
|
7668
7737
|
recurring_schedule:
|
7669
7738
|
MetronomeSDK::V2::ContractEditParams::AddScheduledCharge::Schedule::RecurringSchedule::OrHash,
|
7670
7739
|
schedule_items:
|
@@ -7676,6 +7745,9 @@ module MetronomeSDK
|
|
7676
7745
|
def self.new(
|
7677
7746
|
# Defaults to USD (cents) if not passed.
|
7678
7747
|
credit_type_id: nil,
|
7748
|
+
# This field is only applicable to commit invoice schedules. If true, this
|
7749
|
+
# schedule will not generate an invoice.
|
7750
|
+
do_not_invoice: nil,
|
7679
7751
|
# Enter the unit price and quantity for the charge or instead only send the
|
7680
7752
|
# amount. If amount is sent, the unit price is assumed to be the amount and
|
7681
7753
|
# quantity is inferred to be 1.
|
@@ -7689,6 +7761,7 @@ module MetronomeSDK
|
|
7689
7761
|
override.returns(
|
7690
7762
|
{
|
7691
7763
|
credit_type_id: String,
|
7764
|
+
do_not_invoice: T::Boolean,
|
7692
7765
|
recurring_schedule:
|
7693
7766
|
MetronomeSDK::V2::ContractEditParams::AddScheduledCharge::Schedule::RecurringSchedule,
|
7694
7767
|
schedule_items:
|
@@ -9030,6 +9103,9 @@ module MetronomeSDK
|
|
9030
9103
|
sig { returns(T.nilable(String)) }
|
9031
9104
|
attr_accessor :netsuite_sales_order_id
|
9032
9105
|
|
9106
|
+
sig { returns(T.nilable(Float)) }
|
9107
|
+
attr_accessor :priority
|
9108
|
+
|
9033
9109
|
sig { returns(T.nilable(String)) }
|
9034
9110
|
attr_reader :product_id
|
9035
9111
|
|
@@ -9051,6 +9127,7 @@ module MetronomeSDK
|
|
9051
9127
|
invoice_schedule:
|
9052
9128
|
MetronomeSDK::V2::ContractEditParams::UpdateCommit::InvoiceSchedule::OrHash,
|
9053
9129
|
netsuite_sales_order_id: T.nilable(String),
|
9130
|
+
priority: T.nilable(Float),
|
9054
9131
|
product_id: String,
|
9055
9132
|
rollover_fraction: T.nilable(Float)
|
9056
9133
|
).returns(T.attached_class)
|
@@ -9070,6 +9147,7 @@ module MetronomeSDK
|
|
9070
9147
|
hierarchy_configuration: nil,
|
9071
9148
|
invoice_schedule: nil,
|
9072
9149
|
netsuite_sales_order_id: nil,
|
9150
|
+
priority: nil,
|
9073
9151
|
product_id: nil,
|
9074
9152
|
rollover_fraction: nil
|
9075
9153
|
)
|
@@ -9088,6 +9166,7 @@ module MetronomeSDK
|
|
9088
9166
|
invoice_schedule:
|
9089
9167
|
MetronomeSDK::V2::ContractEditParams::UpdateCommit::InvoiceSchedule,
|
9090
9168
|
netsuite_sales_order_id: T.nilable(String),
|
9169
|
+
priority: T.nilable(Float),
|
9091
9170
|
product_id: String,
|
9092
9171
|
rollover_fraction: T.nilable(Float)
|
9093
9172
|
}
|
@@ -9937,6 +10016,9 @@ module MetronomeSDK
|
|
9937
10016
|
sig { returns(T.nilable(String)) }
|
9938
10017
|
attr_accessor :netsuite_sales_order_id
|
9939
10018
|
|
10019
|
+
sig { returns(T.nilable(Float)) }
|
10020
|
+
attr_accessor :priority
|
10021
|
+
|
9940
10022
|
sig { returns(T.nilable(String)) }
|
9941
10023
|
attr_reader :product_id
|
9942
10024
|
|
@@ -9953,6 +10035,7 @@ module MetronomeSDK
|
|
9953
10035
|
hierarchy_configuration:
|
9954
10036
|
MetronomeSDK::V2::ContractEditParams::UpdateCredit::HierarchyConfiguration::OrHash,
|
9955
10037
|
netsuite_sales_order_id: T.nilable(String),
|
10038
|
+
priority: T.nilable(Float),
|
9956
10039
|
product_id: String
|
9957
10040
|
).returns(T.attached_class)
|
9958
10041
|
end
|
@@ -9970,6 +10053,7 @@ module MetronomeSDK
|
|
9970
10053
|
# Optional configuration for commit hierarchy access control
|
9971
10054
|
hierarchy_configuration: nil,
|
9972
10055
|
netsuite_sales_order_id: nil,
|
10056
|
+
priority: nil,
|
9973
10057
|
product_id: nil
|
9974
10058
|
)
|
9975
10059
|
end
|
@@ -9985,6 +10069,7 @@ module MetronomeSDK
|
|
9985
10069
|
hierarchy_configuration:
|
9986
10070
|
MetronomeSDK::V2::ContractEditParams::UpdateCredit::HierarchyConfiguration,
|
9987
10071
|
netsuite_sales_order_id: T.nilable(String),
|
10072
|
+
priority: T.nilable(Float),
|
9988
10073
|
product_id: String
|
9989
10074
|
}
|
9990
10075
|
)
|
@@ -7300,6 +7300,11 @@ module MetronomeSDK
|
|
7300
7300
|
sig { returns(T.nilable(String)) }
|
7301
7301
|
attr_accessor :netsuite_sales_order_id
|
7302
7302
|
|
7303
|
+
# If multiple commits are applicable, the one with the lower priority will apply
|
7304
|
+
# first.
|
7305
|
+
sig { returns(T.nilable(Float)) }
|
7306
|
+
attr_accessor :priority
|
7307
|
+
|
7303
7308
|
sig { returns(T.nilable(String)) }
|
7304
7309
|
attr_reader :product_id
|
7305
7310
|
|
@@ -7339,6 +7344,7 @@ module MetronomeSDK
|
|
7339
7344
|
MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCommit::InvoiceSchedule::OrHash,
|
7340
7345
|
name: String,
|
7341
7346
|
netsuite_sales_order_id: T.nilable(String),
|
7347
|
+
priority: T.nilable(Float),
|
7342
7348
|
product_id: String,
|
7343
7349
|
rollover_fraction: T.nilable(Float),
|
7344
7350
|
specifiers:
|
@@ -7365,6 +7371,9 @@ module MetronomeSDK
|
|
7365
7371
|
invoice_schedule: nil,
|
7366
7372
|
name: nil,
|
7367
7373
|
netsuite_sales_order_id: nil,
|
7374
|
+
# If multiple commits are applicable, the one with the lower priority will apply
|
7375
|
+
# first.
|
7376
|
+
priority: nil,
|
7368
7377
|
product_id: nil,
|
7369
7378
|
rollover_fraction: nil,
|
7370
7379
|
# List of filters that determine what kind of customer usage draws down a commit
|
@@ -7391,6 +7400,7 @@ module MetronomeSDK
|
|
7391
7400
|
MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCommit::InvoiceSchedule,
|
7392
7401
|
name: String,
|
7393
7402
|
netsuite_sales_order_id: T.nilable(String),
|
7403
|
+
priority: T.nilable(Float),
|
7394
7404
|
product_id: String,
|
7395
7405
|
rollover_fraction: T.nilable(Float),
|
7396
7406
|
specifiers:
|
@@ -8315,6 +8325,11 @@ module MetronomeSDK
|
|
8315
8325
|
sig { returns(T.nilable(String)) }
|
8316
8326
|
attr_accessor :netsuite_sales_order_id
|
8317
8327
|
|
8328
|
+
# If multiple credits are applicable, the one with the lower priority will apply
|
8329
|
+
# first.
|
8330
|
+
sig { returns(T.nilable(Float)) }
|
8331
|
+
attr_accessor :priority
|
8332
|
+
|
8318
8333
|
sig { returns(T.nilable(Float)) }
|
8319
8334
|
attr_accessor :rollover_fraction
|
8320
8335
|
|
@@ -8327,6 +8342,7 @@ module MetronomeSDK
|
|
8327
8342
|
MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCredit::HierarchyConfiguration::OrHash,
|
8328
8343
|
name: String,
|
8329
8344
|
netsuite_sales_order_id: T.nilable(String),
|
8345
|
+
priority: T.nilable(Float),
|
8330
8346
|
rollover_fraction: T.nilable(Float)
|
8331
8347
|
).returns(T.attached_class)
|
8332
8348
|
end
|
@@ -8337,6 +8353,9 @@ module MetronomeSDK
|
|
8337
8353
|
hierarchy_configuration: nil,
|
8338
8354
|
name: nil,
|
8339
8355
|
netsuite_sales_order_id: nil,
|
8356
|
+
# If multiple credits are applicable, the one with the lower priority will apply
|
8357
|
+
# first.
|
8358
|
+
priority: nil,
|
8340
8359
|
rollover_fraction: nil
|
8341
8360
|
)
|
8342
8361
|
end
|
@@ -8351,6 +8370,7 @@ module MetronomeSDK
|
|
8351
8370
|
MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCredit::HierarchyConfiguration,
|
8352
8371
|
name: String,
|
8353
8372
|
netsuite_sales_order_id: T.nilable(String),
|
8373
|
+
priority: T.nilable(Float),
|
8354
8374
|
rollover_fraction: T.nilable(Float)
|
8355
8375
|
}
|
8356
8376
|
)
|
@@ -8973,6 +8993,14 @@ module MetronomeSDK
|
|
8973
8993
|
sig { params(credit_type_id: String).void }
|
8974
8994
|
attr_writer :credit_type_id
|
8975
8995
|
|
8996
|
+
# This field is only applicable to commit invoice schedules. If true, this
|
8997
|
+
# schedule will not generate an invoice.
|
8998
|
+
sig { returns(T.nilable(T::Boolean)) }
|
8999
|
+
attr_reader :do_not_invoice
|
9000
|
+
|
9001
|
+
sig { params(do_not_invoice: T::Boolean).void }
|
9002
|
+
attr_writer :do_not_invoice
|
9003
|
+
|
8976
9004
|
# Enter the unit price and quantity for the charge or instead only send the
|
8977
9005
|
# amount. If amount is sent, the unit price is assumed to be the amount and
|
8978
9006
|
# quantity is inferred to be 1.
|
@@ -9019,6 +9047,7 @@ module MetronomeSDK
|
|
9019
9047
|
sig do
|
9020
9048
|
params(
|
9021
9049
|
credit_type_id: String,
|
9050
|
+
do_not_invoice: T::Boolean,
|
9022
9051
|
recurring_schedule:
|
9023
9052
|
MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateDiscount::Schedule::RecurringSchedule::OrHash,
|
9024
9053
|
schedule_items:
|
@@ -9030,6 +9059,9 @@ module MetronomeSDK
|
|
9030
9059
|
def self.new(
|
9031
9060
|
# Defaults to USD (cents) if not passed.
|
9032
9061
|
credit_type_id: nil,
|
9062
|
+
# This field is only applicable to commit invoice schedules. If true, this
|
9063
|
+
# schedule will not generate an invoice.
|
9064
|
+
do_not_invoice: nil,
|
9033
9065
|
# Enter the unit price and quantity for the charge or instead only send the
|
9034
9066
|
# amount. If amount is sent, the unit price is assumed to be the amount and
|
9035
9067
|
# quantity is inferred to be 1.
|
@@ -9043,6 +9075,7 @@ module MetronomeSDK
|
|
9043
9075
|
override.returns(
|
9044
9076
|
{
|
9045
9077
|
credit_type_id: String,
|
9078
|
+
do_not_invoice: T::Boolean,
|
9046
9079
|
recurring_schedule:
|
9047
9080
|
MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateDiscount::Schedule::RecurringSchedule,
|
9048
9081
|
schedule_items:
|
@@ -14,6 +14,7 @@ module MetronomeSDK
|
|
14
14
|
billable_metric_id: String,
|
15
15
|
composite_product_ids: T::Array[String],
|
16
16
|
composite_tags: T::Array[String],
|
17
|
+
custom_fields: T::Hash[Symbol, String],
|
17
18
|
exclude_free_usage: T::Boolean,
|
18
19
|
is_refundable: T::Boolean,
|
19
20
|
netsuite_internal_item_id: String,
|
@@ -44,6 +45,7 @@ module MetronomeSDK
|
|
44
45
|
composite_product_ids: nil,
|
45
46
|
# Required for COMPOSITE products
|
46
47
|
composite_tags: nil,
|
48
|
+
custom_fields: nil,
|
47
49
|
# Beta feature only available for composite products. If true, products with $0
|
48
50
|
# will not be included when computing composite usage. Defaults to false
|
49
51
|
exclude_free_usage: nil,
|
@@ -231,6 +231,7 @@ module MetronomeSDK
|
|
231
231
|
invoice_contract_id: String,
|
232
232
|
invoice_schedule:
|
233
233
|
MetronomeSDK::V2::ContractEditCommitParams::InvoiceSchedule::OrHash,
|
234
|
+
priority: T.nilable(Float),
|
234
235
|
product_id: String,
|
235
236
|
specifiers:
|
236
237
|
T.nilable(
|
@@ -258,6 +259,9 @@ module MetronomeSDK
|
|
258
259
|
# ID of contract to use for invoicing
|
259
260
|
invoice_contract_id: nil,
|
260
261
|
invoice_schedule: nil,
|
262
|
+
# If multiple commits are applicable, the one with the lower priority will apply
|
263
|
+
# first.
|
264
|
+
priority: nil,
|
261
265
|
product_id: nil,
|
262
266
|
# List of filters that determine what kind of customer usage draws down a commit
|
263
267
|
# or credit. A customer's usage needs to meet the condition of at least one of the
|
@@ -280,6 +284,7 @@ module MetronomeSDK
|
|
280
284
|
MetronomeSDK::V2::ContractEditCreditParams::AccessSchedule::OrHash,
|
281
285
|
applicable_product_ids: T.nilable(T::Array[String]),
|
282
286
|
applicable_product_tags: T.nilable(T::Array[String]),
|
287
|
+
priority: T.nilable(Float),
|
283
288
|
product_id: String,
|
284
289
|
specifiers:
|
285
290
|
T.nilable(
|
@@ -302,6 +307,9 @@ module MetronomeSDK
|
|
302
307
|
# Which tags the credit applies to. If both applicable_product_ids and
|
303
308
|
# applicable_product_tags are not provided, the credit applies to all products.
|
304
309
|
applicable_product_tags: nil,
|
310
|
+
# If multiple commits are applicable, the one with the lower priority will apply
|
311
|
+
# first.
|
312
|
+
priority: nil,
|
305
313
|
product_id: nil,
|
306
314
|
# List of filters that determine what kind of customer usage draws down a commit
|
307
315
|
# or credit. A customer's usage needs to meet the condition of at least one of the
|
@@ -39,6 +39,23 @@ module MetronomeSDK
|
|
39
39
|
| MetronomeSDK::Internal::Type::Converter::input spec
|
40
40
|
) -> (^-> top)
|
41
41
|
|
42
|
+
def self.meta_info: (
|
43
|
+
{
|
44
|
+
const: (nil | bool | Integer | Float | Symbol)?,
|
45
|
+
enum: ^-> MetronomeSDK::Internal::Type::Converter::input?,
|
46
|
+
union: ^-> MetronomeSDK::Internal::Type::Converter::input?
|
47
|
+
}
|
48
|
+
| ^-> MetronomeSDK::Internal::Type::Converter::input
|
49
|
+
| MetronomeSDK::Internal::Type::Converter::input type_info,
|
50
|
+
{
|
51
|
+
const: (nil | bool | Integer | Float | Symbol)?,
|
52
|
+
enum: ^-> MetronomeSDK::Internal::Type::Converter::input?,
|
53
|
+
union: ^-> MetronomeSDK::Internal::Type::Converter::input?
|
54
|
+
}
|
55
|
+
| ^-> MetronomeSDK::Internal::Type::Converter::input
|
56
|
+
| MetronomeSDK::Internal::Type::Converter::input spec
|
57
|
+
) -> ::Hash[Symbol, top]
|
58
|
+
|
42
59
|
def self.new_coerce_state: (
|
43
60
|
?translate_names: bool
|
44
61
|
) -> MetronomeSDK::Internal::Type::Converter::coerce_state
|
@@ -5,9 +5,9 @@ module MetronomeSDK
|
|
5
5
|
include MetronomeSDK::Internal::Type::Converter
|
6
6
|
include MetronomeSDK::Internal::Util::SorbetRuntimeSupport
|
7
7
|
|
8
|
-
private def self.known_variants: -> ::Array[[Symbol?, (^-> MetronomeSDK::Internal::Type::Converter::input)]]
|
8
|
+
private def self.known_variants: -> ::Array[[Symbol?, (^-> MetronomeSDK::Internal::Type::Converter::input), ::Hash[Symbol, top]]]
|
9
9
|
|
10
|
-
def self.derefed_variants: -> ::Array[[Symbol?, top]]
|
10
|
+
def self.derefed_variants: -> ::Array[[Symbol?, top, ::Hash[Symbol, top]]]
|
11
11
|
|
12
12
|
def self.variants: -> ::Array[top]
|
13
13
|
|
@@ -3,6 +3,7 @@ module MetronomeSDK
|
|
3
3
|
type schedule_point_in_time =
|
4
4
|
{
|
5
5
|
credit_type: MetronomeSDK::CreditTypeData,
|
6
|
+
do_not_invoice: bool,
|
6
7
|
schedule_items: ::Array[MetronomeSDK::SchedulePointInTime::ScheduleItem]
|
7
8
|
}
|
8
9
|
|
@@ -13,6 +14,10 @@ module MetronomeSDK
|
|
13
14
|
MetronomeSDK::CreditTypeData
|
14
15
|
) -> MetronomeSDK::CreditTypeData
|
15
16
|
|
17
|
+
attr_reader do_not_invoice: bool?
|
18
|
+
|
19
|
+
def do_not_invoice=: (bool) -> bool
|
20
|
+
|
16
21
|
attr_reader schedule_items: ::Array[MetronomeSDK::SchedulePointInTime::ScheduleItem]?
|
17
22
|
|
18
23
|
def schedule_items=: (
|
@@ -21,11 +26,13 @@ module MetronomeSDK
|
|
21
26
|
|
22
27
|
def initialize: (
|
23
28
|
?credit_type: MetronomeSDK::CreditTypeData,
|
29
|
+
?do_not_invoice: bool,
|
24
30
|
?schedule_items: ::Array[MetronomeSDK::SchedulePointInTime::ScheduleItem]
|
25
31
|
) -> void
|
26
32
|
|
27
33
|
def to_hash: -> {
|
28
34
|
credit_type: MetronomeSDK::CreditTypeData,
|
35
|
+
do_not_invoice: bool,
|
29
36
|
schedule_items: ::Array[MetronomeSDK::SchedulePointInTime::ScheduleItem]
|
30
37
|
}
|
31
38
|
|