Class: MetronomeSDK::Models::V1::PackageCreateParams::Override::OverrideSpecifier

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/metronome_sdk/models/v1/package_create_params.rb,
sig/metronome_sdk/models/v1/package_create_params.rbs

Defined Under Namespace

Modules: BillingFrequency

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#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) ⇒ Object

Some parameter documentations has been truncated, see MetronomeSDK::Models::V1::PackageCreateParams::Override::OverrideSpecifier for more details.

Parameters:

  • any_commit_or_credit_ids (Array<String>) (defaults to: nil)

    Can only be used for commit specific overrides. Must be used in conjunction with

  • billing_frequency (Symbol, MetronomeSDK::Models::V1::PackageCreateParams::Override::OverrideSpecifier::BillingFrequency) (defaults to: nil)
  • commit_ids (Array<String>) (defaults to: nil)

    Can only be used for commit specific overrides. Must be used in conjunction with

  • presentation_group_values (Hash{Symbol=>String}) (defaults to: nil)

    A map of group names to values. The override will only apply to line items with

  • pricing_group_values (Hash{Symbol=>String}) (defaults to: nil)

    A map of pricing group names to values. The override will only apply to products

  • product_id (String) (defaults to: nil)

    If provided, the override will only apply to the product with the specified ID.

  • product_tags (Array<String>) (defaults to: nil)

    If provided, the override will only apply to products with all the specified tag

  • recurring_commit_ids (Array<String>) (defaults to: nil)

    Can only be used for commit specific overrides. Must be used in conjunction with



1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1001

class OverrideSpecifier < MetronomeSDK::Internal::Type::BaseModel
  # @!attribute any_commit_or_credit_ids
  #   Can only be used for commit specific overrides. Must be used in conjunction with
  #   one of `product_id`, `product_tags`, `pricing_group_values`, or
  #   `presentation_group_values`. Must be used instead of both `commit_ids` and
  #   `recurring_commit_ids` If provided, the override will apply to any specified
  #   commit, credit, recurring commit or recurring credit IDs.
  #
  #   @return [Array<String>, nil]
  optional :any_commit_or_credit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]

  # @!attribute billing_frequency
  #
  #   @return [Symbol, MetronomeSDK::Models::V1::PackageCreateParams::Override::OverrideSpecifier::BillingFrequency, nil]
  optional :billing_frequency,
           enum: -> { MetronomeSDK::V1::PackageCreateParams::Override::OverrideSpecifier::BillingFrequency }

  # @!attribute commit_ids
  #   Can only be used for commit specific overrides. Must be used in conjunction with
  #   one of `product_id`, `product_tags`, `pricing_group_values`, or
  #   `presentation_group_values`. If provided, the override will only apply to the
  #   specified commits. If not provided, the override will apply to all commits.
  #
  #   @return [Array<String>, nil]
  optional :commit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]

  # @!attribute presentation_group_values
  #   A map of group names to values. The override will only apply to line items with
  #   the specified presentation group values.
  #
  #   @return [Hash{Symbol=>String}, nil]
  optional :presentation_group_values, MetronomeSDK::Internal::Type::HashOf[String]

  # @!attribute pricing_group_values
  #   A map of pricing group names to values. The override will only apply to products
  #   with the specified pricing group values.
  #
  #   @return [Hash{Symbol=>String}, nil]
  optional :pricing_group_values, MetronomeSDK::Internal::Type::HashOf[String]

  # @!attribute product_id
  #   If provided, the override will only apply to the product with the specified ID.
  #
  #   @return [String, nil]
  optional :product_id, String

  # @!attribute product_tags
  #   If provided, the override will only apply to products with all the specified
  #   tags.
  #
  #   @return [Array<String>, nil]
  optional :product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]

  # @!attribute recurring_commit_ids
  #   Can only be used for commit specific overrides. Must be used in conjunction with
  #   one of `product_id`, `product_tags`, `pricing_group_values`, or
  #   `presentation_group_values`. If provided, the override will only apply to
  #   commits created by the specified recurring commit ids.
  #
  #   @return [Array<String>, nil]
  optional :recurring_commit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]

  # @!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)
  #   Some parameter documentations has been truncated, see
  #   {MetronomeSDK::Models::V1::PackageCreateParams::Override::OverrideSpecifier} for
  #   more details.
  #
  #   @param any_commit_or_credit_ids [Array<String>] Can only be used for commit specific overrides. Must be used in conjunction with
  #
  #   @param billing_frequency [Symbol, MetronomeSDK::Models::V1::PackageCreateParams::Override::OverrideSpecifier::BillingFrequency]
  #
  #   @param commit_ids [Array<String>] Can only be used for commit specific overrides. Must be used in conjunction with
  #
  #   @param presentation_group_values [Hash{Symbol=>String}] A map of group names to values. The override will only apply to line items with
  #
  #   @param pricing_group_values [Hash{Symbol=>String}] A map of pricing group names to values. The override will only apply to products
  #
  #   @param product_id [String] If provided, the override will only apply to the product with the specified ID.
  #
  #   @param product_tags [Array<String>] If provided, the override will only apply to products with all the specified tag
  #
  #   @param recurring_commit_ids [Array<String>] Can only be used for commit specific overrides. Must be used in conjunction with

  # @see MetronomeSDK::Models::V1::PackageCreateParams::Override::OverrideSpecifier#billing_frequency
  module BillingFrequency
    extend MetronomeSDK::Internal::Type::Enum

    MONTHLY = :MONTHLY
    QUARTERLY = :QUARTERLY
    ANNUAL = :ANNUAL
    WEEKLY = :WEEKLY

    # @!method self.values
    #   @return [Array<Symbol>]
  end
