metronome-sdk 3.8.0 → 3.9.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 +8 -0
- data/README.md +1 -1
- data/lib/metronome_sdk/models/contract.rb +46 -16
- data/lib/metronome_sdk/models/contract_v2.rb +355 -9
- data/lib/metronome_sdk/models/v1/contract_create_response.rb +65 -13
- data/lib/metronome_sdk/models/v2/contract_edit_params.rb +2 -0
- data/lib/metronome_sdk/version.rb +1 -1
- data/rbi/metronome_sdk/models/contract.rbi +47 -22
- data/rbi/metronome_sdk/models/contract_v2.rbi +672 -8
- data/rbi/metronome_sdk/models/v1/contract_create_response.rbi +60 -32
- data/rbi/metronome_sdk/models/v2/contract_edit_params.rbi +10 -0
- data/sig/metronome_sdk/models/contract.rbs +22 -11
- data/sig/metronome_sdk/models/contract_v2.rbs +281 -3
- data/sig/metronome_sdk/models/v1/contract_create_response.rbs +30 -15
- data/sig/metronome_sdk/models/v2/contract_edit_params.rbs +4 -2
- metadata +2 -2
|
@@ -103,7 +103,6 @@ module MetronomeSDK
|
|
|
103
103
|
optional :custom_fields, MetronomeSDK::Internal::Type::HashOf[String]
|
|
104
104
|
|
|
105
105
|
# @!attribute customer_billing_provider_configuration
|
|
106
|
-
# The billing provider configuration associated with the contract.
|
|
107
106
|
#
|
|
108
107
|
# @return [MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration, nil]
|
|
109
108
|
optional :customer_billing_provider_configuration,
|
|
@@ -238,7 +237,7 @@ module MetronomeSDK
|
|
|
238
237
|
#
|
|
239
238
|
# @param custom_fields [Hash{Symbol=>String}] Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
240
239
|
#
|
|
241
|
-
# @param customer_billing_provider_configuration [MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration]
|
|
240
|
+
# @param customer_billing_provider_configuration [MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration]
|
|
242
241
|
#
|
|
243
242
|
# @param ending_before [Time]
|
|
244
243
|
#
|
|
@@ -368,29 +367,80 @@ module MetronomeSDK
|
|
|
368
367
|
# @see MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract#customer_billing_provider_configuration
|
|
369
368
|
class CustomerBillingProviderConfiguration < MetronomeSDK::Internal::Type::BaseModel
|
|
370
369
|
# @!attribute id
|
|
370
|
+
# ID of this configuration; can be provided as the
|
|
371
|
+
# billing_provider_configuration_id when creating a contract.
|
|
371
372
|
#
|
|
372
|
-
# @return [String
|
|
373
|
-
|
|
373
|
+
# @return [String]
|
|
374
|
+
required :id, String
|
|
375
|
+
|
|
376
|
+
# @!attribute archived_at
|
|
377
|
+
#
|
|
378
|
+
# @return [Time, nil]
|
|
379
|
+
required :archived_at, Time, nil?: true
|
|
374
380
|
|
|
375
381
|
# @!attribute billing_provider
|
|
382
|
+
# The billing provider set for this configuration.
|
|
376
383
|
#
|
|
377
|
-
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration::BillingProvider
|
|
378
|
-
|
|
384
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration::BillingProvider]
|
|
385
|
+
required :billing_provider,
|
|
379
386
|
enum: -> { MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration::BillingProvider }
|
|
380
387
|
|
|
388
|
+
# @!attribute configuration
|
|
389
|
+
# Configuration for the billing provider. The structure of this object is specific
|
|
390
|
+
# to the billing provider.
|
|
391
|
+
#
|
|
392
|
+
# @return [Hash{Symbol=>Object}]
|
|
393
|
+
required :configuration, MetronomeSDK::Internal::Type::HashOf[MetronomeSDK::Internal::Type::Unknown]
|
|
394
|
+
|
|
395
|
+
# @!attribute customer_id
|
|
396
|
+
#
|
|
397
|
+
# @return [String]
|
|
398
|
+
required :customer_id, String
|
|
399
|
+
|
|
381
400
|
# @!attribute delivery_method
|
|
401
|
+
# The method to use for delivering invoices to this customer.
|
|
382
402
|
#
|
|
383
|
-
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration::DeliveryMethod
|
|
384
|
-
|
|
403
|
+
# @return [Symbol, MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration::DeliveryMethod]
|
|
404
|
+
required :delivery_method,
|
|
385
405
|
enum: -> { MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration::DeliveryMethod }
|
|
386
406
|
|
|
387
|
-
# @!
|
|
388
|
-
# The
|
|
407
|
+
# @!attribute delivery_method_configuration
|
|
408
|
+
# Configuration for the delivery method. The structure of this object is specific
|
|
409
|
+
# to the delivery method.
|
|
389
410
|
#
|
|
390
|
-
# @
|
|
391
|
-
|
|
392
|
-
|
|
411
|
+
# @return [Hash{Symbol=>Object}]
|
|
412
|
+
required :delivery_method_configuration,
|
|
413
|
+
MetronomeSDK::Internal::Type::HashOf[MetronomeSDK::Internal::Type::Unknown]
|
|
414
|
+
|
|
415
|
+
# @!attribute delivery_method_id
|
|
416
|
+
# ID of the delivery method to use for this customer.
|
|
417
|
+
#
|
|
418
|
+
# @return [String]
|
|
419
|
+
required :delivery_method_id, String
|
|
420
|
+
|
|
421
|
+
# @!method initialize(id:, archived_at:, billing_provider:, configuration:, customer_id:, delivery_method:, delivery_method_configuration:, delivery_method_id:)
|
|
422
|
+
# Some parameter documentations has been truncated, see
|
|
423
|
+
# {MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration}
|
|
424
|
+
# for more details.
|
|
425
|
+
#
|
|
426
|
+
# @param id [String] ID of this configuration; can be provided as the billing*provider_configuration*
|
|
427
|
+
#
|
|
428
|
+
# @param archived_at [Time, nil]
|
|
429
|
+
#
|
|
430
|
+
# @param billing_provider [Symbol, MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration::BillingProvider] The billing provider set for this configuration.
|
|
431
|
+
#
|
|
432
|
+
# @param configuration [Hash{Symbol=>Object}] Configuration for the billing provider. The structure of this object is specific
|
|
433
|
+
#
|
|
434
|
+
# @param customer_id [String]
|
|
435
|
+
#
|
|
436
|
+
# @param delivery_method [Symbol, MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration::DeliveryMethod] The method to use for delivering invoices to this customer.
|
|
437
|
+
#
|
|
438
|
+
# @param delivery_method_configuration [Hash{Symbol=>Object}] Configuration for the delivery method. The structure of this object is specific
|
|
439
|
+
#
|
|
440
|
+
# @param delivery_method_id [String] ID of the delivery method to use for this customer.
|
|
393
441
|
|
|
442
|
+
# The billing provider set for this configuration.
|
|
443
|
+
#
|
|
394
444
|
# @see MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration#billing_provider
|
|
395
445
|
module BillingProvider
|
|
396
446
|
extend MetronomeSDK::Internal::Type::Enum
|
|
@@ -409,6 +459,8 @@ module MetronomeSDK
|
|
|
409
459
|
# @return [Array<Symbol>]
|
|
410
460
|
end
|
|
411
461
|
|
|
462
|
+
# The method to use for delivering invoices to this customer.
|
|
463
|
+
#
|
|
412
464
|
# @see MetronomeSDK::Models::V1::ContractCreateResponse::Data::Contract::CustomerBillingProviderConfiguration#delivery_method
|
|
413
465
|
module DeliveryMethod
|
|
414
466
|
extend MetronomeSDK::Internal::Type::Enum
|
|
@@ -427,6 +427,7 @@ module MetronomeSDK
|
|
|
427
427
|
extend MetronomeSDK::Internal::Type::Enum
|
|
428
428
|
|
|
429
429
|
START_OF_CURRENT_PERIOD = :START_OF_CURRENT_PERIOD
|
|
430
|
+
START_OF_NEXT_PERIOD = :START_OF_NEXT_PERIOD
|
|
430
431
|
|
|
431
432
|
# @!method self.values
|
|
432
433
|
# @return [Array<Symbol>]
|
|
@@ -2998,6 +2999,7 @@ module MetronomeSDK
|
|
|
2998
2999
|
extend MetronomeSDK::Internal::Type::Enum
|
|
2999
3000
|
|
|
3000
3001
|
START_OF_CURRENT_PERIOD = :START_OF_CURRENT_PERIOD
|
|
3002
|
+
START_OF_NEXT_PERIOD = :START_OF_NEXT_PERIOD
|
|
3001
3003
|
|
|
3002
3004
|
# @!method self.values
|
|
3003
3005
|
# @return [Array<Symbol>]
|
|
@@ -48,7 +48,6 @@ module MetronomeSDK
|
|
|
48
48
|
sig { params(custom_fields: T::Hash[Symbol, String]).void }
|
|
49
49
|
attr_writer :custom_fields
|
|
50
50
|
|
|
51
|
-
# The billing provider configuration associated with a contract.
|
|
52
51
|
sig do
|
|
53
52
|
returns(
|
|
54
53
|
T.nilable(
|
|
@@ -183,7 +182,6 @@ module MetronomeSDK
|
|
|
183
182
|
archived_at: nil,
|
|
184
183
|
# Custom fields to be added eg. { "key1": "value1", "key2": "value2" }
|
|
185
184
|
custom_fields: nil,
|
|
186
|
-
# The billing provider configuration associated with a contract.
|
|
187
185
|
customer_billing_provider_configuration: nil,
|
|
188
186
|
# ID of the package this contract was created from, if applicable.
|
|
189
187
|
package_id: nil,
|
|
@@ -567,9 +565,15 @@ module MetronomeSDK
|
|
|
567
565
|
)
|
|
568
566
|
end
|
|
569
567
|
|
|
568
|
+
# ID of this configuration; can be provided as the
|
|
569
|
+
# billing_provider_configuration_id when creating a contract.
|
|
570
|
+
sig { returns(String) }
|
|
571
|
+
attr_accessor :id
|
|
572
|
+
|
|
570
573
|
sig { returns(T.nilable(Time)) }
|
|
571
574
|
attr_accessor :archived_at
|
|
572
575
|
|
|
576
|
+
# The billing provider set for this configuration.
|
|
573
577
|
sig do
|
|
574
578
|
returns(
|
|
575
579
|
MetronomeSDK::Contract::CustomerBillingProviderConfiguration::BillingProvider::TaggedSymbol
|
|
@@ -577,6 +581,15 @@ module MetronomeSDK
|
|
|
577
581
|
end
|
|
578
582
|
attr_accessor :billing_provider
|
|
579
583
|
|
|
584
|
+
# Configuration for the billing provider. The structure of this object is specific
|
|
585
|
+
# to the billing provider.
|
|
586
|
+
sig { returns(T::Hash[Symbol, T.anything]) }
|
|
587
|
+
attr_accessor :configuration
|
|
588
|
+
|
|
589
|
+
sig { returns(String) }
|
|
590
|
+
attr_accessor :customer_id
|
|
591
|
+
|
|
592
|
+
# The method to use for delivering invoices to this customer.
|
|
580
593
|
sig do
|
|
581
594
|
returns(
|
|
582
595
|
MetronomeSDK::Contract::CustomerBillingProviderConfiguration::DeliveryMethod::TaggedSymbol
|
|
@@ -584,59 +597,70 @@ module MetronomeSDK
|
|
|
584
597
|
end
|
|
585
598
|
attr_accessor :delivery_method
|
|
586
599
|
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
attr_writer :id
|
|
592
|
-
|
|
593
|
-
# Configuration for the billing provider. The structure of this object is specific
|
|
594
|
-
# to the billing provider.
|
|
595
|
-
sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
|
|
596
|
-
attr_reader :configuration
|
|
600
|
+
# Configuration for the delivery method. The structure of this object is specific
|
|
601
|
+
# to the delivery method.
|
|
602
|
+
sig { returns(T::Hash[Symbol, T.anything]) }
|
|
603
|
+
attr_accessor :delivery_method_configuration
|
|
597
604
|
|
|
598
|
-
|
|
599
|
-
|
|
605
|
+
# ID of the delivery method to use for this customer.
|
|
606
|
+
sig { returns(String) }
|
|
607
|
+
attr_accessor :delivery_method_id
|
|
600
608
|
|
|
601
|
-
# The billing provider configuration associated with a contract.
|
|
602
609
|
sig do
|
|
603
610
|
params(
|
|
611
|
+
id: String,
|
|
604
612
|
archived_at: T.nilable(Time),
|
|
605
613
|
billing_provider:
|
|
606
614
|
MetronomeSDK::Contract::CustomerBillingProviderConfiguration::BillingProvider::OrSymbol,
|
|
615
|
+
configuration: T::Hash[Symbol, T.anything],
|
|
616
|
+
customer_id: String,
|
|
607
617
|
delivery_method:
|
|
608
618
|
MetronomeSDK::Contract::CustomerBillingProviderConfiguration::DeliveryMethod::OrSymbol,
|
|
609
|
-
|
|
610
|
-
|
|
619
|
+
delivery_method_configuration: T::Hash[Symbol, T.anything],
|
|
620
|
+
delivery_method_id: String
|
|
611
621
|
).returns(T.attached_class)
|
|
612
622
|
end
|
|
613
623
|
def self.new(
|
|
624
|
+
# ID of this configuration; can be provided as the
|
|
625
|
+
# billing_provider_configuration_id when creating a contract.
|
|
626
|
+
id:,
|
|
614
627
|
archived_at:,
|
|
628
|
+
# The billing provider set for this configuration.
|
|
615
629
|
billing_provider:,
|
|
616
|
-
delivery_method:,
|
|
617
|
-
id: nil,
|
|
618
630
|
# Configuration for the billing provider. The structure of this object is specific
|
|
619
631
|
# to the billing provider.
|
|
620
|
-
configuration
|
|
632
|
+
configuration:,
|
|
633
|
+
customer_id:,
|
|
634
|
+
# The method to use for delivering invoices to this customer.
|
|
635
|
+
delivery_method:,
|
|
636
|
+
# Configuration for the delivery method. The structure of this object is specific
|
|
637
|
+
# to the delivery method.
|
|
638
|
+
delivery_method_configuration:,
|
|
639
|
+
# ID of the delivery method to use for this customer.
|
|
640
|
+
delivery_method_id:
|
|
621
641
|
)
|
|
622
642
|
end
|
|
623
643
|
|
|
624
644
|
sig do
|
|
625
645
|
override.returns(
|
|
626
646
|
{
|
|
647
|
+
id: String,
|
|
627
648
|
archived_at: T.nilable(Time),
|
|
628
649
|
billing_provider:
|
|
629
650
|
MetronomeSDK::Contract::CustomerBillingProviderConfiguration::BillingProvider::TaggedSymbol,
|
|
651
|
+
configuration: T::Hash[Symbol, T.anything],
|
|
652
|
+
customer_id: String,
|
|
630
653
|
delivery_method:
|
|
631
654
|
MetronomeSDK::Contract::CustomerBillingProviderConfiguration::DeliveryMethod::TaggedSymbol,
|
|
632
|
-
|
|
633
|
-
|
|
655
|
+
delivery_method_configuration: T::Hash[Symbol, T.anything],
|
|
656
|
+
delivery_method_id: String
|
|
634
657
|
}
|
|
635
658
|
)
|
|
636
659
|
end
|
|
637
660
|
def to_hash
|
|
638
661
|
end
|
|
639
662
|
|
|
663
|
+
# The billing provider set for this configuration.
|
|
640
664
|
module BillingProvider
|
|
641
665
|
extend MetronomeSDK::Internal::Type::Enum
|
|
642
666
|
|
|
@@ -706,6 +730,7 @@ module MetronomeSDK
|
|
|
706
730
|
end
|
|
707
731
|
end
|
|
708
732
|
|
|
733
|
+
# The method to use for delivering invoices to this customer.
|
|
709
734
|
module DeliveryMethod
|
|
710
735
|
extend MetronomeSDK::Internal::Type::Enum
|
|
711
736
|
|