metronome-sdk 3.6.0 → 3.8.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 +54 -0
- data/README.md +1 -1
- data/lib/metronome_sdk/internal/transport/base_client.rb +4 -1
- data/lib/metronome_sdk/internal/type/enum.rb +0 -25
- data/lib/metronome_sdk/models/commit.rb +36 -1
- data/lib/metronome_sdk/models/contract.rb +140 -1
- data/lib/metronome_sdk/models/contract_v2.rb +457 -8
- data/lib/metronome_sdk/models/contract_without_amendments.rb +320 -5
- data/lib/metronome_sdk/models/credit.rb +10 -1
- data/lib/metronome_sdk/models/override.rb +7 -1
- data/lib/metronome_sdk/models/prepaid_balance_threshold_configuration.rb +113 -2
- data/lib/metronome_sdk/models/prepaid_balance_threshold_configuration_v2.rb +105 -2
- data/lib/metronome_sdk/models/spend_threshold_configuration.rb +33 -1
- data/lib/metronome_sdk/models/spend_threshold_configuration_v2.rb +33 -1
- data/lib/metronome_sdk/models/subscription.rb +90 -2
- data/lib/metronome_sdk/models/v1/alert_create_params.rb +127 -1
- data/lib/metronome_sdk/models/v1/contract_amend_params.rb +46 -5
- data/lib/metronome_sdk/models/v1/contract_create_params.rb +436 -12
- data/lib/metronome_sdk/models/v1/contract_create_response.rb +1308 -3
- data/lib/metronome_sdk/models/v1/contract_get_subscription_seats_history_params.rb +88 -0
- data/lib/metronome_sdk/models/v1/contract_get_subscription_seats_history_response.rb +62 -0
- data/lib/metronome_sdk/models/v1/contract_list_seat_balances_params.rb +10 -1
- data/lib/metronome_sdk/models/v1/customers/alert_retrieve_params.rb +127 -1
- data/lib/metronome_sdk/models/v1/customers/customer_alert.rb +130 -3
- data/lib/metronome_sdk/models/v1/customers/invoice_list_params.rb +10 -1
- data/lib/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rb +2 -0
- data/lib/metronome_sdk/models/v1/package_create_params.rb +394 -11
- data/lib/metronome_sdk/models/v1/package_list_response.rb +374 -8
- data/lib/metronome_sdk/models/v1/package_retrieve_response.rb +378 -8
- data/lib/metronome_sdk/models/v2/contract_edit_params.rb +817 -13
- data/lib/metronome_sdk/models/v2/contract_edit_response.rb +4310 -3
- data/lib/metronome_sdk/models/v2/contract_get_edit_history_response.rb +600 -10
- data/lib/metronome_sdk/resources/v1/alerts.rb +3 -1
- data/lib/metronome_sdk/resources/v1/contracts/rate_cards/rates.rb +4 -0
- data/lib/metronome_sdk/resources/v1/contracts.rb +71 -2
- data/lib/metronome_sdk/resources/v1/customers/alerts.rb +4 -2
- data/lib/metronome_sdk/resources/v1/customers/invoices.rb +3 -1
- data/lib/metronome_sdk/resources/v1/dashboards.rb +7 -2
- data/lib/metronome_sdk/resources/v1/packages.rb +6 -5
- data/lib/metronome_sdk/resources/v1.rb +0 -4
- data/lib/metronome_sdk/resources/v2/contracts.rb +5 -1
- data/lib/metronome_sdk/version.rb +1 -1
- data/lib/metronome_sdk.rb +2 -8
- data/rbi/metronome_sdk/models/commit.rbi +61 -0
- data/rbi/metronome_sdk/models/contract.rbi +354 -0
- data/rbi/metronome_sdk/models/contract_v2.rbi +1132 -11
- data/rbi/metronome_sdk/models/contract_without_amendments.rbi +831 -0
- data/rbi/metronome_sdk/models/credit.rbi +13 -0
- data/rbi/metronome_sdk/models/override.rbi +9 -0
- data/rbi/metronome_sdk/models/prepaid_balance_threshold_configuration.rbi +299 -6
- data/rbi/metronome_sdk/models/prepaid_balance_threshold_configuration_v2.rbi +287 -6
- data/rbi/metronome_sdk/models/spend_threshold_configuration.rbi +78 -3
- data/rbi/metronome_sdk/models/spend_threshold_configuration_v2.rbi +78 -3
- data/rbi/metronome_sdk/models/subscription.rbi +212 -3
- data/rbi/metronome_sdk/models/v1/alert_create_params.rbi +373 -0
- data/rbi/metronome_sdk/models/v1/contract_amend_params.rbi +81 -6
- data/rbi/metronome_sdk/models/v1/contract_create_params.rbi +1095 -17
- data/rbi/metronome_sdk/models/v1/contract_create_response.rbi +2911 -4
- data/rbi/metronome_sdk/models/v1/contract_get_subscription_seats_history_params.rbi +112 -0
- data/rbi/metronome_sdk/models/v1/contract_get_subscription_seats_history_response.rbi +119 -0
- data/rbi/metronome_sdk/models/v1/contract_list_seat_balances_params.rbi +13 -0
- data/rbi/metronome_sdk/models/v1/customers/alert_retrieve_params.rbi +360 -0
- data/rbi/metronome_sdk/models/v1/customers/customer_alert.rbi +379 -2
- data/rbi/metronome_sdk/models/v1/customers/invoice_list_params.rbi +13 -0
- data/rbi/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rbi +10 -0
- data/rbi/metronome_sdk/models/v1/package_create_params.rbi +1049 -42
- data/rbi/metronome_sdk/models/v1/package_list_response.rbi +1051 -54
- data/rbi/metronome_sdk/models/v1/package_retrieve_response.rbi +1051 -54
- data/rbi/metronome_sdk/models/v2/contract_edit_params.rbi +2130 -114
- data/rbi/metronome_sdk/models/v2/contract_edit_response.rbi +9749 -4
- data/rbi/metronome_sdk/models/v2/contract_get_edit_history_response.rbi +1567 -82
- data/rbi/metronome_sdk/resources/v1/alerts.rbi +8 -0
- data/rbi/metronome_sdk/resources/v1/contracts/rate_cards/rates.rbi +4 -0
- data/rbi/metronome_sdk/resources/v1/contracts.rbi +77 -0
- data/rbi/metronome_sdk/resources/v1/customers/alerts.rbi +8 -1
- data/rbi/metronome_sdk/resources/v1/customers/invoices.rbi +4 -0
- data/rbi/metronome_sdk/resources/v1/dashboards.rbi +7 -2
- data/rbi/metronome_sdk/resources/v1/packages.rbi +8 -4
- data/rbi/metronome_sdk/resources/v1.rbi +0 -3
- data/rbi/metronome_sdk/resources/v2/contracts.rbi +10 -0
- data/sig/metronome_sdk/models/commit.rbs +26 -0
- data/sig/metronome_sdk/models/contract.rbs +151 -0
- data/sig/metronome_sdk/models/contract_v2.rbs +448 -5
- data/sig/metronome_sdk/models/contract_without_amendments.rbs +320 -2
- data/sig/metronome_sdk/models/credit.rbs +7 -0
- data/sig/metronome_sdk/models/override.rbs +7 -0
- data/sig/metronome_sdk/models/prepaid_balance_threshold_configuration.rbs +116 -6
- data/sig/metronome_sdk/models/prepaid_balance_threshold_configuration_v2.rbs +116 -6
- data/sig/metronome_sdk/models/spend_threshold_configuration.rbs +31 -3
- data/sig/metronome_sdk/models/spend_threshold_configuration_v2.rbs +31 -3
- data/sig/metronome_sdk/models/subscription.rbs +88 -3
- data/sig/metronome_sdk/models/v1/alert_create_params.rbs +144 -0
- data/sig/metronome_sdk/models/v1/contract_amend_params.rbs +26 -0
- data/sig/metronome_sdk/models/v1/contract_create_params.rbs +412 -5
- data/sig/metronome_sdk/models/v1/contract_create_response.rbs +1210 -4
- data/sig/metronome_sdk/models/v1/contract_get_subscription_seats_history_params.rbs +63 -0
- data/sig/metronome_sdk/models/v1/contract_get_subscription_seats_history_response.rbs +59 -0
- data/sig/metronome_sdk/models/v1/contract_list_seat_balances_params.rbs +7 -0
- data/sig/metronome_sdk/models/v1/customers/alert_retrieve_params.rbs +141 -0
- data/sig/metronome_sdk/models/v1/customers/customer_alert.rbs +150 -0
- data/sig/metronome_sdk/models/v1/customers/invoice_list_params.rbs +8 -1
- data/sig/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rbs +4 -0
- data/sig/metronome_sdk/models/v1/package_create_params.rbs +386 -5
- data/sig/metronome_sdk/models/v1/package_list_response.rbs +380 -5
- data/sig/metronome_sdk/models/v1/package_retrieve_response.rbs +378 -5
- data/sig/metronome_sdk/models/v2/contract_edit_params.rbs +751 -14
- data/sig/metronome_sdk/models/v2/contract_edit_response.rbs +4215 -4
- data/sig/metronome_sdk/models/v2/contract_get_edit_history_response.rbs +569 -14
- data/sig/metronome_sdk/resources/v1/alerts.rbs +1 -0
- data/sig/metronome_sdk/resources/v1/contracts.rbs +14 -0
- data/sig/metronome_sdk/resources/v1/customers/alerts.rbs +1 -0
- data/sig/metronome_sdk/resources/v1/customers/invoices.rbs +1 -0
- data/sig/metronome_sdk/resources/v1/packages.rbs +1 -0
- data/sig/metronome_sdk/resources/v1.rbs +0 -2
- data/sig/metronome_sdk/resources/v2/contracts.rbs +2 -0
- metadata +8 -26
- data/lib/metronome_sdk/models/v1/payment.rb +0 -196
- data/lib/metronome_sdk/models/v1/payment_attempt_params.rb +0 -28
- data/lib/metronome_sdk/models/v1/payment_attempt_response.rb +0 -18
- data/lib/metronome_sdk/models/v1/payment_cancel_params.rb +0 -28
- data/lib/metronome_sdk/models/v1/payment_cancel_response.rb +0 -18
- data/lib/metronome_sdk/models/v1/payment_list_params.rb +0 -53
- data/lib/metronome_sdk/models/v1/payment_status.rb +0 -19
- data/lib/metronome_sdk/resources/v1/payments.rb +0 -102
- data/rbi/metronome_sdk/models/v1/payment.rbi +0 -403
- data/rbi/metronome_sdk/models/v1/payment_attempt_params.rbi +0 -48
- data/rbi/metronome_sdk/models/v1/payment_attempt_response.rbi +0 -35
- data/rbi/metronome_sdk/models/v1/payment_cancel_params.rbi +0 -48
- data/rbi/metronome_sdk/models/v1/payment_cancel_response.rbi +0 -35
- data/rbi/metronome_sdk/models/v1/payment_list_params.rbi +0 -91
- data/rbi/metronome_sdk/models/v1/payment_status.rbi +0 -33
- data/rbi/metronome_sdk/resources/v1/payments.rbi +0 -72
- data/sig/metronome_sdk/models/v1/payment.rbs +0 -243
- data/sig/metronome_sdk/models/v1/payment_attempt_params.rbs +0 -30
- data/sig/metronome_sdk/models/v1/payment_attempt_response.rbs +0 -15
- data/sig/metronome_sdk/models/v1/payment_cancel_params.rbs +0 -30
- data/sig/metronome_sdk/models/v1/payment_cancel_response.rbs +0 -15
- data/sig/metronome_sdk/models/v1/payment_list_params.rbs +0 -56
- data/sig/metronome_sdk/models/v1/payment_status.rbs +0 -19
- data/sig/metronome_sdk/resources/v1/payments.rbs +0 -30
|
@@ -190,6 +190,14 @@ module MetronomeSDK
|
|
|
190
190
|
# @return [MetronomeSDK::Models::SpendThresholdConfiguration, nil]
|
|
191
191
|
optional :spend_threshold_configuration, -> { MetronomeSDK::SpendThresholdConfiguration }
|
|
192
192
|
|
|
193
|
+
# @!attribute spend_trackers
|
|
194
|
+
# Spend trackers to attach to this contract. Aliases must be unique within a
|
|
195
|
+
# contract.
|
|
196
|
+
#
|
|
197
|
+
# @return [Array<MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker>, nil]
|
|
198
|
+
optional :spend_trackers,
|
|
199
|
+
-> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::V1::ContractCreateParams::SpendTracker] }
|
|
200
|
+
|
|
193
201
|
# @!attribute subscriptions
|
|
194
202
|
# Optional list of
|
|
195
203
|
# [subscriptions](https://docs.metronome.com/manage-product-access/create-subscription/)
|
|
@@ -228,7 +236,7 @@ module MetronomeSDK
|
|
|
228
236
|
# @return [MetronomeSDK::Models::V1::ContractCreateParams::UsageStatementSchedule, nil]
|
|
229
237
|
optional :usage_statement_schedule, -> { MetronomeSDK::V1::ContractCreateParams::UsageStatementSchedule }
|
|
230
238
|
|
|
231
|
-
# @!method initialize(customer_id:, starting_at:, billing_provider_configuration: nil, commits: nil, credits: nil, custom_fields: nil, discounts: nil, ending_before: nil, hierarchy_configuration: nil, multiplier_override_prioritization: nil, name: nil, net_payment_terms_days: nil, netsuite_sales_order_id: nil, overrides: nil, package_alias: nil, package_id: nil, prepaid_balance_threshold_configuration: nil, professional_services: nil, rate_card_alias: nil, rate_card_id: nil, recurring_commits: nil, recurring_credits: nil, reseller_royalties: nil, revenue_system_configuration: nil, salesforce_opportunity_id: nil, scheduled_charges: nil, scheduled_charges_on_usage_invoices: nil, spend_threshold_configuration: nil, subscriptions: nil, total_contract_value: nil, transition: nil, uniqueness_key: nil, usage_filter: nil, usage_statement_schedule: nil, request_options: {})
|
|
239
|
+
# @!method initialize(customer_id:, starting_at:, billing_provider_configuration: nil, commits: nil, credits: nil, custom_fields: nil, discounts: nil, ending_before: nil, hierarchy_configuration: nil, multiplier_override_prioritization: nil, name: nil, net_payment_terms_days: nil, netsuite_sales_order_id: nil, overrides: nil, package_alias: nil, package_id: nil, prepaid_balance_threshold_configuration: nil, professional_services: nil, rate_card_alias: nil, rate_card_id: nil, recurring_commits: nil, recurring_credits: nil, reseller_royalties: nil, revenue_system_configuration: nil, salesforce_opportunity_id: nil, scheduled_charges: nil, scheduled_charges_on_usage_invoices: nil, spend_threshold_configuration: nil, spend_trackers: nil, subscriptions: nil, total_contract_value: nil, transition: nil, uniqueness_key: nil, usage_filter: nil, usage_statement_schedule: nil, request_options: {})
|
|
232
240
|
# Some parameter documentations has been truncated, see
|
|
233
241
|
# {MetronomeSDK::Models::V1::ContractCreateParams} for more details.
|
|
234
242
|
#
|
|
@@ -288,6 +296,8 @@ module MetronomeSDK
|
|
|
288
296
|
#
|
|
289
297
|
# @param spend_threshold_configuration [MetronomeSDK::Models::SpendThresholdConfiguration]
|
|
290
298
|
#
|
|
299
|
+
# @param spend_trackers [Array<MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker>] Spend trackers to attach to this contract. Aliases must be unique within a contr
|
|
300
|
+
#
|
|
291
301
|
# @param subscriptions [Array<MetronomeSDK::Models::V1::ContractCreateParams::Subscription>] Optional list of [subscriptions](https://docs.metronome.com/manage-product-acces
|
|
292
302
|
#
|
|
293
303
|
# @param total_contract_value [Float] This field's availability is dependent on your client's configuration.
|
|
@@ -478,6 +488,13 @@ module MetronomeSDK
|
|
|
478
488
|
# @return [Array<MetronomeSDK::Models::CommitSpecifierInput>, nil]
|
|
479
489
|
optional :specifiers, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::CommitSpecifierInput] }
|
|
480
490
|
|
|
491
|
+
# @!attribute spend_tracker_attributes
|
|
492
|
+
# Optional attributes for spend tracker integration. Immutable after creation.
|
|
493
|
+
#
|
|
494
|
+
# @return [MetronomeSDK::Models::V1::ContractCreateParams::Commit::SpendTrackerAttributes, nil]
|
|
495
|
+
optional :spend_tracker_attributes,
|
|
496
|
+
-> { MetronomeSDK::V1::ContractCreateParams::Commit::SpendTrackerAttributes }
|
|
497
|
+
|
|
481
498
|
# @!attribute temporary_id
|
|
482
499
|
# A temporary ID for the commit that can be used to reference the commit for
|
|
483
500
|
# commit specific overrides.
|
|
@@ -485,7 +502,7 @@ module MetronomeSDK
|
|
|
485
502
|
# @return [String, nil]
|
|
486
503
|
optional :temporary_id, String
|
|
487
504
|
|
|
488
|
-
# @!method initialize(product_id:, type:, access_schedule: nil, amount: nil, applicable_product_ids: nil, applicable_product_tags: nil, custom_fields: nil, description: nil, hierarchy_configuration: nil, invoice_schedule: nil, name: nil, netsuite_sales_order_id: nil, priority: nil, rate_type: nil, rollover_fraction: nil, specifiers: nil, temporary_id: nil)
|
|
505
|
+
# @!method initialize(product_id:, type:, access_schedule: nil, amount: nil, applicable_product_ids: nil, applicable_product_tags: nil, custom_fields: nil, description: nil, hierarchy_configuration: nil, invoice_schedule: nil, name: nil, netsuite_sales_order_id: nil, priority: nil, rate_type: nil, rollover_fraction: nil, specifiers: nil, spend_tracker_attributes: nil, temporary_id: nil)
|
|
489
506
|
# Some parameter documentations has been truncated, see
|
|
490
507
|
# {MetronomeSDK::Models::V1::ContractCreateParams::Commit} for more details.
|
|
491
508
|
#
|
|
@@ -521,6 +538,8 @@ module MetronomeSDK
|
|
|
521
538
|
#
|
|
522
539
|
# @param specifiers [Array<MetronomeSDK::Models::CommitSpecifierInput>] List of filters that determine what kind of customer usage draws down a commit o
|
|
523
540
|
#
|
|
541
|
+
# @param spend_tracker_attributes [MetronomeSDK::Models::V1::ContractCreateParams::Commit::SpendTrackerAttributes] Optional attributes for spend tracker integration. Immutable after creation.
|
|
542
|
+
#
|
|
524
543
|
# @param temporary_id [String] A temporary ID for the commit that can be used to reference the commit for commi
|
|
525
544
|
|
|
526
545
|
# @see MetronomeSDK::Models::V1::ContractCreateParams::Commit#type
|
|
@@ -788,6 +807,25 @@ module MetronomeSDK
|
|
|
788
807
|
# @!method self.values
|
|
789
808
|
# @return [Array<Symbol>]
|
|
790
809
|
end
|
|
810
|
+
|
|
811
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::Commit#spend_tracker_attributes
|
|
812
|
+
class SpendTrackerAttributes < MetronomeSDK::Internal::Type::BaseModel
|
|
813
|
+
# @!attribute counts_as_discounted
|
|
814
|
+
# If true, this commit will be included in spend trackers with discounted set to
|
|
815
|
+
# DISCOUNTED_ONLY
|
|
816
|
+
#
|
|
817
|
+
# @return [Boolean]
|
|
818
|
+
required :counts_as_discounted, MetronomeSDK::Internal::Type::Boolean
|
|
819
|
+
|
|
820
|
+
# @!method initialize(counts_as_discounted:)
|
|
821
|
+
# Some parameter documentations has been truncated, see
|
|
822
|
+
# {MetronomeSDK::Models::V1::ContractCreateParams::Commit::SpendTrackerAttributes}
|
|
823
|
+
# for more details.
|
|
824
|
+
#
|
|
825
|
+
# Optional attributes for spend tracker integration. Immutable after creation.
|
|
826
|
+
#
|
|
827
|
+
# @param counts_as_discounted [Boolean] If true, this commit will be included in spend trackers with discounted set to D
|
|
828
|
+
end
|
|
791
829
|
end
|
|
792
830
|
|
|
793
831
|
class Credit < MetronomeSDK::Internal::Type::BaseModel
|
|
@@ -1383,9 +1421,10 @@ module MetronomeSDK
|
|
|
1383
1421
|
|
|
1384
1422
|
# @!attribute is_commit_specific
|
|
1385
1423
|
# Indicates whether the override should only apply to commits. Defaults to
|
|
1386
|
-
# `false`. If `true
|
|
1387
|
-
# passing `commit_ids
|
|
1388
|
-
#
|
|
1424
|
+
# `false`. If `true` you can specify relevant commits in `override_specifiers` by
|
|
1425
|
+
# passing `commit_ids`, `recurring_commit_ids`, or `any_commit_or_credit_ids`. If
|
|
1426
|
+
# you do not specify any of these fields, the override will apply when consuming
|
|
1427
|
+
# any prepaid commit, postpaid commit, or credit
|
|
1389
1428
|
#
|
|
1390
1429
|
# @return [Boolean, nil]
|
|
1391
1430
|
optional :is_commit_specific, MetronomeSDK::Internal::Type::Boolean
|
|
@@ -1478,6 +1517,16 @@ module MetronomeSDK
|
|
|
1478
1517
|
# @param type [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::Override::Type] Overwrites are prioritized over multipliers and tiered overrides.
|
|
1479
1518
|
|
|
1480
1519
|
class OverrideSpecifier < MetronomeSDK::Internal::Type::BaseModel
|
|
1520
|
+
# @!attribute any_commit_or_credit_ids
|
|
1521
|
+
# Can only be used for commit specific overrides. Must be used in conjunction with
|
|
1522
|
+
# one of `product_id`, `product_tags`, `pricing_group_values`, or
|
|
1523
|
+
# `presentation_group_values`. Must be used instead of both `commit_ids` and
|
|
1524
|
+
# `recurring_commit_ids` If provided, the override will apply to any specified
|
|
1525
|
+
# commit, credit, recurring commit or recurring credit IDs.
|
|
1526
|
+
#
|
|
1527
|
+
# @return [Array<String>, nil]
|
|
1528
|
+
optional :any_commit_or_credit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]
|
|
1529
|
+
|
|
1481
1530
|
# @!attribute billing_frequency
|
|
1482
1531
|
#
|
|
1483
1532
|
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::Override::OverrideSpecifier::BillingFrequency, nil]
|
|
@@ -1529,11 +1578,13 @@ module MetronomeSDK
|
|
|
1529
1578
|
# @return [Array<String>, nil]
|
|
1530
1579
|
optional :recurring_commit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]
|
|
1531
1580
|
|
|
1532
|
-
# @!method initialize(billing_frequency: nil, commit_ids: nil, presentation_group_values: nil, pricing_group_values: nil, product_id: nil, product_tags: nil, recurring_commit_ids: nil)
|
|
1581
|
+
# @!method initialize(any_commit_or_credit_ids: nil, billing_frequency: nil, commit_ids: nil, presentation_group_values: nil, pricing_group_values: nil, product_id: nil, product_tags: nil, recurring_commit_ids: nil)
|
|
1533
1582
|
# Some parameter documentations has been truncated, see
|
|
1534
1583
|
# {MetronomeSDK::Models::V1::ContractCreateParams::Override::OverrideSpecifier}
|
|
1535
1584
|
# for more details.
|
|
1536
1585
|
#
|
|
1586
|
+
# @param any_commit_or_credit_ids [Array<String>] Can only be used for commit specific overrides. Must be used in conjunction with
|
|
1587
|
+
#
|
|
1537
1588
|
# @param billing_frequency [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::Override::OverrideSpecifier::BillingFrequency]
|
|
1538
1589
|
#
|
|
1539
1590
|
# @param commit_ids [Array<String>] Can only be used for commit specific overrides. Must be used in conjunction with
|
|
@@ -1841,6 +1892,13 @@ module MetronomeSDK
|
|
|
1841
1892
|
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::Proration, nil]
|
|
1842
1893
|
optional :proration, enum: -> { MetronomeSDK::V1::ContractCreateParams::RecurringCommit::Proration }
|
|
1843
1894
|
|
|
1895
|
+
# @!attribute proration_rounding
|
|
1896
|
+
# Optional rounding configuration for prorated recurring commit amounts.
|
|
1897
|
+
#
|
|
1898
|
+
# @return [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding, nil]
|
|
1899
|
+
optional :proration_rounding,
|
|
1900
|
+
-> { MetronomeSDK::V1::ContractCreateParams::RecurringCommit::ProrationRounding }
|
|
1901
|
+
|
|
1844
1902
|
# @!attribute rate_type
|
|
1845
1903
|
# Whether the created commits will use the commit rate or list rate
|
|
1846
1904
|
#
|
|
@@ -1889,7 +1947,7 @@ module MetronomeSDK
|
|
|
1889
1947
|
# @return [String, nil]
|
|
1890
1948
|
optional :temporary_id, String
|
|
1891
1949
|
|
|
1892
|
-
# @!method initialize(access_amount:, commit_duration:, priority:, product_id:, starting_at:, applicable_product_ids: nil, applicable_product_tags: nil, description: nil, ending_before: nil, hierarchy_configuration: nil, invoice_amount: nil, name: nil, netsuite_sales_order_id: nil, proration: nil, rate_type: nil, recurrence_frequency: nil, rollover_fraction: nil, specifiers: nil, subscription_config: nil, temporary_id: nil)
|
|
1950
|
+
# @!method initialize(access_amount:, commit_duration:, priority:, product_id:, starting_at:, applicable_product_ids: nil, applicable_product_tags: nil, description: nil, ending_before: nil, hierarchy_configuration: nil, invoice_amount: nil, name: nil, netsuite_sales_order_id: nil, proration: nil, proration_rounding: nil, rate_type: nil, recurrence_frequency: nil, rollover_fraction: nil, specifiers: nil, subscription_config: nil, temporary_id: nil)
|
|
1893
1951
|
# Some parameter documentations has been truncated, see
|
|
1894
1952
|
# {MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit} for more
|
|
1895
1953
|
# details.
|
|
@@ -1922,9 +1980,11 @@ module MetronomeSDK
|
|
|
1922
1980
|
#
|
|
1923
1981
|
# @param proration [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::Proration] Determines whether the first and last commit will be prorated. If not provided,
|
|
1924
1982
|
#
|
|
1983
|
+
# @param proration_rounding [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding] Optional rounding configuration for prorated recurring commit amounts.
|
|
1984
|
+
#
|
|
1925
1985
|
# @param rate_type [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::RateType] Whether the created commits will use the commit rate or list rate
|
|
1926
1986
|
#
|
|
1927
|
-
# @param recurrence_frequency [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::RecurrenceFrequency] The frequency at which the recurring commits will be created. If not provided:
|
|
1987
|
+
# @param recurrence_frequency [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::RecurrenceFrequency] The frequency at which the recurring commits will be created. If not provided: -
|
|
1928
1988
|
#
|
|
1929
1989
|
# @param rollover_fraction [Float] Will be passed down to the individual commits. This controls how much of an indi
|
|
1930
1990
|
#
|
|
@@ -2039,6 +2099,105 @@ module MetronomeSDK
|
|
|
2039
2099
|
# @return [Array<Symbol>]
|
|
2040
2100
|
end
|
|
2041
2101
|
|
|
2102
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit#proration_rounding
|
|
2103
|
+
class ProrationRounding < MetronomeSDK::Internal::Type::BaseModel
|
|
2104
|
+
# @!attribute access
|
|
2105
|
+
#
|
|
2106
|
+
# @return [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Access, nil]
|
|
2107
|
+
optional :access,
|
|
2108
|
+
-> { MetronomeSDK::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Access }
|
|
2109
|
+
|
|
2110
|
+
# @!attribute invoice
|
|
2111
|
+
#
|
|
2112
|
+
# @return [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Invoice, nil]
|
|
2113
|
+
optional :invoice,
|
|
2114
|
+
-> { MetronomeSDK::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Invoice }
|
|
2115
|
+
|
|
2116
|
+
# @!method initialize(access: nil, invoice: nil)
|
|
2117
|
+
# Optional rounding configuration for prorated recurring commit amounts.
|
|
2118
|
+
#
|
|
2119
|
+
# @param access [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Access]
|
|
2120
|
+
# @param invoice [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Invoice]
|
|
2121
|
+
|
|
2122
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding#access
|
|
2123
|
+
class Access < MetronomeSDK::Internal::Type::BaseModel
|
|
2124
|
+
# @!attribute decimal_places
|
|
2125
|
+
# Number of decimal places to round to. Applied directly to the stored monetary
|
|
2126
|
+
# representation. Negative values round to powers of 10 (e.g., -2 rounds to
|
|
2127
|
+
# nearest 100 in the stored unit. For USD, this means rounding to the nearest
|
|
2128
|
+
# dollar).
|
|
2129
|
+
#
|
|
2130
|
+
# @return [Float]
|
|
2131
|
+
required :decimal_places, Float
|
|
2132
|
+
|
|
2133
|
+
# @!attribute rounding_method
|
|
2134
|
+
#
|
|
2135
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Access::RoundingMethod]
|
|
2136
|
+
required :rounding_method,
|
|
2137
|
+
enum: -> { MetronomeSDK::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Access::RoundingMethod }
|
|
2138
|
+
|
|
2139
|
+
# @!method initialize(decimal_places:, rounding_method:)
|
|
2140
|
+
# Some parameter documentations has been truncated, see
|
|
2141
|
+
# {MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Access}
|
|
2142
|
+
# for more details.
|
|
2143
|
+
#
|
|
2144
|
+
# @param decimal_places [Float] Number of decimal places to round to. Applied directly to the stored monetary re
|
|
2145
|
+
#
|
|
2146
|
+
# @param rounding_method [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Access::RoundingMethod]
|
|
2147
|
+
|
|
2148
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Access#rounding_method
|
|
2149
|
+
module RoundingMethod
|
|
2150
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
2151
|
+
|
|
2152
|
+
HALF_UP = :HALF_UP
|
|
2153
|
+
FLOOR = :FLOOR
|
|
2154
|
+
CEILING = :CEILING
|
|
2155
|
+
|
|
2156
|
+
# @!method self.values
|
|
2157
|
+
# @return [Array<Symbol>]
|
|
2158
|
+
end
|
|
2159
|
+
end
|
|
2160
|
+
|
|
2161
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding#invoice
|
|
2162
|
+
class Invoice < MetronomeSDK::Internal::Type::BaseModel
|
|
2163
|
+
# @!attribute decimal_places
|
|
2164
|
+
# Number of decimal places to round to. Applied directly to the stored monetary
|
|
2165
|
+
# representation. Negative values round to powers of 10 (e.g., -2 rounds to
|
|
2166
|
+
# nearest 100 in the stored unit. For USD, this means rounding to the nearest
|
|
2167
|
+
# dollar).
|
|
2168
|
+
#
|
|
2169
|
+
# @return [Float]
|
|
2170
|
+
required :decimal_places, Float
|
|
2171
|
+
|
|
2172
|
+
# @!attribute rounding_method
|
|
2173
|
+
#
|
|
2174
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Invoice::RoundingMethod]
|
|
2175
|
+
required :rounding_method,
|
|
2176
|
+
enum: -> { MetronomeSDK::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Invoice::RoundingMethod }
|
|
2177
|
+
|
|
2178
|
+
# @!method initialize(decimal_places:, rounding_method:)
|
|
2179
|
+
# Some parameter documentations has been truncated, see
|
|
2180
|
+
# {MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Invoice}
|
|
2181
|
+
# for more details.
|
|
2182
|
+
#
|
|
2183
|
+
# @param decimal_places [Float] Number of decimal places to round to. Applied directly to the stored monetary re
|
|
2184
|
+
#
|
|
2185
|
+
# @param rounding_method [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Invoice::RoundingMethod]
|
|
2186
|
+
|
|
2187
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit::ProrationRounding::Invoice#rounding_method
|
|
2188
|
+
module RoundingMethod
|
|
2189
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
2190
|
+
|
|
2191
|
+
HALF_UP = :HALF_UP
|
|
2192
|
+
FLOOR = :FLOOR
|
|
2193
|
+
CEILING = :CEILING
|
|
2194
|
+
|
|
2195
|
+
# @!method self.values
|
|
2196
|
+
# @return [Array<Symbol>]
|
|
2197
|
+
end
|
|
2198
|
+
end
|
|
2199
|
+
end
|
|
2200
|
+
|
|
2042
2201
|
# Whether the created commits will use the commit rate or list rate
|
|
2043
2202
|
#
|
|
2044
2203
|
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCommit#rate_type
|
|
@@ -2066,6 +2225,7 @@ module MetronomeSDK
|
|
|
2066
2225
|
QUARTERLY = :QUARTERLY
|
|
2067
2226
|
ANNUAL = :ANNUAL
|
|
2068
2227
|
WEEKLY = :WEEKLY
|
|
2228
|
+
DAILY = :DAILY
|
|
2069
2229
|
|
|
2070
2230
|
# @!method self.values
|
|
2071
2231
|
# @return [Array<Symbol>]
|
|
@@ -2215,6 +2375,13 @@ module MetronomeSDK
|
|
|
2215
2375
|
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::Proration, nil]
|
|
2216
2376
|
optional :proration, enum: -> { MetronomeSDK::V1::ContractCreateParams::RecurringCredit::Proration }
|
|
2217
2377
|
|
|
2378
|
+
# @!attribute proration_rounding
|
|
2379
|
+
# Optional rounding configuration for prorated recurring credit amounts.
|
|
2380
|
+
#
|
|
2381
|
+
# @return [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding, nil]
|
|
2382
|
+
optional :proration_rounding,
|
|
2383
|
+
-> { MetronomeSDK::V1::ContractCreateParams::RecurringCredit::ProrationRounding }
|
|
2384
|
+
|
|
2218
2385
|
# @!attribute rate_type
|
|
2219
2386
|
# Whether the created commits will use the commit rate or list rate
|
|
2220
2387
|
#
|
|
@@ -2263,7 +2430,7 @@ module MetronomeSDK
|
|
|
2263
2430
|
# @return [String, nil]
|
|
2264
2431
|
optional :temporary_id, String
|
|
2265
2432
|
|
|
2266
|
-
# @!method initialize(access_amount:, commit_duration:, priority:, product_id:, starting_at:, applicable_product_ids: nil, applicable_product_tags: nil, description: nil, ending_before: nil, hierarchy_configuration: nil, name: nil, netsuite_sales_order_id: nil, proration: nil, rate_type: nil, recurrence_frequency: nil, rollover_fraction: nil, specifiers: nil, subscription_config: nil, temporary_id: nil)
|
|
2433
|
+
# @!method initialize(access_amount:, commit_duration:, priority:, product_id:, starting_at:, applicable_product_ids: nil, applicable_product_tags: nil, description: nil, ending_before: nil, hierarchy_configuration: nil, name: nil, netsuite_sales_order_id: nil, proration: nil, proration_rounding: nil, rate_type: nil, recurrence_frequency: nil, rollover_fraction: nil, specifiers: nil, subscription_config: nil, temporary_id: nil)
|
|
2267
2434
|
# Some parameter documentations has been truncated, see
|
|
2268
2435
|
# {MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit} for more
|
|
2269
2436
|
# details.
|
|
@@ -2294,9 +2461,11 @@ module MetronomeSDK
|
|
|
2294
2461
|
#
|
|
2295
2462
|
# @param proration [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::Proration] Determines whether the first and last commit will be prorated. If not provided,
|
|
2296
2463
|
#
|
|
2464
|
+
# @param proration_rounding [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding] Optional rounding configuration for prorated recurring credit amounts.
|
|
2465
|
+
#
|
|
2297
2466
|
# @param rate_type [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::RateType] Whether the created commits will use the commit rate or list rate
|
|
2298
2467
|
#
|
|
2299
|
-
# @param recurrence_frequency [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::RecurrenceFrequency] The frequency at which the recurring commits will be created. If not provided:
|
|
2468
|
+
# @param recurrence_frequency [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::RecurrenceFrequency] The frequency at which the recurring commits will be created. If not provided: -
|
|
2300
2469
|
#
|
|
2301
2470
|
# @param rollover_fraction [Float] Will be passed down to the individual commits. This controls how much of an indi
|
|
2302
2471
|
#
|
|
@@ -2386,6 +2555,59 @@ module MetronomeSDK
|
|
|
2386
2555
|
# @return [Array<Symbol>]
|
|
2387
2556
|
end
|
|
2388
2557
|
|
|
2558
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit#proration_rounding
|
|
2559
|
+
class ProrationRounding < MetronomeSDK::Internal::Type::BaseModel
|
|
2560
|
+
# @!attribute access
|
|
2561
|
+
#
|
|
2562
|
+
# @return [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding::Access, nil]
|
|
2563
|
+
optional :access,
|
|
2564
|
+
-> { MetronomeSDK::V1::ContractCreateParams::RecurringCredit::ProrationRounding::Access }
|
|
2565
|
+
|
|
2566
|
+
# @!method initialize(access: nil)
|
|
2567
|
+
# Optional rounding configuration for prorated recurring credit amounts.
|
|
2568
|
+
#
|
|
2569
|
+
# @param access [MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding::Access]
|
|
2570
|
+
|
|
2571
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding#access
|
|
2572
|
+
class Access < MetronomeSDK::Internal::Type::BaseModel
|
|
2573
|
+
# @!attribute decimal_places
|
|
2574
|
+
# Number of decimal places to round to. Applied directly to the stored monetary
|
|
2575
|
+
# representation. Negative values round to powers of 10 (e.g., -2 rounds to
|
|
2576
|
+
# nearest 100 in the stored unit. For USD, this means rounding to the nearest
|
|
2577
|
+
# dollar).
|
|
2578
|
+
#
|
|
2579
|
+
# @return [Float]
|
|
2580
|
+
required :decimal_places, Float
|
|
2581
|
+
|
|
2582
|
+
# @!attribute rounding_method
|
|
2583
|
+
#
|
|
2584
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding::Access::RoundingMethod]
|
|
2585
|
+
required :rounding_method,
|
|
2586
|
+
enum: -> { MetronomeSDK::V1::ContractCreateParams::RecurringCredit::ProrationRounding::Access::RoundingMethod }
|
|
2587
|
+
|
|
2588
|
+
# @!method initialize(decimal_places:, rounding_method:)
|
|
2589
|
+
# Some parameter documentations has been truncated, see
|
|
2590
|
+
# {MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding::Access}
|
|
2591
|
+
# for more details.
|
|
2592
|
+
#
|
|
2593
|
+
# @param decimal_places [Float] Number of decimal places to round to. Applied directly to the stored monetary re
|
|
2594
|
+
#
|
|
2595
|
+
# @param rounding_method [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding::Access::RoundingMethod]
|
|
2596
|
+
|
|
2597
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit::ProrationRounding::Access#rounding_method
|
|
2598
|
+
module RoundingMethod
|
|
2599
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
2600
|
+
|
|
2601
|
+
HALF_UP = :HALF_UP
|
|
2602
|
+
FLOOR = :FLOOR
|
|
2603
|
+
CEILING = :CEILING
|
|
2604
|
+
|
|
2605
|
+
# @!method self.values
|
|
2606
|
+
# @return [Array<Symbol>]
|
|
2607
|
+
end
|
|
2608
|
+
end
|
|
2609
|
+
end
|
|
2610
|
+
|
|
2389
2611
|
# Whether the created commits will use the commit rate or list rate
|
|
2390
2612
|
#
|
|
2391
2613
|
# @see MetronomeSDK::Models::V1::ContractCreateParams::RecurringCredit#rate_type
|
|
@@ -2413,6 +2635,7 @@ module MetronomeSDK
|
|
|
2413
2635
|
QUARTERLY = :QUARTERLY
|
|
2414
2636
|
ANNUAL = :ANNUAL
|
|
2415
2637
|
WEEKLY = :WEEKLY
|
|
2638
|
+
DAILY = :DAILY
|
|
2416
2639
|
|
|
2417
2640
|
# @!method self.values
|
|
2418
2641
|
# @return [Array<Symbol>]
|
|
@@ -2923,6 +3146,112 @@ module MetronomeSDK
|
|
|
2923
3146
|
# @return [Array<Symbol>]
|
|
2924
3147
|
end
|
|
2925
3148
|
|
|
3149
|
+
class SpendTracker < MetronomeSDK::Internal::Type::BaseModel
|
|
3150
|
+
# @!attribute alias_
|
|
3151
|
+
# Human-readable identifier, unique per contract.
|
|
3152
|
+
#
|
|
3153
|
+
# @return [String]
|
|
3154
|
+
required :alias_, String, api_name: :alias
|
|
3155
|
+
|
|
3156
|
+
# @!attribute applicable_spend_specifiers
|
|
3157
|
+
#
|
|
3158
|
+
# @return [Array<MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier>]
|
|
3159
|
+
required :applicable_spend_specifiers,
|
|
3160
|
+
-> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier] }
|
|
3161
|
+
|
|
3162
|
+
# @!attribute credit_type_id
|
|
3163
|
+
#
|
|
3164
|
+
# @return [String]
|
|
3165
|
+
required :credit_type_id, String
|
|
3166
|
+
|
|
3167
|
+
# @!attribute reset_frequency
|
|
3168
|
+
#
|
|
3169
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ResetFrequency]
|
|
3170
|
+
required :reset_frequency,
|
|
3171
|
+
enum: -> { MetronomeSDK::V1::ContractCreateParams::SpendTracker::ResetFrequency }
|
|
3172
|
+
|
|
3173
|
+
# @!method initialize(alias_:, applicable_spend_specifiers:, credit_type_id:, reset_frequency:)
|
|
3174
|
+
# @param alias_ [String] Human-readable identifier, unique per contract.
|
|
3175
|
+
#
|
|
3176
|
+
# @param applicable_spend_specifiers [Array<MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier>]
|
|
3177
|
+
#
|
|
3178
|
+
# @param credit_type_id [String]
|
|
3179
|
+
#
|
|
3180
|
+
# @param reset_frequency [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ResetFrequency]
|
|
3181
|
+
|
|
3182
|
+
class ApplicableSpendSpecifier < MetronomeSDK::Internal::Type::BaseModel
|
|
3183
|
+
# @!attribute sources
|
|
3184
|
+
#
|
|
3185
|
+
# @return [Array<Symbol, MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::Source>]
|
|
3186
|
+
required :sources,
|
|
3187
|
+
-> { MetronomeSDK::Internal::Type::ArrayOf[enum: MetronomeSDK::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::Source] }
|
|
3188
|
+
|
|
3189
|
+
# @!attribute spend_type
|
|
3190
|
+
#
|
|
3191
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::SpendType]
|
|
3192
|
+
required :spend_type,
|
|
3193
|
+
enum: -> { MetronomeSDK::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::SpendType }
|
|
3194
|
+
|
|
3195
|
+
# @!attribute discounted
|
|
3196
|
+
# Filter by whether the spend was discounted. Defaults to ANY if omitted.
|
|
3197
|
+
#
|
|
3198
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::Discounted, nil]
|
|
3199
|
+
optional :discounted,
|
|
3200
|
+
enum: -> { MetronomeSDK::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::Discounted }
|
|
3201
|
+
|
|
3202
|
+
# @!method initialize(sources:, spend_type:, discounted: nil)
|
|
3203
|
+
# @param sources [Array<Symbol, MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::Source>]
|
|
3204
|
+
#
|
|
3205
|
+
# @param spend_type [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::SpendType]
|
|
3206
|
+
#
|
|
3207
|
+
# @param discounted [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier::Discounted] Filter by whether the spend was discounted. Defaults to ANY if omitted.
|
|
3208
|
+
|
|
3209
|
+
module Source
|
|
3210
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
3211
|
+
|
|
3212
|
+
THRESHOLD_RECHARGE = :THRESHOLD_RECHARGE
|
|
3213
|
+
MANUAL = :MANUAL
|
|
3214
|
+
|
|
3215
|
+
# @!method self.values
|
|
3216
|
+
# @return [Array<Symbol>]
|
|
3217
|
+
end
|
|
3218
|
+
|
|
3219
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier#spend_type
|
|
3220
|
+
module SpendType
|
|
3221
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
3222
|
+
|
|
3223
|
+
COMMIT_PURCHASE = :COMMIT_PURCHASE
|
|
3224
|
+
|
|
3225
|
+
# @!method self.values
|
|
3226
|
+
# @return [Array<Symbol>]
|
|
3227
|
+
end
|
|
3228
|
+
|
|
3229
|
+
# Filter by whether the spend was discounted. Defaults to ANY if omitted.
|
|
3230
|
+
#
|
|
3231
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker::ApplicableSpendSpecifier#discounted
|
|
3232
|
+
module Discounted
|
|
3233
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
3234
|
+
|
|
3235
|
+
ANY = :ANY
|
|
3236
|
+
DISCOUNTED_ONLY = :DISCOUNTED_ONLY
|
|
3237
|
+
UNDISCOUNTED_ONLY = :UNDISCOUNTED_ONLY
|
|
3238
|
+
|
|
3239
|
+
# @!method self.values
|
|
3240
|
+
# @return [Array<Symbol>]
|
|
3241
|
+
end
|
|
3242
|
+
end
|
|
3243
|
+
|
|
3244
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::SpendTracker#reset_frequency
|
|
3245
|
+
module ResetFrequency
|
|
3246
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
3247
|
+
|
|
3248
|
+
BILLING_PERIOD = :BILLING_PERIOD
|
|
3249
|
+
|
|
3250
|
+
# @!method self.values
|
|
3251
|
+
# @return [Array<Symbol>]
|
|
3252
|
+
end
|
|
3253
|
+
end
|
|
3254
|
+
|
|
2926
3255
|
class Subscription < MetronomeSDK::Internal::Type::BaseModel
|
|
2927
3256
|
# @!attribute collection_schedule
|
|
2928
3257
|
#
|
|
@@ -2940,6 +3269,12 @@ module MetronomeSDK
|
|
|
2940
3269
|
# @return [MetronomeSDK::Models::V1::ContractCreateParams::Subscription::SubscriptionRate]
|
|
2941
3270
|
required :subscription_rate, -> { MetronomeSDK::V1::ContractCreateParams::Subscription::SubscriptionRate }
|
|
2942
3271
|
|
|
3272
|
+
# @!attribute billing_cycle_config
|
|
3273
|
+
#
|
|
3274
|
+
# @return [MetronomeSDK::Models::V1::ContractCreateParams::Subscription::BillingCycleConfig, nil]
|
|
3275
|
+
optional :billing_cycle_config,
|
|
3276
|
+
-> { MetronomeSDK::V1::ContractCreateParams::Subscription::BillingCycleConfig }
|
|
3277
|
+
|
|
2943
3278
|
# @!attribute custom_fields
|
|
2944
3279
|
# Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
2945
3280
|
#
|
|
@@ -3004,7 +3339,7 @@ module MetronomeSDK
|
|
|
3004
3339
|
# @return [String, nil]
|
|
3005
3340
|
optional :temporary_id, String
|
|
3006
3341
|
|
|
3007
|
-
# @!method initialize(collection_schedule:, proration:, subscription_rate:, custom_fields: nil, description: nil, ending_before: nil, initial_quantity: nil, name: nil, quantity_management_mode: nil, seat_config: nil, starting_at: nil, temporary_id: nil)
|
|
3342
|
+
# @!method initialize(collection_schedule:, proration:, subscription_rate:, billing_cycle_config: nil, custom_fields: nil, description: nil, ending_before: nil, initial_quantity: nil, name: nil, quantity_management_mode: nil, seat_config: nil, starting_at: nil, temporary_id: nil)
|
|
3008
3343
|
# Some parameter documentations has been truncated, see
|
|
3009
3344
|
# {MetronomeSDK::Models::V1::ContractCreateParams::Subscription} for more details.
|
|
3010
3345
|
#
|
|
@@ -3014,6 +3349,8 @@ module MetronomeSDK
|
|
|
3014
3349
|
#
|
|
3015
3350
|
# @param subscription_rate [MetronomeSDK::Models::V1::ContractCreateParams::Subscription::SubscriptionRate]
|
|
3016
3351
|
#
|
|
3352
|
+
# @param billing_cycle_config [MetronomeSDK::Models::V1::ContractCreateParams::Subscription::BillingCycleConfig]
|
|
3353
|
+
#
|
|
3017
3354
|
# @param custom_fields [Hash{Symbol=>String}] Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
3018
3355
|
#
|
|
3019
3356
|
# @param description [String]
|
|
@@ -3062,7 +3399,12 @@ module MetronomeSDK
|
|
|
3062
3399
|
# @return [Boolean, nil]
|
|
3063
3400
|
optional :is_prorated, MetronomeSDK::Internal::Type::Boolean
|
|
3064
3401
|
|
|
3065
|
-
# @!
|
|
3402
|
+
# @!attribute rounding
|
|
3403
|
+
#
|
|
3404
|
+
# @return [MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration::Rounding, nil]
|
|
3405
|
+
optional :rounding, -> { MetronomeSDK::V1::ContractCreateParams::Subscription::Proration::Rounding }
|
|
3406
|
+
|
|
3407
|
+
# @!method initialize(invoice_behavior: nil, is_prorated: nil, rounding: nil)
|
|
3066
3408
|
# Some parameter documentations has been truncated, see
|
|
3067
3409
|
# {MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration} for
|
|
3068
3410
|
# more details.
|
|
@@ -3070,6 +3412,8 @@ module MetronomeSDK
|
|
|
3070
3412
|
# @param invoice_behavior [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration::InvoiceBehavior] Indicates how mid-period quantity adjustments are invoiced.
|
|
3071
3413
|
#
|
|
3072
3414
|
# @param is_prorated [Boolean] Indicates if the partial period will be prorated or charged a full amount.
|
|
3415
|
+
#
|
|
3416
|
+
# @param rounding [MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration::Rounding]
|
|
3073
3417
|
|
|
3074
3418
|
# Indicates how mid-period quantity adjustments are invoiced.
|
|
3075
3419
|
# **BILL_IMMEDIATELY**: Only available when collection schedule is `ADVANCE`. The
|
|
@@ -3087,6 +3431,45 @@ module MetronomeSDK
|
|
|
3087
3431
|
# @!method self.values
|
|
3088
3432
|
# @return [Array<Symbol>]
|
|
3089
3433
|
end
|
|
3434
|
+
|
|
3435
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration#rounding
|
|
3436
|
+
class Rounding < MetronomeSDK::Internal::Type::BaseModel
|
|
3437
|
+
# @!attribute decimal_places
|
|
3438
|
+
# Number of decimal places to round to. Applied directly to the stored monetary
|
|
3439
|
+
# representation. Negative values round to powers of 10 (e.g., -2 rounds to
|
|
3440
|
+
# nearest 100 in the stored unit. For USD, this means rounding to the nearest
|
|
3441
|
+
# dollar).
|
|
3442
|
+
#
|
|
3443
|
+
# @return [Float]
|
|
3444
|
+
required :decimal_places, Float
|
|
3445
|
+
|
|
3446
|
+
# @!attribute rounding_method
|
|
3447
|
+
#
|
|
3448
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration::Rounding::RoundingMethod]
|
|
3449
|
+
required :rounding_method,
|
|
3450
|
+
enum: -> { MetronomeSDK::V1::ContractCreateParams::Subscription::Proration::Rounding::RoundingMethod }
|
|
3451
|
+
|
|
3452
|
+
# @!method initialize(decimal_places:, rounding_method:)
|
|
3453
|
+
# Some parameter documentations has been truncated, see
|
|
3454
|
+
# {MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration::Rounding}
|
|
3455
|
+
# for more details.
|
|
3456
|
+
#
|
|
3457
|
+
# @param decimal_places [Float] Number of decimal places to round to. Applied directly to the stored monetary re
|
|
3458
|
+
#
|
|
3459
|
+
# @param rounding_method [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration::Rounding::RoundingMethod]
|
|
3460
|
+
|
|
3461
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::Subscription::Proration::Rounding#rounding_method
|
|
3462
|
+
module RoundingMethod
|
|
3463
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
3464
|
+
|
|
3465
|
+
HALF_UP = :HALF_UP
|
|
3466
|
+
FLOOR = :FLOOR
|
|
3467
|
+
CEILING = :CEILING
|
|
3468
|
+
|
|
3469
|
+
# @!method self.values
|
|
3470
|
+
# @return [Array<Symbol>]
|
|
3471
|
+
end
|
|
3472
|
+
end
|
|
3090
3473
|
end
|
|
3091
3474
|
|
|
3092
3475
|
# @see MetronomeSDK::Models::V1::ContractCreateParams::Subscription#subscription_rate
|
|
@@ -3131,6 +3514,47 @@ module MetronomeSDK
|
|
|
3131
3514
|
end
|
|
3132
3515
|
end
|
|
3133
3516
|
|
|
3517
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::Subscription#billing_cycle_config
|
|
3518
|
+
class BillingCycleConfig < MetronomeSDK::Internal::Type::BaseModel
|
|
3519
|
+
# @!attribute anchor_date
|
|
3520
|
+
# The date to anchor the billing cycle to. If omitted, defaults to the contract's
|
|
3521
|
+
# usage invoice billing cycle anchor date.
|
|
3522
|
+
#
|
|
3523
|
+
# @return [Time, nil]
|
|
3524
|
+
optional :anchor_date, Time
|
|
3525
|
+
|
|
3526
|
+
# @!attribute invoice_placement
|
|
3527
|
+
# Controls whether this subscription consolidates onto usage invoices or gets its
|
|
3528
|
+
# own scheduled invoice. Defaults to ON_USAGE_INVOICE if omitted.
|
|
3529
|
+
#
|
|
3530
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::Subscription::BillingCycleConfig::InvoicePlacement, nil]
|
|
3531
|
+
optional :invoice_placement,
|
|
3532
|
+
enum: -> { MetronomeSDK::V1::ContractCreateParams::Subscription::BillingCycleConfig::InvoicePlacement }
|
|
3533
|
+
|
|
3534
|
+
# @!method initialize(anchor_date: nil, invoice_placement: nil)
|
|
3535
|
+
# Some parameter documentations has been truncated, see
|
|
3536
|
+
# {MetronomeSDK::Models::V1::ContractCreateParams::Subscription::BillingCycleConfig}
|
|
3537
|
+
# for more details.
|
|
3538
|
+
#
|
|
3539
|
+
# @param anchor_date [Time] The date to anchor the billing cycle to. If omitted, defaults to the contract's
|
|
3540
|
+
#
|
|
3541
|
+
# @param invoice_placement [Symbol, MetronomeSDK::Models::V1::ContractCreateParams::Subscription::BillingCycleConfig::InvoicePlacement] Controls whether this subscription consolidates onto usage invoices or gets its
|
|
3542
|
+
|
|
3543
|
+
# Controls whether this subscription consolidates onto usage invoices or gets its
|
|
3544
|
+
# own scheduled invoice. Defaults to ON_USAGE_INVOICE if omitted.
|
|
3545
|
+
#
|
|
3546
|
+
# @see MetronomeSDK::Models::V1::ContractCreateParams::Subscription::BillingCycleConfig#invoice_placement
|
|
3547
|
+
module InvoicePlacement
|
|
3548
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
3549
|
+
|
|
3550
|
+
ON_SCHEDULED_INVOICE = :ON_SCHEDULED_INVOICE
|
|
3551
|
+
ON_USAGE_INVOICE = :ON_USAGE_INVOICE
|
|
3552
|
+
|
|
3553
|
+
# @!method self.values
|
|
3554
|
+
# @return [Array<Symbol>]
|
|
3555
|
+
end
|
|
3556
|
+
end
|
|
3557
|
+
|
|
3134
3558
|
# Determines how the subscription's quantity is controlled. Defaults to
|
|
3135
3559
|
# QUANTITY_ONLY. **QUANTITY_ONLY**: The subscription quantity is specified
|
|
3136
3560
|
# directly on the subscription. `initial_quantity` must be provided with this
|