end

Instance Attribute Details

#any_commit_or_credit_idsArray<String>?

Can only be used for commit specific overrides. Must be used in conjunction with one of product_id, product_tags, pricing_group_values, or presentation_group_values. Must be used instead of both commit_ids and recurring_commit_ids If provided, the override will apply to any specified commit, credit, recurring commit or recurring credit IDs.

Parameters:

  • (::Array[String])

Returns:

  • (Array<String>, nil)


1010
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1010

optional :any_commit_or_credit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]

#billing_frequencySymbol, ...



1015
1016
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1015

optional :billing_frequency,
enum: -> { MetronomeSDK::V1::PackageCreateParams::Override::OverrideSpecifier::BillingFrequency }

#commit_idsArray<String>?

Can only be used for commit specific overrides. Must be used in conjunction with one of product_id, product_tags, pricing_group_values, or presentation_group_values. If provided, the override will only apply to the specified commits. If not provided, the override will apply to all commits.

Parameters:

  • (::Array[String])

Returns:

  • (Array<String>, nil)


1025
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1025

optional :commit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]

#presentation_group_valuesHash{Symbol=>String}?

A map of group names to values. The override will only apply to line items with the specified presentation group values.

Returns:

  • (Hash{Symbol=>String}, nil)


1032
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1032

optional :presentation_group_values, MetronomeSDK::Internal::Type::HashOf[String]

#pricing_group_valuesHash{Symbol=>String}?

A map of pricing group names to values. The override will only apply to products with the specified pricing group values.

Returns:

  • (Hash{Symbol=>String}, nil)


1039
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1039

optional :pricing_group_values, MetronomeSDK::Internal::Type::HashOf[String]

#product_idString?

If provided, the override will only apply to the product with the specified ID.

Parameters:

  • (String)

Returns:

  • (String, nil)


1045
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1045

optional :product_id, String

#product_tagsArray<String>?

If provided, the override will only apply to products with all the specified tags.

Parameters:

  • (::Array[String])

Returns:

  • (Array<String>, nil)


1052
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1052

optional :product_tags, MetronomeSDK::Internal::Type::ArrayOf[String]

#recurring_commit_idsArray<String>?

Can only be used for commit specific overrides. Must be used in conjunction with one of product_id, product_tags, pricing_group_values, or presentation_group_values. If provided, the override will only apply to commits created by the specified recurring commit ids.

Parameters:

  • (::Array[String])

Returns:

  • (Array<String>, nil)


1061
# File 'lib/metronome_sdk/models/v1/package_create_params.rb', line 1061

optional :recurring_commit_ids, MetronomeSDK::Internal::Type::ArrayOf[String]

Instance Method Details

#to_hash{

Returns:

  • ({)


1035
# File 'sig/metronome_sdk/models/v1/package_create_params.rbs', line 1035

def to_hash: -> {