metronome-sdk 3.4.0 → 3.6.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 +84 -0
- data/README.md +1 -1
- data/lib/metronome_sdk/client.rb +15 -1
- data/lib/metronome_sdk/internal/transport/base_client.rb +2 -0
- data/lib/metronome_sdk/internal/util.rb +22 -7
- data/lib/metronome_sdk/models/base_threshold_commit.rb +10 -1
- data/lib/metronome_sdk/models/contract_v2.rb +443 -15
- data/lib/metronome_sdk/models/credit.rb +74 -4
- data/lib/metronome_sdk/models/override.rb +9 -8
- data/lib/metronome_sdk/models/prepaid_balance_threshold_configuration.rb +27 -1
- data/lib/metronome_sdk/models/prepaid_balance_threshold_configuration_v2.rb +28 -2
- data/lib/metronome_sdk/models/spend_threshold_configuration.rb +26 -1
- data/lib/metronome_sdk/models/spend_threshold_configuration_v2.rb +30 -4
- data/lib/metronome_sdk/models/update_base_threshold_commit.rb +11 -1
- data/lib/metronome_sdk/models/v1/alert_create_params.rb +1 -0
- data/lib/metronome_sdk/models/v1/contract_amend_params.rb +2 -189
- data/lib/metronome_sdk/models/v1/contract_create_params.rb +3 -191
- data/lib/metronome_sdk/models/v1/contract_list_seat_balances_params.rb +119 -0
- data/lib/metronome_sdk/models/v1/contract_list_seat_balances_response.rb +315 -0
- data/lib/metronome_sdk/models/v1/contracts/product_create_params.rb +31 -1
- data/lib/metronome_sdk/models/v1/contracts/product_update_params.rb +31 -1
- data/lib/metronome_sdk/models/v1/customers/customer_alert.rb +1 -0
- data/lib/metronome_sdk/models/v1/customers/invoice.rb +8 -1
- data/lib/metronome_sdk/models/v1/customers/invoice_list_params.rb +29 -1
- data/lib/metronome_sdk/models/v1/package_create_params.rb +2 -30
- data/lib/metronome_sdk/models/v1/package_list_response.rb +28 -9
- data/lib/metronome_sdk/models/v1/package_retrieve_response.rb +29 -9
- data/lib/metronome_sdk/models/v2/contract_edit_params.rb +67 -20
- data/lib/metronome_sdk/models/v2/contract_get_edit_history_response.rb +496 -15
- data/lib/metronome_sdk/resources/v1/contracts/products.rb +6 -2
- data/lib/metronome_sdk/resources/v1/contracts.rb +76 -2
- data/lib/metronome_sdk/resources/v1/customers/invoices.rb +5 -1
- data/lib/metronome_sdk/resources/v1/packages.rb +1 -3
- data/lib/metronome_sdk/version.rb +1 -1
- data/lib/metronome_sdk.rb +3 -1
- data/rbi/metronome_sdk/internal/util.rbi +8 -0
- data/rbi/metronome_sdk/models/base_threshold_commit.rbi +24 -5
- data/rbi/metronome_sdk/models/contract_v2.rbi +916 -19
- data/rbi/metronome_sdk/models/credit.rbi +139 -3
- data/rbi/metronome_sdk/models/override.rbi +9 -12
- data/rbi/metronome_sdk/models/prepaid_balance_threshold_configuration.rbi +54 -3
- data/rbi/metronome_sdk/models/prepaid_balance_threshold_configuration_v2.rbi +55 -4
- data/rbi/metronome_sdk/models/spend_threshold_configuration.rbi +54 -3
- data/rbi/metronome_sdk/models/spend_threshold_configuration_v2.rbi +58 -9
- data/rbi/metronome_sdk/models/update_base_threshold_commit.rbi +22 -4
- data/rbi/metronome_sdk/models/v1/alert_create_params.rbi +5 -0
- data/rbi/metronome_sdk/models/v1/contract_amend_params.rbi +3 -416
- data/rbi/metronome_sdk/models/v1/contract_create_params.rbi +5 -418
- data/rbi/metronome_sdk/models/v1/contract_list_seat_balances_params.rbi +179 -0
- data/rbi/metronome_sdk/models/v1/contract_list_seat_balances_response.rbi +714 -0
- data/rbi/metronome_sdk/models/v1/contracts/product_create_params.rbi +74 -0
- data/rbi/metronome_sdk/models/v1/contracts/product_update_params.rbi +74 -0
- data/rbi/metronome_sdk/models/v1/customers/customer_alert.rbi +5 -0
- data/rbi/metronome_sdk/models/v1/customers/invoice.rbi +9 -0
- data/rbi/metronome_sdk/models/v1/customers/invoice_list_params.rbi +75 -0
- data/rbi/metronome_sdk/models/v1/package_create_params.rbi +3 -76
- data/rbi/metronome_sdk/models/v1/package_list_response.rbi +72 -15
- data/rbi/metronome_sdk/models/v1/package_retrieve_response.rbi +72 -17
- data/rbi/metronome_sdk/models/v2/contract_edit_params.rbi +133 -28
- data/rbi/metronome_sdk/models/v2/contract_get_edit_history_response.rbi +1174 -145
- data/rbi/metronome_sdk/resources/v1/contracts/products.rbi +18 -0
- data/rbi/metronome_sdk/resources/v1/contracts.rbi +88 -3
- data/rbi/metronome_sdk/resources/v1/customers/invoices.rbi +7 -0
- data/rbi/metronome_sdk/resources/v1/packages.rbi +0 -3
- data/sig/metronome_sdk/internal/util.rbs +4 -0
- data/sig/metronome_sdk/models/base_threshold_commit.rbs +13 -3
- data/sig/metronome_sdk/models/contract_v2.rbs +401 -16
- data/sig/metronome_sdk/models/credit.rbs +69 -0
- data/sig/metronome_sdk/models/override.rbs +8 -10
- data/sig/metronome_sdk/models/prepaid_balance_threshold_configuration.rbs +22 -3
- data/sig/metronome_sdk/models/prepaid_balance_threshold_configuration_v2.rbs +23 -4
- data/sig/metronome_sdk/models/spend_threshold_configuration.rbs +22 -3
- data/sig/metronome_sdk/models/spend_threshold_configuration_v2.rbs +26 -7
- data/sig/metronome_sdk/models/update_base_threshold_commit.rbs +15 -2
- data/sig/metronome_sdk/models/v1/alert_create_params.rbs +3 -1
- data/sig/metronome_sdk/models/v1/contract_amend_params.rbs +3 -147
- data/sig/metronome_sdk/models/v1/contract_create_params.rbs +3 -147
- data/sig/metronome_sdk/models/v1/contract_list_seat_balances_params.rbs +96 -0
- data/sig/metronome_sdk/models/v1/contract_list_seat_balances_response.rbs +299 -0
- data/sig/metronome_sdk/models/v1/contracts/product_create_params.rbs +20 -0
- data/sig/metronome_sdk/models/v1/contracts/product_update_params.rbs +20 -0
- data/sig/metronome_sdk/models/v1/customers/customer_alert.rbs +3 -1
- data/sig/metronome_sdk/models/v1/customers/invoice.rbs +7 -0
- data/sig/metronome_sdk/models/v1/customers/invoice_list_params.rbs +29 -1
- data/sig/metronome_sdk/models/v1/package_create_params.rbs +3 -30
- data/sig/metronome_sdk/models/v1/package_list_response.rbs +33 -15
- data/sig/metronome_sdk/models/v1/package_retrieve_response.rbs +33 -15
- data/sig/metronome_sdk/models/v2/contract_edit_params.rbs +33 -10
- data/sig/metronome_sdk/models/v2/contract_get_edit_history_response.rbs +409 -19
- data/sig/metronome_sdk/resources/v1/contracts/products.rbs +2 -0
- data/sig/metronome_sdk/resources/v1/contracts.rbs +15 -0
- data/sig/metronome_sdk/resources/v1/customers/invoices.rbs +2 -0
- data/sig/metronome_sdk/resources/v1/packages.rbs +0 -1
- metadata +8 -2
|
@@ -86,8 +86,9 @@ module MetronomeSDK
|
|
|
86
86
|
# @!attribute add_subscriptions
|
|
87
87
|
# List of subscriptions on the contract.
|
|
88
88
|
#
|
|
89
|
-
# @return [Array<MetronomeSDK::Models::
|
|
90
|
-
optional :add_subscriptions,
|
|
89
|
+
# @return [Array<MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription>, nil]
|
|
90
|
+
optional :add_subscriptions,
|
|
91
|
+
-> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription] }
|
|
91
92
|
|
|
92
93
|
# @!attribute add_usage_filters
|
|
93
94
|
#
|
|
@@ -234,7 +235,7 @@ module MetronomeSDK
|
|
|
234
235
|
#
|
|
235
236
|
# @param add_spend_threshold_configuration [MetronomeSDK::Models::SpendThresholdConfigurationV2]
|
|
236
237
|
#
|
|
237
|
-
# @param add_subscriptions [Array<MetronomeSDK::Models::
|
|
238
|
+
# @param add_subscriptions [Array<MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription>] List of subscriptions on the contract.
|
|
238
239
|
#
|
|
239
240
|
# @param add_usage_filters [Array<MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddUsageFilter>]
|
|
240
241
|
#
|
|
@@ -582,6 +583,17 @@ module MetronomeSDK
|
|
|
582
583
|
# @return [Float, nil]
|
|
583
584
|
optional :priority, Float
|
|
584
585
|
|
|
586
|
+
# @!attribute rate_type
|
|
587
|
+
#
|
|
588
|
+
# @return [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddCredit::RateType, nil]
|
|
589
|
+
optional :rate_type,
|
|
590
|
+
enum: -> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddCredit::RateType }
|
|
591
|
+
|
|
592
|
+
# @!attribute rollover_fraction
|
|
593
|
+
#
|
|
594
|
+
# @return [Float, nil]
|
|
595
|
+
optional :rollover_fraction, Float
|
|
596
|
+
|
|
585
597
|
# @!attribute salesforce_opportunity_id
|
|
586
598
|
# This field's availability is dependent on your client's configuration.
|
|
587
599
|
#
|
|
@@ -599,7 +611,7 @@ module MetronomeSDK
|
|
|
599
611
|
# @return [Array<MetronomeSDK::Models::CommitSpecifierInput>, nil]
|
|
600
612
|
optional :specifiers, -> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::CommitSpecifierInput] }
|
|
601
613
|
|
|
602
|
-
# @!method initialize(id:, product:, type:, access_schedule: nil, applicable_product_ids: nil, applicable_product_tags: nil, description: nil, hierarchy_configuration: nil, name: nil, netsuite_sales_order_id: nil, priority: nil, salesforce_opportunity_id: nil, specifiers: nil)
|
|
614
|
+
# @!method initialize(id:, product:, type:, access_schedule: nil, applicable_product_ids: nil, applicable_product_tags: nil, description: nil, hierarchy_configuration: nil, name: nil, netsuite_sales_order_id: nil, priority: nil, rate_type: nil, rollover_fraction: nil, salesforce_opportunity_id: nil, specifiers: nil)
|
|
603
615
|
# Some parameter documentations has been truncated, see
|
|
604
616
|
# {MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddCredit} for
|
|
605
617
|
# more details.
|
|
@@ -626,6 +638,10 @@ module MetronomeSDK
|
|
|
626
638
|
#
|
|
627
639
|
# @param priority [Float] If multiple credits or commits are applicable, the one with the lower priority w
|
|
628
640
|
#
|
|
641
|
+
# @param rate_type [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddCredit::RateType]
|
|
642
|
+
#
|
|
643
|
+
# @param rollover_fraction [Float]
|
|
644
|
+
#
|
|
629
645
|
# @param salesforce_opportunity_id [String] This field's availability is dependent on your client's configuration.
|
|
630
646
|
#
|
|
631
647
|
# @param specifiers [Array<MetronomeSDK::Models::CommitSpecifierInput>] List of filters that determine what kind of customer usage draws down a commit o
|
|
@@ -656,6 +672,17 @@ module MetronomeSDK
|
|
|
656
672
|
# @!method self.values
|
|
657
673
|
# @return [Array<Symbol>]
|
|
658
674
|
end
|
|
675
|
+
|
|
676
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddCredit#rate_type
|
|
677
|
+
module RateType
|
|
678
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
679
|
+
|
|
680
|
+
COMMIT_RATE = :COMMIT_RATE
|
|
681
|
+
LIST_RATE = :LIST_RATE
|
|
682
|
+
|
|
683
|
+
# @!method self.values
|
|
684
|
+
# @return [Array<Symbol>]
|
|
685
|
+
end
|
|
659
686
|
end
|
|
660
687
|
|
|
661
688
|
class AddOverride < MetronomeSDK::Internal::Type::BaseModel
|
|
@@ -664,6 +691,11 @@ module MetronomeSDK
|
|
|
664
691
|
# @return [String]
|
|
665
692
|
required :id, String
|
|
666
693
|
|
|
694
|
+
# @!attribute created_at
|
|
695
|
+
#
|
|
696
|
+
# @return [Time]
|
|
697
|
+
required :created_at, Time
|
|
698
|
+
|
|
667
699
|
# @!attribute starting_at
|
|
668
700
|
#
|
|
669
701
|
# @return [Time]
|
|
@@ -734,8 +766,9 @@ module MetronomeSDK
|
|
|
734
766
|
optional :type,
|
|
735
767
|
enum: -> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddOverride::Type }
|
|
736
768
|
|
|
737
|
-
# @!method initialize(id:, starting_at:, applicable_product_tags: nil, ending_before: nil, entitled: nil, is_commit_specific: nil, multiplier: nil, override_specifiers: nil, override_tiers: nil, overwrite_rate: nil, priority: nil, product: nil, target: nil, type: nil)
|
|
769
|
+
# @!method initialize(id:, created_at:, starting_at:, applicable_product_tags: nil, ending_before: nil, entitled: nil, is_commit_specific: nil, multiplier: nil, override_specifiers: nil, override_tiers: nil, overwrite_rate: nil, priority: nil, product: nil, target: nil, type: nil)
|
|
738
770
|
# @param id [String]
|
|
771
|
+
# @param created_at [Time]
|
|
739
772
|
# @param starting_at [Time]
|
|
740
773
|
# @param applicable_product_tags [Array<String>]
|
|
741
774
|
# @param ending_before [Time]
|
|
@@ -787,12 +820,7 @@ module MetronomeSDK
|
|
|
787
820
|
# @return [Array<String>, nil]
|
|
788
821
|
optional :recurring_commit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]
|
|
789
822
|
|
|
790
|
-
# @!
|
|
791
|
-
#
|
|
792
|
-
# @return [Array<String>, nil]
|
|
793
|
-
optional :recurring_credit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]
|
|
794
|
-
|
|
795
|
-
# @!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, recurring_credit_ids: nil)
|
|
823
|
+
# @!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)
|
|
796
824
|
# @param billing_frequency [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddOverride::OverrideSpecifier::BillingFrequency]
|
|
797
825
|
# @param commit_ids [Array<String>]
|
|
798
826
|
# @param presentation_group_values [Hash{Symbol=>String, nil}]
|
|
@@ -800,7 +828,6 @@ module MetronomeSDK
|
|
|
800
828
|
# @param product_id [String]
|
|
801
829
|
# @param product_tags [Array<String>]
|
|
802
830
|
# @param recurring_commit_ids [Array<String>]
|
|
803
|
-
# @param recurring_credit_ids [Array<String>]
|
|
804
831
|
|
|
805
832
|
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddOverride::OverrideSpecifier#billing_frequency
|
|
806
833
|
module BillingFrequency
|
|
@@ -1748,6 +1775,364 @@ module MetronomeSDK
|
|
|
1748
1775
|
end
|
|
1749
1776
|
end
|
|
1750
1777
|
|
|
1778
|
+
class AddSubscription < MetronomeSDK::Internal::Type::BaseModel
|
|
1779
|
+
# @!attribute billing_periods
|
|
1780
|
+
# Previous, current, and next billing periods for the subscription.
|
|
1781
|
+
#
|
|
1782
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods]
|
|
1783
|
+
required :billing_periods,
|
|
1784
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods }
|
|
1785
|
+
|
|
1786
|
+
# @!attribute collection_schedule
|
|
1787
|
+
#
|
|
1788
|
+
# @return [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::CollectionSchedule]
|
|
1789
|
+
required :collection_schedule,
|
|
1790
|
+
enum: -> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::CollectionSchedule }
|
|
1791
|
+
|
|
1792
|
+
# @!attribute proration
|
|
1793
|
+
#
|
|
1794
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::Proration]
|
|
1795
|
+
required :proration,
|
|
1796
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::Proration }
|
|
1797
|
+
|
|
1798
|
+
# @!attribute quantity_management_mode
|
|
1799
|
+
# Determines how the subscription's quantity is controlled. Defaults to
|
|
1800
|
+
# QUANTITY_ONLY. **QUANTITY_ONLY**: The subscription quantity is specified
|
|
1801
|
+
# directly on the subscription. `initial_quantity` must be provided with this
|
|
1802
|
+
# option. Compatible with recurring commits/credits that use POOLED allocation.
|
|
1803
|
+
# **SEAT_BASED**: Use when you want to pass specific seat identifiers (e.g. add
|
|
1804
|
+
# user_123) to increment and decrement a subscription quantity, rather than
|
|
1805
|
+
# directly providing the quantity. You must use a **SEAT_BASED** subscription to
|
|
1806
|
+
# use a linked recurring credit with an allocation per seat. `seat_config` must be
|
|
1807
|
+
# provided with this option.
|
|
1808
|
+
#
|
|
1809
|
+
# @return [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::QuantityManagementMode]
|
|
1810
|
+
required :quantity_management_mode,
|
|
1811
|
+
enum: -> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::QuantityManagementMode }
|
|
1812
|
+
|
|
1813
|
+
# @!attribute quantity_schedule
|
|
1814
|
+
# List of quantity schedule items for the subscription. Only includes the current
|
|
1815
|
+
# quantity and future quantity changes.
|
|
1816
|
+
#
|
|
1817
|
+
# @return [Array<MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::QuantitySchedule>]
|
|
1818
|
+
required :quantity_schedule,
|
|
1819
|
+
-> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::QuantitySchedule] }
|
|
1820
|
+
|
|
1821
|
+
# @!attribute starting_at
|
|
1822
|
+
#
|
|
1823
|
+
# @return [Time]
|
|
1824
|
+
required :starting_at, Time
|
|
1825
|
+
|
|
1826
|
+
# @!attribute subscription_rate
|
|
1827
|
+
#
|
|
1828
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate]
|
|
1829
|
+
required :subscription_rate,
|
|
1830
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate }
|
|
1831
|
+
|
|
1832
|
+
# @!attribute id
|
|
1833
|
+
#
|
|
1834
|
+
# @return [String, nil]
|
|
1835
|
+
optional :id, String
|
|
1836
|
+
|
|
1837
|
+
# @!attribute custom_fields
|
|
1838
|
+
# Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
1839
|
+
#
|
|
1840
|
+
# @return [Hash{Symbol=>String}, nil]
|
|
1841
|
+
optional :custom_fields, MetronomeSDK::Internal::Type::HashOf[String]
|
|
1842
|
+
|
|
1843
|
+
# @!attribute description
|
|
1844
|
+
#
|
|
1845
|
+
# @return [String, nil]
|
|
1846
|
+
optional :description, String
|
|
1847
|
+
|
|
1848
|
+
# @!attribute ending_before
|
|
1849
|
+
#
|
|
1850
|
+
# @return [Time, nil]
|
|
1851
|
+
optional :ending_before, Time
|
|
1852
|
+
|
|
1853
|
+
# @!attribute fiat_credit_type_id
|
|
1854
|
+
#
|
|
1855
|
+
# @return [String, nil]
|
|
1856
|
+
optional :fiat_credit_type_id, String
|
|
1857
|
+
|
|
1858
|
+
# @!attribute name
|
|
1859
|
+
#
|
|
1860
|
+
# @return [String, nil]
|
|
1861
|
+
optional :name, String
|
|
1862
|
+
|
|
1863
|
+
# @!attribute seat_config
|
|
1864
|
+
#
|
|
1865
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SeatConfig, nil]
|
|
1866
|
+
optional :seat_config,
|
|
1867
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SeatConfig }
|
|
1868
|
+
|
|
1869
|
+
# @!method initialize(billing_periods:, collection_schedule:, proration:, quantity_management_mode:, quantity_schedule:, starting_at:, subscription_rate:, id: nil, custom_fields: nil, description: nil, ending_before: nil, fiat_credit_type_id: nil, name: nil, seat_config: nil)
|
|
1870
|
+
# Some parameter documentations has been truncated, see
|
|
1871
|
+
# {MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription}
|
|
1872
|
+
# for more details.
|
|
1873
|
+
#
|
|
1874
|
+
# @param billing_periods [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods] Previous, current, and next billing periods for the subscription.
|
|
1875
|
+
#
|
|
1876
|
+
# @param collection_schedule [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::CollectionSchedule]
|
|
1877
|
+
#
|
|
1878
|
+
# @param proration [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::Proration]
|
|
1879
|
+
#
|
|
1880
|
+
# @param quantity_management_mode [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::QuantityManagementMode] Determines how the subscription's quantity is controlled. Defaults to QUANTITY_O
|
|
1881
|
+
#
|
|
1882
|
+
# @param quantity_schedule [Array<MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::QuantitySchedule>] List of quantity schedule items for the subscription. Only includes the current
|
|
1883
|
+
#
|
|
1884
|
+
# @param starting_at [Time]
|
|
1885
|
+
#
|
|
1886
|
+
# @param subscription_rate [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate]
|
|
1887
|
+
#
|
|
1888
|
+
# @param id [String]
|
|
1889
|
+
#
|
|
1890
|
+
# @param custom_fields [Hash{Symbol=>String}] Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
1891
|
+
#
|
|
1892
|
+
# @param description [String]
|
|
1893
|
+
#
|
|
1894
|
+
# @param ending_before [Time]
|
|
1895
|
+
#
|
|
1896
|
+
# @param fiat_credit_type_id [String]
|
|
1897
|
+
#
|
|
1898
|
+
# @param name [String]
|
|
1899
|
+
#
|
|
1900
|
+
# @param seat_config [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SeatConfig]
|
|
1901
|
+
|
|
1902
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription#billing_periods
|
|
1903
|
+
class BillingPeriods < MetronomeSDK::Internal::Type::BaseModel
|
|
1904
|
+
# @!attribute current
|
|
1905
|
+
#
|
|
1906
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Current, nil]
|
|
1907
|
+
optional :current,
|
|
1908
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Current }
|
|
1909
|
+
|
|
1910
|
+
# @!attribute next_
|
|
1911
|
+
#
|
|
1912
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Next, nil]
|
|
1913
|
+
optional :next_,
|
|
1914
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Next },
|
|
1915
|
+
api_name: :next
|
|
1916
|
+
|
|
1917
|
+
# @!attribute previous
|
|
1918
|
+
#
|
|
1919
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Previous, nil]
|
|
1920
|
+
optional :previous,
|
|
1921
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Previous }
|
|
1922
|
+
|
|
1923
|
+
# @!method initialize(current: nil, next_: nil, previous: nil)
|
|
1924
|
+
# Previous, current, and next billing periods for the subscription.
|
|
1925
|
+
#
|
|
1926
|
+
# @param current [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Current]
|
|
1927
|
+
# @param next_ [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Next]
|
|
1928
|
+
# @param previous [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods::Previous]
|
|
1929
|
+
|
|
1930
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods#current
|
|
1931
|
+
class Current < MetronomeSDK::Internal::Type::BaseModel
|
|
1932
|
+
# @!attribute ending_before
|
|
1933
|
+
#
|
|
1934
|
+
# @return [Time]
|
|
1935
|
+
required :ending_before, Time
|
|
1936
|
+
|
|
1937
|
+
# @!attribute starting_at
|
|
1938
|
+
#
|
|
1939
|
+
# @return [Time]
|
|
1940
|
+
required :starting_at, Time
|
|
1941
|
+
|
|
1942
|
+
# @!method initialize(ending_before:, starting_at:)
|
|
1943
|
+
# @param ending_before [Time]
|
|
1944
|
+
# @param starting_at [Time]
|
|
1945
|
+
end
|
|
1946
|
+
|
|
1947
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods#next_
|
|
1948
|
+
class Next < MetronomeSDK::Internal::Type::BaseModel
|
|
1949
|
+
# @!attribute ending_before
|
|
1950
|
+
#
|
|
1951
|
+
# @return [Time]
|
|
1952
|
+
required :ending_before, Time
|
|
1953
|
+
|
|
1954
|
+
# @!attribute starting_at
|
|
1955
|
+
#
|
|
1956
|
+
# @return [Time]
|
|
1957
|
+
required :starting_at, Time
|
|
1958
|
+
|
|
1959
|
+
# @!method initialize(ending_before:, starting_at:)
|
|
1960
|
+
# @param ending_before [Time]
|
|
1961
|
+
# @param starting_at [Time]
|
|
1962
|
+
end
|
|
1963
|
+
|
|
1964
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::BillingPeriods#previous
|
|
1965
|
+
class Previous < MetronomeSDK::Internal::Type::BaseModel
|
|
1966
|
+
# @!attribute ending_before
|
|
1967
|
+
#
|
|
1968
|
+
# @return [Time]
|
|
1969
|
+
required :ending_before, Time
|
|
1970
|
+
|
|
1971
|
+
# @!attribute starting_at
|
|
1972
|
+
#
|
|
1973
|
+
# @return [Time]
|
|
1974
|
+
required :starting_at, Time
|
|
1975
|
+
|
|
1976
|
+
# @!method initialize(ending_before:, starting_at:)
|
|
1977
|
+
# @param ending_before [Time]
|
|
1978
|
+
# @param starting_at [Time]
|
|
1979
|
+
end
|
|
1980
|
+
end
|
|
1981
|
+
|
|
1982
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription#collection_schedule
|
|
1983
|
+
module CollectionSchedule
|
|
1984
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
1985
|
+
|
|
1986
|
+
ADVANCE = :ADVANCE
|
|
1987
|
+
ARREARS = :ARREARS
|
|
1988
|
+
|
|
1989
|
+
# @!method self.values
|
|
1990
|
+
# @return [Array<Symbol>]
|
|
1991
|
+
end
|
|
1992
|
+
|
|
1993
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription#proration
|
|
1994
|
+
class Proration < MetronomeSDK::Internal::Type::BaseModel
|
|
1995
|
+
# @!attribute invoice_behavior
|
|
1996
|
+
#
|
|
1997
|
+
# @return [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::Proration::InvoiceBehavior]
|
|
1998
|
+
required :invoice_behavior,
|
|
1999
|
+
enum: -> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::Proration::InvoiceBehavior }
|
|
2000
|
+
|
|
2001
|
+
# @!attribute is_prorated
|
|
2002
|
+
#
|
|
2003
|
+
# @return [Boolean]
|
|
2004
|
+
required :is_prorated, MetronomeSDK::Internal::Type::Boolean
|
|
2005
|
+
|
|
2006
|
+
# @!method initialize(invoice_behavior:, is_prorated:)
|
|
2007
|
+
# @param invoice_behavior [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::Proration::InvoiceBehavior]
|
|
2008
|
+
# @param is_prorated [Boolean]
|
|
2009
|
+
|
|
2010
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::Proration#invoice_behavior
|
|
2011
|
+
module InvoiceBehavior
|
|
2012
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
2013
|
+
|
|
2014
|
+
BILL_IMMEDIATELY = :BILL_IMMEDIATELY
|
|
2015
|
+
BILL_ON_NEXT_COLLECTION_DATE = :BILL_ON_NEXT_COLLECTION_DATE
|
|
2016
|
+
|
|
2017
|
+
# @!method self.values
|
|
2018
|
+
# @return [Array<Symbol>]
|
|
2019
|
+
end
|
|
2020
|
+
end
|
|
2021
|
+
|
|
2022
|
+
# Determines how the subscription's quantity is controlled. Defaults to
|
|
2023
|
+
# QUANTITY_ONLY. **QUANTITY_ONLY**: The subscription quantity is specified
|
|
2024
|
+
# directly on the subscription. `initial_quantity` must be provided with this
|
|
2025
|
+
# option. Compatible with recurring commits/credits that use POOLED allocation.
|
|
2026
|
+
# **SEAT_BASED**: Use when you want to pass specific seat identifiers (e.g. add
|
|
2027
|
+
# user_123) to increment and decrement a subscription quantity, rather than
|
|
2028
|
+
# directly providing the quantity. You must use a **SEAT_BASED** subscription to
|
|
2029
|
+
# use a linked recurring credit with an allocation per seat. `seat_config` must be
|
|
2030
|
+
# provided with this option.
|
|
2031
|
+
#
|
|
2032
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription#quantity_management_mode
|
|
2033
|
+
module QuantityManagementMode
|
|
2034
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
2035
|
+
|
|
2036
|
+
SEAT_BASED = :SEAT_BASED
|
|
2037
|
+
QUANTITY_ONLY = :QUANTITY_ONLY
|
|
2038
|
+
|
|
2039
|
+
# @!method self.values
|
|
2040
|
+
# @return [Array<Symbol>]
|
|
2041
|
+
end
|
|
2042
|
+
|
|
2043
|
+
class QuantitySchedule < MetronomeSDK::Internal::Type::BaseModel
|
|
2044
|
+
# @!attribute quantity
|
|
2045
|
+
#
|
|
2046
|
+
# @return [Float]
|
|
2047
|
+
required :quantity, Float
|
|
2048
|
+
|
|
2049
|
+
# @!attribute starting_at
|
|
2050
|
+
#
|
|
2051
|
+
# @return [Time]
|
|
2052
|
+
required :starting_at, Time
|
|
2053
|
+
|
|
2054
|
+
# @!attribute ending_before
|
|
2055
|
+
#
|
|
2056
|
+
# @return [Time, nil]
|
|
2057
|
+
optional :ending_before, Time
|
|
2058
|
+
|
|
2059
|
+
# @!method initialize(quantity:, starting_at:, ending_before: nil)
|
|
2060
|
+
# @param quantity [Float]
|
|
2061
|
+
# @param starting_at [Time]
|
|
2062
|
+
# @param ending_before [Time]
|
|
2063
|
+
end
|
|
2064
|
+
|
|
2065
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription#subscription_rate
|
|
2066
|
+
class SubscriptionRate < MetronomeSDK::Internal::Type::BaseModel
|
|
2067
|
+
# @!attribute billing_frequency
|
|
2068
|
+
#
|
|
2069
|
+
# @return [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate::BillingFrequency]
|
|
2070
|
+
required :billing_frequency,
|
|
2071
|
+
enum: -> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate::BillingFrequency }
|
|
2072
|
+
|
|
2073
|
+
# @!attribute product
|
|
2074
|
+
#
|
|
2075
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate::Product]
|
|
2076
|
+
required :product,
|
|
2077
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate::Product }
|
|
2078
|
+
|
|
2079
|
+
# @!method initialize(billing_frequency:, product:)
|
|
2080
|
+
# @param billing_frequency [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate::BillingFrequency]
|
|
2081
|
+
# @param product [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate::Product]
|
|
2082
|
+
|
|
2083
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate#billing_frequency
|
|
2084
|
+
module BillingFrequency
|
|
2085
|
+
extend MetronomeSDK::Internal::Type::Enum
|
|
2086
|
+
|
|
2087
|
+
MONTHLY = :MONTHLY
|
|
2088
|
+
QUARTERLY = :QUARTERLY
|
|
2089
|
+
ANNUAL = :ANNUAL
|
|
2090
|
+
WEEKLY = :WEEKLY
|
|
2091
|
+
|
|
2092
|
+
# @!method self.values
|
|
2093
|
+
# @return [Array<Symbol>]
|
|
2094
|
+
end
|
|
2095
|
+
|
|
2096
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SubscriptionRate#product
|
|
2097
|
+
class Product < MetronomeSDK::Internal::Type::BaseModel
|
|
2098
|
+
# @!attribute id
|
|
2099
|
+
#
|
|
2100
|
+
# @return [String]
|
|
2101
|
+
required :id, String
|
|
2102
|
+
|
|
2103
|
+
# @!attribute name
|
|
2104
|
+
#
|
|
2105
|
+
# @return [String]
|
|
2106
|
+
required :name, String
|
|
2107
|
+
|
|
2108
|
+
# @!method initialize(id:, name:)
|
|
2109
|
+
# @param id [String]
|
|
2110
|
+
# @param name [String]
|
|
2111
|
+
end
|
|
2112
|
+
end
|
|
2113
|
+
|
|
2114
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription#seat_config
|
|
2115
|
+
class SeatConfig < MetronomeSDK::Internal::Type::BaseModel
|
|
2116
|
+
# @!attribute seat_group_key
|
|
2117
|
+
# The property name, sent on usage events, that identifies the seat ID associated
|
|
2118
|
+
# with the usage event. For example, the property name might be seat_id or
|
|
2119
|
+
# user_id. The property must be set as a group key on billable metrics and a
|
|
2120
|
+
# presentation/pricing group key on contract products. This allows linked
|
|
2121
|
+
# recurring credits with an allocation per seat to be consumed by only one seat's
|
|
2122
|
+
# usage.
|
|
2123
|
+
#
|
|
2124
|
+
# @return [String]
|
|
2125
|
+
required :seat_group_key, String
|
|
2126
|
+
|
|
2127
|
+
# @!method initialize(seat_group_key:)
|
|
2128
|
+
# Some parameter documentations has been truncated, see
|
|
2129
|
+
# {MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::AddSubscription::SeatConfig}
|
|
2130
|
+
# for more details.
|
|
2131
|
+
#
|
|
2132
|
+
# @param seat_group_key [String] The property name, sent on usage events, that identifies the seat ID associated
|
|
2133
|
+
end
|
|
2134
|
+
end
|
|
2135
|
+
|
|
1751
2136
|
class AddUsageFilter < MetronomeSDK::Internal::Type::BaseModel
|
|
1752
2137
|
# @!attribute group_key
|
|
1753
2138
|
#
|
|
@@ -2195,6 +2580,22 @@ module MetronomeSDK
|
|
|
2195
2580
|
optional :access_schedule,
|
|
2196
2581
|
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCredit::AccessSchedule }
|
|
2197
2582
|
|
|
2583
|
+
# @!attribute applicable_product_ids
|
|
2584
|
+
# Which products the credit applies to. If applicable_product_ids,
|
|
2585
|
+
# applicable_product_tags or specifiers are not provided, the credit applies to
|
|
2586
|
+
# all products.
|
|
2587
|
+
#
|
|
2588
|
+
# @return [Array<String>, nil]
|
|
2589
|
+
optional :applicable_product_ids, MetronomeSDK::Internal::Type::ArrayOf[String], nil?: true
|
|
2590
|
+
|
|
2591
|
+
# @!attribute applicable_product_tags
|
|
2592
|
+
# Which tags the credit applies to. If applicable_product_ids,
|
|
2593
|
+
# applicable_product_tags or specifiers are not provided, the credit applies to
|
|
2594
|
+
# all products.
|
|
2595
|
+
#
|
|
2596
|
+
# @return [Array<String>, nil]
|
|
2597
|
+
optional :applicable_product_tags, MetronomeSDK::Internal::Type::ArrayOf[String], nil?: true
|
|
2598
|
+
|
|
2198
2599
|
# @!attribute description
|
|
2199
2600
|
#
|
|
2200
2601
|
# @return [String, nil]
|
|
@@ -2223,6 +2624,11 @@ module MetronomeSDK
|
|
|
2223
2624
|
# @return [Float, nil]
|
|
2224
2625
|
optional :priority, Float, nil?: true
|
|
2225
2626
|
|
|
2627
|
+
# @!attribute product_id
|
|
2628
|
+
#
|
|
2629
|
+
# @return [String, nil]
|
|
2630
|
+
optional :product_id, String
|
|
2631
|
+
|
|
2226
2632
|
# @!attribute rate_type
|
|
2227
2633
|
# If set, the credit's rate type was updated to the specified value.
|
|
2228
2634
|
#
|
|
@@ -2235,7 +2641,20 @@ module MetronomeSDK
|
|
|
2235
2641
|
# @return [Float, nil]
|
|
2236
2642
|
optional :rollover_fraction, Float, nil?: true
|
|
2237
2643
|
|
|
2238
|
-
# @!
|
|
2644
|
+
# @!attribute specifiers
|
|
2645
|
+
# List of filters that determine what kind of customer usage draws down a commit
|
|
2646
|
+
# or credit. A customer's usage needs to meet the condition of at least one of the
|
|
2647
|
+
# specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
|
2648
|
+
# be used together with `applicable_product_ids` or `applicable_product_tags`.
|
|
2649
|
+
# Instead, to target usage by product or product tag, pass those values in the
|
|
2650
|
+
# body of `specifiers`.
|
|
2651
|
+
#
|
|
2652
|
+
# @return [Array<MetronomeSDK::Models::CommitSpecifierInput>, nil]
|
|
2653
|
+
optional :specifiers,
|
|
2654
|
+
-> { MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::CommitSpecifierInput] },
|
|
2655
|
+
nil?: true
|
|
2656
|
+
|
|
2657
|
+
# @!method initialize(id:, access_schedule: nil, applicable_product_ids: nil, applicable_product_tags: nil, description: nil, hierarchy_configuration: nil, name: nil, netsuite_sales_order_id: nil, priority: nil, product_id: nil, rate_type: nil, rollover_fraction: nil, specifiers: nil)
|
|
2239
2658
|
# Some parameter documentations has been truncated, see
|
|
2240
2659
|
# {MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCredit}
|
|
2241
2660
|
# for more details.
|
|
@@ -2244,6 +2663,10 @@ module MetronomeSDK
|
|
|
2244
2663
|
#
|
|
2245
2664
|
# @param access_schedule [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCredit::AccessSchedule]
|
|
2246
2665
|
#
|
|
2666
|
+
# @param applicable_product_ids [Array<String>, nil] Which products the credit applies to. If applicable_product_ids, applicable_prod
|
|
2667
|
+
#
|
|
2668
|
+
# @param applicable_product_tags [Array<String>, nil] Which tags the credit applies to. If applicable*product_ids, applicable_product*
|
|
2669
|
+
#
|
|
2247
2670
|
# @param description [String]
|
|
2248
2671
|
#
|
|
2249
2672
|
# @param hierarchy_configuration [MetronomeSDK::Models::CommitHierarchyConfiguration] Optional configuration for credit hierarchy access control
|
|
@@ -2254,9 +2677,13 @@ module MetronomeSDK
|
|
|
2254
2677
|
#
|
|
2255
2678
|
# @param priority [Float, nil] If multiple credits are applicable, the one with the lower priority will apply f
|
|
2256
2679
|
#
|
|
2680
|
+
# @param product_id [String]
|
|
2681
|
+
#
|
|
2257
2682
|
# @param rate_type [Symbol, MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCredit::RateType] If set, the credit's rate type was updated to the specified value.
|
|
2258
2683
|
#
|
|
2259
2684
|
# @param rollover_fraction [Float, nil]
|
|
2685
|
+
#
|
|
2686
|
+
# @param specifiers [Array<MetronomeSDK::Models::CommitSpecifierInput>, nil] List of filters that determine what kind of customer usage draws down a commit o
|
|
2260
2687
|
|
|
2261
2688
|
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateCredit#access_schedule
|
|
2262
2689
|
class AccessSchedule < MetronomeSDK::Internal::Type::BaseModel
|
|
@@ -2627,6 +3054,13 @@ module MetronomeSDK
|
|
|
2627
3054
|
# @return [String, nil]
|
|
2628
3055
|
optional :custom_credit_type_id, String, nil?: true
|
|
2629
3056
|
|
|
3057
|
+
# @!attribute discount_configuration
|
|
3058
|
+
#
|
|
3059
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdatePrepaidBalanceThresholdConfiguration::DiscountConfiguration, nil]
|
|
3060
|
+
optional :discount_configuration,
|
|
3061
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdatePrepaidBalanceThresholdConfiguration::DiscountConfiguration },
|
|
3062
|
+
nil?: true
|
|
3063
|
+
|
|
2630
3064
|
# @!attribute is_enabled
|
|
2631
3065
|
# When set to false, the contract will not be evaluated against the
|
|
2632
3066
|
# threshold_amount. Toggling to true will result an immediate evaluation,
|
|
@@ -2653,7 +3087,7 @@ module MetronomeSDK
|
|
|
2653
3087
|
# @return [Float, nil]
|
|
2654
3088
|
optional :threshold_amount, Float
|
|
2655
3089
|
|
|
2656
|
-
# @!method initialize(commit: nil, custom_credit_type_id: nil, is_enabled: nil, payment_gate_config: nil, recharge_to_amount: nil, threshold_amount: nil)
|
|
3090
|
+
# @!method initialize(commit: nil, custom_credit_type_id: nil, discount_configuration: nil, is_enabled: nil, payment_gate_config: nil, recharge_to_amount: nil, threshold_amount: nil)
|
|
2657
3091
|
# Some parameter documentations has been truncated, see
|
|
2658
3092
|
# {MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdatePrepaidBalanceThresholdConfiguration}
|
|
2659
3093
|
# for more details.
|
|
@@ -2662,6 +3096,8 @@ module MetronomeSDK
|
|
|
2662
3096
|
#
|
|
2663
3097
|
# @param custom_credit_type_id [String, nil] If provided, the threshold, recharge-to amount, and the resulting threshold comm
|
|
2664
3098
|
#
|
|
3099
|
+
# @param discount_configuration [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdatePrepaidBalanceThresholdConfiguration::DiscountConfiguration, nil]
|
|
3100
|
+
#
|
|
2665
3101
|
# @param is_enabled [Boolean] When set to false, the contract will not be evaluated against the threshold_amou
|
|
2666
3102
|
#
|
|
2667
3103
|
# @param payment_gate_config [MetronomeSDK::Models::PaymentGateConfigV2]
|
|
@@ -2711,6 +3147,24 @@ module MetronomeSDK
|
|
|
2711
3147
|
#
|
|
2712
3148
|
# @param specifiers [Array<MetronomeSDK::Models::CommitSpecifierInput>, nil] List of filters that determine what kind of customer usage draws down a commit o
|
|
2713
3149
|
end
|
|
3150
|
+
|
|
3151
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdatePrepaidBalanceThresholdConfiguration#discount_configuration
|
|
3152
|
+
class DiscountConfiguration < MetronomeSDK::Internal::Type::BaseModel
|
|
3153
|
+
# @!attribute payment_fraction
|
|
3154
|
+
# The fraction of the original amount that the customer pays after applying the
|
|
3155
|
+
# discount. Set to null to remove the discount fraction. For example, 0.85 means
|
|
3156
|
+
# the customer pays 85% of the original amount (a 15% discount).
|
|
3157
|
+
#
|
|
3158
|
+
# @return [Float, nil]
|
|
3159
|
+
optional :payment_fraction, Float, nil?: true
|
|
3160
|
+
|
|
3161
|
+
# @!method initialize(payment_fraction: nil)
|
|
3162
|
+
# Some parameter documentations has been truncated, see
|
|
3163
|
+
# {MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdatePrepaidBalanceThresholdConfiguration::DiscountConfiguration}
|
|
3164
|
+
# for more details.
|
|
3165
|
+
#
|
|
3166
|
+
# @param payment_fraction [Float, nil] The fraction of the original amount that the customer pays after applying the di
|
|
3167
|
+
end
|
|
2714
3168
|
end
|
|
2715
3169
|
|
|
2716
3170
|
class UpdateRecurringCommit < MetronomeSDK::Internal::Type::BaseModel
|
|
@@ -3015,6 +3469,13 @@ module MetronomeSDK
|
|
|
3015
3469
|
# @return [MetronomeSDK::Models::UpdateBaseThresholdCommit, nil]
|
|
3016
3470
|
optional :commit, -> { MetronomeSDK::UpdateBaseThresholdCommit }
|
|
3017
3471
|
|
|
3472
|
+
# @!attribute discount_configuration
|
|
3473
|
+
#
|
|
3474
|
+
# @return [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateSpendThresholdConfiguration::DiscountConfiguration, nil]
|
|
3475
|
+
optional :discount_configuration,
|
|
3476
|
+
-> { MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateSpendThresholdConfiguration::DiscountConfiguration },
|
|
3477
|
+
nil?: true
|
|
3478
|
+
|
|
3018
3479
|
# @!attribute is_enabled
|
|
3019
3480
|
# When set to false, the contract will not be evaluated against the
|
|
3020
3481
|
# threshold_amount. Toggling to true will result an immediate evaluation,
|
|
@@ -3035,18 +3496,38 @@ module MetronomeSDK
|
|
|
3035
3496
|
# @return [Float, nil]
|
|
3036
3497
|
optional :threshold_amount, Float
|
|
3037
3498
|
|
|
3038
|
-
# @!method initialize(commit: nil, is_enabled: nil, payment_gate_config: nil, threshold_amount: nil)
|
|
3499
|
+
# @!method initialize(commit: nil, discount_configuration: nil, is_enabled: nil, payment_gate_config: nil, threshold_amount: nil)
|
|
3039
3500
|
# Some parameter documentations has been truncated, see
|
|
3040
3501
|
# {MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateSpendThresholdConfiguration}
|
|
3041
3502
|
# for more details.
|
|
3042
3503
|
#
|
|
3043
3504
|
# @param commit [MetronomeSDK::Models::UpdateBaseThresholdCommit]
|
|
3044
3505
|
#
|
|
3506
|
+
# @param discount_configuration [MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateSpendThresholdConfiguration::DiscountConfiguration, nil]
|
|
3507
|
+
#
|
|
3045
3508
|
# @param is_enabled [Boolean] When set to false, the contract will not be evaluated against the threshold_amou
|
|
3046
3509
|
#
|
|
3047
3510
|
# @param payment_gate_config [MetronomeSDK::Models::PaymentGateConfigV2]
|
|
3048
3511
|
#
|
|
3049
3512
|
# @param threshold_amount [Float] Specify the threshold amount for the contract. Each time the contract's usage hi
|
|
3513
|
+
|
|
3514
|
+
# @see MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateSpendThresholdConfiguration#discount_configuration
|
|
3515
|
+
class DiscountConfiguration < MetronomeSDK::Internal::Type::BaseModel
|
|
3516
|
+
# @!attribute payment_fraction
|
|
3517
|
+
# The fraction of the original amount that the customer pays after applying the
|
|
3518
|
+
# discount. Set to null to remove the discount fraction. For example, 0.85 means
|
|
3519
|
+
# the customer pays 85% of the original amount (a 15% discount).
|
|
3520
|
+
#
|
|
3521
|
+
# @return [Float, nil]
|
|
3522
|
+
optional :payment_fraction, Float, nil?: true
|
|
3523
|
+
|
|
3524
|
+
# @!method initialize(payment_fraction: nil)
|
|
3525
|
+
# Some parameter documentations has been truncated, see
|
|
3526
|
+
# {MetronomeSDK::Models::V2::ContractGetEditHistoryResponse::Data::UpdateSpendThresholdConfiguration::DiscountConfiguration}
|
|
3527
|
+
# for more details.
|
|
3528
|
+
#
|
|
3529
|
+
# @param payment_fraction [Float, nil] The fraction of the original amount that the customer pays after applying the di
|
|
3530
|
+
end
|
|
3050
3531
|
end
|
|
3051
3532
|
|
|
3052
3533
|
class UpdateSubscription < MetronomeSDK::Internal::Type::BaseModel
|