metronome-sdk 0.1.0 → 0.2.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 +14 -0
- data/README.md +1 -1
- data/lib/metronome_sdk/internal/transport/base_client.rb +1 -1
- data/lib/metronome_sdk/models/commit.rb +35 -5
- data/lib/metronome_sdk/models/contract_without_amendments.rb +128 -2
- data/lib/metronome_sdk/models/credit.rb +21 -3
- data/lib/metronome_sdk/models/v1/alert_create_params.rb +9 -11
- data/lib/metronome_sdk/models/v1/contract_create_params.rb +159 -12
- data/lib/metronome_sdk/models/v1/customers/customer_alert.rb +29 -1
- data/lib/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rb +2 -0
- data/lib/metronome_sdk/models/v2/contract_edit_commit_params.rb +2 -0
- data/lib/metronome_sdk/models/v2/contract_edit_credit_params.rb +2 -0
- data/lib/metronome_sdk/models/v2/contract_edit_params.rb +183 -24
- data/lib/metronome_sdk/models/v2/contract_get_edit_history_response.rb +570 -14
- data/lib/metronome_sdk/models/v2/contract_list_response.rb +194 -17
- data/lib/metronome_sdk/models/v2/contract_retrieve_response.rb +194 -17
- data/lib/metronome_sdk/resources/v1/alerts.rb +2 -2
- data/lib/metronome_sdk/version.rb +1 -1
- data/rbi/metronome_sdk/internal/transport/base_client.rbi +1 -1
- data/rbi/metronome_sdk/models/commit.rbi +89 -15
- data/rbi/metronome_sdk/models/contract_without_amendments.rbi +304 -6
- data/rbi/metronome_sdk/models/credit.rbi +54 -9
- data/rbi/metronome_sdk/models/v1/alert_create_params.rbi +16 -18
- data/rbi/metronome_sdk/models/v1/contract_create_params.rbi +349 -15
- data/rbi/metronome_sdk/models/v1/customers/customer_alert.rbi +60 -0
- data/rbi/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rbi +10 -0
- data/rbi/metronome_sdk/models/v2/contract_edit_commit_params.rbi +4 -0
- data/rbi/metronome_sdk/models/v2/contract_edit_credit_params.rbi +4 -0
- data/rbi/metronome_sdk/models/v2/contract_edit_params.rbi +385 -27
- data/rbi/metronome_sdk/models/v2/contract_get_edit_history_response.rbi +1532 -42
- data/rbi/metronome_sdk/models/v2/contract_list_response.rbi +431 -37
- data/rbi/metronome_sdk/models/v2/contract_retrieve_response.rbi +431 -37
- data/rbi/metronome_sdk/resources/v1/alerts.rbi +5 -5
- data/rbi/metronome_sdk/resources/v2/contracts.rbi +4 -0
- data/sig/metronome_sdk/internal/transport/base_client.rbs +1 -1
- data/sig/metronome_sdk/models/commit.rbs +50 -15
- data/sig/metronome_sdk/models/contract_without_amendments.rbs +120 -6
- data/sig/metronome_sdk/models/credit.rbs +30 -9
- data/sig/metronome_sdk/models/v1/alert_create_params.rbs +9 -9
- data/sig/metronome_sdk/models/v1/contract_create_params.rbs +130 -3
- data/sig/metronome_sdk/models/v1/customers/customer_alert.rbs +21 -0
- data/sig/metronome_sdk/models/v1/dashboard_get_embeddable_url_params.rbs +4 -0
- data/sig/metronome_sdk/models/v2/contract_edit_params.rbs +130 -3
- data/sig/metronome_sdk/models/v2/contract_get_edit_history_response.rbs +612 -6
- data/sig/metronome_sdk/models/v2/contract_list_response.rbs +205 -30
- data/sig/metronome_sdk/models/v2/contract_retrieve_response.rbs +205 -30
- data/sig/metronome_sdk/resources/v1/alerts.rbs +1 -1
- metadata +2 -2
@@ -413,6 +413,8 @@ module MetronomeSDK
|
|
413
413
|
# or credit. A customer's usage needs to meet the condition of at least one of the
|
414
414
|
# specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
415
415
|
# be used together with `applicable_product_ids` or `applicable_product_tags`.
|
416
|
+
# Instead, to target usage by product or product tag, pass those values in the
|
417
|
+
# body of `specifiers`.
|
416
418
|
#
|
417
419
|
# @return [Array<MetronomeSDK::Models::V2::ContractEditParams::AddCommit::Specifier>, nil]
|
418
420
|
optional :specifiers,
|
@@ -642,7 +644,7 @@ module MetronomeSDK
|
|
642
644
|
# @see MetronomeSDK::Models::V2::ContractEditParams::AddCommit#invoice_schedule
|
643
645
|
class InvoiceSchedule < MetronomeSDK::Internal::Type::BaseModel
|
644
646
|
# @!attribute credit_type_id
|
645
|
-
# Defaults to USD if not passed.
|
647
|
+
# Defaults to USD (cents) if not passed.
|
646
648
|
#
|
647
649
|
# @return [String, nil]
|
648
650
|
optional :credit_type_id, String
|
@@ -677,7 +679,7 @@ module MetronomeSDK
|
|
677
679
|
# amount. Optional for "PREPAID" commits: if not provided, this will be a
|
678
680
|
# "complimentary" commit with no invoice.
|
679
681
|
#
|
680
|
-
# @param credit_type_id [String] Defaults to USD if not passed.
|
682
|
+
# @param credit_type_id [String] Defaults to USD (cents) if not passed.
|
681
683
|
#
|
682
684
|
# @param recurring_schedule [MetronomeSDK::Models::V2::ContractEditParams::AddCommit::InvoiceSchedule::RecurringSchedule] Enter the unit price and quantity for the charge or instead only send the amount
|
683
685
|
#
|
@@ -1116,6 +1118,8 @@ module MetronomeSDK
|
|
1116
1118
|
# or credit. A customer's usage needs to meet the condition of at least one of the
|
1117
1119
|
# specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
1118
1120
|
# be used together with `applicable_product_ids` or `applicable_product_tags`.
|
1121
|
+
# Instead, to target usage by product or product tag, pass those values in the
|
1122
|
+
# body of `specifiers`.
|
1119
1123
|
#
|
1120
1124
|
# @return [Array<MetronomeSDK::Models::V2::ContractEditParams::AddCredit::Specifier>, nil]
|
1121
1125
|
optional :specifiers,
|
@@ -1403,7 +1407,7 @@ module MetronomeSDK
|
|
1403
1407
|
# @see MetronomeSDK::Models::V2::ContractEditParams::AddDiscount#schedule
|
1404
1408
|
class Schedule < MetronomeSDK::Internal::Type::BaseModel
|
1405
1409
|
# @!attribute credit_type_id
|
1406
|
-
# Defaults to USD if not passed.
|
1410
|
+
# Defaults to USD (cents) if not passed.
|
1407
1411
|
#
|
1408
1412
|
# @return [String, nil]
|
1409
1413
|
optional :credit_type_id, String
|
@@ -1433,7 +1437,7 @@ module MetronomeSDK
|
|
1433
1437
|
#
|
1434
1438
|
# Must provide either schedule_items or recurring_schedule.
|
1435
1439
|
#
|
1436
|
-
# @param credit_type_id [String] Defaults to USD if not passed.
|
1440
|
+
# @param credit_type_id [String] Defaults to USD (cents) if not passed.
|
1437
1441
|
#
|
1438
1442
|
# @param recurring_schedule [MetronomeSDK::Models::V2::ContractEditParams::AddDiscount::Schedule::RecurringSchedule] Enter the unit price and quantity for the charge or instead only send the amount
|
1439
1443
|
#
|
@@ -2042,6 +2046,8 @@ module MetronomeSDK
|
|
2042
2046
|
# or credit. A customer's usage needs to meet the condition of at least one of the
|
2043
2047
|
# specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
2044
2048
|
# be used together with `applicable_product_ids` or `applicable_product_tags`.
|
2049
|
+
# Instead, to target usage by product or product tag, pass those values in the
|
2050
|
+
# body of `specifiers`.
|
2045
2051
|
#
|
2046
2052
|
# @return [Array<MetronomeSDK::Models::V2::ContractEditParams::AddPrepaidBalanceThresholdConfiguration::Commit::Specifier>, nil]
|
2047
2053
|
optional :specifiers,
|
@@ -2393,7 +2399,7 @@ module MetronomeSDK
|
|
2393
2399
|
optional :ending_before, Time
|
2394
2400
|
|
2395
2401
|
# @!attribute hierarchy_configuration
|
2396
|
-
# Optional configuration for recurring
|
2402
|
+
# Optional configuration for recurring credit hierarchy access control
|
2397
2403
|
#
|
2398
2404
|
# @return [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::HierarchyConfiguration, nil]
|
2399
2405
|
optional :hierarchy_configuration,
|
@@ -2460,6 +2466,8 @@ module MetronomeSDK
|
|
2460
2466
|
# or credit. A customer's usage needs to meet the condition of at least one of the
|
2461
2467
|
# specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
2462
2468
|
# be used together with `applicable_product_ids` or `applicable_product_tags`.
|
2469
|
+
# Instead, to target usage by product or product tag, pass those values in the
|
2470
|
+
# body of `specifiers`.
|
2463
2471
|
#
|
2464
2472
|
# @return [Array<MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::Specifier>, nil]
|
2465
2473
|
optional :specifiers,
|
@@ -2467,6 +2475,13 @@ module MetronomeSDK
|
|
2467
2475
|
MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::V2::ContractEditParams::AddRecurringCommit::Specifier]
|
2468
2476
|
}
|
2469
2477
|
|
2478
|
+
# @!attribute subscription_config
|
2479
|
+
# Attach a subscription to the recurring commit/credit.
|
2480
|
+
#
|
2481
|
+
# @return [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig, nil]
|
2482
|
+
optional :subscription_config,
|
2483
|
+
-> { MetronomeSDK::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig }
|
2484
|
+
|
2470
2485
|
# @!attribute temporary_id
|
2471
2486
|
# A temporary ID that can be used to reference the recurring commit for commit
|
2472
2487
|
# specific overrides.
|
@@ -2474,7 +2489,7 @@ module MetronomeSDK
|
|
2474
2489
|
# @return [String, nil]
|
2475
2490
|
optional :temporary_id, String
|
2476
2491
|
|
2477
|
-
# @!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, temporary_id: nil)
|
2492
|
+
# @!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)
|
2478
2493
|
# Some parameter documentations has been truncated, see
|
2479
2494
|
# {MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit} for more
|
2480
2495
|
# details.
|
@@ -2497,7 +2512,7 @@ module MetronomeSDK
|
|
2497
2512
|
#
|
2498
2513
|
# @param ending_before [Time] Determines when the contract will stop creating recurring commits. optional
|
2499
2514
|
#
|
2500
|
-
# @param hierarchy_configuration [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::HierarchyConfiguration] Optional configuration for recurring
|
2515
|
+
# @param hierarchy_configuration [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::HierarchyConfiguration] Optional configuration for recurring credit hierarchy access control
|
2501
2516
|
#
|
2502
2517
|
# @param invoice_amount [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::InvoiceAmount] The amount the customer should be billed for the commit. Not required.
|
2503
2518
|
#
|
@@ -2515,6 +2530,8 @@ module MetronomeSDK
|
|
2515
2530
|
#
|
2516
2531
|
# @param specifiers [Array<MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::Specifier>] List of filters that determine what kind of customer usage draws down a commit o
|
2517
2532
|
#
|
2533
|
+
# @param subscription_config [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig] Attach a subscription to the recurring commit/credit.
|
2534
|
+
#
|
2518
2535
|
# @param temporary_id [String] A temporary ID that can be used to reference the recurring commit for commit spe
|
2519
2536
|
|
2520
2537
|
# @see MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit#access_amount
|
@@ -2595,7 +2612,7 @@ module MetronomeSDK
|
|
2595
2612
|
}
|
2596
2613
|
|
2597
2614
|
# @!method initialize(child_access:)
|
2598
|
-
# Optional configuration for recurring
|
2615
|
+
# Optional configuration for recurring credit hierarchy access control
|
2599
2616
|
#
|
2600
2617
|
# @param child_access [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::HierarchyConfiguration::ChildAccess::CommitHierarchyChildAccessAll, MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::HierarchyConfiguration::ChildAccess::CommitHierarchyChildAccessNone, MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::HierarchyConfiguration::ChildAccess::CommitHierarchyChildAccessContractIDs]
|
2601
2618
|
|
@@ -2805,6 +2822,65 @@ module MetronomeSDK
|
|
2805
2822
|
#
|
2806
2823
|
# @param product_tags [Array<String>] If provided, the specifier will only apply to products with all the specified ta
|
2807
2824
|
end
|
2825
|
+
|
2826
|
+
# @see MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit#subscription_config
|
2827
|
+
class SubscriptionConfig < MetronomeSDK::Internal::Type::BaseModel
|
2828
|
+
# @!attribute apply_seat_increase_config
|
2829
|
+
#
|
2830
|
+
# @return [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig::ApplySeatIncreaseConfig]
|
2831
|
+
required :apply_seat_increase_config,
|
2832
|
+
-> {
|
2833
|
+
MetronomeSDK::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig::ApplySeatIncreaseConfig
|
2834
|
+
}
|
2835
|
+
|
2836
|
+
# @!attribute subscription_id
|
2837
|
+
# ID of the subscription to configure on the recurring commit/credit.
|
2838
|
+
#
|
2839
|
+
# @return [String]
|
2840
|
+
required :subscription_id, String
|
2841
|
+
|
2842
|
+
# @!attribute allocation
|
2843
|
+
# If set to POOLED, allocation added per seat is pooled across the account.
|
2844
|
+
#
|
2845
|
+
# @return [Symbol, MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig::Allocation, nil]
|
2846
|
+
optional :allocation,
|
2847
|
+
enum: -> {
|
2848
|
+
MetronomeSDK::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig::Allocation
|
2849
|
+
}
|
2850
|
+
|
2851
|
+
# @!method initialize(apply_seat_increase_config:, subscription_id:, allocation: nil)
|
2852
|
+
# Attach a subscription to the recurring commit/credit.
|
2853
|
+
#
|
2854
|
+
# @param apply_seat_increase_config [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig::ApplySeatIncreaseConfig]
|
2855
|
+
#
|
2856
|
+
# @param subscription_id [String] ID of the subscription to configure on the recurring commit/credit.
|
2857
|
+
#
|
2858
|
+
# @param allocation [Symbol, MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig::Allocation] If set to POOLED, allocation added per seat is pooled across the account.
|
2859
|
+
|
2860
|
+
# @see MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig#apply_seat_increase_config
|
2861
|
+
class ApplySeatIncreaseConfig < MetronomeSDK::Internal::Type::BaseModel
|
2862
|
+
# @!attribute is_prorated
|
2863
|
+
# Indicates whether a mid-period seat increase should be prorated.
|
2864
|
+
#
|
2865
|
+
# @return [Boolean]
|
2866
|
+
required :is_prorated, MetronomeSDK::Internal::Type::Boolean
|
2867
|
+
|
2868
|
+
# @!method initialize(is_prorated:)
|
2869
|
+
# @param is_prorated [Boolean] Indicates whether a mid-period seat increase should be prorated.
|
2870
|
+
end
|
2871
|
+
|
2872
|
+
# If set to POOLED, allocation added per seat is pooled across the account.
|
2873
|
+
#
|
2874
|
+
# @see MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCommit::SubscriptionConfig#allocation
|
2875
|
+
module Allocation
|
2876
|
+
extend MetronomeSDK::Internal::Type::Enum
|
2877
|
+
|
2878
|
+
POOLED = :POOLED
|
2879
|
+
|
2880
|
+
# @!method self.values
|
2881
|
+
# @return [Array<Symbol>]
|
2882
|
+
end
|
2883
|
+
end
|
2808
2884
|
end
|
2809
2885
|
|
2810
2886
|
class AddRecurringCredit < MetronomeSDK::Internal::Type::BaseModel
|
@@ -2870,7 +2946,7 @@ module MetronomeSDK
|
|
2870
2946
|
optional :ending_before, Time
|
2871
2947
|
|
2872
2948
|
# @!attribute hierarchy_configuration
|
2873
|
-
# Optional configuration for recurring
|
2949
|
+
# Optional configuration for recurring credit hierarchy access control
|
2874
2950
|
#
|
2875
2951
|
# @return [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::HierarchyConfiguration, nil]
|
2876
2952
|
optional :hierarchy_configuration,
|
@@ -2928,6 +3004,8 @@ module MetronomeSDK
|
|
2928
3004
|
# or credit. A customer's usage needs to meet the condition of at least one of the
|
2929
3005
|
# specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
2930
3006
|
# be used together with `applicable_product_ids` or `applicable_product_tags`.
|
3007
|
+
# Instead, to target usage by product or product tag, pass those values in the
|
3008
|
+
# body of `specifiers`.
|
2931
3009
|
#
|
2932
3010
|
# @return [Array<MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::Specifier>, nil]
|
2933
3011
|
optional :specifiers,
|
@@ -2935,6 +3013,13 @@ module MetronomeSDK
|
|
2935
3013
|
MetronomeSDK::Internal::Type::ArrayOf[MetronomeSDK::V2::ContractEditParams::AddRecurringCredit::Specifier]
|
2936
3014
|
}
|
2937
3015
|
|
3016
|
+
# @!attribute subscription_config
|
3017
|
+
# Attach a subscription to the recurring commit/credit.
|
3018
|
+
#
|
3019
|
+
# @return [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig, nil]
|
3020
|
+
optional :subscription_config,
|
3021
|
+
-> { MetronomeSDK::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig }
|
3022
|
+
|
2938
3023
|
# @!attribute temporary_id
|
2939
3024
|
# A temporary ID that can be used to reference the recurring commit for commit
|
2940
3025
|
# specific overrides.
|
@@ -2942,7 +3027,7 @@ module MetronomeSDK
|
|
2942
3027
|
# @return [String, nil]
|
2943
3028
|
optional :temporary_id, String
|
2944
3029
|
|
2945
|
-
# @!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, temporary_id: nil)
|
3030
|
+
# @!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)
|
2946
3031
|
# Some parameter documentations has been truncated, see
|
2947
3032
|
# {MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit} for more
|
2948
3033
|
# details.
|
@@ -2965,7 +3050,7 @@ module MetronomeSDK
|
|
2965
3050
|
#
|
2966
3051
|
# @param ending_before [Time] Determines when the contract will stop creating recurring commits. optional
|
2967
3052
|
#
|
2968
|
-
# @param hierarchy_configuration [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::HierarchyConfiguration] Optional configuration for recurring
|
3053
|
+
# @param hierarchy_configuration [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::HierarchyConfiguration] Optional configuration for recurring credit hierarchy access control
|
2969
3054
|
#
|
2970
3055
|
# @param name [String] displayed on invoices. will be passed through to the individual commits
|
2971
3056
|
#
|
@@ -2981,6 +3066,8 @@ module MetronomeSDK
|
|
2981
3066
|
#
|
2982
3067
|
# @param specifiers [Array<MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::Specifier>] List of filters that determine what kind of customer usage draws down a commit o
|
2983
3068
|
#
|
3069
|
+
# @param subscription_config [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig] Attach a subscription to the recurring commit/credit.
|
3070
|
+
#
|
2984
3071
|
# @param temporary_id [String] A temporary ID that can be used to reference the recurring commit for commit spe
|
2985
3072
|
|
2986
3073
|
# @see MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit#access_amount
|
@@ -3061,7 +3148,7 @@ module MetronomeSDK
|
|
3061
3148
|
}
|
3062
3149
|
|
3063
3150
|
# @!method initialize(child_access:)
|
3064
|
-
# Optional configuration for recurring
|
3151
|
+
# Optional configuration for recurring credit hierarchy access control
|
3065
3152
|
#
|
3066
3153
|
# @param child_access [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::HierarchyConfiguration::ChildAccess::CommitHierarchyChildAccessAll, MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::HierarchyConfiguration::ChildAccess::CommitHierarchyChildAccessNone, MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::HierarchyConfiguration::ChildAccess::CommitHierarchyChildAccessContractIDs]
|
3067
3154
|
|
@@ -3246,6 +3333,65 @@ module MetronomeSDK
|
|
3246
3333
|
#
|
3247
3334
|
# @param product_tags [Array<String>] If provided, the specifier will only apply to products with all the specified ta
|
3248
3335
|
end
|
3336
|
+
|
3337
|
+
# @see MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit#subscription_config
|
3338
|
+
class SubscriptionConfig < MetronomeSDK::Internal::Type::BaseModel
|
3339
|
+
# @!attribute apply_seat_increase_config
|
3340
|
+
#
|
3341
|
+
# @return [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig::ApplySeatIncreaseConfig]
|
3342
|
+
required :apply_seat_increase_config,
|
3343
|
+
-> {
|
3344
|
+
MetronomeSDK::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig::ApplySeatIncreaseConfig
|
3345
|
+
}
|
3346
|
+
|
3347
|
+
# @!attribute subscription_id
|
3348
|
+
# ID of the subscription to configure on the recurring commit/credit.
|
3349
|
+
#
|
3350
|
+
# @return [String]
|
3351
|
+
required :subscription_id, String
|
3352
|
+
|
3353
|
+
# @!attribute allocation
|
3354
|
+
# If set to POOLED, allocation added per seat is pooled across the account.
|
3355
|
+
#
|
3356
|
+
# @return [Symbol, MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig::Allocation, nil]
|
3357
|
+
optional :allocation,
|
3358
|
+
enum: -> {
|
3359
|
+
MetronomeSDK::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig::Allocation
|
3360
|
+
}
|
3361
|
+
|
3362
|
+
# @!method initialize(apply_seat_increase_config:, subscription_id:, allocation: nil)
|
3363
|
+
# Attach a subscription to the recurring commit/credit.
|
3364
|
+
#
|
3365
|
+
# @param apply_seat_increase_config [MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig::ApplySeatIncreaseConfig]
|
3366
|
+
#
|
3367
|
+
# @param subscription_id [String] ID of the subscription to configure on the recurring commit/credit.
|
3368
|
+
#
|
3369
|
+
# @param allocation [Symbol, MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig::Allocation] If set to POOLED, allocation added per seat is pooled across the account.
|
3370
|
+
|
3371
|
+
# @see MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig#apply_seat_increase_config
|
3372
|
+
class ApplySeatIncreaseConfig < MetronomeSDK::Internal::Type::BaseModel
|
3373
|
+
# @!attribute is_prorated
|
3374
|
+
# Indicates whether a mid-period seat increase should be prorated.
|
3375
|
+
#
|
3376
|
+
# @return [Boolean]
|
3377
|
+
required :is_prorated, MetronomeSDK::Internal::Type::Boolean
|
3378
|
+
|
3379
|
+
# @!method initialize(is_prorated:)
|
3380
|
+
# @param is_prorated [Boolean] Indicates whether a mid-period seat increase should be prorated.
|
3381
|
+
end
|
3382
|
+
|
3383
|
+
# If set to POOLED, allocation added per seat is pooled across the account.
|
3384
|
+
#
|
3385
|
+
# @see MetronomeSDK::Models::V2::ContractEditParams::AddRecurringCredit::SubscriptionConfig#allocation
|
3386
|
+
module Allocation
|
3387
|
+
extend MetronomeSDK::Internal::Type::Enum
|
3388
|
+
|
3389
|
+
POOLED = :POOLED
|
3390
|
+
|
3391
|
+
# @!method self.values
|
3392
|
+
# @return [Array<Symbol>]
|
3393
|
+
end
|
3394
|
+
end
|
3249
3395
|
end
|
3250
3396
|
|
3251
3397
|
class AddResellerRoyalty < MetronomeSDK::Internal::Type::BaseModel
|
@@ -3414,7 +3560,7 @@ module MetronomeSDK
|
|
3414
3560
|
# @see MetronomeSDK::Models::V2::ContractEditParams::AddScheduledCharge#schedule
|
3415
3561
|
class Schedule < MetronomeSDK::Internal::Type::BaseModel
|
3416
3562
|
# @!attribute credit_type_id
|
3417
|
-
# Defaults to USD if not passed.
|
3563
|
+
# Defaults to USD (cents) if not passed.
|
3418
3564
|
#
|
3419
3565
|
# @return [String, nil]
|
3420
3566
|
optional :credit_type_id, String
|
@@ -3446,7 +3592,7 @@ module MetronomeSDK
|
|
3446
3592
|
#
|
3447
3593
|
# Must provide either schedule_items or recurring_schedule.
|
3448
3594
|
#
|
3449
|
-
# @param credit_type_id [String] Defaults to USD if not passed.
|
3595
|
+
# @param credit_type_id [String] Defaults to USD (cents) if not passed.
|
3450
3596
|
#
|
3451
3597
|
# @param recurring_schedule [MetronomeSDK::Models::V2::ContractEditParams::AddScheduledCharge::Schedule::RecurringSchedule] Enter the unit price and quantity for the charge or instead only send the amount
|
3452
3598
|
#
|
@@ -3896,7 +4042,14 @@ module MetronomeSDK
|
|
3896
4042
|
# @return [Time, nil]
|
3897
4043
|
optional :starting_at, Time
|
3898
4044
|
|
3899
|
-
# @!
|
4045
|
+
# @!attribute temporary_id
|
4046
|
+
# A temporary ID used to reference the subscription in recurring commit/credit
|
4047
|
+
# subscription configs created within the same payload.
|
4048
|
+
#
|
4049
|
+
# @return [String, nil]
|
4050
|
+
optional :temporary_id, String
|
4051
|
+
|
4052
|
+
# @!method initialize(collection_schedule:, initial_quantity:, proration:, subscription_rate:, custom_fields: nil, description: nil, ending_before: nil, name: nil, starting_at: nil, temporary_id: nil)
|
3900
4053
|
# Some parameter documentations has been truncated, see
|
3901
4054
|
# {MetronomeSDK::Models::V2::ContractEditParams::AddSubscription} for more
|
3902
4055
|
# details.
|
@@ -3918,6 +4071,8 @@ module MetronomeSDK
|
|
3918
4071
|
# @param name [String]
|
3919
4072
|
#
|
3920
4073
|
# @param starting_at [Time] Inclusive start time for the subscription. If not provided, defaults to contract
|
4074
|
+
#
|
4075
|
+
# @param temporary_id [String] A temporary ID used to reference the subscription in recurring commit/credit sub
|
3921
4076
|
|
3922
4077
|
# @see MetronomeSDK::Models::V2::ContractEditParams::AddSubscription#collection_schedule
|
3923
4078
|
module CollectionSchedule
|
@@ -3933,10 +4088,11 @@ module MetronomeSDK
|
|
3933
4088
|
# @see MetronomeSDK::Models::V2::ContractEditParams::AddSubscription#proration
|
3934
4089
|
class Proration < MetronomeSDK::Internal::Type::BaseModel
|
3935
4090
|
# @!attribute invoice_behavior
|
3936
|
-
# Indicates how mid-period quantity adjustments are invoiced.
|
3937
|
-
#
|
3938
|
-
#
|
3939
|
-
#
|
4091
|
+
# Indicates how mid-period quantity adjustments are invoiced.
|
4092
|
+
# **BILL_IMMEDIATELY**: Only available when collection schedule is `ADVANCE`. The
|
4093
|
+
# quantity increase will be billed immediately on the scheduled date.
|
4094
|
+
# **BILL_ON_NEXT_COLLECTION_DATE**: The quantity increase will be billed for
|
4095
|
+
# in-arrears at the end of the period.
|
3940
4096
|
#
|
3941
4097
|
# @return [Symbol, MetronomeSDK::Models::V2::ContractEditParams::AddSubscription::Proration::InvoiceBehavior, nil]
|
3942
4098
|
optional :invoice_behavior,
|
@@ -3955,14 +4111,15 @@ module MetronomeSDK
|
|
3955
4111
|
# {MetronomeSDK::Models::V2::ContractEditParams::AddSubscription::Proration} for
|
3956
4112
|
# more details.
|
3957
4113
|
#
|
3958
|
-
# @param invoice_behavior [Symbol, MetronomeSDK::Models::V2::ContractEditParams::AddSubscription::Proration::InvoiceBehavior] Indicates how mid-period quantity adjustments are invoiced.
|
4114
|
+
# @param invoice_behavior [Symbol, MetronomeSDK::Models::V2::ContractEditParams::AddSubscription::Proration::InvoiceBehavior] Indicates how mid-period quantity adjustments are invoiced.
|
3959
4115
|
#
|
3960
4116
|
# @param is_prorated [Boolean] Indicates if the partial period will be prorated or charged a full amount.
|
3961
4117
|
|
3962
|
-
# Indicates how mid-period quantity adjustments are invoiced.
|
3963
|
-
#
|
3964
|
-
#
|
3965
|
-
#
|
4118
|
+
# Indicates how mid-period quantity adjustments are invoiced.
|
4119
|
+
# **BILL_IMMEDIATELY**: Only available when collection schedule is `ADVANCE`. The
|
4120
|
+
# quantity increase will be billed immediately on the scheduled date.
|
4121
|
+
# **BILL_ON_NEXT_COLLECTION_DATE**: The quantity increase will be billed for
|
4122
|
+
# in-arrears at the end of the period.
|
3966
4123
|
#
|
3967
4124
|
# @see MetronomeSDK::Models::V2::ContractEditParams::AddSubscription::Proration#invoice_behavior
|
3968
4125
|
module InvoiceBehavior
|
@@ -4817,6 +4974,8 @@ module MetronomeSDK
|
|
4817
4974
|
# or credit. A customer's usage needs to meet the condition of at least one of the
|
4818
4975
|
# specifiers to contribute to a commit's or credit's drawdown. This field cannot
|
4819
4976
|
# be used together with `applicable_product_ids` or `applicable_product_tags`.
|
4977
|
+
# Instead, to target usage by product or product tag, pass those values in the
|
4978
|
+
# body of `specifiers`.
|
4820
4979
|
#
|
4821
4980
|
# @return [Array<MetronomeSDK::Models::V2::ContractEditParams::UpdatePrepaidBalanceThresholdConfiguration::Commit::Specifier>, nil]
|
4822
4981
|
optional :specifiers,
|